/*
 * lcd_sed1335.h - Epson SED 1335 LCD controller
 * (C) 2006 Cole Design and Development
 */

#ifndef _LCD_SED1335_H
#define _LCD_SED1335_H	1

char lcd_read_data(void);
void lcd_write_cmd(char c);
void lcd_write_data(char c);
void lcd_clear(void);
void lcd_print(char *s);

// Command Set
#define SED1335_CMD_SYSTEM_SET	0x40	// Init device and display
#define SED1335_CMD_SLEEP_IN	0x53	// Enter standby mode
#define SED1335_CMD_DISP_OFF	0x58	// Disable display and flashing
#define SED1335_CMD_DISP_ON	0x59	// Enable display and flashing
#define SED1335_CMD_SCROLL	0x44	// Set display start address and region
#define SED1335_CMD_CSRFORM	0x5D	// Set cursor type
#define SED1335_CMD_CGRAM_ADR	0x5C	// Set start address of char generator RAM
#define SED1335_CMD_CSRDIR_U	0x4E	// Set direction of cursor movement - up
#define SED1335_CMD_CSRDIR_D	0x4F	// Down
#define SED1335_CMD_CSRDIR_L	0x4D	// Left
#define SED1335_CMD_CSRDIR_R	0x4C	// Right
#define SED1335_CMD_HDOT_SCR	0x5A	// Set horizontal scroll position
#define SED1335_CMD_OVLAY	0x5B	// Set display overlay format
#define SED1335_CMD_CSRW	0x46	// Set cursor address
#define SED1335_CMD_CSRR	0x47	// Read cursor address
#define SED1335_CMD_MWRITE	0x42	// Write to display memory
#define SED1335_CMD_MREAD	0x43	// Read from display memory

#endif // _LCD_SED1335_H


