フィルターのクリア

DC-motor control with F28379D LaunchPad and BOOST-DRV8848 Dual H-Bridge Motor Driver

8 ビュー (過去 30 日間)
Peter Fiebig
Peter Fiebig 2022 年 8 月 29 日
編集済み: Sayan 2023 年 12 月 5 日
Hey,
I want to control one DC Motor. As input, I’ve got potentiometers which are connected to ADC ports. I’m using the F28379D LaunchPad with the DRV8848 Dual Bridge Motor driver on top. I wanted to use the ePWM module from the Embedded Coder Toolbox for TI C2000 processors. I’ve attached the block diagram when using parallel mode from the Datasheet of the motor driver.
How can I use the potentiometer to control the speed of the motor?
I’m really struggling the this and I feel like it shouldn’t be that difficult.
I appreciate any help I can get and thank you for your time.

回答 (1 件)

Sayan
Sayan 2023 年 12 月 5 日
編集済み: Sayan 2023 年 12 月 5 日
Hi Peter Fiebig,
I understand from your query that you need to find a way to control the speed of the motor using the F28379D Launchpad with the DRV8848 Dual Bridge Motor driver on top by varying the potentiometer.
You can follow these steps to opt for the same.
  • The speed of the motor is directly related to the duty ratio of the PWM pulses provided using the ePWM block of the corresponding processor. So, the idea is to vary the duty ratio by varying the potentiometer.
  • In the ePWM block, choose the value of the "Specify CMPA via" parameter as "Input port" in the "Counter Compare" tab. This creates an input port in the ePWM block. The value provided in the input port defines the reference value against which the carrier signal will be compared to generate the PWM signal.
  • Configure other parameters of the ePWM block as required for your application ("Timer period", "Counting mode" etc.).
  • Connect the ADC output to the input port of the ePWM block.
  • Make the required scaling of the ADC output before providing it to the ePWM input. The scaling factor can be determined by the "Timer period" , range of ADC you are using, and the range of duty cycle you need to vary. This will ensure the "CMPA value" changes whenever the potentiometer is varied and the ADC senses the new voltage.
  • As the "CMPA value" changes, the duty ratio of the PWM also changes, which in turn changes the speed of the motor.
For more information on how to configure the ePWM block, you can refer to the following documentation:
Hope this helps in answering the query.

製品


リリース

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by