2392083_en-US

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

2392083_en-US

2392083_en-US

MIMXRT1186 :first LPIT trigger fails to enter ADC interrupt.
I am working with the FRDM MIMXRT1186 EVK board ,SDK V26.03. I flashed the LPIT ADC demo project to learn the peripheral triggered ADC conversions. However, I changed the LPIT trigger frequency—specifically by modifying the macro definition LPIT_PERIOD in the app.h to 50, which yields a 20 kHz trigger rate—I met a problem: the first LPIT trigger fails to enter ADC interrupt.
To find whether the root cause lies with the LPIT or the ADC peripheral, I performed two tests:
  1. Swapped the initialization sequence of the ADC and LPIT modules (initializing the ADC first, followed by the LPIT);
  2. Added a GPIO toggle operation inside the ADC1_IRQHandler function, and routed the LPIT trigger signal to an external pin via XBAR (kXBAR1_OutputIomuxXbarInout19). then captured waveforms on pins.
The oscilloscope measurements confirmed that the LPIT trigger signal is being generated correctly, yet the ADC does not respond by entering its interrupt service routine.
I cannot figure out why raising the trigger frequency introduces this problem. Could anyone provide some troubleshooting insight? Many thanks in advance. The test code is attached for reference.
Re: MIMXRT1186 :first LPIT trigger fails to enter ADC interrupt.

Hi @ChandlerY,

Thanks for sharing the code.

I am currently performing some tests with it and will get back to you with my findings.

Best Regards,
Pablo

Re: MIMXRT1186 :first LPIT trigger fails to enter ADC interrupt.

Hi @ChandlerY,

The extra delay seen only on the first interrupt is caused by the CM33 vector table and ISR code being located in non-TCM memory (XSPI flash / OCRAM accessed via cache).

Could you help me test whether the behavior continues after placing all CM33 code (vector table and ISRs) into TCM?

Best Regards,
Pablo

Re: MIMXRT1186 :first LPIT trigger fails to enter ADC interrupt.

Hi,Pablo,

    Thanks for your reply, I had tested, it works when cm33 code run in TCM, the first LPIT trigger and enter ADC interrupt. But how to solve this problem when cm33 code run in flash, could you please provide some workaround? Many thanks to you. 

Re: MIMXRT1186 :first LPIT trigger fails to enter ADC interrupt.

Hi @ChandlerY,

Since this behavior is not related to the peripherals, but rather to where the code is being located, one option would be to run the application in non-XIP mode, meaning that the image is stored in Flash while the code executes from RAM.

You can find the steps to configure this through Secure Provisioning Tool in the following link:

Processor-specific workflows — Secure Provisioning Tool 26.06

Best Regards,
Pablo

Tags (1)
No ratings
Version history
Last update:
2 weeks ago
Updated by: