rossmann-engineering / EasyModbusTCP.NET

Modbus TCP, Modbus UDP and Modbus RTU client/server library for .NET implementations
928 stars 402 forks source link

Random ReadHoldingRegisters 4096 value #17

Closed dnviti closed 5 years ago

dnviti commented 5 years ago

After a short period of readings signal from plc, the value of reading goes up to 4096, instead I'm expecting only 0 and 1.

rossmann-engineering commented 5 years ago

Sorry I don't really understand

dnviti commented 5 years ago

I do not neither. Ported the software to Python, no problem.

Padanian commented 5 years ago

4096 is 0010 000 in binary, so actually you are receiving a 1 on the 6th bit. It's probably a bitmapped register.