ADC callback routine fires multiple times although continuous conversion is disabled

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

ADC callback routine fires multiple times although continuous conversion is disabled

ソリューションへジャンプ
286件の閲覧回数
DenisT1980
Contributor III

Here is the configuration:

/*! @brief PAL instance information */
const adc_instance_t adc_pal_1_instance = { ADC_INST_TYPE_ADC_S32K1xx, 0u };

/*! @brief PAL extension */
static extension_adc_s32k1xx_t adc_pal_1_extensionConfig = {
.clockDivide = ADC_CLK_DIVIDE_1,
.resolution = ADC_RESOLUTION_12BIT,
.inputClock = ADC_CLK_ALT_1,
.voltageRef = ADC_VOLTAGEREF_VREF,
.supplyMonitoringEnable = false,
.pdbPrescaler = PDB_CLK_PREDIV_BY_1
};

/*! @brief configuration structure */
const adc_config_t adc_pal_1_config = {
.groupConfigArray = adc_pal_1_groupArray,
.numGroups = 2u,
.sampleTicks = 12u,
.extension = &adc_pal_1_extensionConfig
};

/*! @brief array of conversion groups */
const adc_group_config_t adc_pal_1_groupArray[2u] = {
/* Conversion group 0 */
{
.inputChannelArray = adc_pal_1_channelsArray0,
.resultBuffer = adc_pal_1_results0,
.numChannels = 8u,
.numSetsResultBuffer = 1u,
.hwTriggerSupport = false,
.triggerSource = TRGMUX_TRIG_SOURCE_DISABLED,
.delayType = ADC_DELAY_TYPE_NO_DELAY,
.delayArray = NULL,
.continuousConvEn = false,
.callback = SYSTEM_ADC_MODULE1_GROUP1_IRQ_HANDLER,
.callbackUserData = NULL
},
/* Conversion group 1 */
{
.inputChannelArray = adc_pal_1_channelsArray1,
.resultBuffer = adc_pal_1_results1,
.numChannels = 4u,
.numSetsResultBuffer = 1u,
.hwTriggerSupport = false,
.triggerSource = TRGMUX_TRIG_SOURCE_DISABLED,
.delayType = ADC_DELAY_TYPE_NO_DELAY,
.delayArray = NULL,
.continuousConvEn = false,
.callback = SYSTEM_ADC_MODULE1_GROUP2_IRQ_HANDLER,
.callbackUserData = NULL
},
};

/*! @brief group 0: input channels array */
adc_input_chan_t adc_pal_1_channelsArray0[8u] = {
/* 0 */ ADC_INPUTCHAN_EXT2,
/* 1 */ ADC_INPUTCHAN_EXT3,
/* 2 */ ADC_INPUTCHAN_EXT4,
/* 3 */ ADC_INPUTCHAN_EXT5,
/* 4 */ ADC_INPUTCHAN_EXT8,
/* 5 */ ADC_INPUTCHAN_EXT9,
/* 6 */ ADC_INPUTCHAN_EXT10,
/* 7 */ ADC_INPUTCHAN_EXT11,
};
/*! @brief group 0: results buffer */
uint16_t adc_pal_1_results0[8u];

/*! @brief group 1: input channels array */
adc_input_chan_t adc_pal_1_channelsArray1[4u] = {
/* 0 */ ADC_INPUTCHAN_EXT12,
/* 1 */ ADC_INPUTCHAN_EXT13,
/* 2 */ ADC_INPUTCHAN_EXT14,
/* 3 */ ADC_INPUTCHAN_EXT15,
};
/*! @brief group 1: results buffer */
uint16_t adc_pal_1_results1[4u];

 

used SDK 4.0.2 on S32DS 3.4

 

0 件の賞賛
返信
1 解決策
267件の閲覧回数
DenisT1980
Contributor III

Sorry, fault in other place found. Can be closed

元の投稿で解決策を見る

0 件の賞賛
返信
1 返信
268件の閲覧回数
DenisT1980
Contributor III

Sorry, fault in other place found. Can be closed

0 件の賞賛
返信