Cyril Union

falsh during pwm init on 9S08AC60

Discussion created by Cyril Union on Jun 30, 2009
Latest reply on Aug 6, 2010 by giacomopetrini

Hello evry body,

 

 

I have a trouble during the initialization phase of the timer

to generate PWM :

 

here is my code

 

  //start up Timer 1
  TPM1MOD=MAX_VALUE_PWM-2;
  TPM1SC=0x08;
 
  //startup timer channel 
  TPM1C0V=MAX_VALUE_PWM;
  TPM1C2V=MAX_VALUE_PWM;
  TPM1C3V=MAX_VALUE_PWM;

  TPM1C0SC=0x24; 
  TPM1C2SC=0x24;
  TPM1C3SC=0x24;

 

My probleme is that after this code i have one period at low level

even if i put 0 or max to TPM1CxV registers.

 

If you have any idea ...

 

Thanks for your help

 

Best regards

 

Paul

Outcomes