Basically i glued Peter Drescher and Simon Ford libs in a GraphicsDisplay class, then derived TFT or LCD class (which inherits Protocols class), then the most derived ones (Inits), which are per-display and are the only part needed to be adapted to diff hw.

Dependents:   Brew

Revision:
33:f87f06292637
Parent:
30:87855d03d91a
diff -r 9cd6227dc7a6 -r f87f06292637 Protocols/Protocols.h
--- a/Protocols/Protocols.h	Mon May 02 22:44:05 2016 +0000
+++ b/Protocols/Protocols.h	Mon Feb 06 12:29:33 2017 +0000
@@ -31,6 +31,7 @@
     ,BUS_16   /**< Parallel 16bit, scattered pins */
     ,SPI_8  /**< SPI 8bit */
     ,SPI_16 /**< SPI 16bit */
+    ,I2C_   /**< I2C */
 };
 #else 
 enum proto_t {
@@ -38,6 +39,7 @@
     ,BUS_16   /**< Parallel 16bit, scattered pins */
     ,SPI_8  /**< SPI 8bit */
     ,SPI_16 /**< SPI 16bit */
+    ,I2C_   /**< I2C */
 };
 #endif