S32k342: Bctudmabuffer is not updating with data. Hello, I have configured PIT,BCTU , DMA(Ch6) for ADC0 having 10 channel. had checked register value LISTCHR and FIFO1DR, MSR:(Decimal) MSR : 32768, TRGCFG[23] :268477184 MCR: 67305600 FIFO1DR: 781516942 LISTCHR[0] : 2162725 LISTCHR[1] : 65576 LISTCHR[2] : 6 LISTCHR[3] : 327687 LISTCHR[4] : 2147909636 FIFCR: 16777216 FIFOERR: 151060480 FIF0SR: 0 FIFOCNTR: 15 Have configured the DMA ch 6 for autosar MCAL with help of example code using https://community.nxp.com/t5/S32K-Knowledge-Base/Example-S32K312-PIT-BTCU-parallel-ADC-FIFO-DMA-DS3-... query is here i am not getting DMA watermark notification and data on bctudma buffer. what is missing , please guide. Thansk Re: S32k342: Bctudmabuffer is not updating with data. i am using AUTOSAR MCAL . Is transfer config also require to configure. and require to call transfer API .? Mcl_SetDmaChannelTransferList and Mcl_SetDmaCHannelCommand with MCL_DMA_CH_START_REQUEST. Re: S32k342: Bctudmabuffer is not updating with data. Currently i am using path and have shared config for this : PIT_CH0 → TRGMUX → BCTU_Trg23 → ADC0/Adc1 → DMA please let me. Final path which i will use : PIT_CH0 - TRGMUX - BCTU_Trg23 ADC0 (5 channel) - FIFO1 - eDMA PIT_CH1 - TRGMUX - BCTU_Trg47 - ADC1 (5 channel) - FIFO2 - eDMA Please also let me know config for this. Re: S32k342: Bctudmabuffer is not updating with data. I am using RTD 3.0.0 Re: S32k342: Bctudmabuffer is not updating with data. Bctu Config: Adc: DMA: Also Peripheral clock enabled for BCT, PIT, EDMA,DMAMUX_0 Re: S32k342: Bctudmabuffer is not updating with data. Hi,
Thank you for the details.
From the register values alone it is difficult to determine what is missing. Since the ADC conversions appear to be reaching the BCTU FIFO, the issue may be related to the BCTU→DMA request path, DMA channel configuration, or the DMAMUX setup.
Could you please provide either:
a simplified test project reproducing the issue, or
screenshots of your S32 Configuration Tools settings for:
ADC
BCTU
DMA/eDMA
DMAMUX
PIT
Additionally, please let us know RTD version you are using. With the configuration or a simplified project, we can compare it against the working example and identify any missing or incorrect settings much more efficiently.
BR, Petr
Re: S32k342: Bctudmabuffer is not updating with data. Hi,
no transfer config and code coresponding to it is needed. Transfer config is done in driver.
Have you config and init the DMAMUX as well through Rm component? You should have something like this...
with desired channel selected. Then call Rm init in code
#include "CDD_Rm.h"
/* Initialize DMAMUX via HLD RM driver */
Rm_Init(&Rm_Config);
BR, Petr Re: S32k342: Bctudmabuffer is not updating with data. Yes am doing . and also doing Rm_Init Re: S32k342: Bctudmabuffer is not updating with data. All the config i have shared you previously . Adc: using control mode with the calling API Adc_EnableCtuControlMode fro both Adc 0 and 1. is it also require to call Adc_CtuEnableHwTrigger this one i have not called yet.? Re: S32k342: Bctudmabuffer is not updating with data. Hi,
Thank you for the details.
Based on the information provided so far, it is difficult to determine the root cause. The register dump alone is not sufficient to identify whether the issue is in the BCTU, DMA, DMAMUX, or software configuration.
A few additional things to verify:
Is the DMA interrupt enabled and correctly configured?
Are you using ADC BCTU Control Mode or Trigger Mode?
Please note that DMA watermark notifications are available only when using BCTU Control Mode. If you are using Trigger Mode, receiving a DMA watermark notification is not expected.
To help us analyze the issue, could you please share either:
a simplified standalone project reproducing the problem, or
complete screenshots of the relevant S32 Configuration Tools settings (ADC, BCTU, DMA/DMAMUX, PIT) together with related code?
Ideally, a complete simplified project would allow us to review the configuration and compare it against the working reference example more efficiently.
BR, Petr
Re: S32k342: Bctudmabuffer is not updating with data. Hi,
from given screenshots I do not see obvious issue. As you did share project, code used, let me create some to test your indended trigegr scenario.
BR, Petr Re: S32k342: Bctudmabuffer is not updating with data. Please check config. Re: S32k342: Bctudmabuffer is not updating with data. Yes please , as it is difficult to share the code , please create a test project for s32k342 . Thanks. Re: S32k342: Bctudmabuffer is not updating with data. Hi,
finally I did a ADC HLD demo for your intended configuration
Trigger paths: PIT0_CH0 -> TRGMUX -> BCTU Trigger 23 -> ADC0 (5 channels) -> BCTU FIFO1 -> eDMA (ch0) PIT1_CH1 -> TRGMUX -> BCTU Trigger 47 -> ADC1 (5 channels) -> BCTU FIFO2 -> eDMA (ch16) It is posted here: https://community.nxp.com/t5/S32K-Knowledge-Base/Example-FRDM-A-S32K344-PIT-ADC-BTCU-ControlMode-FIFO-DMA-HLD/ta-p/2420432 Hope it helps.
BR, Petr Re: S32k342: Bctudmabuffer is not updating with data. Thank, I will check and confirm. Re: S32k342: Bctudmabuffer is not updating with data. I checked example code but it is not working .
View full article