erdemarslan / GSMSim

GSM Library for SIMCOM Modules on Arduino.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How can i use? at GSMSimTime the get function?

rubinlicht opened this issue · comments

I want read out the Time with SIM800L. With the command don't go

get(int *day, int *month, int *year, int *hour, int *minute, int *second)

What make i wrong?

Sometimes module gets time information too late and this function sometimes not work well. Please use getRaw function instead of get function. Then you can split raw value in your code.

commented

You have to make an existing variable then let the function fill them out:

int day;
int month;
int year;
int hour;
int minute;
int second;
gsmsim.get(day, month, year, hour, minute, second);
Serial.println(day); //a test