Get time using C++

/* localtime example */
#include <stdio.h>
#include <time.h>

int main ()
{
time_t rawtime;
struct tm * timeinfo;

time ( &rawtime );
timeinfo = localtime ( &rawtime );
printf ( "Current local time and date: %s", asctime (timeinfo) );

return 0;
}
 
Your looking at NITZ and you need to reference your Wavecoms AT command manual. I've tried to test my E220 but it does not support NITZ. Also most devices only get the time zone from the network and not the actual time. From looking at one of the Wavecom AT comman guides it does seem possible to do it. Wavecom have their own set of commands.

May I ask why you need the network time? If your looking at auditing then rather make use of a data base to insert your SMS and DLRs.
 
Top
Sign up to the MyBroadband newsletter
X