cancel
Showing results for 
Search instead for 
Did you mean: 

NUCLEO-F401RE UART not showing up on logic analyser via pins

BadEngineer
Associate II

I am using a Nucleo-F401RE and wanted to look at the UART section. Ideally i wanted to see the pins go up and down to see what they are doing. 

I am using huart1 so the transmit is on PA9 and receive is on PA10. I've hooked up the logic analyzer to PA9 and PA10. To ground the logic analyser i am using pin number 7 on the CN6 connector. 

Below is what the logic analyzer is showing. It seems like it is very intermittent. When i am debugging it and get to the stage where it needs to send a signal out, nothing shows up. If i run it continuously i can see the pin fluctuate. 

What am i doing wrong? 

 

BadEngineer_0-1730226871586.png

 

My Code is rather simple.

BadEngineer_1-1730226905349.png

 

BadEngineer_2-1730226937288.png

 

 

 

11 REPLIES 11
Karl Yamashita
Lead III

It looks like a basic transmit. Though you should be using strlen((char*)p_str) instead of hardcoding the number 15 because the string length changes.

If you use the VCP( UART2), do you see your string using something like Putty or Docklight? 

 

Tips and Tricks with TimerCallback https://www.youtube.com/@eebykarl
If you find my solution useful, please click the Accept as Solution so others see the solution.

Hi Karl,

 

So i've taken on board what you have said and i am not transmitting it to huart2 aswell. I can see that hello world is being transmitted onto tera term. 

However the signals from huart1 are still not showing up when running it through debug 

BadEngineer_0-1730230312846.png

My code and tera term communication 

 

BadEngineer_1-1730230356536.png

 

 

Your code shows a comment that UART2 doesn't work. However Tera Term shows that it is working. So it looks like it's an issue with your logic analyzer?

Maybe try a basic blinking LED or GPIO pin at 1 KHz and see if the logic analyzer works picking up that signal? 

Tips and Tricks with TimerCallback https://www.youtube.com/@eebykarl
If you find my solution useful, please click the Accept as Solution so others see the solution.
SofLit
ST Employee

Hello,

Need to fine tune the timings of your logic analyzer (decrease the time scale) an set a trigger on the falling edge

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

I see where the confusion occurs, the reason it says UART2 doesn't work is because i don't get anything though PA2 or PA3 even when running the program at full speed. 

I thought the exact same thing that the logic analyser might be the issue so I actually have 2 logic analysers and they both seem to be giving me the exact same issue. 

Well where are you testing for PA2 and PA3? They don't go to the Arduino connector or Morpho connector.

Edit: I stand corrected, they do go to the Arduino connector so i assume you're testing there with the logic analyzer?

Have you checked to see if the SB63 and SB62 have solder or a resistor?

Tips and Tricks with TimerCallback https://www.youtube.com/@eebykarl
If you find my solution useful, please click the Accept as Solution so others see the solution.

Hi SofLit, 

I wanted to make sure I wasn't going crazy, so I brought out one of my previous projects with the logic analyser. This is a simple I2C communication (using the same nucleo board) communicated with an AHT10 sensor. Below are the readings from my logic analyser (top is SCL and bottom is SDA). You can see that it works fine with I2C protocol 

 

BadEngineer_0-1730235286060.png

 

Hi Karl, 

 

I appreciate you taking the time to help me fix this. 

I turned the board on it's front and saw that SB61 and SB62 both have solder on them and not a resistor. I'm not sure what this means? (They are located at the bottom of the image)

 

BadEngineer_1-1730235586703.png

 

It's only solder on the pads, but not soldered to make a bridge. So that is why if you're testing at the Arduino connector D0 and D1, you're not seeing any data. 

 

KarlYamashita_0-1730236654815.png

 

Tips and Tricks with TimerCallback https://www.youtube.com/@eebykarl
If you find my solution useful, please click the Accept as Solution so others see the solution.