We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi, I use a MCBSTM32E evaluation board, which is composed of an STM32F103ZET6 MCU, and I loaded the measure example provided by Keil. It works perfectly, but I want to add another variable resistor on PC13 which is the channel 13 of ADC1. The onboard variable resistor is connected to channel 14. Thus I configured the ADC to work with two channels (13 & 14), the DMA to have a buffersize of 2 and created an int ADC_ConvertedValue2 that should contain the second conversion result. I configured the channels like underneath : ADC_RegularChannelConfig(ADC1, ADC_Channel_14, 1, ADC_SampleTime_55Cycles5); ADC_RegularChannelConfig(ADC1, ADC_Channel_13, 2, ADC_SampleTime_55Cycles5);
My result is that each conversion result is store on the same variable (ADC_ConvertedValue) and the second one has nothing. I dont know how to get the value of the second conversion in the EOC interruption routine. Can I still use this interruption and do i have to use a DMA one ? I'm a bit confused about how ADC channels really works and neither the datasheet nor the FWLib helped me. Thanks in advance for any hint. Gary
Thank you. I did not know what was the SWJ, now I do. But I encountered the same problem. I think it is each time the Cortex is in sleep mode (I cannot access memory). I tried my infinite loop without the __WFI() instruction and now I can load my programs easily.
Several processors will drop the JTAG support when sleeping. The sleep turns off clocking to too large sections of the processor, making it inert until it receives an interrupt.