Connect Sonoff PIR to OpenHAB2 with MQTT

  • Platform information:
    • Hardware: _Core i3/12/500GB SSD
    • OS: Windows 10 latest build
    • Java Runtime Environment:Java™ SE Runtime Environment (build 1.8.0_171-b11)
    • openHAB version:2.4
  • Issue of the topic: hello, I’m actually new to openhab, I really need the specific steps and configuration to connect sonoff PIR motion sensor to openhab2 with MQTT. I started openHAB2 service and chose PaperUI.
    I can’t find any related project.
    Thank you .

Start from the beginning
How in the data from the PIR going to arrive at openHAB

The Sonoff PIR send data on the 433MHz band
Do you have a receiver?

The PIR is connected to arduino, and the arduino uno is connected to openHAB2 server (windows) via ethernet shield on the arduino

Using what protocol?
If yes what topic and payload are used?

we are trying to connect PIR with arduino to openHAB using MQTT protocol.the openHAB should trigger a switch through the result getting from the PIR motion.

Is the Arduino publishing mqtt message?
If yes what topic and payload are used?