Part Number: LAUNCHXL-F280049C
Other Parts Discussed in Thread: C2000WARE, TIDA-010054
Hi, my name is Iulian Popa.
I´m a student from Univerity of Zaragoza in Spain. Im using one of your development board 'LAUNCHXL-F280049C' and I have some questions and problems when I´m trying to control some PWM signals.
First of all, Im using:
- CodeComposer version 9.3
- C2000Ware version 3.1.0.00
Finally, after the support of Nima Eskandari in my post (e2e.ti.com/.../954853) I have achieved a phase shift control where I am able to update both the phase shift and the high resolution phase shift. However, I have made a couple of tests to verify the correct operation of the MEP module(I have followed forum post to learn how to use this module).
I am using the internal oscillator of the MCU at a frequency of 10 MHz and using the PLL defines as follows:
#define DEVICE_OSCSRC_FREQ 10000000U
#define DEVICE_SETCLOCK_CFG (SYSCTL_OSCSRC_OSC2 | SYSCTL_IMULT(40) |
SYSCTL_FMULT_NONE | SYSCTL_SYSDIV(2) |
SYSCTL_PLL_ENABLE)
#define DEVICE_SYSCLK_FREQ ((DEVICE_OSCSRC_FREQ * 40 * 1) / 2)
With this I am able to generate 100 KHz PWM signals with a resolution of 5ns (TBPRD = 2000; Measured frequency = 100 KHz ; Resolution obtained 5ns).
Using the functions of the library "SFO_V8.h" each one of the coarse steps of 5ns divides them into 33 fine steps (150ps of resolution). However, in practice when I try to manually configure the EPwmxRegs.TBPHS.bit.TBPHSHR register with multiples of 256 from 256*1, 256*2, 256*3, 256*4 ...256*33 the phase shift obtained is not 150ps * 33 micro-steps = 5ns in fact the result is close to 2.5ns.
Why is it that the 33 steps indicated by the MEP module do not sweep all the coarse step?
A greeting. Iulian.
Translated with www.DeepL.com/Translator (free version)







