English
Language : 

MEC1404 Datasheet, PDF (111/572 Pages) Microchip Technology – Keyboard and Embedded Controller Products for Notebook PC
MEC140X/1X
The Configuration Port is composed of an INDEX and DATA Register. The INDEX register is used as an address pointer
to an 8-bit configuration register and the DATA register is used to read or write the data value from the indexed config-
uration register. Once CONFIG MODE is enabled, reading the Configuration Port Data register will return the data value
that is in the indexed Configuration Register.
If no value was written to the INDEX register, reading the Data Register in the Configuration Port will return the value in
Configuration Address location 00h (default).
TABLE 4-8: CONFIGURATION PORT
Default I/O
Address
(Note 4-7)
002Eh
002Fh
Type
Read /
Write
Read /
Write
Register Name
Relative Address
Default
Value
INDEX
Configuration Port’s Base Address + 0
00h
Notes
Note 4-7
DATA
Configuration Port’s Base Address + 1
00h
Note 4-7
The default Base I/O Address of the Configuration Port can be relocated by programming the BAR
register for Logical Device Ch (LPC/Configuration Port) at offset 60h. The Relative Address shows
the general case for determining the I/O address for each register.
4.8.3.1 Enable CONFIG MODE
The INDEX and DATA registers are effective only when the chip is in CONFIG MODE. CONFIG MODE is enabled when
the Config Entry Key is successfully written to the I/O address of the INDEX register of the CONFIG PORT while the
CONFIG MODE is disabled (see Section 4.8.3.2, "Disable CONFIG MODE").
Config Entry Key = < 55h>
4.8.3.2 Disable CONFIG MODE
CONFIG MODE defaults to disabled on a nSYSRST, nSIO_RESET, and when LRESET# is asserted. CONFIG MODE
is also disabled when the following Config Exit Key is successfully written to the I/O address of the INDEX PORT of the
CONFIG PORT while CONFIG MODE is enabled.
Config Exit Key = < AAh>
4.8.3.3 Configuration Sequence Example
To program the configuration registers, the following sequence must be followed:
1. Enable Configuration State
2. Program the Configuration Registers
3. Disable Configuration State.
The following is an example of a configuration program in Intel 8086 assembly language.
;----------------------------.
; ENABLE CONFIGURATION STATE
;----------------------------'
MOV
DX,CONFIG_PORT_BASE_ADDRESS
MOV
AX,055H; Config Entry Key
OUT
DX,AL
;----------------------------.
; CONFIGURE BASE ADDRESS, |
; LOGICAL DEVICE 8
|
;----------------------------'
MOV
DX,CONFIG_PORT_BASE_ADDRESS
MOV
AL,07H
OUT
DX,AL; Point to LD# Config Reg
MOV
DX,CONFIG_PORT_BASE_ADDRESS+1
MOV
AL, 08H
OUT DX,AL; Point to Logical Device 8
 2015 - 2016 Microchip Technology Inc.
DS00001956D-page 111