Hi.
It is being developed at S32DS Design studio, and MPC5746C MCU chip is used. I am using FreeRTOS component and ADC component together. The problem is that it stops at IVOR1_Handler in the process of ADC_Init() function processing. I don't know why for this problem. I am attaching the source code, so please answer the question.
For reference, the symbol "USING_OS_FREERTOS" is defined as shown in the figure below.
Please give me a quick reply.
Thank you to everyone.
Solved! Go to Solution.
Hi Dukyu,
sorry for delayed response.
I have only MPC5748G here today, so I tried to load your project to this board. I didn't re-compiled the project, I used your elf file directly to be sure it's exactly the same. I can see that the ADC Init function is successfully executed and then it continues the execution, I can see no exceptions.
I can try it directly on MPC5746C on Monday to see if there's a difference.
Regards,
Lukas
Hi Dukyu,
It seems you uploaded wrong project, I can’t see ADC there.
But common mistake is: if a function/driver uses OS services, it's mandatory to call them after starting the scheduler. Maybe this is the reason.
I can remember this discussion which could be helpful:
Regards,
Lukas
Dear Lukas,
First of all, thanks for the quick reply. The source code is attached again. According to your answer, do I need to initialize the ADC in the function registered in the scheduler? Even if I initialize the ADC in the task, the same symptom was present. Please give me a more detailed answer.
Can you please check whether ADC group setting and code writing in the attached source code are correct?
Thank for Lukas.
I tested it on MPC5746C now and it also works. Where does it fail exactly in the project? Which instruction?
Regards,
Lukas
Hi Dukyu,
sorry for delayed response.
I have only MPC5748G here today, so I tried to load your project to this board. I didn't re-compiled the project, I used your elf file directly to be sure it's exactly the same. I can see that the ADC Init function is successfully executed and then it continues the execution, I can see no exceptions.
I can try it directly on MPC5746C on Monday to see if there's a difference.
Regards,
Lukas