I understand that writing to e.g., FTM0_C1V writes to a shadow register (which I apparently cannot see, at least with KDS). But I cannot get that value to transfer out of the shadow register. I would most like it to be transferred out when the PWM Counter is reloaded, but I would also like to know how to make it happen immediately upon writing to the shadow register.
I am trying to do this without your "drivers." I'm setting FTM=1 and CLKS[1:0] ≠ 0:0. I would note that in the manual I have (KV10P48M75RMRev. 7, September 2014) only discusses non-output compare mode and SYNCEN = 1. I'm trying to get a single edge-mode PWM going. At least initially, I don't care about synchronization with other PWMs. And I only see SYNCENn's defined. I do not see a single SYNCEN bit.
Note that if I set FTMEN=0, everything works the way I expect it to for now but I know that eventually I will want capabilities like Deadtime which only exist when FTMEN=1.
Code is attached.
Original Attachment has been moved to: main.c.zip
Original Attachment has been moved to: HdwrRegDefn.h.zip
Hi
For the customer is using a single-edge PWM mode of FTM module, the CnV register update doesn't support combined mode PWM synchronization (C(n)V and C(n+1)V register synchronization).
As table 35-245 shows, customer need to select below CnV synchronization way(with red rectangle):
Wish it helps.
Have a great day,
Ma Hui
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
I’m not sure I understand what I can or cannot do. I’ve tried all sorts of setups and NONE of them work.
Perhaps you could send me an example of ANY PWM setup with FTMEN=1 where the CnV register is updated immediately after its shadow is written to or at the next counter reload point, but without writing to any other register.
Hi
1> Below example is about combine PWM C(n)V & C(n+1)V register synchronization:
2> There also with another way to update the FTM CnV register with CLKS[1:0] = 0:0
Wish it helps.
Have a great day,
Ma Hui
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------