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.

TMS320F280039C: Porting Universal Code to Custom board

Part Number: TMS320F280039C
Other Parts Discussed in Thread: C2000WARE, C2000WARE-MOTORCONTROL-SDK

Hi team,
I am working on sensor less FOC using TMS320F280039C controller.
I am using Universal motor control lab code and Ported code from F280025 to F280039C micro controller (Custom drive + f280039C).
Example lab project at the folder: C:\ti\c2000\C2000Ware_MotorControl_SDK_<version>\solutions\universal_motorcontrol_lab\f28002x.
C2000WARE-MOTORCONTROL-SDK: www.ti.com/.../C2000WARE-MOTORCONTROL-SDK
Universal Project and Lab User’s Guide: www.ti.com/.../spruj26.

As per Universal_motorcontrol_lab guide, we are changed the Below parameters from HVKIT to custom board.

USER_M1_NOMINAL_DC_BUS_VOLTAGE_V 690
USER_M1_ADC_FULL_SCALE_VOLTAGE_V 690
USER_M1_VOLTAGE_FILTER_POLE_Hz 340.0f
USER_M1_ADC_FULL_SCALE_CURRENT_A 40.00f
DC_bus scale factor 1300

FYI: We have been tested HVKIT with F280039C CPU using universal code. Now, we are testing custom board with TI PMSM motor.

1.What are the other parameters We need to change From HVKIT to custom board?

Please Help me.

Thanks & Regards.

  • The "Building Custom Board" chapter of the lab guide is fairly complete. I assume you also made the required updates for the pins/peripherals in use--or does your custom board happen to use the same pins as the controlCARD+HVKIT setup? I guess one thing that isn't mentioned in this chapter (but is elsewhere in the document) is making sure that adcData.current_sf has the right sign for your board (see initMotor1CtrlParameters() function).

    By the way, we did release an F28003x version of this lab in v4.01.00.00 of the SDK (I assume you're using an earlier version since you said you ported from 002x). It sounds like your own port is working fine, but it's there if you want to refer to it.

    Whitney

  • Hi Whitney Dewey,

    Thanks for the Reply.

    We are ported the code from HVKIT to our Custom board.

    FYI: Build level-1 was completed (Checked ADC Readings and PWMS, All are working).

    Now, We are testing Build level-2 i.e., Open loop testing. We observed that the motor rotating at reference speed (Measured with Tachometer), But getting Feedback Speed "motorVars_M1.speed_Hz" was not matched.

    At 10Hz SpeedRef, the feedback speed was 5 Hz.

    At 20Hz SpeedRef, the feedback speed was 15 Hz.

    What could be the reason for feed back speed not matched with Reference speed?.

    Please help me.

    Thanks & Regards.

  • For lab 2 you sometimes need to tune the v/f profile parameters in user_mtr1.h sometimes to get it running well, although I'm not sure if that will help with this particular issue, especially if build level 2 was working okay with the same motor and the HVKIT.

    #define USER_MOTOR1_FREQ_LOW_Hz (10.0f) // Hz
    #define USER_MOTOR1_FREQ_HIGH_Hz (200.0f) // Hz
    #define USER_MOTOR1_VOLT_MIN_V (10.0f) // Volt
    #define USER_MOTOR1_VOLT_MAX_V (200.0f) // Volt

    Our primary expert for this project is out of the office at the moment, but I can check in with him when he's back next week.

    Whitney