Shop OBEX P1 Docs P2 Docs Learn Events
Robot Safety-- issue 1 XBee short — Parallax Forums

Robot Safety-- issue 1 XBee short

rjo__rjo__ Posts: 2,114
edited 2013-05-08 07:23 in Robotics
I am building a Propeller based test platform as an incremental step in a long term project to build a semi-autonomous wheelchair. I am currently using 24V 15A motors.
The motors have a gear lever on them, so that they can be tested without worrying about the chair moving.

The motors are controlled by a Sabertooth 2X60 dual, regenerative motor driver. The Sabertooth has several modes of operation... serial, analog(pwm), and servo modes. For this build, I chose PWM, because there are cheaper PWM controllers that I might want to use in the future.

The test configuration includes a Prob-based xbee remote controller that I have built. There is a software kill swich of sorts. If the Prop-based controller on the bot does not receive any valid instructions in 150 milliseconds, the unit puts out a neutral PWM. I should be clear that the XBee units I am using are NOT from Parallax. AND they are NOT NEW. I found a cheap source of used parts on the internet.

Yesterday, with the motors out of gear, I was testing a program to record and re-play instructions from the remote controller to the bot. And the bot went crazy.

When I took everything apart, I found that the XBee unit was shorted out across the power terminals. The XBee was receiving 3.3V from the Quickstart. This kept the Quickstart board from being recognized by the BST gui or operating.
After replacing the Xbee module, everything worked perfectly again.

Is this a normal failure mode for an XBee? IF so, don't we need short circuit protection between our boards and these units? What would that be?

Thanks

Rich

ps... I had been planning to begin posting this project, and I will. But I'm thinking servo mode is in my future, since in this mode, without a signal, the Sabertooth just sits there:)

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2013-04-22 08:17
    No, this is not a normal failure mode for an xBee. Since they are used devices and not guaranteed (and presumably not tested), anything goes. In the future, you should assume responsibility for "incoming device testing". That's where the protection needs to be thorough. You should also consider adding additional layers of protection. Often a hardware timeout is added that has to be reset every so often by other critical controllers. If it times out, the robot shuts down
  • rjo__rjo__ Posts: 2,114
    edited 2013-04-22 08:41
    Thanks Mike. That's right. You buy cheap... you die cheap. And you only have yourself to blame.

    I actually bought on the cheap this time because I wasn't sure how useful the XBee units would be. Turns out they are really useful and a lot of fun.

    In fact... if this isn't a known failure mode, I am wondering if these are real XBee modules. They look real, the act real, but they don't fail right. Hmmm.

    On the other hand... even real XBees will eventually be old, and who knows what kind of environment effects they will suffer?
    If I assume that this kind of failure is possible(which obviously it is)... what do I put in between the module and my Prop? Would using an external power supply be enough?






    Rich
  • Mike GreenMike Green Posts: 23,101
    edited 2013-04-22 09:13
    I wouldn't say it isn't a known failure mode. Any device can develop short circuits if it's abused. A lightning strike nearby can do it, even if there's basic protection against power surges. At some point, there are diminishing returns in terms of protection against rare events. The Prop is pretty robust and mostly needs to be protected against reversed power supply connections and over-voltage inputs. Putting a fuse in the power supply leads is a reasonable protection against a short circuit. A series resistor in I/O leads (3.3K for example) can add some over-voltage protection in cases where the switching time isn't that important. Other over-voltage protections are possible. Using polarized connectors will usually protect against reversal. A fuse and a diode will usually protect against mistakes (hook the battery up backwards, the diode will short the battery through the fuse, and the fuse will blow protecting everything "downstream"). Generally, if you test your devices first, you'll catch the failed parts and the rest will likely work for years, then fail in some hard to predict way.
  • BrainStrainBrainStrain Posts: 30
    edited 2013-04-22 09:37
    Max encouragement for your project! I am also building a Prop-based wheel chair, but not autonomous... some point future. I'm starting with a joy stick, then advancing to remote control. Semi-autonomous, that is biting off a big chunk. Looking forward to hearing about your progress.
  • rjo__rjo__ Posts: 2,114
    edited 2013-04-22 10:12
    Mike... thanks. Will post what I do.

    Brainstrain,

    Wheelchairs unite!

    My project is for my grand-nephew and kids with quad type problems. My grand-nephew is anencephalic, due the mononucleosis virus. He wasn't expected to live a year. Thanks to the excellent care he has received, he is going strong at six. But, of course, he can't move.

    I have some extra joysticks off of various motorized wheelchairs... if you want one to tear apart, let me know.

    Rich
  • al1970al1970 Posts: 64
    edited 2013-05-06 23:58
    Hi:

    I would not be so fast in saying there was a problem with the XBee ! Spikes from large motors running at 24 volts are very large. I don't know how you have things wired up but I would make sure that the motors aren't causing the XBee to fail. I would check it all out with a scope. Even a wire that is close to the motor wire could carry enough of a voltage spike to cause an IC to fail.

    Al
  • rjo__rjo__ Posts: 2,114
    edited 2013-05-07 07:53
    Al,

    I have been assuming that no current spikes will originate from within the Sabertooth motor controller, but I hadn't really considered spikes coming from
    the motors themselves. I gave my scope away to a forum member, because I never used it:) As a general practice, should I be putting
    my board in a metal/grounded housing?... sort of like a Faraday cage?

    In this case, my best guess is that my sloppy handling probably damaged the XBee. But I really don't know.

    That being said, since I'm in the testing and learning phase with this project and safety is the issue,
    this problem is exactly the sort of thing I wanted to find.

    Here is what probably happened: a short circuit of the XBee kept the Quickstart board from working properly. I believe the board didn't function because the short circuit
    in the XBee sucked too much current through the 3.3v regulator circuit on the board. The Quickstart survived and appears to be OK, but because it didn't supply
    a control voltage to the motor controller... that failure caused the unengaged motors to spin out of any control... which is how the Sabertooth controller is actually designed to work.

    To keep this exact scenario from happening again, I am planning to use an independent current limited/diode protected circuit to power the XBee in the future.

    To make sure that the motor controller always gets a neutral voltage (2.5v), when a Propeller is not in control, I am thinking about the circuit shown below. The idea is that
    this will supply 2.5v until a Propeller pin is brought high ( at which time control is switched to the propeller...) the drawing needs some work. I'm using common grounds and the prop to sabertooth
    connection is not shown:)

    Any comments would be welcome.



    Rich
    540 x 405 - 25K
  • al1970al1970 Posts: 64
    edited 2013-05-07 22:58
    Hi Rich:

    Sorry to hear you gave your scope away. I have never used the parts you are using so I don't want to come off like I know about the parts you are using BUT. It not a good sign when a part dies shorted. "sloppy handling probably damaged the XBee." Unless you got neg., pos. mixed; I don't buy sloppy handling as the cause. The metal/grounded housing is fine for a board but if the spike is coming over the power wires to the XBee, it is not going to help.

    Since you don't have a scope, try this. Use a LED solder to a .1uf cap. Put this on the power line going to where the XBee was before (I assume it's not there anymore). If the LED even has a little glow when you have the motors on, you got problems.

    Also remember that you have not put the motors under load yet. Which can make matters worst.

    Al
  • rjo__rjo__ Posts: 2,114
    edited 2013-05-08 07:23
    Will try it... have to put it all back together first.

    Thanks
Sign In or Register to comment.