I have a problem with the module RCM4010

When I read the port D, I always obtain 0xFF value, but I expect to obtain 0x00. Of course, I don’t have anything connected to port D.
I have the port D configured as input.

Anybody could post an example of configuring the port D as input, and how to read and store the result on a variable ?