Differences and Connections Between C and C++

Differences and Connections Between C and C++

Click the "Xiaobai Learns Vision" above, select "Star" or "Top" Heavyweight content delivered promptly Introduction Do you fully understand the connections and differences between C and C++? After reading this article, you may gain some new insights. Reprinted from丨C Language and CPP Programming What is the relationship between C and C++? First of all, C++ … Read more

How to Achieve Byte Endian Conversion in Embedded Programming?

How to Achieve Byte Endian Conversion in Embedded Programming?

Recently, I encountered a problem with byte endian conversion in a protocol, so I lazily went online to check it out and came across a similar issue, learning a new term called butterfly swapping. The Problem Is As Follows The protocol requires that the low byte is on the left and the high byte is … Read more

Practical Tips for Microcontroller Development (Part 1)

Practical Tips for Microcontroller Development (Part 1)

1. Embedding Assembly Language in C In microcontroller development, we usually write the main program in C language, which allows us to fully utilize the mathematical libraries and powerful data processing capabilities provided by C language tools. However, the controllability of C language is not as good as that of assembly language. For some time-sensitive … Read more

14 Common C Language Algorithms for Microcontrollers

14 Common C Language Algorithms for Microcontrollers

Word Count: 9700 Practical Value: ⭐⭐⭐⭐⭐ Simple Algorithms for Counting, Summation, and Factorial These types of problems require the use of loops. It is important to determine the initial value, terminal value, or termination condition of the loop based on the problem. Additionally, pay attention to the initial values of the variables used to represent … Read more

Learn to Write Structs in Microcontroller Programming from Scratch

Learn to Write Structs in Microcontroller Programming from Scratch

Abstract: I heard that many friends learning microcontrollers can’t use structs? Pointers and structs are essential to mastering microcontrollers. If your C language skills are shaky, you won’t grasp the essence of microcontrollers and will only complete some basic projects. Understanding structs and being able to use them flexibly indicates that you have entered the … Read more

How to Compile C Programs in Linux

How to Compile C Programs in Linux

Article Word Count: 1400 Practical Index: ⭐⭐⭐⭐⭐ Common IDEs for compiling on Windows, while using gcc directly for compilation in Linux, is the foundation of Linux embedded programming and also a frequently asked question in embedded interviews. Command Line Compilation and Detailed Compilation Process Example code for hello.c: #include <stdio.h> int main(void) { printf("Hello world\n"); … Read more

How to Write Embedded Linux Device Drivers

How to Write Embedded Linux Device Drivers

Word Count:4500 Content Index:⭐⭐⭐⭐⭐ Concept of Linux Device Driver System calls are the interface between the operating system kernel and application programs, while device drivers serve as the interface between the operating system kernel and machine hardware. Device drivers abstract hardware details from application programs, allowing them to interact with hardware devices as if they … Read more

Understanding Serial Port Configuration in Embedded Development

Understanding Serial Port Configuration in Embedded Development

The serial port is a commonly used interface in computers, with the most common being the RS-232-C interface. It was established in 1970 by the Electronic Industries Alliance (EIA) in collaboration with Bell Systems, modem manufacturers, and computer terminal manufacturers as a standard for serial communication. Its full name is “serial binary data exchange interface … Read more

Understanding Pointers in Microcontrollers

Understanding Pointers in Microcontrollers

Word Count: 6000 Content Quality Index: ⭐⭐⭐⭐⭐ Abstract: Have you ever wondered where the functions and variables you write in Keil for microcontrollers end up? We often talk about the five areas of memory, but what exactly are those five areas? Where are they located on the chip? And why is it that after learning … Read more

Step-by-Step Guide to STM32 GPIO

Step-by-Step Guide to STM32 GPIO

GPIO, translated as General Purpose Input Output. I believe everyone is quite clear about the meaning of input and output. The most commonly used output function is the LED, while the most commonly used input function is the key. To use the GPIO functionality of STM32, the first thing to clarify is who controls this … Read more