STM32 Serial Output Is Empty

Hello, Im looking for help related to getting any output to show in serial output. Im flashing ExpressLRS firmware from there last supported STM32 release (version 3.4). They use DBGLN and my program keeps getting stuck or halted here. Im trying to test tx functionality but im not sure how packets are being sent or what im supposed to be seeing in serial output. Building and uploading are succesful when I use platform io and upload through st link.

Board:

Chip:
https://static6.arrow.com/aropdfconversion/43b9b61144c96d8c542fbf71189a3857782fff4f/204015493684881dm00108832.pdf

Here is a screenshot of me in debug mode halted at DBGLN and the terminal is using minicom but serial output on pio shows nothing as well:


And heres my ini :

[env:DIY_900_TX_STM32_LR1121_via_STLINK]
extends = env_common_stm32, radio_LR1121    
upload_protocol = stlink
platform = ststm32
framework = arduino
board = nucleo_l476rg  
build_flags =
	${env_common_stm32.build_flags}
	${radio_LR1121.build_flags}
	${common_env_data.build_flags_tx}
	-include target/DIY_900_TX_STM32_LR1121.h
	-flto
	-DDEBUG_LOG
board_build.ldscript = variants/stm32_test.ld	# Custom linker script (controls memory layout).
board_build.mcu = stm32l476rgt6 
board_build.f_cpu = 80000000L
#monitor_port = /dev/ttyACM0
upload_speed = 460800
monitor_speed = 460800
build_src_filter = ${env_common_stm32.build_src_filter} -<rx_*.cpp>

and they have a logging.h that defines DEBUG_LOG as DBGLN here:

#if defined(DEBUG_LOG) && !defined(CRITICAL_FLASH)
  #define DBGCR   LOGGING_UART.println()
  #define DBGW(c) LOGGING_UART.write(c)
  #ifndef LOG_USE_PROGMEM
    #define DBG(msg, ...)   debugPrintf(msg, ##__VA_ARGS__)
    #define DBGLN(msg, ...) do { \
      debugPrintf(msg, ##__VA_ARGS__); \
      LOGGING_UART.println(); \
    } while(0)
  #else
    #define DBG(msg, ...)   debugPrintf(PSTR(msg), ##__VA_ARGS__)
    #define DBGLN(msg, ...) { \
      debugPrintf(PSTR(msg), ##__VA_ARGS__); \
      LOGGING_UART.println(); \
    }
  #endif

So when I try anything like DBGLN(“ExpressLRS TX Setup”); it just halts.
So if its building and uploading I think my linker script is fine. The header file I include is for pin layout and macro defines.Overall, Im not sure If its something as simply as i need to restart my board each time I upload or open serial port right after upload Im still learning about mcus. Or if I need to look over the logging.h file.

Any advice would be helpful thanks

Seems like a very project specific issue. There are no problems uploading or compiling stuff, just with the logic of the project. Please use the project appropriate channels like https://github.com/ExpressLRS/ExpressLRS/discussions or https://github.com/ExpressLRS/ExpressLRS/issues or their discord server https://discord.gg/expresslrs. I don’t think it makes sense to have someone who’s unfamilier with the project debug such a complex project. The people who made it will surely have better answers.

Yeah I posted on their discord as well and wanted to see if maybe anything looked wrong within my ini file or anything platform.io related that could cause this. So wanted to give some project specifics

If you want a sanity check that your serial output is in principle working on your Nucleo L476RG, then I suggest creating a new blank project for Nucleo L476RG with framework “Arduino”, that should give you

[env:nucleo_l476rg]
platform = ststm32
framework = arduino
board = nucleo_l476rg

with src/main.cpp code

#include <Arduino.h>

void setup() {
  Serial.begin(9600);
}

void loop() {
  Serial.println("Teeeest");
  delay(1000);
}

“Upload and Monitor” that, at the default 9600 baud.