|
HFCC-01 Low-Level Software (LLSW) Rel_6802_HFCC-01-RP-CSAR-CB
|
Go to the source code of this file.
Functions | |
| ModStatus | modAnalogIn_enableRead (const AInChannelNum channelNum) |
| modAnalogIn_enableRead. | |
| ModStatus | modAnalogIn_disableRead (const AInChannelNum channelNum) |
| modAnalogIn_disableRead. | |
| ModStatus | modAnalogIn_read (const AInChannelNum channelNum, Float32 *readVal) |
| modAnalogIn_read. | |
AnalogIn Module
| ModStatus modAnalogIn_disableRead | ( | const AInChannelNum | channelNum | ) |
modAnalogIn_disableRead.
Disable analog input to stop AIN conversion for specific channel.
| [in] | channelNum | Analog input channel to access. |
| MD_SUCCESS | : Success. |
| MD_INVALID_INIT | : The module has not been initialized. |
| MD_INVALID_CHANNEL | : The channel number is invalid. |
| MD_OP_ALREADY_PERFORMED | : The channel state is already disabled. |
| Requirement ID | Parent HLR ID | Detailed Low-Level Requirement Statement (EARS Format) | Software Unit Reference | Verification Method | Status |
|---|---|---|---|---|---|
| LLR_ANALOGIN_MODANALOGIN_DISABLEREAD_01 | HLR_AIN_16934 | WHEN channelNum is not one of the defined analog input channel identifiers (AIN_5V_CH1, AIN_5V_CH2, AIN_5V_CH3, AIN_5V_CH4, AIN_10V_CH1, AIN_10V_CH2, AIN_10V_CH3, AIN_10V_CH4), the modAnalogIn_disableRead() function SHALL abort processing and return MD_INVALID_CHANNEL. | modAnalogIn.c:modAnalogIn_disableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_DISABLEREAD_02 | HLR_AIN_16934 | WHEN the module initialization state is not initialized (INIT), the modAnalogIn_disableRead() function SHALL abort processing and return MD_INVALID_INIT. | modAnalogIn.c:modAnalogIn_disableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_DISABLEREAD_03 | HLR_AIN_16934 | WHEN the driver status is not equal to DRV_SUCCESS, the modAnalogIn_disableRead() function SHALL abort processing and return the module error code produced by errCheck() for the reported driver status. | modAnalogIn.c:modAnalogIn_disableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_DISABLEREAD_04 | HLR_AIN_16934 | WHEN the target analog input channel is already disabled (channel enable status is FALSE), the modAnalogIn_disableRead() function SHALL abort processing and return MD_OP_ALREADY_PERFORMED. | modAnalogIn.c:modAnalogIn_disableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_DISABLEREAD_05 | HLR_AIN_16934 | WHEN preconditions are satisfied, the modAnalogIn_disableRead() function SHALL invoke routine analogIn_getChannelStatus() to execute target subsystem hardware operation. | modAnalogIn.c:modAnalogIn_disableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_DISABLEREAD_06 | HLR_AIN_16934 | WHEN preconditions are satisfied, the modAnalogIn_disableRead() function SHALL evaluate the driver return status using errCheck(). | modAnalogIn.c:modAnalogIn_disableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_DISABLEREAD_07 | HLR_AIN_16934 | WHEN preconditions are satisfied, the modAnalogIn_disableRead() function SHALL invoke routine analogIn_enableDisableCh() to execute target subsystem hardware operation. | modAnalogIn.c:modAnalogIn_disableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_DISABLEREAD_08 | HLR_AIN_16934 | WHEN all operational processing completes successfully, the modAnalogIn_disableRead() function SHALL return MD_SUCCESS. | modAnalogIn.c:modAnalogIn_disableRead() | Test | Closed |
| ModStatus modAnalogIn_enableRead | ( | const AInChannelNum | channelNum | ) |
modAnalogIn_enableRead.
Enable analog input to start AIN conversion for specific channel.
| [in] | channelNum | Analog input channel to access. |
| MD_SUCCESS | : Success. |
| MD_INVALID_INIT | : The module has not been initialized. |
| MD_INVALID_CHANNEL | : The channel number is invalid. |
| MD_OP_ALREADY_PERFORMED | : The channel state is already enabled. |
| Requirement ID | Parent HLR ID | Detailed Low-Level Requirement Statement (EARS Format) | Software Unit Reference | Verification Method | Status |
|---|---|---|---|---|---|
| LLR_ANALOGIN_MODANALOGIN_ENABLEREAD_01 | HLR_AIN_16934 | WHEN channelNum is not one of the defined analog input channel identifiers (AIN_5V_CH1, AIN_5V_CH2, AIN_5V_CH3, AIN_5V_CH4, AIN_10V_CH1, AIN_10V_CH2, AIN_10V_CH3, AIN_10V_CH4), the modAnalogIn_enableRead() function SHALL abort processing and return MD_INVALID_CHANNEL. | modAnalogIn.c:modAnalogIn_enableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_ENABLEREAD_02 | HLR_AIN_16934 | WHEN the module initialization state is not initialized (INIT), the modAnalogIn_enableRead() function SHALL abort processing and return MD_INVALID_INIT. | modAnalogIn.c:modAnalogIn_enableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_ENABLEREAD_03 | HLR_AIN_16934 | WHEN the driver status is not equal to DRV_SUCCESS, the modAnalogIn_enableRead() function SHALL abort processing and return the module error code produced by errCheck() for the reported driver status. | modAnalogIn.c:modAnalogIn_enableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_ENABLEREAD_04 | HLR_AIN_16934 | WHEN the target analog input channel is already enabled (channel enable status is TRUE), the modAnalogIn_enableRead() function SHALL abort processing and return MD_OP_ALREADY_PERFORMED. | modAnalogIn.c:modAnalogIn_enableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_ENABLEREAD_05 | HLR_AIN_16934 | WHEN preconditions are satisfied, the modAnalogIn_enableRead() function SHALL invoke routine analogIn_getChannelStatus() to execute target subsystem hardware operation. | modAnalogIn.c:modAnalogIn_enableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_ENABLEREAD_06 | HLR_AIN_16934 | WHEN preconditions are satisfied, the modAnalogIn_enableRead() function SHALL evaluate the driver return status using errCheck(). | modAnalogIn.c:modAnalogIn_enableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_ENABLEREAD_07 | HLR_AIN_16934 | WHEN preconditions are satisfied, the modAnalogIn_enableRead() function SHALL invoke routine analogIn_enableDisableCh() to execute target subsystem hardware operation. | modAnalogIn.c:modAnalogIn_enableRead() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_ENABLEREAD_08 | HLR_AIN_16934 | WHEN all operational processing completes successfully, the modAnalogIn_enableRead() function SHALL return MD_SUCCESS. | modAnalogIn.c:modAnalogIn_enableRead() | Test | Closed |
| ModStatus modAnalogIn_read | ( | const AInChannelNum | channelNum, |
| Float32 * | readVal ) |
modAnalogIn_read.
Read analog input from specific channel.
| [in] | channelNum | Analog input channel to access. |
| [out] | readVal | Analog read value 0V to 5V for 5V channels and 0V to 10V for 10V channels with tolerance of 1E-6. |
| MD_SUCCESS | : Success. |
| MD_INVALID_INIT | : The module has not been initialized. |
| MD_INVALID_PARAM | : The provided address pointer is invalid. |
| MD_INVALID_CHANNEL | : The channel number is invalid. |
| MD_CHANNEL_DISABLED | : Channel is disabled. |
| MD_INVALID_VALUE | : Analog read value is out of range. |
| Requirement ID | Parent HLR ID | Detailed Low-Level Requirement Statement (EARS Format) | Software Unit Reference | Verification Method | Status |
|---|---|---|---|---|---|
| LLR_ANALOGIN_MODANALOGIN_READ_01 | HLR_AIN_21627 | WHEN channelNum is not one of the defined analog input channel identifiers (AIN_5V_CH1, AIN_5V_CH2, AIN_5V_CH3, AIN_5V_CH4, AIN_10V_CH1, AIN_10V_CH2, AIN_10V_CH3, AIN_10V_CH4), the modAnalogIn_read() function SHALL abort processing and return MD_INVALID_CHANNEL. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_02 | HLR_AIN_21627 | WHEN the pointer readVal is NULL (invalid), the modAnalogIn_read() function SHALL abort processing and return MD_INVALID_PARAM. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_03 | HLR_AIN_21627 | WHEN the module initialization state is not initialized (INIT), the modAnalogIn_read() function SHALL abort processing and return MD_INVALID_INIT. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_04 | HLR_AIN_21627 | WHEN the driver status is not equal to DRV_SUCCESS, the modAnalogIn_read() function SHALL abort processing and return the module error code produced by errCheck() for the reported driver status. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_05 | HLR_AIN_21627 | WHEN the target analog input channel is disabled (channel enable status is FALSE), the modAnalogIn_read() function SHALL abort processing and return MD_CHANNEL_DISABLED. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_06 | HLR_AIN_21627 | WHEN MOD_CONFIG_AIN_5V_BANK is equal to the bank identifier, the modAnalogIn_read() function SHALL abort processing and return MD_INVALID_VALUE. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_07 | HLR_AIN_21627 | WHEN the converted analog input voltage reading pointed to by readVal is outside the valid range of 0.0 V (MOD_CONFIG_AIN_0V_RANGE) to 10.0 V (MOD_CONFIG_AIN_10V_RANGE) (less than 0.0 V or greater than 10.0 V), the modAnalogIn_read() function SHALL abort processing and return MD_INVALID_VALUE. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_08 | HLR_AIN_21627 | WHEN preconditions are satisfied, the modAnalogIn_read() function SHALL invoke routine status() to execute target subsystem hardware operation. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_09 | HLR_AIN_21627 | WHEN preconditions are satisfied, the modAnalogIn_read() function SHALL evaluate the driver return status using errCheck(). | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_10 | HLR_AIN_21627 | WHEN preconditions are satisfied, the modAnalogIn_read() function SHALL invoke routine analogIn_getAdcReading() to execute target subsystem hardware operation. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |
| LLR_ANALOGIN_MODANALOGIN_READ_11 | HLR_AIN_21627 | WHEN all operational processing completes successfully, the modAnalogIn_read() function SHALL return MD_SUCCESS. | modAnalogIn.c:modAnalogIn_read() | Test | Closed |