My serial monitor is not working properly

I used dht11 to connect the esp32dev module. When I opened the serial port monitor, I found incorrect output.


After trying, I found that the output of the serial port monitor opened in the terminal was normal when I entered pio device monitor -e esp32dev command normally.

PS D:\DATA\PlatformIOProjects\ESP32_PlatformIO_Clion_Demo1> pio device monitor -e esp32dev                            
--- Terminal on COM6 | 115200 8-N-1
--- Available filters and text transformations: colorize, debug, default, direct, esp32_exception_decoder, hexlify, log2file, nocontrol, printable, send_on_enter, time
--- More details at https://bit.ly/pio-monitor-filters
--- Quit: Ctrl+C | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H
Humidity: 52.00%  Temperature: 24.60°C 76.28°F  Heat index: 24.47°C 76.05!!!!!!!!!!!!@#$%^&*()_+{}:<>?°C
Humidity: 52.00%  Temperature: 24.60°C 76.28°F  Heat index: 24.47°C 76.05!!!!!!!!!!!!@#$%^&*()_+{}:<>?°C
Humidity: 52.00%  Temperature: 24.60°C 76.28°F  Heat index: 24.47°C 76.05!!!!!!!!!!!!@#$%^&*()_+{}:<>?°C
Humidity: 52.00%  Temperature: 24.60°C 76.28°F  Heat index: 24.47°C 76.05!!!!!!!!!!!!@#$%^&*()_+{}:<>?°C

The display content of the first picture is the display content of the serial port monitor that pops up when I click the platformio plug-in, and the display content of the code segment is the display content of the command that I input in the terminal

As you can see, the ° in the first picture is not displayed correctly, it is displayed as a

Does anybody got an idea how to fix it?

Seems like CLion has a text encoding issue then in their terminal and the ° is being misinterpreted as a UTF32 codepoint of some sort. Do you have any options to change terminal encoding in the CLion settings?

I tried, but I couldn’t find a way to change the coding of the terminal, and this picture show what I encountered.