Updated changelog
[hackover2013-badge-firmware.git] / drivers / lcd / tft / hw / ssd1331.h
index ff0931a..3dd4bc8 100644 (file)
 #include "drivers/lcd/tft/lcd.h"
 #include "core/gpio/gpio.h"
 
 #include "drivers/lcd/tft/lcd.h"
 #include "core/gpio/gpio.h"
 
+// Select one of these defines to set the pixel color order
+#define SSD1331_COLORORDER_RGB
+// #define SSD1331_COLORORDER_BGR
+
+#if defined SSD1331_COLORORDER_RGB && defined SSD1331_COLORORDER_BGR
+  #error "RGB and BGR can not both be defined for SSD1331_COLORODER."
+#endif
+
 // Control pins
 #define SSD1331_SID_PORT          2     // DAT
 #define SSD1331_SID_PIN           1
 // Control pins
 #define SSD1331_SID_PORT          2     // DAT
 #define SSD1331_SID_PIN           1
 #define SET_RST         SSD1331_GPIO2DATA_RST = (1 << SSD1331_RST_PIN)
 #define CLR_CS          SSD1331_GPIO2DATA_CS = (0)
 #define SET_CS          SSD1331_GPIO2DATA_CS = (1 << SSD1331_CS_PIN)
 #define SET_RST         SSD1331_GPIO2DATA_RST = (1 << SSD1331_RST_PIN)
 #define CLR_CS          SSD1331_GPIO2DATA_CS = (0)
 #define SET_CS          SSD1331_GPIO2DATA_CS = (1 << SSD1331_CS_PIN)
+#define CLR_SCK         SSD1331_GPIO2DATA_SCK = (0)
+#define SET_SCK         SSD1331_GPIO2DATA_SCK = (1 << SSD1331_SCK_PIN)
+#define CLR_SID         SSD1331_GPIO2DATA_SID = (0)
+#define SET_SID         SSD1331_GPIO2DATA_SID = (1 << SSD1331_SID_PIN)
 
 enum
 {
 
 enum
 {
This page took 0.026265 seconds and 4 git commands to generate.