Shop OBEX P1 Docs P2 Docs Learn Events
BSX-II Resetting — Parallax Forums

BSX-II Resetting

RancheroManRancheroMan Posts: 14
edited 2006-08-17 20:16 in BASIC Stamp
I seem to be experiencing a small problem with my Stamp in that it is periodically resetting for reasons unknown to me. I have since changed my program so that a reset does not return any unwanted data, however I am still trying to figure out why it is resetting.

I am powering the Stamp off a computer power supply (the entire project including a PINK and some LED’s and relays are all deployed in a computer case – sans computer!) and I have tested the output voltage – which is fine.

Any thought?

Thanks

Adam

Comments

  • Beau SchwabeBeau Schwabe Posts: 6,559
    edited 2006-08-16 22:20
    Do you have any reverse biased diodes on your relays, and also on the transistor(s) energizing the relays?

    Check out the link below. It references a MOTOR, but it could just as easily be a relay....
    Don't get HOT choosing the wrong transistor

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • RancheroManRancheroMan Posts: 14
    edited 2006-08-16 22:58
    The stamp is not driving the relays at all, only looking at the swtiched output of them (+5V or Gnd). The Relays are being use to isolate the stamp from the system that is being monitored.

    Thanks
  • allanlane5allanlane5 Posts: 3,815
    edited 2006-08-17 00:26
    Are you perhaps putting +5 on 'Vin'? Because if you're driving it with +5, you need to send it to Vdd.

    If you're driving it with +12, then a PC supply usually needs some load (a load resistor of 220 ohms should do) on the +5, before the +- 12 volt lines are good. Have you checked the voltages with a voltmeter?
  • Beau SchwabeBeau Schwabe Posts: 6,559
    edited 2006-08-17 00:41
    If the relays are on the same power supply as the Stamp, it doesn't matter if the Stamp is not driving the relays or not, the relays should still have reverse biased diodes across their coils.

    That aside, you mentioned that you are using a computer power supply. Is it also powering the computer?, and if not are you supplying an adequate load for the power supply?

    Another thought... how long is the programming cable to the Stamp? Noise on the power line is capable of resetting the Stamp. This can be caused from Motors, Relays, Noisy power supply.
    I know this from building an industrial application some years ago where I was able to re-program the stamp at a remote location some 100ft away. Because of the long programming cable,
    the system was susceptible to noise from the machinery. One method that I used to help "dampen" this problem was to place a 1K resistor across pins 3&4 on the BS2. This made it harder
    for the Stamp to reset, and allowed it to still be programmed. In this mode you will need to make a direct connection and bypass the .1uF caps so that the DTR line goes directly to the ATN line.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • RancheroManRancheroMan Posts: 14
    edited 2006-08-17 15:13
    The "computer" is not computing, however it is powering the motherboard as we are using some modified boards that plug into the MB for power (The relay board plugs into the MB and that is how it is receiving power).

    We are not using the +12 volt line on the power supply to run the stamp and when checked, the +5V is solid.

    The programing cable is ~30 feet long. I will disconnect it from the stamp and see if that stops the resetting problem. The stamp is simple to get to so unplugging/plugging the cable won't be an issue.

    Thanks for all your help guys!
  • allanlane5allanlane5 Posts: 3,815
    edited 2006-08-17 15:41
    Good. Is that +5 tied to "Vin" (which MUST be 5.5 or above) or "Vdd" which MUST be 5 volts, +- .05 volts.

    And you DO have the ground wire tied to "Vss", right?
  • RancheroManRancheroMan Posts: 14
    edited 2006-08-17 18:02
    Allan,

    http://www.hvwtech.com/products_view.asp?CatID=90&SubCatID=93&SubSubCatID=138&ProductID=43

    I am using a Stamp Stack that has an on-board regulator. I guess the short answer to your question is I don't know. I've got +5V going the +5V pin and Gnd going to the Gnd pin.

    I will try to verify which pin Vin or Vdd is being used.

    Regards,

    Adam
  • allanlane5allanlane5 Posts: 3,815
    edited 2006-08-17 18:38
    Hmm. Having looked at the docs, it doesn't look like the "Stamp-Stack" gives you access to "Vdd" (aka +5 volts regulated). The "StampStack" expects you to give it +5 volts on "Vin". If you installed the capacitor backwards, you MIGHT get this effect -- basically, it looks like your SX chip is 'browning out' from too low a voltage.

    It's possible switching noise on the 5-volt line is causing this -- a 4.7 uF capacitor should filter this, though.
  • HVWTechHVWTech Posts: 6
    edited 2006-08-17 18:55
    Adam,

    For support on an HVWTech product, you should contact support@HVWTech.com !

    To save you some time however and since spontaneous resets are a problem encountered by many people, we can deal with this here.

    First, the recommended input voltage is 6 Volts. This is because there is some drop associated with the 5-volt regulator (i.e it takes more than 5 volts to provide a regulated 5 volts). In this case though, this is only a minor contributor.

    You say you are using a computer power supply. These supplies are designed to be cheap and are intended to be connected to a PC motherboard which has extensive filtering. You also mention using inductive devices (i.e. relays) which, when activated, will cause short 'dips' in voltage on the supply's +5 line. If you arent' using 'snubber' diodes across your relays, that only makes things worse. If you have an oscilloscope, looking at the +5 volt line will show all kinds of 'noise' from the PC supply and activating relays.

    To solve your problem, we would recommend that you don't use PC power supplies -they are good for PCs but can cause grief for other uses unless you know exactly what you are doing. Assuming you need to keep the supply in this case, then try putting as large a capacitor as is practically possible (or several in parallel), say at least 1000 uF @16V, across Vin and ground, as close to the Stamp Stack as possible. Also (and this is always a good idea, regardless of what voltage relays you use) put 'snubber' diodes across your relay pins (a reverse biased 1N4001 or similar) to help keep the relays from injecting noise to the power supply.

    Since you only get the occasional reset, this should solve your problem. For more in-depth help on this, feel free to contact our support staff directly at support@HVWTech.com

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Mark
    HVW Technologies Inc.
    http://www.HVWTech.com
    Parallax Distributor
  • RancheroManRancheroMan Posts: 14
    edited 2006-08-17 19:46
    Thanks everyone for all your help!

    My guess is that the PC power supply is the cause of this problem after reading all the suggestions. I will install a large capacitor next time we have the equipment apart to add functionality.

    Regards,

    Adam

    P.S> Come to think of it, I had a similar problem with a StampStack I use at home. I have since switched to different power supply (not out of a PC) and I can't remember the problem still occuring. Hmmm...

    P.P.S> "intended to be connected to a PC motherboard which has extensive filtering"
    if I found a place on the motherboard with this filtered 5V, could I use that to power the stamp?
  • HVWTechHVWTech Posts: 6
    edited 2006-08-17 20:08
    "P.P.S> "intended to be connected to a PC motherboard which has extensive filtering"
    if I found a place on the motherboard with this filtered 5V, could I use that to power the stamp?"

    In principal, sure; but why not just connect it to the PC supply's 12V line ? The on-board regulator can handle it, although it may get quite warm if you are drawing lots of current from the Stamp I/O pins...

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Mark
    HVW Technologies Inc.
    http://www.HVWTech.com
    Parallax Distributor
  • RancheroManRancheroMan Posts: 14
    edited 2006-08-17 20:16
    Deal!

    I think that may be the best way to go.

    Thanks,

    Adam
Sign In or Register to comment.