se incrementa y decrementa parámetros con el encoder.
Dependencies: QEI TextLCD mbed
Fork of TAREA_4_PROCESADORES by
DebouncedIn.h
- Committer:
- jana
- Date:
- 2014-05-23
- Revision:
- 2:fba5e2ee8bee
- Parent:
- 0:dd68101b1b99
File content as of revision 2:fba5e2ee8bee:
#include "mbed.h" class DebouncedIn { public: DebouncedIn(PinName in); int read (void); operator int(); int rising(void); int falling(void); int steady(void); private : // objects DigitalIn _in; Ticker _ticker; // function to take a sample, and update flags void _sample(void); // counters and flags int _samples; int _output; int _output_last; int _rising_flag; int _falling_flag; int _state_counter; };