Should embedded engineers learn ARM assembly instructions at all?
Search the Internet for this question, the answer is a lot, most of the advice is not to learn assembly, just learn C.
As a driver engineer with more than ten years of experience, Ejun personally believes that assembly language is still needed to master, and assembly and computer system knowledge is a must in order to master and deepen.
Let’s list some of the problems
-
How does the system start?
-
How are linked C functions called, and how are arguments passed?
-
How can I turn off interrupts?
-
How do multicore processors assign processes to a particular core to run on?
-
How is MMU implemented?
-
How does the CPU handle the interrupt after it occurs?
-
How is the system call implemented?
To understand these problems, we must understand assembly code and arm architecture. System startup, power-on code is assembly, assembly does not master, how do you know how the system is started? Want to understand the essence of the pointer, the essence of the function name, it is necessary to go deep into the assembly level code, through disassembly, see how the underlying instructions on the ADVANCED features of C language processing, which need the assembly language foundation.
Mastering assembly is a necessary skill to become a low-level system engineer and NB engineer
In addition, the assembly is not so horrible, that is, a dozen commonly used commands, coupled with supporting pseudo-instructions, basic program structure, half a day is about the same. Rather than spend half the day here debating whether to learn, learn quickly.
Of course, before learning assembly, you also need to have an understanding of CPU processor architecture, registers, you know, assembly programs are dealing with these registers. If you learn ARM assembly, you need to master the basic architecture of ARM processor and register configuration in different modes.
Eventually you will find, where do you study assembly? It’s obviously ARM!
Assembly, just a language tool, some mnemonic just.
“What we want to learn is actually ARM.”
ARM Article Plan
In order to make everyone learn ARM better and faster, Eqijun gradually decomposed the knowledge points of ARM according to its years of research and development and teaching experience, explained them in a certain order, and finally decomposed them into more than ten articles.
Eqijun has combed out the overwhelming information on the Internet in detail, and the content setting can be said to be a wet nurse’s explanation. We only need to learn step by step according to my article to be able to master ARM assembly, and really learn ARM assembly from 0.
The article
Whether or not complete
What is Cortex, ARMv8, ARM architecture, ARM instruction set, SOC? This article will help you sort out the basic concepts.
The published
1. Learn ARM from 0 – Install Keil MDK uVision integrated development environment
The published
2. Learn arm-CPU principle from 0, and explain SOC based on ARM
The published
3. Learn ARM-ARM mode, register and pipeline from 0
In the review
4. Learn ARM-ARM instruction, shift, data processing, BL, machine code from 0
In the review
5. Learn arm-MRS, MSR, addressing operation and atomic operation principle from 0
In the review
6. Learn ARM- Exception, Abnormal Direction scale and SWI from 0
In the review
7. Learn ARM-GNU pseudo-instruction from 0
In the review
8. Learn ARM- Mixed assembly from 0
In the review
9. Learn arm-GPIO and LED driver writing methods from 0
In the review
10. From 0 to learn ARM- based on Exynos4412 PWM detailed solution
In the review
11. Learn ARM from 0 – based on Exynos4412 interrupt details and key naked computer program writing
In the review
12. ARM UART based naked machine driver details
The published
13. Learn arm-ExyNOS4412-RTC naked computer programming from 0
In the review
14. Learn ARM- ExyNOs4412 – Watchdog naked computer programming from 0
In the review
15. Learn ARM- position independent code from 0
TBD
16. Understand ADC naked and Linux-based driver writing methods
The published
17.I2C timing detail, based on ARM Cortex-A9 I2C peripheral bare machine driver writing method
The published
18.SPI protocol, SPI to CAN, MCP2515 naked machine driver details
The published
19. Uboot code startup analysis
TBD
Some articles have been published, some are still under review, and some are still under intense preparation. This article is constantly updated.
You want to learn ARM, please pay attention to [a Linux], the subsequent article will be slowly presented for you.