Skip to content
balk77 edited this page Feb 15, 2024 · 3 revisions

MQTT topic structure

This page contains the MQTT reference topics for communication between ha-button-plus and the actual Button+ device.

Main display

The Button+ main display can have several display items, listening to MQTT topics for its configuration. Currently, Button+ only listens to the value topic but that may change in the future. Each of these attributes have individual MQTT broker setting.

Attribute Topic Eventtype Future Home Assistant
Value buttonplus/<deviceID>/display/<sequence number>/value 15 sensor
Label above the value buttonplus/<deviceID>/display/<sequence number>/label 16 x sensor attribute
Unit of measurement buttonplus/<deviceID>/display/<sequence number>/uom 17 x sensor attribute

Each display item has additional attributes which can be set in the Button+ software. These attributes are available in Home Assistant as an attribute of the sensor.

Attribute Description Home Assistant Implemented?
x Horizontal postion of the item within the lcd (in % of the display width) sensor attribute n
y Vertical postion of the item within the lcd (in % of the display width) sensor attribute n
fontsize Smallest size is 1, largest size is 4 sensor attribute n
width Width of the item in % of display width sensor attribute n
round Round the incoming payload to decimal places, 0 is round to whole numbers sensor attribute n
Alignment numeric: sensor attribute n
0 Top Left
1 Top Center
2 Top Right
3 Center Left
4 Center Center
5 Center Right
6 Bottom Left
7 Bottom Center
8 Bottom Right

Naming convention

Naming convention for the display item sensors: sensor.<deviceID>_displayitem_<sequence number>

Buttons

Each button has a button, a display a front LED and a wall LED. The device will publish topics (P) and subscribe to topics (S). The button state can be pressed, released, double_click, triple_click, long_press.

Attribute Topic P/S value Home Assistant
click buttonplus/<deviceID>/button/<buttonID>/state P text sensor
label buttonplus/<deviceID>/button/<buttonID>/label S text attribute
toplabel buttonplus/<deviceID>/button/<buttonID>/toplabel S text attribute
unit buttonplus/<deviceID>/button/<buttonID>/uom S text attribute
label buttonplus/<deviceID>/button/<buttonID>/label S text attribute
led_front buttonplus/<deviceID>/button/<buttonID>/led_front S true/false attribute
ledcolorfront buttonplus/<deviceID>/button/<buttonID>/ledcolorfront S decimal color (for instance 15140872) attribute
led_wall buttonplus/<deviceID>/button/<buttonID>/led_wall S true/false attribute
ledcolorwall buttonplus/<deviceID>/button/<buttonID>/ledcolorwall S decimal color (for instance 15140872) attribute
button state Issued when Implemented
press Button is pressed (no matter how long, on press) Implemented
release Button is released (no matter after how long/often) Implemented
double_click Button is pressed twice in short time Future
triple_click Button is pressed three times in short time Future
longpress Button is held for n seconds Implemented

Naming convention

Naming convention for the button binary_sensors: binary_sensor.<deviceID>_button_<buttonID>

General

General topics for the Button+ are the following:

Attribute Topic P/S value Home Assistant
name
location
temperature buttonplus/<deviceID>/sensors/temperature P number sensor

Naming convention

Naming convention for the general sensors: sensor.<deviceID>_temperature