From time-to-time we'll grab a few contacts and queries from our Site and/or Store and publish here. We believe that some questions are quite common and can help others with their own projects. We'll make sure all private information is removed, keeping it anonymous.
Comment on YouTube Channel on 04/Aug/2016:
Reply:
Hello, at the same time the ESP8266 is a very popular board and offers easy integration with a TCP/IP network over WiFi (2.4GHz), it might not be the best solution when you are building a solution capable of communicate over-the-air but also running at very low-power, especially if you intent to run it on batteries.
The WiFi (generally 802.11g) and TCP/IP protocols are quite complex, especially if you're using any sort of encryption on top of that. Although most of the modern MCUs will be able to handle that, it comes to a cost of more MCU cycles, more running time and consequently more power consumption. The WiFi and TCP/IP negotiation can take up to a few seconds, which is a very long time for this sort of project. Also, once you place your device in sleeping mode or stop communicating for longer periods, the whole negotiation needs to happen again, normally after waking up the MCU.
Another aspect to consider is the TX and RX power consumption, which is normally high for WiFi devices. If my memory doesn't fail, the ESP8266 consumes around 50mA during RX and 130mA-180mA during TX, depending on the transmitting power. Those are very high figures, specially if you need to keep communicating for few seconds only to establish the initial link.
Well, after saying all of that, you might be thinking: "So, how can I run a very similar project using Whisper Node for years, using only AA batteries?" The answer (and this is true not only for the Whisper Node) is that low-power devices need to be kept as simple as possible, especially if they involve RF communication.
The first thing to note is that you can't have a device to talk directly with a SQL or HTTP Server on the Internet, over a WiFi connection, expecting it to run for years on a single AA. The preferred approach is to keep things very simple on the battery powered devices, stacking up a few layers on top of that, until you build the "link" to the SQL Server on the Internet.
A common model is to have an Internet Gateway for those small devices, which is basically a "Base Station" able to talk a simple protocol with the battery/remote nodes but also able talk a more sophisticated protocol, in this case to communicated with a SQL or HTTP Server. The combination of a Whisper Node and a Raspberry PI as "Base Station" normally works very well. In this case you leave all the heavy lift for the Raspberry PI, which will be always running from a mains power supply and you can have multiple Whisper Nodes talking with this single "Base Station".
In a summary, you can use the Whisper Node to build the same solution as the one you have running using ESP8266, but you'll need a "Base Station" to connect the Whisper Nodes to the Internet and adapt your code to run on this new architecture. Now regarding you specific question about the Ultrasonic Sensor, the HC-SR04 works only at 5V and Whisper Node runs on 3.3V to preserve energy. In this case the alternative sensor US-100 is the recommended part.
Sorry for the long answer, I normally prefer to clarify all aspects involved instead of simply saying "yes" that's possible.
Cheers,
Talk²
Hi there,
I currently designed my own pcb with esp8266 chip and HC-SR04, it measures a distance and then sends the data via http over internet and goes into deep sleep.
At the moment it still uses 2mA in deep sleep, and that is too much, since I will only be able to run them 60 days at the moment.
the ESP9266 runs arduino code, could I easily run my code on the whisper node? please let me know!
Hello, at the same time the ESP8266 is a very popular board and offers easy integration with a TCP/IP network over WiFi (2.4GHz), it might not be the best solution when you are building a solution capable of communicate over-the-air but also running at very low-power, especially if you intent to run it on batteries.
The WiFi (generally 802.11g) and TCP/IP protocols are quite complex, especially if you're using any sort of encryption on top of that. Although most of the modern MCUs will be able to handle that, it comes to a cost of more MCU cycles, more running time and consequently more power consumption. The WiFi and TCP/IP negotiation can take up to a few seconds, which is a very long time for this sort of project. Also, once you place your device in sleeping mode or stop communicating for longer periods, the whole negotiation needs to happen again, normally after waking up the MCU.
Another aspect to consider is the TX and RX power consumption, which is normally high for WiFi devices. If my memory doesn't fail, the ESP8266 consumes around 50mA during RX and 130mA-180mA during TX, depending on the transmitting power. Those are very high figures, specially if you need to keep communicating for few seconds only to establish the initial link.
Well, after saying all of that, you might be thinking: "So, how can I run a very similar project using Whisper Node for years, using only AA batteries?" The answer (and this is true not only for the Whisper Node) is that low-power devices need to be kept as simple as possible, especially if they involve RF communication.
The first thing to note is that you can't have a device to talk directly with a SQL or HTTP Server on the Internet, over a WiFi connection, expecting it to run for years on a single AA. The preferred approach is to keep things very simple on the battery powered devices, stacking up a few layers on top of that, until you build the "link" to the SQL Server on the Internet.
A common model is to have an Internet Gateway for those small devices, which is basically a "Base Station" able to talk a simple protocol with the battery/remote nodes but also able talk a more sophisticated protocol, in this case to communicated with a SQL or HTTP Server. The combination of a Whisper Node and a Raspberry PI as "Base Station" normally works very well. In this case you leave all the heavy lift for the Raspberry PI, which will be always running from a mains power supply and you can have multiple Whisper Nodes talking with this single "Base Station".
In a summary, you can use the Whisper Node to build the same solution as the one you have running using ESP8266, but you'll need a "Base Station" to connect the Whisper Nodes to the Internet and adapt your code to run on this new architecture. Now regarding you specific question about the Ultrasonic Sensor, the HC-SR04 works only at 5V and Whisper Node runs on 3.3V to preserve energy. In this case the alternative sensor US-100 is the recommended part.
Sorry for the long answer, I normally prefer to clarify all aspects involved instead of simply saying "yes" that's possible.
Cheers,
Talk²
