Shop OBEX P1 Docs P2 Docs Learn Events
Older newbe designs yacht race start countdown horn blaster, and needs Basic St — Parallax Forums

Older newbe designs yacht race start countdown horn blaster, and needs Basic St

shorpalshorpal Posts: 6
edited 2010-08-23 21:06 in BASIC Stamp
Good day all:

Attached is our attempt at an automatic sailboat race start device. A wireless
signal starts the unit which sounds a standard series of very loud horn blasts
that tell the yacht racers the count down time until the race starts.

It's a simple Basic Stamp 1 circuit and very simple program. However, it does not always finish
the program correctly. Sometimes it hangs and doesn't finish the timing sequence. Sometimes it runs fine.

Attached is the program, and also a diagram of the electrical hookup. I know the program is
crude and probably stupid, and would very much appreciate any professional suggestions to make
it reliable!

Notes:
There is a choice of 2 race start sequences, selected by toggle switch on pin 4.
The circuit runs on a 5v regulator from a 12v battery.
The horn draws 30amps 12v, so it is operated by a 12v relay which is activated by a reed relay from the Stamp on pin 1.
The wireless remote start device is a 12v off the shelf receiver that gets activated by a wireless key fob.
It gets turned on via a reed relay on pin 3. After it receives a key fob signal to begin the race count down,
it provides a high signal to pin 2 to start the count down, and the program cycles the power to the receiver
so it's output is in the off state ready for another race signal.

Thank you so much

Comments

  • sumdawgysumdawgy Posts: 167
    edited 2010-06-12 23:00
    At first glance,
    you need a clamping diode on the relay.
    When the relay disengages it creates a bit of reverse voltage that disrupts the bs1..randomly.

    I just had the same issuses with my own BS1 project (here)·..I knew I needed the clamp but I managed to forget to make the final connection to the diode.· Couldn't get it act reliably either·untill I realized my mistake.

    your·schematic is a bit...uh....····Well, after I get a bit more into it, I'll post a corrected version.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Before you criticize someone, walk a mile in his shoes. That way if he gets angry, he'll be a mile away and barefoot. - unknown

    Post Edited (sumdawgy) : 6/12/2010 11:23:18 PM GMT
  • sumdawgysumdawgy Posts: 167
    edited 2010-06-12 23:18
    Installing a diode across the relay input terminals should solve your issues.

    But there's a few items undocumented on yer schematic..(these MIGHT be the reed relays?)· they also should have clamping diodes.

    Reed relays generate less of a pulse than the primary·12vhorn relay.· But looking at your program you seem to fire more than one of them at a time sometimes...increasing the interference they provide.

    Your program also could use a bit of "for next"ing.· 2 reasons. 1)easier to read. & 2)saves space for other operations/functions.

    ·(I just read (as opposed to skimming) your intro.· RE:the reed relays. My apologies.)

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Before you criticize someone, walk a mile in his shoes. That way if he gets angry, he'll be a mile away and barefoot. - unknown

    Post Edited (sumdawgy) : 6/12/2010 11:29:24 PM GMT
    123 x 95 - 9K
  • shorpalshorpal Posts: 6
    edited 2010-06-12 23:40
    I am so excited to get help with this, thank you!

    The items wired to pins 1, 2 and 3 are reed relays. I understand you are suggesting clamping diodes on the big horn relay as well as the small reed relays? Can I use little
    signal diodes or would you recommend something larger?

    Your observation of the problem seems to make sense to me and would explain the randomness of the issue. Does the code seem like it would be OK and reliable to you?
    I know the code and wiring (and diagram) are a bit childish.......

    Thanks again
  • sumdawgysumdawgy Posts: 167
    edited 2010-06-12 23:52
    shorpal said...
    I am so excited to get help with this, thank you!

    The items wired to pins 1, 2 and 3 are reed relays. I understand you are suggesting clamping diodes on the big horn relay as well as the small reed relays? Can I use little
    signal diodes or would you recommend something larger?

    Don't worry about it...that's kinda the point to the forum tongue.gif

    Yes I would clamp all the relays.· Technically, the 12v relay should be isolated by the regulator (you indicated this with R?)· But I wouldn't count on it. Especially since there's no CAP installed on the output of the Regulator.· & yes I suggest a good sized one just to avoid a power fluctuation that could reset/stop your stamp.

    If you use the 12v source for something else, it's possible this could happen.

    as to the diodes regular 1N4004, 1N4005 or 1N4007 are fine.· They trigger at just over .2v and short the rest of the reverse voltage·back into the relay.· Just watch yer polarity!

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Before you criticize someone, walk a mile in his shoes. That way if he gets angry, he'll be a mile away and barefoot. - unknown

    Post Edited (sumdawgy) : 6/13/2010 12:01:16 AM GMT
  • shorpalshorpal Posts: 6
    edited 2010-06-13 03:20
    Fantastic. I will try this out early next week and report back.

    You are very kind with your advice.
  • sumdawgysumdawgy Posts: 167
    edited 2010-06-13 03:31
    my pleasure.. I just finished editing a schematic that helps me clearly understand your circuit.

    I added the diodes & added 2 power filter circuits using caps & 2 diodes.

    The 5v stamp diode can be a standard diode.
    but the 12v one MUST be able to handle the current draw of the entire circuit.
    You COULD use multiple diodes in parallel to increase the current handling.

    the 12v filter circuit is a thought. If your source is a car battery (I'm guessing.) then you most likely won't need to worry a but it so much. But the 5v one needs a cap, as the regulator DOES adj voltage based on input so easy for a momentary lag to drop below 4.7. It could cause the stamp to go into brownout mode and reset/freeze. (Usually reset.)


    updated schematic posted at the end of this topic.....one that fully shows....

    Before you criticize someone, walk a mile in his shoes. That way if he gets angry, he'll be a mile away and barefoot. - unknown
    805 x 953 - 141K
  • shorpalshorpal Posts: 6
    edited 2010-06-13 15:04
    Your diagram is a thing of beauty!

    The power supply is a 30AH 12v sealed wet cell battery. It is contained in a plastic carry box along with the circuitry. The duel horns mount on top of the box making the whole thing portable. It is left on a skiff that makes up one end of the starting line for the race. One of the racers sails by and wireless activates the unit to start up the honking to lead up to the start.

    What are you recommending for the C1,2,3 caps? Were you indicating that little diodes like 1N914 / 1N4148 would be OK for the 5V relays or should I use the larger ones. I only ask because I have some of the smaller on hand.

    Thanks again for you thoughts and time, I think this is finally going to come together. Last summer it was a bust.....
  • sumdawgysumdawgy Posts: 167
    edited 2010-06-14 01:05
    shorpal said...
    Your diagram is a thing of beauty!

    You flatter me.· It was my second attempt at using express PCB for a cicuit layout.. As opposed to hand drawing.· Which I also prefer.· Tho I'm beging to find express PCB more handy.
    shorpal said...
    The power supply is a 30AH 12v sealed wet cell battery. It is contained in a plastic carry box along with the circuitry. The duel horns mount on top of the box making the whole thing portable. It is left on a skiff that makes up one end of the starting line for the race. One of the racers sails by and wireless activates the unit to start up the honking to lead up to the start.
    Then forget the 12v filter circuit.· Unless, you all decide to add other devices to the skiff later.· All you'll need is the 5v circuit. (and the diodes)
    shorpal said...

    What are you recommending for the C1,2,3 caps? Were you indicating that little diodes like 1N914 / 1N4148 would be OK for the 5V relays or should I use the larger ones. I only ask because I have some of the smaller on hand.

    2200uf· for c1 & c2 should do well.· Half that will also work.· Altho, I prefer a bit of paranoia myself.· Also, bear in mind for the future, that the capacity of the Caps degrade over time.
    The smaller diodes will be fine for the reed relays. All you want to do is dump a a small (BUT ANNOYING) bit of waste energy.· They SHOULD work for the larger relay too but, if you want to be sure, just use 2 in paralell with the relay to increase the current handling. (I have no idea of it's size or potential for energy generation.· You could O-Scope it in operation to get an idea of the Volts of the discharge spike. If you have acess to one.)
    shorpal said...
    ·Last summer it was a bust.....
    If that thing ended up running anywhere as confused as I'm imagining....· You have my sympathies.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Before you criticize someone, walk a mile in his shoes. That way if he gets angry, he'll be a mile away and barefoot. - unknown
  • shorpalshorpal Posts: 6
    edited 2010-06-14 01:15
    Thanks, I'll report back.
  • shorpalshorpal Posts: 6
    edited 2010-06-20 23:14
    Hi:

    This has worked out very well! We got it running Friday and tested it a bunch of times and it seems completely reliable. I thank you very much for your time and brain power.

    The wireless unit we use seems a good choice and has a range of hundreds of feet:
    http://www.sailorssolutions.com/index.asp?page=ProductDetails&Item=WRS01

    Thanks again.
  • sumdawgysumdawgy Posts: 167
    edited 2010-06-21 03:15
    Glad to hear it! It was <corn-on my honor to serve you <corn-off.

    But seriously, when you guys DO run the races.... I'd love to see a vid of a sucessfull race start!

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Before you criticize someone, walk a mile in his shoes. That way if he gets angry, he'll be a mile away and barefoot. - unknown
  • sumdawgysumdawgy Posts: 167
    edited 2010-08-23 21:06
    sumdawgy wrote: »

    updated schematic posted .....one that fully shows....

    Before you criticize someone, walk a mile in his shoes. That way if he gets angry, he'll be a mile away and barefoot. - unknown

    Somone pointed out that the old one wasn't fully visible.
    676 x 800 - 71K
Sign In or Register to comment.