Shop OBEX P1 Docs P2 Docs Learn Events
Two way radio output to a BS2 — Parallax Forums

Two way radio output to a BS2

Nick WaldvogelNick Waldvogel Posts: 71
edited 2008-10-26 02:46 in BASIC Stamp
I have a two way radio that I want to hook up the output of the headphones to a BS2.· I tested with a multi meter and found that I get a 2.1 volt output when the radio is receiving a signal.· I tried to input the headphone input to the BS2 directly but I couldn’t get a high reading on the stamp.· I then tried a few different ways to try and get the voltage up.· One of the circuits was the use of a 339 IC form the pages of the microcontroller cookbook.· I can’t tell you what exact page is because the book is in my desk at work.· Maybe I’m looking at it all wrong and maybe I can’t just read it as a high or low?· If I had a scope it might explain a lot.· Until then I hope that maybe you guys can shed some light on this for me.
Thanks for all your help.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔

Comments

  • FranklinFranklin Posts: 4,747
    edited 2008-10-12 00:16
    If you are trying to read audio the signal is constantly changing from 0 to whatever the high reading is and it would depend on exactly you were reading the port. A voltmeter will not give you an acurate reading of the limits the voltage is swinging so be careful connecting things to the stamp without protection.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - Stephen
  • ercoerco Posts: 20,256
    edited 2008-10-12 00:49
    Kind of the long way around, but your question takes me back to my (much) earlier and (more) innocent ham radio days. Long ago, I made a poor man's·autokeyer by recording audio·tones on a cassette tape to trigger a morse code keyer for my CW transmitter to repeat CQs and my station ID.

    I rectified the audio (AC signal) through a 4-diode bridge rectifier and used a filter cap to smooth the resulting pulsating DC into something that would drive a relay. Volume adjustment was my level control.

    You can try this on your radio's headphone output with 4 diodes (germanium or schottky silicon diodes will have less loss than standard silicon diodes) and an electrolytic·cap, like 100-1000 uF. For direct input to an input pin, your·"on"·signal needs to be above the Stamp's high threshold of ~1.4 volts.

    Be careful if you're 'sperimenting. Might be safer to use a reed relay or optoisolator between your radio & Stamp.
    Best,

    erco

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·"If you build it, they will come."
  • NR1XNR1X Posts: 111
    edited 2008-10-12 01:56
    not too sure what your application is but a good way to control a stamp via 2 way radio is dtmf (touchtones) i have used dtmf succesfuly for many applications..
  • ercoerco Posts: 20,256
    edited 2008-10-13 02:01
    kb1nrb (go ham radio) has a great point. LM567 tone decoders are easy to use. You can trigger several different things with single or dual audio tones. You could send almost any kind of audio tone over your radio. If you want, just whistle.

    You know how to whistle, don't you?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·"If you build it, they will come."
  • NR1XNR1X Posts: 111
    edited 2008-10-13 19:04
    I have had alot of fun with cm8870 or cm8880, the only draw back is that it uses 5 inputs.. i have used it to decode and send dtmf tones.. although the 8880 would be kind of a waste because the stamp itself can generate dtmf tones.. pretty wild that you can control many devices from half a world away with a stamp and a dtmf decoder and a fist full of relays.. imagine a remote car starter you could trigger from 100+ miles away!! plus alot of great pranks..
  • Ken GraceyKen Gracey Posts: 7,389
    edited 2008-10-13 19:23
    Chris Savage and I have an application we should be ready to post pretty soon. It uses two HT radios to send/receive wireless data, coupled with modems.

    Give us one week, maximum!

    Ken Gracey
  • NR1XNR1X Posts: 111
    edited 2008-10-13 22:22
    i use afsk modems to send and recive data every day!! i live in connecticut and can easily connect to a bbs in florida!!! also send email via radio to special stations that send and receive the emails to and from internet servers.. had a thread going in the sandbox trying to interface my radio modem to a bs2 but never was able to get data tha i could understand to debug, so its kinna a dead end for now
  • Nick WaldvogelNick Waldvogel Posts: 71
    edited 2008-10-14 22:47
    If there are no number keys on the radio how can you send dtmf tones? The stamp doesn’t have to decode any data. It just needs to know that the radio is sending out sound through the headphone jack. I will try the diodes that where suggested tonight.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
  • NR1XNR1X Posts: 111
    edited 2008-10-18 00:19
    Ken Gracey said...
    Chris Savage and I have an application we should be ready to post pretty soon. It uses two HT radios to send/receive wireless data, coupled with modems.

    Give us one week, maximum!

    Ken Gracey
    I gotta see this Ken.. Im still on the edge of my seat!!
  • Ken GraceyKen Gracey Posts: 7,389
    edited 2008-10-18 00:37
    kb1nrb,

    You won't have to wait long - I'll be able to post it this weekend.

    This is really an example of using a BS2 with a mini radio modem and HTs. It's very basic, but what we've done that is unique is produced a simple source code demo that can be adapted for all kinds of uses. And we shook out any problems with the radio modems so our customers needn't hassle with it.

    For me, it's a cool application! For seasoned programmers and HAMs, it's probably no big deal. I think I'll use it to control my robots.

    Ken Gracey KI6HBT
  • NR1XNR1X Posts: 111
    edited 2008-10-18 12:54
    Cool, I really just hope to use it as an example for interfacing with a radio modem i have here.. maybe seeing what you have put together will give me one of those "ahh ha" things.. my main problem right now is getting the received data to display in a format that i can understand, not just charecters.. if you want to see more on where im stuck with this checkout my post in the sandbox titled "playing with serin".. KI6HBT 73 de KB1NRB

    ps. You should upgrade your licence.. got my general in march, it was a piece of cake.. would be child play for you..

    Post Edited (kb1nrb) : 10/18/2008 1:00:12 PM GMT
  • ercoerco Posts: 20,256
    edited 2008-10-20 01:35
    KI6HBT & KB1NRB de
    _._
    _ _
    _....
    _..
    ...· (had to edit this, as my spaces·got deleted)

    Don't stop until you've reached your EXTRA class license. Piece of cake now that they dropped the code requirement that used to distinguish hams from the rest. No 20 WPM is enough to make me a bitter _ _
    _ _ _ at 48!

    _ _ ...
    ... _ _

    _._
    _ _
    _....
    _..
    ...

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·"If you build it, they will come."

    Post Edited (erco) : 10/20/2008 1:40:44 AM GMT
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2008-10-20 02:31
    erco,

    You can insert spaces that don't get deleted by using the string   (HTML non-breaking space). I typcically type it just once and copy it to the clipboard, then paste wherever I need it.

    -Phil

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    'Still some PropSTICK Kit bare PCBs left!
  • NR1XNR1X Posts: 111
    edited 2008-10-20 04:29
    erco , way to go with the code!! im on the other end of the spectrum on the cw drop... i couldnt get past 5 wpm.... even that is pretty tough 4 me.. thank goodness for all the digital aids availible for us cw illiterate hams!! i do think code should be required to go beyond general class, but i also know for sure that tech wasnt enough and i probably wouldn't be as active as i am today if i didnt upgrade.. i hope that this doesn't give you a bad opinion of me.. to stay on topic , maybe i should build a cw machine around the basic stamp.. KM6DS 73 de KB1NRB
  • Carl HayesCarl Hayes Posts: 841
    edited 2008-10-26 02:46
    Somewhere in the radio's receiver, if it has a squelch feature, is a place where the voltage is a different value when receiving from when it isn't receiving. Find this point (on REAL radios it's on an accessory jack) and use it as an input to the Stamp. You may need some kind of level translator to change it to 5v/0v from whatever it is. In many transceivers, this is available not only at the rear panel but also in the mike connector on the front.

    If it DOESN'T have squelch, it ain't much of a radio. Throw it away, or donate it to Goodwill.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    · -- Carl
Sign In or Register to comment.