Design and implementation of network communication based on ARM11 under Linux platform

Publisher:温暖梦想Latest update time:2021-01-11 Source: 21icKeywords:ARM11 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

With the rapid development of CPU manufacturing technology, more and more high-performance, low-power embedded microprocessors are applied to all aspects of our lives. ARM11 adopts ARM's new generation instruction architecture ARMv6, with a maximum frequency of 1GHz, power consumption as low as 0.4mW/MHz, and 8-level pipeline technology. On the other hand, it improves the memory system to make it more suitable for the hardware requirements of the operating system.


Linux is developed on the basis of Unix. It is a secure, stable, free and portable processor platform for various architectures. Linux is divided into multiple modules, and some minor modules can be cut to reduce the program size, so as to better meet the power consumption and cost requirements of the microprocessor.


1 Construction of embedded Linux software development environment


1.1 Brief Introduction to Embedded Linux Development Environment


The development of embedded Linux drivers needs to be carried out under an operating system with Linux as the kernel. To facilitate data transmission and information feedback during development, VMware virtual machine software is installed, and the Ubuntu 10.10 operating system is installed in it. It should be noted that the operating system version cannot be too low, because if the version is too low, many tools cannot find the corresponding support package, resulting in the failure of some software.


Ubuntu is an operating system based on Linux. When you first install Ubuntu, you will be asked to enter a new account and password. This new account will be used as the default login account when Ubuntu is first started. Ubuntu 10.10 supports a graphical user interface, but there are still many functions in Linux that cannot be expressed in the form of a graphical interface.


Therefore, to learn Linux well, you must have a deeper understanding of the Linux command line.


Ubuntu 10.10 will automatically install VMware tools for file transfer between the virtual machine system and the host machine, that is, users can directly drag files from the host machine to the virtual machine. If it is not installed automatically, select Install VMware Tools under VM to install it.


Linux has certain permissions restrictions for ordinary users. For example, when installing some support packages, you must use the root user's permissions to operate. To log in as the root user every time you start Linux, you can enter the hyperterminal at the first login and open the user configuration file in the /etc/gdm directory: custom.conf. That is, you can log in with root permissions every time you log in.


1.2 Cross-compiler


A cross compiler is a compiler that runs in a computer environment and can compile code that can run in another environment. We call this compiler a cross compiler. In this article, we will write code in an ordinary personal computer with CISC X86 architecture, and the compiled program will run in an ARM11 microprocessor with RISC ARMv6 architecture.

1.3 Network File System




NFS is the abbreviation of Network File System. NFS allows a system to share directories and files with others on the network. By using NFS, users and programs can access files on the remote system just like accessing local files. In embedded development, NFS makes it extremely convenient to transfer files between hardware platforms and computers during development.


1.4 Network Programming Experiment


Implement a typical client/server program. The client-server model requires that each application should consist of two parts: one part is responsible for initiating communication, and the other part is responsible for responding to it. They usually run on different hosts, called client and server respectively. A server is any program that can provide services on the network. A client is an application that a user needs to run in order to get a certain service. A server accepts requests from clients on the network and returns the results to the client after completing the service.


2 Construction of Embedded Linux Hardware Platform


2.1 Linux bootloader


Embedded Linux boot program generally uses u-boot, the full name of which is Universal Boot Loader, which is an open source project that complies with the GPL terms. First, set the DIP switch to configure ARM11 to read u-boot from the SD card, and then use the hyperterminal to copy the read u-boot to the NAND Flash on the ARM11 board, and then set the boot mode to configure ARM11 to boot from Flash. At this point, the loading of the embedded Linux boot program on the ARM11 platform is completed.


2.2 Linux Kernel


After completing the loading of u-boot, the kernel file can be directly transferred from the PC to the embedded development platform through the hyperterminal. Usually, the kernel file is transferred to a specific address of nandflash for temporary storage, and then the kernel file is burned to a specific kernel address through the burning command to complete the burning of the embedded Linux kernel.


2.3 Embedded Linux File System


The files in the embedded Linux file system are a collection of data. The file system contains not only the data in the files but also the structure of the file system. All files, directories, soft links and file protection information seen by all Linux users and programs are stored in it. Commonly used file systems are yaffs2 file system and cramfs file system. Yaffs is the first embedded file system designed specifically for Nandflash memory, suitable for large-capacity storage devices, and is released under the GPL agreement. Cramfs file system is a read-only compressed file system designed specifically for NorFlash, using real-time decompression, compact and fast.


3 Conclusion


The flowchart summary of the network communication program based on ARM11 under the Linux platform is shown in Figure 2.

This article describes the current embedded Linux and its network communication, with embedded as the knowledge background. The design mainly consists of six processes (NFS, cross compiler, network programming experiment, Linux boot program, Linux kernel, embedded Linux file system). The writing process of other embedded Linux applications is similar.


Keywords:ARM11 Reference address:Design and implementation of network communication based on ARM11 under Linux platform

Previous article:Comparison of the performance of Cortex-M3 and ARM7TDMI-S cores
Next article:Research and implementation of ARM Cortex-M3 microprocessor test method

Recommended ReadingLatest update time:2024-11-15 15:03

ARM11 learning based on S3C6410 (VII) Core initialization: turning off MMU and CACHE
After disabling all interrupts, we need to disable MMU and CACHE. Because at this time, the environment is still being initialized, and these two things are not needed. So we need to disable them all to avoid affecting our initialization.      MMU is the abbreviation of Memory Management Unit. Its Chinese name is Memo
[Microcontroller]
ARM11 learning based on S3C6410 (VII) Core initialization: turning off MMU and CACHE
Relationship between ARM7, ARM9, ARM11 and ARM-Cortex series
When ARM introduced the ARMv7 core architecture in 2004, it abandoned the previous "ARM+number" processor naming method (processors before ARM11 were collectively called classic processor series), re-enabled the Cortex naming method, and subdivided the Cortex series into three categories: Cortex-A Series: Application
[Microcontroller]
Relationship between ARM7, ARM9, ARM11 and ARM-Cortex series
Latest Microcontroller Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号