Hacking a cell phone for use with a stamp 2p40
Hi Guys
I'm building an alarm system using an Stamp BS2p40 and a old Nokia 3310 cell phone. The idea is that the unit will SMS another phone (or phones) as each alarm is triggered. ·It will consist of 2 PIR alarms, hall effect switches on the front and back door and a laser beam perimeter alarm (no rocket science there). The Stamp will send a text message giving alarm information then log the event to the 2p40’s memory. I may add a 1307 clock later (I have several but I don’t have the crystals). I have the choice of using either the intelligence in the Stamp or in the cell phone so I have decided to go Fat-Server Thin-Client. The cell phone will just be a text messaging device and the stamp will enter the text message by switching the cell phone keypad. Even the number to be dialled will come from the stamp.
The keyboard switching is slow, probably slower than 200uS and to enter an “S” for example would need 4 ·pulses on the “7” key (-P-Q-R-S).· Ideal for a DATA table giving the two multiplex ports and the number of pulses.
I need some help with hacking the cell phone keyboard. There are 17 buttons on the 3310 and they are multiplexed into 4 of 5.
What is the best hardware to switch this? What is the most appropriate device number?
Can I use just ·9 Transistors or Fets to switch the busses rather than individual buttons because even with 32 I/O, I can’t accommodate 17 buttons?
Attached are some sketches to clarify (or confuse)…
·
Regards from the Dark Continent
John Bond
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Post Edited (John Bond) : 8/28/2008 11:08:16 AM GMT
I'm building an alarm system using an Stamp BS2p40 and a old Nokia 3310 cell phone. The idea is that the unit will SMS another phone (or phones) as each alarm is triggered. ·It will consist of 2 PIR alarms, hall effect switches on the front and back door and a laser beam perimeter alarm (no rocket science there). The Stamp will send a text message giving alarm information then log the event to the 2p40’s memory. I may add a 1307 clock later (I have several but I don’t have the crystals). I have the choice of using either the intelligence in the Stamp or in the cell phone so I have decided to go Fat-Server Thin-Client. The cell phone will just be a text messaging device and the stamp will enter the text message by switching the cell phone keypad. Even the number to be dialled will come from the stamp.
The keyboard switching is slow, probably slower than 200uS and to enter an “S” for example would need 4 ·pulses on the “7” key (-P-Q-R-S).· Ideal for a DATA table giving the two multiplex ports and the number of pulses.
I need some help with hacking the cell phone keyboard. There are 17 buttons on the 3310 and they are multiplexed into 4 of 5.
What is the best hardware to switch this? What is the most appropriate device number?
Can I use just ·9 Transistors or Fets to switch the busses rather than individual buttons because even with 32 I/O, I can’t accommodate 17 buttons?
Attached are some sketches to clarify (or confuse)…
·
Regards from the Dark Continent
John Bond
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Post Edited (John Bond) : 8/28/2008 11:08:16 AM GMT
Comments
I would be interested in your project.
I'm playing with an alarm system for my boat. I've got a text to voice module with the appropriate alarm states programmed as DATA statements. When an alarm is detected, a servo mechanically pushes the "last number redial" on the cell phone. After a few seconds, the stamp triggers the text-to-voice and hopefully the listener will know who's calling! With proper delays, the home answering machine should pickup so I won't miss the alarm condition if I'm not home.
For your keypad hack, one alternative to fets or transistors are reed relays. They give a definite switching action and you don't have to worry about polarity, bias voltages, etc. I've have some that are small enough that the Stamp can drive them without a transistor.
Keep us informed of your progress.
Cheers,
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Tom Sisk
http://www.siskconsult.com
·
I hadn't thought of reed relays. Polarity and biased voltage were my concerns when considering transistors hence the question about FETS. I've just checked the electronic component supplier in Durban and they have some 5v relays but they don't know the coil resistance or power consumption. If the relays need more than 20ma, I'll just drive them through a ULN2803 (which cost just US$0.80 each, that's small change, even for us in the 3rd world! Even the read relays are cheap, just US$1.10 each).
This is a quick project to fill the gap while I'm waiting for components for other things. Using relays simplifies it a quite a bit.
Kind regards on this hot and dry winters day - 38 DegC or 93 DegF, quite different from the 20 DegC or 64 DegF Yesterday
John Bond
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
http://web.archive.org/web/20000302144234/www.qsl.net/ka2pyj/article1.htm
This is a link to the internet archives, and I believe I have the schematic for the serial circuit.
This project used a analog crosspoint switch to mimic the presses of a keypad on a scanner.· The software and hardware basically inputed freq's, settings, etc. into the scanner memory by duplicating the key presses one would make to program the scanner.
The crosspoint switch comes in different flavors, but I see they're sold here:
http://www.futurlec.com/ICSFZarlink.shtml
the MT8804A 8x4 Analog Switch Array IC would be an example
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Bad spellers of the world untie!
Post Edited (mojorizing) : 8/29/2008 3:54:19 AM GMT
Better yet, do you have any PC's that run 24x7? It would be simpler to write some software to run in the background and respond to serial or other data input, and fire off a SMS over the internet. Plus it would save you $40 a month in cell phone fees.
What are you doing for the perimiter laser? Im building the same, but I couldnt fine a IR laser reasonably priced to save my life, and I ended up building my own mirror and laser mount assemblies.
http://forums.parallax.com/forums/default.aspx?f=25&m=287339
Cheers!
@ Mojorizing
That's a good option, building on it, I could use one of those multiplexed bi-directional analogue switch ICs. Thanks.
@ GICUB12
Thanks for your suggestion; I had thought of that but the situation here in South Africa is a little different.
My old fashioned phone, if I chose to have a land-line phone, is 4 miles of copper running parallel to very noisy power lines. Voice is difficult, internet and data is impossible. The Telecoms company is state owned (to enable them to monitor and control the masses) so there is little motivation to provide service or upgrade. In addition, the cost of line US$12.30, plus the cost of Internet Provider US$28.00 might seem the same as your US costs but we earn about a third of your US salaries.
Thank God for digital, GPRS, cell phone and satellite. South Africa has always been leaders in Cell Phone and Satellite, particularly using the US satelites (even your military ones :-O ). Strangely enough, even though I live way out in the veldt, far from civilisation, I get first class GPRS and 3G at very high data rates. Unfortunately, while these services are cheap by US standards, they’re still a bit pricy for an alarm system.
I chose SMS messaging for the following reasons. A pre-paid cell phone contract for 6 months costs USCents-12.5 (yes, a bit more than a nickel). A pack of 100 pre-paid SMS text messages costs US$2.50 - discount available on larger quantities. In addition, because the network in this area is very lightly loaded (no ATMs, shops or banks) text messages are instantaneous. The alarm will send a text message each morning confirming it is working or 30 SMSs a month so this service should cost less than a US$1.00 a month. Even in South Africa, that is very inexpensive…
@ Paul
Thanks! - Jay is doing some interesting stuff, much more powerful than my project. It’s useful to see how others handle it. I have seen component phones locally at US$35 and they support Hayes Modem commands. The component phone Jay is using is VERY inexpensive!!!
John Bond
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
·I had thought about pre paid as well, but either it costs so many minutes per month, or the minutes expire every 90 days. Thats whats keeping me from doing something simular
There is one pre paid plan that when you get a $100 card the minutes are good for one year
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
··Thanks for any·
·
·
·
·
Sam
http://www.maplin.co.uk/Module.aspx?ModuleNo=99114&criteria=personal%20tracking&doy=30m8
I tried both reed relays and 74HC4066 analog switches. Both work. The keyboard switches even with a high contact resistance. I tried 1K Ohms with no problems so two analog switches per key or 60 ohms isn't an issue. I decided three ICs would be easier than nine relays. Unfortunately, I could not hack the cell phone and retain its keyboard but the job really came out neat.
It is amazing watching the cell phone dial the number sent by the Stamp. The hardware was a lot easier than I expected. I still have a lot to do on the other I/O before I start the programming but I am really looking forward to it.
Project cost for a Home Alarm System that Text Messages will be US$ 200.00:-
1 X BS2-40 with some blown pins (therefore useless except for this project) US$ 89.00
1 X old Nokia 3310 2nd hand value in South Africa US$ 14.00
Various new Components US$ 20.00
Various components out my component store – say US$ 10.00
2 X PIR detectors US$ 32.00
1 X plastic box not yet purchased US$ 8.00
Wiring the house US$ 20.00
SIM Card plus 100 message pack US$ 4.00
My actual outlay in cash has been just US$ 60.00 with another US$ 8.00 for the box later.
Additional (unexpected) features include:-
- My housekeeper can use the device as a phone to call pre-programmed numbers such as the police, ambulance, the neighbour, her daughter or me.
- It will keep a record of all occurrences that trigger the alarm and when the cell phone is used.
Not bad for quite a simple project!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔