Sitara Linux Software Developer's Guide Thank You for Choosing to Evaluate One of Our Sitara ARM Microprocessors [1]
Total Page:16
File Type:pdf, Size:1020Kb
Sitara Linux Software Developer’s Guide v5.06.00.00 NOTE - This PDF is hyperlinked. Clicking on a link (typically bolded and underlined) will take you to that chapter or open the appropriate website. Contents Articles Sitara Linux Software Developer’s Guide 1 How to Build a Ubuntu Linux host under VMware 15 Sitara SDK Installer 32 Sitara Linux SDK Setup Script 35 AMSDK START HERE Script 38 Matrix Users Guide 41 Power Management Users Guide 50 ARM Multimedia Users Guide 54 Camera Users Guide 78 Cryptography Users Guide 85 Oprofile User's Guide 94 Open Source Wireless Connectivity WLAN Bluetooth User Guide 97 OMAP Wireless Connectivity OpenSource Compat Wireless Build 99 OMAP Wireless Connectivity mac80211 compat wireless implementation Architecture 100 OMAP Wireless Connectivity Battleship Game demo 102 AMSDK u-boot User's Guide 107 AMSDK Linux User's Guide 116 Code Composer Studio v5 Users Guide 120 Linux Debug in CCSv5 151 How to setup Remote System Explorer plug-in 164 How to Run GDB on CCSv5 180 Pin Mux Utility for ARM MPU Processors 188 Pin Setup Tool for AM18xx ARM Microprocessors 210 AM335x Flashing Tools Guide 218 Flash v1.6 User Guide 221 AM18x Flash Tool User's Guide 235 AMSDK File System Optimization/Customization 237 Sitara Linux Training 239 How to use a Mouse instead of the Touchscreen with Matrix 241 How to Recalibrate the Touchscreen 242 AM335x U-Boot User's Guide 243 Sitara Linux SDK Top-Level Makefile 258 Sitara Linux SDK GCC Toolchain 261 Sitara Linux SDK create SD card script 266 How to add a JVM 271 AM335x U-Boot User's Guide 273 References Article Sources and Contributors 289 Image Sources, Licenses and Contributors 290 Article Licenses License 294 Sitara Linux Software Developer’s Guide 1 Sitara Linux Software Developer’s Guide NOTE - This Software Developer's Guide (SDG) currently supports the SDK 5.06.00.00 release scheduled for December 21, 2012. For the SDG specific to your SDK release, please refer to Archived SDGs under Reference_Documentation. Welcome to the Sitara Linux Software Developer's Guide Thank you for choosing to evaluate one of our Sitara ARM microprocessors [1]. Please bookmark this page and refer back to it as needed. It is designed to quickly provide the information you need most while evaluating the AMx microprocessor. We are always striving to improve this product. Please let us know if you have ideas or suggestions. Supported Platforms & Version Information The following Sitara ARM microprocessors are supported with this SDK version. Platforms SDK PSP Kernel U-Boot Toolchain Release Date BeagleBone 5.06 04.06.00.09 3.2 2012.10 gcc4.5.3 December 2012 AM335xEVM 5.06 04.06.00.09 3.2 2012.10 gcc4.5.3 December 2012 AM335x StarterKit (SK) 5.06 04.06.00.09 3.2 2012.10 gcc4.5.3 December 2012 Beagleboard-xM 5.05 - 3.3.7 2012.04.01 gcc4.5.3 June 2012 AM37xEVM 5.05 04.02.00.07 2.6.37 2012.04.01 gcc4.5.3 June 2012 AM35xEVM 5.05 04.02.00.07 2.6.37 2011.09 gcc4.5.3 June 2012 AM180xEVM 5.05 03.21.00.04 2.6.37 2010.12 gcc4.5.3 June 2012 Sitara Linux Software Developer’s Guide 2 Linux Software Stack The following software stack illustrates at a high level the various components provided with the Sitara Linux SDK. NOTE - Availability of certain applications are platform dependent and clarified in the associated User Guides below. EVM Hardware Overview Details for various hardware platforms supported by this Sitara Linux SDK are provided before. Platform Document EVM Provider [2] [3] AM335xEVM Hardware User's Guide www.ti.com [4] [3] AM335x StarterKit (SK) Hardware User's Guide www.ti.com [5] [6] BeagleBone Hardware User's Guide (Rev A3) Beagleboard.org [7] [6] Beagleboard-xM Hardware User's Guide Beagleboard.org [8] [9] AM37xEVM Hardware User's Guide Mistral [10] [11] AM35xEVM Hardware User's Guide Logic [12] [11] AM180xEVM Hardware User's Guide Logic Sitara Linux Software Developer’s Guide 3 Start your Linux Development Before using the Sitara Linux SDK you must have a Linux development environment. Linux development environments vary, so we recommend the following for ease of use and consistency when working together. The next few steps will assist you in the setup & configuration of your Linux host based on the physical setup shown below. 1. Configure a Linux Host - If you already have a Linux host machine, go to Step 2. If you do not have a Linux host machine, you can configure a Linux host machine on your Windows PC using a virtual machine. • Build a Ubuntu 10.04 LTS Linux host with VMware on WinXP (preferred) • Build a Ubuntu 10.04 LTS Linux host with VirtualBox on WinXP For standard EVMs: 2. Configure your development For Beaglebone: 2. Configure your development environment environment 3. Install the SDK - Within your Linux host machine, Install 3. Run the START_HERE Script - When Beaglebone boots, a START_HERE the Sitara SDK directory will display on your Linux host desktop. To start your evalaution and development using the BeagleBone, Run the START_HERE.sh script NOTE: The START_HERE.sh script will run the setup.sh script. For Beaglebone boards before rev A5 the setup.sh script will attempt to install a udev rule to load the ftdi_sio module with the proper parameters to recognize the Beaglebone. If you experience difficulty with the Beaglebone being recognized you can load the module manually by doing: • sudo rmmod ftdi_sio • sudo modprobe ftdi_sio vendor=0x0403 product=0xa6d0 4. Run the Setup Script - Once the SDK has been installed, NOTE: If using a VMWare image you will likely need to import the beaglebone Run the Setup.sh Script to guide you through the remaining into the VMWare image as a mass storage device using the instructions here development environment configuration. Configuring a Serial Connection If you chose not to use the setup.sh script (or START_HERE.sh) to configure you connection you can always perform the following steps to configure a serial connection with the board. • The following steps will help you validate that you have a valid serial connection with your target board IMPORTANT These steps are written for boards like the EVM-SK and Beaglebone which use an FTDI USB-to-Serial adapter. For boards with a straight UART connection you can ignore the steps for /dev/ttyUSBx and instead just use the serial port on your Linux host that is connected to the board • Connect the USB cable between your Linux host and your target board Sitara Linux Software Developer’s Guide 4 IMPORTANT On the AM335x EVM-SK, the USB cable enables a USB-to-serial interface to the Linux host PC. If using a virtual machine, please insure the AM335x EVM-SK is a selected USB device. NOTE If you are running your VMWare image with Windows 7 some USB-to-Serial adapters do not properly work with Windows 7. Make sure that your adapter specifically says that it supports Windows 7. You may also need to install an additional driver for your adapter. • Open a terminal and run the following command to find the USB serial adapters available on the system. The FTDI chip used on the board presents two serial interfaces to the Linux host. The first interface is the JTAG interface and the second one is the serial console interface. ls /dev/ttyUSB* You should see output like: /dev/ttyUSB0 /dev/ttyUSB1 NOTE If using VMWare you may need to pass the "Future Technology Devices" device into the VMWare image • As mentioned above since the board's serial interface is the second interface you will want to open a serial console to the second device node. In this case that is /dev/ttyUSB1. This can be done by doing: • minicom -w -s • Select Serial port setup and press ENTER • Press A to modify the Serial Device and change the device to /dev/ttyUSB1. Press ENTER • Press ENTER to exit the serial setup • Select Exit and press ENTER • You should now see a minicom window. • Power on the board, you should see "ccccc" being printed in the window, if so the serial connection is working as expected. Go ahead and leave this console RUNNING in the background. NOTE For the EVM-SK board the power button is under the board in the upper-right hand corner. You must press and hold this button to power on the board. NOTE For the Beaglebone the board will power on as soon as the USB cable is connected. you can reset the board by pressing the reset button which should provide you with the expected output Sitara Linux Software Developer’s Guide 5 SDK Directory Structure Overview The Sitara Linux SDK contains the following top-level directories and files These directories contain the code and tools used to develop for Sitara devices. • bin - Contains the helper scripts for configuring the host system and target device. Most of these scripts are used by the setup.sh script. • board-support - Contains the SDK components that need to be modified when porting to a custom platform. This includes the kernel and boot loaders as well as any out of tree drivers. • docs - Contains various SDK documentation such as the software manifest and additional user's guide. This is also the location where you can find the training directory with the device training materials. • example-applications - Contains the sources for the TI provided example applications seen during the out-of-box demonstration. • filesystem - Contains the reference file systems.