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.

DRV8301-69M-KIT: PID position control in PMSM

Part Number: DRV8301-69M-KIT
Other Parts Discussed in Thread: DRV8301, C2000WARE, CONTROLSUITE, TMS320F28377D, MOTORWARE

Hello,

I am using DRV8301 - 69M kit in order to control my brushless motor U8KV135 fromT-motors. In my robotics project I have to make a position control for my tasks (sensored system) and so far I have used the great SPINTAC position controller for my task. However due to different reasons and to test some things in my motor I would like to implement a simpler P-D position controller, though the disadvantages that it has in comparison with SPINTAC position controller.

Therefore can you provide me any easy way to do that? So far I have tried to use DCL32 library from C2000ware but I had two problems:

1. I am not so sure how to match the output of the controller (variable "uk") with the torque reference in the FOC control as SPINTAC_Position_controller does.

2. I do not know how  to put DCL PID control inside the code in order to not use SPINTAC_Position_controller but  to maintain SPINTAC_Position_Planning and SPINTAC_Position_Movement.

I am not so experienced in writing codes for such tasks in C & C++. I have understood a lot of things upon the code in the projects_labs that are offered, especially in project_lab 13b and project_lab 13c which I used but it would be necessary to get help from you.

It would be pleasure to hear any advice using DCL or any new idea!

Thank you in advance!

Petros

Student at Mechanical Engineering Department

National Technical University of Athens.

  • Given SPINTAC position controller is a black box, it may be difficult for you to break down the portions of the controller to be replaced with another PID controller. It may be more helpful for you to reference this project for position control of servo motors. It is an open source project. Find it here: C:\ti\controlSUITE\development_kits\TMDSIDDK_v2.0\IDDK_PM_Servo_F2837x_v2_00_00_00

    Since the MOTION labs are built specifically for the SPINTAC controller, I think you may have difficulty removing that portion of the code from the example labs

    Sean
  • Hello Sean,

    Thank you for your reply.

    O.K thanks for the information that SPINTAC position controller is a black box and therefore I don't want to use it for some tests. However I want to maintain the other components like SPINTAC position planning , SPINTAC position movement and SPINTAC position converter in order to maintain position planning and to give my position controller the right position reference and feedback. I think I can do that right??

    Nevertheless to maintain the other components of SPINTAC library and understand how to use them with my position controller is not my priority right now. My urgent priority is to implement a position controller.

    Therefore as regarding the position controller I have two questions and one of which is upon of what you proposed to me:

    1. This open source project is for control card target TMS320F28377D right? Am I asking because the control card in DRV8301-69M KIT is TMDSCNCD28069MISO which has MCU piccolo TMSF320F2869M, so can I use this library on my control card?

    2. Also I found that in project_lab5b in motorware C:\ti\motorware\motorware_1_01_00_18\sw\solutions\instaspin_foc\boards\drv8301kit_revD\f28x\f2806xF\projects\ccs\proj_lab05b is implemented a PI speed control above the PI current control which is for Field Oriented Control. The controllers were implemented using the pid.h library and ctrl.h library also in motoware. (C:\ti\motorware\motorware_1_01_00_18\sw\modules\pid\src\32b    &      C:\ti\motorware\motorware_1_01_00_18\sw\modules\ctrl\src\32b)
    Therefore I thought that I can do the same but for a PD position controller and match the output of this controller as current reference to the current controller as it has done in this project_lab5b for speed controller . Can I do that?

    Thank you in advance!
    Petros

  • Hi Petros, were you able to resolve this question? If so, I will mark this closed. Feel free to respond here or start a new thread otherwise.

    Sean