TRGMUX trigger in S32k144

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

TRGMUX trigger in S32k144

跳至解决方案
749 次查看
Sriram
Contributor IV

Hello,

I have some questions about the ADC triggering in S32k144. I am using NXP model based design tool box to build the code. With reference to the S32K1xx ADC guidelines, spec and configuration document (Document Number: AN12217) 

4.4. TRGMUX trigger
For the example code refer to Appendix D.
The TRGMUX is a very flexible module for interconnecting the trigger inputs of peripherals to a wide
variety of internal and/or external trigger signals (timer modules, analog modules flags, external pins). In
particular for ADC  in S32K1xx, the TRGMUX can be used to synchronize conversions with any of the
available trigger signals. It is worth mentioning that the TRGMUX mechanism can be used when triggering
ADC conversions for SC1n registers 0 to 3 [registers SC1A, SC1B, SC1C and SC1D], and this kind of
trigger always goes through the trigger latching gasket.

Does this mean the TRGMUX can be used only for 4 registers ( SC1A to D ) because right now in my model im using 5 registers ( SC1A to SC1E), it seems to work fine. Is there any limitation on using TRGMUX  for 5 registers.

 

Thank you

#S32k144 #MBD

标记 (2)
0 项奖励
回复
1 解答
721 次查看
Senlent
NXP TechSupport
NXP TechSupport

Hi@Sriram

I am not familiar with MBDT. If you have any questions about MBDT, please be sure to create a new topic and add MBDT related keywords.

You can see the difference in the red highlight.
1. Each PDB module has 4 channels, and each channel can support 8 pre-trigger channels, which can realize pre-triggering of a total of 32 channels of the ADC module.

2.PDB module supports ADC_COCO

3. If TRGMUX is used to achieve pre-triggering of the ADC channel, it can only be achieved through the LPIT module, and: LPIT doesn’t support ADC_COCO feedback, it needs software to correctly control the ADC trigger timing setting.

4.Software pre-trigger,SIM_ADCOPT[ADCxSWPRETRG].

Senlent_1-1709791100394.png

The summary is that PDB perfectly supports ADC and is specially designed for the ADC module.

This is what I can explain, for more details you need to read the data sheet yourself

 

 

在原帖中查看解决方案

0 项奖励
回复
3 回复数
725 次查看
Sriram
Contributor IV

Hello @Senlent ,

Thank you for your quick reply. I have attached few pics from the matlab model,

First 2 pics are from the PDB Init dialog box. In adc0 im using 5 channels and they are triggered by trigmux_pdb_trig. All 5 channels seems to be working fine when i trigger it with trigmux 

Sriram_1-1709785777978.png

Sriram_2-1709785833923.png

The pic below is the ADC init dialog box. In the pre trigger source, there are 3 options - PDB , TRGMUX and SOFTWARE . What is the difference between the PDB trigger and TRGMUX

Sriram_0-1709785554151.png

Sriram_3-1709786255118.png

Sriram_4-1709787829156.png

 

Thank u

 

 

0 项奖励
回复
722 次查看
Senlent
NXP TechSupport
NXP TechSupport

Hi@Sriram

I am not familiar with MBDT. If you have any questions about MBDT, please be sure to create a new topic and add MBDT related keywords.

You can see the difference in the red highlight.
1. Each PDB module has 4 channels, and each channel can support 8 pre-trigger channels, which can realize pre-triggering of a total of 32 channels of the ADC module.

2.PDB module supports ADC_COCO

3. If TRGMUX is used to achieve pre-triggering of the ADC channel, it can only be achieved through the LPIT module, and: LPIT doesn’t support ADC_COCO feedback, it needs software to correctly control the ADC trigger timing setting.

4.Software pre-trigger,SIM_ADCOPT[ADCxSWPRETRG].

Senlent_1-1709791100394.png

The summary is that PDB perfectly supports ADC and is specially designed for the ADC module.

This is what I can explain, for more details you need to read the data sheet yourself

 

 

0 项奖励
回复
730 次查看
Senlent
NXP TechSupport
NXP TechSupport

Hi@Sriram

Here, you are setting a software pre-trigger, so there will be no such limitation.

Senlent_0-1709781825824.png

If it is hardware pre-trigger is implemented through TRGMUX, then you can only use LPIT, and only SC1A to D can be used.

 

Senlent_1-1709781849232.png

 

 

0 项奖励
回复