Reputation: 632
In my current scenario, I'm using NETLIGHT Pin (Pin no. 64) of SIM800 module with my PIC microcontroller to know whether my module is registered or not?
This way I built the circuit. Just I removed LED from VBAT. Then I connect collected of NPN transistor to pic micro input PIN.
I want to know whether any easy way using AT commands to find network registration status of SIM800?
Upvotes: 2
Views: 11488
Reputation: 21
In my case; I tried to test "AT+CREG" command by disconnecting the antenna from SIM800C. I know disconnecting antenna is not a good idea and even can cause device damage, but I did it to simulate network registration fail in room area and see what the device will reply to "AT+CREG" in this scenario.
As I tested: while the antenna is disconneced and "AT+CSQ" reports -100dBM signal strength, I can not call to SIM800C or send-receive SMS; but there are lots of time the module confirms network registration in reply to "AT+CREG?" command, although in reality the device has not access to network.
Upvotes: 1
Reputation: 1348
Unfortunalty it's seem not to be really possible (or in fact detecting this state in only one way) I use SIM800 and let it run for hours and I have seen many cases of network loose, while the AT+CREG? continue telling everything is OK.
Also, even with network down, the SIM800 continue sending you the name of the operator and the strengh of the signal.
The only way I've found is to monitor the serial port: when the SIM800 loose the network, it sends two messages: +PDP: DEACT and +SAPBR 1: DEACT
I suggest you to have a look at the document "SIM800 Series_AT Command Manual" and especially the chapter "19.3 Summary of Unsolicited Result Codes". You'll find +PDP and other interesting code (like under-voltage warning, DNS failed...) and see some of these messages are not linked to AT command.
Upvotes: 3