Hi
Can someone tell me what is going on with this code?
I used u8glib bitmap converter to hex but i`m displaying a lot of dots all over the screen
the bitmap is
20x34px
#include "U8glib.h"
//▼RGB
const byte redPin = 12;
const byte greenPin = 11;
const byte bluePin = 10;
const byte RGBbut = 52;
U8GLIB_LM6059 u8g(8, 9, 5, 7, 6);
const uint8_t rook_bitmap[] PROGMEM = {
0x0,0xf0,0x0,0x1f,0x80,0x1,0xf8,0x0,0x1f,0x80,0x0,0xf0,0x0,0x6,0x0,0x0,0x60,0x0,0x6,0x0,
0x3c,0x63,0xc7,0xe6,0x7e,0x7e,0x67,0xe7,0xe6,0x7e,0x3c,0x63,0xc1,0x86,0x18,0x18,0x61,0x80,0xc6,0x30,
0xc,0xf3,0x0,0x6f,0x60,0x3,0xfc,0x0,0x3f,0xc0,0x3,0xfc,0x0,0x3f,0xc0,0x3,0xfc,0x0,0x3f,0xc0,
0x3,0xfc,0x0,0x3f,0xc0,0x7,0xfe,0x0,0x7f,0xe0,0x7f,0xff,0xef,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
0xff,0xff,0xf7,0xff,0xfe
};
void draw(void)
{
// graphic commands to redraw the complete screen should be placed here
u8g.drawBitmapP( 0, 0, 20, 34, rook_bitmap);
}
void setup(void) {
pinMode(redPin, OUTPUT);
pinMode(greenPin, OUTPUT);
pinMode(bluePin, OUTPUT);
}
void loop(void)
{
// picture loop
u8g.firstPage();
do
{
draw();
}
while( u8g.nextPage() );
// rebuild the picture after some delay
delay(1000);
}
Thank you