Expert help with modbus binding and Schneider Modicon PLC

Current situation:

The Schneider M221 PLC (see config attached) controls my lights. I’ve switches on the inputs of the PLC. Some of the outputs direct activates my lights and some outputs control some 5V relays.
I’ve had help programming the PLC, so my knowledge about PLC and Modbus is very poor.

OH 2.2 is running on an micro PC with Win10.

Also i’ve some z-wave devices up and running (dimmers and multi-sensor)

Problem:

I want to keep using my plc to control the lighting in case OH stops running.
OH has to control the outputs of the PLC and also use the inputs.
The ouput of the plc can be triggered by a switch or an sensor (Rules)
Actions on OH can be triggered by input of the PLC (switch) (all active lights off)
I like to combine the functionality of both OH and PLC

I’ve tried an setup with modbus tools slave simulator on other laptop and succeeded in read/write coils and read digital inputs.

Only if I change to the M221 plc nothing happens (with correct settings). Does anyone has some experience with Schneider PLC and modbus?

I’m using the binding of Sami Salonen and tried to program via PaperUI. @ssalonen

hi jakke17

i’m new in openhab. and i tried to make something similiar with your project. can i see your attachment pls ? there is no attachment in your post. thanks b4

@randipandu, see pdf attached.Schneider M221.pdf (908.6 KB)

thanks @Jakke17. you helped me a lot :slight_smile: