I. Purpose
Familiar with barebox frame buffer framework, LCD Driver porting and test command writing.
Ii. Main Content
Port the tiny6410-based LCD driver to the barebox in 1.1.
1.2 compile an LCD command to test the LCD driver.
1.3 write the RZ command so that you can download files to the memory through the serial port.
1.4 added support for direct rendering of image data in the memory to the LCD (barebox itself only supports rendering of image files ).
Iii. Development Environment
HOST: win7 32-bit flagship Edition
Virtual Machine: VMware Workstation 7.0
Linux: Ubuntu 12.04
Compiler: arm-linux-gcc-4.5.1-v6-vfp-20101103
Development Board: tiny6410 (256 m NAND Flash, 128 M DDR)
Step 4:
4.1DownloadBareboxLatest Version
Http://www.barebox.org/download/
The downloaded version is barebox-2013.05.0.tar.bz2.
4.2ToBareboxPatch
Store the barebox-1.3.patchfile in the same directory as the barebox-2013.05.0.tar.bz2 file.
Decompress barebox-2013.05.0.tar.bz2
Tar jxf barebox-2013.05.0.tar.bz2
Go to the barebox source code root directory
CD barebox-2013.05.0
Patch
Patch-P1 <../Barebox-1.4.1.patch
4.3Use the configured File
CP tiny6410_defconfig. config
4. 4 compile
Run make to generate the barebox. binfile in the root directory of the source code, burn it to the nand flash of the development board, and start it from NAND Flash.
4.5Test
After the barebox is started, run the LS/dev command to see that the file name of the LCD device is fb0, as shown in the red box in.
Enter RZ-S 2 Characters (here I am referring to the 2nd character segment. If the parameter file is larger, you can configure the command. Then select the barebox_logo.png file and send it to the serial port. After the sending process starts, the download address to the memory is displayed, for example, download ADDR: 1455722456 in the blue box. After sending, the actual size of the file is displayed, for example, receive size in the blue box: 208620 bytes. And file size are two important parameters. The following LCD commands will use them.
Enter the LCD-D-A 1455722456-s 208620/dev/fb0 command, such as the purple box, to display the barebox logo on the LCD, as shown in. -D Indicates draw picture;-A indicates the address of the image in memory;-s indicates the actual size of the image.
Enter LCD-P/dev/fb0 to view the parameters of the LCD driver, for example:
Enter LCD-B xx/dev/fb0 to clear the LCD screen into a certain color. XX indicates the color value, for example:
Effect:
V. Source Code Analysis
All the modified and added source code are in the patch file. If you are interested, you can first download the research.
Download patch files:
Http://files.cnblogs.com/lknlfy/barebox-1.4.1.patch.rar
Logo image download:
Http://files.cnblogs.com/lknlfy/barebox_logo.rar