How to send a SMS message from Mac with Screen


I just received my GMS 862 Evaluation Board and here is how I managed to send my first SMS message (by reading this article and some trial and error):

  • Install the Virtual Com Port Driver (if you’ve already not done that) to be able to use USB to communicate with the board.
  • Connect the board to the USB port on your Mac. The red light on the board will light up indicating that it is getting power.
  • On the Mac, start the Terminal application
  • Find out the “name” for the serial port: issue the command ls /dev/tty.* 
  • The name will be something like /dev/tty.usbseria;-A80081n2
  • Start a serial session by using the screen application: issue the command screen /dev/tty.usbseria;-A80081n2 115200. To end the screen session enter control-a \
  • Start the GSM module (this is critical, if you don’t start it up then anything you type on the screen session simply wont show up and the AT commands will, of course, wont be sent to the GSM module. You can start up the module, by pressing and holding the little start button on the evaluation board for at least 1 second.
  • Issue the following 3 AT commands:


AT+CMGF=1
OK
AT+CMGW="+14081234567"
> HELLO WORLD!
+CMGW: 1

OK
AT+CMSS=1
+CMSS: 3

OK

The command AT+CMGF=1 will format SMS as a TEXT message.

The command AT+CMGW provides the phone number you wish to send the SMS message to. When you hit enter, the GSM module responds with >. Now you can enter your text message and you terminate it with control-z. The message is read into memory and the module replies with the message index.

The command AT+CMSS=1 sends the SMS message with the specified index.

Here is an excellent introduction to the SMS AT commands.

3 Responses to “How to send a SMS message from Mac with Screen”

  1. Tim Reynolds Says:

    Nice post. Thank you for the info. Keep it up.

  2. How to debug with Arduino « n o t e 1 9 . c o m Says:

    [...] setup (note that on the Mac, you need to use 2400 baud rate for the SoftwareSerial and for when you connect to the USB port via [...]

  3. Nicholas Searcy Says:

    I’m an electrical engineer getting into the computers side of things. THANK YOU. You made this so much easier.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s


Follow

Get every new post delivered to your Inbox.