Your browser does not allow scripts
Please click here to view a static table of contents without scripts
SPI_GetGPIOs
Return to Introduction  Previous page  Next page
Reads the values of the 4 upper general purpose input/output pins of the FT2232C device.

FTC_STATUS
SPI_GetGPIOs
(FTC_HANDLE ftHandle, PFTC_LOW_HIGH_PINS pHighPinsInputData)




Parameters
ftHandle
Handle of the device.
pHighPinsInputData
Pointer to a structure that contains the value of the upper 4 GPIO pins of the FT2232C device.




Return Value
FTC_SUCCESS if successful, otherwise the return value is one of the following FTC error codes:

   FTC_INVALID_HANDLE
   FTC_NULL_INPUT_OUTPUT_BUFFER_POINTER
   FTC_
FAILED_TO_COMPLETE_COMMAND
   FTC_IO_ERROR



Remarks
This function allows the state of the 4 upper general purpose input/output (GPIO) pins to be read as either high or low. The pins can be configured as input, low output or high output using the SPI_SetGPIOs function.

The definition of the FTC_LOW_HIGH_PINS structure is given in the
Appendix.



Example

FTC_STATUS Status = FTC_SUCCESS;
FTC_HANDLE ftHandle;
FTC_LOW_HIGH_PINS 
HighPinsInputData;

Status = SPI_GetGPIOs(ftHandle, &HighPinsInputData);