Hi,I use demo project in
nRF5_SDK_12.1.0_0d23e2a\examples\peripheral\saadc\pca10040\blank\arm5_no_packs\saadc_pca10040.uvprojx.
I made the following changes: 1.add one saadc input 2.channel 0 is connected to VDD,and channel 1 is connected to GND Specific details please check my code:main.c
But, I found a problem, when keil5 simulation, I set a breakpoint in the saadc_callback function, then the results before and after the breakpoint trigger is not the same.
before
after
As you can see,the correct result is
m_buffer_pool[0][ channel 0 , channel 1](m_buffer_pool[1][channel 0 ,channel 1]). But,after the breakpoint trigger,the result is m_buffer_pool[0][ channel 1, channel 0].
If I don't set breakpoints in the saadc_callback function,the reslut is always m_buffer_pool[0][ channel 0 , channel 1](m_buffer_pool[1][channel 0 ,channel 1]).
So, this problem is caused by a breakpoint?Can I get the right answer ? thanks。