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 865B

123456789101112131415161718192021222324252627
  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 <PortWrite_PCA9655E.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 PortWrite_PCA9655E.begin() and PortRead_PCA9655E.begin().
  10. */
  11. class LED_PCA9655E: public LED
  12. {
  13. private:
  14. //PortIOE& port;
  15. //const uint8_t outputByteCommand; //General Purpose Input/Ouput register address
  16. PortWrite_PCA9655E& refPort;
  17. const uint8_t pin; //bit pattern, IOE pin to LED
  18. public:
  19. LED_PCA9655E(PortWrite_PCA9655E& refPort, const uint8_t pin)
  20. : refPort(refPort), pin(pin) {}
  21. virtual void on();
  22. virtual void off();
  23. };
  24. #endif