GPIO Functions


Functions

int fwCcpc_GPIOEnable (string pCCPC, int pLine, int pDirection)
int fwCcpc_GPIODisable (string pCCPC, int pLine)
int fwCcpc_GPIOSet (string pCCPC, int pLine, int pValue)
int fwCcpc_GPIOGet (string pCCPC, int pLine, int &pValue)

Detailed Description

List of functions to operate with GPIO lines (General Purpose I/O lines).

Function Documentation

int fwCcpc_GPIODisable ( string  pCCPC,
int  pLine 
)

This function disables a GPIO line as input or output line.

Parameters:
[in] pCCPC name of the CCPC to be reset.
[in] pLine number of GPIO line.
Returns:
= 0 no error found.

> 0 error found (related with CCPC Server).

= -1 error found (related with PVSS).

Example:

  (...)
  if (fwCcpc_GPIODisable("pclbcecs03",FWCCPC_GPIO_LINE_3) == 0)   // disables GPIO line no.3 
     (...)
  else
     DebugTN("Error found!");
  (...)



int fwCcpc_GPIOEnable ( string  pCCPC,
int  pLine,
int  pDirection 
)

This function enables a GPIO line as input or output line.

Parameters:
[in] pCCPC name of the CCPC to be reset.
[in] pLine number of GPIO line.
[in] pDirection specifies direction of signal. ('0' means input and '1' means output)
Returns:
= 0 no error found.

> 0 error found (related with CCPC Server).

= -1 error found (related with PVSS).

Example:

  (...)
  if (fwCcpc_GPIOEnable("pclbcecs03",FWCCPC_GPIO_LINE_3,FWCCPC_GPIO_INPUT) == 0)   // enables GPIO line no.3 as an input line
     (...)
  else
     DebugTN("Error found!");
  (...)



int fwCcpc_GPIOGet ( string  pCCPC,
int  pLine,
int &  pValue 
)

This function gets the level of a GPIO line

Parameters:
[in] pCCPC name of the CCPC to be reset.
[in] pLine number of GPIO line.
[out] pValue returns the level of the signal. ('0' means low and '1' means high)
Returns:
= 0 no error found.

> 0 error found (related with CCPC Server).

= -1 error found (related with PVSS).

Example:

  (...)
  if (fwCcpc_GPIOGet("pclbcecs03", FWCCPC_GPIO_LINE_3, SignalLevel) == 0)   // gets the signal level of GPIO line no3.
     DebugTN("GPIO line no.3 is set to " + SignalLevel);
  else
     DebugTN("Error found!");
  (...)



int fwCcpc_GPIOSet ( string  pCCPC,
int  pLine,
int  pValue 
)

This function sets the level to a GPIO line

Parameters:
[in] pCCPC name of the CCPC to be reset.
[in] pLine number of GPIO line.
[in] pValue specifies the level of the signal. ('0' means low and '1' means high)
Returns:
= 0 no error found.

> 0 error found (related with CCPC Server).

= -1 error found (related with PVSS).

Example:

  (...)
  if (fwCcpc_GPIOSet("pclbcecs03",FWCCPC_GPIO_LINE_3,FWCCPC_GPIO_LOW) == 0)   // sets the signal level to low on GPIO line no3.
     (...)
  else
     DebugTN("Error found!");
  (...)




Generated on Fri Mar 28 13:15:39 2008 for FwCcpc by  doxygen 1.4.7