2020-05-08 07:56:34 -04:00
|
|
|
: _cmd LCD_PORT_CMD PC! LCDWAIT ;
|
|
|
|
: _data! LCD_PORT_DATA PC! LCDWAIT ;
|
|
|
|
: _data@ LCD_PORT_DATA PC@ LCDWAIT ;
|
2020-05-08 06:50:34 -04:00
|
|
|
: LCDOFF 0x02 ( CMD_DISABLE ) _cmd ;
|
2020-05-08 09:07:44 -04:00
|
|
|
: LCDON 0x03 ( CMD_ENABLE ) _cmd ;
|
2020-05-08 06:50:34 -04:00
|
|
|
: _col! ( col -- )
|
|
|
|
0x20 ( CMD_COL ) + _cmd ;
|
|
|
|
: _row! ( row -- )
|
|
|
|
0x80 ( CMD_ROW ) + _cmd ;
|
2020-05-08 09:07:44 -04:00
|
|
|
: LCD$
|
|
|
|
H@ TI_MEM ! FNTH 2 * 2+ ALLOT
|
|
|
|
LCDON 0x01 ( 8-bit mode ) _cmd
|
|
|
|
;
|