PARALEL PORT D on RCM4010

It’s possible to configure PARALEL PORT D[0…3] as outputs and PARALEL PORT D[4…7] as imputs ?? I’m ussing the rabbit 4010 whit serie prototyping board.

I read something in the RABBIT FORUM about the PARALEL PORT D that is not posible to use like I/O.Exist anyway to do ?

The code I use.

main()
{
WrPortI(PDDCR, &PDDCRShadow, 0x00); // make D non-open drain
WrPortI(PDDDR, &PDDDRShadow, 0x0F); // make D output WrPortI(PDDR, &PDDRShadow, 0x0F); // PD[0…3] ON.
}

But pins PD[0…3] stay at 0 volts. What is wrong ?

Thanks.

Maybe the Parallel Port D Function Register (PDFR) needs to be set up. See page 94 in the Rabbit 4000 Microprocessor User’s Manual. If an alternate pin function is enabled this might affect the I/O capability of the pins.

Thank you for your answer but i can not solve the problem yet. I would like set all PORT D pins as outputs and logic value ‘1’.

This is my code.

main() {

WrPortI(PDDDR, &PDDDRShadow, 0xFF);
WrPortI(PDDR, &PDDRShadow, 0x00);
WrPortI(PDCR, &PDCRShadow, 0x00);
WrPortI(PDFR, &PDFRShadow, 0x00);
WrPortI(PDDCR, &PDDCRShadow, 0x00);
WrPortI(PDDR, &PDDRShadow, 0xFF);

}

What is wrong ??

Thanks.