A test example using the OLED display on the Embedded Artists Xpresso baseboard

Dependencies:   mbed

Revision:
0:f42b25503fd1
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/EAOLED.h	Sun Feb 28 16:04:59 2010 +0000
@@ -0,0 +1,29 @@
+// test library for Embedded Artists OLED used on Xpresso Baseboard
+
+#ifndef MBED_EAOLED_H
+#define MBED_EAOLED_H
+
+#include "mbed.h"
+#include "GraphicsDisplay.h"
+
+class EAOLED : public GraphicsDisplay {
+public:
+    EAOLED(PinName mosi, PinName dnc, PinName sclk, PinName cs, PinName power);
+    virtual void pixel(int x, int y, int colour);
+  //  virtual void cls();
+    virtual int width() { return 96; }
+    virtual int height() { return 64; }
+    
+    void reset();
+    void data(int value);
+    void command(int value);
+
+    SPI _spi;
+    DigitalOut _data;
+    DigitalOut _cs;
+    DigitalOut _power;
+    
+    uint8_t framebuffer[(96 * 64) / 8];
+};
+
+#endif