Showing results for 
Search instead for 
Did you mean: 

Getting ADC Garbage reading when OPENAMP is working

Najib Kassab
Associate III

I have to read ADC readings from 4 channels on both ADC1 and ADC2. In production mode, when OPENAMP isn't enabled, everything works as expected; however, when it's enabled, two channels are getting garbage readings. I do not know why or how to fix it.

P.S I am using starter package from ST and I have updated the device tree

ST Employee

Hi @Najib Kassab​ 

could you please precise what mean for you "OPENAMP enabled/disabled" ? Enabled on M4 side ? Compiled with/without ?

Does 'garbage' mean fixed value ? else ?

Maybe just a buffer overwrite (as OPENAMP uses SRAMs buffers) with ADC DMA buffers or sowftware data. Please have a look to your memory map generated by the compiler.

Could be also a stack/heap overflow.


In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Najib Kassab
Associate III

Hi @PatrickF​ , When I enable OPENAMP on the M4 side, I get two out of four channels with a garabe value; there are no fixed values; they are near-zero values.

I tried to increase the stack size, but it was still the same.

I will check the memory map, as you mentioned.