Skip to content

feat(host): list_ports() and position() convenience helpers #26

Closed

Description

@CameronBrooks11

Two small, app-neutral conveniences so consumers (fiberpath/fiberpath#195) drop their own pyserial glue:

  • list_ports() -> list[PortInfo] — enumerate serial ports (pyserial serial.tools.list_ports.comports()), returning {port/device, description, hwid}. marlin-host already owns the optional pyserial dep; this lets fiberpath drop its only remaining direct serial.tools.list_ports use. Gate behind the [serial] extra like SerialTransport.
  • position() -> Mapping[str, float] — mirror temperatures(): query M114 and return the parsed position fields. query("M114") already works; this is the symmetric first-class helper.

Part of epic #5.

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

    enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions