Hello,
I am trying to increase the speed of data transfer to my CFAF320240F-T my using the PIC32's PMP (Parallel Master Port). I have the display configured to use 8-bit 8080 mode, and have been successful controlling the display using the 8-bit demo code provided by Crystalfontz.
My problem is that once I enable the PMP, it stops wortking. Here is my PMP initialization code:
And my Write_Command and Write_Data functions (these are only used once the PMP is enabled, which happens AFTER LCD Initialization. The initialization uses the normal methods from the CF demo code):
My LCD data lines are connected to PMD0-PMD7, and for the control lines:
Write/Read -> PMWR
Read Strobe -> PMRD
Chip Select -> PMCS2
Chip Reset -> PORTD.1 (general I/O)
Data/Command -> PORTD.2 (general I/O)
My concern is just that I haven't used the PMP much and I'm afraid I have something hooked up wrong or my code is wrong, etc.
If anyone has any insight, I would really appreciate it.
I am trying to increase the speed of data transfer to my CFAF320240F-T my using the PIC32's PMP (Parallel Master Port). I have the display configured to use 8-bit 8080 mode, and have been successful controlling the display using the 8-bit demo code provided by Crystalfontz.
My problem is that once I enable the PMP, it stops wortking. Here is my PMP initialization code:
Code:
// PMP setup
PMMODE = 0; PMAEN = 0; PMCON = 0;
PMMODEbits.MODE = 2; // Intel 80 master interface
PMMODEbits.WAITB = 0;
PMMODEbits.WAITM = 0;
PMMODEbits.WAITE = 0;
PMMODEbits.MODE16 = 0; // 8 bit mode
PMCONbits.PTRDEN = 1; // enable RD line
PMCONbits.PTWREN = 1; // enable WR line
PMCONbits.PMPEN = 1; // enable PMP
Code:
void Write_Command(unsigned int command)
{
CLR_CD;
PMDIN = command;
}
void Write_Data(unsigned int data)
{
SET_CD;
PMDIN = data;
}
Write/Read -> PMWR
Read Strobe -> PMRD
Chip Select -> PMCS2
Chip Reset -> PORTD.1 (general I/O)
Data/Command -> PORTD.2 (general I/O)
My concern is just that I haven't used the PMP much and I'm afraid I have something hooked up wrong or my code is wrong, etc.
If anyone has any insight, I would really appreciate it.
Looking for additional LCD resources? Check out our LCD blog for the latest developments in LCD technology.