-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
https://github.com/alexdutton/python-maestro-servo/blob/main/maestro/device.py#L81 is currently:
for i in range(self.channel_count // 4)This does not work with the Micro Maestro (and probably also the 18-channel Mini Maestro).
The list ends up with 1 group mode (corresponding to only 4 channels) instead of the required 2 (to support all 6 channels).
It needs ceiling division, not floor division:
for i in range(math.ceil(self.channel_count / 4))Or, my personal favorite: upside-down floor division.
for i in range(-(-self.channel_count // 4))Metadata
Metadata
Assignees
Labels
No labels