MOTOROLA
7-4
PARALLEL INPUT/OUTPUT
M68HC11
REFERENCE MANUAL
Figure 7-2 Pin Logic Registers and Control Bits
The addresses for the registers in
Figure 7-1
and
Figure 7-2
are in the form "$10xx"
where xx is a hexadecimal number between 00 and 3F. The "1" indicates that the most
significant hexadecimal digit is a variable controlled by user software. The RAM and I/
O mapping (INIT) register is used to specify the location of internal registers and RAM.
By default, RAM is located from $0000 to $00FF, and registers are located from $1000
to $103F at reset. The user can elect to move either one or both of these resources by
writing a new value into the INIT register within 64 bus cycles after reset. The INIT reg-
ister is discussed in greater detail in
SECTION 4 ON-CHIP MEMORY
.
The bit-manipulation instructions in the MC68HC11A8 can only be used in zero-page
or indexed addressing modes. To use indexed addressing mode to access internal
registers, the user would first set either the X or Y index register equal to the base ad-
dress of the registers (usually $1000). To use the zero-page addressing mode, the
user would first remap the internal registers by writing to the INIT register during reset
initialization.
7.2.1 Port Registers
Reads of port registers will return either the level at the pin itself or the logic state at a
point inside the output pin buffer. Usually, the state of the corresponding DDR bit will
determine which of these points will be used for a read if a choice exists. Refer to
7.3
Detailed I/O Pin Descriptions
for more specific information. Writes to port registers
cause the written data to be latched and driven out of the corresponding port output
pins.
If a port pin is capable of being an output, this written information is latched even if the
pin is not configured as a port output at the time of the write. If the pin is subsequently
reconfigured to be a port output, the output pin will be driven with the last data that was
written to that port. Writes to port bits that are fixed-direction input pins have no mean-
ing or effect.
PORTCL, a special port register associated with port C, is part of the handshake I/O
subsystem. Reads of this address return data from an 8-bit port C latch. The inputs to
Bit 7
FOC1
6
5
4
3
2
0
1
0
Bit 0
0
$100B
FOC2
FOC3
FOC4
FOC5
CFORC
$100C
OC1M7
OC1M6
OC1M5
OC1M4
OC1M3
0
0
0
OC1M
$100D
OC1D7
OC1D6
OC1D5
OC1D4
OC1D3
0
0
0
OC1D
$1020
OM2
OL2
OM3
OL3
OM4
OL4
OM5
OL5
TCTL1
$103D
RAM3
RAM2
RAM1
RAM0
REG3
REG2
REG1
REG0
INIT