0001
0002
0003 #define DEFAULT_LCD_BWIDTH 40
0004 #define DEFAULT_LCD_HWIDTH 64
0005
0006 struct hd44780_common {
0007 int ifwidth;
0008 int bwidth;
0009 int hwidth;
0010 unsigned long hd44780_common_flags;
0011 void (*write_data)(struct hd44780_common *hdc, int data);
0012 void (*write_cmd)(struct hd44780_common *hdc, int cmd);
0013
0014 void (*write_cmd_raw4)(struct hd44780_common *hdc, int cmd);
0015 void *hd44780;
0016 };
0017
0018 int hd44780_common_print(struct charlcd *lcd, int c);
0019 int hd44780_common_gotoxy(struct charlcd *lcd, unsigned int x, unsigned int y);
0020 int hd44780_common_home(struct charlcd *lcd);
0021 int hd44780_common_clear_display(struct charlcd *lcd);
0022 int hd44780_common_init_display(struct charlcd *lcd);
0023 int hd44780_common_shift_cursor(struct charlcd *lcd,
0024 enum charlcd_shift_dir dir);
0025 int hd44780_common_shift_display(struct charlcd *lcd,
0026 enum charlcd_shift_dir dir);
0027 int hd44780_common_display(struct charlcd *lcd, enum charlcd_onoff on);
0028 int hd44780_common_cursor(struct charlcd *lcd, enum charlcd_onoff on);
0029 int hd44780_common_blink(struct charlcd *lcd, enum charlcd_onoff on);
0030 int hd44780_common_fontsize(struct charlcd *lcd, enum charlcd_fontsize size);
0031 int hd44780_common_lines(struct charlcd *lcd, enum charlcd_lines lines);
0032 int hd44780_common_redefine_char(struct charlcd *lcd, char *esc);
0033 struct hd44780_common *hd44780_common_alloc(void);