cancel
Showing results for 
Search instead for 
Did you mean: 

Conflict from UART and STLINK

SGian.1
Senior

Hi there!

i start to work at one project with STM32G031J. Soo my i have this problem one of the pin is use for reset when i download the program at the same time is configurate a single wire half duplex , and 

- i can't simulate

- and it's look like every time i send out data they reset the CPU

Some one can help me

Thank you

SergioImmagine 2024-08-20 200549.png 

1 ACCEPTED SOLUTION

Accepted Solutions
BarryWhit
Lead II

Interesting issue. From the datasheet:

BarryWhit_0-1724192075980.png

possibly being the most opaque and least helpful footnote imaginable. "Particular care", wtf does that mean? (sigh middle-school typos in technical writing from multi-billion $$$ multi-national. can't they afford a spell-checker?)

As DeLorean foretold, the RM documents the option bytes:

nRST.jpg

So it's not enough to assign an AF to the pin in CubeMX, you also have to set the option byte to incapacitate the nRST logic.

- If someone's post helped resolve your issue, please thank them by clicking "Accept as Solution".
- Please post an update with details once you've solved your issue. Your experience may help others.

View solution in original post

4 REPLIES 4

Then you're going to have to make some hard choices..

Test/Debug with a different variant of the part with more pins and dead-bug that into the circuit. 

Learn to write code where you don't have to single step it all the time to understand how it executes.

Use serial output to provide telemetry and dynamic analysis of function and flow.

Perhaps you can use a NUCLEO board as a proxy until you have 95% functionality so you aren't fighting the low pin count issue beginning to end.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
BarryWhit
Lead II

Try harder to explain your question clearly. 

- If someone's post helped resolve your issue, please thank them by clicking "Accept as Solution".
- Please post an update with details once you've solved your issue. Your experience may help others.

I suppose there's a way to change to utilization of the NRST (Pin 4), either on-the-fly, or via the Option Bytes. Cube might not do it for you, but probably coved in the Reference Manual, etc

stm32g031jx_so8n.jpg

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
BarryWhit
Lead II

Interesting issue. From the datasheet:

BarryWhit_0-1724192075980.png

possibly being the most opaque and least helpful footnote imaginable. "Particular care", wtf does that mean? (sigh middle-school typos in technical writing from multi-billion $$$ multi-national. can't they afford a spell-checker?)

As DeLorean foretold, the RM documents the option bytes:

nRST.jpg

So it's not enough to assign an AF to the pin in CubeMX, you also have to set the option byte to incapacitate the nRST logic.

- If someone's post helped resolve your issue, please thank them by clicking "Accept as Solution".
- Please post an update with details once you've solved your issue. Your experience may help others.