keybrd library is an open source library for creating custom-keyboard firmware.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

LED_PCA9655E.h 702B

1234567891011121314151617181920212223
  1. #ifndef LED_PCA9655E_H
  2. #define LED_PCA9655E_H
  3. #include <Arduino.h>
  4. #include <inttypes.h>
  5. #include <Wire.h>
  6. #include <LED.h>
  7. #include <PortPCA9655E.h>
  8. /* A LED_PCA9655E object is an PCA9655E pin that is connected to an LED indicator light.
  9. Input/Ouput Direction configuration are set to ouput in PortPCA9655E.begin() and PortRead_PCA9655E.begin().
  10. */
  11. class LED_PCA9655E: public LED
  12. {
  13. private:
  14. PortPCA9655E& refPort;
  15. const uint8_t pin; //bit pattern, IOE pin to LED
  16. public:
  17. LED_PCA9655E(PortPCA9655E& refPort, const uint8_t pin) : refPort(refPort), pin(pin) {}
  18. virtual void on();
  19. virtual void off();
  20. };
  21. #endif