Mqtt Sonoff bridge

Hi.
i’m trying to config my sonoff bridge with mqtt,

-flashed bridge with tasmota.
seems to work fine- reciving data from motion sensor.
-started mosqitto mqtt. at the logs i see that the Sonoff has connected

1573823774: New connection from 10.0.0.6 on port 1883.
[INFO] found nir on Home Assistant
1573823775: New client connected from 10.0.0.6 as RF_Bridge (p2, c1, k30, u'nir')

an config.yaml

i have:
mqtt:
Broker: 10.0.0.33
Port: 1883
discovery: true
discovery_prefix: homeassistant

binary_sensor:

    - platform: mqtt
      state_topic: 'tele/RF_Bridge/RESULT'
      name: 'window'
      value_template: '{{value_json.RfReceived.Data}}'
      payload_on: '1CE2DA'
      payload_off: '1CE2DAoff'
      device_class: motion
      optimistic: false
      qos: 1
      retain: false

but i cand make it apper on lovlace, or at the entity list.

never worked with mqtt before…
what am i doing wrong?

Just add it like any love lace card

show_header_toggle: false
title: Movement
type: entities
entities:
  - entity: binary_sensor.main_motion
  - entity: binary_sensor.front_door_motion
  - entity: binary_sensor.front_motion
  - entity: binary_sensor.garage_door_motion
  - entity: binary_sensor.desk_motion
  - entity: binary_sensor.laundry_motion
  - entity: binary_sensor.basement_motion

I would recommend taking a look at this post for setting up the Sonoff RF Bridge. The way you have it now is easy for 1 or 2 devices however it starts to be come hard to manage when you get more.

If you use NodeRed this new solution can be done completely in it, with the import near the bottom of the thread.

I can’t add it because the binary sensor option not appear at all…

I know that if some entities add to the config.yaml file, I can find them easily at the GUI.

Am I missing something?

Can you give me an example for yaml config for it?
My bridge name is’ rf_bridge. And my sensor name is “motion1”

My binary sensor is just like this

binary_sensor:
  - platform: mqtt
    name: 'Basement Window'
    state_topic: 'home/BasementWindow'

Based on your post above your entity will be called binary_sensor.window.

You have rebooted after adding this to your configuration.yaml right.

HI all.
Thank you for the support!

I think that my problem is at the MQTT service, no entity appear, and at the services tab I have “mqtt.publish”’ and i have MQTT tab.

at the configuration file i have:

mqtt: 
 Broker: 10.0.0.33
 Port: 1883
 discovery: true
 discovery_prefix: homeassistant

mqtt service logs:

[10:47:42] INFO: Setup mosquitto configuration
[10:47:42] INFO: No local user available
[10:47:43] INFO: Initialize Hass.io Add-on services
[10:47:43] INFO: Initialize Home Assistant discovery
[10:47:43] INFO: Start Mosquitto daemon
1573894063: Loading config file /share/mosquitto/acl.conf
1573894063: mosquitto version 1.6.3 starting
1573894063: Config loaded from /etc/mosquitto.conf.
1573894063: Loading plugin: /usr/share/mosquitto/auth-plug.so
1573894063: |-- *** auth-plug: startup
1573894063: ├── Username/password checking enabled.
1573894063: ├── TLS-PSK checking enabled.
1573894063: └── Extended authentication not enabled.
1573894063: Opening ipv4 listen socket on port 1883.
1573894063: Opening ipv6 listen socket on port 1883.
1573894063: Opening websockets listen socket on port 1884.
1573894063: Opening ipv4 listen socket on port 8883.
1573894063: Opening ipv6 listen socket on port 8883.
1573894063: Opening websockets listen socket on port 8884.
1573894063: Warning: Mosquitto should not be run as root/administrator.
1573894064: New connection from 172.30.32.1 on port 1883.
1573894065: Socket error on client , disconnecting.
1573894065: New connection from 172.30.32.1 on port 1883.
[INFO] found homeassistant on local database
1573894066: New client connected from 172.30.32.1 as auto-C8A1CDDB-1A77-3F2D-9F6C-BE313CDA1101 (p2, c1, k60, u’homeassistant’).
1573894067: New connection from 10.0.0.6 on port 1883.
[INFO] found nir on Home Assistant
1573894069: New client connected from 10.0.0.6 as RF_Bridge (p2, c1, k30, u’nir’).

tasmota sonoff logs:

00:00:00 CFG: Loaded from flash at F7, Count 29
00:00:00 APP: Set Baudrate to 19200
00:00:00 Project sonoff RF_Bridge Version 6.7.1(sonoff)-STAGE
00:00:00 WIF: Connecting to AP1 Lagziel in mode 11N as RF_Bridge-2885…
00:00:05 WIF: Connected
00:00:05 HTP: Web server active on RF_Bridge-2885 with IP address 10.0.0.6
09:22:45 MQT: Attempting connection…
09:22:47 MQT: Connected
09:22:47 MQT: tele/RF_Bridge/LWT = Online (retained)
09:22:47 MQT: cmnd/RF_Bridge/POWER =
09:22:47 MQT: tele/RF_Bridge/INFO1 = {“Module”:“Sonoff Bridge”,“Version”:“6.7.1(sonoff)”,“FallbackTopic”:“cmnd/RF_Bridge_fb/”,“GroupTopic”:“sonoffs”}
09:22:47 MQT: tele/RF_Bridge/INFO2 = {“WebServerMode”:“Admin”,“Hostname”:“RF_Bridge-2885”,“IPAddress”:“10.0.0.6”}