DIY fertilizer mixer and plant watering machine https://www.xythobuz.de/giessomat.html
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.

GPIOBank.h 445B

12345678910111213141516171819202122232425
  1. #ifndef _GPIO_BANK_H_
  2. #define _GPIO_BANK_H_
  3. class GPIOBank {
  4. public:
  5. GPIOBank(int _size);
  6. ~GPIOBank(void);
  7. void setPinNumbers(int _pins[]);
  8. void setOutput(void);
  9. void setInput(bool pullup);
  10. int getSize(void);
  11. void setPin(int n, bool state);
  12. void setAll(bool state);
  13. bool getPin(int n);
  14. private:
  15. int size;
  16. int *pins;
  17. bool *out_state;
  18. bool is_output;
  19. };
  20. #endif // _GPIO_BANK_H_