No-code LaMetric CheerLights with MQTT

A while ago I wrote a CheerLights app for the LaMetric clock, except that you can’t actually really write apps for it,— you just define a sort of catalogue entry for somewhere the clock is going to fetch data from, or in the case of the CheerLights app, the clock gets notified of updates. The actual code needs to run on a server somewhere. Unfortunately the first couple of free cloud compute options I used for running the little app to subscribe to the CheerLights MQTT topic have gone away, and the current server got stopped for not doing enough a while ago!

Fortunately I don’t need to find a new home for the CheerLights server because LaMetric finally implemented an eight year old request to support MQTT, and it actually works very nicely indeed!

Screenshot of the icons screen in My Data DIY

MQTT support was added to the My Data DIY LaMetric app and, even better, it comes with no-code capabilities which means you don’t need a server anywhere to massage the data into the usual LaMetric format!

Unfortunately it doesn’t look like it’s possible to export, import, or share My Data DIY configuration but to add your own CheerLights app, these are the settings you need.

Type: MQTT Channel

MQTT Config

Host: mqtt.cheerlights.com

Port: 1883

Use TLS: off

Topic: cheerlights

Data Format: Any (JSON or XML)

Frames

Name: CheerLights

Frame Type: Data

Text: {#}

That’s all you should need to display the CheerLights colour names. You can also add different icons that depend on the data received, unfortunately you can only have a maximum of 10 conditional icons which seems really stingy to me. There are, for example, 11 supported CheerLights colours! Fortunately the My Data DIY lets you have one more default icon, which is just enough to cover all 11 CheerLights colours!

The CheerLightsRed icon rule in My Data DIY

For example, the icon rule for red has these settings.

Icon: CheerLightsRed

Field: {#}

Function: Equals(==)

Value: red

There are predefined icons for all the colours from the old CheerLights app, and you just need to use the default icon for the final colour.

Now I just need to work out what to with the old app. It’s definitely easier to install instead of all the configuration required for the My Data DIY app, but it needs a new home for the server again. On the other hand, it definitely wouldn’t be worth keeping around if there was a simple way to share My Data DIY settings.

Leave a comment