Garbled text in Editor output

As the image shown:

Some of the error meaages in output show grabled text and I have no idea how to solve it.

Need help please.

I moved your topic to an appropriate forum category @mimjy.

In the future, please take some time to pick the forum category that best suits the subject of your topic. There is an "About the _____ category" topic at the top of each category that explains its purpose.

This is an important part of responsible forum usage, as explained in the "How to get the best out of this forum" guide. The guide contains a lot of other useful information. Please read it.

Thanks in advance for your cooperation.

1 Like

Hi @mimjy
It looks like a non-latin character message.
What is your OS? Do you use any languages other than English on your PC?

Are you using, or is any conductive material touching, pin 0 or pin 1 as you compile?

My OS is win10, chinese(Big-5).
And I've tried the it in 2 different computer(sall are in Win10, big-5 system), same result.
I got grabled text while the connection failure.

It looks like a non-latin error message from the Windows driver.
The Arduino IDE can't display it correctly.

Hi @mimjy. The text following the "avrdude: ser_open(): can't open device "\\.\COM4":" error message provides more details about the cause of the error. That information might help us to better understand how to solve the problem.

I don't have any experience with using the AVRDUDE upload tool that produces this message on systems with non-English language locales, but it is possible that the problem with rendering the text is specific to Arduino IDE rather than AVRDUDE itself. If so, we might be able to obtain the text by running the command from a command line terminal.

Please try this:

  1. Select File > Preferences... (or Arduino IDE > Settings... for macOS users) from the Arduino IDE menus.
    The "Preferences" dialog will open.
  2. Uncheck the box next to Show verbose output during: compilation in the "Preferences" dialog.
  3. Check the box next to Show verbose output during: ☐ upload.
  4. Click the "OK" button.
    The "Preferences" dialog will close.
  5. Attempt an upload, as you did before.
  6. Wait for the upload to fail.
  7. Examine the contents of the black "Output" panel at the bottom of the Arduino IDE window. You will see the avrdude command Arduino IDE invoked for the upload. It will look something like this:
    "C:\Users\per\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude" "-CC:\Users\per\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf" -v -V -patmega328p -carduino "-PCOM12" -b115200 -D "-Uflash:w:C:\Users\per\AppData\Local\Temp\arduino\sketches\E9D161D0632667196D2A5B90BB803265/sketch_apr7b.ino.hex:i"
    
  8. Click and drag the mouse pointer over that line to select the entire line.
  9. Press the Ctrl+C keyboard shortcut.
    This will copy the selected text to the clipboard.
  10. Right click the Windows "Start" button.
    A context menu will open.
  11. Select "Search" from the context menu.
    The Windows "Start" menu will open with a search field selected.
  12. Type windows powershell ise in the search field.
  13. Select "Windows PowerShell ISE" from the search results.
    A "Windows PowerShell ISE" window will open.
  14. In the text editor window, Press the Ctrl+V keyboard shortcut.
    This will paste the copied command to the PowerShell command prompt.
  15. Press the Enter key.
    The avrdude command should now run. It is expected to fail as it did when you ran it from Arduino IDE, but hopefully this time the error message will not be corrupted.
  16. Select Edit > Select All from the Windows PowerShell ISE menus.
    All the text in the terminal panel of the window will be selected.
  17. Select Edit > Copy from the Windows PowerShell ISE menus.
    This will copy the selected text to the clipboard.
  18. Open a forum reply here by clicking the "Reply" button.
  19. Click the <CODE/> icon on the post composer toolbar.
    This will add the forum's code block markup (```) to your reply to make sure the error messages are correctly formatted.
    Code block icon on toolbar
  20. Press the Ctrl+V keyboard shortcut.
    This will paste the output into the code block.
  21. Move the cursor outside of the code block markup before you add any additional text to your reply.
  22. Click the "Reply" button to post the output.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.