Connecting a cell phone / iPhone with Basic Stamp Homework Board
hameem
Posts: 5
How do i connect a cell phone or an iPohne with basic stamp?
My idea is to use the sensors of the cell phone (camera or bluetooth) to send instructions to the microcontroller.
Please help me with ideas.
Thank you.
My idea is to use the sensors of the cell phone (camera or bluetooth) to send instructions to the microcontroller.
Please help me with ideas.
Thank you.
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen
I seriously doubt you phone will send anything useful over USB unless it were programmed (hacked) to do so.
The only way I can think of is two phones, one on the receiving end, and send DTMF. You'd initiate the call, have the receiver set to auto-answer, and send DTMF tones with the keypad of the transmitter.
If your working locally 100ft or so away, there are better ways to do this. Infrared should work line of sight to about 30ft max. RF should work to ????? 200ft or maybe farther? Parallax sells RF Tx / Rx modules.
After I read your question again... I dunno if that information is valid..... Most (all?) phones have a USB communication port. It's still up to the phone's software what goes across the port though. I'd suggest reading hack sites on the web.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"puff"...... Smile, there went another one.
Post Edited (Spiral_72) : 4/9/2010 3:12:06 PM GMT
For example, the iPhone can connect via the Internet and you can even get an "off the shelf" free program ("Mocha Telnet Lite") to do all the work on the iPhone, but you need a Telnet to serial interface on the Stamp side (www.netmedia.com/siteplayer/telnet/spt1.html) and you'll need to figure out how to use it.
Other cell phones may be easier to use, may allow Bluetooth serial connections that you could use with a Bluetooth to serial interface like that sold by Parallax, and may come with "off the shelf" software or you may need to get the manufacturer's SDK and write it yourself.
Most cell phones have some kind of serial connection available, but you'd have to hunt up the documentation on it and you'd have to write your own program to manage it including a terminal program.
As Spiral_72 mentioned, you should be able to find "hack" sites on the web that would have more information specific to a particular phone, but you're on your own.
Regarding using a cell phone on both ends and using DTMF for signalling ... You'd have to write your own software for the phone on the Stamp side. Without a specific program on the phone, the DTMF is used only to make beeps on the speaker.
Post Edited (Mike Green) : 4/9/2010 3:31:36 PM GMT
For the moment lets forget about the sensors. If I wanted just two cell phones on both ends, just like the Spiral_72 said, and I wanted to send DTMF from the sender cell to the receiver cell so that it could give the microcontroller some kind of instructions, would I have to program the receiver cell? Or the DTMF signals received would go through the serial port automatically and give the microcontroller some meaningful signals?
You could build a microphone / amplifier / DTMF decoder that literally listens to the cell phone's speaker and produces signals for the microcontroller, but you'd have to also make something that would detect the ring tone and get the cell phone to answer the call.
Jonathan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
Yea, THAT'S what I had in mind. I THINK it would be pretty simple actually. And you might be able to skip the microphone and amplifier by plugging right into the headset port with something for impedance matching. There are DTMF decoders IC's available for cheap. I Thought Parallax had one... but I don't see it.
For answering the call, your phone may (will?) have an auto-answer setting.... Mine does. Some phones require a hands free device to be plugged in before auto answer works.....
So theoretically, you'd call the receiver phone, it rings twice or whatever, auto-answers..... then you push numbers on the cell. The receiver get's these though the call and plays the button pushes as DTMF tones through the headset port where your BS is connected. The BS listens for the signals from the DTMF decoder and does some function according to the tones sent.
It's a remote control with a range of at least 24,901 miles! [noparse]:o[/noparse])
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"puff"...... Smile, there went another one.
Jonathan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info - Home of the Hydrogen Fuel Cell Robot