sdd1306 stm32l010 h

Dependencies:   mbed SSD1308_128x64_I2C

Revision:
0:84dc6ebb237d
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Tue Aug 02 06:48:31 2022 +0000
@@ -0,0 +1,66 @@
+//oled_test2_16x24_767_1
+
+#include "mbed.h"
+#include "SSD1308.h"
+
+//i2c initialization
+//I2C i2c(I2C_SDA, I2C_SCL); //767
+
+// Instantiate OLED
+//SSD1308 oled = SSD1308(SSD1308_SA0);
+
+// Host PC Communication channels
+//Serial pc(USBTX, USBRX); // tx, rx
+
+
+
+//メイン関数
+int main()
+{
+
+
+
+    int ii; //ループカウンター
+    int nn; //文字カウンター
+
+    //シリアルの初期化
+//    pc.baud(9600);
+
+//    printf("\r\n<START>\r\n");
+
+    // Instantiate OLED
+    SSD1308 oled = SSD1308(SSD1308_SA0);
+
+
+    //charge pump  add=>ca45040
+    //i2c.write(SSD1308_SA0, "\200\215\200\024", 4); //0x80,0x8d,0x80,0x14
+    //set access
+    //oled.setDisplayFlip(false, false);
+
+
+
+    //char n1_8[] = "12345678";
+    char n1_8[] = "87654321";
+    //char n1_8[] =   "88888888";
+
+    ii=0;
+    for(nn=0; nn<8; nn++) {
+        //                y   x
+        oled.writeBigChar(0, ii*16,n1_8[nn]);
+        ii = ii + 1;
+    } //for
+    //pc.printf("Printed something\r\n");
+//    printf("Printed something\r\n");
+    
+    //oled.writeString(0, 0, "Hello World !");  
+    
+    while(1) {}
+
+}//main
+
+
+
+//容量削減
+void error(const char* format, ...) {}
+
+