Skip to main content
Gary Anson
Associate
June 9, 2017
Question

Has anyone had an issue with the port PD2 on the STM8S changing configuration during debug?

  • June 9, 2017
  • 0 replies
  • 1308 views
Posted on June 09, 2017 at 19:05

Has

The port PD2 on the STM8S goes from being an analog input to a digital output when a break is hit during debug.

I have an analog signal being fed into the port PD2, pin 19 on STM8S103F3 and all seems to work fine during normal operation. When I run the debugger via IAR Embedded Workshop and hit a breakpoint or tell the debugger to break the pin suddenly slams up to the 3.3 volts supply level. After resuming the ADC counts are very high (712 or so) and this is an unexpected behavior, to say the least. This behavior causes my software to make erroneous decisions on invalid data - bummer.

Has anyone else had a similar problem and found a way to solve it? 

BTW. I have very similar analog circuits connected to PD3 & PD5 with no abnormal behavior.

Thanks in advance for any assistance you all can give.

#stm8-debug-problem #stm8s103f3 #iar-embedded-workshop
This topic has been closed for replies.