Warnings removed
This commit is contained in:
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
prog_uchar APM font[] = {
|
prog_uchar APM font[] = {
|
||||||
80,8,80,
|
80,8,
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6f,0x00,0x00,0x07,0x00,0x07,0x00,0x14,0x7f,0x14,0x7f,0x14,0x24,0x2a,0x7f,0x2a,0x12,0x23,0x13,0x08,0x64,0x62,0x36,0x49,0x55,0x22,0x50,0x00,0x05,0x03,0x00,0x00,0x00,0x1c,0x22,0x41,0x00,0x00,0x41,0x22,0x1c,0x00,0x14,0x08,0x3e,0x08,0x14,0x08,0x08,0x3e,0x08,0x08,0x00,0x50,0x30,0x00,0x00,0x08,0x08,0x08,0x08,0x08,0x00,0x60,0x60,0x00,0x00,0x20,0x10,0x08,0x04,0x02,
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6f,0x00,0x00,0x07,0x00,0x07,0x00,0x14,0x7f,0x14,0x7f,0x14,0x24,0x2a,0x7f,0x2a,0x12,0x23,0x13,0x08,0x64,0x62,0x36,0x49,0x55,0x22,0x50,0x00,0x05,0x03,0x00,0x00,0x00,0x1c,0x22,0x41,0x00,0x00,0x41,0x22,0x1c,0x00,0x14,0x08,0x3e,0x08,0x14,0x08,0x08,0x3e,0x08,0x08,0x00,0x50,0x30,0x00,0x00,0x08,0x08,0x08,0x08,0x08,0x00,0x60,0x60,0x00,0x00,0x20,0x10,0x08,0x04,0x02,
|
||||||
0x00,0x3e,0x41,0x41,0x3e,0x00,0x00,0x42,0x7f,0x40,0x00,0x62,0x51,0x49,0x46,0x00,0x41,0x49,0x49,0x36,0x00,0x18,0x14,0x12,0x7f,0x00,0x27,0x45,0x45,0x39,0x00,0x3e,0x49,0x49,0x32,0x00,0x01,0x79,0x05,0x03,0x00,0x36,0x49,0x49,0x36,0x00,0x06,0x49,0x29,0x1e,0x00,0x00,0x36,0x36,0x00,0x00,0x00,0x56,0x36,0x00,0x00,0x08,0x14,0x22,0x41,0x14,0x14,0x14,0x14,0x14,0x41,0x22,0x14,0x08,0x00,0x02,0x01,0x51,0x09,0x06,
|
0x00,0x3e,0x41,0x41,0x3e,0x00,0x00,0x42,0x7f,0x40,0x00,0x62,0x51,0x49,0x46,0x00,0x41,0x49,0x49,0x36,0x00,0x18,0x14,0x12,0x7f,0x00,0x27,0x45,0x45,0x39,0x00,0x3e,0x49,0x49,0x32,0x00,0x01,0x79,0x05,0x03,0x00,0x36,0x49,0x49,0x36,0x00,0x06,0x49,0x29,0x1e,0x00,0x00,0x36,0x36,0x00,0x00,0x00,0x56,0x36,0x00,0x00,0x08,0x14,0x22,0x41,0x14,0x14,0x14,0x14,0x14,0x41,0x22,0x14,0x08,0x00,0x02,0x01,0x51,0x09,0x06,
|
||||||
0x06,0x09,0x09,0x06,0x00,0x7e,0x09,0x09,0x09,0x7e,0x7f,0x49,0x49,0x49,0x36,0x3e,0x41,0x41,0x41,0x22,0x7f,0x41,0x41,0x22,0x1c,0x7f,0x49,0x49,0x49,0x41,0x7f,0x09,0x09,0x09,0x01,0x3e,0x41,0x49,0x49,0x7a,0x7f,0x08,0x08,0x08,0x7f,0x00,0x41,0x7f,0x41,0x00,0x20,0x40,0x41,0x3f,0x01,0x7f,0x08,0x14,0x22,0x41,0x7f,0x40,0x40,0x40,0x40,0x7f,0x02,0x0c,0x02,0x7f,0x7f,0x04,0x08,0x10,0x7f,0x3e,0x41,0x41,0x41,0x3e,
|
0x06,0x09,0x09,0x06,0x00,0x7e,0x09,0x09,0x09,0x7e,0x7f,0x49,0x49,0x49,0x36,0x3e,0x41,0x41,0x41,0x22,0x7f,0x41,0x41,0x22,0x1c,0x7f,0x49,0x49,0x49,0x41,0x7f,0x09,0x09,0x09,0x01,0x3e,0x41,0x49,0x49,0x7a,0x7f,0x08,0x08,0x08,0x7f,0x00,0x41,0x7f,0x41,0x00,0x20,0x40,0x41,0x3f,0x01,0x7f,0x08,0x14,0x22,0x41,0x7f,0x40,0x40,0x40,0x40,0x7f,0x02,0x0c,0x02,0x7f,0x7f,0x04,0x08,0x10,0x7f,0x3e,0x41,0x41,0x41,0x3e,
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
prog_uchar APM font_dblsize[] = {
|
prog_uchar APM font_dblsize[] = {
|
||||||
160,96,1920,
|
160,96,
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xfe,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x7e,0x00,0x00,0x7e,0x3e,0x00,0x00,0x60,0x60,0xfe,0xfe,0x60,0x60,0xfe,0xfe,0x60,0x60,0x60,0xf0,0x98,0x98,0xfe,0xfe,0x98,0x98,0x18,0x18,0x0c,0x1e,0x1e,0x0c,0x80,0xc0,0xe0,0x70,0x38,0x18,0x78,0xfc,0x8e,0xc6,0xe6,0x76,0x3c,0x18,0x00,0x00,0x00,0x00,0x66,0x76,0x3e,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xf0,0x38,0x1c,0x0e,0x06,0x00,0x00,0x00,0x00,0x06,0x0e,0x1c,0x38,0xf0,0xe0,0x00,0x00,0x60,0x60,0xc0,0x80,0xf8,0xf8,0x80,0xc0,0x60,0x60,0x80,0x80,0x80,0x80,0xf8,0xf8,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xc0,0xe0,0x70,0x38,0x18,
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xfe,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x7e,0x00,0x00,0x7e,0x3e,0x00,0x00,0x60,0x60,0xfe,0xfe,0x60,0x60,0xfe,0xfe,0x60,0x60,0x60,0xf0,0x98,0x98,0xfe,0xfe,0x98,0x98,0x18,0x18,0x0c,0x1e,0x1e,0x0c,0x80,0xc0,0xe0,0x70,0x38,0x18,0x78,0xfc,0x8e,0xc6,0xe6,0x76,0x3c,0x18,0x00,0x00,0x00,0x00,0x66,0x76,0x3e,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xf0,0x38,0x1c,0x0e,0x06,0x00,0x00,0x00,0x00,0x06,0x0e,0x1c,0x38,0xf0,0xe0,0x00,0x00,0x60,0x60,0xc0,0x80,0xf8,0xf8,0x80,0xc0,0x60,0x60,0x80,0x80,0x80,0x80,0xf8,0xf8,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xc0,0xe0,0x70,0x38,0x18,
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x71,0x71,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x06,0x7f,0x7f,0x06,0x06,0x7f,0x7f,0x06,0x06,0x18,0x18,0x19,0x19,0x7f,0x7f,0x19,0x19,0x0f,0x06,0x18,0x1c,0x0e,0x07,0x03,0x01,0x30,0x78,0x78,0x30,0x1e,0x3f,0x71,0x63,0x67,0x66,0x3c,0x3c,0x66,0x66,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x0f,0x1c,0x38,0x70,0x60,0x00,0x00,0x00,0x00,0x60,0x70,0x38,0x1c,0x0f,0x07,0x00,0x00,0x06,0x06,0x03,0x01,0x1f,0x1f,0x01,0x03,0x06,0x06,0x01,0x01,0x01,0x01,0x1f,0x1f,0x01,0x01,0x01,0x01,0x00,0x00,0x66,0x76,0x3e,0x1e,0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x00,0x00,0x30,0x78,0x78,0x30,0x00,0x00,0x00,0x00,0x18,0x1c,0x0e,0x07,0x03,0x01,0x00,0x00,0x00,0x00,
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x71,0x71,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x06,0x7f,0x7f,0x06,0x06,0x7f,0x7f,0x06,0x06,0x18,0x18,0x19,0x19,0x7f,0x7f,0x19,0x19,0x0f,0x06,0x18,0x1c,0x0e,0x07,0x03,0x01,0x30,0x78,0x78,0x30,0x1e,0x3f,0x71,0x63,0x67,0x66,0x3c,0x3c,0x66,0x66,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x0f,0x1c,0x38,0x70,0x60,0x00,0x00,0x00,0x00,0x60,0x70,0x38,0x1c,0x0f,0x07,0x00,0x00,0x06,0x06,0x03,0x01,0x1f,0x1f,0x01,0x03,0x06,0x06,0x01,0x01,0x01,0x01,0x1f,0x1f,0x01,0x01,0x01,0x01,0x00,0x00,0x66,0x76,0x3e,0x1e,0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x00,0x00,0x30,0x78,0x78,0x30,0x00,0x00,0x00,0x00,0x18,0x1c,0x0e,0x07,0x03,0x01,0x00,0x00,0x00,0x00,
|
||||||
0x00,0x00,0xf8,0xfc,0x0e,0x06,0x06,0x0e,0xfc,0xf8,0x00,0x00,0x18,0x1c,0xfe,0xfe,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x1c,0x0e,0x06,0x86,0xce,0xfc,0x78,0x00,0x00,0x06,0x06,0x86,0x86,0x86,0xce,0xfc,0x78,0x00,0x00,0x80,0xc0,0xe0,0x70,0x38,0x1c,0xfe,0xfe,0x00,0x00,0x7e,0x7e,0x66,0x66,0x66,0xe6,0xc6,0x86,0x00,0x00,0xf8,0xfc,0x8e,0x86,0x86,0x8e,0x1c,0x18,0x00,0x00,0x06,0x06,0x86,0xc6,0xe6,0x76,0x3e,0x1e,0x00,0x00,0x78,0xfc,0xce,0x86,0x86,0xce,0xfc,0x78,0x00,0x00,0x78,0xfc,0xce,0x86,0x86,0xce,0xfc,0xf8,0x00,0x00,0x30,0x78,0x78,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x78,0x78,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xc0,0xe0,0x70,0x38,0x1c,0x0e,0x06,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x06,0x0e,0x1c,0x38,0x70,0xe0,0xc0,0x80,0x00,0x00,0x18,0x1c,0x0e,0x06,0x06,0x06,0x86,0xce,0xfc,0x78,
|
0x00,0x00,0xf8,0xfc,0x0e,0x06,0x06,0x0e,0xfc,0xf8,0x00,0x00,0x18,0x1c,0xfe,0xfe,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x1c,0x0e,0x06,0x86,0xce,0xfc,0x78,0x00,0x00,0x06,0x06,0x86,0x86,0x86,0xce,0xfc,0x78,0x00,0x00,0x80,0xc0,0xe0,0x70,0x38,0x1c,0xfe,0xfe,0x00,0x00,0x7e,0x7e,0x66,0x66,0x66,0xe6,0xc6,0x86,0x00,0x00,0xf8,0xfc,0x8e,0x86,0x86,0x8e,0x1c,0x18,0x00,0x00,0x06,0x06,0x86,0xc6,0xe6,0x76,0x3e,0x1e,0x00,0x00,0x78,0xfc,0xce,0x86,0x86,0xce,0xfc,0x78,0x00,0x00,0x78,0xfc,0xce,0x86,0x86,0xce,0xfc,0xf8,0x00,0x00,0x30,0x78,0x78,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x78,0x78,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xc0,0xe0,0x70,0x38,0x1c,0x0e,0x06,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x06,0x0e,0x1c,0x38,0x70,0xe0,0xc0,0x80,0x00,0x00,0x18,0x1c,0x0e,0x06,0x06,0x06,0x86,0xce,0xfc,0x78,
|
||||||
|
|||||||
+11
-12
@@ -20,14 +20,14 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "lcd.h"
|
#include "lcd.h"
|
||||||
|
#include "font.lbm"
|
||||||
|
#include "font_dblsize.lbm"
|
||||||
|
|
||||||
|
#define font_5x8_x20_x7f (font+2)
|
||||||
|
#define font_10x16_x20_x7f (font_dblsize+2)
|
||||||
|
|
||||||
uint8_t displayBuf[DISPLAY_W*DISPLAY_H/8];
|
uint8_t displayBuf[DISPLAY_W*DISPLAY_H/8];
|
||||||
#define DISPLAY_END (displayBuf+sizeof(displayBuf))
|
#define DISPLAY_END (displayBuf+sizeof(displayBuf))
|
||||||
#include "font.lbm"
|
|
||||||
#define font_5x8_x20_x7f (font+3)
|
|
||||||
|
|
||||||
#include "font_dblsize.lbm"
|
|
||||||
#define font_10x16_x20_x7f (font_dblsize+3)
|
|
||||||
|
|
||||||
#ifdef SIMU
|
#ifdef SIMU
|
||||||
bool lcd_refresh = true;
|
bool lcd_refresh = true;
|
||||||
@@ -39,17 +39,16 @@ void lcd_clear()
|
|||||||
memset(displayBuf, 0, sizeof(displayBuf));
|
memset(displayBuf, 0, sizeof(displayBuf));
|
||||||
}
|
}
|
||||||
|
|
||||||
void lcd_img(uint8_t i_x,uint8_t i_y,const prog_uchar * imgdat,uint8_t idx,uint8_t mode)
|
void lcd_img(uint8_t x, uint8_t y, const prog_uchar * img, uint8_t idx, uint8_t mode)
|
||||||
{
|
{
|
||||||
const prog_uchar *q = imgdat;
|
const prog_uchar *q = img;
|
||||||
uint8_t w = pgm_read_byte(q++);
|
uint8_t w = pgm_read_byte(q++);
|
||||||
uint8_t hb = (pgm_read_byte(q++)+7)/8;
|
uint8_t hb = (pgm_read_byte(q++)+7)/8;
|
||||||
uint8_t sze1 = pgm_read_byte(q++);
|
|
||||||
q += idx*sze1;
|
|
||||||
bool inv = (mode & INVERS) ? true : (mode & BLINK ? BLINK_ON_PHASE : false);
|
bool inv = (mode & INVERS) ? true : (mode & BLINK ? BLINK_ON_PHASE : false);
|
||||||
for(uint8_t yb = 0; yb < hb; yb++){
|
q += idx*w*hb;
|
||||||
uint8_t *p = &displayBuf[ (i_y / 8 + yb) * DISPLAY_W + i_x ];
|
for (uint8_t yb = 0; yb < hb; yb++) {
|
||||||
for(uint8_t x=0; x < w; x++){
|
uint8_t *p = &displayBuf[ (y / 8 + yb) * DISPLAY_W + x ];
|
||||||
|
for (uint8_t i=0; i<w; i++){
|
||||||
uint8_t b = pgm_read_byte(q++);
|
uint8_t b = pgm_read_byte(q++);
|
||||||
*p++ = inv ? ~b : b;
|
*p++ = inv ? ~b : b;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -121,11 +121,8 @@ inline void lcd_square(uint8_t x, uint8_t y, uint8_t w, uint8_t att=0) { lcd_rec
|
|||||||
lcd_vline(xx ,yy-ll,ll); \
|
lcd_vline(xx ,yy-ll,ll); \
|
||||||
lcd_vline(xx+1,yy-ll,ll);
|
lcd_vline(xx+1,yy-ll,ll);
|
||||||
|
|
||||||
extern void lcd_img_f(unsigned char x,unsigned char y);
|
extern void lcd_img(uint8_t x, uint8_t y, const prog_uchar * img, uint8_t idx, uint8_t mode);
|
||||||
extern void lcd_img(uint8_t i_x,uint8_t i_y,const prog_uchar * imgdat,uint8_t idx,uint8_t mode);
|
|
||||||
|
|
||||||
extern void lcdSetRefVolt(unsigned char val);
|
extern void lcdSetRefVolt(unsigned char val);
|
||||||
|
|
||||||
extern void lcd_init();
|
extern void lcd_init();
|
||||||
extern void lcd_clear();
|
extern void lcd_clear();
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -1,5 +1,5 @@
|
|||||||
prog_uchar APM s9xsplash[] = {
|
prog_uchar APM s9xsplash[] = {
|
||||||
128,64,1024,
|
128,64,
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x08,0x04,0x04,0x84,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0xc4,0x04,0x04,0x88,0x70,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x08,0x04,0x04,0x84,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0xc4,0x04,0x04,0x88,0x70,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0xbf,0x80,0x80,0x80,0xbf,0x80,0x80,0x80,0x80,0x00,0x00,0x30,0x48,0x48,0x48,0x48,0x48,0x48,0x48,0x48,0x88,0x09,0x09,0x08,0xf0,0x00,0x00,0x00,0x01,0x01,0x01,0x7f,0x01,0x01,0x01,0x01,0x00,0x00,0x7f,0x49,0x49,0x49,0x49,0x41,0x41,0x40,0x00,0x7f,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x7f,0x49,0x49,0x49,0x49,0x41,0x41,0x40,0x00,0x7f,0x01,0x06,0x0c,0x10,0x10,0x0c,0x06,0x01,0x7f,0x00,0x00,0x7f,0x49,0x49,0x49,0x49,0x41,0x41,0x40,0x01,0x01,0x01,0x7f,0x01,0x01,0x01,0x01,0x00,0x00,0x7f,0x09,0x09,0x09,0x09,0x19,0x29,0x4e,0x00,0x01,0x03,0x06,0x0c,0x78,0x0c,0x06,0x03,0x01,0x00,0x00,
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0xbf,0x80,0x80,0x80,0xbf,0x80,0x80,0x80,0x80,0x00,0x00,0x30,0x48,0x48,0x48,0x48,0x48,0x48,0x48,0x48,0x88,0x09,0x09,0x08,0xf0,0x00,0x00,0x00,0x01,0x01,0x01,0x7f,0x01,0x01,0x01,0x01,0x00,0x00,0x7f,0x49,0x49,0x49,0x49,0x41,0x41,0x40,0x00,0x7f,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x7f,0x49,0x49,0x49,0x49,0x41,0x41,0x40,0x00,0x7f,0x01,0x06,0x0c,0x10,0x10,0x0c,0x06,0x01,0x7f,0x00,0x00,0x7f,0x49,0x49,0x49,0x49,0x41,0x41,0x40,0x01,0x01,0x01,0x7f,0x01,0x01,0x01,0x01,0x00,0x00,0x7f,0x09,0x09,0x09,0x09,0x19,0x29,0x4e,0x00,0x01,0x03,0x06,0x0c,0x78,0x0c,0x06,0x03,0x01,0x00,0x00,
|
||||||
0x00,0x00,0xf8,0xfe,0xff,0xff,0xff,0x0f,0x07,0x07,0x07,0x07,0x07,0x07,0x37,0x47,0x87,0x87,0x87,0x97,0x97,0x07,0x5f,0xdf,0xdf,0xdf,0xde,0xd8,0x80,0x10,0x10,0x10,0x10,0x10,0x0f,0x00,0x80,0x40,0x3f,0x80,0xc0,0xe0,0xe0,0xe0,0x60,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xd0,0x90,0x90,0x90,0x90,0x90,0x00,0x00,0x00,0xf0,0x90,0x90,0x90,0x90,0x10,0x10,0x00,0x00,0xf0,0x90,0x90,0x90,0x90,0x90,0x90,0xe0,0x00,0x00,0xf0,0x00,0x00,0x00,0xf0,0x90,0x90,0x90,0x90,0x10,0x10,0x00,0x60,0xd0,0x90,0x90,0x90,0x90,0x90,0x00,0x00,0x00,0x00,
|
0x00,0x00,0xf8,0xfe,0xff,0xff,0xff,0x0f,0x07,0x07,0x07,0x07,0x07,0x07,0x37,0x47,0x87,0x87,0x87,0x97,0x97,0x07,0x5f,0xdf,0xdf,0xdf,0xde,0xd8,0x80,0x10,0x10,0x10,0x10,0x10,0x0f,0x00,0x80,0x40,0x3f,0x80,0xc0,0xe0,0xe0,0xe0,0x60,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xd0,0x90,0x90,0x90,0x90,0x90,0x00,0x00,0x00,0xf0,0x90,0x90,0x90,0x90,0x10,0x10,0x00,0x00,0xf0,0x90,0x90,0x90,0x90,0x90,0x90,0xe0,0x00,0x00,0xf0,0x00,0x00,0x00,0xf0,0x90,0x90,0x90,0x90,0x10,0x10,0x00,0x60,0xd0,0x90,0x90,0x90,0x90,0x90,0x00,0x00,0x00,0x00,
|
||||||
@@ -7,5 +7,5 @@ prog_uchar APM s9xsplash[] = {
|
|||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x0c,0x1c,0x1c,0x1c,0x1c,0x1c,0x1e,0x1e,0x1e,0x0e,0x0e,0x0f,0x07,0x07,0x03,0x03,0x01,0x80,0xc0,0xe0,0xf0,0xf8,0x7c,0x3e,0x1f,0x0f,0x07,0x07,0x0f,0x1f,0x3f,0x7e,0xfc,0xf8,0xf0,0xe0,0xc0,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7e,0x4a,0x4a,0x4a,0x4a,0x4a,0x7c,0x00,0x02,0x06,0x0c,0x70,0x08,0x04,0x02,0x02,0x00,0x00,0x00,0x00,0x1c,0x22,0x41,0x41,0x49,0x49,0x49,0x3a,0x18,0x00,0x00,0x7e,0x12,0x12,0x12,0x12,0x32,0x4c,0x00,0x00,0x3e,0x40,0x40,0x40,0x40,0x40,0x3e,0x00,0x02,0x0c,0x18,0x60,0x60,0x30,0x0c,0x02,0x00,0x7e,0x00,0x00,0x7e,0x02,0x0c,0x18,0x30,0x40,0x7e,0x00,0x00,0x00,0x00,
|
0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x0c,0x1c,0x1c,0x1c,0x1c,0x1c,0x1e,0x1e,0x1e,0x0e,0x0e,0x0f,0x07,0x07,0x03,0x03,0x01,0x80,0xc0,0xe0,0xf0,0xf8,0x7c,0x3e,0x1f,0x0f,0x07,0x07,0x0f,0x1f,0x3f,0x7e,0xfc,0xf8,0xf0,0xe0,0xc0,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7e,0x4a,0x4a,0x4a,0x4a,0x4a,0x7c,0x00,0x02,0x06,0x0c,0x70,0x08,0x04,0x02,0x02,0x00,0x00,0x00,0x00,0x1c,0x22,0x41,0x41,0x49,0x49,0x49,0x3a,0x18,0x00,0x00,0x7e,0x12,0x12,0x12,0x12,0x32,0x4c,0x00,0x00,0x3e,0x40,0x40,0x40,0x40,0x40,0x3e,0x00,0x02,0x0c,0x18,0x60,0x60,0x30,0x0c,0x02,0x00,0x7e,0x00,0x00,0x7e,0x02,0x0c,0x18,0x30,0x40,0x7e,0x00,0x00,0x00,0x00,
|
||||||
0x00,0x00,0xe0,0x10,0x10,0x10,0xe0,0x00,0x00,0xc0,0x80,0x40,0x80,0x00,0x00,0x80,0x40,0x40,0x80,0x00,0x00,0xcc,0x8e,0x4f,0x8f,0x0f,0x07,0x03,0x01,0x00,0x00,0x00,0x60,0x90,0x90,0x10,0x00,0x00,0x00,0x80,0x41,0x43,0x87,0x0f,0x0f,0xcf,0x0e,0x0c,0xc0,0x00,0x00,0xc0,0x80,0x40,0xc0,0x00,0x00,0x80,0x40,0x40,0x40,0x00,0x00,0x80,0x40,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
|
0x00,0x00,0xe0,0x10,0x10,0x10,0xe0,0x00,0x00,0xc0,0x80,0x40,0x80,0x00,0x00,0x80,0x40,0x40,0x80,0x00,0x00,0xcc,0x8e,0x4f,0x8f,0x0f,0x07,0x03,0x01,0x00,0x00,0x00,0x60,0x90,0x90,0x10,0x00,0x00,0x00,0x80,0x41,0x43,0x87,0x0f,0x0f,0xcf,0x0e,0x0c,0xc0,0x00,0x00,0xc0,0x80,0x40,0xc0,0x00,0x00,0x80,0x40,0x40,0x40,0x00,0x00,0x80,0x40,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
|
||||||
0x00,0x00,0x07,0x08,0x08,0x08,0x07,0x00,0x00,0x3f,0x04,0x08,0x07,0x00,0x00,0x07,0x09,0xc9,0x49,0x40,0x40,0x8f,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x08,0x08,0x09,0x06,0x00,0x00,0x07,0x08,0x08,0x07,0x00,0x00,0x07,0x08,0x04,0x0f,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x40,0x07,0x08,0x08,0x08,0x00,0x00,0x07,0x09,0x09,0x09,0x00,0x00,0x00,0xc8,0x00,0x00,0x08,0xc0,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x00,0x00,0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
|
0x00,0x00,0x07,0x08,0x08,0x08,0x07,0x00,0x00,0x3f,0x04,0x08,0x07,0x00,0x00,0x07,0x09,0xc9,0x49,0x40,0x40,0x8f,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x08,0x08,0x09,0x06,0x00,0x00,0x07,0x08,0x08,0x07,0x00,0x00,0x07,0x08,0x04,0x0f,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x40,0x07,0x08,0x08,0x08,0x00,0x00,0x07,0x09,0x09,0x09,0x00,0x00,0x00,0xc8,0x00,0x00,0x08,0xc0,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x00,0x00,0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
|
||||||
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00,0x00,0x3f,0x04,0x04,0x04,0x03,0x00,0x00,0x1e,0x21,0x21,0x1e,0x00,0x07,0x38,0x0e,0x0e,0x38,0x07,0x00,0x1e,0x25,0x25,0x26,0x00,0x00,0x3f,0x02,0x01,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x01,0x3f,0x00,0x00,0x3f,0x02,0x01,0x3e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x3c,0x03,0x00,0x00,0x00,0x1e,0x21,0x21,0x1e,0x00,0x00,0x1f,0x20,0x10,0x3f,0x00,0x3f,0x02,0x01,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0x02,0x02,0x02,0x3f,0x00,0x00,0x19,0x25,0x15,0x1e,0x20,0x00,0x3f,0x02,0x01,0x3e,0x00,0x1e,0x21,0x12,0x3f,0x00,0x00,0x22,0x25,0x29,0x11,0x00
|
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00,0x00,0x3f,0x04,0x04,0x04,0x03,0x00,0x00,0x1e,0x21,0x21,0x1e,0x00,0x07,0x38,0x0e,0x0e,0x38,0x07,0x00,0x1e,0x25,0x25,0x26,0x00,0x00,0x3f,0x02,0x01,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x01,0x3f,0x00,0x00,0x3f,0x02,0x01,0x3e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x3c,0x03,0x00,0x00,0x00,0x1e,0x21,0x21,0x1e,0x00,0x00,0x1f,0x20,0x10,0x3f,0x00,0x3f,0x02,0x01,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0x02,0x02,0x02,0x3f,0x00,0x00,0x19,0x25,0x15,0x1e,0x20,0x00,0x3f,0x02,0x01,0x3e,0x00,0x1e,0x21,0x12,0x3f,0x00,0x00,0x22,0x25,0x29,0x11,0x00,
|
||||||
};
|
};
|
||||||
|
|||||||
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
prog_uchar APM sticks[] = {
|
prog_uchar APM sticks[] = {
|
||||||
18,8,18,
|
18,8,
|
||||||
0x00,0x08,0x1c,0x08,0x08,0x08,0x1c,0x08,0x00,0x00,0x08,0x22,0x00,0x49,0x00,0x22,0x08,0x00,
|
0x00,0x08,0x1c,0x08,0x08,0x08,0x1c,0x08,0x00,0x00,0x08,0x22,0x00,0x49,0x00,0x22,0x08,0x00,
|
||||||
0x00,0x00,0x00,0x00,0x22,0x7f,0x22,0x00,0x00,0x00,0x08,0x22,0x00,0x49,0x00,0x22,0x08,0x00,
|
0x00,0x00,0x00,0x00,0x22,0x7f,0x22,0x00,0x00,0x00,0x08,0x22,0x00,0x49,0x00,0x22,0x08,0x00,
|
||||||
0x00,0x08,0x22,0x00,0x49,0x00,0x22,0x08,0x00,0x00,0x00,0x22,0x7f,0x22,0x00,0x00,0x00,0x00,
|
0x00,0x08,0x22,0x00,0x49,0x00,0x22,0x08,0x00,0x00,0x00,0x22,0x7f,0x22,0x00,0x00,0x00,0x00,
|
||||||
|
|||||||
@@ -0,0 +1,53 @@
|
|||||||
|
#! /usr/bin/env ruby
|
||||||
|
|
||||||
|
|
||||||
|
require 'pp'
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def main(xbm)
|
||||||
|
base=xbm.sub(/\.xbm/,"")
|
||||||
|
cols,rows=1,1
|
||||||
|
if base.sub! /_(\d+)x(\d+)/,""
|
||||||
|
rows,cols = $1.to_i,$2.to_i
|
||||||
|
end
|
||||||
|
|
||||||
|
File.read(xbm)=~/_width\s+(\d+).*_height\s+(\d+).*\{(.*)\}/m
|
||||||
|
w,h,bits=$1.to_i,$2.to_i,$3
|
||||||
|
bits=eval "["+bits+"]"
|
||||||
|
#pp w,h,bits
|
||||||
|
|
||||||
|
wb=(w+7)/8
|
||||||
|
hb=(h+7)/8
|
||||||
|
|
||||||
|
out=Array.new(w*hb,0)
|
||||||
|
#pp out
|
||||||
|
h.times{|yp| yb=yp/8; msk= 1 << (yp%8)
|
||||||
|
w.times{|xp| xb=xp/8; msk2=1 << (xp%8)
|
||||||
|
out[yb*w+xp]|=msk if bits[wb*yp+xb]&msk2 != 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#pp out
|
||||||
|
|
||||||
|
#prog_uchar img_4sticks_18x8[] = {
|
||||||
|
##include "sticks_lcd.h"
|
||||||
|
#};
|
||||||
|
|
||||||
|
File.open("#{base}.lbm","w"){|f|
|
||||||
|
col=0
|
||||||
|
f.printf("prog_uchar APM %s[] = {\n",base.sub(/.*\//,""))
|
||||||
|
f.printf("%d,%d,\n",w/cols,h/rows)
|
||||||
|
rows.times{|row|
|
||||||
|
(hb/rows).times{|yb| yb
|
||||||
|
w.times{|xp|
|
||||||
|
f.printf("0x%02x,",out[row*w + yb*w + xp])
|
||||||
|
}
|
||||||
|
f.puts
|
||||||
|
}
|
||||||
|
}
|
||||||
|
f.printf("};\n")
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
main(ARGV[0])
|
||||||
Reference in New Issue
Block a user