18.11.2014 Views

The Microcontroller Idea Book - Jan Axelson's Lakeview Research

The Microcontroller Idea Book - Jan Axelson's Lakeview Research

The Microcontroller Idea Book - Jan Axelson's Lakeview Research

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Chapter 8<br />

Table 8-2. Instruction summary for the HD 44780 LCD controller.<br />

Instruction RS R/W D7 D6 D5 D4 D3 D2 D1 D0 Function Execution<br />

time<br />

(max)<br />

Display clear 0 0 0 0 0 0 0 0 0 1 Clear display.<br />

Reset display from shift.<br />

Set DD RAM=0<br />

1.64<br />

msec<br />

Display/cursor<br />

home<br />

Entry mode<br />

set<br />

0 0 0 0 0 0 0 0 1 X Shift=0.<br />

DD RAM=0<br />

0 0 0 0 0 0 0 1 I/D S I/D: increment (1) ,<br />

decrement (0) cursor or<br />

display shift after data<br />

transfer.<br />

S: shift on (1) , off (0).<br />

1.64<br />

msec<br />

40 μsec<br />

Display on/off 0 0 0 0 0 0 1 D C B D: display on (1) , off (0).<br />

C: cursor on (1) , off (0).<br />

B: cursor blink on (1) ,<br />

off(0).<br />

40 μsec<br />

Display/cursor<br />

shift<br />

0 0 0 0 0 1 S/C R/L X X S/C: shift display (1),<br />

cursor (0).<br />

R/L: shift right (1), left (0).<br />

40 μsec<br />

Function set 0 0 0 0 1 DL N 0 X X DL: 8-bit (1), 4-bit (0)<br />

interface.<br />

N: dual (1), single (1) line<br />

display.<br />

40 μsec<br />

CG RAM<br />

address set<br />

DD RAM<br />

address set<br />

Busy<br />

flag/address<br />

counter read<br />

CG/DD RAM<br />

data write<br />

CG/DD RAM<br />

data read<br />

0 0 0 1 CG5 CG4 CG3 CG2 CG1 CG0 Load address counter<br />

with CG0-CG5.<br />

Subsequent data goes to<br />

CG RAM.<br />

0 0 1 DD6 DD5 DD4 DD3 DD2 DD1 DD0 Load address counter<br />

with DD0-DD6.<br />

Subsequent data goes to<br />

DD RAM.<br />

0 1 BF AC6 AC5 AC4 AC3 AC2 AC1 AC0 Read busy flag (BF) and<br />

address counter (AC0-<br />

AC6)<br />

1 0 D7 D6 D5 D4 D3 D2 D1 D0 Write data (D0-D7) to CG<br />

RAM or DD RAM.<br />

1 1 D7 D6 D5 D4 D3 D2 D1 D0 Place data from CG<br />

RAM or DD RAM on D0-<br />

D7.<br />

40 μsec<br />

40 μsec<br />

0<br />

40 μsec<br />

40 μsec<br />

X=don’t care<br />

142 <strong>The</strong> <strong>Microcontroller</strong> <strong>Idea</strong> <strong>Book</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!