This topic has 4 replies, 3 voices, and was last updated 6 years, 3 months ago by Dave.

  • Author
    Posts
  • #5597

    On the electrical assembly page, the documentation says to use a DB9 Rs232 To TTL cable (MCU-026-072) to connect a Roboteq controller to a microcontroller. However, in this code example (https://github.com/SuperDroidRobots/SDC2130-Example/blob/master/SDC2130_Example/SDC2130_Example.ino), it says “Pins 6 and 7 are for TTL level serial”. I tried connecting an Arduino with my SDC2130. I was able to communicate over the digital input pins of the SDC2130 but not over pins 6 and 7 via a TTL serial connection.

    What I did was connect the Rx (D0) and Tx (D1) pins of the Arduino to pins 6 and 7, respectively, on the Roboteq with a wire. Am I missing something? Could you elaborate on this more?

    #5599
     SuperDroid
    Keymaster

    Hi,
    We have to fix that example code, they use to have pins 6 and 7 to be ttl but now you have to use rs232. You can see the RoboteQ datasheet page 6. You can follow this wiring diagram.
    https://sdr-files.s3.us-east-2.amazonaws.com/Schematics/Roboteq_RS232.pdf

    Thanks for letting us know.

    • This reply was modified 2 years, 8 months ago by SuperDroid.
    #5603
     Dave
    Participant

    Hello, I’m also trying to get that exact same demo code working as well, but I’m confused on a couple of points.

    1. Do you need to use the “DB9 Rs232 To TTL cable MCU-026-072” or can you connect the SDC2130 directly to the Arduino? Could you please share the schematic for a direct connection? [ex. SDC2130 DB15 pin2 to Arduino P0 & SDC2130 DB15 P3 to Arduino P1]
    2. The example code mentioned above states that the “Roboteq SDC2130 COM (Must be 115200)” but I don’t see where you can change the rate in the RoboteQ Utility. Is 115200 the motor controller defult? How can I verify this?
    3. It sounds like the encoders have to be enabled using the RobotieQ Utility. What is the proper configuration? I’ve tried a few and I can see the output in the Utility, but no luck with the Arduino moving the motor.
    4. Does the SDC2130 DB P5 need to be connected to ground? If yes, I assume it need to be connected to the Arduino Gnd based on note 5 on pg 5 of the SDC2130 manual.

    Thank you very much for your help!

    PS. I am using your encoder pull-up board (TE-179-000)

    #5604
     SuperDroid
    Keymaster

    Hey Dave,

    See the answers to your questions below:
    1. A direct connection will not work here. You need the RS-232 to TTL converter cable.
    2. The only baud rate accepted by the RoboteQ MC is 115200. The Ardunio serial port has to be initialized to this rate.
    3. Once the encoders have been enabled in Roborun and the configuration has been flashed to the RoboteQ, you should be able to poll encoder data with the Arduino. Of course, the answers to questions 1 and 2 will have to be addressed first. Also, here’s a schematic to verify the encoder wiring: https://www.superdroidrobots.com/Schematics/Roboteq_SDC2260_&_SDC2230.pdf
    4. Yes. The schematic in the previous post shows this. The ground is connected to the signal converter which will also be connected to the Arduino.

    Let us know if you have anymore questions!

    #5605
     Dave
    Participant

    Hello,

    Thank you for your quick reply. Looks like I’ll need to order your DB9 Rs232 To TTL cable MCU-026-072 (or is there a more appropriate one?). Meanwhile, regarding enabling the encoders (question 3). There are two different options for enabling the encoders and two boxes that can be checked. Does it matter which option or if any of the boxes are checked? Thanks.

    Dave

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

Login Register

©2024 SDRobots.com | All rights reserved.

Log in with your credentials

or    

Forgot your details?

Create Account