I have the following within an h file:
typedef struct
{
uint8_t Channels[10]; /*values @CHANNELS */
uint32_t Rate; /*sample rate */
uint8_t CycleSeqence; /*values @CYCLE */
uint8_t TriggerSrc; /*values @TRIGGER */
uint8_t TriggerChannel; /*values @CHANNELS */
uint16_t TriggerLevelLow;
uint16_t TriggerLevelHigh;
}ADC_Config_t;
Within main I am trying to do the following but cannot seem to get this to work
ADCTest.ADC_Config.Channels[] = {ADC_CH3, ADC_CH1, ADC_CH2};
Is there a way in a single line to initialize the array without using three separate lines, one for each element (which works by the way)?
I am using C99 compiler
Thanks