Skip to content

How do you access the raw (bytes) response for decoding messages that aren't composed of 16-bit integers? #111

@fake-name

Description

@fake-name

Effectively the title. I have a device that packs 32-bit floats into two sequential registers.

Currently, there seems to be no way to get anything but the already decoded 16-bit integer sequence.

I can re-pack the return data from umodbus.client.serial.rtu.send_message() into a byte-array, and then re-decode that using the device's structure, bit that seems asinine given that all I really need is uModbus to not do the (in this application incorrect) decode step.

I spent a bit of time looking into potentially just replacing send_message() with a version that still does the CRC check and message trimming, but not the decode, but it appears that separating the message validation and trimming from the decoding is sufficiently annoying that I can't see this as anything other then a bug.

How do I get the raw response the modbus device returns without having to re-pack the data into a bytearray?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions