Professional Documents
Culture Documents
Two small memories contain information to be displayed and the keypad input.
16 bytes can be stored in the display RAM
8 bytes can be saved in the FIFO/Sensor RAM
The codes for the seven segment displays are written to the display RAM.
The FIFO (First-In -First-Out) contains the row and column information of the
key that is pushed. In the sensor matrix mode, a bit is set in the row and
column of the key that is pushed.
Two display formats are available, which are called left entry mode and right
entry mode. It would be better if these are referred to as fixed and variable
entry modes, since left and right entry depends on how the 8279 is connected
to the displays.
The Scan Counter can be either encoded ( counts 0 to 0FH) or decoded ( 1 out
of 4 lines is active). The SDK-86 uses the encoded mode since it has eight
displays.
8279 Commands
The commands are sent to port 0FFEAH.
The three most significant bits in the command word identify the command.
Keyboard/Display Mode Set
[000DDKKK]
DD
00
01
10
11
KKK
000
001
010
011
100
101
110
111
Program
Divide the external clock to getClock
the 100 kHz operating frequency.
[001PPPPP]
PPPPP is the number that divides the clock to get 100 kHZ which is the
scan rate.
On the SDK-86, the clock pin on the 8279 is connected to the 2.5 MHz PCLK
signal. This must be divided by 25 = 19H = 110012 to get 100 kHz. Therefore,
the command word is
[ 0 0 1 1 1 0 0 1] = 39H
II-25
Read FIFO/Sensor
Sets up the 8279 so that the next read of 0FFE8H puts the contents of the
RAM
FIFO on the data pin.
[ 0 1 0 AI X A A A ]
The SDK-86 uses the Scan Keyboard mode where the AI and AAA bits are
irrelevant. The command to read the FIFO is
[ 0 1 0 0 0 0 0 0 ] = 40H
Read Display RAM
Since we write the display RAM, we dont often use this command.
[ 0 1 1 AI A A A A]
AI is the auto-increment bit and AAAA is the address. If AI is set, the
address is automatically incremented.
II-26
col
Data Sheet
0 1 2
3 4
SDK-86
5 6 7
5 4 3 2
1 0
Left Entry Mode - 8 Character Display - the numbers above the boxes are fixed.
1
2 3
4 5 6
7 0
7 6 5 4
3 2 1
Right Entry Mode - the numbers shift before the data is output.
The SDK-86 is wired so that the numbers are reversed from the data sheet.
In the autoincrement mode, the data is written in consecutive locations until a
new command is sent. Right entry mode as shown in the data sheet is the input
mode used by a calculator. If you make a mistake entering data on a calculator
you clear the entry and start over.
DX,0FFEAH
AL,94H
DX,AL
DX,0FFE8H
CX,4
SI,0
AL,DISP[SI]
DX,AL
SI
BACK
7 6 5 4
SDK-86 display
II-27
Other
A B A B
Commands
Display Write Inhibit/Blanking [ 1 0 1 X IW IW BL BL ]
Inhibits or blanks A0-A3 and/or B0-B3. This disrupts the character display.
Clear
[ 1 1 0 Cd Cd Cd Cf Ca ]
[ 1 1 0 1 0 0 1 1 ] = 0D3H clears the display (outputs 0s to segments)
These 2 bits = 1 turns on all the segments.
End Interrupt
[1110XXXX]