#ifndef DIGITAL_IN_H #define DIGITAL_IN_H #include class Digital_in { public: // pin is the PORTB bit number: // PB0 = D8, PB1 = D9, ..., PB5 = D13 Digital_in(uint8_t pin); void init(); bool is_hi() const; bool is_lo() const; private: uint8_t pinMask; }; #endif