Skip to content

Add support for hex values in REPL client.write_registers #628

@rdiez

Description

@rdiez

Modbus registers are 16-bit and sometimes it is easier to understand their values when expressed in hex.

However, in the REPL tool "pymodbus.console", it looks like you cannot use hex for the values:

client.write_registers unit=1 address=9 values=0x0331
ValueError("invalid literal for int() with base 10: '0x0331'")

It would be nice if you could use hex like depicted above.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions