S32K146 Adc Channel configurations array with hw trigger

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

S32K146 Adc Channel configurations array with hw trigger

649 Views
Micha4566465
Contributor II

Hello,

I create an ADC channel configurations array with PDB trigger-hardware.

But I get only an interrupt for (ControlChanIdx == 0).

I configured the system completely in RTD as you can see in the pictures.

Can you help me why there is no interrupt for (ControlChanIdx == 1)?

 

My source code:

// Interrupt routine

void AdcConversionCompleteNotif(const uint8 ControlChanIdx)

{

data = Adc_Ip_GetConvData(ADCHWUNIT_0_INSTANCE, ControlChanIdx);

}

 

int main(void)

{

Adc_Ip_StatusType adcStatus;

Adc_Ip_Init(ADCHWUNIT_0_INSTANCE, &AdcHwUnit_0);

 

adcStatus = Adc_Ip_DoCalibration(ADCHWUNIT_0_INSTANCE);

while (adcStatus != ADC_IP_STATUS_SUCCESS)

{

adcStatus = Adc_Ip_DoCalibration(ADCHWUNIT_0_INSTANCE);

}

 

Pdb_Adc_Ip_Init(PDBHWUNIT_0_INSTANCE, &PdbHwUnit_0);

Pdb_Adc_Ip_SwTrigger(PDBHWUNIT_0_INSTANCE);

 

while (1);

}

0 Kudos
Reply
1 Reply

612 Views
Senlent
NXP TechSupport
NXP TechSupport

Hi@Micha4566465

This problem seems to be caused by setting the delay time of the two trigger channels to be the same.

You can try setting different delay parameters for the two pre-trigger channels.

Senlent_0-1744703480586.png

 

0 Kudos
Reply