RobotCasserole1736 / CasseroleLib

Common Libraries used year-to-year for FRC robot code
MIT License
6 stars 1 forks source link

Create HAL structures for Motor #10

Open gerth2 opened 8 years ago

gerth2 commented 8 years ago

Create a HAL (Hardware Abstraction Layer) class to describe a motor:

Should group together classes for the motor controller, pdp channel, encoder, and ratios between encoder/motor

Common functions (via methodHandles?) Should be provided to set the motor value (-1 to 1 range) or motor voltage (requested voltage / system voltage). Getters should be able to return the motor rotational velocity, acceleration, and motor current in common units of RPM, RPM/sec, and A.

Current reads should be done from Motor Controller (if possible) or PDP (if not possible)

Grouping these things together should better describe the hierarchy of our system.