ADC on MCU got damage

Chatchai Buekban asked Oct 06,2020
0

Hi everyone, my project using STM32L433ccu6 MCU . ADC value readout freezes 2048 (0x0800), but in my prototype with a component from Digikey or Arrow everything ok. And I try to replace MCU I bought from Digikey to PCBA board, then run on the same code It's work !!!!

 

Who has the same problem?

 

Thanks,

Chatchai B.


  • Your Answer(4)
Upload photo
You can only upload 5 files in total. Each file cannot exceed 2MB. Supports JPG, JPEG, GIF, PNG, BMP
0 / 10000
  • 0

    I'm not expert on using the HAL library for STM. I have used STM32F429, but by writing code from scratch, even the startup script in assembly. From what I have read is that you didn't properly configure the ADC. There are several modes of operation, including continuous and polled. Continuous operation samples the analog pin as soon as the conversion is finished. Polled requires you to start the sampling and conversion sequence manually. In both cases, if I remember correctly, you must clear the result buffer before it overflows. Also, it is necessary to reset some bits in the ADC control registers. I would look it up in the datasheet, but that only describes direct register access. Obviously, since you're using the HAL library, I would suggest you read the documentation on the usage of the ADC.

    Reply
  • 1

    My issue has solved add HAL_ADC_Stop(&hadc1); but still confused why some parts can work some parts not work. *** So, the PCBA has no problem **** :) HAL_ADC_Start(&hadc1); if (HAL_ADC_PollForConversion(&hadc1, 1000) == HAL_OK) { result_adc = (uint16_t) HAL_ADC_GetValue(&hadc1); HAL_ADC_Stop(&hadc1); // add this line } Thanks.

    Reply
  • 1

    Yeah, this could be an issue with a static or ESD sensitive device, it is very possible for the MCU to have possibly gotten broken in some way. It is also possible for a part to simply come from a bad batch or have some other manufacturing error on the Chip vendor's or someone else's part.

    Reply
  • 1

    I haven't had that issue, but it sounds like you have done a good job troubleshooting since you have isolated the problem by swapping the MCU.

    Reply
Browse other questions tagged or ask your own question.
List of Questions
pause
Ranking Name Answers
1 PCBWay Team 9
2 weslley ramos 1
3 Epishko Dmitry 1