Functions | |
| HPI_ERR | HPI_GpioOpen (HPI_HSUBSYS *phSubSys, HW16 wAdapterIndex, HPI_HGPIO *phGpio, HW16 *pwNumberInputBits, HW16 *pwNumberOutputBits) |
| Opens the GPIO on a particular adapter for reading and writing. | |
| HPI_ERR | HPI_GpioReadBit (HPI_HSUBSYS *phSubSys, HPI_HGPIO hGpio, HW16 wBitIndex, HW16 *pwBitData) |
| Read a particular bit from an adapter's GPIO input port. | |
| HPI_ERR | HPI_GpioReadAllBits (HPI_HSUBSYS *phSubSys, HPI_HGPIO hGpio, HW16 *pwBitData) |
| Read all bits from an adapter's GPIO input ports. | |
| HPI_ERR | HPI_GpioWriteBit (HPI_HSUBSYS *phSubSys, HPI_HGPIO hGpio, HW16 wBitIndex, HW16 wBitData) |
| Write a particular bit to an adapter's GPIO output port. | |
| HPI_ERR HPI_API | HPI_GpioWriteStatus (HPI_HSUBSYS *phSubSys, HPI_HGPIO hGpio, HW16 *pwBitData) |
| Read back the current status of an adapter's GPIO output. | |
There is at most one GPIO object per adapter.
On an adapter such as an ASI4346, the bit outputs control relay closurers. HPI_GpioWriteBit() can be used to set the state of each of the relays. Similarly, the inputs on the ASI4346 are mapped 1 to 1 to opto isolated inputs.
|
||||||||||||||||||||||||
|
Opens the GPIO on a particular adapter for reading and writing. It returns a handle to the GPIO object (hGpio) and the number of input and output bits (*pwNumberInputBits,*pwNumberOutputBits). If the adapter does not have any GPIO functionality, the function will return an error.
|
|
||||||||||||||||||||
|
Read a particular bit from an adapter's GPIO input port.
|
|
||||||||||||||||
|
Read all bits from an adapter's GPIO input ports.
|
|
||||||||||||||||||||
|
Write a particular bit to an adapter's GPIO output port.
|
|
||||||||||||||||
|
Read back the current status of an adapter's GPIO output.
|
1.4.6-NO