I'm not sure the module itself contains a method, but if you know the AT command you send it's easy enough to add one - the code itself is in https://www.espruino.com/modules/SIM900.js
For example:
// there is already a getVersion function, but you can see how you might change it
gprs.getVersion = function(callback) {
this.at.cmd("AT+GMR\r\n", 1000, function(d) {
callback(null,d);
});
},
If you don't want to/can't change it, does getIP not work? I guess if there is no connection you won't have an IP?
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
I'm not sure the module itself contains a method, but if you know the AT command you send it's easy enough to add one - the code itself is in https://www.espruino.com/modules/SIM900.js
For example:
If you don't want to/can't change it, does getIP not work? I guess if there is no connection you won't have an IP?