diff options
author | reinelt <reinelt@3ae390bd-cb1e-0410-b409-cd5a39f66f1f> | 2000-01-16 12:17:59 +0000 |
---|---|---|
committer | reinelt <reinelt@3ae390bd-cb1e-0410-b409-cd5a39f66f1f> | 2000-01-16 12:17:59 +0000 |
commit | dfc5239aecb7e421afd26a4599bc4600d21e12c4 (patch) | |
tree | e884a890843544c3039c1af4c58e43e45b642018 /display.c | |
parent | fba83a8ef0ad2b95cbe55035441c9ad9435ae6c9 (diff) | |
download | lcd4linux-dfc5239aecb7e421afd26a4599bc4600d21e12c4.tar.gz |
[lcd4linux @ 2000-01-16 12:17:59 by reinelt]
Initial revision
git-svn-id: https://ssl.bulix.org/svn/lcd4linux/trunk@2 3ae390bd-cb1e-0410-b409-cd5a39f66f1f
Diffstat (limited to '')
-rw-r--r-- | display.c | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/display.c b/display.c new file mode 100644 index 0000000..d154b67 --- /dev/null +++ b/display.c @@ -0,0 +1,57 @@ +#include <stdlib.h> +#include <stdio.h> + +#include "display.h" + +extern DISPLAY MatrixOrbital[]; + +FAMILY Driver[] = { + { "MatrixOrbital", MatrixOrbital }, + { "" } +}; + + +static DISPLAY *Display = NULL; + +int lcd_init (char *display) +{ + int i, j; + for (i=0; Driver[i].name[0]; i++) { + for (j=0; Driver[i].Display[j].name[0]; j++) { + if (strcmp (Driver[i].Display[j].name, display)==0) { + Display=&Driver[i].Display[j]; + return Display->init(); + } + } + } + fprintf (stderr, "lcd_init(%s) failed: no such display\n", display); + return -1; +} + +int lcd_clear (void) +{ + return 0; +} + +int lcd_put (int x, int y, char *text) +{ + return 0; +} + +int lcd_bar (int type, int x, int y, int max, int len1, int len2) +{ + return 0; +} + +int lcd_flush (void) +{ + return 0; +} + +void main (void) { + int i, j; + + lcd_init ("junk"); + lcd_init ("LCD2041"); + +} |