|
APCIE-3660 API
1719
|
Functions | |
| uint8_t | i_APCIE3660_SetCalibrationValue (PDEVICE_DATA deviceData, uint8_t moduleIndex, uint8_t calibrationSelection, uint32_t calibrationValue) |
| uint8_t | i_APCIE3660_InitAnalogInputModule (PDEVICE_DATA deviceData, uint8_t moduleIndex, uint8_t singleDiffMode, uint8_t coupling, uint8_t enableCurrentSource, uint8_t gainSelection, uint8_t digitalFilter, uint8_t filterPath, uint8_t dataRate, uint8_t calibrationMode) |
| uint8_t | i_APCIE3660_Read1AnalogInputModule (PDEVICE_DATA deviceData, uint8_t moduleIndex, uint32_t *value) |
| uint8_t | i_APCIE3660_ReleaseAnalogInputModule (PDEVICE_DATA deviceData, uint8_t moduleIndex) |
| uint8_t | i_APCIE3660_InitAnalogInputModuleCyclicAcquisition (PDEVICE_DATA deviceData, uint8_t moduleIndex, uint8_t mode, uint32_t onBoardBufferSize, uint32_t compareValue) |
| uint8_t | i_APCIE3660_TriggerAnalogInputModuleCyclicAcquisition (PDEVICE_DATA deviceData, uint8_t moduleIndex) |
| uint8_t | i_APCIE3660_StartAnalogInputModuleCyclicAcquisition (PDEVICE_DATA deviceData, uint8_t moduleIndex) |
| uint8_t | i_APCIE3660_StartMultipleAnalogInputModuleCyclicAcquisition (PDEVICE_DATA deviceData, uint8_t moduleMask) |
| uint8_t | i_APCIE3660_StopAnalogInputModuleCyclicAcquisition (PDEVICE_DATA deviceData, uint8_t moduleIndex) |
| uint8_t | i_APCIE3660_ReleaseAnalogInputModuleCyclicAcquisition (PDEVICE_DATA deviceData, uint8_t moduleIndex) |
| uint8_t i_APCIE3660_SetCalibrationValue | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex, | ||
| uint8_t | calibrationSelection, | ||
| uint32_t | calibrationValue | ||
| ) |
Sets the calibration value
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Index of the analog input module (0 to 3) |
| [in] | calibrationSelection | Select either Gain or Offset ( 0 = GAIN; 1 = OFFSET) |
| [in] | calibrationValue | calibration value to set coded on 12 bits (0 - 4095)(calibration file apcie3660_calibration.conf is stored in /etc/APCIE3660) |
| 0 | No error |
| 2 | The b_ModuleIndex parameter is wrong |
| 3 | Error with calibration selection |
| uint8_t i_APCIE3660_InitAnalogInputModule | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex, | ||
| uint8_t | singleDiffMode, | ||
| uint8_t | coupling, | ||
| uint8_t | enableCurrentSource, | ||
| uint8_t | gainSelection, | ||
| uint8_t | digitalFilter, | ||
| uint8_t | filterPath, | ||
| uint8_t | dataRate, | ||
| uint8_t | calibrationMode | ||
| ) |
Initialize the analog input module moduleIndex
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Index of the analog input module (0 to 3) |
| [in] | singleDiffMode | Single-Ended / Differential mode of each channel
|
| [in] | coupling | Coupling mode (AC / DC) of each channels
|
| [in] | enableCurrentSource | Enable / Disable the current source for each channel
|
| [in] | gainSelection | Gain selection
|
| [in] | digitalFilter |
|
| [in] | filterPath |
|
| [in] | dataRate | Acquisition frequency, depends on digitalFilter and filterPath parameter:
|
| [in] | calibrationMode |
|
| 0 | No error |
| 2 | The moduleIndex parameter is wrong |
| 3 | Module is already initialized. |
| 4 | Wrong Single/Diff Mode selection |
| 5 | Wrong coupling selection |
| 6 | Wrong gain selection |
| 7 | Wrong Current source flag |
| 8 | When the current source is used, the configuration of the channel must be Single-Ended and AC |
| 9 | Wrong filterPath parameter |
| 10 | Wrong digitalFilter parameter |
| 11 | Wrong dataRate parameter |
| 12 | Wrong dataRate parameter due to filterPath and digitalFilter configuration |
| 13 | Wrong filterPath and digitalFilter configuration, both parameter cannot be 0 |
| 14 | The module power supply could not be turned on |
| uint8_t i_APCIE3660_Read1AnalogInputModule | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex, | ||
| uint32_t * | value | ||
| ) |
Read one analog input module
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Index of the analog input module (0 to 3) |
| [out] | value | value of the analog input channel |
| 0 | No error |
| 2 | The moduleIndex parameter is wrong |
| 3 | Module is already initialized. |
| uint8_t i_APCIE3660_ReleaseAnalogInputModule | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex | ||
| ) |
Release the analog input module moduleIndex
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Index of the analog input module (0 to 3) |
| 0 | No error |
| -1 | The deviceData parameter is wrong |
| -2 | The moduleIndex parameter is wrong |
| uint8_t i_APCIE3660_InitAnalogInputModuleCyclicAcquisition | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex, | ||
| uint8_t | mode, | ||
| uint32_t | onBoardBufferSize, | ||
| uint32_t | compareValue | ||
| ) |
To-Do Write doxygen fucntion description Init analog input module cyclic acquisition
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Index of the analog input module (0 to 3) |
| [in] | mode | In both modes, when the compare value is reached, an interrupt occurs to read the value from the buffer.
|
| [in] | onBoardBufferSize | Board buffer size, the size of this buffer is 1024 * (2^dw_OnBoardBufferSize). |
| [in] | compareValue | Define the number of acquisition to have in the board buffer to generate an interrupt to start the DMA transfer (must be < (1024 * (2^dw_OnBoardBufferSize)). |
| 0 | No error |
| 2 | The moduleIndex parameter is wrong |
| 3 | Wrong mode selection |
| 4 | The module is not initialized |
| 5 | The compare value parameter is wrong, must be < (2^dw_OnBoardBufferSize) * 1024) |
| 6 | The cyclic acquisition is already initialized |
| 7 | Not enough place in the on board RAM |
| 8 | The onBoardBufferSize parameter is wrong (bigger than the board RAM size) |
| 9 | The calibration is running on the module |
| uint8_t i_APCIE3660_TriggerAnalogInputModuleCyclicAcquisition | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex | ||
| ) |
Trigger analog input module cyclic acquisition
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Index of the analog input module (0 to 3) |
| 0 | No error |
| 2 | The moduleIndex parameter is wrong |
| 3 | The cyclic acquisition is not initialized |
| 4 | The cyclic acquisition is already started |
| uint8_t i_APCIE3660_StartAnalogInputModuleCyclicAcquisition | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex | ||
| ) |
Start analog input module cyclic acquisition
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Index of the analog input module (0 to 3) |
| 0 | No error |
| 2 | The moduleIndex parameter is wrong |
| 3 | The cyclic acquisition is not initialized or not by this process |
| 4 | An acquisition is already started on this channel |
| uint8_t i_APCIE3660_StartMultipleAnalogInputModuleCyclicAcquisition | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleMask | ||
| ) |
Start analog input module cyclic acquisition
| [in] | deviceData | Handle of the board |
| [in] | moduleMask | mask of the index of the analog input module(s) to start (0 to 15)(0x0 to 0xF: 0x1 = module1, 0x2 = module2, 0x3 = module1 and module2,...) |
| 0 | No error |
| 2 | The moduleIndex parameter is wrong |
| 3 | The cyclic acquisition is not initialized or not by this process |
| 4 | An acquisition is already started on this channel |
| uint8_t i_APCIE3660_StopAnalogInputModuleCyclicAcquisition | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex | ||
| ) |
To-Do Write doxygen fucntion description Stop analog input module cyclic acquisition
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Module to stop |
| 0 | No error |
| 2 | The moduleIndex parameter is wrong |
| uint8_t i_APCIE3660_ReleaseAnalogInputModuleCyclicAcquisition | ( | PDEVICE_DATA | deviceData, |
| uint8_t | moduleIndex | ||
| ) |
Release analog input module cyclic acquisition
| [in] | deviceData | Handle of the board |
| [in] | moduleIndex | Index of the analog input module (0 to 3) |
| 0 | No error |
| 2 | The moduleIndex parameter is wrong |