This can't be done with jamod because the SimpleProcessImage class adds registers in a linear (no holes) fashion.
You can do this with j2mod, version 1.06 and later, by using the addRegister() method with a specific reference. Holes in the Modbus map will be created and ILLEGAL ADDRESS EXCEPTION responses will be returned when the holes are referenced.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Greetings,
I am currently working with the Java Modbus TCP Slave which can be found here :
http://jamod.sourceforge.net/kb/tcp_slave_howto.html
My question is specifically regarding adding register. For e.g.
spi.addRegister(new SimpleRegister(251));
will add a Register in position 0, is it possible to add a register in a predefined position e.g. 100..
Thx in advance,
Asea
This can't be done with jamod because the SimpleProcessImage class adds registers in a linear (no holes) fashion.
You can do this with j2mod, version 1.06 and later, by using the addRegister() method with a specific reference. Holes in the Modbus map will be created and ILLEGAL ADDRESS EXCEPTION responses will be returned when the holes are referenced.