Schindler to debug applications for iTOP-4412 Development Board on an NFS basis

Source: Internet
Author: User

This article explains how to debug our applications with the NFS network file system, where we use the Linux qt system as

Cases.

When we debug the application on the qt system, we first build the executable binaries on the virtual machine Ubuntu by cross-compiling,

Then copy the generated binaries to the file system, then regenerate the system.imgwith the command, then burn the system.img to

Development Board, and then launch the board to run our program, or to download the executable file to the Development Board via TFTP.

Both of these methods are cumbersome to operate, so let's talk about using the NFS Debugger.

First of all, my NFS mount Directory is "/home/broswer/nfs/root" (How to build NFS, you can refer to our iTOP-4412

Implementation of the NFS Network File System . PDF).

Then we use the helloword program as an example to achieve, my helloword.c saved in the "/home/brower/test directory", In Virtual

The terminal of the machine uses the "VI helloworld.c" command to open the helloword.c, as shown in :

We can see the helloword.c inside a print statement, output "Int_hello world! ".

Next, the virtual machine's terminal uses the command "arm-none-linux-gnueabi-gcc-o HelloWorld helloworld.c-static" to compile

HELLOWORD.C, generate the executable file helloword, as shown in:

When the compilation is complete, Hellowordis generated, as shown in:


Next we launch the Development Board and enter the Linux qt(mounted NFS System) system, the serial port printing information as shown:


We can see the information of NFS mounted through the image above .

Next we enter the "LS" command in the serial port, you can view the file under the root file system, as shown in:


We then enter the command "CP helloworld/home/broswer/nfs/root/" on the terminal of the virtual machineand copy the generated execution text

"Helloword" to the Network File system directory (My network file system here is "/home/broswer/nfs/root/", everyone

Need to be modified according to your network File system directory) as shown in:


Then in the serial port input "ls", we can see the board file system has "helloword" file, as shown:

Next, in the serial port input "./helloword" command Run "helloword", run the result as shown:


We can see the serial print " Int_hello world! "up.

With the above steps, we can use the easy-to-NFS debugging program.

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

WebEx to debug an application for ITOP-4412 Development Board NFS

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.