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/TMS320F28069M: TMS320F28069M

Part Number: TMS320F28069M
Other Parts Discussed in Thread: CONTROLSUITE

Tool/software: Code Composer Studio

Hello,

In the sample code which is located here: C:\ti\controlSUITE\development_kits\DRV8312-C2-KIT_v128\BLDC_Sensored. I want to know what is the purpose of following variables.

HallMap[6] and HallMapPointer. I have already referred the documents of the same it is well written and there is also comments on each  line in sample code. Still I don't understand the purpose of above mention variable.

why hall1.Revolutions is set to -3 initially?

  • You may have a look at the "hall_gpio_drv.pdf" document that helps you to find the answer to your question. The file could be found in the folder of controlSuite.

    C:\ti\controlSUITE\libs\app_libs\motor_control\drivers\f2803x_v121\~Docs

    And you might have a look at the application guide in the below folder of controlSUITE that shows how to create the hall map using open loop control.
    C:\ti\controlSUITE\development_kits\DRV8312-C2-KIT_v128\BLDC_Sensored\~Docs
  • I have already read both documents as I mentioned earlier. Still I have doubt and why hall1.DebounceAmount is 0? There is no meaning if this variable is 0. please clarify.

  • That means the debounce will be bypassed, but you can set it to any non-zero value to enable if according to the hall signal quality. You may go through the two documents mentioned above, and then easy to understand the C code for you.
  • Can you tell me what will happen in the very first stage? How it will determine the current hall state and how it will apply next state? in the main HALL3_INIT_MACRO(hall1) is called as a initialization, So the HallGpioAccepted will as per current state of hall signal but inside void A1(void) it will be 0.
  • Hope you may find the below code in the top of BLDC_Sensored.c, all the variables in the "HALL3" struct have been initialized first., and then will be set again if the flags have been changed. The right state of hall GPIO should get from HALL3_INIT_MACRO() by default. This reference doesn't consider this motor restart, not a real solution for a product, just show how to run BLDC with the hall sensor.
    // Instance a Hall effect driver
    HALL3 hall1 = HALL3_DEFAULTS;