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.

RM46L852: MOTOR DRIVING USING PWM

Part Number: RM46L852
Other Parts Discussed in Thread: HALCOGEN

Hello all!

As I am newbie to TI controllers, I wanted to grasp on how to use them and Halcogen software to do what I want. So I went learning about it like I have learned Arduino. I've started doing basic stuff, like triggering LEDs on the board and similar.

Today, I want to learn: how can I drive motors using the PWM on Hercules board.
I've noticed that there are some extensions out there that you can buy, but I do not have does.

What I want to do is, using those cheap and small Arduino components, servo motor, BDC and stepper, to make them spin.

I am not even sure which periphery on TI controllers should I use. Is it NHET?

The first one I wanted to connect to board is servo motor since I do not need any additional drivers. I understand that I should place one line on 5V and another on GND, but where do I place the third wire? Can you help me out? How do you do this via Halcogen and later with code? I couldn't find any of the tutorials out there and there is no one to teach me how to do this. I am trying to learn TI controllers on my own.

Later, I want to try and drive stepper motor. I also have some Arduino kit driver that goes with it. How would I drive stepper motor?

In the end, I would like to try and drive the BDC motor.

The truth is, I understand how to do this, but not using TI. So far, I have never used controller that requires graphical tool (Halcogen) to manipulate the controller, so I am completely lost. Also, periphery names are a bit confusing to me, lol. :D


Are there some tutorials that completely cover how to use Halcogen and work with Hercules family controllers? I found out some official TI videos on YouTube but they do not cover much topic, at all.

Thanks!

  • Hello Marc,

    1. HALCoGen:

    We don't have regular user manual for HALCoGen. The help and sample code are embedded into HAlCoGen "help".

    here is a HALCoGen tutorial:

    The N2HET module or ePWM module can be used to generate PWM signal to drive the motor. N2HET is a high end timer module. This timer module provides sophisticated timing functions for real-time applications such as motor control. The HalCoGen has example to use NHET.

    This is a tool to simulate NHET instruction. The user guide is under teh docs folder:

    The ePWM is a peripheral called enhanced pulse width modulator.

    HALCoGen conatins ePWM example to generate PWM signals: HALCoGen-->Help-->Help Topics-->Examples-->example_etpwm_ecap.c

  • Hello QJ Wang!

    Thank you for your reply.

    I'll be sure to watch that tutorial.

    So, if I want to drive two BDC motors I could use two eCAPs? But what if I want to add three servos, two steppers, etc. I could do that with that N2HET you've talked about? How many N2HETs are available on RM46?

    Thanks once again!
    Marc Hewitt
  • Hello Marc,

    The RM46 device has 7 ePWM, 6 ECAP modules. If those are not enough for your application, yes, you can use NHET to generate PWM signals and capture the input.
  • RM46 has 2 NHET modules: N2HEt1, and N2HET2. N2HET1 has 32 pins, and N2HET2 has 18 pins. Please check the datasheet. Thanks
  • Thank you for your detailed explanation. I am sorry for being newbie.