Sending a flash SMS message
This post was written by Jeroen on February 12, 2009
Posted Under: SMS
Posted Under: SMS
- Sending out an SMS in text mode
- Sending out an SMS in PDU mode
- More on the SMS PDU
- Sending a flash SMS message
- What are EMS messages?
- Combining SMS messages
- WAP Push over SMS
- WAP Push SMS encoding
- EMS and WAP Push support
- Another WAP Push over SMS encoding
- SMS based applications
- Text formatting with EMS
- GSM-7 Encoding with the GNU iconv library
- How to pack GSM-7 characters into septets
- References
- Setting Voicemail Waiting Indication via SMS
- SMS via Email
So far I’ve show how to send a text message in PDU mode. There is nothing special about this. There are a number of things you can do in PDU mode, that you can’t do in text mode.
A first example is a flash SMS message.
A flash SMS message is an SMS message that, instead of being stored in the SIM or memory of the receiving phone, pops-up on the receiving phone’s screen, without the user taking any action. When dismissed the message is usually gone.
Here is an example AT command to send a flash SMS message in PDU mode:
AT+CMGS=28<crlf> > 0001010B915121551532F40010104190991D9EA341EDF27C1E3E9743<Ctrl-Z>
Here is what the individual octets represent:
| Size | Value | Description |
| 1 octet | 00 | We don’t supply a SMSC number. |
| 1 octet | 01 | PDU type and options. This is a plain SUBMIT-PDU. |
| 1 octet | 01 | Our message reference. |
| 1 octet | 0B | Size of destination telephone number (in digits) |
| 1 octet | 91 | International numbering plan. |
| 6 octets | 5121551532f4 | This represents the destination and it translates to 1 512 555 1234 |
| 1 octet | 00 | Protocol identifier. |
| 1 octet | 10 | Data Coding Scheme.This is the value that cause the message to be a flash message as opposed to a standard SMS. |
| 1 octet | 10 | User Data Length or payload size (in characters). |
| 16 septets | 4190991D9EA341EDF27C 1E3E9743 |
The payload, also known as User Data. In this case it is just GSM encoded text. This particular string represents “A flash message!”” |
A more elaborate explanation of the GSM encoding and other fields is giving in a previous post in this series.







Reader Comments
My site is accesible for only two hours a day!!!
Coooool!!!.
Have tried your flash message with my modem Siemens TC65 (Now Cinterion) and pdu mode with destination to my SonyEricsson w200
with local operator http://www.movistar.com.ni and also tried it with another SonyEricsson w200 with another local company CLARO or http://www.americamovil.com (CLARO enitel.com.ni).
I live in Managua, Nicaragua!.
IT WORKED PERFECT.
There is NO other site that offers such detailed and well explained procedure.
Hope in the future that all features that pdu has to offer will be available in the text mode.
Regards
And Thanks very much!!!.
Franco
Jeroen:
If, instead of 10 for data coding schema I change it to
14 (00010100) , is it posible to send the message using octets instead of septets?
And then UDL will be the same and will have 16 octets instead of 16 septets!.
Regards
Franco
Sending in octets is only used for non-text applications like WAP push. If you want to send text messages (like flash) you’ll have to stick with UCS-2 or GSM-7. Think about it, if you’re sending text in octets, which character set would be used? ISO-8859-1? Windows-1252? UTF-8 encoded unicode?
If you want to send an ASCII message you could send it in UCS-2 and add a 0×00 before each ASCII character. The first 128 characters of UCS-2 are the same as ASCII.
In general you’re right about the UDL:
- When sending a message in octets the UDL is the octet count
- When sending a message in GSM-7 the UDL is the septet count
- When sending a mesage in UCS-2 the UDL is the character count (each character taking up 2 bytes)
Saludos,
Jeroen
Jeroen:
Just tried using 14 (00010100) instead of the 10 you have and encoded the message ascii to HEX.
And message was sent as a flash message OK.
Any comments
Regards
Franco
The value 14 stands for a flash message with 8 bit data. It seems that your receiving device interprets this as characters in some character-set (most single octet character sets correspond to ASCII for values < 128). This is a great feature of that device, but you can’t rely on all devices behaving this way. This is not a standard feature!
Jeroen:
Perhaps the key word is “Standard feature”.
I use the cheapest of all SonyEricsson phones
that can handle wap (w200). It is a US$125.00
phone. Bought it 6 month ago.
Could it be that technology is somehow ahead of standards and that very soon that feature will be a standard.
I think that technology con make obsolete huge amounts of Inventory for this companies and so the standard should somehow wait a little.
Regards
Franco
P.S. Your responses give us information very valuable and feel sure you are aware of this real facts!!!.
Franco,
The SMS technology is hardly changing. It is one of the oldest and most stable features on GSM networks. All innovations are happening in other areas (SIP, Device Management, SMIL, Audio, Video, Instant Messaging, etc). I you look at the latest specs (Rel 8 of December 2008) and the earlier specs (Rel 3 of 1999), you’ll see that the definition of DCS hasn’t changed. The specs still says that 8-bit data is ‘user defined’. This means (to the manufacturers) use it anyway you like.
So what the Sony Ericsson is doing is perfectly fine, it may even be a ‘de facto’ standard (I really don’t know how many manufacturers do this), but I still see some issues:
- Which character set is used? For ASCII characters this may work fine, but how about characters > 127?
- You can only send 140 characters this way
So it is easier to program, but if that is what you’re looking for, why don’t use text mode? I personally would not rely on this feature, but of course that doesn’t mean that you shouldn’t…. I am just trying to make you aware of the implications.
Cheers,
Jeroen
Jeroen:
Thanks again!.
Sent a flash message with UCS-2
at+cmgs=37…
0001010B91
0585785777F5
0018 (00011000) flash + UCS-2
18
00560069007600610020004600720061006E0063006F0021
It worked perfect!!!.
Regards
Franco
how long can our message be???
Flash SMS messages can be just as long as plain text SMS messages (which is 160 characters when using the GSM-7 alphabet). Flash messages can also be concatenated to create larger messages. Be sure to set the same DCS in all parts of the multi-part SMS message.
Jeroen
Jeroen:
I had learned that a flash message requires a
DCS = hex->10 which is 00010000
I tried DCS = hex-> F4 which is 11110100
and receive the message as flash too.
According to the specs it should be a flash message
in both cases!.
Why would they have two DCS for same message?
Is there something else involved in this?
Your thoughts will be appreciated!.
regards
Franco
Franco,
You’re right: there is more than one way to specify a message with a message class. Not sure why they specified it this way though.
Jeroen
Readers,
I need some help. I have a GSM device Siemens MC35i Terminal and it only sends SMS as Flash. Can anyone give me the AT command to reset it back to a normal SMS that saves on the phone or memory.
Any help appreciated.