I'm working with two PWM channels in order to make a sine wave from DC voltage, and my strategy is to use a sine table, which means that within a specific period of time I need to update my position or step in the table, moving forward each time one step. I've tested my KWIKSTIK with MQX 4.0 and despite installing the interrupt correctly (I think?) I'm not having the results I expected. I have two questions:
-For KWIKSTIK users:
I'm using Flextimer 1 and 2 for the PWM channels, and I was testing the flextimer0 to use as interrupt. Is this correct or could it be the cause of my problem? The interrupt works but when trying to change the PWM Duty Cycle on the interrupt routine the channels do not respond well, I need to refine the signal.( Channels are working at 20 Khz, interrupt should be at 10Khz)
-For MQX users:
The only thing I have to do with MQX is to install the interrupt with int_install_isr and then I'm good to go right? I know I have to set a routine for the interrupt but besides that no further instructions are needed?
If possible, could you please provide me with a example of an interrupt in MQX 4.0? I'm interested also in an example on how to set up a PIT Timer, if the Flextimer0 Interrupt is interfering with the PWM channels.
Thanks for everything!!