AnsweredAssumed Answered

PWM output Port configuration

Question asked by binki on May 16, 2013
Latest reply on May 17, 2013 by Nabeel

Hi,

 

I am trying to use PWM_AH channel to generate 50% duty cycle.

 

Can you please guide me if i have done any wrong configuration in port registers.

 

I am supposed to get output on PF01 and pin no 20 of J1.

 

 

int main(void)

{

    /* Initialize managed drivers and/or services */

    adi_initComponents();

 

    /**

     * The default startup code does not include any functionality to allow

     * core 0 to enable core 1. A convenient way to enable core 1 is to use the

     * 'adi_core_1_enable' function.

     */

    adi_core_1_disable();

 

 

 

    *pREG_PORTF_FER = BITM_PORT_FER_CLR_PX1;

    *pREG_PORTF_FER = BITM_PORT_FER_PX1;

    *pREG_PORTF_MUX = (0x00000004);

 

    Pwm_Init(NULL_PTR);

    /* Begin adding your custom code here */

    while(1)

    {

        asm("NOP;");

    }

      //     Pwm_SetDutyCycle(PWM_CHANNEL_ZERO,0x2000);

 

}

 

Thanks in Advance.

 

Regards,

Kishore K

Outcomes