@@ -37,7 +37,8 @@ debian this is available from the `python3-paho-mqtt` package.
3737
3838 The name of HAL pins, signals and other values to publish using
3939 MQTT. The names are also used as the JSON keys in the MQTT
40- message published with the broker.
40+ message published with the broker. If multiple "keys=" options
41+ are specified, the lists are merged.
4142
4243*--dryrun*::
4344
@@ -94,22 +95,33 @@ The loop reading HAL values and publishing MQTT messages.
9495Any set of HAL pins and signals can be published. This setup might be
9596a useful starting point:
9697
97- loadusr -W mqtt-publisher [MQTT]DRYRUN --mqtt-broker=[MQTT]BROKER
98- --mqtt-user=[MQTT]USERNAME --mqtt-password=[MQTT]PASSWORD
99- keys=halui.axis.a.pos-feedback,halui.axis.b.pos-feedback,
100- halui.axis.c.pos-feedback,halui.axis.u.pos-feedback,
101- halui.axis.v.pos-feedback,halui.axis.w.pos-feedback,
102- halui.axis.x.pos-feedback,halui.axis.y.pos-feedback,
103- halui.axis.z.pos-feedback,halui.estop.is-activated,
104- halui.joint.0.is-homed,halui.joint.1.is-homed,halui.joint.2.is-homed,
105- halui.joint.3.is-homed,halui.joint.4.is-homed,halui.joint.5.is-homed,
106- halui.joint.6.is-homed,halui.joint.7.is-homed,halui.joint.8.is-homed,
107- halui.machine.is-on,halui.max-velocity.value,halui.mode.is-auto,
108- halui.mode.is-manual,halui.mode.is-mdi,halui.mode.is-teleop,
109- halui.program.is-running'
110-
111- Note, the list of keys can not include space after comma. The lines
112- are only broken here to avoid too long lines in the documentation.
98+ ----
99+ loadusr -W mqtt-publisher \
100+ [MQTT]DRYRUN \
101+ --mqtt-broker=[MQTT]BROKER
102+ --mqtt-user=[MQTT]USERNAME \
103+ --mqtt-password=[MQTT]PASSWORD \
104+ keys=halui.axis.a.pos-feedback,halui.axis.b.pos-feedback,\
105+ halui.axis.c.pos-feedback,halui.axis.u.pos-feedback,\
106+ halui.axis.v.pos-feedback,halui.axis.w.pos-feedback,\
107+ halui.axis.x.pos-feedback,halui.axis.y.pos-feedback,\
108+ halui.axis.z.pos-feedback \
109+ keys=halui.estop.is-activated, halui.joint.0.is-homed,\
110+ halui.joint.1.is-homed,halui.joint.2.is-homed,halui.joint.3.is-homed,\
111+ halui.joint.4.is-homed,halui.joint.5.is-homed,halui.joint.6.is-homed,\
112+ halui.joint.7.is-homed,halui.joint.8.is-homed \
113+ keys=halui.machine.is-on,halui.max-velocity.value,halui.mode.is-auto,
114+ halui.mode.is-manual,halui.mode.is-mdi,halui.mode.is-teleop,
115+ halui.program.is-running
116+ ----
117+
118+ Note: It is recommended to use the line continuation character "\" as
119+ shown here to improve readability. But note that spaces must be left in
120+ to delimit options, and must not be included (including at the beginning
121+ of a line) inside a single option.
122+
123+ HAL limits a single option/token (for example "keys=") to 255 characters.
124+ To work around this issue use multiple "keys=" entries as shown.
113125
114126== SEE ALSO
115127
0 commit comments