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.

CCS/TMDXIDDK379D: BLDC Operation for IDDK

Part Number: TMDXIDDK379D


Tool/software: Code Composer Studio

I am trying to use the IDDK for driving a BLDC motor, and have not found any information online pertaining to these two specifically.  Is there any information available for BLDC operation on the IDDK, such as which libraries to use, SW to alter from IDDK_PM_SERVO example, etc?  Thank you

  • A BLDC with Hall effect sensors

  • Hello,

    For IDDK, only PMSM motor control projects are provided right now. If you want to control BLDC motors, you can refer to that under the HVMotor+PFC board. It has a range of projects supporting various motors. But you will have to port over yourself.

  • Hello,

    I am trying to grasp the scope for doing this, and what code is necessary to port over.

    For the Hall Effect sensors, would I hook them up to the QEP module and reconfigure the QEP code for the hall SW from the HVM+PFC project?

    The PWM code seems substantially different from the PFC piccolo SW to the IDDK delfino SW. Am I maintaining the PWM code from the IDDK and altering the PFC code as I port it over, or use the PWM code from the PFC kit.

    For instance in the PeripheralHeaderIncludes:
    // Include All Peripheral Header Files:
    //
    #include "DSP2803x_Adc.h" // ADC Registers
    #include "DSP2803x_BootVars.h" // Boot ROM Variables
    #include "DSP2803x_DevEmu.h" // Device Emulation Registers
    #include "DSP2803x_Cla.h" // Control Law Accelerator Registers
    #include "DSP2803x_Comp.h" // Comparator Registers
    #include "DSP2803x_CpuTimers.h" // 32-bit CPU Timers
    #include "DSP2803x_ECan.h" // Enhanced eCAN Registers
    #include "DSP2803x_ECap.h" // Enhanced Capture
    #include "DSP2803x_EPwm.h" // Enhanced PWM
    #include "DSP2803x_EQep.h" // Enhanced QEP
    #include "DSP2803x_Gpio.h" // General Purpose I/O Registers
    #include "DSP2803x_I2c.h" // I2C Registers
    #include "DSP2803x_Lin.h" // LIN Registers
    #include "DSP2803x_NmiIntrupt.h" // NMI Interrupt Registers
    #include "DSP2803x_PieCtrl.h" // PIE Control Registers
    #include "DSP2803x_PieVect.h" // PIE Vector Table
    #include "DSP2803x_Spi.h" // SPI Registers
    #include "DSP2803x_Sci.h" // SCI Registers
    #include "DSP2803x_SysCtrl.h" // System Control/Power Modes
    #include "DSP2803x_XIntrupt.h" // External Interrupts

    Can I keep these or do I have to convert them to the F2837x version?

    Thank you, any guidance is much appreciated.
  • You can keep the project in IDDK, and change it to support sensored BLDC as HVMTRPFC kit. You only need to port below files for driver to IDDK project, change the pwm configuration for BLDC as in f2803xbldcpwm_BLDC.h.
    f2803xbldcpwm_BLDC.h
    f2803xhall_gpio_BLDC.h
    f2803xileg_vdc_BLDC.h

    And port below files for BLDC control.
    BLDC_Sensored.c
    BLDC_Sensored.h
    mod6_cnt.h
    impulse.h

    The pid_grando.h, speed_pr.h, rmp_cntl.h, rmp2cntl.h and rmp3cntl.h should be used in IDDK project also.
  • From my understanding do you mean to import into IDDK:

    f2803xhall_gpio_BLDC.h
    f2803xileg_vdc_BLDC.h
    BLDC_Sensored.c
    BLDC_Sensored.h
    mod6_cnt.h
    impulse.h

    pid_grando.h,

    speed_pr.h,

    rmp_cntl.h,

    rmp2cntl.h 

    rmp3cntl.h

    2) Then change pwm configuration in  f2803xbldcpwm_BLDC.h to match F2837xD_epwm.h in the IDDK?

    3) Now I use BLDC_Sensored.c instead of IDDK_PM_Servo_F2837x.c and this will run BLDCs on the IDDK?

  • More flexible, refer to f2803xbldcpwm_BLDC.h and f2803xileg_vdc_BLDC.h to change the pwm and adc configuration in IDDK project.
    It's ok to use BLDC_Sensored.c in IDDK, but you need to change pwm and adc configuration to match IDDK board.
  • Still confused

    So port over:
    mod6_cnt.h
    impulse.h
    pid_grando.h,
    speed_pr.h,
    rmp_cntl.h,
    rmp2cntl.h
    rmp3cntl.h
    BLDC_Sensored.c
    BLDC_Sensored.h

    And use these files below
    f2803xhall_gpio_BLDC.h
    f2803xileg_vdc_BLDC.h
    f2803xbldcpwm_BLDC.h

    to reconfigure their respective header files in the IDDK project? Then use BLDC_Sensored.c for operation?
  • Your choice, you can use BLDC_Sensored.c in IDDK project, change the pwm and adc configuration based IDDK board, or use the main source file in IDDK project, and port the BLDC_Sensored.c to it.
  • Where do I hook up the hall effect sensors to?