0
\$\begingroup\$

I have a SIM800c and I'm also using an adafruit.io server. I'm building an alarm system and I'm wondering if I will be able to send commands to the system using the server while the GSM module is in sleep mode.The way the commands work is I update a feed on my server and my device detects that via the cellular network. It notices changes because it has "subscribed" to the feed.

My device uses the MQTT protocol to communicate with an adafruit.io server. When a device is subscribed to a feed, it takes note of any changes that occur there. A feed is basically just a list of data. When a value is added to the feed, any devices that are subscribed to the feed notice.

To give you some context, my alarm system has 2 commands, arm and disarm. I want to put the GSM module in sleep mode while its not being used in order to save power. I'm concerned that the device wont be able to respond to changes in the feed on my server.

I would test this myself and I will as soon as I can. I just don't have the PIC device yet, so I figured I would ask and see if the answer is out there.

I've included the datasheet for the SIM800c. See this following link: Elecrow Hardware Design PDF.

See the attached image. It says it can still respond to data calls while in sleep mode. I'm just not sure what that means. Does that mean that if my device is subscribed to a feed, and the feed changes, the device will still notice it? It's all done through data.

What do you think?

Information from datasheet

\$\endgroup\$
  • 1
    \$\begingroup\$ You need to be much more specific about what you mean by your device being "subscribed to a feed"... does that mean some server is effectively going to inspire a data call (like a phone call or an SMS message) to your device? If not, then the answer is probably "No." Certainly, the cellular module will not be able to keep a TCP/IP connection live while it's in sleep mode. That would shock the heck out of me if it could do that. \$\endgroup\$ – vicatcu Nov 30 '19 at 0:59
  • \$\begingroup\$ My device uses the MQTT protocol to communicate with an adafruit.io server. When a device is subscribed to a feed, it takes note of any changes that occur there. A feed is basically just a list of data. When a value is added to the feed, any devices that are subscribed to the feed notice. Also if you don't understand what a feed is or what it means to be subscribed to one, then you probably wont be able to help with this question. \$\endgroup\$ – user3308807 Nov 30 '19 at 1:15
2
\$\begingroup\$

The MQTT protocol sits on top of a long-lived TCP/IP connection. There is next to no chance that a cellular modem would maintain a TCP/IP connection while in sleep mode. So you won't wake up from a subscription firing.

It's not impossible that once you wake up for some other reason and reconnect, depending on the configuration of the MQTT broker, that you might get subscribed to messages that arrived since you last connected (i.e. QoS level 2), but I don't Adsfruit.io would provide that.

| improve this answer | |
\$\endgroup\$
  • \$\begingroup\$ That's okay. I figure I will use an SMS to wake up the module since it does respond to that and then once its woken up, then update the feed. \$\endgroup\$ – user3308807 Dec 1 '19 at 2:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.