0.前言
本章主要介紹關(guān)于100ASK_V853-PRO開發(fā)板的Tina SDK包的下載和編譯打包生成鏡像,并將鏡像燒錄到100ASK_V853-PRO開發(fā)板上。在進(jìn)行100ASK_V853-PRO開發(fā)板的環(huán)境配置前需要獲取配置虛擬機(jī)系統(tǒng),可以參考:https://dongshanpi.com/DongshanPI-D1s/06-ConfigHostEnv/#_3。
全志Linux Tina-SDK開發(fā)完全手冊:https://tina.100ask.net/
100ASK_V853-PRO開發(fā)板資料合集(包含2000+頁 開發(fā)文檔和Tina SDK包等):
鏈接:https://pan.baidu.com/s/1TX742vfEde9bMLd9IrwwqA?pwd=sp6a 提取碼:sp6a
100ASK_V853-PRO開發(fā)板資料匯總:
鏈接:100ASK_100ASK-PRO 資料匯總 - Allwinner / V853-Pro - 嵌入式開發(fā)問答社區(qū)
100ASK_V853-PRO開發(fā)板購買鏈接:100ASK_V853-PRO開發(fā)板
1.下載Tina SDK包
由于Tina SDK包的大小較大,我們將其分卷壓縮并放在在了百度網(wǎng)盤中 ,鏈接:https://pan.baidu.com/s/1TX742vfEde9bMLd9IrwwqA?pwd=sp6a 提取碼:sp6a
SDK包位于07_Tina_SDK包目錄下,將該目錄下的全部文件下載并拷貝到虛擬機(jī)下,如下所示
在此目錄下打開終端,輸入cat tina-v853-open.tar.gz* | tar xz,合并壓縮包并解壓壓縮包。
book@100ask:~/workspaces
$ cat
tina-v853-open.tar.gz* | tar xz
該過程時(shí)間可能會(huì)比較長,需要耐心等待。
解壓完成后會(huì)在當(dāng)前目錄下生成一個(gè)tina-v853-open的文件夾,該文件夾即為Tina SDK包的全部目錄。
book@100ask:~/workspaces
$ ls
tina-v853-open tina-v853-open.tar.gz.01 tina-v853-open.tar.gz.03 tina-v853-open.tar.gz.05 tina-v853-open.tar.gz.07 tina-v853-open.tar.gz.09 tina-v853-open.tar.gz.11
tina-v853-open.tar.gz.00 tina-v853-open.tar.gz.02 tina-v853-open.tar.gz.04 tina-v853-open.tar.gz.06 tina-v853-open.tar.gz.08 tina-v853-open.tar.gz.10
2.為Tina SDK包打上百問網(wǎng)V853的補(bǔ)丁包
在當(dāng)前目錄下通過GIT命令下載100ASK_V853-PRO補(bǔ)丁包,對(duì)于此補(bǔ)丁包我們也在gitee和百度網(wǎng)盤中提供,百度網(wǎng)盤中位于02_開發(fā)工具/【Ubuntu】100ASK_V853-PRO_TinaSDK補(bǔ)丁包/目錄下。
book@100ask:~/workspaces$ git clone https://github.com/DongshanPI/100ASK_V853-PRO_TinaSDK.git
Cloning into '100ASK_V853-PRO_TinaSDK'...
remote: Enumerating objects: 14606, done.
remote: Counting objects: 100% (232/232), done.
remote: Compressing objects: 100% (167/167), done.
remote: Total 14606 (delta 39), reused 225 (delta 34), pack-reused 14374
Receiving objects: 100% (14606/14606), 883.22 MiB | 4.26 MiB/s, done.
Resolving deltas: 100% (1491/1491), done.
Checking out files: 100% (11560/11560), done.
下載完成后將此文件夾拷貝到tina-v853-open文件夾中
book@100ask:~/workspaces$ cp -rfvd 100ASK_V853-PRO_TinaSDK/* tina-v853-open/
3.編譯V853系統(tǒng)
進(jìn)入tina-v853-open目錄下,可以通過ls命令查看當(dāng)前文件夾下的所有文件
book@100ask:~/workspaces$ cd tina-v853-open/
book@100ask:~/workspaces/tina-v853-open$ ls
brandy build buildroot build.sh device kernel openwrt platform prebuilt tools
對(duì)于想詳細(xì)了解Allwinner Tina Linux系統(tǒng)平臺(tái),可以在后續(xù)訪問:https://tina.100ask.net/SdkModule/Linux_SystemSoftware_DevelopmentGuide-01/
建立編譯環(huán)境,輸入 source build/envsetup.sh
book@100ask:~/workspaces/tina-v853-open$ source build/envsetup.sh
NOTE: The SDK(/home/book/workspaces/tina-v853-open) was successfully loaded
load openwrt... ok
Please run lunch next for openwrt.
load buildroot,bsp...ok
Please run ./build.sh config next for buildroot,bsp.
選擇編譯的開發(fā)板,輸入lunch
book@100ask:~/workspaces/tina-v853-open$ lunch
You're building on Linux
Lunch menu... pick a combo:
1 v853-100ask-tina
2 v853-vision-tina
Which would you like?:
這里是需要您選擇編譯哪個(gè)方案的開發(fā)板,這里輸入1,選擇v853-100ask-tina,再按回車即可。
選擇完成后會(huì)倒數(shù)8秒,讓您閱讀許可協(xié)議,閱讀完成后,會(huì)詢問您是否接受上述條款協(xié)議。輸入y,再按回車即同意以上條款。
book@100ask:~/workspaces/tina-v853-open$ lunch
You're building on Linux
Lunch menu... pick a combo:
1 v853-100ask-tina
2 v853-vision-tina
Which would you like?: 1
Jump to longan autoconfig
/home/book/workspaces/tina-v853-open/build.sh autoconfig -o openwrt -i v853 -b 100ask -n default
Before using this files, please make sure that you note the following important information.
**********************************************************************
Copyright (c) 2019-2022 Allwinner Technology Co., Ltd. ALL rights reserved.
Allwinner is a trademark of Allwinner Technology Co.,Ltd., registered in
the the People's Republic of China and other countries.
All Allwinner Technology Co.,Ltd. trademarks are used with permission.
DISCLAIMER
THIRD PARTY LICENCES MAY BE REQUIRED TO IMPLEMENT THE SOLUTION/PRODUCT.
IF YOU NEED TO INTEGRATE THIRD PARTY'S TECHNOLOGY (SONY, DTS, DOLBY, AVS OR MPEGLA, ETC.)
IN ALLWINNERS'SDK OR PRODUCTS, YOU SHALL BE SOLELY RESPONSIBLE TO OBTAIN
ALL APPROPRIATELY REQUIRED THIRD PARTY LICENCES.
ALLWINNER SHALL HAVE NO WARRANTY, INDEMNITY OR OTHER OBLIGATIONS WITH RESPECT TO MATTERS
COVERED UNDER ANY REQUIRED THIRD PARTY LICENSE.
YOU ARE SOLELY RESPONSIBLE FOR YOUR USAGE OF THIRD PARTY'S TECHNOLOGY.
THIS SOFTWARE IS PROVIDED BY ALLWINNER"AS IS" AND TO THE MAXIMUM EXTENT
PERMITTED BY LAW, ALLWINNER EXPRESSLY DISCLAIMS ALL WARRANTIES OF ANY KIND,
WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING WITHOUT LIMITATION REGARDING
THE TITLE, NON-INFRINGEMENT, ACCURACY, CONDITION, COMPLETENESS, PERFORMANCE
OR MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
IN NO EVENT SHALL ALLWINNER BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS, OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
OF THE POSSIBILITY OF SUCH DAMAGE.
**********************************************************************
You can read /home/book/workspaces/tina-v853-open/build/disclaimer/Allwinnertech_Disclaimer(Cn_En)_20181122.md for detailed information.
You read time left 8 seconds....
I have already read, understood and accepted the above terms? [Y/N]y
確認(rèn)同意條款后,系統(tǒng)會(huì)自動(dòng)配置環(huán)境變量
You select Yes, Build continue....
========ACTION List: mk_autoconfig -o openwrt -i v853 -b 100ask -n default;========
options :
INFO: Prepare toolchain ...
INFO: kernel defconfig: generate /home/book/workspaces/tina-v853-open/kernel/linux-4.9/.config by /home/book/workspaces/tina-v853-open/device/config/chips/v853/configs/100ask/linux-4.9/config-4.9
INFO: Prepare toolchain ...
make: Entering directory '/home/book/workspaces/tina-v853-open/kernel/linux-4.9'
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
SHIPPED scripts/kconfig/zconf.tab.c
SHIPPED scripts/kconfig/zconf.lex.c
SHIPPED scripts/kconfig/zconf.hash.c
HOSTCC scripts/kconfig/zconf.tab.o
HOSTLD scripts/kconfig/conf
*** Default configuration is based on '../../../../../device/config/chips/v853/configs/100ask/linux-4.9/config-4.9'
#
# configuration written to .config
#
make: Leaving directory '/home/book/workspaces/tina-v853-open/kernel/linux-4.9'
INFO: clean buildserver
Usage:
kill [options] [...]
Options:
[...] send signal to every listed
-, -s, --signal
specify the to be sent
-l, --list=[] list all signal names, or convert one to a name
-L, --table list all signal names in a nice table
-h, --help display this help and exit
-V, --version output version information and exit
For more details see kill(1).
INFO: prepare_buildserver
編譯系統(tǒng),輸入make,輸入完成后系統(tǒng)將會(huì)開始編譯
book@100ask:~/workspaces/tina-v853-open$ make
===There is tina environment.===
Note: make is the shell functon in envsetup.sh.
== action: openwrt_build, action_args: ==
========ACTION List: build_linuxdev ;========
options :
INFO: ----------------------------------------
INFO: build linuxdev ...
INFO: chip: sun8iw21p1
INFO: platform: linux
INFO: kernel: linux-4.9
INFO: board: 100ask
INFO: output: /home/book/workspaces/tina-v853-open/out/v853/100ask/openwrt
INFO: ----------------------------------------
INFO: don't build dtbo ...
INFO: build arisc
INFO: build_bootloader: brandy_path= /home/book/workspaces/tina-v853-open/brandy/brandy-2.0
grep: /home/book/workspaces/tina-v853-open/brandy/brandy-2.0/spl/Makefile: No such file or directory
build for sun8iw21p1_defconfig ...
Prepare arm toolchain ...
...//此部分編譯輸出信息省略
Building kernel
/home/book/workspaces/tina-v853-open/kernel/linux-4.9/output/lib/modules/4.9.191
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CHK scripts/mod/devicetable-offsets.h
CHK include/generated/timeconst.h
CHK include/generated/bounds.h
CHK include/generated/asm-offsets.h
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
DTC arch/arm/boot/dts/board.dtb
Kernel: arch/arm/boot/Image is ready
Building modules, stage 2.
MODPOST 27 modules
Kernel: arch/arm/boot/zImage is ready
Kernel: arch/arm/boot/uImage is ready
'arch/arm/boot/Image' -> 'output/bImage'
'arch/arm/boot/uImage' -> 'output/uImage'
'arch/arm/boot/zImage' -> 'output/zImage'
Copy rootfs.cpio.gz for arm
Building modules
[GPU]: No GPU type is configured in /home/book/workspaces/tina-v853-open/kernel/linux-4.9/.config.
regenerate rootfs cpio
16149 blocks
16150 blocks
build_ramfs
Copy boot.img to output directory ...
./scripts/build.sh
sun8iw21p1 compile Kernel successful
INFO: ----------------------------------------
INFO: build Tina OK.
INFO: ----------------------------------------
等待編譯完成,此部分編譯時(shí)間由電腦CPU等決定,第一次編譯系統(tǒng)的時(shí)間比較長,請(qǐng)耐心等待。等待輸出編譯Tina OK即編譯成功。
4.打包生成100ASK_V853-PRO系統(tǒng)鏡像
編譯完成后,輸入pack,可以直接將剛剛編譯完成的系統(tǒng)打包生成可燒寫到板載EMMC上的鏡像。
book@100ask:~/workspaces/tina-v853-open$ pack
/home/book/workspaces/tina-v853-open/build/pack -c sun8iw21p1 -i v853 -p openwrt -b 100ask -k linux-4.9 -d uart0 -v none -m normal -w none -n default
INFO: /home/book/workspaces/tina-v853-open/out/v853/common/keys
copying tools file
copying configs file
copying product configs file
...
Dragon execute image.cfg SUCCESS !
----------image is at----------
33M /home/book/workspaces/tina-v853-open/out/v853/100ask/openwrt/v853_linux_100ask_uart0.img
pack finish
等待打包完成,打包完成后可以根據(jù)上面的輸出信息提示的目錄下找到v853_linux_100ask_uart0.img鏡像,將此鏡像文件拷貝到Windows電腦中。
5.使用PhoenixSuit燒寫工具進(jìn)行系統(tǒng)的燒寫
全志USB燒錄驅(qū)動(dòng)包:AllwinnerUSBFlashDeviceDriver
全志線刷工具:AllwinnertechPhoeniSuit
在連接開發(fā)板后需要注意,虛擬機(jī)可能會(huì)攔截串口或者USB,選擇連接到主機(jī)即可。
5.1 安裝全志USB驅(qū)動(dòng)
全志USB燒錄驅(qū)動(dòng)包:AllwinnerUSBFlashDeviceDriver
如果是第一次使用,需要安裝全志USB驅(qū)動(dòng),如果已經(jīng)安裝過全志USB驅(qū)動(dòng)即可跳轉(zhuǎn)到5.2繼續(xù)進(jìn)行燒寫系統(tǒng)。
在我們連接好開發(fā)板的12V電源線,并將兩條Type-C分別連接到開發(fā)板和電腦端以后,將開關(guān)撥向靠近12V電源的方向即可將開發(fā)板上電。然后先按住 100ASK-V853-PRO開發(fā)板 FEL 燒寫模式按鍵,之后按一下reset復(fù)位鍵,就可以自動(dòng)進(jìn)入燒寫模式。
這時(shí)我們可以看到電腦設(shè)備管理器 通用串行總線控制器 部分彈出一個(gè) 未知設(shè)備 ,這個(gè)時(shí)候我們就需要把我們提前下載好的 全志USB燒錄驅(qū)動(dòng) 進(jìn)行修改,然后將解壓縮過的 全志USB燒錄驅(qū)動(dòng) 壓縮包,解壓縮,可以看到里面有這么幾個(gè)文件。
InstallUSBDrv.exe
drvinstaller_IA64.exe
drvinstaller_X86.exe
UsbDriver/
drvinstaller_X64.exe
install.bat
對(duì)于wind7系統(tǒng)的同學(xué),只需要以管理員 打開 install.bat
腳本,等待安裝,在彈出的 是否安裝驅(qū)動(dòng)的對(duì)話框里面,點(diǎn)擊安裝即可。
對(duì)于wind10/wind11系統(tǒng)的同學(xué),需要在設(shè)備管理器里面進(jìn)行手動(dòng)安裝驅(qū)動(dòng)。
如下圖所示,在第一次插入OTG設(shè)備,進(jìn)入燒寫模式設(shè)備管理器會(huì)彈出一個(gè)未知設(shè)備。
接下來鼠標(biāo)右鍵點(diǎn)擊這個(gè)未知設(shè)備,在彈出的對(duì)話框里, 點(diǎn)擊瀏覽我計(jì)算機(jī)以查找驅(qū)動(dòng)程序軟件。
之后在彈出新的對(duì)話框里,點(diǎn)擊瀏覽找到我們之前下載好的 usb燒錄驅(qū)動(dòng)文件夾內(nèi),找到 UsbDriver/
這個(gè)目錄,并進(jìn)入,之后點(diǎn)擊確定即可。
注意進(jìn)入到 UsbDriver/
文件夾,然后點(diǎn)擊確定,如下圖所示。
此時(shí),我們繼續(xù)點(diǎn)擊 下一頁 按鈕,這時(shí)系統(tǒng)就會(huì)提示安裝一個(gè)驅(qū)動(dòng)程序。
在彈出的對(duì)話框里,我們點(diǎn)擊 始終安裝此驅(qū)動(dòng)程序軟件 等待安裝完成。
安裝完成后,會(huì)提示,Windows已成功更新你的驅(qū)動(dòng)程序。
最后我們可以看到,設(shè)備管理器 里面的未知設(shè)備 變成了一個(gè) USB Device(VID_1f3a_efe8)
的設(shè)備,這時(shí)就表明設(shè)備驅(qū)動(dòng)已經(jīng)安裝成功。
安裝完成USB驅(qū)動(dòng)后后續(xù)即可正常使用燒錄功能。
5.2 燒寫系統(tǒng)
全志線刷工具:AllwinnertechPhoeniSuit
在我們連接好開發(fā)板的12V電源線,并將兩條Type-C分別連接到開發(fā)板和電腦端以后,打開PhoenixSuit燒寫工具,
打開軟件后 軟件主界面如下圖所示
接下來 我們需要切換到 一鍵刷機(jī)窗口。如下圖所示,點(diǎn)擊紅框標(biāo)號(hào)1,在彈出的新窗口內(nèi),我們點(diǎn)擊 紅框2 瀏覽 找到我們剛剛編譯出來的 V853系統(tǒng)鏡像v853_linux_100ask_uart0.img,選中鏡像后,點(diǎn)擊紅框3 全盤擦除升級(jí) 。
這時(shí) 我們拿起已經(jīng)連接好的開發(fā)板,先按住 FEL 燒寫模式按鍵,之后按一下 RESET 系統(tǒng)復(fù)位鍵,就可以自動(dòng)進(jìn)入燒寫模式并開始燒寫。
燒寫時(shí)會(huì)提示燒寫進(jìn)度條,燒寫完成后,會(huì)在紅框處提示固件燒寫成功。
6.進(jìn)入Tina系統(tǒng)
燒寫完成,我們可以使用串口工具M(jìn)obaXterm進(jìn)入串口查看,軟件我們放在百度網(wǎng)盤的02_開發(fā)工具/【W(wǎng)indows】MobaXterm(串口工具 ssh工具合集)
默認(rèn)情況下系統(tǒng)會(huì)自動(dòng)安裝串口設(shè)備驅(qū)動(dòng),如果沒有自動(dòng)安裝,可以使用驅(qū)動(dòng)精靈來自動(dòng)安裝。 * 對(duì)于Windows系統(tǒng) 此時(shí)Windows設(shè)備管理器 在 端口(COM和LPT) 處會(huì)多出一個(gè)串口設(shè)備,一般是以 USB-Enhanced-SERIAL CH9102
開頭,您需要留意一下后面的具體COM編號(hào),用于后續(xù)連接使用。
如上圖,COM號(hào)是96,我們接下來連接所使用的串口號(hào)就是96。
打開軟件后新建會(huì)話后,第1步選擇串口功能,第2步在串口端選擇CH9102的串口,第3步波特率設(shè)置115200,第4步流控選擇None,第5步選擇OK。
選擇后進(jìn)入了串口界面,此時(shí)可能會(huì)沒有輸出信息的情況,按下回車鍵即可進(jìn)入tina開發(fā)板控制臺(tái)。
如果此時(shí)想重新查看啟動(dòng)信息,可以在終端輸入reboot,或者在開發(fā)板上按下reset鍵。
上述為啟動(dòng)完成的信息,可以看到Tina Linux的標(biāo)識(shí)
-
Linux
+關(guān)注
關(guān)注
87文章
11123瀏覽量
207920 -
開發(fā)板
+關(guān)注
關(guān)注
25文章
4771瀏覽量
96185 -
編譯
+關(guān)注
關(guān)注
0文章
646瀏覽量
32672 -
虛擬機(jī)
+關(guān)注
關(guān)注
1文章
888瀏覽量
27813 -
SDK
+關(guān)注
關(guān)注
3文章
1006瀏覽量
45421
發(fā)布評(píng)論請(qǐng)先 登錄
相關(guān)推薦
評(píng)論