In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
Editor to share with you the embedded Linux development environment to build ping, nfs cases, I hope you will learn something after reading this article, let's discuss it together!
one。 Embedded software level
1) Bootloader- > Boot Loader
The load and boot task of the entire embedded system is completely left to Bootloader, its main task is to read the kernel image from the hard disk to RAM, and then jump to the kernel entrance to start the kernel (operating system)! Generally speaking, the function of Bootloader is to initialize the hardware and boot the operating system.
U-BOOT is one of the most commonly used Bootloader. Download uboot to the nand flash (ROM) of the development board, and you can initially set up the development board through the simulation software Secure CRT. Including the environment variables of the development board, IP and other settings, to download the kernel, load the file system as the basis.
2) Linux kernel
Achieve different hardware and software requirements and configure different system kernels. It is generally modified based on the existing kernel.
Configure kernel-> compile kernel-> install kernel-> clean up kernel process files (make clean)
Configure kernel: make menuconfig ARCH=arm menu interface to select the required drivers and protocol files
Compile kernel: make uImage (kernel name) ARCH=arm CROSS_COMPILE=arm-linux-
Install the kernel: download uImage to 20000fc0 "tftp uImage 20007fc0" through the tftp server based on uboot.
3) File system
To put it simply, the file system is a kind of directory structure. Because the devices of the linux operating system exist in the form of files in the system, the classified management of these files and the interface with the kernel form a certain directory structure, that is, the file system.
Basic process:
a. Set the root file system directory rootfs and internal storage file directories bin, dev, lib, sbin, sys, usr, mnt, etc.
b. Add kernel modules to the file system, and "/ home/S4-Driver/linux-smart210/" in the linux kernel directory
"make modules ARCH=arm CROSS_COMPILE=arm-linux-" kernel compilation
Copy the "make modules--install ARCH=arm INSTALL_MOD_PATH=/home/S5-/rootfs" kernel file to the root file directory
c. Install the cross compiler busybox under the root directory "/... / rootfs" and configure the kernel-> compile the kernel-> install and copy make install
d. Mount the root file system, using nfs mode, real-time online root file system rootfs
SecureCRT-> configure the parameters of the development board through uboot (nfs configuration item)-> download the Linux kernel from the tftp server-> mount the bootm 20007fc0!
two。 Encounter a problem
1. A series of problems in the development board ping
1) Model structure: PC-> wired network card-> router-> directly connected network cable-> development board network port
2) a. Set the virtual machine to bridge mode to ensure that the Linux virtual machine ip can be found in the public network
B. if the PC uses a wired network card, the PC and Linux virtual network adapter will choose Realtak USB (wired network port).
c. Ensure that the ip of Linux virtual machine, PC and development board are in the same network segment.
3) turn off the firewall of Linux virtual machine and PC, so that PC can ping Linux and development board.
Then eliminate the problem of hardware interface, and then you can communicate.
2.nfs mount problem
There are some problems in nfs mounting, such as "Server is not responding" and "unable to mount root". The main reason is that there is a problem with the setting parameters and download address of nfs. For example, if the download address of smart210 is 20007fc0 (not 20008000), nfs uses udp communication protocol by default, and the mount parameters can be searched on the Internet. It is no problem to try more, as long as the nfs server of Linux can be used normally.
After reading this article, I believe you have a certain understanding of "the case of building ping and nfs in embedded Linux development environment". If you want to know more about it, you are welcome to follow the industry information channel. Thank you for reading!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.