Using ESP-12 NodeMCU 1.0 to with IoT Central
lafrank opened this issue · 4 comments
Is it supported by this library to use ESP-12 (NodeMCU 1.0 8266) with IoT Central ? There isn't any examples for this.
The examples show using either ESP-32 with IoT Central, OR using 8266 with IoT Hub.
I do have a legacy iotc library based sketch that runs on ESP-12 NodeMCU 1.0 and sends telemetry to IoT Central, but would prefer to use the newer library. Unfortunatley can't produce a working code for IoT Central using this NodeMCU 1.0.
Setup (please complete the following information if applicable):
- OS: Windows 10
- IDE: Arduino IDE 2.0.3
- Version of the Library used : 1.1.2
Hi @lafrank
The library should work just fine with the ESP-12 if you have had it previously connected. You will likely have to supply your own MQTT and TLS stacks to get it to work. The ESP8266 sample should act as a good starting point to see what needs to be done or swapped out. Note that a supported sample for an ESP-12 is not in our plans, but we will help where we can.
Hello @danewalton, thank you for your reply.
I understand that supporting ESP-12 is not amongst your plans.
Please take into consideration that operating sensors from battery requires a lower power consumption, and ESP-12E's power consumption is considerably less than ESP-32's. That's the reason why it was my choice of chip. If I switched to ESP-32, battery life of the sensors would be greatly reduced (according to documentations available on this topic such as https://blog.voneicken.com/2018/lp-wifi-esp-comparison/)
So maybe it is worth considering to support a low-powered chip. However, I am also open to use other chips if you can advise a supported one with a comparable or lower power consumption than ESP-12E.
Thank you.
This is an example of an ESP12 using PubSubClient to connect over MQTT. You can create an Arduino project and import the Azure SDK for C library to use in conjunction with the PubSubClient. Our ESP8266 sample in fact uses the PubSubClient, so there might be minimal necessary changes to get it to work (if not work directly).
If you need specific pointers in how to adapt over, please let us know.