robotpy / examples

Repository of RobotPy example projects
43 stars 52 forks source link

Added drivetrain demo for PWM, CTRE and REV motors. #77

Closed martinrioux closed 1 year ago

martinrioux commented 1 year ago

Added a frc-docs folder to place linked code examples.

martinrioux commented 1 year ago

I've fixed the headerfile. It should indeed not have read PWM for the 3 examples.

virtuald commented 1 year ago

The original frc-docs link you pointed me at links to the getting-started example, which is already at https://github.com/robotpy/examples/blob/main/getting-started/robot.py. Any reason to add this new example instead of using that existing one?

martinrioux commented 1 year ago

In the Zero to Robot section of the frc-docs, the tutorial go through all the basics to get a robot (drivetrain) working as simply as possible. This is why there are 3 Drivetrain examples (for CTRE, REV or basic PWM). The getting started code found at https://github.com/robotpy/examples/blob/main/getting-started/robot.py will in fact be linked after these bases have been established and the robot tested. I also try to respect the Java/C++ tutorials as close as possible.

virtuald commented 1 year ago

I think the CTRE and REV examples can be added to the examples directory in robotpy-ctre and robotpy-rev. The frc-docs PWM example should link to getting-started.