Skip to content

Implement motor driver for 4.4#31

Open
hyx0329 wants to merge 2 commits into
themactep:masterfrom
hyx0329:t40-motor-rebased
Open

Implement motor driver for 4.4#31
hyx0329 wants to merge 2 commits into
themactep:masterfrom
hyx0329:t40-motor-rebased

Conversation

@hyx0329

@hyx0329 hyx0329 commented Jan 15, 2026

Copy link
Copy Markdown
Contributor

Here's my current progress, and I think it's usable right now.

This is based on existing code from both 4.4 and 3.10, and further enhanced to allow smoother diagonal movement.

Current differences to 3.10:

  • no invert_direction_polarity, motor_switch_gpio, hmotor2vmotor
  • has optional GPIO endstops
  • smoother diagonal movement
  • use current step count to determine power on state(which coil to power) so the torque is applied correctly

@hyx0329 hyx0329 force-pushed the t40-motor-rebased branch 2 times, most recently from ac1b352 to 74344ce Compare January 17, 2026 01:38
@hyx0329 hyx0329 marked this pull request as ready for review January 17, 2026 01:53
@hyx0329 hyx0329 force-pushed the t40-motor-rebased branch 2 times, most recently from 6f46ac7 to d843c38 Compare January 17, 2026 15:58
This is based on existing code from 4.4 and 3.10, and further enhanced
to allow smoother diagonal movement for any angle.

Some differences to 3.10:
- no invert_direction_polarity, motor_switch_gpio, hmotor2vmotor
- gpio endstops added, but not tested yet
- smoother diagonal movement for any angle
- The coils power on state is determined by current step count values
  and proper torque is applied.
- Some `gpio_direction_output` are replaced with `gpio_set_value` for
  spinlock safety.
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