I used a different solution based on the Exec-Binding. So no need for a second OH2.5 instance. It is not as easy as the mochad binding but works quite fine for me.
What you need:
- exec binding
- shell script called by exec binding
- three generic X10 items for exec in, exec out and exec run
- one generic X10 rule for triggering the binding
- one specific rule for each specific X10 item
I’ll just explain the pretty easy way of switching lights on an off. But if you are able to write shell scripts, the world is open to you 
To be honest, I don’t like the openhab documentation at all, it is not easy to understand, but nevertheless, first have a look here:
But now, lets do the magic, step by step…
-
Add the exec binding
-
Add a thing based on the exec binding. Configuration:
Command: “/usr/local/bin/OH3_X10_Mochad_Switch %2$s”
Transformation: “REGEX((.*))”
Intervall: 0
Timeout: 15
Autorun: off
-
Add three string items:
X10_Out
X10_In
X10_Run
Nothing to configure, but it is important, that these are string items
-
Go to Exec-Binding Thing and edit Channel:
Link Output to X10_Out item
Link Input to X10_In item
Link Run to X10_Run item
-
Go to Rules. Add a Rule called “X10_Run”
“When X10_in received a command, execute a given script”
The script:
if (X10_Run.state != ON) {
X10_Run.sendCommand(ON)
// the Run indicator state will go ON shortly, and return OFF when script finished
}else{
logInfo("Your command exec", "Script already in use, skipping execution.")
}
- Create your shellscript named “OH3_X10_Mochad_Switch”, here just my example for using NC to control mochad:
#!/bin/bash
echo "pl $1 $2" | nc localhost 1099 >/dev/null
-
Add the following line to “/etc/openhab/misc/exec.whitelist”:
/usr/local/bin/OH3_X10_Mochad_Switch %2$s
-
Add an Item for every X10 switch you want to control. e.g. “X10_Lamp_Bathroom”, type Switch.
-
Add a rule for every X10 switch you want to control, e.g.
“X10_Lamp_Bathroom_Rule”:
“When X10_Lamp_Bathroom changed, execute a given script”
The script:
if(X10_Lamp_Bathroom.state == ON){
X10_In.sendCommand("C1 ON")
}else{
X10_In.sendCommand("C1 OFF")
}
The magic: The specific rule sends a command to X10_In, when a switch is changed. The X10_In triggers the Exec-Thing with the input parameters (X10 Addresses). The The Exec-Thing triggers the the X10_Run item and calls the shell-Script, if not running.
For switching X10 lamps this is completely sufficent. If you want to react on mochad output, you have to add rules for X10_out item.
So, for adding new lamps/switches you now just need to do step 8 and 9.
For me that works fine and easy and no need to host a separate OH instance… Add metadata to your X10-Switch-Items to make them visible for Alexa, Siri, etc…