I am doing things a bit out of sequence - I'm going to complete course module 9 on smartphone programming before module 8 which deals with register level programming of a Cortex-A9 application processor. The reason that I'm doing that is that I probably will never do low level programming of a smartphone. That type of programming is normally required to write driver code or to do performance optimization. The coding requires using Arm Development Studio and the lab exercise is done on a simulator rather than a real smartphone. I think it is valuable to learn Arm Development Studio so I'll do module 8 at the end of the course. I've actually completed the lecture, just haven't done the lab exercise.
Course module 9 provides an overview of smartphone components and details which Arm processor models are used for the different hardware components. Then it discusses mobile OSs and Android in particular and describes Android program development.
Arm processor use for smartphone hardware
- Application processor - Cortex-A
- Memory controller - Cortex-M
- RF chip - Cortex-R
- Power management chip - Cortex-M
- GPS receiver - Cortex-M
- Subscriber Identity Module (SIM) - SecureCore
- Bluetooth - Cortex-M
The manifest file is contains the detailed description of the application components, requirements, and permissions.
Lab6 Exercise - Create application in Android Studio and deploy to smartphone
- Install Java JDK - I already use Java so I have it installed
- Install Android Studio - this is free but a large (1GB) download
- Install Android USB driver - included with Android Studio but installed separately
- Enable USB debugging - this is done on phone/tablet - need to enable developer mode and enable debug on first use
One thing that I should note is that the lab example is quite dated. The version of Studio shown in the lab video is 1.1.0 and the latest version that I downloaded is 3.4.1. Their phone target is a Nexus 5 with a minimum OS level of 4.4. I am using a 6 year old Nexus 7 tablet and I'm running Android 6.0. The good news is that none of this caused any problems.
Android Studio seems fairly straightforward other than trying to figure what all the various icons represent and which view you should be using. This is a tool that I've been wanting to use for quite a while, so I'm glad that this course pushed me into it. Now just have to get up the learning curve. The lab takes you through creating, building, and deploying the app and also running the debugger.
The application developed in the lab exercise is fairly simple. A single button is created and the button callback function just prints a temporary textbox with the text "Hello from button!" when the button is pressed. Below is the screenshot from my tablet.