Setting Voicemail Waiting Indication via SMS

This post was written by Jeroen on July 8, 2009
Posted Under: SMS
This entry is part 16 of 17 in the series Sending out an SMS

As shown in an earlier post, the Data Coding Scheme (DCS) octet in the SMS PDU can be used to turn a regular text message into a flash message.

Another feature of SMS that is enabled through use of the DCS is the Message Waiting Indication:

  • When someone leaves you a voicemail, the voicemail system communicates with the SMSC to send your phone a special SMS message that turns on the little icon on your phone that indicates that you have a new voicemail.
  • When you listen to your voicemail, the voicemail system also communicates with the SMSC to send your phone a SMS message that turns the little icon off again.

Using the DCS you can turn the voicemail icon on or off yourself.

This is an example PDU to set a voicemail indication:

AT+CMGS=27
0001AB0B915121551532F400C80F3190BB7C07D9DFE971B91D4EB301<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 AB 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 C8 Data Coding Scheme. This is the value that cause the message to be a voicemail notification as opposed to a standard SMS.The first nibble can be:

  • 0xC for Message Waiting Discard (do not store the text that is in this message)
  • 0XD for Message Waiting Store (do store the text that is in this message

The second nibble’s first bit represents on/off:

  • 0×0 is set indication inactive
  • 0×8 is set indication active

The second nibble’s last 2 bits determine the type of message:

  • 0×0 stand for voicemail
  • 0×1 stands for fax
  • 0×2 stands for email
  • 0×3 stand for other message

So 0xC8 stands for turn on voicemail message waiting and discard this message.

1 octet 0F User Data Length or payload size (in characters).
15 septets 3190BB7C07D9DFE971B91D4EB301 The payload, also known as User Data. In this case it is just GSM encoded text.This particular string represents “1 new voicemail”

And for completeness, here is a command to turn it off again:

AT+CMGS=28
0001AC0B915121551532F400C011EE37C85DBE83ECEFF4B8DC0EA7D973<Ctrl-Z>
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 AC 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 C0 Data Coding Scheme. 0xC8 stands for turn off voicemail message waiting and discard this message.
1 octet 11 User Data Length or payload size (in characters).
17 septets EE37C85DBE83ECEFF4B8DC0EA7D973 The payload, also known as User Data. In this case it is just GSM encoded text.This particular string represents “no new voicemails”

You can play with the DCS field:

In the messages with these DCS the text is discarded:
  • 0xC8 – turn on voicemail (discard)
  • 0xC9 – turn on fax (discard)
  • 0xCA – turn on email (discard)
  • 0xCB – turn on other message (discard)
  • 0xC0 – turn off voicemail (discard)
  • 0xC1 – turn off fax (discard)
  • 0xC2 – turn off email (discard)
  • 0xC3 – turn off other message (discard)
In the messages with these DCS the text is stored in the SMS inbox and the text is GSM-7 encoded:
  • 0xD8 – turn on voicemail (store)
  • 0xD9 – turn on fax (store)
  • 0xDA – turn on email (store)
  • 0xDB – turn on other message (store)
  • 0xD0 – turn off voicemail (store)
  • 0xD1 – turn off fax (store)
  • 0xD2 – turn off email (store)
  • 0xD3 – turn off other message (store)
In the messages with these DCS the text is stored in the SMS inbox and the text is UCS-2 encoded:
  • 0xE8 – turn on voicemail (store)
  • 0xE9 – turn on fax (store)
  • 0xEA – turn on email (store)
  • 0xEB – turn on other message (store)
  • 0xE0 – turn off voicemail (store)
  • 0xE1 – turn off fax (store)
  • 0xE2 – turn off email (store)
  • 0xE3 – turn off other message (store)

The Data Coding Scheme is just one octet, but the spec 3GPP TS 23.038 dedicates a whole chapter to it.

Series NavigationReferencesSMS via Email
Tags: , ,

Reader Comments

Jeroen:
Your contribution is incredible.
Thanks again!.
Regards
Franco

#1 
Written By Franco on July 9th, 2009 @ 1:50 pm

Jeroen:
Tried DCS(0xDA) Trun on e-mail (Store).
Works perfect.
A sms is stored at my inbox OK.
Is there a way to make such sms as a wap push sms?
What I actually do is to send a text link and from there the broweser, via get, takes you to the URL.
Using a Carriage Return, I send two links; one goes to the ‘mail server wap main page’ and the second one automatically ‘downloads via sms the headers of the mail’ received.
If such message could be turned into a wap push, I think
it would be much better!:
Regards
Franco

#2 
Written By Franco on August 1st, 2009 @ 10:57 am

Franco,

No, you can’t do this with WAP push. There is a way of doing it without setting the DCS though. There is an UDH IE that has the same effect as setting the message waiting flags in the DCS. It has an additional feature: it lets you set the message count (how many message are waiting). I haven’t seen any device showing the message count though.

Here is a brief description of the IE
- IEI = 0×01 (this identifies this IE as a “special SMS message indication”)
- IE length = 0×02 (this IE always has 2 octets of data)
- 1 Octet = message type
- 1 Octet – message count

The message type is
- 0×00 for voice message
- 0×01 for fax message
- 0×02 for email message
- 0×03 for other message

Set the first bit of the message type (0×80) to let the device store the message, discard is the default

Jeroen

#3 
Written By Jeroen on August 4th, 2009 @ 11:12 am

Jeroen:
This is what you have up here !:
AT+CMGS=27
0001AB0B91
0585785777F5
00
C8
0F
3190BB7C07D9DFE971B91D4EB301
This is what I have been working on:
1 octets 0×09 header length is 9 octets. UDH
1 octet 0×01 IEI 0×05 source and dest. port.
1 octet 0×02 IEDL. Content is 2 octets.
1 octet 0×02 Message type. 00(Voice) 02(Mail)
1 octet 0x0F Message count.
1 octet 0×00 IEI 0×00 concatenation information
1 octet 0×03 EIDL. Content is 3 octets.
1 octet 0xF0 Reference number
1 octet 0×01 Total 1 parts
1 octet 0×01 This is the 1st (and only) part
This is what I came up with:
AT+CMGS=35
0001AB0B91
0585785777F5
00
090102020F0003F00101
3190BB7C07D9DFE971B91D4EB301
I get errors and I have tried about twenty different arrangements and do not seem to come up with a successful message.
Your help will be appreciated.
Regards
Franco

#4 
Written By Franco on August 5th, 2009 @ 5:31 pm

Franco,

I think you forgot to the the UDH bit in the first octet of the PDU (you have 0×01 for SUBMIT PDU, change this to 0×41 for SUBMIT PDU + UDH). You don’t need the concatenation IE.

Jeroen

#5 
Written By Jeroen on August 5th, 2009 @ 9:26 pm

Thanks a ton for the detailed explainations….Really useful and easy to understand…Much Appreciated !

#6 
Written By Vikrant on February 25th, 2010 @ 3:43 am

So Jeroen, Franco, Vikrant,
What was the final PDU “string” necessary to send a send the message count along with the message waiting indicator. I’ve been having some trouble replicating your results. Thanks!
-Karl

#7 
Written By Karl on July 17th, 2011 @ 2:01 pm

Got it!
0041AB0B911234567890F100C806040102000100

#8 
Written By Karl on July 18th, 2011 @ 9:26 am

Krishna:

is any technique! to retrieve SMS from remote mobile to my email id via WAP PUSH/PDU/UDH/any technique by you?

Brief: I will send one SMS to target (remote) phone. That SMS makes some changes in that phone. That change sends its SMS to my email id.

#9 
Written By Krishna on August 29th, 2012 @ 5:14 am

how to send all three message indiction in a single sms?

#10 
Written By kp on December 17th, 2012 @ 6:30 am

Hello,

I have something regarding this please, i used DSC 0xDB to indicate voicemssage but it’s a flash message so my question can i send normal ordinary message and just send indication for the voicemail icon? i dont want it to be flash message just normal SMS and i want the voicemail icon to be displayed! what should i change to do it please.

Thx in advance.

#11 
Written By Fuad on June 1st, 2013 @ 3:40 am

Add a Comment

required, use real name
required, will not be published
optional, your blog address

Next Post:
Previous Post: