English
Language : 

PIC32MX440F256H-80I Datasheet, PDF (464/646 Pages) Microchip Technology – 64/100-Pin General Purpose and USB 32-Bit Flash Microcontrollers
PIC32MX3XX/4XX
20.3.14 ADDRESSABLE SLAVE MODE
In the Addressable Parallel Slave Port mode, the mod-
ule is configured with two extra inputs, PMA<1:0>. This
makes the 4-byte buffer space directly addressable as
fixed pairs of read and write buffers. As with Buffered
Legacy mode, data is output from register PMDOUT
and is input to register PMDIN. Table 20-10 shows the
address resolution for the incoming address to the
input and output registers.
TABLE 20-10: SLAVE MODE BUFFER
ADDRESSES
PMA<1:0>
Output Register
PMDOUT
(Buffer)
Input Register
PMDIN (Buffer)
00
<7:0> (0)
<7:0> (0)
01
<15:8> (1)
<15:8> (1)
10
<23:16> (2)
<23:16> (2)
11
<31:24> (3)
<31:24> (3)
FIGURE 20-10: PARALLEL MASTER/SLAVE CONNECTION ADDRESSABLE BUFFER
Master
A<1:0>
D<7:0>
CS
RD
WR
PMA<1:0>
PIC32MX3XX/4XX Slave
PMD<7:0> Write
Address
Decode
Read
Address
Decode
PMCS1
PMRD
PMWR
PMDOUT (0)
PMDOUT (1)
PMDOUT (2)
PMDOUT (3)
PMDIN (0)
PMDIN (1)
PMDIN (2)
PMDIN (3)
20.3.15 ADDRESSABLE SLAVE
CONFIGURATION
The Addressable Slave mode configuration is deter-
mined automatically and dedicated to the PSP module
when the Addressable Slave mode is selected. The
user only need to configure the polarity of the PMCS1,
PMRD and PMWR signals.
The following example illustrates which control bits are
to be set for Addressable Slave mode configuration:
• Configure Addressable Slave mode bits –
MODE<1:0> (PMMODE<9:8>) = 01
• Select PMRD “active-low” pin polarity –
RDSP (PMCON<0>) = 0
• Select PMWR “active-low” pin polarity –
WRSP (PMCON<1>) = 0
• Select PMCS2, PMCS1 “active-low” pin polarity –
CS2P (PMCON<4>) = 0 and CS1P (PMCON<3>) = 0
20.3.16 ADDRESSABLE SLAVE PORT
INITIALIZATION
The Addressable Slave mode initialization properly
prepares the PSP port for communicating with an
external master device.
The following steps should be performed to properly
configure the PSP port:
1. If interrupts are used, disable the PMP interrupt
by clearing the interrupt enable bit PMPIE
(IEC1<2>) = 0.
2. Stop and reset the PMP module by clearing the
control bit ON (PMCON<15>) = 0.
3. Configure the desired settings in the PMCON
and PMMODE control registers.
4. If interrupts are used:
a) Clear interrupt flag bit PMPIF
(IFS1<2>) = 0.
b) Configure the PMP interrupt priority bits
PMPIP<2:0> (IPC7<4:2>) and interrupt sub
priority bits PMPIS (IPC7<1:0>.
c) Enable PSP interrupt by setting interrupt
enable bit PMPIE = 1.
5. Enable the PMP slave port by setting control bit
ON = 1.
DS61143E-page 462
Preliminary
© 2008 Microchip Technology Inc.