|
@@ -22,18 +22,48 @@
|
|
|
////////// Define Symbol //////////
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
-// SDA
|
|
|
-#ifndef HSA_LCD_SDA
|
|
|
-#define HSA_LCD_SDA A4
|
|
|
+// I²C Addresse
|
|
|
+#ifndef I2C_ADDRESS
|
|
|
+#define I2C_ADDRESS 0x3C
|
|
|
#endif
|
|
|
|
|
|
-// SCL
|
|
|
-#ifndef HSA_LCD_SCL
|
|
|
-#define HSA_LCD_SCL A5
|
|
|
+// Button Right
|
|
|
+#ifndef BUTTON_RIGHT
|
|
|
+#define BUTTON_RIGHT 0x02
|
|
|
+#endif
|
|
|
+
|
|
|
+// Button Down
|
|
|
+#ifndef BUTTON_DOWN
|
|
|
+#define BUTTON_DOWN 0x03
|
|
|
+#endif
|
|
|
+
|
|
|
+// Button Up
|
|
|
+#ifndef BUTTON_UP
|
|
|
+#define BUTTON_UP 0x04
|
|
|
+#endif
|
|
|
+
|
|
|
+// Button Left
|
|
|
+#ifndef BUTTON_LEFT
|
|
|
+#define BUTTON_LEFT 0x05
|
|
|
+#endif
|
|
|
+
|
|
|
+// LED Red
|
|
|
+#ifndef LED_RED
|
|
|
+#define LED_RED 0x06
|
|
|
+#endif
|
|
|
+
|
|
|
+// LED Green
|
|
|
+#ifndef LED_GREEN
|
|
|
+#define LED_GREEN 0x07
|
|
|
+#endif
|
|
|
+
|
|
|
+// LCD-Backlight
|
|
|
+#ifndef LCD_BACKLIGHT
|
|
|
+#define LCD_BACKLIGHT 0x08
|
|
|
#endif
|
|
|
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
-////////// Include Header-Data //////////
|
|
|
+////////// Include Header-File //////////
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
#include <Arduino.h>
|
|
@@ -49,25 +79,35 @@
|
|
|
////////// Define Class //////////
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
-/**
|
|
|
- * @brief HSA_LCD_Shield class
|
|
|
- * @details Is used, to control all functions of the HSA_LCD_Shield
|
|
|
- *
|
|
|
- */
|
|
|
+/// @brief HSA_LCD_Shield class
|
|
|
+/// @details Is used, to control all functions of the HSA_LCD_Shield
|
|
|
class HSA_LCD_Shield {
|
|
|
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
-////////// Privat Functions //////////
|
|
|
+////////// Privat Area //////////
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
private:
|
|
|
|
|
|
+Byte _i2cAddress;
|
|
|
+Byte _buttonRight;
|
|
|
+Byte _buttonDown;
|
|
|
+Byte _buttonUp;
|
|
|
+Byte _buttonLeft;
|
|
|
+Byte _buttonRight;
|
|
|
+Byte _ledRed;
|
|
|
+Byte _ledGreen;
|
|
|
+Byte _lcdBacklight;
|
|
|
+
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
////////// Public Functions //////////
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
public:
|
|
|
|
|
|
+////////// Public Functions //////////
|
|
|
+
|
|
|
+HSA_LCD_Shield
|
|
|
|
|
|
|
|
|
//////////////////////////////////////////////////////////////////////
|