I am attempting to use 6 of the 8 PWM outputs as 8-bit PWM on the 9S12ZVLA12MLF. I am also using CodeWarrior 10.7 and using Processor Expert to set up the channels. I cannot get PP0 to work for PWM0 nor PP2 to work for PWM2. I have also tried manipulating the PWM registers directly, but cannot get a response on those pins. Are those pins available for use as PWM?
Solved! Go to Solution.
Hi Peter,
Yes, you can use those pins for PWM.
For the S12ZVLA128 MCU, there are two PWM modules PWM0 and PWM1 available. You can see channel mapping in the reference manual Figure 1-8.:
According to the figure above you need to set PWM1 module and channel 1 for uses PWM for PP0 pin.
We have example code for the S12ZVL32 MCU. The S12ZVL32 has only one PWM module. However, it could be useful for inspiration.PWM example code for S12ZVL
I hope it helps you.
Best regards,
Diana
Hi Diana,
Thank you for the reply. I wasn't aware that they were separated like that, control-wise. Thank you for the diagram and the figure reference, that was invaluable. I missed that the mapping is different from the 32/16/8 variants to the 128/96/64 variants.
Regards,
Peter
Hi Peter,
Yes, you can use those pins for PWM.
For the S12ZVLA128 MCU, there are two PWM modules PWM0 and PWM1 available. You can see channel mapping in the reference manual Figure 1-8.:
According to the figure above you need to set PWM1 module and channel 1 for uses PWM for PP0 pin.
We have example code for the S12ZVL32 MCU. The S12ZVL32 has only one PWM module. However, it could be useful for inspiration.PWM example code for S12ZVL
I hope it helps you.
Best regards,
Diana