ebelski / rust-copter

A quadcopter build using a Teensy running Rust and some other cool stuff that's yet to be determined.
MIT License
6 stars 1 forks source link

Set PWM pin muxing in pwm-control example #46

Closed mciantyre closed 3 years ago

mciantyre commented 3 years ago

This patch fixes the pwm-control example. Before this commit, the PWM outputs were constantly low. Now, the PWM outputs initialize to the 50% duty cycle. This duty cycle correlates to 0% throttle for OneShot125.

Set motor B to 50% throttle:

python3 host/esc-throttle.py /dev/tty.usbmodem62987801 B 50

Observe a faster duty cycle:

Screen Shot 2021-04-22 at 9 07 22 PM

Root cause is down in the PWM driver. See here for details and a fix. We can revert this commit when the bug is fixed in a future HAL release.

See #42 for the initial report.

ebelski commented 3 years ago

Success! Thanks for the quick fix on this!!! 🚀 🌔 💎 👐