Post Go back to editing

pwm-dutycylcle config problem

I have a problem with pwm dutycycle config.

why duty,duty1 is uint32_t but not int32_t.   as the figure below, I need to config duty to a negative value.

For  I want to input a dutycylcle (double x:0-100) , output a 4 pwm .   Problem: set y0 as (  uint ,  int  ) , doesn't work well.  is there any suggestions?
  • Hi,

    Apologies for the delay

    The perameter Duty in the "adi_pwm_SetOutputDutyCycle API" sets the duty cycle for the PWM output. When you say, negative value of perameter Duty doesn't work well, what exactly you are looking for. Can you please specify your desired output in the form of waveform. It will help us to assist you better.