GSM cell phone with PIC?

For Adafruit customers who seek help with microcontrollers

Moderators: adafruit_support_bill, adafruit

GSM cell phone with PIC?

Postby bobfixesstuff » Sun Nov 20, 2011 7:06 pm

I'm a little new to PICs but what I'd like to delve into is the integration of cellular phones and some sort of automated control.

The smoke detector that phones you?

The burglar alarm that phones you? Basic motion detector?

Fire risk in particular is (at least in the UK) almost always addressed with independently powered smoke detectors; 'cause fire could be caused by or cause mains electricity KABOOM!

Cell phones preeeeeeeety much guaranteed to last long enough to make a phone call or two before battery fails or fire consumes. Or before burglar discovers.

It all comes down to the reliability of LiPoly cells.

All that is a sidenote to what I wanted to seek wisdom on: what's the best way to approach automated control of a cellphone? With a microcontroller?

Something with sensory inputs and the ability to close switches like a relay or outputs.

Are there any PICs which can be programmed so simplistically?

To make a cell phone perform a "program" requires only about 13 distinct buttons to be "pressed". (You press numerical digits, and menu navigation buttons). Can a PIC be programmed to do that sort of thing? To "push" buttons (close circuits) in a timely fashion, and follow a program list of button pushes?

My first project is to make a GSM alarm system which alerts me when there is a blackout. (So I can rush home and save work before my uninterruptible power supply runs out of power!
bobfixesstuff
 
Posts: 48
Joined: Fri Jun 17, 2011 7:54 am

Re: GSM cell phone with PIC?

Postby cstratton » Sun Nov 20, 2011 8:12 pm

There have been phones, some of them even on prepaid plans, which had serial ports in their headset jack that would accept AT-type commands derived from extending the old modem command sets. At a minimum, these could send an SMS message under control of an external micro-controller.

There are non-phone GSM modules sold for precisely this type of purpose and accepting AT commands - they tend to cost more than a cheap phone, but are better set up for interfacing.

Lastly, there are smart phones which may be able to place calls or at least send SMS autonomously. Capabilities vary a bit from platform to platform, and depending on if the device is running consumer software or if it has been "rooted". Famously, android phones in general cannot play generated sound into a phone call, even if they are rooted. Most android phones can work with an external USB host board (ioio, adk, arduino host shield, etc) to interface real-world sensors. Some can be modified (generally by undocumented means) to be USB hosts themselves and talk to simpler/cheaper usb-device external microcontrollers which might be connected to sensors.
User avatar
cstratton
 
Posts: 246
Joined: Wed Sep 29, 2010 2:52 pm

Re: GSM cell phone with PIC?

Postby bobfixesstuff » Mon Nov 21, 2011 5:06 am

cheers dude! good advice!

I remember I looked into GSM modules before, and ended up thinking "hold on a second.... I'm building a cellphone now".

But the way you describe using a module combined with a microcontroller to perform basic routines; that's pretty much what I am aiming for. Sending SMS would be a really nice abstraction of the initial idea.

One module could therefore deliver different reports from multiple sensors.

But the core ambition here is to find a practical use for old / broken cell phones, of which there are many many many! If this means having to hard wire to the button pads then so be it... but is there a typical microcontroller which could store routines, and in a timely fashion close different circuits?

I can already envisage the concept with AND gates sort of (for very simple functionality) and have already found a couple of microcontrollers that look suitable for the abstract project, but again, I'm new to PICs!

Can anyone think of a comparable (and simpler) project that I could look at to get some insight into the first steps to take? :)
bobfixesstuff
 
Posts: 48
Joined: Fri Jun 17, 2011 7:54 am

Re: GSM cell phone with PIC?

Postby cstratton » Mon Nov 21, 2011 12:31 pm

I think your simplest best would be to do some googling and try to identify a phone with the AT command set serial port on the headset. I think they were primarily by motorola, but it was only a project I read about / thought about, not one I actually did.

The idea of simulating button pushes on a keypad is interesting. You could try using a scope to figure out which lines of the key matrix are driven in scanning, and wire those up the the micro as inputs with a pin change interrupt. Then drive one of the remaining other set of lines low to push a button. You may have voltage level issues to contend with if your micro can't run at the same (presumably low, but who knows?) voltage as the phone's circuitry.

A more serious problem could be that the phone might not always do the same thing in response to button pushes. Sometimes on some models there are extra alerts or warnings and the like you have to acknowledge? It's possible you could find some sequence (turn the screen off, then back on again for example) that would get you to a place where a known command sequence would always work. And you may be able to detect screen (backlight) on either with a photocell or by tapping in electrically.
User avatar
cstratton
 
Posts: 246
Joined: Wed Sep 29, 2010 2:52 pm

Re: GSM cell phone with PIC?

Postby bobfixesstuff » Mon Nov 21, 2011 1:02 pm

more fantastic insights, thanks mate!

particularly good observation on "the extra alerts or warnings and the like you have to acknowledge?"

my ambition is to find a use for very old / broken cell phones. phones which already have "broken" buttons, or battery issues, or a broken screen for example. these phones tend to have keypads which are two copper circles (one inside another), easy to solder to and then to wire up to a relay or switch... or microcontroller?

with older phones (I'm thinking of simple nokia in particular), the nagivation is really simple and I think the surprise alerts and surprise warnings could be navigated around by simply starting each command routine with two presses of the "hang up" button.

this is sort of similar to the "turn screen off then back on" thing that you were talking about, which is pretty standard on modern phones and smart phones.

I reckon this project is quite doable...

check out this for example,

http://www.anthony-dacko.net/Cell-phone ... phone..htm

but this guy uses DTMF (dual tone multi-frequency) sounds (standard telephone tones) as the means of communication.

this means his projects are reliant on using old cell phones with an "auto-answer" feature.

for his alarm dialer projects he relies on old cell phones which have "fast dial" or "one touch dial" features... where you press one button to dial a pre-chosen number.

but the punchline is that such old phones, particularly nokias, are actually in some abundance. and they're cheap of course!

there are loads on ebay going cheap, so it's quite feasible to include one cell phone for each microcontroller in a given project or projects. both parts are cheap and low power lol.
bobfixesstuff
 
Posts: 48
Joined: Fri Jun 17, 2011 7:54 am


Return to Microcontrollers

Who is online

Users browsing this forum: mibignistinly and 3 guests

Stuff to buy from the Adafruit store and links to product documentation!


New Products [108]

Raspberry Pi[80]
 
FLORA[23]
 
Bunnie Studios[9]
 
FPGA[1]
 
mbed[11]
Arduino[60]
 
NETduino[14]
 
BeagleBone[24]
 
Android[6]
 
XBee[10]
More Dev Boards[31]


 
BoArduino[8]
 
SpokePOV[4]
 
TV-B-Gone[4]
 
MiniPOV[3]
 
SIM reader[3]
 
Microtouch[5]
 
Clocks & Watches[18]
 
Drawdio[4]
 
Brain Machine[1]
 
Game of Life[2]
 
MintyBoost[2]
More DIY Kits[16]


 
MaKey MaKey[3]
 
Tweet-a-Watt[5]
 
Young Engineers[33]
 
Discover Electronics[2]
 
Snap Circuits[4]
 
littleBits[3]
 
Project packs[8]


 
Breakout Boards[34]
LCDs & Displays[48]
Components & Parts[70]
Batteries & Power[49]
EL Wire/Tape/Panel[52]
LEDs[111]
 
Wireless[14]
Cables[62]
 
Lasers[6]
Sensors/Parts[145]
 
Enclosures/Cases[11]
 
Solar[11]
 
RFID / NFC[13]
Prototyping[70]
 
iDevices[13]
Tools[71]
 
Wearables[39]
 
CNC[37]
 
Robotics[29]
 
3D printing[1]
 
Materials[24]


 
Stickers[41]
 
Skill badges[55]
 
Books[25]
 
Circuit Playground[7]
 
Gift Certificates[4]