Both sides previous revisionPrevious revisionNext revision | Previous revision |
mqtt [2024-07-23 23:29] – river | mqtt [2025-05-07 20:09] (current) – [Misc] simon |
---|
^ Topic ^ Payload ^ Notes ^ | ^ Topic ^ Payload ^ Notes ^ |
| environment/g1/extractor | 0=off, 1=on | [[https://github.com/edinburghhacklab/circuitpython_remote_relay|Controlled]] by {{:23-10-24_21-50-40_2656.jpg?linkonly|ESP32-S2 relay board}}. Debugging feedback availble on //debug/esp-487f307d5dad// | | | environment/g1/extractor | 0=off, 1=on | [[https://github.com/edinburghhacklab/circuitpython_remote_relay|Controlled]] by {{:23-10-24_21-50-40_2656.jpg?linkonly|ESP32-S2 relay board}}. Debugging feedback availble on //debug/esp-487f307d5dad// | |
| environment/g1/heating | 0-30, off | Send a numeric value to set a target temperature for G1, off to turn the heating off | | | environment/g1/heating | 0-30, off | Send a numeric value to set a target temperature for G1, off to turn the heating off. Mark the message as retained in case the thermostat script is restarted. | |
| | environment/g2/heating | 0-30, off | Send a numeric value to set a target temperature for G2, off to turn the heating off. Mark the message as retained in case the thermostat script is restarted. | |
| environment/g8/extraction | off/on | Wall extractor in workshop | | | environment/g8/extraction | off/on | Wall extractor in workshop | |
| environment/g14/heating | 0-30, off | Send a numeric value to set a target temperature for G14, off to turn the heating off | | | environment/g14/heating | 0-30, off | Send a numeric value to set a target temperature for G14, off to turn the heating off. Mark the message as retained in case the thermostat script is restarted. | |
| espurna/g1-ceiling-air-purifier/relay/0/set | 0=off, 1=on | G1 Ceiling Air purifier (Smart Air Sqair) | | | espurna/g1-ceiling-air-purifier/relay/0/set | 0=off, 1=on | G1 Ceiling Air purifier (Smart Air Sqair) | |
| |
* test | * test |
* pixelpicker | * pixelpicker |
| * redalert |
| * emergency |
| * xmas |
| * cyber |
| * lmanberg |
| |
== Pride flags == | == Pride flags == |
| |
* lessbeans | * lessbeans / lesbinyan |
* nyanbinary | * nyanbinary |
* pan | * pan |
| * trains / trams |
| |
The LEDs can also be addressed in real time via a UDP network protocol. See [[https://gist.github.com/timhawes/910ee6b5bf9c36833235b0e075f01cbf|this example]]. | The LEDs can also be addressed in real time via a UDP network protocol. See [[https://gist.github.com/timhawes/910ee6b5bf9c36833235b0e075f01cbf|this example]]. |
| |
| The strip is controlled by ledpi.hacklab, a pi 2 in the corner of the ceiling of G1. All code is in /opt/leds/. See README there for more info. |
| |
==== G1 LED String ==== | ==== G1 LED String ==== |
These are running the WLED firmware, which is ridiculously comprehensive and can talk to basically everything. However, MQTT seems to have been disabled. | These are running the WLED firmware, which is ridiculously comprehensive and can talk to basically everything. However, MQTT seems to have been disabled. |
| |
There is a web interface at http://wled-ceiling-string.hacklab. | There is a web interface at http://wled-ceiling-string-a.hacklab. |
| |
<del>Full MQTT docs at https://github.com/Aircoookie/WLED/wiki/MQTT | <del>Full MQTT docs at https://github.com/Aircoookie/WLED/wiki/MQTT |
|||STRIP_NAME can be replaced with "dangle" for the strip dangling in G1 or "all" for every strip running this firmware in G1|</del> | |||STRIP_NAME can be replaced with "dangle" for the strip dangling in G1 or "all" for every strip running this firmware in G1|</del> |
| |
==== G1 Warning Turret ==== | ==== G1 Light Turret ==== |
| |
| See also: [[turret|Light Turret]] |
| |
^ Topic ^ Payload ^ Notes ^ | ^ Topic ^ Payload ^ Notes ^ |
| timesignal/3600 | (none) | ... | | | timesignal/3600 | (none) | ... | |
| timesignal/86400 | (none) | ... | | | timesignal/86400 | (none) | ... | |
| |
===== Christmas Tree ===== | |
| |
^ Topic ^ Payload ^ Notes ^ | |
| xmas/tree | <n> | 0=off 1=red 2=dim-red 3=green 4=yellow 5=blue 6=magenta 7=cyan 8=white 9=colour-scroll 10=colour-fade 11=christmas 12=twinkle 13=nightlight | | |
| xmas/tree | <colour> | black/red/green/... (from the [[http://webcolors.readthedocs.io|webcolors]] library) and hex RGB values (e.g. ff0000) | | |
| xmas/tree | <name> | Execute a saved script (e.g. chase, trail) | | |
| xmas/tree | JSON | Execute a script | | |
| xmas/tree/preset/<name> | JSON | Store a script for later use | | |
| |
In JSON mode, the payload is a sequence of frames and delay times. The following example would flash red/green/blue in 1000ms intervals. | |
| |
<code> | |
[ | |
[[[255, 0, 0], [255, 0, 0], ...], 1000], | |
[[[0, 255, 0], [0, 255, 0], ...], 1000], | |
[[[0, 0, 255], [0, 0, 255], ...], 1000] | |
] | |
</code> | |
| |
There are 50 pixels on our tree, so 50 RGB values should be sent in each frame. | |
| |
===== G1 Amp ===== | ===== G1 Amp ===== |
^ Topic ^ Payload ^ Notes ^ | ^ Topic ^ Payload ^ Notes ^ |
| stats/member_count | n | Number of members | | | stats/member_count | n | Number of members | |
| | time-since-last/reset | <name> | Reset "time since last" timer <name> | |
| | stock/<item-name>/in/<location>/add | <quantity> | Add <quantity> of <item-name> to <location> | |
| | stock/<item-name>/in/<location>/remove | <quantity> | Remove <quantity> of <item-name> from <location> | |
| | stock/<item-name>/in/<location>/current | <quantity> | //Read Only//: There is <quantity> of <item-name> in <location> | |
| | stock/<item-name>/in/<location>/important | 0-1 (retain) | Report when we run out of <item-name> in <location>, or are running low (see minimum below) | |
| | stock/<item-name>/in/<location>/minimum | 2-n (retain) | Report when we have fewer than <n> of <item-name> in <location> | |
| |
| |
===== TODO ===== | ===== TODO ===== |