Skip to content

motorsd: add shared motor service prototype - #23

Draft
MayorBug wants to merge 2 commits into
OpenIPC:masterfrom
MayorBug:motorsd-prototype
Draft

MayorBug wants to merge 2 commits into
OpenIPC:masterfrom
MayorBug:motorsd-prototype

Conversation

@MayorBug

Copy link
Copy Markdown
Contributor

Summary

This draft adds a shared motor service for OpenIPC.

motorsd coordinates motor access. A persistent driver process owns the hardware. Applications use libmotors, motorsctl, or the documented socket protocol.

Included

  • connection-bound leases and fixed client roles
  • manual command preemption
  • timed and continuous movement
  • driver lifecycle events
  • driver supervision and recovery
  • a first-party C client library
  • a command-line client
  • Pelco-D and Pelco-XM support
  • controller settings exposed through the selected driver
  • a pelcodtui motorsd backend
  • generic driver telemetry

The Pelco-XM driver converts the XiongMai X<ratio> report into a zoom_magnification event. This allows AF2 to receive live zoom magnification without opening the motor UART.

Current status

The service architecture, public API, private driver API, and test drivers are implemented.

The P035 path has been tested during development. Pelco-XM frames and telemetry have PTY tests, but the zoom telemetry path still needs validation on an actual XiongMai 85H50AI controller.

Firmware packaging and wider hardware testing remain follow-up work.

Validation

  • make test
  • camera ARM build
  • git diff --check

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant