I get an error in the Bridge settings (.things file).
This is the thing file:
Bridge modbus:serial:myNilan [ port="ttyUSB-RS486", id=30, baud=19200, stopBits=1, parity="even", dataBits=8, encoding="rtu" ] {
// here will go any pollers
}
This is the error:
018-12-16 00:01:18.434 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'nilan.things'
==> /var/log/openhab2/events.log <==
2018-12-16 00:01:18.541 [hingStatusInfoChangedEvent] - 'modbus:serial:myNilan' changed from UNINITIALIZED to INITIALIZING
==> /var/log/openhab2/openhab.log <==
2018-12-16 00:01:18.542 [WARN ] [me.config.core.internal.ConfigMapper] - Could not set field value for field 'stopBits': Can not set java.lang.String field org.openhab.binding.modbus.internal.config.ModbusSerialConfiguration.stopBits to java.math.BigDecimal
java.lang.IllegalArgumentException: Can not set java.lang.String field org.openhab.binding.modbus.internal.config.ModbusSerialConfiguration.stopBits to java.math.BigDecimal
at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:167) ~[?:?]
at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:171) ~[?:?]
at sun.reflect.UnsafeObjectFieldAccessorImpl.set(UnsafeObjectFieldAccessorImpl.java:81) ~[?:?]
at java.lang.reflect.Field.set(Field.java:764) ~[?:?]
at org.apache.commons.lang.reflect.FieldUtils.writeField(FieldUtils.java:523) ~[38:org.apache.commons.lang:2.6.0]
at org.apache.commons.lang.reflect.FieldUtils.writeField(FieldUtils.java:500) ~[38:org.apache.commons.lang:2.6.0]
at org.apache.commons.lang.reflect.FieldUtils.writeField(FieldUtils.java:560) ~[38:org.apache.commons.lang:2.6.0]
at org.eclipse.smarthome.config.core.internal.ConfigMapper.as(ConfigMapper.java:102) [97:org.eclipse.smarthome.config.core:0.10.0.oh240M8]
at org.eclipse.smarthome.config.core.Configuration.as(Configuration.java:85) [97:org.eclipse.smarthome.config.core:0.10.0.oh240M8]
at org.eclipse.smarthome.core.thing.binding.BaseThingHandler.getConfigAs(BaseThingHandler.java:274) [109:org.eclipse.smarthome.core.thing:0.10.0.oh240M8]
at org.openhab.binding.modbus.internal.handler.ModbusSerialThingHandler.configure(ModbusSerialThingHandler.java:38) [274:org.openhab.binding.modbus:2.4.0.M8]
at org.openhab.binding.modbus.internal.handler.AbstractModbusEndpointThingHandler.initialize(AbstractModbusEndpointThingHandler.java:65) [274:org.openhab.binding.modbus:2.4.0.M8]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:?]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:?]
at org.eclipse.smarthome.core.internal.common.AbstractInvocationHandler.invokeDirect(AbstractInvocationHandler.java:153) [102:org.eclipse.smarthome.core:0.10.0.oh240M8]
at org.eclipse.smarthome.core.internal.common.Invocation.call(Invocation.java:53) [102:org.eclipse.smarthome.core:0.10.0.oh240M8]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]
==> /var/log/openhab2/events.log <==
2018-12-16 00:01:18.555 [hingStatusInfoChangedEvent] - 'modbus:serial:myNilan' changed from INITIALIZING to OFFLINE (CONFIGURATION_ERROR): Exception during initialization: port, baud, flowControlIn, flowControlOut, stopBits, parity, encoding all must be non-null! (ModbusConfigurationException)