AnsweredAssumed Answered

S12XE TIM Output Compare Set and Clear Pins

Question asked by Ray Hall on Sep 24, 2016
Latest reply on Sep 29, 2016 by Ray Hall

I am trying to use TIM to charge and then discharge an ignition coil. I have spent many hours trying to get the output compare to work. All the examples I can find toggle the pin on compare. None show how to set and clear the pins.

What I required  is to enable the OC to interrupt in the future to set the pin. In the interrupt the next interrupt period is set to clear the pin.

 

I have attached my attempt that will do this only one time.

 

Ray.

 

 

Please do not mark this question as "presumed answered" until I have confirmed this to be true.

Original Attachment has been moved to: TIM_OutputCompare.zip

Outcomes