4 ms·
MQTT is great on an internal LAN for controlling small devices based on say the ESP8266, but I wouldn't trust it over the public Internet unless it is VPN'd. Wh
by hwstar 11y ago
MQTT is great on an internal LAN for controlling small devices based on say the ESP8266, but I wouldn't trust it over the public Internet unless it is VPN'd. What's needed is a new protocol you can use between your phone or tablet which is websockets-based and can use HTTPS to talk to either node.js or something similar. This protocol could also convey graphing data and GUI building blocks to your phone or tablet.
BTW: I have several ESP8266 building blocks on my Github site https://github.com/hwstar https://github.com/hwstar with are home automation related. These include AC control, AC energy measurement, and DC voltage and current measurement. I'm not a GUI/android/ios programmer, but would like to work on open source software with someone who is.
- StavrosK 11y agoWhy websockets and HTTPS? That's way too heavy for embedded devices, and why do you care what the transport is if the messages themselves are encrypted and authenticated? If you want to take a look at what I'm building, I'll publish it at https://github.com/skorokithakis/stringphone https://github.com/skorokithakis/stringphone when I have some code.
- hwstar 11y agoYou are correct. If the transport is secure, then the protocol doesn't matter. I just think that a central controller model could use a protocol which is more suited to keeping the code on the mobile device as simple as possible. If you just want to send MQTT commands to nodes without a central controller, then what you propose makes sense.
- StavrosK 11y agoThe problem is that TLS is far from "as simple as possible", and you need TLS on the device in order to have encrypted communications just device-to-server. In my opinion, device-to-device encryption is much better, and you don't need all the overhead of TLS. I've actually finished a first draft of the prototype and am looking for people to kick the tires and discuss it. Would you be interested?
- hwstar 11y agoIf you make it open to everyone, I'll take a look. Post the code on Github and document what it does in the README.md file.
- StavrosK 11y agoDone.
- hwstar 11y agoHow would you run this on a mobile device? Since it's written in Python, you'd have to run it with something like Kivy.
- StavrosK 11y agoIt would be reimplemented in the target language (or possibly C). The interesting part is mostly the protocol, the language is just the proof of concept for now.