PoC_Team / Mbed OS ADMW1001_example_firmware
Embed: (wiki syntax)

« Back to documentation index

ADMW1001_CHANNEL_CONFIG Struct Reference

ADMW1001_CHANNEL_CONFIG Struct Reference
[ADMW1001 Host Library API]

#include <admw1001_config.h>

Data Fields

bool enableChannel
bool disablePublishing
ADMW1001_CH_ID compensationChannel
ADMW1001_LUT_SELECT lutSelect
ADMW1001_MEASUREMENT_UNIT measurementUnit
float32_t lowThreshold
float32_t highThreshold
float32_t offsetAdjustment
float32_t gainAdjustment
float32_t sensorParameter
uint32_t measurementsPerCycle
uint32_t cycleSkipCount
uint32_t extraSettlingTime
ADMW1001_CHANNEL_PRIORITY priority
union {
   ADMW1001_ADC_CHANNEL_CONFIG   adcChannelConfig
   ADMW1001_I2C_CHANNEL_CONFIG   i2cChannelConfig
   ADMW1001_SPI_CHANNEL_CONFIG   spiChannelConfig
}; 

Detailed Description

ADMW1001 Measurement Channel configuration details

Definition at line 755 of file admw1001_config.h.


Field Documentation

union { ... }

Only one of adcChannelConfig, i2cChannelConfig, spiChannelConfig is required, depending on the channel designation (analog, I2C, SPI)

ADC channel configuration - applicable only to ADC channels

Definition at line 836 of file admw1001_config.h.

Optional compensation channel. Set to ADMW1001_CH_ID_NONE if not required. Typically used for thermocouple sensors that require a separate measurement of the "cold-junction" temperature, which can be be provided by an RTD temperature sensor connected on a separate "compensation channel"

Definition at line 767 of file admw1001_config.h.

uint32_t cycleSkipCount

Optional number of cycles to skip, such that this channel is included in the sequence in only one of every (cycleSkipCount + 1) cycles that occur. If set to 0 (default), this channel is included in every cycle; if set to 1, this channel is included in every 2nd cycle; if set to 2, this channel is included in every 3rd cycle, and so on.

Definition at line 813 of file admw1001_config.h.

Option to disable publishing of data samples from this channel. The channel may still be included in measurement cycles, but data samples obtained from this channel will not be published. This is typically used for channels which are required only as a compensation reference for another channel (e.g. Cold-Junction Compensation channels).

Definition at line 760 of file admw1001_config.h.

Option to include this channel in normal measurement cycles

Definition at line 758 of file admw1001_config.h.

A minimum settling time is applied internally for each channel, based on the sensor type. However, additional settling time (microseconds) can optionally be specified. Set to 0 if not required.

Definition at line 820 of file admw1001_config.h.

float32_t gainAdjustment

Optional gain adjustment value applied to each processed sample. Set to NaN or 1.0 if not required.

Definition at line 799 of file admw1001_config.h.

float32_t highThreshold

Optional maximum threshold value for each processed sample, to be checked prior to publishing. A channel ALERT condition is raised if the processed value is higher than this threshold. Set to NaN if not required.

Definition at line 789 of file admw1001_config.h.

I2C channel configuration - applicable only to I2C channels

Definition at line 838 of file admw1001_config.h.

float32_t lowThreshold

Optional minimum threshold value for each processed sample, to be checked prior to publishing. A channel ALERT condition is raised if the processed value is lower than this threshold. Set to NaN if not required.

Definition at line 783 of file admw1001_config.h.

Select Look Up Table LUT for calculations, this implies that the fundamental measurement for the sensor (typically mV or Ohms) 0 = default, 1= unity, 2 = custom

Definition at line 773 of file admw1001_config.h.

The number of measurements to obtain from this channel within each cycle. Each enabled channel is measured in turn, until the number of measurements requested for the channel has been reached. A different number of measurements-per-cycle may be specified for each channel.

Definition at line 807 of file admw1001_config.h.

Optional measurement unit selection for conversion results. Applicable only for certain sensor types. Set to ADMW1001_MEASUREMENT_UNIT_DEFAULT if not applicable.

Definition at line 778 of file admw1001_config.h.

float32_t offsetAdjustment

Optional offset adjustment value applied to each processed sample. Set to NaN or 0.0 if not required.

Definition at line 795 of file admw1001_config.h.

By default, channels are arranged in the measurement sequence based on ascending order of channel ID. However, a priority-level may be specified per channel to force a different ordering of the channels, with higher-priority channels appearing before lower-priority channels. Channels with equal priority are ordered by ascending order of channel ID. Lower numbers indicate higher priority, with 0 being the highest. Set to 0 if not required.

Definition at line 825 of file admw1001_config.h.

float32_t sensorParameter

Optional sensor parameter adjustment. Set to NaN or 0 if not required.

Definition at line 803 of file admw1001_config.h.

SPI channel configuration - applicable only to SPI channels

Definition at line 840 of file admw1001_config.h.