AnsweredAssumed Answered

Timer ISR problem with flash write/read for FRDM-K64F in MCUXpresso

Question asked by Shoaib Shaikh on Nov 9, 2017
Latest reply on Nov 12, 2017 by Jing Pan

Dear All,

 

I am facing some problems with timer interrupt while writing/reading data in flash in the timer ISR. I am able to write and read data in the ISR but the ISR is running at an independent rate, regardless of the value in the CMR (30 to 65530) of the lptmr0. In the ISR I toggle the LED whenever the read value is even.

 

I added the timer interrupt code to the PFlash example of the SDK.

 

I also checked the timer register values while debugging, they don't seem to get initialized as the watch window displays following error messages:

 

Multiple errors reported.

 

1) Unable to create variable object

 

2) Failed to execute MI command:
-data-evaluate-expression LPTMR0->CSR
Error message from debugger back end:
No symbol "LPTMR0" in current context.

 

3) Failed to execute MI command:
-var-create - * LPTMR0->CSR
Error message from debugger back end:
-var-create: unable to create variable object

 

4) Failed to execute MI command:
-var-create - * LPTMR0->CSR
Error message from debugger back end:
-var-create: unable to create variable object

 

The code does go into the timer ISR, as I checked it using breakpoints.

 

When I check the lptmr0 project independently it is running as expected.

 

Any pointers as to where I may be going wrong. I am using FRDM K64F board in MCUXpresso 10.0.0.

 

Thanks,

Attachments

Outcomes