Toon gets data from MQtt (InfluxDB)

Everything about software tools, new software development and toolchains. For developers, mostly.

Moderators: marcelr, TheHogNL, Toonz

Post Reply
BillytheKid
Starting Member
Starting Member
Posts: 5
Joined: Fri Nov 19, 2021 12:25 pm

Toon gets data from MQtt (InfluxDB)

Post by BillytheKid »

Hello,

I've just rooted my Toon 2 and playing a bit now. I've got an existing solution for water, power and solar usage so don't want to add the Toon hardware for that.
I'm getting my usage stats via ESPHome into an MQtt database (InfluxDB in my case). Any way to get my usage stats out of InfluxDB into Toon?

Cheers, Bill
HansS
Starting Member
Starting Member
Posts: 34
Joined: Thu Feb 15, 2018 11:54 pm

Re: Toon gets data from MQtt (InfluxDB)

Post by HansS »

This is an old topic I see. But I'm doing something similar. A long time ago I tried to use MQTT via node.js (See here: viewtopic.php?t=11982). But that wasn't a viable option. Too resource intensive, and difficult to integrate with apps.

Nowadays, I send statistics using websockets (Introduced here: viewtopic.php?t=12332). I use this mechanism to send energy usage and weather data from my MQTT environment to Toon pretty much as soon as it is available. So no historic data from InfluxDB at the moment.

My energy data comes from a custom P1 reader running on an Arduino board. It sends the information via WiFi to my central MQTT broker. A node.js process is subscribed to the P1 topic. It is connected to two Toon apps that use websockets, and display the information. I like having my local outside temperature and other weather information, and current energy consumption and solar panel production numbers on my Toon 2.

MQTT and node.js run in a containers in a Docker swarm environment running on Raspberry Pi's. I have Telegraf containers that take the MQTT statistics and put them into an InfluxDB as well. I use Grafana to display the historic information.
oepi-loepi
Advanced Member
Advanced Member
Posts: 628
Joined: Sat Feb 09, 2019 7:18 pm

Re: Toon gets data from MQtt (InfluxDB)

Post by oepi-loepi »

Indeed, we introduced the webSockets to toon from version 5.33.9. The first use was the onkyo controller app which was allmost same: a Wemos board as broker between the toon websockets and the TCP eICP of Onkyo. All together packet with some udp discovery and some html to create a http page.

Websockets working very quick and only sending packets only when something has changed.

So you created an arduino app as broker between your mqtt broker and websockets as i understand and also some websocket apps on the toon?

Can you share the info?
Post Reply

Return to “Toon software development”