Hi all OH3 fans,
I’m migrating from OH 2.5.11 to OH 3.0.0 on a docker based setup and have trouble with the serial communication with my Vantage domotic system.
On the same debian buster, by just switching OH containers
- OH 2.5.11 serial communication runs fine
- OH 3.0.0 serial reception is ok, transmission seems to block/ignore the terminating ‘\r’
The communication is simple: in ASCII, just send ex. ‘VGC 2 3 5’ + ‘\r’ and the Vantage will reply with the load settings (all commands look similar).
OH 3.0.0 configuration:
serial.things (simplest form possible, without serialDevice)
Bridge serial:serialBridge:port0 [serialPort="/dev/ttyUSB0", baudRate=19200, charset="ASCII"]
vantage.items
String Vantage "Vantage [%s]" { channel="serial:serialBridge:port0:string" }
// Test button
Switch VantageTest
vantage.rules (I push on the VantageTest via HABPanel)
rule "vantageTest"
when
Item VantageTest changed
then {
logInfo("vantage", "Vantage Test ....")
Vantage.sendCommand("VGC 2 3 5\r")
}
end
On OH 2.5.11, Vantage answers promptly and the String Vantage contains the result.
On OH 3.0.0, Vantage does not answer, the ‘\r’ does not seem to be transmitted over the wire…
Working OH 2.5.11 config:
vantage.items:
String Vantage "Vantage [%s]" { serial="/dev/ttyUSB0@19200,CHARSET(ASCII)" }
// Test button
Switch VantageTest
No serial.things, vantage.rules identical as above.
When I run the openhab (OH 2.5.11) container, it works.
When I run the openhab (OH 3.0.0) container, it does not work.
Note: Vantage returns by itself also status information. On both OH versions this information is received in the Vantage String variable as expected, with no issues.
Are ‘\r’ not part of a String anymore in OH3? or stripped somewhere?
Any clue?
Can I somehow enable more serial debugging? (I have tried log.set DEBUG ROOT, log.set DEBUG org.openhab.binding.serial, …)
Many thanks and OH3 rocks, what a major step, congrats to everyone.