Rochester Institute of Technology Beagle Board Workshop Gerald
Rochester Institute of Technology Beagle. Board Workshop Gerald Coley gerald@beagleboard. org December 2 nd , 2010
Agenda The Embedded Processor Evolution Introduction to the Beagle. Board ◦ Hands On #1 – Board Power-up, explore Desktop, In Linux, everything is a file ◦ Hands On #2 – Toggle LEDs, read switches, read I 2 C, and USB GUI building with Qt ◦ Hands On #3 – Toggle an LED from a GUI Getting help from peer developers Expanding Questions the Beagle. Board
The Embedded Evolution The embedded world is changing ◦ QUIZ What has a 7” LCD, Touchscreen, BT, WIFI, Power management, and Sensors? Classical embedded processors can’t handle these new requirements Applications ◦ ◦ ◦ demand more capabilities Connectivity Application infrastructure and SW reuse On-demand performance Complex Power Management Time to market The new embedded world holds a wealth of opportunities ARM® is leading the way in the Embedded Evolution
Find the right ARM® Solution for you Comprehensive developer ecosystem TMS 570 ARM Cortex-R 4™ Up to 250 DMIPS/ 160 MHz 32 -bit ARM Cortex™-M 3 MCUs Stellaris ® ARM Cortex-M 3 Up to 80 MHz ARM Cortex-A 8 & ARM 9™ MPUs Sitara™ ARM Cortex-A 8 & ARM 9 375 MHz to >1 GHz DSP+ARM C 6000™ Integra™ Da. Vinci™ Digital Media processors 300 MHz to >1 Ghz +Accelerator Cache RAM, ROM Flash Cache, 8 KB to 256 KB RAM, ROM FPU, ECC, Timer/PWM USB, ENET, USB, CAN, SATA, Co-Proc, 12 bit ADCs, CAN, MAC+PHY CAN, PCIe, SATA, SPI, PCIe, EMAC EMIF, LIN, SPI, Flexray ADC, PWM, SPI Transportation, Motor Connectivity, Security, Industrial automation, Floating/Fixed Point Control, Certified for use in. Motion Control, HMI, POS & portable Video, Audio, Voice, safety critical (SIL 3) systems data terminals Industrial Automation Security, Conferencing $7. 00 to $18. 00 $5. 00 to $25. 00 $5. 00 to $200. 00 $1. 00 to $8. 00 2 MB Flash, 160 KB RAM Responsive design support Development tools Software support 32 -bit ARM MCU for Safety-Critical Applications
ARM® Cortex™-A 8 : Block Level Support for ARMv 7 § Added new support for Thumb-2, Thumb 2 EE(, Jazelle-RCT) and NEON Advanced Dynamic Branch Prediction § 95% accurate across industry benchmarks Integrated L 2 Cache 256 KB (low latency/high BW i/f w/L 1) § Optimizes access to larger data sets and minimizes bus traffic Dual issue In-Order Superscalar Pipeline § 2. 0 DMIPS/MHz High speed Level 1 Caches (16 KB) § Dual 32 entry memory translation TLB Integrated NEON coprocessor for media and signal processing § 2 to 4 x performance improvement § Integer and Floating Point support § VFPv 3 -IEEE 754 compliant (single and double precision) floating point support.
Community Development > 3, 200 participants and growing Personally affordable $125/$149 Active & technical community Freedom to innovate ® Open access to hardware documentation Opportunity to tinker and learn Wikis, blogs/RSS, promotion of community activity Android, Ubuntu, Angstrom, FFmpeg, Mee. Go, Symbian, … Free software
Why such an active community? Affordable Freedom to tinker at all levels Lots of open starting points Large and experienced community Open ecosystem provides real options § Low cost for the same core processing as used § in more expensive, yet popular, commercial products Focus on open source, open hardware and DIY § § >25, 000 boards sold exclusively in small quantities All design, test, web, etc. materials shared § § Over 150 registered projects on Beagle. Board. org Part of the Google Summer of Code with 6 projects to improve Linux, XBMC, and other open source Average of around 5 articles or blog posts per day Over 3, 200 English-language mailing list subscribers with additional dedicated mailing lists in Japanese and Portuguese and numerous project oriented mailing lists in dozens of languages Hundreds of followers on each of Facebook, Twitter, and Linked. In § Teaching tool for high-level OS on embedded § Ubuntu, Debian, Angstrom, Gentoo, Win. CE, Symbian, QNX, and many others § The Beagle. Board community shares § § Rich ecosystem using the design materials § § § Compatible or enhanced system-on-module/computer-on-module designs § See http: //beagleboard. org/resources Innovative mobile computers (Touch. Book) Radios (Beagle. Brick) Modular rapid prototyping development systems (Bug 2. 0) And many add-ons…
Beagle. Board C 4…$125 OMAP 3530 Processor § 720 MHz Cortex-A 8 § NEON+VFPv 3 § 16 KB/16 KB L 1$ § 256 KB L 2$ § 430 MHz C 64 x+ DSP § 32 K/32 K L 1$ § 48 K L 1 D § 32 K L 2 § Power. VR SGX GPU § 64 K on-chip RAM POP Memory § 256 MB LPDDR RAM § 256 MB NAND flash 3. 1” Peripheral I/O § DVI-D video out § SD/MMC+ § S-Video out § USB 2. 0 HS OTG § I 2 C, I 2 S, SPI, MMC/SD § JTAG § Stereo in/out § Alternate power § RS-232 serial USB Powered § 2 W maximum consumption § OMAP is small % of that § Many adapter options § Car, wall, battery, solar, …
And more… Other Features § 4 LEDs § USR 0 § USR 1 § PMU_STAT § PWR § 2 buttons § USER § RESET § 4 boot sources § SD/MMC § NAND flash § USB § Serial On-going collaboration at Beagle. Board. org § Live chat via IRC for 24/7 community support § Links to software projects to download 3. 1” Peripheral I/O § DVI-D video out § SD/MMC+ § S-Video out § USB HS on-the-go § I 2 C, I 2 S, SPI, MMC/SD § JTAG § Stereo in/out § Alternate power § RS-232 serial
Beagle. Board–x. M means Extra MHz and Extra MB 2, 000 Dhrystone MIPS performance with ARM® Cortex™-A 8 512 MB POP memory enabling ◦ Native builds of Ubuntu and other distros ◦ More multitasking with complex apps like Firefox or Open. Office. org $149 Robust expansion with more direct connectivity without external hubs; on-board Ethernet and five USB 2. 0 ports USB-powered board via low power processor integration Active and growing open source community at beagleboard. org 10
Beagle. Board-x. M details Laptop-like performance DM 3730 processor (AM 37 xcompatibile) § 1 GHz superscaler ARM® Cortex ™-A 8 § More than 2, 000 Dhrystone MIPS § Up to 20 Million polygons per sec graphics § 512 KB L 2$ § HD video capable C 64 x+™ DSP core POP Memory § 512 MB LPDDR RAM 3. 25” DM 3730 § LCD Expansion § I 2 C, I 2 S, SPI, MMC/SD Expansion § DVI-D § Camera Header § S-Video § JTAG § 4 -port USB 2. 0 Hub** § Stereo Out § Stereo In § 10/100 Ethernet § USB 2. 0 HS OTG § Alternate Power § RS-232 Serial § micro. SD Slot
Use your Beagle. Board like a desktop SD USB Stereo in Stereo out DVI-D Power
Take your Beagle. Board anywhere & crank code on the go Serial Port Power over USB
Hands On #1 …. Boot your board 14
Hands On #1 …Connect the Display Connector Connect cable to the Board Confirm cable is connected to monitor Be careful when connecting a TV. Most of the time the default timing is not compatible.
Hands On #1 …Connect the Keyboard & Mouse Keyboard Mouse Connect the Keyboard to one of the USB ports Connect the Mouse to one of the USB ports
Hands On #1…Insert the SD #1 Card Insert the SD card printing side up Be careful not to exert upward pressure on the card when inserting it.
Hands On #1…Optional #1 Stuff. . . Debug Port Connect the serial cable here -Requires a USB to Serial Cable or a straight cable -Laptop or a PC -Terminal SW set to 115 K, 8, n, 1, no handshaking
Hands On #1…Connect the #1 Power Connect 5 V supply here Be careful doing this and make sure you have 5 V supply and the correct polarity of power supply.
Hands On #1…Board Powers #1 Up 1) Power LED comes on 2) User 0/1 LEDs comes on 3) User 0 LED blinks 4) User 1 LED flashes
Hands On #1…Board Boots #1 Angstrom Screen Mouse pointer Login Screen ◦ Do nothing White screen and Mouse pointer Matrix Application Launcher
Hands On #1… #1 TI Matrix GUI Web browser with HTML code served up from the board Written in Qt Includes ability to launch apps click 3 D Graphics click Chameleon close window select Main select Exit
Hands On #1…Angstrom Gnome #1 Desktop Just one of the desktop options as part of the Angstrom Distribution Menu bar at top gives list of installed programs Add other applications using ‘opkg’ select Applications Scroll down the Menu close window
Hands On #1…System Monitor #1 Monitors the system performance Displays CPU loading select Applications select System Tools click System Monitor click Resources Tab close Window
Hands On #1…Frequency Scaling #1 Sets System Speed click 1 GHz Icon click 600 MHz click 600 MHz Icon click 1 GHz
Hands On #1…Multimedia Player #1 GNOME Comes Multimedia player standard in Desktop Image Big Buck Bunny is an open source movie from the Peach Open Movie Project. double Click Big. Buck Icon close Window
Hands On #1…Linux Command Line #1 Allows direct access to the Linux Kernel Enter Linux Commands Can also use an external debug port over the serial port select Applications select Accessories select Terminal type ls -al
In Linux, everything is a file Learning about Linux through SYSFS Thanks to Bill Gatliff
The file interface abstraction What can we do with files? ◦ open, read, write, close, delete ◦ What is an ‘ioctl’? Gets you to the HW! What is a virtual file system? ◦ Looks like a file, but executes code in the driver ◦ Not really storing anything to media ◦ A bit like a “ram disk”
What is SYSFS? Virtual file system that exposes drivers to userspace mount ◦ sysfs on /sys type sysfs (rw, realtime) /sys/devices driver hierarchy /sys/bus symbolic links to bus owners /sys/class common interfaces /sys/block interface Let’s go thru some examples…
Hands On #2…. . Test USR 0 and USR 1 LED select Applications select Terminal type testled Cycles through a short LED test type cd /sys/class/leds; ls type ls "beagleboard: : usr 0" type cat "beagleboard: : usr 0/trigger“ USR 0 LED will Turn on and off. 31
Hands On #2…Reading the User Button type cd /sys/class/gpio; ls type echo “ 4“ > export; ls type echo "in“ > gpio 4/direction type cat gpio 4/value type readgpio 4 press User Button press <ctrl> C to stop 32
Hands On #2…Reading Events When the mouse is moved, events are triggered and sent via the USB port to the processor type opkg install evtest press <ctrl> C to stop type evtest /dev/input/event 3 move the Mouse press <ctrl> C to stop 33
Hands On #2…Reading I 2 C Bus Read the EEPROM inside the display that provides information about that display. type cd /sys/bus; ls type cd i 2 c/devices; ls type echo "eeprom 0 x 50” > i 2 c-3/new device; ls type i 2 cdump -y 0 x 3 0 x 50 b type fbset 34
Hands On #2…Reading USB Ports • Read what USB devices are connected to the processor type cd /sys/bus/usb/devices; ls type cat usb 1/speed type cat usb? /manufacturer type lsusb close Terminal Window 35
GUI building with Qt Qt C++ framework is just one option for creating graphical applications, but it is fast, flexible, cross-platform and well-supported by an open source community Thanks to Gregg Lebovitz of ICS
Qt architecture
Qt Creator http: //qt. nokia. com Integrated development environment ◦ Runs on Windows, Mac, or Linux ◦ Designer for your GUIs ◦ C++ editor and debugger Build your GUI on your PC, then move it over to the Beagle. Board to add I/O, etc. ◦ Angstrom Linux distribution has the compiler and libraries ready to build Qt apps natively on your Beagle. Board
Hands On #3…Qt Demos Lots of different GUI tools Many other programming tools, like networking, IPC, 3 D, database, … open Terminal Program type qtdemo close Window
Hands On #3 – Button & LED GUI close Terminal Program open Labs from desktop type cd lab 2; ls –al type gedit. /lab 2. cpp & close GEDIT type qmake 2 && make type. /lab 2 click Push me! Watch the Flashing LED on the board close the application
Getting help from your peers How to work in the Linux community
Baseline tools and software http: //beagleboard. org/resources Hardware verification procedure (http: //beagleboard. org/support) ◦ GPL x-load, u-boot, Linux kernel, and demo distro for validation ◦ Code images, procedure, and sources are provided to verify the board functionality GPL ARM GNU compiler collection (GCC) ◦ Code Sourcery version 2009 q 1 is the latest supported by TI Runs on Linux/Windows and generates ARMv 7/Thumb 2 ◦ Angstrom version is utilized in ESC training and demo image on x. M Access to C 6000 with compilers and open source software ◦ Free TI C 6000 compiler for non-commercial use x 86 -Linux hosted (ARM hosted version in evaluation) ◦ GPL GCC compiler in progress (http: //linux-c 6 x. org) ◦ C 6 Run (DSPEasy) project to simplify development model ◦ BSD/GPL DSP/Link interface software Free 3 D graphics libraries (Open. GLES 2. 0) Free production audio/video codecs for the DSP
How to ask for help http: //catb. org/~esr/faqs/smart-questions. html Know the on-line resources Know the on-line community Know the manual Listen to the answers Pay for performance Share the answers you find 43
Order of resources 1. Search beagleboard. org, e. Linux. org, the mailing list archive, and IRC logs 2. Read and search BBSRM_latest. pdf 3. Check the http: //beagleboard. org/faq link 4. Search the web 5. Try something Gives you some perspective on what to ask Ask on IRC and be patient/polite 6. Doesn’t disrupt everyone Mailing list 7. Individual developers will go away if load isn’t shared 44
The community perspective Earn respect by saying what you’ve done and how you’ve tried to find an answer ◦ Where did you search? ◦ What did you try on the board? You aren’t entitled to an answer ◦ Show that you are willing to work for it and the community will feel you are a part of it ◦ Impatience implies that your time is more valuable than others in the community 45
Chat, mail, forums, blogs, and wikis! All exist because they all solve different problems Chat allows you to know someone’s listening http: //beagleboard. org/chat or #beagle on irc. freenode. net ◦ Great for beginner questions and rapid coordination Mail allows you to reach almost anyone http: //groups. google. com/group/beagleboard ◦ Brings larger group into the conversation ◦ Provides you with a personal log in your inbox Forums helps get the threads organized https: //community. ti. com/forums/32. aspx (minimal activity to avoid disrupting community critical mass) Blogs provide emphasis, filtering, and timeliness http: //beagleboard. org/news and http: //beagleboard. blogspot. com Wikis enable inputs to become documentation http: //e. Linux. org/Beagle. Board and http: //code. google. com/p/beagleboard/wiki
Chat on IRC http: //webchat. freenode. net ◦ ◦ ◦ #beagle: discussion of the Beagle. Board #gst-ti: discussion of GStreamer with TI DSP components #ubuntu-arm: discussion of Ubuntu on ARM processors #rowboat: discussion of Android on OMAP & Sitara devices #linux-omap: discussion of OMAP Linux kernel IRC clients ◦ http: //beagleboard. org/chat ◦ http: //pidgin. im ◦ http: //www. mirc. com ◦ /List_of_IRC_clients http: //en. wikipedia. org/wiki ◦ http: //www. ircreviews. org/clients
OSs and Distributions Angstrom and Open Embedded http: //www. angstrom-distribution. org/demo/beagleboard Angstrom is what you are running Ubuntu https: //wiki. ubuntu. com/ARM/Beagle Most popular Linux distribution Has support for the Beagle. Board (Netbook, server, and network installers) Android http: //arowboat. org At least half-a-dozen companies provide commercial support for Android on the Beagle. Board; Rowboat is the one endorsed by TI Mee. Go http: //wiki. meego. com/ARM/Meego_on_Beagleboard_from_scratch The combination of Moblin and Maemo 48
OSs and Distributions Gentoo https: //www. slashorg. net/48 -Gentoo-port-for-Beagle. Board. html The Linux distribution the Beagle. Board. org web server runs Builds ARM applications both natively and cross QNX http: //www. qnx. com/products/reference-design/ti-reference-design. html Not Linux, but Posix compliant and real-time Symbian http: //developer. symbian. org/wiki/index. php/Beagle. Board_Quick_Start Most popular smart phone operating system Initial open source release was on the Beagle. Board 49
Win. CE http: //beagleboard. org/esc Advanced Lots GUI and code tools of code libraries available Low-cost entry through “Spark” 50
Expanding the Beagle. Board Create your own expansion cards ◦ Rev C 4 does not come with expansion connectors (Can be added by user) ◦ -x. M does come with connectors ◦ Mounting holes are the same ◦ Common connectors in the same place Gerber and CAD files available to assist in making your own PCB
Expansion Cards & Accessories ZIPPY TRAINER LCD DISPLAY ZIPPY 2 PLASTIC CASE VGA ADAPTER METAL CASE Cables & Supplies
Available Resources Beagle Hardware Documentation ◦ http: //beagleboard. org/hardware/design Processor Documentation ◦ http: //focus. ti. com/docs/prod/folders/print/omap 3530. html Add-On Boards and Accessories ◦ http: //www. beagleboardtoys. com/ ◦ http: //www. tincantools. com/home. php? cat=255 ◦ https: //specialcomp. com/beagleboard/index. htm
Thank you! g-coley 1@ti. com gerald@beagleboard. org http: //beagleboard. org/discuss ============= jdk@ti. com jkridner@beagleboard. org http: //beagleboard. org/chat ◦ IRC nickname: jkridner
- Slides: 54