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.
Part Number: TIDM-1003
Tool/software: Code Composer Studio
Do I need to modify the default code to enable the system and connect the throttle to use as a stand alone circuit?
To start the motor in CCS, I have to click in enable system and set it to 1, then click on run and set it to one, then click on SpeedRef_krpm and set it to a value to control speed.
When I cycle power however, the board is not controlling any speed nor does the throttle have any effect. My thought is that enable and run have to be hard-coded to 1 in order to use this board outside of CCS. Is that so? Also, there appears to be no link in the code between throttle.result and gMotorVars.SpeedRef_krpm. Is this a line I will need to add?
Thank you in advance and best regards,
P.S., here is where I expected this link, around line 400 in TIDM-1003.c
// set the speed reference
// set the speed acceleration
Flag_Latch_softwareUpdate = false;
// initialize the watch window kp and ki current values with pre-calculated values
gMotorVars.Kp_Idq = CTRL_getKp(ctrlHandle,CTRL_Type_PID_Id);
gMotorVars.Ki_Idq = CTRL_getKi(ctrlHandle,CTRL_Type_PID_Id);
// initialize the watch window kp and ki values with pre-calculated values
gMotorVars.Kp_spd = CTRL_getKp(ctrlHandle,CTRL_Type_PID_spd);
gMotorVars.Ki_spd = CTRL_getKi(ctrlHandle,CTRL_Type_PID_spd);
Flag_Latch_softwareUpdate = true;
// the estimator sets the maximum current slope during identification
gMaxCurrentSlope = EST_getMaxCurrentSlope_pu(obj->estHandle);
// when appropriate, update the global variables
if(gCounter_updateGlobals >= NUM_MAIN_TICKS_FOR_GLOBAL_VARIABLE_UPDATE)
// reset the counter
gCounter_updateGlobals = 0;
We are glad that we were able to resolve this issue, and will now proceed to close this thread.
If you have further questions related to this thread, you may click "Ask a related question" below. The newly created question will be automatically linked to this question.
In reply to Yanming Luo:
In reply to Sean Cashin:
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.