Serial.println() not working

I got a new ESP32-S3 board and it seems like I cannot print anyting to the Serial Monitor. The code that I am working with is this:

#include <Arduino.h>

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

void loop () {
  Serial.println("Test");
}

and my platformio.ini file looks like this:

[env:project]
platform = espressif32
board = esp32-s3-devkitc-1
framework = arduino

monitor_speed = 9600
; monitor_dtr = 0
; monitor_rts = 0

build_flags =
    -Wl,--print-memory-usage

I’ve tried using the solution from this topic [SOLVED] ESP32 Serial monitor not working, but that didn’t work
I don’t know if this is relevant, but I was not able to program the board over a USB-C to USB-C cable, only over a USB-C to USB-A one.

I am using PlatformIO Core to program and listen to the board with these commands:

pio run -t upload
pio device monitor

I can provide the output of these commands if needed.
Hopefully I am not missing something super simple, sorry if I am. :sweat_smile:
Thank you for the help!

If your board is using the ESP32-S3’s built-in USB port you need to set

build_flags =
  -DARDUINO_USB_CDC_ON_BOOT=1

That was exactly it. Thanks again @sivar2311 :smile: