DevTouch Pro Windows/Linux Developers Guide Updated October 2011 AMYUNI Consultants AMYUNI Technologies www.amyuni.com Contents Legal Information................................................................................................................................... 3 Acknowledgments.................................................................................................................................. 4 Copyright Notice and License Agreement.............................................................................................. 4 One Year Limited Warranty ................................................................................................................... 5 DevTouch Pro Front View ...................................................................................................................... 8 DevTouch Pro Connectors...................................................................................................................... 8 Setting-Up the Development Workspace .............................................................................................. 9 Powering-Up the Device ........................................................................................................................ 9 Installing the Linux OS.......................................................................................................................... 11 Obtaining Technical Support................................................................................................................ 13 Page | 2 Legal Information Information in this document is subject to change without notice and does not represent a commitment on the part of AMYUNI. The software described in this document is provided under a license agreement or nondisclosure agreement. The software accompanying the DevTouch tablet may be used or copied only in accordance with the terms of the agreement. It is against the law to copy the software on any medium except as specifically allowed in the license or nondisclosure agreement. The licensee may make one copy of the software for backup purposes. No part of this manual may be reproduced or transmitted in any form or by any means, electronic or mechanical, including photocopying, recording, or information storage and retrieval systems, for any purpose other than the licensees personal use, without express written permission of AMYUNI. Copyright 2001-2010, AMYUNI Consultants AMYUNI Technologies. All rights reserved. Amyuni and the Amyuni logo are trademarks of Amyuni Technologies Inc. Microsoft, the Microsoft logo, Microsoft Windows, Microsoft Windows NT and their logos are trademarks of Microsoft Corporation. All other trademarks are the property of their respective owners. USA - FCC Notice:
This device complies with Part 15 of the FCC Rules. Operation is subject to the following two conditions: (1) This device may not cause harmful interference, and (2) This device must accept any interference received, including interference that may cause undesired operation. This equipment has been tested and found to comply with the limits for Class B Digital Devices, pursuant to Part 15 of the FCC Rules. These limits are designed to provide reasonable protection against harmful interference in a residential installation. This equipment generates and can radiate radio frequency energy and, if not installed and used in accordance with the instructions, may cause harmful interference to radio communications. However, there is no guarantee that interference will not occur in a particular installation. If this equipment does cause harmful interference to radio or television reception, which can be determined by turning the equipment off and on, the user is encouraged to try to correct the interference by one or more of the following measures:
Reorient or relocate the receiving antenna Increase the separation between the equipment and receiver Connect the equipment into an outlet on a circuit different from that to which the receiver is connected Consult the dealer or an experienced radio/TV technician for help Page | 3 Any changes or modifications not expressly approved by the party responsible for compliance could void the users authority to operate the equipment. This transmitter must not be co-located or operating in conjunction with any other antenna or transmitter. This equipment complies with FCC RF radiation exposure limits set forth for an uncontrolled environment. Canada - Industry Canada Notices:
This device complies with Industry Canada license-exempt RSS standard(s). Operation is subject to the following two conditions: (1) this device may not cause interference, and (2) this device must accept any interference, including interference that may cause undesired operation of the device. This equipment complies with RSS RF radiation exposure limits set forth for an uncontrolled environment. Canada - Avis dIndustrie Canada :
Cet appareil est conforme aux normes d'exemption de licence RSS d'Industry Canada. Son fonctionnement est soumis aux deux conditions suivantes : (1) cet appareil ne doit pas causer d'interfrence et (2) cet appareil doit accepter toute interfrence, notamment les interfrences qui peuvent affecter son fonctionnement. Cet quipement est conforme aux limites dexposition aux radiations RSS RF dans un environnement non contrl. Acknowledgments The Linux operating system provided with the device is based on the Open Source Linux Kernel. The source-code is provided by Amyuni upon request. Copyright Notice and License Agreement AMYUNI CONSULTANTS AMYUNI TECHNOLOGIES DEVELOPER LICENSE AGREEMENT FOR DEVTOUCH PRO TABLET PRODUCT NOTICE TO USER:
THIS IS A CONTRACT. BY INSTALLING THIS SOFTWARE YOU ACCEPT ALL THE TERMS AND CONDITIONS OF THIS AGREEMENT. This AMYUNI ("Amyuni") Developer License Agreement accompanies the DevTouch Tablet, accompanying software and related explanatory materials ("Tablet"). The term Tablet also shall include any upgrades, modified versions or updates of the Tablet licensed to you by Amyuni. Page | 4 Please read this Agreement carefully. You will be asked to accept this agreement and continue to install or, if you do not wish to accept this Agreement, to decline this agreement, in which case you will not be able to use the Tablet. Upon your acceptance of this Agreement, Amyuni grants to you a perpetual but nonexclusive license to use the Tablet and all accompanying software, provided that you agree to the following:
1. Use of the Tablet. You may use the tablet for any lawful purposes, whether for development, software installation or distribution to third parties. The Tablet and accompanying software can be used by any number of developers or users without limitation. 2. Copyright and Trademark Rights. The Tablet architecture and design are owned by Amyuni, and its structure, organization and code are the valuable trade secrets of Amyuni. The Tablet is protected by Canadian Copyright Law and International Treaty provisions. This Agreement does not grant you any intellectual property rights in the Tablet. 3. Restrictions. You agree not to modify, adapt, translate, reverse engineer, decompile, disassemble or otherwise attempt to discover the design or source code of the Tablet other than for the source-code directly provided to you by Amyuni. 4. No Warranty. The Tablet and accompanying software are being delivered to you AS IS and Amyuni makes no warranty as to their use or performance. AMYUNI AND ITS SUPPLIERS DO NOT AND CANNOT WARRANT THE PERFORMANCE OR RESULTS YOU MAY OBTAIN BY USING THE TABLET OR DOCUMENTATION. AMYUNI AND ITS SUPPLIERS MAKE NO WARRANTIES, EXPRESS OR IMPLIED, AS TO MERCHANTABILITY, OR FITNESS FOR ANY PARTICULAR PURPOSE. IN NO EVENT WILL AMYUNI OR ITS SUPPLIERS BE LIABLE TO YOU FOR ANY CONSEQUENTIAL, INCIDENTAL OR SPECIAL DAMAGES, INCLUDING ANY LOST PROFITS OR LOST SAVINGS, EVEN IF AN AMYUNI REPRESENTATIVE HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES, OR FOR ANY CLAIM BY ANY THIRD PARTY. Some states or jurisdictions do not allow the exclusion or limitation of incidental, consequential or special damages, or the exclusion of implied warranties or limitations on how long an implied warranty may last, so the above limitations may not apply to you. BY OPENING, USING OR DISTRIBUTING THIS TABLET, YOU INDICATE ACCEPTANCE OF THE FOREGOING AGREEMENT. One Year Limited Warranty WARRANTY COVERAGE Amyuni's warranty obligations are limited to the terms set forth below: Amyuni Technologies, Inc.
("Amyuni") warrants this hardware product against defects in materials and workmanship for a period of ONE (1) YEAR from the date of original purchase. If a defect exists, at its option Amyuni will
(1) repair the product at no charge, using new replacement parts, (2) exchange the product with a product that is new or which has been manufactured from new or serviceable used parts and is at least functionally equivalent to the original product, or (3) refund the purchase price of the product. A replacement product/part assumes the remaining warranty of the original product or ninety (90) days from the date of replacement or repair, whichever provides longer coverage for you. When a product or part is exchanged, any replacement item becomes your property and the replaced item becomes Amyuni's property. When a refund is given, your product becomes Amyuni's property. OBTAINING WARRANTY SERVICE Page | 5 You may deliver the product, at your expense, to Amyuni Technologies offices located in Canada or France. Upon repair or replacement, the product will be delivered back to you free of charge. Note: Before you deliver your product for warranty service it is your responsibility to keep a separate backup copy of the system software, application software and data, and disable any security passwords. You will be responsible for reinstalling all such software, data and passwords. Data recovery is not included in the warranty service and Amyuni is not responsible for data that may be lost or damaged during transit or a repair. EXCLUSIONS AND LIMITATIONS This Limited Warranty applies only to hardware products manufactured by or for Amyuni that can be identified by the "Amyuni" trademark, trade name, or logo affixed to them. The Limited Warranty does not apply to any non-Amyuni hardware products or any software, even if packaged or sold with Amyuni hardware. Software distributed by Amyuni under the Amyuni brand name (including, but not limited to system software) is not covered under this Limited Warranty. Refer to the Amyuni Software License Agreement for more information. Recovery and reinstallation of system and application software and user data are not covered under this Limited Warranty. This warranty does not apply: (a) to damage caused by accident, abuse, misuse, misapplication, or non-Amyuni products; (b) to damage caused by service
(including upgrades and expansions) performed by anyone other than Amyuni; (c) to a product or a part that has been modified without the written permission of Amyuni;, THIS WARRANTY AND REMEDIES SET FORTH ABOVE ARE EXCLUSIVE AND IN LIEU OF ALL OTHER WARRANTIES, REMEDIES AND CONDITIONS, WHETHER ORAL OR WRITTEN, EXPRESS OR IMPLIED. AMYUNI SPECIFICALLY DISCLAIMS ANY AND ALL IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IF AMYUNI CANNOT LAWFULLY DISCLAIM IMPLIED WARRANTIES UNDER THIS LIMITED WARRANTY, ALL SUCH WARRANTIES, INCLUDING WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE LIMITED IN DURATION TO THE DURATION OF THIS WARRANTY. No Amyuni reseller, agent, or employee is authorized to make any modification, extension, or addition to this warranty. AMYUNI IS NOT RESPONSIBLE FOR DIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES RESULTING FROM ANY BREACH OF WARRANTY OR CONDITION, OR UNDER ANY OTHER LEGAL THEORY, INCLUDING BUT NOT LIMITED TO LOST PROFITS, DOWNTIME, GOODWILL, DAMAGE TO OR REPLACEMENT OF EQUIPMENT AND PROPERTY, ANY COSTS OF RECOVERING, REPROGRAMMING, OR REPRODUCING ANY PROGRAM OR DATA STORED IN OR USED WITH AMYUNI PRODUCTS, AND ANY FAILURE TO MAINTAIN THE CONFIDENTIALITY OF DATA STORED ON THE PRODUCT. AMYUNI SPECIFICALLY DOES NOT REPRESENT THAT IT WILL BE ABLE TO REPAIR ANY PRODUCT UNDER THIS WARRANTY OR MAKE A PRODUCT EXCHANGE WITHOUT RISK TO OR LOSS OF PROGRAMS OR DATA. Some states and provinces do not allow the exclusion or limitation of incidental or consequential damages or exclusions or limitations on the duration of implied warranties or conditions, so the above limitations or exclusions may not apply to you. This warranty gives you specific legal rights, and you may also have other rights that vary by state or province. Page | 6 Page | 7 DevTouch Pro Front View DevTouch Pro Connectors Page | 8 Setting-Up the Development Workspace Use the supplied USB adapter (white cable) to connect a keyboard, mouse and USB key. Multiple devices can be connected using a hub. Power-up the device by pressing the On/Off button here. Connect the USB cable to your PC (Optional, might not work with all OSes) Connect the 5V power adapter. Powering-Up the Device The device goes through three stages during power-up:
1) The Open-Source U-Boot OS loader starts first 2) The Linux kernel or the Windows CE E-Boot is executed next 3) Linux, Windows CE OS or Android is started The default Linux login is:
User name: root Password: devtouch The Debian filesystem can be started using the startx command. Page | 9 The U-Boot loader can be interrupted by pressing any keyboard button as soon as the keyboard lights turn-on (the keyboard lights indicated that the USB port is powered.) When U-Boot is interrupted, the developer can enter any U-Boot command as described in the U-Boot documentation:
http://www.denx.de/wiki/view/DULG/UBootCommandLineInterface A U-Boot quick reference, easier to read, can be found here:
http://cache.freescale.com/files/32bit/doc/quick_ref_guide/LITE5200BUBPG/LITE5200BUBPG.pdf Although the U-Boot boot loader can be re-installed, replacing U-Boot is not supported nor covered by the Amyuni warranty. This is because replacing the U-Boot requires detailed knowledge of the hardware and frequently leads to the device being disabled. A disabled device cannot be fixed remotely and has to be replaced at the developers cost. The main U-Boot commands that can be useful for Devtouch developers (sll these commands are described in details in the above two links):
bootm [addr [arg ...]] - boot application image stored in memory passing arguments 'arg
...'; when booting a Linux kernel,arg' can be the address of an initrd image fsload - load binary file from a filesystem image
(fsload and bootm work together in order to start the Linux OS) E.g.:
fsload; bootm;
fatload <interface> <dev[:part]> <addr> <filename> [bytes] - load binary file 'filename' from 'dev' on
'interface'to address 'addr' from dos filesystem E.g.:
if fatload usb 0:1 80400000 amyuni_boot.img;then; autoscr 80400000; else; run bootcmd; fi autoscr [addr] - run script starting at addr - A valid autoscr header must be present E.g.:
if fatload usb 0:1 80400000 amyuni_boot.img;then; autoscr 80400000; else; run bootcmd; fi The tool mkimage is needed to create scripts that can be executed using this command. Mkimage is available from devteam@amyuni.com for Windows and Linux upon request. iminfo addr [addr ...] - print header information for application image starting at address 'addr' in memory; this includes verification of the image contents (magic number, header and payload checksums) printenv - print values of all environment variables Page | 10 printenv name - print value of environment variable 'name'
E.g.:
printenv bootcmd run var [...] - run the commands in the environment variable(s) 'var'
E.g.:
setenv aboot "usb start; if fatload usb 0:1 80400000 amyuni_boot.img; then; autoscr 80400000;
else; fsload; bootm; fi"
run aboot setenv - set environment variables saveenv - save environment variables to persistent storage
(all variables set using setenv will be lost upon reboot unless this command is called) sleep - delay execution for some time This instruction can come in handy when switching between a keyboard and a USB key, E.g.:
usb stop 1; echo Plug USB Key (10 secs); sleep 10; usb start; if fatload usb 0:1 80400000 amyuni_boot.img; then; autoscr 80400000;else;run eboot;fi usb start - start USB controller usb reset - reset (rescan) USB controller usb stop 1 - stop USB 1=force stop usb info [dev] - show available USB devices usb read addr blk# cnt - read `cnt' blocks starting at block `blk#' to memory address `addr'
Important note: U-Boot only supports one device connected at the same time (no hubs!) and does not support plugging/unplugging devices on the fly. Call "usb stop 1" before unplugging a device and
"usb start" after plugging another device. E.g.:
usb stop 1; echo Plug USB Key (10 secs); sleep 10; usb start;
Installing the Linux OS Linux installation is done in three steps, first the kernel is loaded with a ramdisk based filesystem, then the kernel is installed into a JFFS2 formatted partition, then the file system is installed to a UBI partition. The DevTouch Pro comes preloaded with kernel 2.6.31 and a default Debian file system. All the needed binary files should be stored on a USB key and a USB keyboard is needed to enter the installation commands. Booting the kernel with a basic ramdisk filesystem:
Enter the U-Boot command prompt while the device is booting. The screen should turn green with the "Devtouch:" prompt. At the prompt, enter:
# load the kernel followed by from the USB key into memory:
Page | 11 fatload usb 0:1 80a00000 uImage; fatload usb 0:1 a0f00000 ramdisk.img;
# configure the linux kernel parameters setenv bootargs "root=/dev/ram0 ramdisk_size=12240 video=pxafb:mode:800x480-
16,pixclock:30066,left:64,right:64,hsynclen:60,upper:19,lower:41,vsynclen:3,active,hsync:0,vsync:0, outputen:1,pixclockpol:0"
#start the linux kernel bootm 80a00000 a0f00000 A few hints:
Because the USB key and the keyboard cannot be plugged-in together at the U-Boot command prompt, the developer should either use a script stored on the USB key and then run the script using the fatload and autoscr commands. Using environment variables to store scripts and executing then using the run command is a powerful feature of U-Boot that can be very useful when installing/updating the OS, e.g.:
setenv aboot "usb stop 1;echo Plug USB Key (10 secs);sleep 10;usb start;if fatload usb 0:1 80400000 amyuni_boot.img;then;autoscr 80400000;else;run eboot;fi"
saveenv run aboot
# set the kernel boot arguments to be used after the Debian setenv bootargs "ubi.mtd=5 root=ubi0:rootfs rootfstype=ubifs Here is a sample complete script:
filesystem is installed console=ttyS2,38499 console=tty0 video=pxafb:mode:800x480-
16,pixclock:30066,left:64,right:64,hsynclen:60,upper:19,lower:41,vsynclen:
3,active,hsync:0,vsync:0,outputen:1,pixclockpol:0"
saveenv echo ==== Launching Linux Updater ====
fatload usb 0:1 80a00000 uImage fatload usb 0:1 a0f00000 ramdisk.img usb stop 1; echo Plugin Keyboard (10 secs);sleep 10;
if iminfo 80a00000 && iminfo a0f00000 then
# reboot under Linux setenv bootdelay 1 setenv bootcmd "fsload;bootm;"
saveenv
# temporary bootargs to activate the ramdisk image setenv bootargs "root=/dev/ram0 ramdisk_size=12240 video=pxafb:mode:800x480-
16,pixclock:30066,left:64,right:64,hsynclen:60,upper:19,lower:41,vsynclen:
3,active,hsync:0,vsync:0,outputen:1,pixclockpol:0"
bootm 80a00000 a0f00000 Page | 12 else fi into USB flash drive echo ********** No valid images found echo ********** Please put valid kernel.img and ramdisk.img The sleep command can be used with the USB Stop/Start commands to switch between the keyboard and the USB key. Login to the Angstrom Linux kernel using the root user (no password) Flash the Linux kernel to the JFFS2 partition At the Linux command prompt, enter:
flash_eraseall /dev/mtd4 nandwrite /dev/mtd4 /media/sda1/amyuni-kernel.jffs2 Note that under Linux, a hub can be used or the keyboard and memory key switched without stopping and restarting the USB interface, which make the developers task easier. Flash the Debian filesystem to a UBI formatted partition:
ubiformat /dev/mtd5 -y -f /media/sda1/debian-image.ubi Reboot under the new OS Calibrating the screen Login as root and enter the following commands:
export TSLIB_TSDEVICE=/dev/input/event0
/usr/bin/ts_calibrate Obtaining Technical Support To obtain technical support, source-code or binaries, the Amyuni Development Team is available at devteam@amyuni.com. Page | 13