Skip to content

(Preset) Write Single Register (6) incorrect value transmission #16

@Pratched

Description

@Pratched

I was trying to see if my FunctionCode 0x06 works alright, but realised that the implementation in Modbusmechanic v2.5 seems to be a little bit faulty?

When I setup the simulator as Holding Register 50000 (UINT16), no swaps, I am not able to overwrite this value with FnC 0x06 correctly. No matter what I want to write, it always defaults to 0. Attached youl find screenshots of the WireShark capture of different write requests, always with the same data value.

ModbusMechanic client with 0x06 request and value=5.
grafik

WireShark Output for my own implementation, same settings.
grafik

ModbusMechanic client with 0x10 request and value=5 seems to work okay...
grafik
... but as far as I understand simply writing one register (u16) should be possible with 0x06 as well?

Sorry in advance, if I missed something.
EDIT: My understandings in this are based on "MODBUS APPLICATION PROTOCOL SPECIFICATION
V1.1b3" from Modbus.org but might be oudated.
grafik
grafik

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions