Date ,Time ,Time Zone information

Dear All

I have a wavecom Fasttrack superme 20 modem evaluation kit with me.
I want to get the date/time information from the network service provider using GSM.
Though we can achieve the same by connecting to internet using GPRS and then use ‘ntpclient’ to get this done,i have a special requirement where i need to do it using GSM.

So i searched the AT commands document and found that there is a Wavecom proprietary command AT+WLOC.
For this command to work,first we need to enable this feature and restart the modem which i did first.
Then i issued this command and i got the output. I am in India and using a Airtel SIM card.
Here is the response for it.

at+wloc=1
+WLOC: 04f404,1391,7758,bb40012b541401d85bc3c779d1440000,00100011001200140016001
700180019001a001b001c001d001e001f,01, 08101000800422

OK

The last 7 bytes of the output i.e “08101000800422” has the data,time,month,year and time-zone information.
The AT command document says that this information is in the SIM toolkit format.

After searching in Google,I found that this date/tine information is in the Service-Centre-Time-Stamp-(SCTS) format which is explained in the GSM 04.08( Version 6.10 Release 1997) document.

All that i understood(if i am right) is that the last byte ‘22’ stands for the timezone information expressed as quartets of an hour,between the local time and GMT.For my case i am at GMT+5.30 timezone,so that comes to 22.
The rest of the information seemed to give wrong data and time.Is there anything that i am doing wrong.

Please excuse me if this is the wrong place to post this question.
Any help would be of great use.

Thanks.

Basically, there is no guaranteed way to do this - you just cannot rely upon the network:

viewtopic.php?f=34&t=748&p=2667&hilit=wloc#p2667

Hiya,

I didn’t decode your example, but the NITZ message ships the time in UTC, with the number of 15 minute increments to convert UTC to the local timezone.

Is the time in your example in UTC, rather than local time?

ciao, Dave

The output is not UTC.It is the local time. Another information i missed is that i got the o/p of AT+CCLK which gives the RTC time whose o/p is shown below.

at+cclk?
+CCLK: “00/01/01,05:49:19”

The AT+WLOC command was issued few seconds before this command to the modem whose o/p i had posted earlier.

Decoding the o/p(08101050843322) according to GSM standards yields

80,Jan 01,05:48:33 GMT+5.30.

So what i can conclude is that modem gives just the RTC time information. But the timezone information seems to be correct.
However the “Year” field is not matching with that of the RTC “YEAR” field.

What could be the problem.Is it a problem with the modem or my interpretation?

Also,there is no problem with the network as my phone(Sony Ericson K750i) is able to get the NITZ from my network provider(“AIRTEL”).So my network can be trusted.

Hiya,

The NITZ messages come from the unsolicited +WIND: 15 messages. I’ve used this (with a little bit of coding) to set the RTC using AT+CCLK.

You have to enable these using at+WIND command before they will appear on your serial console.

All this indicates is that the clock has never been set since power on. If you don’t have a battery connected (or it’s gone flat) to the RTC pin on your modem, the RTC is reset each time the modem is power cycled. Now, the Fastrack Supreme’s that I have disassembled have got a little coin cell soldered to the carrier board - so this battery may be flat in your modem.

ciao, Dave

Hi Dave,

I am sure that my modem RTC has battery backup because i set the current date/time manually using at+cclk.
I removed the power for the board and powered it again and found it that the date time was saved.

Now i activated the unsolicited event notification for NITZ message using the AT+WIND=15 command.
I didn’t get any unsolicited notification from network.

The AT+WLOC command is supported by modem to get date/time/timezone information at anytime as opposed to the modem notifying to us through unsolicited event 15.

All that i am seeing is it just gives the RTC’s date time only. I think it is of no use to try this anymore.

As I said to you earlier (the very first reply in this thread):

The modem cannot report information that hasn’t been provided to it!

Indeed - unless you can find a service provider that will specifically guarantee that this inforation will be provided…