Using MQTT/Nmap but no known_devices.yaml

Hi all,

Just starting out with Home Assistant and attempting to get the device tracking working to do some automations based on devices being home or not.

Anyway, attempting to use MQTT and I’ve followed the component guides on here and a couple of forum posts but I cannot seem to get it working.

I have the inbuilt MQTT broker running, and the config confirms this. I’ve then used Zanzito to connect to my MQTT broker and from what I’ve read, Home Assistant should then create a file of known devices, but this doesn’t seem to be happening.
I also have Nmap on in the configuration, and again, no new device file.

Can anyone point out where I’m going wrong and either provide a solution, or point to the relevant docs?

Thanks!

show us what you have done and we help

1 Like

ok, so

configuration.yaml

# MQTT
mqtt:
  broker: !secret mqtt_broker
  username: !secret mqtt_username
  password: !secret mqtt_password

mqtt_statestream:
  base_topic: homeassistant

includes/device_trackers.yaml
############################################################
#
# Home Assistant device trackers
#
############################################################

device_tracker:
  - platform: mqtt
    devices:
      sean_s8: location/sean
      kelly_s8: location/kelly

############################################################
#
# Home Assistant Other Trackers
#
############################################################

- platform: nmap_tracker
  hosts: !secret nmap_hosts
  home_interval: 10

Thanks!

next I would install

mqttfx This will let you see the MQTT traffic

1 Like

Will get this downloaded onto my Windows machine this evening and will let you know how I get on.

Once installed point it to the ha server

All installed
Can see the client connect in the Mosquitto log in Home Assistant:
1518502889: Client MQTT_FX_Client disconnected.
1518502913: New connection from 192.168.255.x on port 1883.
1518502913: New client connected from 192.168.255.x as somerandomhasnowhidden (c1, k60, u’wosak-mqtt’).

I also tested with the the Zanzito application, and again is connecting, so not sure why the list of devices is not showing.

@myle any further thoughts?

no

all i did was Run MQTT.fx

connect to the server HA which Im using the BUILT in one
and Subscribe to some topic and it work