English
Language : 

MC908AP8CFBE Datasheet, PDF (241/324 Pages) Freescale Semiconductor, Inc – Microcontrollers
MMIIC I/O Registers
When the MMIIC module is enabled, MMEN = 1, data written into this register depends on whether
module is in master or slave mode.
In slave mode, the data in MMDTR will be transferred to the output circuit when:
• the module detects a matched calling address (MMATCH = 1), with the calling master requesting
data (MMSRW = 1); or
• the previous data in the output circuit has be transmitted and the receiving master returns an
acknowledge bit, indicated by a received acknowledge bit (MMRXAK = 0).
If the calling master does not return an acknowledge bit (MMRXAK = 1), the module will release the SDA
line for master to generate a STOP or repeated START condition. The data in the MMDTR will not be
transferred to the output circuit until the next calling from a master. The transmit buffer empty flag remains
cleared (MMTXBE = 0).
In master mode, the data in MMDTR will be transferred to the output circuit when:
• the module receives an acknowledge bit (MMRXAK = 0), after
setting master transmit mode (MMRW = 0), and the calling address has been transmitted; or
• the previous data in the output circuit has be transmitted and the receiving slave returns an
acknowledge bit, indicated by a received acknowledge bit (MMRXAK = 0).
If the slave does not return an acknowledge bit (MMRXAK = 1), the master will generate a STOP or
repeated START condition. The data in the MMDTR will not be transferred to the output circuit. The
transmit buffer empty flag remains cleared (MMTXBE = 0).
The sequence of events for slave transmit and master transmit are illustrated in Figure 14-12.
14.6.6 MMIIC Data Receive Register (MMDRR)
Address:
Read:
$004D
Bit 7
MMRD7
6
MMRD6
5
MMRD5
4
MMRD4
3
MMRD3
2
MMRD2
1
MMRD1
Write:
Reset: 0
0
0
0
0
0
0
= Unimplemented
Figure 14-9. MMIIC Data Receive Register (MMDRR)
Bit 0
MMRD0
0
When the MMIIC module is enabled, MMEN = 1, data in this read-only register depends on whether
module is in master or slave mode.
In slave mode, the data in MMDRR is:
• the calling address from the master when the address match flag is set (MMATCH = 1); or
• the last data received when MMATCH = 0.
In master mode, the data in the MMDRR is:
• the last data received.
When the MMDRR is read by the CPU, the receive buffer full flag is cleared (MMRXBF = 0), and the next
received data is loaded to the MMDRR. Each time when new data is loaded to the MMDRR, the MMRXIF
interrupt flag is set, indicating that new data is available in MMDRR.
The sequence of events for slave receive and master receive are illustrated in Figure 14-12.
MC68HC908AP Family Data Sheet, Rev. 4
Freescale Semiconductor
239