Just installed the mqtt extension
https://github.com/weewx/weewx/wiki/mqtt and configured the /etc/weewx/weewx.conf file
[[MQTT]]
server_url = "mqtt://mqtt-local:<password-hidden-here>@homeassistant.local:1883"
topic = weewx
unit_system = METRIC
But the broker does not receive any message on this topic.
Checking the log files everything looks fine:
Dec 28 18:34:49 raspberrypi systemd[1]: Starting LSB: weewx weather system...
Dec 28 18:34:52 raspberrypi weewx[31732] INFO __main__: Initializing weewx version 4.2.0
Dec 28 18:34:52 raspberrypi weewx[31732] INFO __main__: Using Python 3.7.3 (default, Dec 20 2019, 18:57:59) #012[GCC 8.3.0]
Dec 28 18:34:52 raspberrypi weewx[31732] INFO __main__: Platform Linux-4.19.97+-armv6l-with-debian-10.3
Dec 28 18:34:52 raspberrypi weewx[31732] INFO __main__: Locale is 'de_DE.UTF-8'
Dec 28 18:34:52 raspberrypi weewx[31732] INFO __main__: PID file is /var/run/weewx.pid
Dec 28 18:34:52 raspberrypi weewx[31720]: Starting weewx weather system: weewx.
Dec 28 18:34:52 raspberrypi systemd[1]: Started LSB: weewx weather system.
Dec 28 18:34:52 raspberrypi weewx[31736] INFO __main__: Using configuration file /etc/weewx/weewx.conf
Dec 28 18:34:53 raspberrypi weewx[31736] INFO __main__: Debug is 0
Dec 28 18:34:53 raspberrypi weewx[31736] INFO weewx.engine: Loading station type TE923 (weewx.drivers.te923)
Dec 28 18:34:53 raspberrypi weewx[31736] INFO weewx.drivers.te923: driver version is 0.41.1
Dec 28 18:34:53 raspberrypi weewx[31736] INFO weewx.drivers.te923: polling interval is 10
Dec 28 18:34:53 raspberrypi weewx[31736] INFO weewx.drivers.te923: sensor map is {'windLinkStatus': 'link_wind', 'windBatteryStatus': 'bat_wind', 'rainLinkStatus': 'link_rain', 'rainBatteryStatus': 'bat_rain', 'uvLinkStatus': 'link_uv', 'uvBatteryStatus': 'bat_uv', 'inTemp': 't_in', 'inHumidity': 'h_in', 'outTemp': 't_1', 'outHumidity': 'h_1', 'outTempBatteryStatus': 'bat_1', 'outLinkStatus': 'link_1', 'extraTemp1': 't_2', 'extraHumid1': 'h_2', 'extraBatteryStatus1': 'bat_2', 'extraLinkStatus1': 'link_2', 'extraTemp2': 't_3', 'extraHumid2': 'h_3', 'extraBatteryStatus2': 'bat_3', 'extraLinkStatus2': 'link_3', 'extraTemp3': 't_4', 'extraHumid3': 'h_4', 'extraBatteryStatus3': 'bat_4', 'extraLinkStatus3': 'link_4', 'extraTemp4': 't_5', 'extraHumid4': 'h_5', 'extraBatteryStatus4': 'bat_5', 'extraLinkStatus4': 'link_5'}
Dec 28 18:34:53 raspberrypi weewx[31736] INFO weewx.drivers.te923: Found device on USB bus= device=
Dec 28 18:34:55 raspberrypi weewx[31736] ERROR weewx.drivers.te923: Failed attempt 1 of 5 to read data: [Errno 110] Operation timed out
Dec 28 18:34:58 raspberrypi weewx[31736] INFO weewx.drivers.te923: logger capacity 208 records
Dec 28 18:34:58 raspberrypi weewx[31736] INFO weewx.drivers.te923: station time is 1582844400.0, computer time is 1609176898
Dec 28 18:34:58 raspberrypi weewx[31736] INFO weewx.engine: StdConvert target unit is 0x1
Dec 28 18:34:58 raspberrypi weewx[31736] INFO weewx.engine: Archive will use data binding wx_binding
Dec 28 18:34:58 raspberrypi weewx[31736] INFO weewx.engine: Record generation will be attempted in 'hardware'
Dec 28 18:34:58 raspberrypi weewx[31736] INFO weewx.engine: Using archive interval of 300 seconds (specified in weewx configuration)
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.restx: StationRegistry: Registration not requested.
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.restx: Wunderground-PWS: Data for station IBADENWR90 will be posted
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.restx: PWSweather: Posting not enabled.
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.restx: CWOP: Posting not enabled.
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.restx: WOW: Posting not enabled.
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.restx: AWEKAS: Posting not enabled.
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: service version is 0.23
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: binding to archive
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: topic is weewx
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: desired unit system is METRIC
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: data will be uploaded to mqtt://mqtt-local:x...@homeassistant.local:1883
Dec 28 18:34:59 raspberrypi weewx[31736] INFO __main__: Starting up weewx version 4.2.0
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.engine: Using binding 'wx_binding' to database 'weewx.sdb'
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.manager: Starting backfill of daily summaries
Dec 28 18:34:59 raspberrypi weewx[31736] INFO weewx.drivers.te923: reading records from logger since 1609176600
Dec 28 18:35:00 raspberrypi weewx[31736] INFO weewx.drivers.te923: read 0 records from logger
Dec 28 18:35:00 raspberrypi weewx[31736] INFO weewx.engine: Starting main packet loop.
the "loop" also reports success
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: service version is 0.23
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: binding to archive
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: topic is weewx
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: desired unit system is METRIC
Dec 28 18:34:59 raspberrypi weewx[31736] INFO user.mqtt: data will be uploaded to mqtt://mqtt-local:x...@homeassistant.local:1883
manual testing with same settings works fine:
pi@raspberrypi:~ $ mosquitto_pub -h homeassistant.local -m "my personal weewx message" -t weewx -u mqtt-local -P <password-hidden-here> -d
Client mosqpub|31800-raspberry sending CONNECT
Client mosqpub|31800-raspberry received CONNACK (0)
Client mosqpub|31800-raspberry sending PUBLISH (d0, q0, r0, m1, 'weewx', ... (25 bytes))
Client mosqpub|31800-raspberry sending DISCONNECT
same with root user
pi@raspberrypi:~ $ sudo mosquitto_pub -h homeassistant.local -m "my personal root weewx" -t weewx -u mqtt-local -P <password-hidden-here> -d
Client mosqpub|31809-raspberry sending CONNECT
Client mosqpub|31809-raspberry received CONNACK (0)
Client mosqpub|31809-raspberry sending PUBLISH (d0, q0, r0, m1, 'weewx', ... (22 bytes))
Client mosqpub|31809-raspberry sending DISCONNECT
Any ideas what I did wrong here?