I am trying to make the Arduino Portenta a complete Edge Impulse Home Automation product. It seems MQTT is the standard method for subscribing and publishing Sensor, Actuator or Machine Learning data.
It seems that everyone uses the Mosquitto MQTT Broker on the Raspberry Pi, or some fancy cloud broker. As far as I can tell an MQTT Broker (other than some fancy bells and whistles) has a fixed IP and just receives an MQTT publish message from a dynamic IP and sends it to all the subscribed dynamic IPâs. That should not be very hard to get working for say 30 clients on the Arduino Portenta (Dual core with Wifi, BLE and Ethernet), however I am not finding much about an Arduino MQTT Broker.
I have just started looking in microPython but also finding nothing:
Any words of wisdom if this would run on the Arduino PortentaH7 using OpenMV micropython? No worries since I will try it. Very cool to see your name there?
And for the MQTT broker on Mbed OS, it actually seems that @jenny authored the code sample in your link
And if you are new to MQTT, Iâd recommend to use this lightweight software to visualise your payloads going through the broker: http://mqtt-explorer.com/
It is super easy to use and you can connect to any broker easily (just make sure you are on the same network if you use a Raspberry-Pi-base broker ).
Thanks @louis I am getting MQTT clients running on both Arduino and OpenMV. Also mqtt-explorer.com works great so does node-red. My interest is to get a very small MQTT broker working on the Portenta. I will have to look at the code @jenny worked on, the example page I saw was only an MQTT client.
I have a method to run C++ cross compiled programs on the arduino but not expecting that route to have much luck. Also I donât need a full fledged Broker, just something that can handle 1-5 topics.
Presently looking into the handshake between MQTT client and broker.
Finding a few MQTT and IOT HTTPS webhook sites out there, see my list here, and many charge quite a bit for monthly use ($5/month to $1000/month). This confuses me as the MQTT (port 1883) is a port allowed on most home sites and the mosquitto broker is free and static easy to write webpges can connect to these MQTT sites. See my example here.
Anyone at Edge Impulse have an MQTT broker (or HTTPS webhook) they prefer? @louis@shawn_edgeimpulse@jenny I am having some luck with:
I have little experience with MQTT. Of the sites you mentioned:
IFTTT - used to be good, but went to a subscription model and is super wonky to use now (IMO)
ThingSpeak - owned by MathWorks, used to be an open source project. Itâs decent, but there are limits on datarates (to be expected for the free version) Adafruit.io - Free version is pretty solid
If I go with adafruit.io for the MQTT, or make my own home mosquito server, anyone got any suggestions for easy to use https webhooks for IOT data. The big solution is for me to go through all of the ones I have found and try them out. Really hoping someone at edgeimpulse has found something they really like.
Thinking out loud here, is edgeimpulse interested in providing an integrated Machine Learning IOT data movement site with both MQTT and HTTPS webhook abilities? Probably not, since the space is already flooded, but since edgeimpulse already has my raw data I might be more inclined to trust them with my Edge data as well.
Here are the sites I have found. Twitter sites not shown here only webpages. See my link above for the twitter sites
Good catch Allen. I didnât know adafruit.io did Webhooks as well as MQTT, that might be the service I stick with, as the MQTT works so well with the Arduino IDE ready CayenneLPP library . By the way LadyAda is one of my heroâs, even this link is interesting.
Most of this tinyML work we do is not much help unless you can publish some kind of feedback from your data on the web (unless everything you are doing is private). I wish to be able to send Arduino Portenta information using Cellular, Wifi, Ethernet and LoRaWan and then present that information on a static (websocket) webpage.
I am still really confused with MQTT or Webhook websites. I made this 45 min video where I go through the above links (I can barely stay awake).
I did actually find a few sites to check. Presently also looking into making my own MQTT server on Heroku. Adafruit.io seems to be winning the battle for me. Yes @LadderLogic you can use webhooks with Adafruit.io so that is cool, but I think you cannot yet receive webhooks from adafruit.io. So here is my present issue.
I love using HTML, localStorage, websockets or async/await fetch and Javascript with static webpages on Github. I should be able to get my feed or last 30 days of data off the site in JSON format, then I can make my own public dashboard, without giving up my private key. Anyone got any suggestions of sites that allow making your own public dashboard. Seems that most sites like cloudmqtt.com that were free now have a basic $5/month fee.
My work is always for teaching. I am leery of free to try sites because they often want your credit card.
Anyone other suggestions. Arduino Cloud is so close, they just have a few changes and updates to make.
which looks like it get all past (30 days) group information. not s websocket but better than nothing. would be easy to poll it every say 30 seconds on a static webpage. The could be entered from a text box to git a bit more security. I would prefer a live websocket for each feed but this looks better than nothing.
That is so awesome @louis. That might fully switch me to scaleway. I never thought of sending images controlled by MQTT, great tutorial. Nice use of github markdown as well.
Yes, what I did was to create an organisation under my name and then invite the students in my organisation (so they donât have to go through this screen). But if they create other ressources other than the free ones, you might have to pay for it :D.
I was also making sure that all the ressources were removed at the end of the lab + remove the students from the organisation .
As most of the resources are hourly billable, even for one 3 or 4-hour lab with 30 students, it does not cost more than a couple of euros/dollars when using paid resources.
Your project @louis has shown me what can be done, but I need to find a non-credit card IOT site, and EdgeImpulse of IOT!. I get their issues with people taking advantage of them, but as a teacher I canât be using my credit card with any potential for overcharges. Here is my latest list of sites to try, hopefully some of the Ambassadors can get involved. I am looking for the ultimate student IOT site.
These are the interesting IOT sites so far: (I should delete them from the list as issues are found)
This is a big job! At least I now know exactly what I am looking for. To teach IOT connectivity for my EdgeImpulse capable devices I need an IOT site that has:
My Student/Developer IOT Platform Criteria
>= 3 free devices without a needed credit card
Easy to setup MQTT connectivity for multiple devices and platforms
Easy to setup HTTPS connectivity for multiple devices and platforms
Easy to setup Websocket-MQTT connectivity for multiple devices and platforms
Sensible free limited datastorage, say >= 10Mb, >= 2 weeks
.
Problem is that every site takes a fairbit of time to setup and get your bearings.
So far I like but they donât have all my criteria: Arduino Cloud, Adafruit, Ubidots, thingspeak, pipedream, tagio.
Websockets seem to be the problem, and yes I am being a little stubborn here. However if you have seen the power of the Edge Impulse WASM (Machine learning output for web pages using web-Assembly) and realize that webpages are the most powerful way to reach a massive audience, you will understand the reason to try to get websocket-mqtt working with Machine Learning data.
I am now going to test Databricks and Akenza, but if anyone else has suggestions for IOT devices with potential for the above criteria I would be interested to hear about it.
.
Well that was fast: Databricks you must signup your company, Akensa only give 3 months then needs a credit card. Whoâs next?
So this is starting to get interesting. Presently HiveMQ is my favorite. It has SSL Websocket-MQTT and I already have a vanilla Javascript static webpage working here Not userfriendly as I havenât taught it yet. For hive you need a special hostname, username and password. To setup multiple pages you need different ClientIDâs
So websockets seem to be for me the defining feature of a good IOT integration.
HiveMQ has some issues with a @Helium integration, but that might be able to be solved. This is exciting as this is one of the last things I need for my course.
If anyone knows other sites that have websocket-MQTT please tell me. I am presently trying to find out if some of the above sites have it.
I am very impressed with Adafruit. After I emailed them about MQTT-Websockets, they contacted me to describe the issue, assigned a developer and within 24 hours had it working!