CounterBase¶
- class wpilib.interfaces.CounterBase¶
Bases:
pybind11_objectInterface for counting the number of ticks on a digital input channel.
Encoders, Gear tooth sensors, and counters should all subclass this so it can be used to build more advanced classes for control and driving.
All counters will immediately start counting - Reset() them if you need them to be zeroed before use.
- class EncodingType(value: int)¶
Bases:
pybind11_objectMembers:
k1X
k2X
k4X
- k1X = <EncodingType.k1X: 0>¶
- k2X = <EncodingType.k2X: 1>¶
- k4X = <EncodingType.k4X: 2>¶
- property name¶
- property value¶
- get() int¶
- getDirection() bool¶
- getPeriod() seconds¶
- getStopped() bool¶
- reset() None¶
- setMaxPeriod(maxPeriod: seconds) None¶