{"action":"created","issue":{"url":"https://api.github.com/repos/olikraus/u8glib/issues/371","labels_url":"https://api.github.com/repos/olikraus/u8glib/issues/371/labels{/name}","comments_url":"https://api.github.com/repos/olikraus/u8glib/issues/371/comments","events_url":"https://api.github.com/repos/olikraus/u8glib/issues/371/events","html_url":"https://github.com/olikraus/u8glib/issues/371","id":113058143,"number":371,"title":"6pin i2c 0.96 oled works with adafruit code but not u8glib","user":{"login":"s21rc","id":15243893,"avatar_url":"https://avatars.githubusercontent.com/u/15243893?v=3","gravatar_id":"","url":"https://api.github.com/users/s21rc","html_url":"https://github.com/s21rc","followers_url":"https://api.github.com/users/s21rc/followers","following_url":"https://api.github.com/users/s21rc/following{/other_user}","gists_url":"https://api.github.com/users/s21rc/gists{/gist_id}","starred_url":"https://api.github.com/users/s21rc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/s21rc/subscriptions","organizations_url":"https://api.github.com/users/s21rc/orgs","repos_url":"https://api.github.com/users/s21rc/repos","events_url":"https://api.github.com/users/s21rc/events{/privacy}","received_events_url":"https://api.github.com/users/s21rc/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-10-23T16:50:23Z","updated_at":"2015-10-25T08:27:21Z","closed_at":null,"body":"Hi Olikraus, Greetings from Bangladesh and thanks for the nice small footprint driver for the oled. I have few 0.96 oled (cheap chines, pic attached) which has the following pin:\r\nGND\r\nVCC\r\nSCL\r\nSDA\r\nRST\r\nD/C\r\n\r\nIt works if I connect the RST and D/C pin to digital pin and using the below code. But I am unable to operate it using only 4 wire (except the RST, D/C pin). Can you please have a look and advise if I can static LOW or HIGH those pins so that it works with U8GLIB. I am willing to use it with a ATMEGA328P-PU chip and thus need a small driver. Thanks a lot. Fazlay\r\n\r\n\r\n\r\n![20151023_223547 1](https://cloud.githubusercontent.com/assets/15243893/10699361/f9b5935c-79d7-11e5-8d3c-9679378406a9.jpg)\r\n![20151023_223608 1](https://cloud.githubusercontent.com/assets/15243893/10699394/59147d90-79d8-11e5-9091-6733427cc0e9.jpg)\r\n\r\nWorking Code:\r\n\r\n/*  OLED          arduino\r\n     D0-----------10\r\n     D1-----------9\r\n     RST----------13\r\n     DC-----------11\r\n     VCC----------5V\r\n     GND----------GND*/\r\nint SCL_PIN=A5;//D0\r\nint SDA_PIN=A4; //D1\r\nint RST_PIN=4;//RST\r\nint DC_PIN=3; //DC\r\n\r\n void LED_CLS(void);\r\n void LED_Set_Pos(unsigned char x,unsigned char y);//Set the coordinate\r\n void LED_WrDat(unsigned char data);   //Write Data\r\n void LED_P6x8Char(unsigned char x,unsigned char y,unsigned char ch);\r\n void LED_P6x8Str(unsigned char x,unsigned char y,unsigned char ch[]);\r\n void LED_P8x16Str(unsigned char x,unsigned char y,unsigned char ch[]);\r\n\r\n void LED_PrintBMP(unsigned char x0,unsigned char y0,unsigned char x1,unsigned char y1,unsigned char bmp[]); \r\n void LED_Fill(unsigned char dat);\r\n void LED_PrintValueC(unsigned char x, unsigned char y,char data);\r\n void LED_PrintValueI(unsigned char x, unsigned char y, int data);\r\n void LED_PrintValueF(unsigned char x, unsigned char y, float data, unsigned char num);\r\n void LED_PrintEdge(void);\r\n void LED_Cursor(unsigned char cursor_column, unsigned char cursor_row);\r\n void LED_PrintLine(void);\r\n\r\n\r\n\r\n\r\n\r\n\r\nconst unsigned char F6x8[][6] =\r\n{\r\n  { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 },   // sp\r\n  { 0x00, 0x00, 0x00, 0x2f, 0x00, 0x00 },   // !\r\n  { 0x00, 0x00, 0x07, 0x00, 0x07, 0x00 },   // \"\r\n  { 0x00, 0x14, 0x7f, 0x14, 0x7f, 0x14 },   // #\r\n  { 0x00, 0x24, 0x2a, 0x7f, 0x2a, 0x12 },   // $\r\n  { 0x00, 0x62, 0x64, 0x08, 0x13, 0x23 },   // %\r\n  { 0x00, 0x36, 0x49, 0x55, 0x22, 0x50 },   // &\r\n  { 0x00, 0x00, 0x05, 0x03, 0x00, 0x00 },   // '\r\n  { 0x00, 0x00, 0x1c, 0x22, 0x41, 0x00 },   // (\r\n  { 0x00, 0x00, 0x41, 0x22, 0x1c, 0x00 },   // )\r\n  { 0x00, 0x14, 0x08, 0x3E, 0x08, 0x14 },   // *\r\n  { 0x00, 0x08, 0x08, 0x3E, 0x08, 0x08 },   // +\r\n  { 0x00, 0x00, 0x00, 0xA0, 0x60, 0x00 },   // ,\r\n  { 0x00, 0x08, 0x08, 0x08, 0x08, 0x08 },   // -\r\n  { 0x00, 0x00, 0x60, 0x60, 0x00, 0x00 },   // .\r\n  { 0x00, 0x20, 0x10, 0x08, 0x04, 0x02 },   // /\r\n  { 0x00, 0x3E, 0x51, 0x49, 0x45, 0x3E },   // 0\r\n  { 0x00, 0x00, 0x42, 0x7F, 0x40, 0x00 },   // 1\r\n  { 0x00, 0x42, 0x61, 0x51, 0x49, 0x46 },   // 2\r\n  { 0x00, 0x21, 0x41, 0x45, 0x4B, 0x31 },   // 3\r\n  { 0x00, 0x18, 0x14, 0x12, 0x7F, 0x10 },   // 4\r\n  { 0x00, 0x27, 0x45, 0x45, 0x45, 0x39 },   // 5\r\n  { 0x00, 0x3C, 0x4A, 0x49, 0x49, 0x30 },   // 6\r\n  { 0x00, 0x01, 0x71, 0x09, 0x05, 0x03 },   // 7\r\n  { 0x00, 0x36, 0x49, 0x49, 0x49, 0x36 },   // 8\r\n  { 0x00, 0x06, 0x49, 0x49, 0x29, 0x1E },   // 9\r\n  { 0x00, 0x00, 0x36, 0x36, 0x00, 0x00 },   // :\r\n  { 0x00, 0x00, 0x56, 0x36, 0x00, 0x00 },   // ;\r\n  { 0x00, 0x08, 0x14, 0x22, 0x41, 0x00 },   // <\r\n  { 0x00, 0x14, 0x14, 0x14, 0x14, 0x14 },   // =\r\n  { 0x00, 0x00, 0x41, 0x22, 0x14, 0x08 },   // >\r\n  { 0x00, 0x02, 0x01, 0x51, 0x09, 0x06 },   // ?\r\n  { 0x00, 0x32, 0x49, 0x59, 0x51, 0x3E },   // @\r\n  { 0x00, 0x7C, 0x12, 0x11, 0x12, 0x7C },   // A\r\n  { 0x00, 0x7F, 0x49, 0x49, 0x49, 0x36 },   // B\r\n  { 0x00, 0x3E, 0x41, 0x41, 0x41, 0x22 },   // C\r\n  { 0x00, 0x7F, 0x41, 0x41, 0x22, 0x1C },   // D\r\n  { 0x00, 0x7F, 0x49, 0x49, 0x49, 0x41 },   // E\r\n  { 0x00, 0x7F, 0x09, 0x09, 0x09, 0x01 },   // F\r\n  { 0x00, 0x3E, 0x41, 0x49, 0x49, 0x7A },   // G\r\n  { 0x00, 0x7F, 0x08, 0x08, 0x08, 0x7F },   // H\r\n  { 0x00, 0x00, 0x41, 0x7F, 0x41, 0x00 },   // I\r\n  { 0x00, 0x20, 0x40, 0x41, 0x3F, 0x01 },   // J\r\n  { 0x00, 0x7F, 0x08, 0x14, 0x22, 0x41 },   // K\r\n  { 0x00, 0x7F, 0x40, 0x40, 0x40, 0x40 },   // L\r\n  { 0x00, 0x7F, 0x02, 0x0C, 0x02, 0x7F },   // M\r\n  { 0x00, 0x7F, 0x04, 0x08, 0x10, 0x7F },   // N\r\n  { 0x00, 0x3E, 0x41, 0x41, 0x41, 0x3E },   // O\r\n  { 0x00, 0x7F, 0x09, 0x09, 0x09, 0x06 },   // P\r\n  { 0x00, 0x3E, 0x41, 0x51, 0x21, 0x5E },   // Q\r\n  { 0x00, 0x7F, 0x09, 0x19, 0x29, 0x46 },   // R\r\n  { 0x00, 0x46, 0x49, 0x49, 0x49, 0x31 },   // S\r\n  { 0x00, 0x01, 0x01, 0x7F, 0x01, 0x01 },   // T\r\n  { 0x00, 0x3F, 0x40, 0x40, 0x40, 0x3F },   // U\r\n  { 0x00, 0x1F, 0x20, 0x40, 0x20, 0x1F },   // V\r\n  { 0x00, 0x3F, 0x40, 0x38, 0x40, 0x3F },   // W\r\n  { 0x00, 0x63, 0x14, 0x08, 0x14, 0x63 },   // X\r\n  { 0x00, 0x07, 0x08, 0x70, 0x08, 0x07 },   // Y\r\n  { 0x00, 0x61, 0x51, 0x49, 0x45, 0x43 },   // Z\r\n  { 0x00, 0x00, 0x7F, 0x41, 0x41, 0x00 },   // [ 91\r\n  { 0x00, 0x02, 0x04 ,0x08, 0x10, 0x20 },    // \\92\r\n  { 0x00, 0x00, 0x41, 0x41, 0x7F, 0x00 },   // ]\r\n  { 0x00, 0x04, 0x02, 0x01, 0x02, 0x04 },   // ^\r\n  { 0x00, 0x40, 0x40, 0x40, 0x40, 0x40 },   // _\r\n  { 0x00, 0x00, 0x01, 0x02, 0x04, 0x00 },   // '\r\n  { 0x00, 0x20, 0x54, 0x54, 0x54, 0x78 },   // a\r\n  { 0x00, 0x7F, 0x48, 0x44, 0x44, 0x38 },   // b\r\n  { 0x00, 0x38, 0x44, 0x44, 0x44, 0x20 },   // c\r\n  { 0x00, 0x38, 0x44, 0x44, 0x48, 0x7F },   // d\r\n  { 0x00, 0x38, 0x54, 0x54, 0x54, 0x18 },   // e\r\n  { 0x00, 0x08, 0x7E, 0x09, 0x01, 0x02 },   // f\r\n  { 0x00, 0x18, 0xA4, 0xA4, 0xA4, 0x7C },   // g\r\n  { 0x00, 0x7F, 0x08, 0x04, 0x04, 0x78 },   // h\r\n  { 0x00, 0x00, 0x44, 0x7D, 0x40, 0x00 },   // i\r\n  { 0x00, 0x40, 0x80, 0x84, 0x7D, 0x00 },   // j\r\n  { 0x00, 0x7F, 0x10, 0x28, 0x44, 0x00 },   // k\r\n  { 0x00, 0x00, 0x41, 0x7F, 0x40, 0x00 },   // l\r\n  { 0x00, 0x7C, 0x04, 0x18, 0x04, 0x78 },   // m\r\n  { 0x00, 0x7C, 0x08, 0x04, 0x04, 0x78 },   // n\r\n  { 0x00, 0x38, 0x44, 0x44, 0x44, 0x38 },   // o\r\n  { 0x00, 0xFC, 0x24, 0x24, 0x24, 0x18 },   // p\r\n  { 0x00, 0x18, 0x24, 0x24, 0x18, 0xFC },   // q\r\n  { 0x00, 0x7C, 0x08, 0x04, 0x04, 0x08 },   // r\r\n  { 0x00, 0x48, 0x54, 0x54, 0x54, 0x20 },   // s\r\n  { 0x00, 0x04, 0x3F, 0x44, 0x40, 0x20 },   // t\r\n  { 0x00, 0x3C, 0x40, 0x40, 0x20, 0x7C },   // u\r\n  { 0x00, 0x1C, 0x20, 0x40, 0x20, 0x1C },   // v\r\n  { 0x00, 0x3C, 0x40, 0x30, 0x40, 0x3C },   // w\r\n  { 0x00, 0x44, 0x28, 0x10, 0x28, 0x44 },   // x\r\n  { 0x00, 0x1C, 0xA0, 0xA0, 0xA0, 0x7C },   // y\r\n  { 0x00, 0x44, 0x64, 0x54, 0x4C, 0x44 },   // z\r\n  { 0x14, 0x14, 0x14, 0x14, 0x14, 0x14 }    // horiz lines\r\n};\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\nconst unsigned char F8X16[]=\r\n{\r\n  0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,// 0\r\n  0x00,0x00,0x00,0xF8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x33,0x30,0x00,0x00,0x00,//!1\r\n  0x00,0x10,0x0C,0x06,0x10,0x0C,0x06,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,//\"2\r\n  0x40,0xC0,0x78,0x40,0xC0,0x78,0x40,0x00,0x04,0x3F,0x04,0x04,0x3F,0x04,0x04,0x00,//#3\r\n  0x00,0x70,0x88,0xFC,0x08,0x30,0x00,0x00,0x00,0x18,0x20,0xFF,0x21,0x1E,0x00,0x00,//$4\r\n  0xF0,0x08,0xF0,0x00,0xE0,0x18,0x00,0x00,0x00,0x21,0x1C,0x03,0x1E,0x21,0x1E,0x00,//%5\r\n  0x00,0xF0,0x08,0x88,0x70,0x00,0x00,0x00,0x1E,0x21,0x23,0x24,0x19,0x27,0x21,0x10,//&6\r\n  0x10,0x16,0x0E,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,//'7\r\n  0x00,0x00,0x00,0xE0,0x18,0x04,0x02,0x00,0x00,0x00,0x00,0x07,0x18,0x20,0x40,0x00,//(8\r\n  0x00,0x02,0x04,0x18,0xE0,0x00,0x00,0x00,0x00,0x40,0x20,0x18,0x07,0x00,0x00,0x00,//)9\r\n  0x40,0x40,0x80,0xF0,0x80,0x40,0x40,0x00,0x02,0x02,0x01,0x0F,0x01,0x02,0x02,0x00,//*10\r\n  0x00,0x00,0x00,0xF0,0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x1F,0x01,0x01,0x01,0x00,//+11\r\n  0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xB0,0x70,0x00,0x00,0x00,0x00,0x00,//,12\r\n  0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x01,0x01,0x01,0x01,//-13\r\n  0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x00,0x00,//.14\r\n  0x00,0x00,0x00,0x00,0x80,0x60,0x18,0x04,0x00,0x60,0x18,0x06,0x01,0x00,0x00,0x00,///15\r\n  0x00,0xE0,0x10,0x08,0x08,0x10,0xE0,0x00,0x00,0x0F,0x10,0x20,0x20,0x10,0x0F,0x00,//016\r\n  0x00,0x10,0x10,0xF8,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x3F,0x20,0x20,0x00,0x00,//117\r\n  0x00,0x70,0x08,0x08,0x08,0x88,0x70,0x00,0x00,0x30,0x28,0x24,0x22,0x21,0x30,0x00,//218\r\n  0x00,0x30,0x08,0x88,0x88,0x48,0x30,0x00,0x00,0x18,0x20,0x20,0x20,0x11,0x0E,0x00,//319\r\n  0x00,0x00,0xC0,0x20,0x10,0xF8,0x00,0x00,0x00,0x07,0x04,0x24,0x24,0x3F,0x24,0x00,//420\r\n  0x00,0xF8,0x08,0x88,0x88,0x08,0x08,0x00,0x00,0x19,0x21,0x20,0x20,0x11,0x0E,0x00,//521\r\n  0x00,0xE0,0x10,0x88,0x88,0x18,0x00,0x00,0x00,0x0F,0x11,0x20,0x20,0x11,0x0E,0x00,//622\r\n  0x00,0x38,0x08,0x08,0xC8,0x38,0x08,0x00,0x00,0x00,0x00,0x3F,0x00,0x00,0x00,0x00,//723\r\n  0x00,0x70,0x88,0x08,0x08,0x88,0x70,0x00,0x00,0x1C,0x22,0x21,0x21,0x22,0x1C,0x00,//824\r\n  0x00,0xE0,0x10,0x08,0x08,0x10,0xE0,0x00,0x00,0x00,0x31,0x22,0x22,0x11,0x0F,0x00,//925\r\n  0x00,0x00,0x00,0xC0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,//:26\r\n  0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x60,0x00,0x00,0x00,0x00,//;27\r\n  0x00,0x00,0x80,0x40,0x20,0x10,0x08,0x00,0x00,0x01,0x02,0x04,0x08,0x10,0x20,0x00,//<28\r\n  0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x00,//=29\r\n  0x00,0x08,0x10,0x20,0x40,0x80,0x00,0x00,0x00,0x20,0x10,0x08,0x04,0x02,0x01,0x00,//>30\r\n  0x00,0x70,0x48,0x08,0x08,0x08,0xF0,0x00,0x00,0x00,0x00,0x30,0x36,0x01,0x00,0x00,//?31\r\n  0xC0,0x30,0xC8,0x28,0xE8,0x10,0xE0,0x00,0x07,0x18,0x27,0x24,0x23,0x14,0x0B,0x00,//@32\r\n  0x00,0x00,0xC0,0x38,0xE0,0x00,0x00,0x00,0x20,0x3C,0x23,0x02,0x02,0x27,0x38,0x20,//A33\r\n  0x08,0xF8,0x88,0x88,0x88,0x70,0x00,0x00,0x20,0x3F,0x20,0x20,0x20,0x11,0x0E,0x00,//B34\r\n  0xC0,0x30,0x08,0x08,0x08,0x08,0x38,0x00,0x07,0x18,0x20,0x20,0x20,0x10,0x08,0x00,//C35\r\n  0x08,0xF8,0x08,0x08,0x08,0x10,0xE0,0x00,0x20,0x3F,0x20,0x20,0x20,0x10,0x0F,0x00,//D36\r\n  0x08,0xF8,0x88,0x88,0xE8,0x08,0x10,0x00,0x20,0x3F,0x20,0x20,0x23,0x20,0x18,0x00,//E37\r\n  0x08,0xF8,0x88,0x88,0xE8,0x08,0x10,0x00,0x20,0x3F,0x20,0x00,0x03,0x00,0x00,0x00,//F38\r\n  0xC0,0x30,0x08,0x08,0x08,0x38,0x00,0x00,0x07,0x18,0x20,0x20,0x22,0x1E,0x02,0x00,//G39\r\n  0x08,0xF8,0x08,0x00,0x00,0x08,0xF8,0x08,0x20,0x3F,0x21,0x01,0x01,0x21,0x3F,0x20,//H40\r\n  0x00,0x08,0x08,0xF8,0x08,0x08,0x00,0x00,0x00,0x20,0x20,0x3F,0x20,0x20,0x00,0x00,//I41\r\n  0x00,0x00,0x08,0x08,0xF8,0x08,0x08,0x00,0xC0,0x80,0x80,0x80,0x7F,0x00,0x00,0x00,//J42\r\n  0x08,0xF8,0x88,0xC0,0x28,0x18,0x08,0x00,0x20,0x3F,0x20,0x01,0x26,0x38,0x20,0x00,//K43\r\n  0x08,0xF8,0x08,0x00,0x00,0x00,0x00,0x00,0x20,0x3F,0x20,0x20,0x20,0x20,0x30,0x00,//L44\r\n  0x08,0xF8,0xF8,0x00,0xF8,0xF8,0x08,0x00,0x20,0x3F,0x00,0x3F,0x00,0x3F,0x20,0x00,//M45\r\n  0x08,0xF8,0x30,0xC0,0x00,0x08,0xF8,0x08,0x20,0x3F,0x20,0x00,0x07,0x18,0x3F,0x00,//N46\r\n  0xE0,0x10,0x08,0x08,0x08,0x10,0xE0,0x00,0x0F,0x10,0x20,0x20,0x20,0x10,0x0F,0x00,//O47\r\n  0x08,0xF8,0x08,0x08,0x08,0x08,0xF0,0x00,0x20,0x3F,0x21,0x01,0x01,0x01,0x00,0x00,//P48\r\n  0xE0,0x10,0x08,0x08,0x08,0x10,0xE0,0x00,0x0F,0x18,0x24,0x24,0x38,0x50,0x4F,0x00,//Q49\r\n  0x08,0xF8,0x88,0x88,0x88,0x88,0x70,0x00,0x20,0x3F,0x20,0x00,0x03,0x0C,0x30,0x20,//R50\r\n  0x00,0x70,0x88,0x08,0x08,0x08,0x38,0x00,0x00,0x38,0x20,0x21,0x21,0x22,0x1C,0x00,//S51\r\n  0x18,0x08,0x08,0xF8,0x08,0x08,0x18,0x00,0x00,0x00,0x20,0x3F,0x20,0x00,0x00,0x00,//T52\r\n  0x08,0xF8,0x08,0x00,0x00,0x08,0xF8,0x08,0x00,0x1F,0x20,0x20,0x20,0x20,0x1F,0x00,//U53\r\n  0x08,0x78,0x88,0x00,0x00,0xC8,0x38,0x08,0x00,0x00,0x07,0x38,0x0E,0x01,0x00,0x00,//V54\r\n  0xF8,0x08,0x00,0xF8,0x00,0x08,0xF8,0x00,0x03,0x3C,0x07,0x00,0x07,0x3C,0x03,0x00,//W55\r\n  0x08,0x18,0x68,0x80,0x80,0x68,0x18,0x08,0x20,0x30,0x2C,0x03,0x03,0x2C,0x30,0x20,//X56\r\n  0x08,0x38,0xC8,0x00,0xC8,0x38,0x08,0x00,0x00,0x00,0x20,0x3F,0x20,0x00,0x00,0x00,//Y57\r\n  0x10,0x08,0x08,0x08,0xC8,0x38,0x08,0x00,0x20,0x38,0x26,0x21,0x20,0x20,0x18,0x00,//Z58\r\n  0x00,0x00,0x00,0xFE,0x02,0x02,0x02,0x00,0x00,0x00,0x00,0x7F,0x40,0x40,0x40,0x00,//[59\r\n  0x00,0x0C,0x30,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x06,0x38,0xC0,0x00,//\\60\r\n  0x00,0x02,0x02,0x02,0xFE,0x00,0x00,0x00,0x00,0x40,0x40,0x40,0x7F,0x00,0x00,0x00,//]61\r\n  0x00,0x00,0x04,0x02,0x02,0x02,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,//^62\r\n  0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,//_63\r\n  0x00,0x02,0x02,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,//`64\r\n  0x00,0x00,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x19,0x24,0x22,0x22,0x22,0x3F,0x20,//a65\r\n  0x08,0xF8,0x00,0x80,0x80,0x00,0x00,0x00,0x00,0x3F,0x11,0x20,0x20,0x11,0x0E,0x00,//b66\r\n  0x00,0x00,0x00,0x80,0x80,0x80,0x00,0x00,0x00,0x0E,0x11,0x20,0x20,0x20,0x11,0x00,//c67\r\n  0x00,0x00,0x00,0x80,0x80,0x88,0xF8,0x00,0x00,0x0E,0x11,0x20,0x20,0x10,0x3F,0x20,//d68\r\n  0x00,0x00,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x1F,0x22,0x22,0x22,0x22,0x13,0x00,//e69\r\n  0x00,0x80,0x80,0xF0,0x88,0x88,0x88,0x18,0x00,0x20,0x20,0x3F,0x20,0x20,0x00,0x00,//f70\r\n  0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x00,0x00,0x6B,0x94,0x94,0x94,0x93,0x60,0x00,//g71\r\n  0x08,0xF8,0x00,0x80,0x80,0x80,0x00,0x00,0x20,0x3F,0x21,0x00,0x00,0x20,0x3F,0x20,//h72\r\n  0x00,0x80,0x98,0x98,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x3F,0x20,0x20,0x00,0x00,//i73\r\n  0x00,0x00,0x00,0x80,0x98,0x98,0x00,0x00,0x00,0xC0,0x80,0x80,0x80,0x7F,0x00,0x00,//j74\r\n  0x08,0xF8,0x00,0x00,0x80,0x80,0x80,0x00,0x20,0x3F,0x24,0x02,0x2D,0x30,0x20,0x00,//k75\r\n  0x00,0x08,0x08,0xF8,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x3F,0x20,0x20,0x00,0x00,//l76\r\n  0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x00,0x20,0x3F,0x20,0x00,0x3F,0x20,0x00,0x3F,//m77\r\n  0x80,0x80,0x00,0x80,0x80,0x80,0x00,0x00,0x20,0x3F,0x21,0x00,0x00,0x20,0x3F,0x20,//n78\r\n  0x00,0x00,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x1F,0x20,0x20,0x20,0x20,0x1F,0x00,//o79\r\n  0x80,0x80,0x00,0x80,0x80,0x00,0x00,0x00,0x80,0xFF,0xA1,0x20,0x20,0x11,0x0E,0x00,//p80\r\n  0x00,0x00,0x00,0x80,0x80,0x80,0x80,0x00,0x00,0x0E,0x11,0x20,0x20,0xA0,0xFF,0x80,//q81\r\n  0x80,0x80,0x80,0x00,0x80,0x80,0x80,0x00,0x20,0x20,0x3F,0x21,0x20,0x00,0x01,0x00,//r82\r\n  0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x00,0x00,0x33,0x24,0x24,0x24,0x24,0x19,0x00,//s83\r\n  0x00,0x80,0x80,0xE0,0x80,0x80,0x00,0x00,0x00,0x00,0x00,0x1F,0x20,0x20,0x00,0x00,//t84\r\n  0x80,0x80,0x00,0x00,0x00,0x80,0x80,0x00,0x00,0x1F,0x20,0x20,0x20,0x10,0x3F,0x20,//unsigned char5\r\n  0x80,0x80,0x80,0x00,0x00,0x80,0x80,0x80,0x00,0x01,0x0E,0x30,0x08,0x06,0x01,0x00,//v86\r\n  0x80,0x80,0x00,0x80,0x00,0x80,0x80,0x80,0x0F,0x30,0x0C,0x03,0x0C,0x30,0x0F,0x00,//w87\r\n  0x00,0x80,0x80,0x00,0x80,0x80,0x80,0x00,0x00,0x20,0x31,0x2E,0x0E,0x31,0x20,0x00,//x88\r\n  0x80,0x80,0x80,0x00,0x00,0x80,0x80,0x80,0x80,0x81,0x8E,0x70,0x18,0x06,0x01,0x00,//y89\r\n  0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x00,0x00,0x21,0x30,0x2C,0x22,0x21,0x30,0x00,//z90\r\n  0x00,0x00,0x00,0x00,0x80,0x7C,0x02,0x02,0x00,0x00,0x00,0x00,0x00,0x3F,0x40,0x40,//{91\r\n  0x00,0x00,0x00,0x00,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x00,0x00,0x00,//|92\r\n  0x00,0x02,0x02,0x7C,0x80,0x00,0x00,0x00,0x00,0x40,0x40,0x3F,0x00,0x00,0x00,0x00,//}93\r\n  0x00,0x06,0x01,0x01,0x02,0x02,0x04,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,//~94\r\n\r\n};\r\n\r\n\r\n\r\nvoid LEDPIN_Init(void)    \r\n{\r\n /* LED_SCL_Init;\r\n  LED_SDA_Init;\r\n  LED_RST_Init;\r\n  LED_DC_Init;*/\r\n  pinMode(SCL_PIN,OUTPUT);\r\n  pinMode(SDA_PIN,OUTPUT);\r\n  pinMode(RST_PIN,OUTPUT);\r\n  pinMode(DC_PIN,OUTPUT);\r\n}\r\nvoid LED_WrDat(unsigned char data)   \r\n{\r\n  unsigned char i = 8;\r\n  //LED_CS=0;\r\n  //LED_DCH;;;\r\n        digitalWrite(DC_PIN,HIGH);\r\n  //LED_SCLL;;; \r\n        digitalWrite(SCL_PIN,LOW);\r\n  while (i--)\r\n  {\r\n    if (data & 0x80)\r\n    {\r\n      digitalWrite(SDA_PIN,HIGH);;;;\r\n    }\r\n    else\r\n    {\r\n      digitalWrite(SDA_PIN,LOW);;;\r\n    }\r\n    //LED_SCLH;;; \r\n                digitalWrite(SCL_PIN,HIGH);;;\r\n    asm(\"nop\");;;     \r\n    //LED_SCLL;;;\r\n                digitalWrite(SCL_PIN,LOW);\r\n    data <<= 1;    \r\n  }\r\n  //LED_CS=1;\r\n}\r\nvoid LED_WrCmd(unsigned char cmd) \r\n{\r\n  unsigned char i = 8;\r\n  //LED_CS = 0;\r\n  //LED_DCL;;;\r\n        digitalWrite(DC_PIN,LOW);;;\r\n  //LED_SCLL;;;\r\n  digitalWrite(SCL_PIN,LOW);;;\r\n         while (i--)\r\n  {\r\n    if (cmd & 0x80)\r\n    {\r\n      //LED_SDAH;;;\r\n                      digitalWrite(SDA_PIN,HIGH);;;\r\n    }\r\n    else\r\n    {\r\n      //LED_SDAL;;;\r\n                      digitalWrite(SDA_PIN,LOW);;;\r\n    }\r\n    //LED_SCLH;;;\r\n    digitalWrite(SCL_PIN,HIGH);;;\r\n                asm(\"nop\");;;           \r\n    //LED_SCLL;;;\r\n                digitalWrite(SCL_PIN,LOW);;;\r\n    cmd <<= 1;   \r\n  }   \r\n  //LED_CS = 1;\r\n}\r\nvoid LED_Set_Pos(unsigned char x, unsigned char y)\r\n{ \r\n  LED_WrCmd(0xb0+y);\r\n  LED_WrCmd(((x&0xf0)>>4)|0x10);\r\n  LED_WrCmd((x&0x0f)|0x00); \r\n} \r\n\r\n\r\nvoid LED_Fill(unsigned char bmp_data)\r\n{\r\n  unsigned char y,x;\r\n  \r\n  for(y=0;y<8;y++)\r\n  {\r\n    LED_WrCmd(0xb0+y);  \r\n    LED_WrCmd(0x00);     \r\n    LED_WrCmd(0x10);       \r\n    for(x=0;x<128;x++)\r\n      LED_WrDat(bmp_data);\r\n  }\r\n} \r\n\r\n\r\n\r\nvoid LED_CLS(void) \r\n{\r\n  unsigned char y,x;  \r\n  for(y=0;y<8;y++)\r\n  {\r\n    LED_WrCmd(0xb0+y);\r\n    LED_WrCmd(0x00);\r\n    LED_WrCmd(0x10); \r\n    for(x=0;x<128;x++)\r\n      LED_WrDat(0);\r\n  }\r\n}\r\n\r\nvoid LED_DLY_ms(unsigned int ms)\r\n{                         \r\n  unsigned int a;\r\n  while(ms)\r\n  {\r\n    a=6675;\r\n    while(a--);\r\n    ms--;\r\n  }\r\n  return;\r\n//  time_delay_ms(ms);\r\n}\r\n\r\nvoid SetStartColumn(unsigned char d)\r\n{\r\n  LED_WrCmd(0x00+d%16); // Set Lower Column Start Address for Page Addressing Mode\r\n              // Default => 0x00\r\n  LED_WrCmd(0x10+d/16); // Set Higher Column Start Address for Page Addressing Mode\r\n              // Default => 0x10\r\n}\r\n\r\nvoid SetAddressingMode(unsigned char d)\r\n{\r\n  LED_WrCmd(0x20);      // Set Memory Addressing Mode\r\n  LED_WrCmd(d);     // Default => 0x02\r\n              // 0x00 => Horizontal Addressing Mode\r\n              // 0x01 => Vertical Addressing Mode\r\n              // 0x02 => Page Addressing Mode\r\n}\r\n\r\nvoid SetColumnAddress(unsigned char a, unsigned char b)\r\n{\r\n  LED_WrCmd(0x21);      // Set Column Address\r\n  LED_WrCmd(a);     // Default => 0x00 (Column Start Address)\r\n  LED_WrCmd(b);     // Default => 0x7F (Column End Address)\r\n}\r\n\r\nvoid SetPageAddress(unsigned char a, unsigned char b)\r\n{\r\n  LED_WrCmd(0x22);      // Set Page Address\r\n  LED_WrCmd(a);     // Default => 0x00 (Page Start Address)\r\n  LED_WrCmd(b);     // Default => 0x07 (Page End Address)\r\n}\r\n\r\nvoid SetStartLine(unsigned char d)\r\n{\r\n  LED_WrCmd(0x40|d);    // Set Display Start Line\r\n              // Default => 0x40 (0x00)\r\n}\r\n\r\nvoid SetContrastControl(unsigned char d)\r\n{\r\n  LED_WrCmd(0x81);      // Set Contrast Control\r\n  LED_WrCmd(d);     // Default => 0x7F\r\n}\r\n\r\nvoid Set_Charge_Pump(unsigned char d)\r\n{\r\n  LED_WrCmd(0x8D);      // Set Charge Pump\r\n  LED_WrCmd(0x10|d);    // Default => 0x10\r\n              // 0x10 (0x00) => Disable Charge Pump\r\n              // 0x14 (0x04) => Enable Charge Pump\r\n}\r\n\r\nvoid Set_Segment_Remap(unsigned char d)\r\n{\r\n  LED_WrCmd(0xA0|d);    // Set Segment Re-Map\r\n              // Default => 0xA0\r\n              // 0xA0 (0x00) => Column Address 0 Mapped to SEG0\r\n              // 0xA1 (0x01) => Column Address 0 Mapped to SEG127\r\n}\r\n\r\nvoid Set_Entire_Display(unsigned char d)\r\n{\r\n  LED_WrCmd(0xA4|d);    // Set Entire Display On / Off\r\n              // Default => 0xA4\r\n              // 0xA4 (0x00) => Normal Display\r\n              // 0xA5 (0x01) => Entire Display On\r\n}\r\n\r\nvoid Set_Inverse_Display(unsigned char d)\r\n{\r\n  LED_WrCmd(0xA6|d);    // Set Inverse Display On/Off\r\n              // Default => 0xA6\r\n              // 0xA6 (0x00) => Normal Display\r\n              // 0xA7 (0x01) => Inverse Display On\r\n}\r\n\r\nvoid Set_Multiplex_Ratio(unsigned char d)\r\n{\r\n  LED_WrCmd(0xA8);      // Set Multiplex Ratio\r\n  LED_WrCmd(d);     // Default => 0x3F (1/64 Duty)\r\n}\r\n\r\nvoid Set_Display_On_Off(unsigned char d)\r\n{\r\n  LED_WrCmd(0xAE|d);    // Set Display On/Off\r\n              // Default => 0xAE\r\n              // 0xAE (0x00) => Display Off\r\n              // 0xAF (0x01) => Display On\r\n}\r\n\r\nvoid SetStartPage(unsigned char d)\r\n{\r\n  LED_WrCmd(0xB0|d);    // Set Page Start Address for Page Addressing Mode\r\n              // Default => 0xB0 (0x00)\r\n}\r\n\r\nvoid Set_Common_Remap(unsigned char d)\r\n{\r\n  LED_WrCmd(0xC0|d);    // Set COM Output Scan Direction\r\n              // Default => 0xC0\r\n              // 0xC0 (0x00) => Scan from COM0 to 63\r\n              // 0xC8 (0x08) => Scan from COM63 to 0\r\n}\r\n\r\nvoid Set_Display_Offset(unsigned char d)\r\n{\r\n  LED_WrCmd(0xD3);      // Set Display Offset\r\n  LED_WrCmd(d);     // Default => 0x00\r\n}\r\n\r\nvoid Set_Display_Clock(unsigned char d)\r\n{\r\n  LED_WrCmd(0xD5);      // Set Display Clock Divide Ratio / Oscillator Frequency\r\n  LED_WrCmd(d);     // Default => 0x80\r\n              // D[3:0] => Display Clock Divider\r\n              // D[7:4] => Oscillator Frequency\r\n}\r\n\r\nvoid Set_Precharge_Period(unsigned char d)\r\n{\r\n  LED_WrCmd(0xD9);      // Set Pre-Charge Period\r\n  LED_WrCmd(d);     // Default => 0x22 (2 Display Clocks [Phase 2] / 2 Display Clocks [Phase 1])\r\n              // D[3:0] => Phase 1 Period in 1~15 Display Clocks\r\n              // D[7:4] => Phase 2 Period in 1~15 Display Clocks\r\n}\r\n\r\nvoid Set_Common_Config(unsigned char d)\r\n{\r\n  LED_WrCmd(0xDA);      // Set COM Pins Hardware Configuration\r\n  LED_WrCmd(0x02|d);    // Default => 0x12 (0x10)\r\n              // Alternative COM Pin Configuration\r\n              // Disable COM Left/Right Re-Map\r\n}\r\n\r\nvoid Set_VCOMH(unsigned char d)\r\n{\r\n  LED_WrCmd(0xDB);      // Set VCOMH Deselect Level\r\n  LED_WrCmd(d);     // Default => 0x20 (0.77*VCC)\r\n}\r\n\r\nvoid Set_NOP(void)\r\n{\r\n  LED_WrCmd(0xE3);      // Command for No Operation\r\n}\r\n\r\nvoid LED_Init(void)        \r\n{\r\n  unsigned char i;\r\n        LEDPIN_Init();\r\n//  LED_PORT=0X0F;\r\n  //LED_SCLH;;;   \r\n  //LED_RSTL;;;\r\n        digitalWrite(SCL_PIN,HIGH);;;\r\n        digitalWrite(RST_PIN,LOW);;;\r\n//  for(i=0;i<100;i++)asm(\"nop\");       \r\n        LED_DLY_ms(50);\r\n  //LED_RSTH;;;\r\n        digitalWrite(RST_PIN,HIGH);\r\n  Set_Display_On_Off(0x00);     // Display Off (0x00/0x01)\r\n  Set_Display_Clock(0x80);      // Set Clock as 100 Frames/Sec\r\n  Set_Multiplex_Ratio(0x3F);    // 1/64 Duty (0x0F~0x3F)\r\n  Set_Display_Offset(0x00);     // Shift Mapping RAM Counter (0x00~0x3F)\r\n  SetStartLine(0x00);       // Set Mapping RAM Display Start Line (0x00~0x3F)\r\n  Set_Charge_Pump(0x04);      // Enable Embedded DC/DC Converter (0x00/0x04)\r\n  SetAddressingMode(0x02);    // Set Page Addressing Mode (0x00/0x01/0x02)\r\n  Set_Segment_Remap(0x01);    // Set SEG/Column Mapping  \r\n  Set_Common_Remap(0x08);   // Set COM/Row Scan Direction \r\n  Set_Common_Config(0x10);    // Set Sequential Configuration (0x00/0x10)\r\n  SetContrastControl(0xCF); // Set SEG Output Current\r\n  Set_Precharge_Period(0xF1);   // Set Pre-Charge as 15 Clocks & Discharge as 1 Clock\r\n  Set_VCOMH(0x40);        // Set VCOM Deselect Level\r\n  Set_Entire_Display(0x00);     // Disable Entire Display On (0x00/0x01)\r\n  Set_Inverse_Display(0x00);    // Disable Inverse Display On (0x00/0x01)  \r\n  Set_Display_On_Off(0x01);     // Display On (0x00/0x01)\r\n  LED_Fill(0x00);                               //clear all\r\n  LED_Set_Pos(0,0);   \r\n} \r\n \r\n\r\nvoid LED_P6x8Char(unsigned char x,unsigned char y,unsigned char ch)\r\n{\r\n   unsigned char c=0,i=0,j=0;     \r\n     \r\n  c =ch-32;\r\n  if(x>122)\r\n  {\r\n    x=0;\r\n    y++;\r\n  }\r\n  LED_Set_Pos(x,y);    \r\n  for(i=0;i<6;i++)\r\n  {     \r\n    LED_WrDat(F6x8[c][i]);  \r\n  }\r\n}\r\n\r\nvoid LED_P6x8Str(unsigned char x,unsigned char y,char ch[])\r\n{\r\n  unsigned char c=0,i=0,j=0;      \r\n  while (ch[j]!='\\0')\r\n  {    \r\n    c =ch[j]-32;\r\n    if(x>126)\r\n    {\r\n      x=0;\r\n      y++;\r\n    }\r\n    LED_Set_Pos(x,y);    \r\n    for(i=0;i<6;i++)\r\n    {     \r\n      LED_WrDat(F6x8[c][i]);  \r\n    }\r\n    x+=6;\r\n    j++;\r\n  }\r\n}\r\n\r\nvoid LED_P8x16Str(unsigned char x,unsigned char y,char ch[])\r\n{\r\n  unsigned char c=0,i=0,j=0;\r\n  while (ch[j]!='\\0')\r\n  {    \r\n    c =ch[j]-32;\r\n    if(x>120)\r\n    {\r\n      x=0;\r\n      y++;\r\n    }\r\n    LED_Set_Pos(x,y);    \r\n    for(i=0;i<8;i++) \r\n    {\r\n      LED_WrDat(F8X16[(c<<4)+i]);\r\n    }\r\n    LED_Set_Pos(x,y+1);    \r\n    for(i=0;i<8;i++) \r\n    {\r\n      LED_WrDat(F8X16[(c<<4)+i+8]);\r\n    }\r\n    x+=8;\r\n    j++;\r\n  }\r\n}\r\n\r\n\r\n\r\nvoid LED_PrintBMP(unsigned char x0,unsigned char y0,unsigned char x1,unsigned char y1,unsigned char bmp[])\r\n{   \r\n  int ii=0;\r\n  unsigned char x,y;\r\n  for(y=y0;y<=y1;y++)\r\n  {\r\n    LED_Set_Pos(x0,y);        \r\n    for(x=x0;x<x1;x++)\r\n    {      \r\n      LED_WrDat(bmp[ii++]);       \r\n    }\r\n  }\r\n}\r\n\r\nvoid LED_PrintValueC(unsigned char x, unsigned char y, char data)\r\n{\r\n  unsigned char i,j,k;\r\n  if(data < 0)\r\n  {\r\n    LED_P6x8Char(x,y,'-');\r\n    data = - data;  \r\n  }\r\n  else\r\n  {\r\n    LED_P6x8Char(x,y,'+');\r\n  }\r\n  i = data/100;\r\n  j = (data%100)/10;\r\n  k = data%10;\r\n  LED_P6x8Char(x+6,y,i+48);\r\n  LED_P6x8Char(x+12,y,j+48);\r\n  LED_P6x8Char(x+18,y,k+48);    \r\n}\r\n\r\n\r\nvoid LED_PrintValueI(unsigned char x, unsigned char y, int data)\r\n{\r\n  unsigned char i,j,k,l,m;  \r\n  if(data < 0)\r\n  {\r\n    LED_P6x8Char(x,y,'-');\r\n    data = - data;  \r\n  }\r\n  else\r\n  {\r\n    LED_P6x8Char(x,y,'+');\r\n  }\r\n  \r\n  l  = data/10000;\r\n  m= (data%10000)/1000;\r\n  i = (data%1000)/100;\r\n  j = (data%100)/10;\r\n  k = data%10;\r\n  LED_P6x8Char(x+6,y,l+48);\r\n  LED_P6x8Char(x+12,y,m+48);\r\n  LED_P6x8Char(x+18,y,i+48);\r\n  LED_P6x8Char(x+24,y,j+48);\r\n  LED_P6x8Char(x+30,y,k+48);    \r\n}\r\n\r\n void LED_PrintValueFP(unsigned char x, unsigned char y, unsigned int data, unsigned char num)\r\n {\r\n  unsigned char m,i,j,k;    \r\n  LED_P6x8Char(x, y, '.');\r\n  m= data/1000;\r\n  i = (data%1000)/100;\r\n  j = (data%100)/10;\r\n  k = data%10;\r\n  switch(num)\r\n  {\r\n    case 1:   LED_P6x8Char(x+6,y,k+48);\r\n        break;\r\n    case 2:   LED_P6x8Char(x+6,y,j+48);\r\n        LED_P6x8Char(x+12,y,k+48);\r\n        break;\r\n    case 3: LED_P6x8Char(x+6,y,i+48);\r\n        LED_P6x8Char(x+12,y,j+48);\r\n        LED_P6x8Char(x+18,y,k+48);\r\n        break;\r\n    case 4:   LED_P6x8Char(x+6,y,m+48);\r\n        LED_P6x8Char(x+12,y,i+48);\r\n        LED_P6x8Char(x+18,y,j+48);\r\n        LED_P6x8Char(x+24,y,k+48);\r\n        break;  \r\n  }\r\n }\r\n\r\n\r\n void LED_PrintValueF(unsigned char x, unsigned char y, float data, unsigned char num)\r\n {\r\n  unsigned char l,m,i,j,k;  \r\n  unsigned char databiti = 6; \r\n  unsigned int tempdataui = 0;\r\n    int tempdataii = (int)data; \r\n  long int tempdatalp = (long int)((data - (int)data)*10000); \r\n  \r\n\r\n  if(data < 0.0000001)  LED_P6x8Char(x, y,'-'); \r\n  else LED_P6x8Char(x, y,'+');\r\n  if(tempdataii < 0)tempdataii = - tempdataii;  \r\n  tempdataui = tempdataii;\r\n  l  = tempdataui/10000;\r\n  m= (tempdataui%10000)/1000;\r\n  i = (tempdataui%1000)/100;\r\n  j = (tempdataui%100)/10;\r\n  k = tempdataui%10;\r\n  if (l != 0) \r\n  {\r\n    LED_P6x8Char(x+6,y,l+48);\r\n    LED_P6x8Char(x+12,y,m+48);\r\n    LED_P6x8Char(x+18,y,i+48);\r\n    LED_P6x8Char(x+24,y,j+48);\r\n    LED_P6x8Char(x+30,y,k+48);\r\n  }\r\n  else if(m != 0) \r\n  {\r\n    databiti = 5;\r\n    LED_P6x8Char(x+6,y,m+48);\r\n    LED_P6x8Char(x+12,y,i+48);\r\n    LED_P6x8Char(x+18,y,j+48);\r\n    LED_P6x8Char(x+24,y,k+48);\r\n  }\r\n    else if(i != 0) \r\n    {\r\n      databiti = 4;\r\n      LED_P6x8Char(x+6,y,i+48);\r\n    LED_P6x8Char(x+12,y,j+48);\r\n    LED_P6x8Char(x+18,y,k+48);\r\n    }\r\n    else if(j != 0) \r\n    {\r\n        databiti = 3; \r\n      LED_P6x8Char(x+6,y,j+48);\r\n    LED_P6x8Char(x+12,y,k+48);\r\n    }\r\n  else  \r\n  {\r\n    databiti = 2;\r\n    LED_P6x8Char(x+6,y,k+48);\r\n  } \r\n  if(tempdatalp < 0)tempdatalp = - tempdatalp;  \r\n  switch(num)\r\n  {\r\n    case 0: break;\r\n    case 1:  LED_PrintValueFP(x + databiti * 6, y, (unsigned int)(tempdatalp / 1000),num);break;\r\n    case 2:  LED_PrintValueFP(x + databiti * 6, y, (unsigned int)(tempdatalp / 100),num);break;\r\n    case 3:  LED_PrintValueFP(x + databiti * 6, y, (unsigned int)(tempdatalp / 10),num);break;\r\n    case 4:  LED_PrintValueFP(x + databiti * 6, y, (unsigned int)(tempdatalp),num);break;         \r\n  }\r\n }\r\n\r\n void LED_Cursor(unsigned char cursor_column, unsigned char cursor_row)\r\n {  \r\n  if(cursor_row != 0) \r\n  {\r\n    if(cursor_column == 1) LED_Set_Pos(0, cursor_row + 2);\r\n    else  LED_Set_Pos(80 + (cursor_column - 2)*6, cursor_row + 2);\r\n    LED_WrDat(0xFF);\r\n    LED_WrDat(0xFF);\r\n    LED_WrDat(0xFF);\r\n    LED_WrDat(0xFF);\r\n    LED_WrDat(0xFF);\r\n    LED_WrDat(0xFF);           \r\n  }\r\n }\r\n void setup()\r\n {\r\n   LEDPIN_Init();\r\n   LED_Init();\r\n }\r\n void loop()\r\n {\r\n  //  LED_P8x16Str(20,0,\"Hello\");\r\n   // LED_P8x16Str(40,2,\"World\");\r\n   // LED_P8x16Str(20,4,\"Test\");\r\n   LED_P6x8Str(20,0,\"Hello World\");\r\n }\r\n "},"comment":{"url":"https://api.github.com/repos/olikraus/u8glib/issues/comments/150900373","html_url":"https://github.com/olikraus/u8glib/issues/371#issuecomment-150900373","issue_url":"https://api.github.com/repos/olikraus/u8glib/issues/371","id":150900373,"user":{"login":"olikraus","id":1084992,"avatar_url":"https://avatars.githubusercontent.com/u/1084992?v=3","gravatar_id":"","url":"https://api.github.com/users/olikraus","html_url":"https://github.com/olikraus","followers_url":"https://api.github.com/users/olikraus/followers","following_url":"https://api.github.com/users/olikraus/following{/other_user}","gists_url":"https://api.github.com/users/olikraus/gists{/gist_id}","starred_url":"https://api.github.com/users/olikraus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/olikraus/subscriptions","organizations_url":"https://api.github.com/users/olikraus/orgs","repos_url":"https://api.github.com/users/olikraus/repos","events_url":"https://api.github.com/users/olikraus/events{/privacy}","received_events_url":"https://api.github.com/users/olikraus/received_events","type":"User","site_admin":false},"created_at":"2015-10-25T08:27:20Z","updated_at":"2015-10-25T08:27:20Z","body":"Hi\r\nI am confused. Your pictures show an SPI OLED, but you tested I2C? You should use the SPI constructors.\r\n\r\nOliver"}}