cancel
Showing results for 
Search instead for 
Did you mean: 

When flashing firmware, the characters are garbled

totoro
Associate II

Hi, thank you for having access to this report.

Here is STM32CubeProgrammer's output text.

(0) > STM32_Programmer_CLI --connect port=swd -w .\board\art-pi\projects\applications\build\Debug\applications.elf 0x90000000 -v -el .\board\art-pi\ExternalLoader\ART-Pi_W25Q64.stldr ------------------------------------------------------------------- STM32CubeProgrammer v2.17.0 ------------------------------------------------------------------- ST-LINK SN : 066BFF554957886687101038 ST-LINK FW : V2J42M27 Board : -- Voltage : 3.27V SWD freq : 4000 KHz Connect mode: Normal Reset mode : Software reset Device ID : 0x450 Revision ID : Rev V Device name : STM32H7xx Flash size : 128 KBytes Device type : MCU Device CPU : Cortex-M7 BL Version : 0x91 Warning: Write address is ignored for hex, Srec, s19 and elf files Memory Programming ... Opening and parsing file: applications.elf File : applications.elf Size : 996.35 KB Address : 0x90000000 Erasing memory corresponding to segment 0: Erasing external memory sectors [0 249] Download in Progress: ��������������������������������������������������� 100% File download complete Time elapsed during download operation: 00:00:11.568 Verifying ... Read progress: ��������������������������������������������������� 100% Download verified successfully
View more

This works fine, but he doesn't feel very well.

And I tried to use utf-8 encoding format, but it's still garbled.

 

11 REPLIES 11

Hi,Aziz

I've seen a lot Chinese users met that garbled character problem in other forums. Cause Vscode terminal is UTF8 by default and encoding 850 or 437 is rarely used in Asia. I change my local STM32VSCODE extension file, adding chcp 437 &&(or chcp 850 &&) right before STM32CubeProgrammerCLI command in "flash" task template, and that just fix mine. To get a better performance in more computers, is it feasible to add that "chcp 437" or "chcp 850" to extension's source code?

Thanks in advance!

This has nothing to do with VSCODE, the problem is on Windows Terminal. As mentioned earlier, I changed the code page to 850 before using the STM32ProgrammerCLI. Today I tried to active code page to 437, but the result is still the same.