I’m struggling with this as well. I’ve tried a cheap ch341 device as well as a ftdi device, but I can’t get any of them to work…
I hooked up pin4 to B and pin5 to A and plugged the RJ45 into the connector on the top of my VTR300. Sounds about right? Used the suggested config further up, but no luck…
For those who got it to work, how is the modbus config on the villavent unit? I noticed there is a meny under modbus which is called “gateway”, and on mine it says “not present”. Not sure what it means or if it is relevant.
Sounds to me like you are getting data. RTU is not ASCII from what I can tell, so its probably right. I don’t get anything out of my serial adapter though, so I must be doing something wrong…
For reference, I have this udev rule to create softlink, set permissions and owner for the serial device:
SUBSYSTEM==“tty”, ATTRS{idVendor}==“0403”, ATTRS{idProduct}==“6001”, OWNER=“openhab”, MODE=“0600”, SYMLINK+=“modbus”
In /etc/defaults/openhab2 I also have:
EXTRA_JAVA_OPTS="-Dgnu.io.rxtx.SerialPorts=/dev/modbus"
Which is something I understand is often necessary for making serial ports work in openhab. I have a similar setup for my zwave dongle which works, so I think this should be sufficient.
I asked system air and they said I need to connect it to the modbus port and not the control panel port, so I need to take the saw to get of the lid to connect the wires, I will see what I manage todo by the end of the month…
2017-09-30 13:47:32.390 [ERROR] [.binding.modbus.internal.ModbusSlave] - ModbusSlave (fan): Error getting modbus data for request net.wimpi.modbus.msg.ReadMultipleRegistersRequest@1eb21e1. Error: I/O exception - failed to read. Endpoint ModbusSerialSlaveEndpoint@1386d57[portName=/dev/ttyUSB0]. Connection: SerialConnection@14a68b8[portName=/dev/ttyUSB0,port=/dev/ttyUSB0]
Is wiring or USB port wrong?
I have two usb things attached:
[13:39:39] pi@openHABianPi2:~$ lsusb
Bus 001 Device 005: ID 1a86:7523 QinHeng Electronics HL-340 USB-Serial adapter
Bus 001 Device 004: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9514 Standard Microsystems Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
[13:40:36] pi@openHABianPi2:~$ sudo lsusb -t
/: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=dwc_otg/1p, 480M
|__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/5p, 480M
|__ Port 1: Dev 3, If 0, Class=Vendor Specific Class, Driver=smsc95xx, 480M
|__ Port 2: Dev 4, If 0, Class=Vendor Specific Class, Driver=usbfs, 12M
|__ Port 4: Dev 5, If 0, Class=Vendor Specific Class, Driver=ch341, 12M
[13:40:45] pi@openHABianPi2:~$ ls /dev/ttyUSB*
/dev/ttyUSB0
[13:42:12] pi@openHABianPi2:~$
After fighting with serial port problems in OH (which was caused by lgtvserial binding), I have now successfully connected my VTR300 to openhab with a FTDI USB-RS485-PCB. Modbus have been set to 9600 baud and address 1 via the control panel on the unit. I’m adding my OH config below for reference.
Number VillaventFan "Fan speed [%d]" <fan> { modbus="vvfan:0" }
Number VillaventSupplyFanRpm "Supply fan RPM [%d]" <fan> { modbus="vvfan:10" }
Number VillaventExtractFanRpm "Extract fan RPM [%d]" <fan> { modbus="vvfan:11" }
Number VillaventHeatSetpoint "Set temperature [%d]" <temperature> { modbus="vvhc:7"}
Number VillaventSupplyAirTemp "Supply air temperature [%.1f °C]" <temperature>
Number VillaventSupplyAirTemp_in "Supply air temperature [%d]" { modbus="vvhc:13" }
Number VillaventExtractAirTemp "Extract air temperature [%.1f °C]" <temperature>
Number VillaventExtractAirTemp_in "Extract air temperature [%d]" { modbus="vvhc:14" }
Number VillaventIntakeAirTemp "Intake air temperature [%.1f °C]" <temperature>
Number VillaventIntakeAirTemp_in "Intake air temperature [%d]" { modbus="vvhc:17" }
And the following rules:
import java.math.BigDecimal
rule "Correct supply air temp"
when
Item VillaventSupplyAirTemp_in changed
then
val BigDecimal ret = (VillaventSupplyAirTemp_in.state as DecimalType).toBigDecimal.movePointLeft(1)
VillaventSupplyAirTemp.postUpdate(new DecimalType(ret))
end
rule "Correct extract air temp"
when
Item VillaventExtractAirTemp_in changed
then
val BigDecimal ret = (VillaventExtractAirTemp_in.state as DecimalType).toBigDecimal.movePointLeft(1)
VillaventExtractAirTemp.postUpdate(new DecimalType(ret))
end
rule "Correct intake air temp"
when
Item VillaventIntakeAirTemp_in changed
then
val BigDecimal ret = (VillaventIntakeAirTemp_in.state as DecimalType).toBigDecimal.movePointLeft(1)
VillaventIntakeAirTemp.postUpdate(new DecimalType(ret))
end
And this in my sitemap:
Selection item=VillaventFan icon=fan mappings=[0="Off", 1="Low", 2="Medium", 3="Max"]
Selection item=VillaventHeatSetpoint mappings=[220="22 °C", 210="21 °C", 200="20 °C", 190="19 °C", 180="18 °C", 170="17 °C", 160="16 °C", 150="15 °C", 140="14 °C", 130="13 °C", 120="12° C", 0="Off"]
Text item=VillaventSupplyFanRpm
Text item=VillaventSupplyAirTemp
Text item=VillaventExtractFanRpm
Text item=VillaventExtractAirTemp
Text item=VillaventIntakeAirTemp
I am struggling to get it to work, I am afraid I did not wire it correctly. Could you please provide a picture of your setup and how you did your initial testing to see if it was wired correctly before moving to Openhab
I’ll try to take a picture over the weekend. It was sort of hard seeing what was A and B on the PCB, so I just soldered pin 4 and 5 where I though was correct and then downloaded modpoll (http://www.focus-sw.com/fieldtalk/modpoll.html) and did:
I figured my wiring was incorrect, so I switched the wires and tried again. This time I had a constant stream of this:
-- Polling slave... (Ctrl-C to stop)
[101]: 2
Which basically tells you that register 101 has a value of 2, which was correct. Just remember to have openhab2 service stopped when you do this so that your current config does not interfere with the communication.
After this I moved straight on to openhab where it worked out of the box after I added the config and restartet openhab.
Earlier I had a cheap dongle using ch341 driver, but I could never get that to work. Not sure if it was hardware or driver related, but I did read online that many people have issues with devices using the ch341 driver. I knew that a FTDI device would never let me down, so that’s why I bought the dongle I use now.
I also have Thessla Green. Today I received Modbus User Guide and I agree it looks clear. Tell me which commands (registers) do you use (or did you try) to control it – seems “airFlowRateManual” looks perfect for it in manual mode. Is RS485 your only way to control it or you use it together with i.e. Air++ simultaneously?
I use many of them like mode, season, flow, program, temperatures, fun voltage, heater (PWM), etc. I don’t remember Thessla’s names, since in config you just operate on registers. If you will be able to config one item/register then they rest is simple.
Air++ works together with OH without a problem, so all parameters can be read or change via both channels
Hi gskjold. I´m facing some trouble locating the modbus pins on my systemair VR400, which have a very similar PCB as your unit. Could you provide a picture of the soldering or a description of the location?
On my PCB the only RJ-plugs are for manual control…
Hi, Attached below is an overview of the pcb in my unit. I have a RJ45 for my modbus connection and a RJ11 for the control panel. The only place on the terminals I can find A and B is for the control panel connection which I find weird. I think someone commented in this thread that this connection could not be used for modbus, but maybe worth a try? I am lifting the unit off the wall today to paint the room. I can have a closer look at my PCB then. But I would definitely look for terminals marked with modbus or “A” and “B” in your case. VR400 is supported for modbus, so there must be a way to connect it.
Had it open today, but there is no real way of telling how the RJ45 is connected on the PCB without removing it. I suggest contacting systemair and ask them how to connect to modbus on your unit. They have been helpful with me in the past, so I think they will help you out.