Mastering Strings and Encoding in Python

Previously, we learned about Python data types and variables, and we also mentioned strings. Next, let’s explore more knowledge about strings and encoding. Strings Strings are a commonly used data type in Python, and they can be created using single or double quotes. To create a string, simply assign a value to a variable. For … Read more

Displaying Unicode Text Using Arduino

Displaying Unicode Text Using Arduino

【Click the above「Blue Text」 to follow DF Maker Community and become a tech aesthetician together】 This week’s project is about how to use Arduino to display Unicode text.(Video demonstration at the end) Development Board Any Arduino development board that supports Arduino_GFX. Reference: https://github.com/moononournation/Arduino_GFX Step 1: Unicode and UTF-8 Unicode defines over 144k characters, covering 159 … Read more

Key Considerations for Encoding and Decoding Chinese Strings in C++ on Windows

Key Considerations for Encoding and Decoding Chinese Strings in C++ on Windows

When using C++ for encoding and decoding Chinese strings in a Windows environment, special attention must be paid to encoding standards, system API characteristics, and cross-scenario compatibility issues. Below is a detailed summary of key considerations: 1. Clarify Encoding Types and System Default Behavior The Windows system supports Chinese primarily through three core encodings: GBK/GB2312: … Read more

Important Considerations for Displaying Strings in LVGL V8.2 on Keil MDK (Example with Xiong Pai)

Important Considerations for Displaying Strings in LVGL V8.2 on Keil MDK (Example with Xiong Pai)

Click on the above “Embedded Application Research Institute” and select “Top/Star Public Account“ Useful Benefits Delivered First-Hand! Source | Embedded Application Research Institute Compiled & Styled | Embedded Application Research Institute Previously, I wrote a multilingual demo on the LVGL simulator CodeBlock to learn about the application of LVGL in multiple languages, as shown below: … Read more

C++ Small String, Big Trouble

C++ Small String, Big Trouble

1 Introduction Many years ago, we had a library that caused garbled text when users input Chinese characters. As a result, we modified it internally to use UTF-8 encoding throughout. The interface still used the std::string type as a carrier for UTF-8 strings because std::u8string did not exist at that time. For many years, everything … Read more