mbed support for LPC4088 Display Module

Dependencies:   DM_FATFileSystem DM_HttpServer DM_USBHost EthernetInterface USBDevice mbed-rpc mbed-rtos mbed-src

Dependents:   emptyProgram

Fork of DMSupport by Embedded Artists

Revision:
28:8ae20cb0b943
Parent:
26:a65fbb4bde5c
Child:
39:e1cb4dd9bfeb
--- a/Bios/bios.h	Fri Jan 23 13:48:44 2015 +0100
+++ b/Bios/bios.h	Fri Jan 23 17:31:56 2015 +0100
@@ -5,7 +5,7 @@
 #include <stdbool.h>
 
 #define BIOS_MAGIC  0xEA0123EA
-#define BIOS_VER      0x000100  // MAJOR.MINOR.BUILD
+#define BIOS_VER      0x000200  // MAJOR.MINOR.BUILD
 #define BIOS_VER_MASK 0xffffff
 
 typedef enum {
@@ -32,11 +32,19 @@
     uint16_t z;
 } touch_coordinate_t;
 
+typedef enum {
+    TOUCH_IRQ_RISING_EDGE,
+    TOUCH_IRQ_FALLING_EDGE,
+    TOUCH_IRQ_HIGH_LEVEL,
+    TOUCH_IRQ_LOW_LEVEL,
+} touch_irq_trigger_t;
+
 typedef void (*delayUsFunc)(int us);
 typedef uint32_t (*readTimeMsFunc)(void);
 
 typedef BiosError_t (*initParamFunc)(void* data, uint32_t SystemCoreClock, uint32_t PeripheralClock, delayUsFunc delay, readTimeMsFunc readMs);
 typedef BiosError_t (*simpleFunc)(void* data);
+typedef BiosError_t (*macFunc)(void* data, char* mac);
 
 typedef BiosError_t (*powerUpFunc)(void* data, void* framebuffer, Resolution_t wanted);
 typedef BiosError_t (*backlightFunc)(void* data, int percent);
@@ -50,10 +58,9 @@
 typedef BiosError_t (*infoFuncT)(void* data,
                                  bool* supportsTouch,
                                  bool* supportsCalibration,
-                                 bool* resistive,
                                  uint8_t* numPoints);
 
-typedef void (*touchIrqFunc)(uint32_t arg, bool enable, bool rising);
+typedef void (*touchIrqFunc)(uint32_t arg, bool enable, touch_irq_trigger_t trigger);
 typedef void (*touchNewDataFunc)(uint32_t arg, touch_coordinate_t* coords, int num);
 typedef BiosError_t (*touchInitFunc)(void* data, 
                                      touchIrqFunc irqEnabler, uint32_t enablerArg, 
@@ -65,6 +72,9 @@
 
 typedef struct {
   initParamFunc initParams;
+  simpleFunc    i2cIRQHandler;
+  spifiFunc     spifiIsSupported;
+  macFunc       ethernetMac;
 
   simpleFunc    displayInit;
   powerUpFunc   displayPowerUp;
@@ -82,9 +92,6 @@
   simpleFunc    touchIrqHandler;
   infoFuncT     touchInformation;
 
-  simpleFunc    touchI2CIRQHandler;
-    
-  spifiFunc     spifiIsSupported;
 } bios_header_t;
 
 typedef struct {