e-paper whereabouts board program

Dependencies:   SDFileSystem mbed

Committer:
kohacraft
Date:
Tue May 23 22:40:04 2017 +0000
Revision:
2:9150515ecd68
Parent:
1:cb28911c7ba5
bug fix

Who changed what in which revision?

UserRevisionLine numberNew contents of line
kohacraft 1:cb28911c7ba5 1 /* EDP control program */
kohacraft 1:cb28911c7ba5 2
kohacraft 0:e4c67c26ba3f 3 #include "mbed.h"
kohacraft 0:e4c67c26ba3f 4 #include "extdio.h"
kohacraft 0:e4c67c26ba3f 5 #include "eink.h"
kohacraft 0:e4c67c26ba3f 6
kohacraft 1:cb28911c7ba5 7 int clPulseCount = 0; //for CL pluse count
kohacraft 0:e4c67c26ba3f 8
kohacraft 1:cb28911c7ba5 9 //Initialize the port
kohacraft 0:e4c67c26ba3f 10 void initPort()
kohacraft 0:e4c67c26ba3f 11 {
kohacraft 0:e4c67c26ba3f 12 setCL( 0 );
kohacraft 1:cb28911c7ba5 13 setContBus( LE , 0);
kohacraft 1:cb28911c7ba5 14 setContBus( OE , 0);
kohacraft 1:cb28911c7ba5 15 setContBus( NC10 , 1);
kohacraft 1:cb28911c7ba5 16 setContBus( SPH , 1);
kohacraft 0:e4c67c26ba3f 17
kohacraft 1:cb28911c7ba5 18 setContBus( GMODE , 0);
kohacraft 1:cb28911c7ba5 19 setContBus( SPV , 1);
kohacraft 1:cb28911c7ba5 20 setContBus( CKV , 0);
kohacraft 1:cb28911c7ba5 21 setContBus( EN , 0);
kohacraft 1:cb28911c7ba5 22
kohacraft 1:cb28911c7ba5 23 setDataBus( 0b00000001 );
kohacraft 1:cb28911c7ba5 24 setDataBus( 0b00000000 );
kohacraft 0:e4c67c26ba3f 25
kohacraft 1:cb28911c7ba5 26 return;
kohacraft 0:e4c67c26ba3f 27 }
kohacraft 0:e4c67c26ba3f 28
kohacraft 1:cb28911c7ba5 29 //page start sequence
kohacraft 0:e4c67c26ba3f 30 void pageStart()
kohacraft 0:e4c67c26ba3f 31 {
kohacraft 0:e4c67c26ba3f 32
kohacraft 1:cb28911c7ba5 33 setContBus( GMODE , 1 );
kohacraft 1:cb28911c7ba5 34 setContBus( CKV , 1 );
kohacraft 0:e4c67c26ba3f 35 wait_us(11);
kohacraft 1:cb28911c7ba5 36 setContBus( SPV , 0 );
kohacraft 0:e4c67c26ba3f 37 wait_us(11);
kohacraft 1:cb28911c7ba5 38 setContBus( CKV , 0 );
kohacraft 0:e4c67c26ba3f 39 wait_us(10);
kohacraft 1:cb28911c7ba5 40 setContBus( CKV , 1 );
kohacraft 0:e4c67c26ba3f 41 wait_us(10);
kohacraft 1:cb28911c7ba5 42 setContBus( SPV , 1 );
kohacraft 0:e4c67c26ba3f 43 wait_us(12);
kohacraft 0:e4c67c26ba3f 44
kohacraft 1:cb28911c7ba5 45 setContBus( CKV , 0 );
kohacraft 0:e4c67c26ba3f 46 wait_us(10);
kohacraft 1:cb28911c7ba5 47 setContBus( CKV , 1 );
kohacraft 0:e4c67c26ba3f 48 wait_us(22);
kohacraft 1:cb28911c7ba5 49 setContBus( CKV , 0 );
kohacraft 0:e4c67c26ba3f 50 wait_us(10);
kohacraft 1:cb28911c7ba5 51 setContBus( CKV , 1 );
kohacraft 0:e4c67c26ba3f 52 wait_us(22);
kohacraft 1:cb28911c7ba5 53 setContBus( CKV , 0 );
kohacraft 0:e4c67c26ba3f 54 wait_us(10);
kohacraft 1:cb28911c7ba5 55 setContBus( CKV , 1 );
kohacraft 0:e4c67c26ba3f 56 wait_us(1);
kohacraft 1:cb28911c7ba5 57
kohacraft 1:cb28911c7ba5 58 return;
kohacraft 0:e4c67c26ba3f 59 }
kohacraft 0:e4c67c26ba3f 60
kohacraft 1:cb28911c7ba5 61 //line startsequence
kohacraft 0:e4c67c26ba3f 62 void lineStart()
kohacraft 0:e4c67c26ba3f 63 {
kohacraft 0:e4c67c26ba3f 64
kohacraft 1:cb28911c7ba5 65 setContBus( LE , 0 );
kohacraft 1:cb28911c7ba5 66 setContBus( OE , 1 );
kohacraft 1:cb28911c7ba5 67 setContBus( SPH , 0 );
kohacraft 0:e4c67c26ba3f 68
kohacraft 1:cb28911c7ba5 69 clPulseCount = 0;
kohacraft 1:cb28911c7ba5 70
kohacraft 1:cb28911c7ba5 71 return;
kohacraft 1:cb28911c7ba5 72 }
kohacraft 0:e4c67c26ba3f 73
kohacraft 1:cb28911c7ba5 74 //center of line sequence
kohacraft 1:cb28911c7ba5 75 void changeSPH()
kohacraft 1:cb28911c7ba5 76 {
kohacraft 1:cb28911c7ba5 77 setContBus( SPH , 1 );
kohacraft 1:cb28911c7ba5 78 setContBus( NC10 , 0 );
kohacraft 0:e4c67c26ba3f 79
kohacraft 1:cb28911c7ba5 80 return;
kohacraft 1:cb28911c7ba5 81 }
kohacraft 0:e4c67c26ba3f 82
kohacraft 1:cb28911c7ba5 83 //4bit draw sequence
kohacraft 1:cb28911c7ba5 84 void setDrawData( char data )
kohacraft 1:cb28911c7ba5 85 {
kohacraft 1:cb28911c7ba5 86 setDataBus( data );
kohacraft 0:e4c67c26ba3f 87 setCL( 1 );
kohacraft 0:e4c67c26ba3f 88 setCL( 0 );
kohacraft 1:cb28911c7ba5 89
kohacraft 1:cb28911c7ba5 90 //SPH change when CL puls is 200
kohacraft 1:cb28911c7ba5 91 clPulseCount++;
kohacraft 1:cb28911c7ba5 92 if( clPulseCount == EDP_WIDTH/8 )
kohacraft 1:cb28911c7ba5 93 {
kohacraft 1:cb28911c7ba5 94 changeSPH();
kohacraft 1:cb28911c7ba5 95 }
kohacraft 1:cb28911c7ba5 96
kohacraft 1:cb28911c7ba5 97 return;
kohacraft 0:e4c67c26ba3f 98 }
kohacraft 0:e4c67c26ba3f 99
kohacraft 1:cb28911c7ba5 100 //end line sequence
kohacraft 0:e4c67c26ba3f 101 void lineEnd()
kohacraft 0:e4c67c26ba3f 102 {
kohacraft 1:cb28911c7ba5 103 setContBus( NC10 , 1 );
kohacraft 1:cb28911c7ba5 104 setContBus( CKV , 0 );
kohacraft 0:e4c67c26ba3f 105 wait_us(10);
kohacraft 0:e4c67c26ba3f 106
kohacraft 1:cb28911c7ba5 107 setContBus( OE , 0 );
kohacraft 1:cb28911c7ba5 108 setContBus( LE , 1 );
kohacraft 1:cb28911c7ba5 109 setContBus( CKV , 1 );
kohacraft 0:e4c67c26ba3f 110 wait_us(1);
kohacraft 0:e4c67c26ba3f 111 }
kohacraft 0:e4c67c26ba3f 112
kohacraft 1:cb28911c7ba5 113 //end page sequence
kohacraft 0:e4c67c26ba3f 114 void pageEnd()
kohacraft 0:e4c67c26ba3f 115 {
kohacraft 1:cb28911c7ba5 116 setContBus( LE , 0 );
kohacraft 1:cb28911c7ba5 117 setContBus( OE , 1 );
kohacraft 0:e4c67c26ba3f 118
kohacraft 1:cb28911c7ba5 119 for( int i=0 ; i<EDP_WIDTH/4 ; i++ )
kohacraft 0:e4c67c26ba3f 120 {
kohacraft 0:e4c67c26ba3f 121 setCL( 1 );
kohacraft 0:e4c67c26ba3f 122 setCL( 0 );
kohacraft 0:e4c67c26ba3f 123 }
kohacraft 1:cb28911c7ba5 124 setContBus( CKV , 0 );
kohacraft 0:e4c67c26ba3f 125 wait_us(10);
kohacraft 1:cb28911c7ba5 126 setContBus( OE , 0 );
kohacraft 0:e4c67c26ba3f 127 wait_us(330);
kohacraft 1:cb28911c7ba5 128 setContBus( GMODE , 0 );
kohacraft 0:e4c67c26ba3f 129 wait_us(130);
kohacraft 0:e4c67c26ba3f 130
kohacraft 0:e4c67c26ba3f 131 }
kohacraft 0:e4c67c26ba3f 132
kohacraft 0:e4c67c26ba3f 133
kohacraft 1:cb28911c7ba5 134 //trun off EDP
kohacraft 0:e4c67c26ba3f 135 void powerOff()
kohacraft 0:e4c67c26ba3f 136 {
kohacraft 1:cb28911c7ba5 137 setDataBus( 0b00000000 );
kohacraft 0:e4c67c26ba3f 138
kohacraft 0:e4c67c26ba3f 139 setCL( 0 );
kohacraft 1:cb28911c7ba5 140 setContBus( LE , 0);
kohacraft 1:cb28911c7ba5 141 setContBus( OE , 0);
kohacraft 1:cb28911c7ba5 142 setContBus( NC10 , 0);
kohacraft 1:cb28911c7ba5 143 setContBus( SPH , 0);
kohacraft 0:e4c67c26ba3f 144
kohacraft 1:cb28911c7ba5 145 setContBus( GMODE , 0);
kohacraft 1:cb28911c7ba5 146 setContBus( SPV , 0);
kohacraft 1:cb28911c7ba5 147 setContBus( CKV , 0);
kohacraft 0:e4c67c26ba3f 148
kohacraft 1:cb28911c7ba5 149 setContBus( EN , 1);
kohacraft 1:cb28911c7ba5 150
kohacraft 1:cb28911c7ba5 151 return;
kohacraft 0:e4c67c26ba3f 152
kohacraft 0:e4c67c26ba3f 153 }
kohacraft 0:e4c67c26ba3f 154
kohacraft 1:cb28911c7ba5 155 //turn on EDP
kohacraft 0:e4c67c26ba3f 156 void powerOn()
kohacraft 0:e4c67c26ba3f 157 {
kohacraft 1:cb28911c7ba5 158 setContBus( EN , 0);
kohacraft 1:cb28911c7ba5 159 wait_us(100);
kohacraft 1:cb28911c7ba5 160
kohacraft 1:cb28911c7ba5 161 return;
kohacraft 0:e4c67c26ba3f 162 }
kohacraft 0:e4c67c26ba3f 163
kohacraft 1:cb28911c7ba5 164 //fill color
kohacraft 1:cb28911c7ba5 165 //drawMode EDP_WHITE:white EDP_BLACK:black
kohacraft 1:cb28911c7ba5 166 void clrDisp( char drawMode )
kohacraft 0:e4c67c26ba3f 167 {
kohacraft 1:cb28911c7ba5 168 char data;
kohacraft 1:cb28911c7ba5 169 if( drawMode == EDP_WHITE)
kohacraft 1:cb28911c7ba5 170 data = 0b01010101; //all pixels white
kohacraft 1:cb28911c7ba5 171 else
kohacraft 1:cb28911c7ba5 172 data = 0b10101010; //all pixels black
kohacraft 1:cb28911c7ba5 173
kohacraft 0:e4c67c26ba3f 174 pageStart();
kohacraft 1:cb28911c7ba5 175 for( int j=0 ; j<EDP_HEIGHT ; j++)
kohacraft 0:e4c67c26ba3f 176 {
kohacraft 0:e4c67c26ba3f 177 lineStart();
kohacraft 1:cb28911c7ba5 178 for( int i=0 ; i<EDP_WIDTH ; i+=4 )
kohacraft 0:e4c67c26ba3f 179 {
kohacraft 1:cb28911c7ba5 180 setDrawData( data );
kohacraft 0:e4c67c26ba3f 181 }
kohacraft 0:e4c67c26ba3f 182 lineEnd();
kohacraft 0:e4c67c26ba3f 183
kohacraft 0:e4c67c26ba3f 184 }
kohacraft 0:e4c67c26ba3f 185 pageEnd();
kohacraft 1:cb28911c7ba5 186
kohacraft 1:cb28911c7ba5 187 return;
kohacraft 0:e4c67c26ba3f 188 }
kohacraft 0:e4c67c26ba3f 189
kohacraft 1:cb28911c7ba5 190 //draw 8pixels bmp data
kohacraft 1:cb28911c7ba5 191 // data: (MSB)b0A b0B b1A b1B b2A b2B b3A bB3(LSB)
kohacraft 1:cb28911c7ba5 192 // b0 b1 b2 b4:pixels
kohacraft 1:cb28911c7ba5 193 // AB: 10:black 01:white 00:transparent
kohacraft 1:cb28911c7ba5 194 // drawMode: EDP_BLACK draw black at black pixel and draw transparent at white pixel
kohacraft 1:cb28911c7ba5 195 // EDP_WHITE draw white at white pixel and draw transparent at black pixel
kohacraft 1:cb28911c7ba5 196 // EDP_BLACK_WHITE draw black at black pixel and draw white at white pixel
kohacraft 1:cb28911c7ba5 197 void drowPixels( char data , char drawMode )
kohacraft 0:e4c67c26ba3f 198 {
kohacraft 1:cb28911c7ba5 199 char _data = 0;
kohacraft 1:cb28911c7ba5 200 switch( drawMode )
kohacraft 0:e4c67c26ba3f 201 {
kohacraft 1:cb28911c7ba5 202 case EDP_BLACK :
kohacraft 1:cb28911c7ba5 203 _data = 0;
kohacraft 1:cb28911c7ba5 204 _data |= ((data&0x10)==0)<<7;
kohacraft 1:cb28911c7ba5 205 _data |= ((data&0x20)==0)<<5;
kohacraft 1:cb28911c7ba5 206 _data |= ((data&0x40)==0)<<3;
kohacraft 1:cb28911c7ba5 207 _data |= ((data&0x80)==0)<<1;
kohacraft 1:cb28911c7ba5 208 setDrawData( _data );
kohacraft 1:cb28911c7ba5 209 _data = 0;
kohacraft 1:cb28911c7ba5 210 _data |= ((data&0x01)==0)<<7;
kohacraft 1:cb28911c7ba5 211 _data |= ((data&0x02)==0)<<5;
kohacraft 1:cb28911c7ba5 212 _data |= ((data&0x04)==0)<<3;
kohacraft 1:cb28911c7ba5 213 _data |= ((data&0x08)==0)<<1;
kohacraft 1:cb28911c7ba5 214 setDrawData( _data );
kohacraft 1:cb28911c7ba5 215 break;
kohacraft 1:cb28911c7ba5 216 case EDP_WHITE :
kohacraft 1:cb28911c7ba5 217 _data = 0;
kohacraft 1:cb28911c7ba5 218 _data |= ((data&0x10)!=0)<<6;
kohacraft 1:cb28911c7ba5 219 _data |= ((data&0x20)!=0)<<4;
kohacraft 1:cb28911c7ba5 220 _data |= ((data&0x40)!=0)<<2;
kohacraft 1:cb28911c7ba5 221 _data |= ((data&0x80)!=0);
kohacraft 1:cb28911c7ba5 222 setDrawData( _data );
kohacraft 1:cb28911c7ba5 223 _data = 0;
kohacraft 1:cb28911c7ba5 224 _data |= ((data&0x01)!=0)<<6;
kohacraft 1:cb28911c7ba5 225 _data |= ((data&0x02)!=0)<<4;
kohacraft 1:cb28911c7ba5 226 _data |= ((data&0x04)!=0)<<2;
kohacraft 1:cb28911c7ba5 227 _data |= ((data&0x08)!=0);
kohacraft 1:cb28911c7ba5 228 setDrawData( _data );
kohacraft 1:cb28911c7ba5 229 break;
kohacraft 1:cb28911c7ba5 230 default :
kohacraft 1:cb28911c7ba5 231 _data = 0;
kohacraft 1:cb28911c7ba5 232 _data |= ((data&0x10)==0)<<7;
kohacraft 1:cb28911c7ba5 233 _data |= ((data&0x10)!=0)<<6;
kohacraft 1:cb28911c7ba5 234 _data |= ((data&0x20)==0)<<5;
kohacraft 1:cb28911c7ba5 235 _data |= ((data&0x20)!=0)<<4;
kohacraft 1:cb28911c7ba5 236 _data |= ((data&0x40)==0)<<3;
kohacraft 1:cb28911c7ba5 237 _data |= ((data&0x40)!=0)<<2;
kohacraft 1:cb28911c7ba5 238 _data |= ((data&0x80)==0)<<1;
kohacraft 1:cb28911c7ba5 239 _data |= ((data&0x80)!=0);
kohacraft 1:cb28911c7ba5 240 setDrawData( _data );
kohacraft 1:cb28911c7ba5 241 _data = 0;
kohacraft 1:cb28911c7ba5 242 _data |= ((data&0x01)==0)<<7;
kohacraft 1:cb28911c7ba5 243 _data |= ((data&0x01)!=0)<<6;
kohacraft 1:cb28911c7ba5 244 _data |= ((data&0x02)==0)<<5;
kohacraft 1:cb28911c7ba5 245 _data |= ((data&0x02)!=0)<<4;
kohacraft 1:cb28911c7ba5 246 _data |= ((data&0x04)==0)<<3;
kohacraft 1:cb28911c7ba5 247 _data |= ((data&0x04)!=0)<<2;
kohacraft 1:cb28911c7ba5 248 _data |= ((data&0x08)==0)<<1;
kohacraft 1:cb28911c7ba5 249 _data |= ((data&0x08)!=0);
kohacraft 1:cb28911c7ba5 250 setDrawData( _data );
kohacraft 1:cb28911c7ba5 251 break;
kohacraft 0:e4c67c26ba3f 252 }
kohacraft 1:cb28911c7ba5 253
kohacraft 1:cb28911c7ba5 254 return;
kohacraft 0:e4c67c26ba3f 255 }
kohacraft 0:e4c67c26ba3f 256
kohacraft 1:cb28911c7ba5 257 //display the bmp image to EDP
kohacraft 1:cb28911c7ba5 258 // drawMode: EDP_BLACK draw black at black pixel and draw transparent at white pixel
kohacraft 1:cb28911c7ba5 259 // EDP_WHITE draw white at white pixel and draw transparent at black pixel
kohacraft 1:cb28911c7ba5 260 // EDP_BLACK_WHITE draw black at black pixel and draw white at white pixel
kohacraft 1:cb28911c7ba5 261 void dispBmp(FILE *fp , char drawMode )
kohacraft 0:e4c67c26ba3f 262 {
kohacraft 1:cb28911c7ba5 263 bool paletteWhite = 0; //white palette number
kohacraft 1:cb28911c7ba5 264 char bmpdata[EDP_WIDTH/8]; //data buffer for one line
kohacraft 1:cb28911c7ba5 265
kohacraft 1:cb28911c7ba5 266 //confirm the filepointer is available
kohacraft 1:cb28911c7ba5 267 if( fp == NULL )
kohacraft 1:cb28911c7ba5 268 {
kohacraft 1:cb28911c7ba5 269 fclose(fp);
kohacraft 1:cb28911c7ba5 270 free(fp);
kohacraft 1:cb28911c7ba5 271
kohacraft 1:cb28911c7ba5 272 //unavailable
kohacraft 1:cb28911c7ba5 273 clrDisp(EDP_WHITE); //fill white
kohacraft 1:cb28911c7ba5 274 clrDisp(EDP_BLACK); //fill black
kohacraft 1:cb28911c7ba5 275 clrDisp(EDP_WHITE); //fill white
kohacraft 1:cb28911c7ba5 276 clrDisp(EDP_BLACK); //fill black
kohacraft 0:e4c67c26ba3f 277
kohacraft 1:cb28911c7ba5 278 return;
kohacraft 1:cb28911c7ba5 279 }
kohacraft 1:cb28911c7ba5 280
kohacraft 1:cb28911c7ba5 281 //get image wight anf height
kohacraft 1:cb28911c7ba5 282 unsigned int bmpWidth , bmpHeight;
kohacraft 1:cb28911c7ba5 283 fseek(fp, 18 , SEEK_SET);//to xsize
kohacraft 1:cb28911c7ba5 284 fread( &bmpWidth , sizeof(unsigned int) , 1 , fp);
kohacraft 1:cb28911c7ba5 285 fread( &bmpHeight , sizeof(unsigned int) , 1 , fp);
kohacraft 1:cb28911c7ba5 286 if( bmpWidth != EDP_WIDTH || bmpHeight != EDP_HEIGHT )
kohacraft 1:cb28911c7ba5 287 {
kohacraft 1:cb28911c7ba5 288 fclose(fp);
kohacraft 1:cb28911c7ba5 289 free(fp);
kohacraft 1:cb28911c7ba5 290
kohacraft 1:cb28911c7ba5 291 //not match size with EDP
kohacraft 1:cb28911c7ba5 292 clrDisp(EDP_WHITE); //fill white
kohacraft 1:cb28911c7ba5 293 clrDisp(EDP_BLACK); //fill black
kohacraft 1:cb28911c7ba5 294 clrDisp(EDP_WHITE); //fill white
kohacraft 0:e4c67c26ba3f 295
kohacraft 1:cb28911c7ba5 296 return;
kohacraft 1:cb28911c7ba5 297 }
kohacraft 1:cb28911c7ba5 298
kohacraft 1:cb28911c7ba5 299 //get palette data
kohacraft 1:cb28911c7ba5 300 unsigned char paletteTemp[8];
kohacraft 1:cb28911c7ba5 301 fseek(fp, 54 , SEEK_SET);//bitmap headder throw
kohacraft 1:cb28911c7ba5 302 fread( paletteTemp , sizeof(char) , 8 , fp);
kohacraft 1:cb28911c7ba5 303 int palette0 = (int)paletteTemp[0]+(int)paletteTemp[1]+(int)paletteTemp[2];
kohacraft 1:cb28911c7ba5 304 int palette1 = (int)paletteTemp[4]+(int)paletteTemp[5]+(int)paletteTemp[6];
kohacraft 1:cb28911c7ba5 305 if( palette0 > palette1 ) //select white palette number,witch the braightest palette
kohacraft 1:cb28911c7ba5 306 paletteWhite = 0; //
kohacraft 1:cb28911c7ba5 307 else
kohacraft 1:cb28911c7ba5 308 paletteWhite = 1; //
kohacraft 1:cb28911c7ba5 309
kohacraft 1:cb28911c7ba5 310 //skip to image data
kohacraft 1:cb28911c7ba5 311 unsigned int dataOffset;
kohacraft 1:cb28911c7ba5 312 fseek(fp, 10 , SEEK_SET);
kohacraft 1:cb28911c7ba5 313 fread( &dataOffset , sizeof(unsigned int) , 1 , fp);
kohacraft 1:cb28911c7ba5 314 fseek(fp, dataOffset , SEEK_SET);
kohacraft 1:cb28911c7ba5 315
kohacraft 1:cb28911c7ba5 316 //dwar bmp data to EDP
kohacraft 1:cb28911c7ba5 317 pageStart();
kohacraft 1:cb28911c7ba5 318 for( int j=0 ; j<EDP_HEIGHT ; j++)
kohacraft 1:cb28911c7ba5 319 {
kohacraft 1:cb28911c7ba5 320 //read for one line and chage to bit for white is 1 and black is 0
kohacraft 1:cb28911c7ba5 321 fread( &bmpdata , sizeof(char) , EDP_WIDTH/8 , fp);
kohacraft 1:cb28911c7ba5 322 if( paletteWhite == 0 )
kohacraft 0:e4c67c26ba3f 323 {
kohacraft 1:cb28911c7ba5 324 for( int i=0 ; i<EDP_WIDTH/8 ; i++ )
kohacraft 1:cb28911c7ba5 325 bmpdata[i] = ~bmpdata[i];
kohacraft 0:e4c67c26ba3f 326 }
kohacraft 1:cb28911c7ba5 327
kohacraft 1:cb28911c7ba5 328 lineStart();
kohacraft 1:cb28911c7ba5 329 for( int i=0 ; i<EDP_WIDTH ; i+=8 )
kohacraft 0:e4c67c26ba3f 330 {
kohacraft 1:cb28911c7ba5 331 drowPixels(bmpdata[i/8],drawMode);
kohacraft 0:e4c67c26ba3f 332 }
kohacraft 1:cb28911c7ba5 333 lineEnd();
kohacraft 1:cb28911c7ba5 334
kohacraft 1:cb28911c7ba5 335 }
kohacraft 1:cb28911c7ba5 336 pageEnd();
kohacraft 1:cb28911c7ba5 337
kohacraft 1:cb28911c7ba5 338 return;
kohacraft 0:e4c67c26ba3f 339 }
kohacraft 0:e4c67c26ba3f 340