Tool/software: Code Composer Studio
I am using TMS320F29335 to run a three-phase inverter. It is working very well at 5 kHz but whenever I increase frequency by using different values as TBPRD I get sinusoidal output instead pulsed inverted output. Is there any other parameter I need to change with TBPRD to change the switching frequency? such as any of these parameters;
int fs=500; // frequency of the output sinusoidal
InitCpuTimers(); // Start the timer modules
// Configure CPU-Timer 0, 1, and 2 to interrupt every second:
// 150MHz CPU Freq, 1 second Period (in uSeconds
ConfigCpuTimer(&CpuTimer0,150,50); // Configure CPU - Timer0 at 1000 microseconds
EPwm1Regs.TBPRD = 7500; // timer period for 5 KHz, Note: TBPRD = 1/4 ( 150 MHz / 5kHz) = 7,500
Thanks.