4418 development board based on compiling and running Linux-c test program

ITOP4418 development board Linux-c test procedures based on
pre-development board can run a lot of iTOP4418 file system specific functions on a specific file system, you can
use Linux-c program to test the hardware and drivers. And these procedures are easily portable to Android, Qt / E, and a minimum
on the file system.
Special note: Linux-c is a cross-platform program, just follow the method described below to compile, Linux-c can be
run with the program and Android systems, the use of Linux-c program to test the contents of our attention. In essence, we can
understand this, Android is just a large file only to the first helloworld following example, the Linux kernel running on
the two programs "helloworld" + "Android".
Test code "Summary (excluding CD-ROM content) \ 07_iTOP-4418 development board development board iTOP4418 network disk directory information in
Android application development environment software and source code \ 04_linux-C test programs" under.
8.1 compile and run the test program
8.1.1 compiler environment setup
application C programs running on Android, use the compiler is gcc4.4.1. Installation of the compiler reference
chapter.
Shown below to modify environment variables.
<ignore_js_op>  
After modifying, updating the environment variable, as shown below.

<ignore_js_op>  
shown below, enter "arm", and then press the "TAB" key, the display will need later compiler
"Arm-none-linux-gnueabi -gcc-4.4.1".
<ignore_js_op>  
8.1.2 compiler helloworld
program source helloworld.c follows.
<ignore_js_op>  
compiler helloworld, enter the command "none-ARM-Linux-GCC-4.4.1-gnueabi -o helloworld
helloworld.c -static", as shown below, to generate an executable file helloworld.

<ignore_js_op>  
8.1.3 uploaded to the development board helloworld
executable files copied to fastboot programming helloworld directory, as shown below, this directory is to program
the directory where fastboot tool. The method of using the tool reference fastboot Section 3.6.
<ignore_js_op>  
After stable Android system development board, the USB OTG interface connected to the computer, to open the "fastboot"
directory "cmd.exe", as shown in FIG.
<ignore_js_op>  
started after complete development board, you will be prompted on-screen connection OTG interface, the development board "whether to allow debugging", select the
"Allow" button.
Then enter "chmod 777 / data" command in the serial console to modify data directory permissions, as shown below.
<ignore_js_op> 
Below, in the PC input "cmd.exe" command "adb push helloworld / data", the program will upload
to the development board "/ data" directory. If you do not turn on "Allow USB debugging", it will prompt the following information.

<ignore_js_op>  
after turning "USB debugging run", as shown below, using the command "adb push helloworld / data".
<ignore_js_op>  
also be implemented by mobile assistant, TF card or U disk to upload executable file helloworld. If the prompt command
is not available Note: Please refer to the manual section 10.2.2, update the adb.
8.1.4 permissions and modify the program running helloworld
shown below, in HyperTerminal, type "cd / data" enter "/ data" directory, using "the chmod 777
helloworld" command to modify the permissions, and finally enter "./helloworld" command run the program. Super Terminal will print out
"Hello world!", Indicating that the program runs successfully.

<ignore_js_op>  
iTOP4418 development board already supports Android 7.1 system

Guess you like

Origin www.cnblogs.com/liyue3/p/11981989.html