diff --git a/server/drivers/i2500vfd.c b/server/drivers/i2500vfd.c new file mode 100644 index 0000000..3457d92 --- /dev/null +++ b/server/drivers/i2500vfd.c @@ -0,0 +1,463 @@ +////////////////////////////////////////////////////////////////////////// +// This is a driver for the Intra2net Intranator 2500 VFD display // +// // +// The display features: // +// - B/W and two additional grayscale colors // +// - USB data transfer // +// - Animated boot logo // +// - Hardware double buffering, limit is 27 FPS // +// - Adjustable brightness / brightness of single colors // +// // +// (C) 2003,2007 Intra2net AG // +// // +// The HD44780 font in i2500vfdfm.c was taken from // +// Michael Reinelt / lcd4linux and is (C) 2000 by him. // +// // +// Code here is basend on sed1520.c: // +// (C) 2001,2002 Robin Adams ( robin@adams-online.de ) // +// // +// This driver is released under the GPL. See file COPYING in this // +// package for further details. // +////////////////////////////////////////////////////////////////////////// + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "i2500vfdfm.h" + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include "shared/str.h" +#include "lcd.h" +#include "i2500vfd.h" +#include "report.h" + +#include + +// The display itself stores three pixels in one byte +// We waste a little memory as we store one pixel per byte +// as we want to keep the drawing code simple. +// Take a look at i2500vfd_flush for the conversion + +#define INTRA2NET_VFD_XSIZE 140 +#define INTRA2NET_VFD_YSIZE 32 +#define INTRA2NET_VFD_SCREENSIZE INTRA2NET_VFD_XSIZE*INTRA2NET_VFD_YSIZE +#define INTRA2NET_VFD_PACKEDSIZE 47*32 +#define INTRA2NET_VFD_XSHIFT 0 + +#define WIDTH 23 +#define HEIGHT 4 +#define CELLWIDTH 6 +#define CELLHEIGHT 8 + +typedef struct driver_private_data { + struct ftdi_context ftdi; + unsigned char *framebuf; + int changed; +} PrivateData; + +// Vars for the server core +MODULE_EXPORT char *api_version = API_VERSION; +MODULE_EXPORT int stay_in_foreground = 0; +MODULE_EXPORT int supports_multiple = 0; +MODULE_EXPORT char *symbol_prefix = "i2500vfd_"; + +///////////////////////////////////////////////////////////////// +// draws char z from fontmap to the framebuffer at position +// x,y. These are zero-based textmode positions. +// The Fontmap is stored in rows while the framebuffer is stored +// in columns, so we need a little conversion. +// +void +drawchar2fb (Driver *drvthis, int x, int y, unsigned char z) +{ + PrivateData *p = drvthis->private_data; + + if (x < 0 || x >= WIDTH || y < 0 || y >= HEIGHT) + return; + + x++; + + int font_x, font_y; + for (font_y = 0; font_y < 8; font_y++) { + for (font_x = 5; font_x > -1; font_x--) { + if ((i2500vfd_fontmap[z][font_y] & 1<framebuf[INTRA2NET_VFD_XSHIFT+x*6-font_x + (y*8+font_y)*140] = 1; + else + p->framebuf[INTRA2NET_VFD_XSHIFT+x*6-font_x + (y*8+font_y)*140] = 0; + } + } + + p->changed = 1; +} + +///////////////////////////////////////////////////////////////// +// This initialises the stuff. +// +MODULE_EXPORT int +i2500vfd_init (Driver *drvthis) +{ + PrivateData *p; + int i; + unsigned char c; + + /* Allocate and store private data */ + p = (PrivateData *) calloc(1, sizeof(PrivateData)); + if (p == NULL) + return -1; + if (drvthis->store_private_ptr(drvthis, p)) + return -1; + + if (ftdi_init (&p->ftdi) < 0) { + report (RPT_ERR, "ftdi_init failed. Out of memory?"); + return -1; + } + + i = ftdi_usb_open (&p->ftdi, 0x0403, 0xF8A8); + if (i != 0 && i != -5) { + report (RPT_ERR, "Unable to find i2500 VFD display on USB bus. Aborting"); + return -1; + } + + // Allocate our framebuffer + p->framebuf = (unsigned char *) malloc(INTRA2NET_VFD_SCREENSIZE * 2 + INTRA2NET_VFD_PACKEDSIZE + 1); + if (p->framebuf == NULL) { + report(RPT_ERR, "%s: unable to allocate framebuffer", drvthis->name); + i2500vfd_close (drvthis); + return -1; + } + + // Fade out (set brightness to zero) + c = 4|64; + ftdi_write_data (&p->ftdi, &c, 1); + c = 0|64; + ftdi_write_data (&p->ftdi, &c, 1); + sleep (1); + + // Blank display + c = 2|64; + ftdi_write_data (&p->ftdi, &c, 1); + + // Bring voltage up again + c = 4|64; + ftdi_write_data (&p->ftdi, &c, 1); + c = 63|64; + ftdi_write_data (&p->ftdi, &c, 1); + + // Flip to blank page + c = 64; + ftdi_write_data (&p->ftdi, &c, 1); + sleep (1); + + // Clear internal screen + i2500vfd_clear(drvthis); + + // Unblank display + c = 3|64; + ftdi_write_data (&p->ftdi, &c, 1); + + report(RPT_DEBUG, "%s: init() done", drvthis->name); + return 1; +} + +///////////////////////////////////////////////////////////////// +// Frees the frambuffer and exits the driver. +// +MODULE_EXPORT void +i2500vfd_close (Driver *drvthis) +{ + PrivateData *p = drvthis->private_data; + + if (p) { + ftdi_usb_close (&p->ftdi); + ftdi_deinit(&p->ftdi); + + if (p->framebuf) + free(p->framebuf); + + free(p); + } + drvthis->store_private_ptr(drvthis, NULL); +} + +///////////////////////////////////////////////////////////////// +// Returns the display width +// +MODULE_EXPORT int +i2500vfd_width (Driver *drvthis) +{ + return WIDTH; +} + +///////////////////////////////////////////////////////////////// +// Returns the display height +// +MODULE_EXPORT int +i2500vfd_height (Driver *drvthis) +{ + return HEIGHT; +} + +///////////////////////////////////////////////////////////////// +// Returns the display width +// +MODULE_EXPORT int +i2500vfd_cellwidth (Driver *drvthis) +{ + return CELLWIDTH; +} + +///////////////////////////////////////////////////////////////// +// Returns the display height +// +MODULE_EXPORT int +i2500vfd_cellheight (Driver *drvthis) +{ + return CELLHEIGHT; +} + +///////////////////////////////////////////////////////////////// +// Clears the LCD screen +// +MODULE_EXPORT void +i2500vfd_clear (Driver *drvthis) +{ + PrivateData *p = drvthis->private_data; + + memset(p->framebuf, 0, INTRA2NET_VFD_SCREENSIZE); + p->changed = 1; +} + +///////////////////////////////////////////////////////////////// +// +// Flushes all output to the VFD... +// +MODULE_EXPORT void +i2500vfd_flush (Driver *drvthis) +{ + PrivateData *p = drvthis->private_data; + + if (!p->changed) + return; + + // Grayscales are currently discarded. + // Could be useful for antialised fonts + int packed_begin = INTRA2NET_VFD_SCREENSIZE*2; + int packed_offset = packed_begin, offset = 0, pixpos = 0, xpos = 0; + memset (p->framebuf+packed_begin, 0, INTRA2NET_VFD_PACKEDSIZE); + while (offset != INTRA2NET_VFD_SCREENSIZE) { + if (p->framebuf[offset] != 0) { + switch(pixpos) { + case 0: + p->framebuf[packed_offset] = 3; + break; + case 1: + p->framebuf[packed_offset] |= 3<<2; + break; + case 2: + p->framebuf[packed_offset] |= 3<<4; + break; + } + } + + xpos++; + offset++; + pixpos++; + if (pixpos == 3) { + pixpos = 0; + packed_offset++; + } + // Special: The display is organized in 3-pixel columns, but the last column got only 2 pixels + if (xpos == 140) { + packed_offset++; + pixpos = 0; + xpos = 0; + } + } + + // Page flip command + p->framebuf[INTRA2NET_VFD_SCREENSIZE * 2 + INTRA2NET_VFD_PACKEDSIZE] = 64; + + // Write data to display + ftdi_write_data (&p->ftdi, p->framebuf+packed_begin, INTRA2NET_VFD_PACKEDSIZE+1); + + p->changed = 0; +} + +///////////////////////////////////////////////////////////////// +// Prints a string on the lc display, at position (x,y). The +// upper-left is (1,1), and the lower right should be (20,4). +// +MODULE_EXPORT void +i2500vfd_string (Driver *drvthis, int x, int y, const char string[]) +{ + int i; + x--; // Convert 1-based coords to 0-based + y--; + + for (i = 0; string[i]; i++) + drawchar2fb (drvthis, x + i, y, string[i]); +} + +///////////////////////////////////////////////////////////////// +// Writes char c at position x,y into the framebuffer. +// x and y are 1-based textmode coordinates. +// +MODULE_EXPORT void +i2500vfd_chr (Driver *drvthis, int x, int y, char c) +{ + y--; + x--; + drawchar2fb(drvthis, x, y, c); +} + +///////////////////////////////////////////////////////////////// +// Changes the font of character n to a pattern given by *dat. +// HD44780 Controllers only posses 8 programmable chars. But +// we store the fontmap completely in RAM, so every character +// can be altered. !Important: Characters have to be redrawn +// by drawchar2fb() to show their new shape. Because we use +// a non-standard 6x8 font a *dat not calculated from +// width and height will fail. +// +MODULE_EXPORT void +i2500vfd_set_char (Driver *drvthis, int n, char *dat) +{ + int row, col; + + if (n < 0 || n > 255) + return; + if (!dat) + return; + + for (row = 0; row < CELLHEIGHT; row++) { + int i = 0; + + for (col = 0; col < CELLWIDTH; col++) + i = (i << 1) | (dat[(row * CELLWIDTH) + col] > 0); + + i2500vfd_fontmap[n][row] = i; + } +} + +///////////////////////////////////////////////////////////////// +// Draws a vertical from the bottom up to the last 3 rows of the +// framebuffer at 1-based position x. len is given in pixels. +// +MODULE_EXPORT void +i2500vfd_vbar(Driver *drvthis, int x, int y, int len, int promille, int pattern) +{ + PrivateData *p = drvthis->private_data; + unsigned int offset; + int i, j, pixels; + + x--; + // don't do y-- as we draw bottom up + + if (x < 0 || y < 1 || x >= WIDTH || y > HEIGHT || len > HEIGHT) { + report(RPT_DEBUG, "%s: [vbar ERROR] x: %d, y: %d, len: %d", drvthis->name, x, y, len); + return; + } + + offset = INTRA2NET_VFD_XSHIFT + x*CELLWIDTH + y*INTRA2NET_VFD_XSIZE*CELLHEIGHT; + pixels = len*CELLHEIGHT*promille/1000; + + // printf("[vbar] x: %d, y: %d, len: %d, offset: %d, pixels: %d\n", x, y, len, offset, pixels); + for (i = 0; i < pixels; i++) { + for (j = 0; j < CELLWIDTH; j++) { + p->framebuf[offset+j] = 1; + } + // go to next y-line + offset -= INTRA2NET_VFD_XSIZE; + } + + p->changed = 1; +} + +///////////////////////////////////////////////////////////////// +// Draws a horizontal bar from left to right at 1-based position +// x,y into the framebuffer. len is given in characters; +// +MODULE_EXPORT void +i2500vfd_hbar(Driver *drvthis, int x, int y, int len, int promille, int pattern) +{ + PrivateData *p = drvthis->private_data; + unsigned int offset; + int i, j, pixels; + + x--; + y--; + + if (y < 0 || y >= HEIGHT || x < 0 || len < 0 || x + len > WIDTH) { + return; + } + + offset = INTRA2NET_VFD_XSHIFT + 2 + x*CELLWIDTH + y*INTRA2NET_VFD_XSIZE*CELLHEIGHT; + + // calculate length of bar + pixels = len*CELLWIDTH*promille/1000; + + for (i = 0; i < CELLHEIGHT-1; i++) { + for (j = 0; j < pixels; j++) { + p->framebuf[offset+j] = 1; + } + // go to next y-line + offset += INTRA2NET_VFD_XSIZE; + } + + p->changed = 1; +} + +///////////////////////////////////////////////////////////////// +// Reprogrammes character dest to contain an icon given by +// which. Calls set_char() to do this. +// +MODULE_EXPORT int +i2500vfd_icon (Driver *drvthis, int x, int y, int icon) +{ + static char heart_open[] = { + 1, 1, 1, 1, 1, + 1, 0, 1, 0, 1, + 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, + 1, 0, 0, 0, 1, + 1, 1, 0, 1, 1, + 1, 1, 1, 1, 1 }; + + static char heart_filled[] = { + 1, 1, 1, 1, 1, + 1, 0, 1, 0, 1, + 0, 1, 0, 1, 0, + 0, 1, 1, 1, 0, + 0, 1, 1, 1, 0, + 1, 0, 1, 0, 1, + 1, 1, 0, 1, 1, + 1, 1, 1, 1, 1 }; + + switch (icon) { + case ICON_BLOCK_FILLED: + i2500vfd_chr(drvthis, x, y, 255); + break; + case ICON_HEART_FILLED: + i2500vfd_set_char(drvthis, 0, heart_filled); + i2500vfd_chr(drvthis, x, y, 0); + break; + case ICON_HEART_OPEN: + i2500vfd_set_char(drvthis, 0, heart_open); + i2500vfd_chr(drvthis, x, y, 0); + break; + default: + return -1; + } + + return 0; +} diff --git a/server/drivers/i2500vfd.h b/server/drivers/i2500vfd.h new file mode 100644 index 0000000..4087585 --- /dev/null +++ b/server/drivers/i2500vfd.h @@ -0,0 +1,23 @@ +#ifndef I2500VFD_H +#define I2500VFD_H + +#include "lcd.h" + +MODULE_EXPORT int i2500vfd_init (Driver *drvthis); +MODULE_EXPORT void i2500vfd_close (Driver *drvthis); +MODULE_EXPORT int i2500vfd_width (Driver *drvthis); +MODULE_EXPORT int i2500vfd_height (Driver *drvthis); +MODULE_EXPORT int i2500vfd_cellwidth (Driver *drvthis); +MODULE_EXPORT int i2500vfd_cellheight (Driver *drvthis); +MODULE_EXPORT void i2500vfd_clear (Driver *drvthis); +MODULE_EXPORT void i2500vfd_flush (Driver *drvthis); +MODULE_EXPORT void i2500vfd_string (Driver *drvthis, int x, int y, const char string[]); +MODULE_EXPORT void i2500vfd_chr (Driver *drvthis, int x, int y, char c); + +MODULE_EXPORT void i2500vfd_vbar(Driver *drvthis, int x, int y, int len, int promille, int pattern); +MODULE_EXPORT void i2500vfd_hbar(Driver *drvthis, int x, int y, int len, int promille, int pattern); +MODULE_EXPORT int i2500vfd_icon (Driver *drvthis, int x, int y, int icon); + +MODULE_EXPORT void i2500vfd_set_char (Driver *drvthis, int n, char *dat); + +#endif diff --git a/server/drivers/i2500vfdfm.c b/server/drivers/i2500vfdfm.c new file mode 100644 index 0000000..39d4b8f --- /dev/null +++ b/server/drivers/i2500vfdfm.c @@ -0,0 +1,835 @@ +////////////////////////////////////////////////////////////////////////// +// This file contains a HD44780 font and a font for big numbers. // +// The HD44780 font in this file was shamelessly stolen from // +// Michael Reinelt / lcd4linux and is // +// Copyright 1999, 2000 by Michael Reinelt (reinelt@eunet.at) // +// The rest of this file is // +// // +// (C) 2001 Robin Adams ( robin@adams-online.de ) // +// // +// This file is released under the GPL. See file COPYING in this // +// package for further details. // +////////////////////////////////////////////////////////////////////////// + +#define b______ 0x00 +#define b_____O 0x01 +#define b____O_ 0x02 +#define b____OO 0x03 +#define b___O__ 0x04 +#define b___O_O 0x05 +#define b___OO_ 0x06 +#define b___OOO 0x07 +#define b__O___ 0x08 +#define b__O__O 0x09 +#define b__O_O_ 0x0a +#define b__O_OO 0x0b +#define b__OO__ 0x0c +#define b__OO_O 0x0d +#define b__OOO_ 0x0e +#define b__OOOO 0x0f +#define b_O____ 0x10 +#define b_O___O 0x11 +#define b_O__O_ 0x12 +#define b_O__OO 0x13 +#define b_O_O__ 0x14 +#define b_O_O_O 0x15 +#define b_O_OO_ 0x16 +#define b_O_OOO 0x17 +#define b_OO___ 0x18 +#define b_OO__O 0x19 +#define b_OO_O_ 0x1a +#define b_OO_OO 0x1b +#define b_OOO__ 0x1c +#define b_OOO_O 0x1d +#define b_OOOO_ 0x1e +#define b_OOOOO 0x1f +#define b_OOOOO 0x1f +#define bOOOOOO 0x3f + +unsigned char i2500vfd_fontmap[256][8] = { + [0x20] {b______, + b______, + b______, + b______, + b______, + b______, + b______, + b______}, + [0x21] {b___O__, + b___O__, + b___O__, + b___O__, + b______, + b______, + b___O__, + b______}, + [0x22] {b__O_O_, + b__O_O_, + b__O_O_, + b______, + b______, + b______, + b______, + b______}, + [0x23] {b__O_O_, + b__O_O_, + b_OOOOO, + b__O_O_, + b_OOOOO, + b__O_O_, + b__O_O_, + b______}, + [0x24] {b___O__, + b__OOOO, + b_O_O__, + b__OOO_, + b___O_O, + b_OOOO_, + b___O__, + b______}, + [0x25] {b_OO___, + b_OO__O, + b____O_, + b___O__, + b__O___, + b_O__OO, + b____OO, + b______}, + [0x26] {b__OO__, + b_O__O_, + b_O_O__, + b__O___, + b_O_O_O, + b_O__O_, + b__OO_O, + b______}, + [0x27] {b__OO__, + b___O__, + b__O___, + b______, + b______, + b______, + b______, + b______}, + [0x28] {b____O_, + b___O__, + b__O___, + b__O___, + b__O___, + b___O__, + b____O_, + b______}, + [0x29] {b__O___, + b___O__, + b____O_, + b____O_, + b____O_, + b___O__, + b__O___, + b______}, + [0x2a] {b______, + b___O__, + b_O_O_O, + b__OOO_, + b_O_O_O, + b___O__, + b______, + b______}, + [0x2b] {b______, + b___O__, + b___O__, + b_OOOOO, + b___O__, + b___O__, + b______, + b______}, + [0x2c] {b______, + b______, + b______, + b______, + b__OO__, + b___O__, + b__O___, + b______}, + [0x2d] {b______, + b______, + b______, + b_OOOOO, + b______, + b______, + b______, + b______}, + [0x2e] {b______, + b______, + b______, + b______, + b______, + b__OO__, + b__OO__, + b______}, + [0x2f] {b______, + b_____O, + b____O_, + b___O__, + b__O___, + b_O____, + b______, + b______}, + [0x30] {b__OOO_, + b_O___O, + b_O__OO, + b_O_O_O, + b_OO__O, + b_O___O, + b__OOO_, + b______}, + [0x31] {b___O__, + b__OO__, + b___O__, + b___O__, + b___O__, + b___O__, + b__OOO_, + b______}, + [0x32] {b__OOO_, + b_O___O, + b_____O, + b____O_, + b___O__, + b__O___, + b_OOOOO, + b______}, + [0x33] {b_OOOOO, + b____O_, + b___O__, + b____O_, + b_____O, + b_O___O, + b__OOO_, + b______}, + [0x34] {b____O_, + b___OO_, + b__O_O_, + b_O__O_, + b_OOOOO, + b____O_, + b____O_, + b______}, + [0x35] {b_OOOOO, + b_O____, + b_O____, + b_OOOO_, + b_____O, + b_O___O, + b__OOO_, + b______}, + [0x36] {b___OO_, + b__O___, + b_O____, + b_OOOO_, + b_O___O, + b_O___O, + b__OOO_, + b______}, + [0x37] {b_OOOOO, + b_____O, + b____O_, + b___O__, + b__O___, + b__O___, + b__O___, + b______}, + [0x38] {b__OOO_, + b_O___O, + b_O___O, + b__OOO_, + b_O___O, + b_O___O, + b__OOO_, + b______}, + [0x39] {b__OOO_, + b_O___O, + b_O___O, + b__OOOO, + b_____O, + b____O_, + b__OO__, + b______}, + [0x3a] {b______, + b__OO__, + b__OO__, + b______, + b__OO__, + b__OO__, + b______, + b______}, + [0x3b] {b______, + b__OO__, + b__OO__, + b______, + b__OO__, + b___O__, + b__O___, + b______}, + [0x3c] {b____O_, + b___O__, + b__O___, + b_O____, + b__O___, + b___O__, + b____O_, + b______}, + [0x3d] {b______, + b______, + b_OOOOO, + b______, + b_OOOOO, + b______, + b______, + b______}, + [0x3e] {b_O____, + b__O___, + b___O__, + b____O_, + b___O__, + b__O___, + b_O____, + b______}, + [0x3f] {b__OOO_, + b_O___O, + b_____O, + b____O_, + b___O__, + b______, + b___O__, + b______}, + [0x40] {b__OOO_, + b_O___O, + b_____O, + b__OO_O, + b_O_O_O, + b_O_O_O, + b__OOO_, + b______}, + [0x41] {b__OOO_, + b_O___O, + b_O___O, + b_O___O, + b_OOOOO, + b_O___O, + b_O___O, + b______}, + [0x42] {b_OOOO_, + b_O___O, + b_O___O, + b_OOOO_, + b_O___O, + b_O___O, + b_OOOO_, + b______}, + [0x43] {b__OOO_, + b_O___O, + b_O____, + b_O____, + b_O____, + b_O___O, + b__OOO_, + b______}, + [0x44] {b_OOO__, + b_O__O_, + b_O___O, + b_O___O, + b_O___O, + b_O__O_, + b_OOO__, + b______}, + [0x45] {b_OOOOO, + b_O____, + b_O____, + b_OOOO_, + b_O____, + b_O____, + b_OOOOO, + b______}, + [0x46] {b_OOOOO, + b_O____, + b_O____, + b_OOOO_, + b_O____, + b_O____, + b_O____, + b______}, + [0x47] {b__OOO_, + b_O___O, + b_O____, + b_O_OOO, + b_O___O, + b_O___O, + b__OOOO, + b______}, + [0x48] {b_O___O, + b_O___O, + b_O___O, + b_OOOOO, + b_O___O, + b_O___O, + b_O___O, + b______}, + [0x49] {b__OOO_, + b___O__, + b___O__, + b___O__, + b___O__, + b___O__, + b__OOO_, + b______}, + [0x4a] {b___OOO, + b____O_, + b____O_, + b____O_, + b____O_, + b_O__O_, + b__OO__, + b______}, + [0x4b] {b_O___O, + b_O__O_, + b_O_O__, + b_OO___, + b_O_O__, + b_O__O_, + b_O___O, + b______}, + [0x4c] {b_O____, + b_O____, + b_O____, + b_O____, + b_O____, + b_O____, + b_OOOOO, + b______}, + [0x4d] {b_O___O, + b_OO_OO, + b_O_O_O, + b_O_O_O, + b_O___O, + b_O___O, + b_O___O, + b______}, + [0x4e] {b_O___O, + b_O___O, + b_OO__O, + b_O_O_O, + b_O__OO, + b_O___O, + b_O___O, + b______}, + [0x4f] {b__OOO_, + b_O___O, + b_O___O, + b_O___O, + b_O___O, + b_O___O, + b__OOO_, + b______}, + [0x50] {b_OOOO_, + b_O___O, + b_O___O, + b_OOOO_, + b_O____, + b_O____, + b_O____, + b______}, + [0x51] {b__OOO_, + b_O___O, + b_O___O, + b_O___O, + b_O_O_O, + b_O__O_, + b__OO_O, + b______}, + [0x52] {b_OOOO_, + b_O___O, + b_O___O, + b_OOOO_, + b_O_O__, + b_O__O_, + b_O___O, + b______}, + [0x53] {b__OOOO, + b_O____, + b_O____, + b__OOO_, + b_____O, + b_____O, + b_OOOO_, + b______}, + [0x54] {b_OOOOO, + b___O__, + b___O__, + b___O__, + b___O__, + b___O__, + b___O__, + b______}, + [0x55] {b_O___O, + b_O___O, + b_O___O, + b_O___O, + b_O___O, + b_O___O, + b__OOO_, + b______}, + [0x56] {b_O___O, + b_O___O, + b_O___O, + b_O___O, + b_O___O, + b__O_O_, + b___O__, + b______}, + [0x57] {b_O___O, + b_O___O, + b_O___O, + b_O_O_O, + b_O_O_O, + b_O_O_O, + b__O_O_, + b______}, + [0x58] {b_O___O, + b_O___O, + b__O_O_, + b___O__, + b__O_O_, + b_O___O, + b_O___O, + b______}, + [0x59] {b_O___O, + b_O___O, + b_O___O, + b__O_O_, + b___O__, + b___O__, + b___O__, + b______}, + [0x5a] {b_OOOOO, + b_____O, + b____O_, + b___O__, + b__O___, + b_O____, + b_OOOOO, + b______}, + [0x5b] {b__OOO_, + b__O___, + b__O___, + b__O___, + b__O___, + b__O___, + b__OOO_, + b______}, + [0x5c] {b_O___O, + b__O_O_, + b_OOOOO, + b___O__, + b_OOOOO, + b___O__, + b___O__, + b______}, + [0x5d] {b__OOO_, + b____O_, + b____O_, + b____O_, + b____O_, + b____O_, + b__OOO_, + b______}, + [0x5e] {b___O__, + b__O_O_, + b_O___O, + b______, + b______, + b______, + b______, + b______}, + [0x5f] {b______, + b______, + b______, + b______, + b______, + b______, + b_OOOOO, + b______}, + [0x60] {b__O___, + b___O__, + b____O_, + b______, + b______, + b______, + b______, + b______}, + [0x61] {b______, + b______, + b__OOO_, + b_____O, + b__OOOO, + b_O___O, + b__OOOO, + b______}, + [0x62] {b_O____, + b_O____, + b_O____, + b_O_OO_, + b_OO__O, + b_O___O, + b_OOOO_, + b______}, + [0x63] {b______, + b______, + b__OOO_, + b_O____, + b_O____, + b_O___O, + b__OOO_, + b______}, + [0x64] {b_____O, + b_____O, + b_____O, + b__OO_O, + b_O__OO, + b_O___O, + b__OOOO, + b______}, + [0x65] {b______, + b______, + b__OOO_, + b_O___O, + b_OOOOO, + b_O____, + b__OOO_, + b______}, + [0x66] {b___OO_, + b__O__O, + b__O___, + b_OOO__, + b__O___, + b__O___, + b__O___, + b______}, + [0x67] {b______, + b__OOOO, + b_O___O, + b_O___O, + b__OOOO, + b_____O, + b__OOO_, + b______}, + [0x68] {b_O____, + b_O____, + b_O_OO_, + b_OO__O, + b_O___O, + b_O___O, + b_O___O, + b______}, + [0x69] {b___O__, + b______, + b__OO__, + b___O__, + b___O__, + b___O__, + b__OOO_, + b______}, + [0x6a] {b____O_, + b______, + b___OO_, + b____O_, + b____O_, + b_O__O_, + b__OO__, + b______}, + [0x6b] {b__O___, + b__O___, + b__O__O, + b__O_O_, + b__OO__, + b__O_O_, + b__O__O, + b______}, + [0x6c] {b__OO__, + b___O__, + b___O__, + b___O__, + b___O__, + b___O__, + b__OOO_, + b______}, + [0x6d] {b______, + b______, + b_OO_O_, + b_O_O_O, + b_O_O_O, + b_O___O, + b_O___O, + b______}, + [0x6e] {b______, + b______, + b_OOOO_, + b_O___O, + b_O___O, + b_O___O, + b_O___O, + b______}, + [0x6f] {b______, + b______, + b__OOO_, + b_O___O, + b_O___O, + b_O___O, + b__OOO_, + b______}, + [0x70] {b______, + b______, + b_OOOO_, + b_O___O, + b_OOOO_, + b_O____, + b_O____, + b______}, + [0x71] {b______, + b______, + b__OO_O, + b_O__OO, + b__OOOO, + b_____O, + b_____O, + b______}, + [0x72] {b______, + b______, + b_O_OO_, + b_OO__O, + b_O____, + b_O____, + b_O____, + b______}, + [0x73] {b______, + b______, + b__OOO_, + b_O____, + b__OOO_, + b_____O, + b_OOOO_, + b______}, + [0x74] {b__O___, + b_OOO__, + b__O___, + b__O___, + b__O___, + b__O__O, + b___OO_, + b______}, + [0x75] {b______, + b______, + b_O___O, + b_O___O, + b_O___O, + b_O__OO, + b__OO_O, + b______}, + [0x76] {b______, + b______, + b_O___O, + b_O___O, + b_O___O, + b__O_O_, + b___O__, + b______}, + [0x77] {b______, + b______, + b_O___O, + b_O___O, + b_O___O, + b_O_O_O, + b__O_O_, + b______}, + [0x78] {b______, + b______, + b_O___O, + b__O_O_, + b___O__, + b__O_O_, + b_O___O, + b______}, + [0x79] {b______, + b______, + b_O___O, + b_O___O, + b__OOOO, + b_____O, + b__OOO_, + b______}, + [0x7a] {b______, + b______, + b_OOOOO, + b____O_, + b___O__, + b__O___, + b_OOOOO, + b______}, + [0x7b] {b____O_, + b___O__, + b___O__, + b__O___, + b___O__, + b___O__, + b____O_, + b______}, + [0x7c] {b___O__, + b___O__, + b___O__, + b___O__, + b___O__, + b___O__, + b___O__, + b______}, + [0x7d] {b__O___, + b___O__, + b___O__, + b____O_, + b___O__, + b___O__, + b__O___, + b______}, + [0x7e] {b______, + b___O__, + b____O_, + b_OOOOO, + b____O_, + b___O__, + b______, + b______}, + + [0x7f] {b______, + b___O__, + b__O___, + b_OOOOO, + b__O___, + b___O__, + b______, + b______}, + [0xb0] {b__OOO_, + b__O_O_, + b__OOO_, + b______, + b______, + b______, + b______, + b______}, + [0xff] {bOOOOOO, + bOOOOOO, + bOOOOOO, + bOOOOOO, + bOOOOOO, + bOOOOOO, + bOOOOOO, + bOOOOOO}, +}; diff --git a/server/drivers/i2500vfdfm.h b/server/drivers/i2500vfdfm.h new file mode 100644 index 0000000..f64dd9d --- /dev/null +++ b/server/drivers/i2500vfdfm.h @@ -0,0 +1,6 @@ +#ifndef I2500VFDFM_H +#define I2500VFDFM_H + +unsigned char i2500vfd_fontmap[256][8]; + +#endif