|
Re: one sensor multiple subsystems
If the sensor isn't truly part of a subsystem, I don't make it part of one. I just declare it as public static final in CommandBase and access it from there.
Most of my raw hardware things are declared this way in CommandBase; It seemed more elegant to me to give CAN/DIO/AIO IDs or SpeedController objects to subsystems' constructors. This way CommandBase basically acts like RobotMap (I deleted RobotMap).
Last edited by LukeS : 11-02-2012 at 20:16.
Reason: clarify
|