Skip to content

Voetglin driver: modbus serial kwargs have no effect #41

Description

@albertogomcas

I have not checked everywhere, but definitely this is the case in the voetglin driver, you can change for example BAUDRATE in DEFAULT_COM_KWARGS to no effect (the serial is open with 19200).

The same when using the serial_com_kwargs of RedFlowMeter.init

Both of these approaches write whatever value (i.e. BAUDRATE=value) on the minimalmodbus module, which is not used at all by minimalmodbus itself.

The only way to ensure that the parameters are used is to set them after instantiation with flow_meter.instrument.serial.parameter=value, I have no issues with that, but the dict with defaults and the argument on init are very misleading and had me chasing ghosts for a couple hours.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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