Mqtt_room and Shelly gen2 (Shelly Plus 1PM) - presence detection

hi everyone, I try to integrate my new shelly gen2 device as ble monitor to check if some device in at the room.
my first try, to scan with an custom mqtt-room script and send this information to HA (works fine) but I’m not able to integrate mqtt_room in my HA configuration
my goal would be, according the specified room (topic) and respective signal strength locate my mobile device
are there anyone who have a running and successful setup

Update: MQTT room presence - Home Assistant integration direct in my configuration.yaml does not work

What do you mean by “works fine”? Show us what you’re getting including MQTT messages and sensors states in HA.

ok i got messages from shelly device, only IDs not Name, but i got it.

Shelly Console Output:

Bildschirmfoto 2024-04-10 um 16.39.33

MQTT Topic listend

so in my opinion mqqt works, but if i try to configure mqtt_home to define entities i’m not able to get this to work

there is no possibility to add this in my configuration.yaml, because i split the sensors

configuration.yaml

mqtt:
    sensor: !include_dir_merge_list mqtt/sensor
    binary_sensor: !include_dir_merge_list mqtt/binary_sensor
    switch: !include_dir_merge_list mqtt/switch


configuration example :
########################################. mqtt_room ################################

/homeassistant/mqtt/sensor/sensor.yaml

- platform: mqtt_room
  device_id: 123testid
  state_topic: "espresense/devices/123testid"

I got this error

Don’t put it under mqtt: heading. Look at the example:

# Example configuration.yaml entry
sensor:
  - platform: mqtt_room
    device_id: 123testid
    state_topic: "espresense/devices/123testid"

It’s under sensor:, not under mqtt: then sensor:.

Hi, the Bermuda BLE Trilateration project could be better solution to use Shelly Plus devices as BT proxy. (GitHub - agittins/bermuda: Bermuda Bluetooth/BLE Triangulation / Trilateration for HomeAssistant) In this case, you don not need to setup any custom Shelly script because the built in HA script enough. Moreover, you do not need to use it via MQTT because the Bermuda project is an integration into HA and communicate with the Shelly devices via the native Shelly integration (which is not MQTT). I only use ESPresence project to get the IRK for Apple devices and I also use the HA’s builtin “Private BLE Device” integration to handle Apple BLE privacy… All solution is very simple. I hope it helps.