Hi all,
Just making sure that this is the correct procedure to initialize PWM
output for channel 0. i am using a CardS12 MC9S12DP512, programmed by
ICC12.
Here is the code that i am using to start the PWM:
// Initiate PWM Port
void init_PWM(void){
PWMPOL =0xFF; // Sets PWM polarity High start, low end
PWMCLK =0x00; // Select clock source A
PWMPRCLK=0x00; // clock prescale set to zero
PWMCAE =0x00; // Left aligned mode
PWMCTL =0x00; // Do not concatenate, continuous running
PWMSCLA =0x05; // PWM scale clock A = 0x01
PWMPER0 =0x80; // Period for PWM 0
PWMDTY0 =0x40; // Duty for PWM 0
PWME =0xFF; // Enable channel 0 and 1 for output
}
// End code
Is there any reason that the PWM output should not be "seen" at PM0.
Regards,
Paul

(You need to be a member of 68hc12 -- send a blank email to 68hc12-subscribe@yahoogroups.com )