Very confused with Owntracks / OH2

Hey guys,

I’m trying to setup Owntrack, but I’m very confused. I think I’m hitting a bug where an old configuration item is messing around with my config.

A couple of questions:

  • Do I need to configure anything in mqtt-eventbus? So far, Owntracks is the only app using mqtt.
  • I did set up everything, but I’m getting an error message from an older attempt to configure everything ([ng.mqtt.internal.MqttEventBusBinding] - Unable to find item XXXXXXX for update; dropping)
  • Finally: does anyone have Owntracks and iBeacons working? Looking for a demo setup of this as well.

I’ve checked the forum extensively, but haven’t found a proper solution yet.

Thanks in advance!

1 Like

you should not have to configure anything in the mqtt-eventbus config. honestly, you don’t even have to edit the mqttitude.cfg file either. please answer a few questions…

  1. have you tested to ensure your mqtt binding is working? (simple item, say switch and some mosquitto_pub commands from the terminal of the host or another host on your network)
  2. if your binding is working, the next step would be to port forward 1883 (i’d use some obscure port as the external and map to your server on 1883 internally until you get around to setting up tls), open the owntracks app and add your public ip and external port to your settings. you should get a “connected” message if your port is forwarded, your broker is up and running, and the app can find your broker.
  3. enter mosquitto_sub -t owntracks/# -d on your mosquitto server (or add the -h [host ip] to the command to link up with it. go back to your app and submit a manual location message (ios app is the sharing up arrow [i think] when on the map/location page)
  4. if the above steps result in messages being published to your broker WE’RE IN BUSINESS! let me know and i’ll help with the last bit (items, sitemap, ios/android region setup, and a presense switch).

Thanks for responding! Much appreciated!!!

I’ve reinstalled my Pi and Openhab since there were some other issues that might be related. Everything looks a little more promising…

To answer your questions:

  1. I did install mqtt and mqttitude, and I’m getting a happy message: 'Starting MQTT broker connection ‘cloudmqtt’. No errors.
  2. and 3. I’m using an external server (cloudmqtt). When I use mosquitto_pub (on same Pi) messages are showing up.
  3. Looks like we’re in business…

Current situation: receiving messages. One of the switches is actually updating, but with a “cheat”. It currently responds to any message send to my device.

in Items:
Switch Presence_Me_Living "Me @ Living" { mqttitude="cloudmqtt:owntracks/ID/PHONE" }

This updates the switch, but… I have 2 location that I want to use. One is GPS and one is an iBeacon.

I would expect the following to work:

Switch  Presence_Me_Home "Me @ Home" {mqttitude="cloudmqtt:owntracks/ID/PHONE/event:home" }

but it doesn’t :frowning: Whenever I update, the log screen doesn’t show any switch updating like it does when I use the previous one.

I’ve looked all over, but many of the errors were Openhab 1. I’m using Openhab 2 which seems to use different parameters.

Hope you can crack this. This is one of the things that Home Assistant does WAY better than OH. That being said: most Openhab features absolutely POWN HA…