1 / 232

計畫主持人:許蒼嶺 授課教師:李宗南、 簡銘伸 、李名峰 教材編撰 : 吳普誠 國立中山大學 資訊工程系

教育部補助「行動寬頻尖端技術跨校教學聯盟計畫 - 行動寬頻網路與應用 - 小細胞基站聯盟中心計畫」 Small Cell 創新應用與服務專題 課程單元 : Small Cell 實驗- TI-6614 開發板實務. 計畫主持人:許蒼嶺 授課教師:李宗南、 簡銘伸 、李名峰 教材編撰 : 吳普誠 國立中山大學 資訊工程系. Outline. TI-6614 Evaluation Module 與軟體開發環境介紹 ARM & DSP software develop environment

timmyh
Download Presentation

計畫主持人:許蒼嶺 授課教師:李宗南、 簡銘伸 、李名峰 教材編撰 : 吳普誠 國立中山大學 資訊工程系

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. 教育部補助「行動寬頻尖端技術跨校教學聯盟計畫-行動寬頻網路與應用-小細胞基站聯盟中心計畫」Small Cell創新應用與服務專題課程單元:Small Cell實驗-TI-6614開發板實務 計畫主持人:許蒼嶺 授課教師:李宗南、簡銘伸、李名峰 教材編撰:吳普誠 國立中山大學 資訊工程系

  2. Outline • TI-6614Evaluation Module與軟體開發環境介紹 • ARM & DSP software develop environment • TI-6614 SoC Multicore communication Research • Inter-Processor Communication(IPC) • Multicore Navigator Msgcom communication • TI System Analyzer Research • TI LTE PHY co-processor Research

  3. TI-6614EVM Introduction • TMS320TCI6614 are new wireless base station system-on-chips (SoCs) that deliver the industry’s highest performing small cell base station solutions with simultaneous dual mode 3G and 4G. • The 4TMS320C66x DSP cores in the TCI6614 provide programmable performance with new hardware accelerators and control processing is performed by an integral ARM RISC core in each SoC to design low power, high performance solutions for small cell base stations

  4. TMS320TCI-6614 SoC Architecture • C66x CorePac • 4 DSP Cores • ARM Cortex-A8 • 1 ARM CPU • Memory Subsystem • Memory control unit • Hardware Coprocessors • Supplement for primary processor • Multicore Navigator • Multicore co-working • Network Coprocessor • Hardware accelerators • Peripherals • Communication interface

  5. TCI6614 block diagram • Processors • ARM A8 • CorePac 66x DSP • Multicore Navigator • Transferring data between cores and peripherals • Layer1-PHY co-processor • Hardware acceleration

  6. TMDXEVM6614 EVM

  7. LTE small-cell implementation

  8. LTE PHY software solution TI-6614 EVM SoftwarePac • SoftwarePac  LTE Layer1/PHY software MC-SCSDK

  9. LTE PHY software solution

  10. Multicore Software Development Kit Introduction • The MCSDK provides the core foundational building blocks for customers toquickly start developing embedded applications on TI high performance multicore DSPs. • Uses the SYS/BIOS or Linux real-time operating system • Accelerates customer time to market by focusing on ease of use and performance • Provides multicore programming methodologies • Ensures software reuse by maintaining compatibility across different product generations

  11. SC-MCSDK Introduction

  12. TI-6614 EVM開發環境介紹 • System Development Environments • Host OS:Ubuntu 14.04 LTS • IDE:Code Composer Studio V5 • GNU cross tool chain:arm-linux-gnueabihf v4.7 • Root filesystem:UBIFS • Mount root filesystem via NFS for Linux • Bootloader:U-boot • Target OS:AragoLinux-tci6614 Kernel <PC Linux Host> Cross-Platform Development Environment <Target> TI-6614 EVM Cross tool chain Bootloader (Kernel image) (Root filesystem) RS232 COM1 Kernel image Root filesystem TFTP,NFS LAN XDS560v2 Emulator JTAG/USB Code Composer Studio IDE USB

  13. TI-6614EVM連接示意圖 • Connecting Console Port: • Use Hyper Terminal window to operate the board and display results. • Connecting LAN Port: • Connecting the board to the network and download images to the board from server through TFTP, NFS or FTP • Connecting JTAG Port: • Use CCS IDE to load applications to the board for debugging. <PC Linux Host> Cross-Platform Development Environment <Target> TI-6614 EVM Cross tool chain Bootloader (Kernel image) (Root filesystem) RS232 COM1 Kernel image Root filesystem TFTP,NFS LAN XDS560v2 Emulator XDS560v2 Emulator JTAG/USB Code Composer Studio IDE USB

  14. TI-6614 EVM連接示意圖 • 實際連接圖與說明 RS232_COM1 Ethernet USB/JTAG Power SW Boot mode/ configuration setting

  15. Code Composer Studio IDE Introduction • Code Composer Studio™ (CCStudio) is an integrated development environment (IDE) for Texas Instruments (TI) embedded processor families. It includes: • Compilersfor each of TI's device families • Source code editor • Project build environment • Debugger & Profiler • Real-time operating system

  16. TI-6614EVM之DSP開發環境設定流程 • CCS Development Flow 1. Build ProjectGenerate .out file 2. Lunch EVM configuration 3. Connect DSP Core 4. Load .out file to Run application 1 2 2 4 3

  17. TI-6614EVM之ARM開發環境設定流程 • Loading and running Linux file system on EVM • U-Boot設定 • 在EVM上執行U-Boot • TFTP Linux kernel image through Ethernet on EVM • 透過網路線傳輸檔案到EVM • Boot-up Linux kerneland NFS environment • 啟動EVM的Linuxfile system並與PC端的NFS同步資料 • 建立Linux host端的Cross Tool Chain環境 • 下載SC-MCSDK文件所提供的cross tool chain檔案 • 安裝cross compiler並設定環境變數 • 編譯程式並在開發板上執行

  18. 移植Linux kernel流程 • 為了能在開發板上的ARM核心運行程式,首先必須根據使用手冊將SDK所提供的Linux kernel移植到ARM核心,而所需步驟如下所示: • Load and running U-Boot on EVM using CCS • Transfer Linux kernelthroughTFTP • Set up U-Boot environment • Boot up file system TFTP U-boot

  19. Network File System介紹 • 透過NFS mount root filesystem在開發時可以很輕易的更新root filesystem上面的程式或檔案,不需要每次都將新的程式包至root filesystem後重新製作image,且由於Flash有燒寫次數的限制,透過此方法也可以降低Flash在燒寫時所會造成壞塊的機會。 TI-6614 EVM • PC (Ubuntu) • Setup NFS • Create nfsroot and set it public • Set Network Card IP to the same local network • Create a Root File System innfsroot • U-Boot • Set EVM Network Card IP to the same local network • Set bootargument • Kernel • (Automatically) Mount nfsroot via NFS • (Automatically) Load Root File System from nfsroot

  20. Boot Linux kernel方式 • Running Linux Kernel on EVM • Loading and running U-Boot on EVM using CCS • 使用SC-MCSDK所提供的預先編譯的kernel • 可燒錄到NAND,成功後可不用透過CCS來啟動Linux • Booting Linux through CCS • 使用script方式來移植自行編譯的kernel • 每次重啟後必須重新移植kernel

  21. Dip switch介紹 • Boot Mode and Boot Configuration Switch Settings • 21 sliding DIP switches (Board Ref. SW2 to SW6) to determine boot mode, boot configuration, device number, endian mode, PLL clock selection, and PCIe Mode selection options. SW3 SW2 SW7 SW6 SW5 SW4

  22. Dip switch設定方式 • Boot Mode and Boot Configuration Switch Settings

  23. 燒錄U-Boot(1/5) • Loading and running U-Boot on EVM using CCS • Set boot dip switch to ARM master no boot mode • SW2[2]=1b, {SW5[3:1], SW4[4]}=0000b • Open Tera Term to monitor EVM through COM port

  24. 燒錄U-Boot(2/5) • Loading and running U-Boot on EVM using CCS • Set up Serial port • Baud rate=115200

  25. 燒錄U-Boot(3/5) • In CCS, launch the tci6614_xds560v2 target • Connect the CortexA8 ARM core • Open Memory Browser • ViewMemory Browser • Load Memory data • ToolsLoad Memory

  26. 燒錄U-Boot(4/5) • Memory Browser • Load u-boot-tci6614-evm.bin to start address 0x0c001000 with 32-bits type-size

  27. 燒錄U-Boot(5/5) • In Registers window, change the PC register value to 0x0c001000 and run the image

  28. TFTP設定(1/4) • TFTP (Trivial File transfer Protocol)如同我們一般所熟知FTP,其主要用途為在不同機器間傳送檔案,其所提供的功能相較於FTP少的許多,但也因為其輕巧的特性,因此我們通常都會透過TFTP來在Host端及Target端互傳檔案。 • TFTPServer • Windows hostTftp32 tool • Linux host tftpd-hpa • 本實驗採用方法

  29. TFTP設定(2/4) server IP=10.168.1.233(host) ipaddr=10.168.1.234(EVM) netmask=255.255.255.0 gatewayip=10.168.1.254 • TI-6614 EVM U-Boot設定 • 設定TFTP Server IP與板子IP(可自定) EVM U-Boot Linux PC host print env

  30. TFTP設定(2/4) • How to setup U-boot environment variable: • Enter:”setenvvariable_namevalue” • Then enter:”saveenv”, to save the new environments to Flash Ex: 設定linux host ip > setenv serverip 10.168.1.233 > saveenv Ex: 設定EVM ip > setenv ipaddr 10.168.1.234 > saveenv Ex: 設定子網路遮罩 > setenv netmask 255.255.255.0 > saveenv Ex: 設定閘道 > setenv gatewayip 10.168.1.233 > saveenv

  31. TFTP設定(3/4) • TFTP file system image and burn to the nand flash • > tftp 0x88000000 tci6614-evm-ubifs.ubi • > nand erase.part ubifs • > nand write 0x88000000 ubifs 0x02fe0000 Size of tci6614-evm-ubifs.ubi

  32. TFTP設定(4/4) • TFTP Linux kernel image & device tree blob • uImage-tci6614-evm.bin0x88000000 • Tci6614-evm.dtb0x80000200

  33. Linux host的NFS設定(1/6) 為了讓EVMfile system與Linux host的NFS能順利溝通,必須先設定Linux host端的nfs環境,其詳細步驟如下: • Step 1. 輸入”apt-get install nfs-kernel-server”即可在Ubuntu環境下安裝NFS Server Daemon • Step 2. 建立我們所要給予client端mount的資料夾,此資料夾應該包含我們所需的root filesystem目錄 • root filesystem目錄的檔案由SC-MCSDK提供 • Step 3. 編輯/etc/exports來設定我們所建立的資料夾可以被client端所mount • Step 4. 編輯/etc/hosts.allow來設定我們外部設備存取NFS服務的權限 • Step5. 重新啟動NFS Server服務

  34. Linux host的NFS設定(2/6) • Step 1. 輸入”apt-get install nfs-kernel-server”即可在Ubuntu環境下安裝NFS Server Daemon

  35. Linux host的NFS設定(3/6) • Step 2. 建立我們所要給予client端mount的資料夾,此資料夾應該包含我們所需的root filesystem目錄 • mount資料夾路徑:/home/vlsi/TI6614_NFS • Root filesystem目錄檔案:ti-scmcsdk-rootfs-tci6614-evm.rootfs.tar 將tar檔案解壓縮到mount資料夾

  36. Linux host的NFS設定(4/6) • Step 3. 編輯/etc/exports來設定我們所建立的資料夾可以被client端所mount • 加入mount資料夾路徑 *rw所有使用者都可讀寫mount資料夾 No_root_squash開放用戶端使用 root 身份 來操作伺服器的檔案系統 Mount資料夾路徑

  37. Linux host的NFS設定(5/6) • Step 4. 編輯/etc/hosts.allow來設定我們外部設備存取NFS服務的權限

  38. Linux host的NFS設定(6/6) • Step5. 重新啟動NFS Server服務 • 重新啟動:service nfs-kernel-server restart • 檢視狀態:service nfs-kernel-server status • 停止服務:service nfs-kernel-server stop

  39. U-Boot Network file system設定(1/2) • nfs:為我們所建立用來使用NFS mount root filesystem的script,主要目的在於設定Linux boot up時,U-boot所會傳給Linux的開機參數:bootargs • >setenvnfs “setenvbootargs console=ttyS0,115200n8 root=/dev/nfsrwnfsroot=10.168.1.233:/home/vlsi/TI6614_NFS ip=10.168.1.234:10.168.1.233:10.168.1.254:255.255.255.0:TCI6614:eth0” • >run nfs; boot

  40. U-Boot Network file system設定(2/2) bootargs參數說明: • console:Linux所使用的output console,在此我們設定為ttyS0,也就是第一個UART serial port • root:Linux Kernel所會使用的root filesystem,在此我們設定為NFS的裝置 • rw:設定Linux Kernel所mount的root device是可讀可寫的 • nfsroot:NFS root filesystem目錄 • ip:設定NFS Server的IP address,使用”:”來區分各個子欄位 • 第一個欄位:EVM的IP address • 第二個欄位:NFS Server的IP address • 第三個欄位:EVM的Gateway • 第四個欄位:EVM的Netmask • 第五個欄位:EVM主機名稱,此欄位可以不填,但不可直接忽略此欄位,i.e. 你還是必須輸入”::”代表一個空值的欄位 • 第六個欄位:我們將使用的網路裝置,在此我們使用eth0這個裝置

  41. 啟動NFS並登入root帳戶 • Boot-up network root file system successfully NFS連接 使用者登入 Host NFS目錄

  42. Cross tool chain介紹 • Cross Tool Chain is used for compiling the programs into the Target executable program, such as ARM, MIPS… etc • Cross Tool Chain includes gcc (C Compiler)、as (Assembler) and ld (Linker)…etc LinuxHost (x86) Cross-Platform Development Environment Target (ARM) Linux Head File ARM Executable TI-6614 EVM GCC C/C++ compiler Source Code Executable program Binutil- as, ld, … Glibc- C library

  43. Cross tool chain設定(1/7) • 下載Linarocross compiler toolchain • https://launchpad.net/linaro-toolchain-binaries/trunk/2013.03/+download/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux.tar.bz2 • 安裝cross compiler • 解壓縮指令:tar -jxf gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux.tar.bz2

  44. Cross tool chain設定(2/7) • 設定cross tool chain環境參數: • 設定”PATH”環境變數,”PATH”這個環境變數主要包含了我們一般所會使用程式之路徑,若沒有被設定在”PATH”環境變數的話,就必須提供完整的指令路徑方可使用該程式(指令) • 修改使用者家目錄下的.bashrc檔案,此檔案在每次使用者登入,或重新開啟一個新的Terminal時都會被讀取,因此修改”PATH”環境變數的指令在此檔案便可在每次登入的時候都自動執行該指令 • 指令:export PATH=$PATH:cross_tool_chain路徑 • export指令代表要將接下來所欲設定的環境變數給export出去 • $PATH代表要先取代原先PATH這個變數的值 • 另外再加上Cross Tool Chain之程式所放置之目錄路徑 ,中間使用:來隔開路徑值

  45. Cross tool chain設定(3/7) 編輯.bashrc設定檔 • 加入下列cross compiler路徑: • export PATH=$PATH:/home/vlsi/linaro_cross_compiler/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux_cross/bin

  46. Cross tool chain設定(4/7) • 重新source .bashrc才可使用修改之結果 • 檢查是否設定成功,可以輸入arm-linux-gnueabi-後再按下Tab鍵,讓程式自動補齊後面的指令 Ubuntu GCC: arm-linux-gnueabi-gcc 不支援FPU浮點運算, 僅支援軟體模式(soft) Linaro GCC: arm-linux-gnueabihf-gcc 支援FPU計算浮點運算

  47. Cross tool chain設定(5/7) • 使用arm-linux-gnueabihf-gcc–v來觀看安裝路徑與版本 arm-linux-gnueabihf-gcc 安裝路徑:/home/vlsi/linaro_cross_compiler/gcc-linaro-arm-linux-gnueabihf/ Gcc版本:Linaro GCC_4.7.3 Target版本:armv7_hard_fpu

  48. Cross tool chain設定(6/7) • Cross compiler編譯程式指令: • arm-linux-gnueabihf-gcchello.c–o hello_new • arm-linux-gnueabihf-gcc-static hello.c–o hello_new_static

  49. Cross tool chain設定(7/7) • 將執行檔透過nfs傳到EVM上面並執行 • 在開發板上執行結果: • 可直接編譯程式並成功在開發版上執行,並不需要額外設定library路徑。

  50. 參考資料 • TI-6614 SoC document: • http://www.ti.com/lit/ds/symlink/tms320tci6614.pdf • TI-6614 EVM Technical reference manual describing EVM hardware: • http://www.advantech.com/Support/TI-EVM/6614le_download4.aspx • Small Cell Multicore Software Development Kit user guide: • http://software-dl.ti.com/sdoemb/sdoemb_public_sw/sc_mcsdk/latest/index_FDS.html

More Related