9.2DevelopmentTools
ApplicationsarewrittenintheJavalanguage,butcompiledandexecutedintheDalvikVM(anon-Javavirtual
machine).OncetheJavacodeiscompiledcleanly,thedevelopertoolsmakesuretheapplicationispackaged
properly,includingtheAndroidManifest.xmlle.
ThedevelopmentSDKisdistributedasaZIPlethatunpackstoadirectoryonthehostcomputerharddrive.
TheSDKincludes:
•android.jar
–JavaarchivelecontainingallofthedevelopmentSDKclassesnecessarytobuildanapplication.
•documention.htmlanddocsdirectory
–TheSDKdocumentationisprovidedlocallyandontheWeb.It'slargelyintheformofJavaDocs,makingit
easytonavigatethemanypackagesintheSDK.Thedocumentationalsoincludesahigh-levelDevelopment
Guideandlinkstothebroadercommunity.
•Samplesdirectory
–Thesamplessubdirectorycontainsfullsourcecodeforavarietyofapplications,includingApiDemo,
whichexercisesmanyAPIs.Thesampleapplicationisagreatplacetoexplorewhenstartingapplication
development.
•Toolsdirectory
–Containsallofthecommand-linetoolstobuildapplications.Themostcommonlyemployedandusefultool
istheadbutility.
•usb_driver
–Directorycontainingthenecessarydriverstoconnectthedevelopmentenvironmenttoanenableddevice.
TheselesareonlyrequiredfordevelopersusingtheWindowsplatform.
OpenstheDeveloperoptionsscreentosetdevelopmentrelatedsettings.
Touch>Developeroptions.SlidetheswitchtotheONpositiontoenabledeveloperoptions.The
followingdeveloperoptionsareavailable:
•Desktopbackuppassword
•Stayawake
•ProtectSDcard
•Debugging
–USBdebugging
–Selectdebugapp
–Wakefordebugger
•Input
–Showtouches
–Pointerlocation
•Drawing
–Showlayoutbounds
–ShowGPUviewupdates
–Showsurfaceupdates
–Windowanimationscale
–Transitionanimationscale
MN000112A01-September2013
9-3