PlatformIO package of the Teensy core framework compatible with GCC 10 & C++20
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

35 行
1.1KB

  1. // Die - A class to handle the display of a six sided die, using
  2. // seven light emitting diodes
  3. //
  4. // Copyright 2012 by Walter Anderson
  5. //
  6. // This file is part of Entropy, an Arduino library.
  7. // Entropy is free software: you can redistribute it and/or modify
  8. // it under the terms of the GNU General Public License as published by
  9. // the Free Software Foundation, either version 3 of the License, or
  10. // (at your option) any later version.
  11. //
  12. // Entropy is distributed in the hope that it will be useful,
  13. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. // GNU General Public License for more details.
  16. //
  17. // You should have received a copy of the GNU General Public License
  18. // along with Entropy. If not, see <http://www.gnu.org/licenses/>.
  19. #ifndef Die_h
  20. #define Die_h
  21. class Die
  22. {
  23. public:
  24. void Initialize(int a, int b, int c, int d, int e, int f, int g);
  25. void Show(unsigned char value);
  26. private:
  27. int led_a, led_b, led_c, led_d, led_e, led_f, led_g;
  28. void On(void);
  29. void Off(void);
  30. void Error(void);
  31. };
  32. #endif