I am using a sample app to send/receive messages but I have noticed that there is a long latency with the handler when receiving SMS and I am trying to understand if this is due to the network, signal or the app itself.
This is the radio signal for the SIM:
root@fx30s:~# cm radio
Power: ON
Current Network Operator: Telstra Mobile
Current RAT: LTE network (LE_MRC_RAT_LTE)
Status: Registered, home network (LE_MRC_REG_HOME)
Signal: Strong signal strength (4)
PS: Packet Switched Registered, home network (LE_MRC_REG_HOME)
On bootup it will get the SMS, but after the unit is running for a while it will take a long time to receive the messages, I have noticed up to 10 minutes to get them.
the handler from the sample code is just not getting invoked
res = le_sms_DeleteFromStorage(msgRef);
if(res != LE_OK)
{
LE_ERROR("le_sms_DeleteFromStorage has failed (res.%d)!", res);
}
else
{
LE_INFO("the message has been successfully deleted from storage.");
}
}
else
{
LE_WARN("Warning! I read only Text messages!");
}
le_sms_Delete(msgRef);
LE_INFO("message object deleted from memory.");
}
and I am having an hard time to understand if this is due to the app or there are some settings I can change for the le_sms (couldn`t find any from the le_sms API) which will make this more responsive.
Is this just a matter of the modem polling the SMS server for new messages?
it seems that the AT port will behave as the Handler itself, so to say, as soon as the +CMTI: “ME”,XX is displayed then the message handler will be invoked.
root@fx30s:~# microcom /dev/ttyAT
+CMTI: “ME”,40
+CMTI: “ME”,41
+CMTI: “ME”,40
+CMTI: “ME”,41
+CMTI: “ME”,40
+CMTI: “ME”,41
+CMTI: “ME”,40
+CMTI: “ME”,41
+CMTI: “ME”,40
but sometimes after a send a SMS from my phone, it will take a fair bit before the the message is shown and the handler is invoked.
using phone number 1 to send messages, at a given point the modem will stop receiving messages
then I use phone number 2 and the message will be received immediately, also the messages sent from phone number 1 will be received. After a couple of messages, SMS from this number will not be received anymore.
using phone number 3 will have the same effect, SMS immediately received and also the SMS sent from phone numbers 1 and 2 will be received.
It may be related with the server side, but if I use the same SIM card in a normal phone, then all SMS will be received immediately so I am wondering if there is a polling problem related with the le_sms API?