This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28069: HRPWM precision

Part Number: TMS320F28069
Other Parts Discussed in Thread: C2000WARE

Hi,

The TRM discusses the HRPWM configuration and the notion of MEPs. It has been said that the duration of 1 MEP is about 150 picoseconds. However if mu MCU is running at 90Mhz then 1 SYSCLK is 11.1ns long and from there the 150 picosecond period is about 1/74-th. Thats an odd number and from there I assume that actually the MEP is 1/64-th of SYSCLK as 64 can be described with 6 bits?

From this I assume that while the TBPRDHR register is 16 bits long, then only upper 6 bits are relevant and remaining 10 bits are unused? That would give 64 microsteps fro every SYSCLK and the 1 MEP duration would be about 174 picoseconds at 90Mhz operation.

Is that correct?

  • Rein,

    Rein Kadastik said:
    Thats an odd number and from there I assume that actually the MEP is 1/64-th of SYSCLK as 64 can be described with 6 bits?

    This is incorrect. Yes the MEP step has a nominal length of 150pS, but depending on operating conditions this will vary. You may end up with any number of MEP steps per clock cycle, it is not fitted to any power of 2. Please note: The SFO is provided to allow the user to convert between MEP step size and the system clock.

    Rein Kadastik said:
    From this I assume that while the TBPRDHR register is 16 bits long, then only upper 6 bits are relevant and remaining 10 bits are unused?

    No, only the upper 8 bits are used, the lower 8 are ignored. Providing you are using auto-conversion mode then you should simply write the desired fractional portion in Q format and the device will provide the closest possible output.

    Please look at "Example_2806xHRPWM_PrdUp_SFO_V6.c" in C2000Ware, it should help shed some light on the operation.

    Regards,
    Cody