Shop OBEX P1 Docs P2 Docs Learn Events
Prop and Sabertooth 2x10 motor driver — Parallax Forums

Prop and Sabertooth 2x10 motor driver

J_WJ_W Posts: 2
edited 2011-02-06 18:20 in Propeller 1
First off I wanted to say I love the propeller and its possibilities. There is so much that I can do with this chip, but first things first. I am trying to control a Sabertooth 2x10 motor controller with the prop, but nothing seems to be working. According to the documentation, it can be controlled by either serial commands, or pulses in the 1000 to 2000 microsecond range. I have tried both, but neither are working for me. I have searched all over for a solution so you guys are my last hope. I know the motor controller works because I hooked it up to a Pot and controlled it that way.

I would really like to get the serial option working. I tried using the "Simple_Serial.spin" file to set the baud and send the commands, but there is no response. I don't really understand how the serial communications work, nor do I know which of the hundreds of serial spin files to use. Any help would be great.

Thanks,
Jason

Comments

  • bambinobambino Posts: 789
    edited 2011-02-06 17:48
    The documation posted says that to use simplified serial a TTL signal 0 to 5 volts is expected. A lot of devices can see the 3.3 volts from a propeller as a high signal, this device may not! I don't know for sure if this is the case here, but if you where to buffer the output from the prop with a darlington transistor and use 5 volts for the signal you may have some results.
    Hope this helps.
  • J_WJ_W Posts: 2
    edited 2011-02-06 18:20
    That is a great point. I knew that the prop output 3.3 volts, but I guess I overlooked it when sending the signal. I will try your suggestion.

    My other question, then, is can I use the "Simple_Serial.spin" file and use the following code to send the appropriate signals:
    CON   
      _clkmode = xtal1 + pll16x
      _xinfreq = 5_000_000
    
    OBJ
      serial : "Simple_Serial"                              ' bit-bang serial driver
      
    PUB start
    
      serial.init(-1, 0, 9600)  'only need tx on pin 0, and rx is -1 and baud set to 9600
    
      serial.tx(80)  'send motor one forward signal
      serial.tx(208)  'send motor two forward signal
    
    Thanks,
    Jason
Sign In or Register to comment.