How to send SMS and make calls from OS X with AT commands
big pic
Tags
Learn how to communicate with an N95 via AT commands, which enable new ways to interface your N95 with your computer. What are AT commands? Back in the late 70s, the computer industry needed a way to tell modems what number to dial via software. Hayes Communication introduced a solution in 1977 via its product, the Smartmodem, and command language. The command set - now known as the Hayes command set [1] - consists of a series of short strings that combine together to produce complete commands for operations such as dialing, hanging up, and changing the parameters of the connection. With time, every major telephone, modem and GSM mobile phone manufacturer adopted their own set of the specification. The specification’s command for “attention” or “AT” - the way to get the phone ready to receive commands - has become the de facto name for the command set. Unfortunately, different phones support variant sets of AT commands. Moreover, there is no authoritative list available of supported AT commands by all phones. For our purposes, I was fortunate to find a small subset of the Nokia GSM AT command set. Nokia AT Command Set Ok, so I know what AT commands are and I have small list of them, now what do I do with this stuff? Not so fast! Before you move on, you should understand how this whole system works. From your computer, you’ll type AT commands in a terminal that then sends - via a USB cable, infrared or maybe Bluetooth - your commands to your mobile. Here’s how you would do the preliminary setup to send commands via a terminal and Bluetooth in OS X. Set up a Bluetooth connection between your N95 and your OS X computer. Pair your phone with your OS X computer. Here’s how you do it: 1. Choose Apple menu>System Preferences and then click Bluetooth. 2. Click Add (%2B). 3. When the Bluetooth Setup Assistant comes up and you’re asked for the “Device Type”, select Mobile Phone. 4. The Bluetooth Setup Assistant will then start to search for mobile devices in your surroundings. 5. Turn on Bluetooth on your N95. Select your device from the list and continue with the setup. When your N95 is finally paired, go back to System Preferences>Bluetooth. Your device will now appear as a Bluetooth device accessible from your computer. 1. Select your phone and click on the pinwheel symbol next to the (-) minus sign and select Edit serial ports. 2. Click Add(%2B). 3. Give it a simple name - I called mine Jose-2. 4. For a Protocol, select Modem. 5. For Service, select Dial-up Networking. 6. A device Path will show up at the bottom: in my case it’s something like: /dev/tty.Jose-2 7. Make a note with the Path somewhere and click Apply. Everything you need dealing with Bluetooth is now taken care of. Now we need to talk to the N95. To do that you need to: 1. Download goSerial [2] - a free OS X terminal application that lets you “talk” to serial devices - like your N95. 2. Go to File>New and configure the terminal with the following settings: Serial Port -> Select the port you created in the previous steps. In my case it’s Jose-2. Speed -> 9600 Data Bits -> 8 For the Hardware Flow Control: Input -> RTS Output -> CTS Click OK. Now you’re all set! First make sure that your N95 and computer have Bluetooth turned on and go to goSerial>Session>Connect. Type AT in the terminal and press the Enter/Return key. If everything is working correctly you should see an OK as a reply. Making a call with AT commands Now that the environment is ready, let’s see it in action. We’ll start by making a call via a few AT commands. 1. Open your goSerial terminal and type: ATDT 12125551212; 2. Press the Enter/Return key. 3. Replace the phone number with the number of your choice. Also, don’t forget the semicolon at the end of the command. You’ll see your N95 dialing almost immediately after you enter the command. Sending text messages Let’s assume that your uber-interactive project needs to send a text message. Here’s the set of commands you would need to get your N95 to do just that: 1. Define the message format - text mode - by typing AT+CMGF=1 2. Enter the recipient’s phone number using the AT+CMGS=”##########” command. ### is the phone number you would like to text. Don’t forget the quotes around the phone number. 3. Write the message and press Ctrl-Z. In less than a second you’ll see your message sent from your phone. And that’s it! Try it out and let me know what you think in the comments section. %5C + [1] http://en.wikipedia.org/wiki/Hayes_command_set [2] http://www.furrysoft.de/download/goSerial0.2.zip

Comments (6)

Michael Stanford
4:53 PM 08.02.08
Thanks! this was very useful. I copied it exactly with my Nokia E61i and it worked without any modifications.

Cheap international calls from UK
2:25 PM 11.04.08
hi this site is nice Cheap international calls from UK briing.com

joly
8:43 AM 01.03.09
Thank u for the nice project it worked but i trai it withe the hyper prog and i used a N81 but how to receive an SMS to ur PC ..... i hope u have the answer

tomciaaa
3:09 PM 01.26.09
Nokia_AT_help.pdf is a great book, covering just what you need, joly. I can't remember where its hosted, but google it with quotes and it will be there :) Hope this helps. P.s. great find :)

7biba
7:36 AM 05.08.09
hahkkl

nidal
7:37 AM 06.07.09
salut zine ca va hani hadi njki daba ok

Name

Email (not displayed publicly)

Enter comment

 

Tags