Lecture 1

advertisement
COMP 446 / ELEC 446
Mobile Device Applications
Scott Cutler
Professor in the Practice of Computer Technology
Department of Computer Science
Department of Electrical and Computer Engineering
cutler@rice.edu
8/22/12
Wednesday 2-3:30, DH 1046
Goals
 Learn what differentiates programming a Smartphone from other
software development.
 Provide Thorough Exposure to iOS Ecosystem

Apple iPhone / iPad / Xcode / Objective-C
 Cover (but in less detail ~1 lecture each)




Google Android
Windows Phone 8
Web services / HTML / HTML 5 / ASP.NET
SQL Server
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
2
Process
 Learn iOS and Objective-C through a series of small applications
 Leverage an excellent set of online videos to augment a mixture of
lectures and seminars.
 Develop an awareness of the changing factors influencing the
mobile industry.
 Apply this knowledge for a final project taking most of the second
half of the semester
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
3
Many Mobile Application Types
 Dedicated, native mobile application
 iOS (iPhone, iPad, iPod Touch), Android, Windows Phone,
Blackberry, etc.
 Dedicated application calling a web service
 Mobile interface to a heavy lifting server application
 Mobile Web Application
 mobile.google.com, mobile.live.com, mobile.yahoo.com
 iPhone / Safari web application
 Important, but not covered in 446 are Widgets, mobile J2ME or
applications meant for mobile Java browsers. We concentrate
on genuine smartphones.
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
4
PEOPLE
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
5
Who Am I?
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
6
Birth Through High School
New Haven, CT
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
7
MIT
Cambridge, MA
BS
MS
Ph.D.
Zork
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
1973
1973
1976
1979
8
GE Research and Development
Niskayuna, NY
First business use of
PC (TRS-80) in GE
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
9
Tandy Electronics (Radio Shack)
Fort Worth, TX
Deskmate
- First graphical Quicken
- First graphical Lotus
- Foundation for AOL
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
10
Chips and Technologies
San Jose, CA
Wingine Windows Graphics
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
11
Digital Equipment Corporation
Boston, MA
CTO – PC Group
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
12
Compaq
Houston, TX
CTO – PC Group
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
13
Rice University (2001 – Present)
Houston, TX
COMP / ELEC 694
Future Personal Computing Technology
COMP / ELEC 446
Mobile Device Applications
Digital Media
Personal Electronics
Useful Applications
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
14
Who are you?
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
15
Current Roster
 Victor Acuna
 Ryan Artecona
 Gbenga Badipe
 Joel Baranowski
 Peter Chang
 Joan Chao
 Heaven Chen
 Alex Chiu
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
16
Current Roster (2)
 Lingo Dai
 Weibo He
 Sahil Hingorani
 Bill Robertson
 Frank Salinas
 Tyler Siegert
 Austin Witt
 Matthew Zhao
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
17
Course TA
 Richard Latimer
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
18
COMP 446 HISTORY
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
19
History





ELEC 446 started Jan 03 using iPAQs, 802.11b and .Net (1.0) Web Services
 Operating system premature, poor connectivity
Continued a couple more semesters with next version of software, but
connectivity still an issue
COMP 446 cross registered version started fall 05 with emphasis on
smartphones
 Not well organized
 Windows Mobile 3 and GPRS didn’t cut it
Reasonable Internet Connectivity by fall 06
 Beta tools still an issue
2008 was a banner year for Smartphones
 Introduction of the iPhone app store
 Initial shipments of Google’s Android
 Windows Mobile becoming much less relevant
 Wide deployment of 3G networks
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
20
2009
 iTunes App Store a HUGE success
 iPhone remains the smart phone to beat

Limited to AT&T – others wanted iPhone competitor
 Great support for Google Android

Second Generation phones started to come out
 New competition from Palm
 Blackberry and Nokia still holding on to large customer base
 Windows Mobile continues to lose ground – but many have been hurt
counting Microsoft out; particularly in an important area.
 Ecosystem taking smart phones seriously and smart phones starting to
thrive
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
21
2010
 Smartphones everywhere
 iTunes App Store grows

Close to 250K apps

Close to 50K publishers

Approx 375 apps submitted per day

Stats per http://148apps.biz/app-store-metrics/
 iPad released.

Same basic foundation as iPhone and iPod Touch

Incredible growth

Launches new product category – different than all previous tablet attempts
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
22
2010
 2nd Quarter stats: Sales numbers and ranking differ by research study, but
clearly show:


Fast rise by Android platform and modest % rise by iPhone
Decrease in market share from Symbian, RIM and Windows Mobile, Palm
 Android 2.x and various ‘Droid’ devices provide first real competition to
the iPhone.

About 200,000 Android devices being sold every day.
 Palm fades – but is now part of HP – but is HP fading??
 Blackberry not giving up
 Windows Phone 7 announced based on Silverlight and XNA
programming stack
 Strong rumors of Verizon iPhone
 Sprint ships first 4G phone
 New announcements every day
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
23
2011
 Smartphones more the rule than the exception in many environments
 iTunes App Store grows

Close to 460K apps (over 570K have been created)

Over 100K publishers

Approx 744 apps submitted per day

Stats per http://148apps.biz/app-store-metrics/
 iPad 2 released.

Many competitors. None getting any traction
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
24
2012
 iTunes App Store grows

Close to 700K apps (almost 900K have been created)

Over 175K publishers

Stats per http://148apps.biz/app-store-metrics/
 4g iPad
 Google Android dominates sales, but iPhones still seen much more
than Android
 Apple and Samsung by far the dominant manufacturers.
 Blackberry continues to spiral, Palm gone, Nokia still struggles
 Windows Phone gaining respect and momentum; however still a distant
third player
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
25
2009 COMP 446 – iPhone Transition
 Mobile devices proliferating exponentially
 General consensus was that smartphones are for
upper end market only

But that is not the view of a technologist
 Strong desire to teach iPhone app class


I was a Windows, .Net person
Did not know Xcode or iOS
 iTunes University iOS class


Taught by Apple people and at an elite university level
Could handle the heavy lifting language portion of the class
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
26
Results from 2009 Class
 The Good News
 First class to leverage iTunes-U
 9 Students – nice small class 
 Creation of Rice iPhone Application
 Great Evaluations












C-Overall:
C-Organization:
C-Challenge:
C-Assignments:
I-Organization:
I-Presentations:
I-Responsiveness:
I-Atmosphere:
I-Independence:
I-Stimulation:
I-Effectiveness:
I-Responsibility:
SEC - 8/22/12
 The Not as Good News
 C-Workload:
4.00 / 3.01
 I-Knowledge
1.63 / 1.64

Class became very popular
1.00 / 1.93
1.00 / 1.91
1.00 / 1.85
1.38 / 1.95
1.13 / 1.69
1.25 / 1.89
1.13 / 1.69
1.13 / 1.71
1.13 / 1.88
1.13 / 1.71
1.13 / 1.83
1.00 / 1.53
COMP 446 / ELEC 446 - Week 1
27
Results from 2010 Class



2010 Course filled to limit of 10 on first day
Limit raised to 16 on second day, filled in hours
Acquired larger room



More topics to cover in 2010


Registration grew to 22 before first class.
Accepted 5 walk-ins for a total of 27
Some things had to be de-emphasized to make room
Evaluations were good, but markedly worse than 2009.


Far too many people to effectively support
Some students signed up for course because of cancellation of another
specialization course.
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
28
2011 Class
 2011 Course filled to limit of 16 on first day

Limit raised to 17, but only through reclassification of one student

Bipolar reviews. Predominantly outstanding but …


A few students did not at all like the concept of highly leveraging the Stanford videos.
Important takeaway – most undergraduates have not had experience
with SQL and HTML/JavaScript – things that are very important for real
mobile applications.
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
29
Prerequisites
 Formal prerequisites for COMP/ELEC 446 dropped

There are no other courses teaching Xcode, Objective-C, ASP.Net or
other web programming
 Experience from last few years clearly shows need for:

An interest in cool connected mobile devices is a must.


Homework will be satisfying when completed, but will likely take a long time.
Understanding of basic object oriented programming concepts (class,
instance, inheritance, etc.)

SEC - 8/22/12
Without OOP foundation, you will get lost in Objective-C tutorial and likely have trouble
catching up
COMP 446 / ELEC 446 - Week 1
30
Object-Oriented Terms
 Class
- description/template for an object
 Instance
- manifestation of a class
 Message
- sent to objects to make them act
 Method
- code invoked by a Message
 iVar
- object-specific storage
 Inheritance
- code-sharing mechanism
 Super/Subclass - inheritance relationships
 Protocol
- non-class-specific method definition

Source: CS193p Lecture #1
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
31
RESOURCES
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
32
Hardware / Software
 Software: Xcode including iOS simulator
 Note current Xcode version = 4.4.1
 Development Macs
 Students encouraged to get a Mac
 Campus Macs loaded with XCode 4.4.0 software and emulators


User ID: xcode, Password: xcode (will be needed to run developer tools).
Dedicated Mac Mini available for class use via LogMeIn

User ID: COMP446@scottcutler.com, Password given out in class.
 Devices



A few older (personal) iPhones available for student use
2 Windows Phone 7 Device available
A few (old) Motorola Droid (Android) devices are available
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
33
Optional Hardware / Software
 Server (likely not needed by students)
 DiscountASP.Net account, www.comp446.com/ws<Application>
where Application is your application name (e.g.
www.comp446.com/wsAssignments)
 Access to MS SQL Server 2008 located on DiscountASP.Net
 Credentials to be set up and disseminated later if needed.
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
34
Software
 Course Website: www.comp446.com

assignment submission website linked through www.comp446.com
 iPhone Developer Program



iPhone Documentation available at http://developer.apple.com
Students will be enrolled in Rice’s iPhone University Developer’s
Program
You should have already responded to invitations
 Xcode available free on Macs
 iTunes-U and Stanford CS193P resources freely available
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
35
Course Format
 One formal classroom meeting a week
 Round table, project management style
 Likely optional Monday review / Q&A session with TA
 Typical class flow:
 Events of the week
 General discussion / review of previous week’s technology or assignment
 Short lecture on a technology.
 Discussion of current project, future projects and / or next step in current project
 Homework
 6 initial projects; most lasting one week.
 Homework and mandatory videos




Videos must be watched before class
Assignments due Friday at 6:00am (think of it as Thursday at 30:00).
You will have all the resources needed to start early and get ahead.
Final project

SEC - 8/22/12
Topic picked before October 10th class
COMP 446 / ELEC 446 - Week 1
36
iPhone Development Videos
 Leveraging iTunes-U, Stanford University CS193P course.
 Significant homework will be in the form of watching external 1hr videos and their
coordinated exercises.



Experiment when it started three years ago which proved quite effective.


It will be nearly impossible to do the assignments without watching the videos.
Logistics:



Expect 2 full and possibly one optional video per week as well as one application through
the first half of the semester
You will eventually watch all of the CS193P lectures, and do problems up to and including
assignment 6 (although assignment 6 may have a required and an optional component)
iTunes => App Store => iTunes U => Stanford => iPhone Application Programming
Subscribe and download everything from Fall 2011 course offering
http://www.stanford.edu/class/cs193p - Download fall 2011 session available at
http://www.stanford.edu/class/cs193p/cgi-bin/drupal/downloads-2011-fall
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
37
OS X & Xcode version
 OS X Mountain Lion has desirable but not required features
 Developing iOS apps does not require much disk space or GHz
 Large screen not needed but helpful
 University Macs running Lion
 Xcode 4.4 (or 4.4.1) is desired, not required
 Definite improvement over in integration and debugging
 Not materially different than version on videos.
 iTunes videos use Xcode 4.2. Read release notes for differences.
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
38
Optional Sessions and Support
 Sunday or Monday office hours with TA. Schedule to be
determined between class and Richard Latimer.
 Ability to email questions to me at any time.

Can email Richard Latimer as well.
 Level of support will vary over semester



High level of support at the beginning.
Support decreasing each project as over time as knowing
where to look or how to debug is a very important skill for
you to learn.
Richard instructed to respond conceptually – not just provide
solutions.
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
39
SYLLABUS
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
40
Syllabus Overview
 First Half of Semester
 Pedagogical approach to iPhone programming through a series of
lectures and assignments that build on each other
 Mandatory iTunes-U lectures covering basic iOS functionality
 Second Half of Semester
 Dominated by one large project.


Students choose projects, platforms


Typically solo final projects.
There will be significant guidelines and possibly suggested projects
Optional videos covering subjects of general interest to all, but
specific interest only to those working the technology
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
41
COMP 446 (tentative) Syllabus

Lecture 1 - 8/22/12 - Introduction








1, 2
#2 – Function Calculator
Friday, 9/7 6:00 am (Thursday 30:00)
Watch before:
Assignment:
Assignment due:
3, 4 (demo part)
#3 – Graphing Universal Calculator
Tuesday, 9/18 6:00 am (Thursday 30:00)
Lecture 4 - 9/12/12 - Assignment 3 issues and questions from videos




Watch before:
Assignment:
Assignment due:
Lecture 3 - 9/05/12 - Assignment 2 issues and questions from videos


None
#1 - Calculator
Friday, 8/31 6:00 am (Thursday 30:00)
Lecture 2 - 8/29/12- Assignment 1 issues and questions from videos


Watch before:
Assignment:
Assignment due:
Watch before:
Assignment:
Assignment due:
4 (post demo), 5, 6
Continue with #3 – Graphing Universal Calculator
Tuesday, 9/18 6:00 am (Monday 30:00)
Lecture 5 - 9/19/12 - Assignment 3 issues and questions from videos



Watch before:
Assignment:
Assignment due:
SEC - 8/22/12
Watch 7 before class, 8 after class
#4 – Fiickr Top Places
Friday, 9/28 6:00 am (Thursday 30:00)
COMP 446 / ELEC 446 - Week 1
42
COMP 446 (tentative) Syllabus

Lecture 6 - 9/26/12 - Assignment 4 issues and questions from videos





Watch before:
Assignment:

Assignment due:
10 (after Tab Bar), 11, 12
1: #6 – Fiickr Core Data
- Likely to be broken into required and optional parts
- Optional part required for A+
2: Final Project Topic (due before next class)
Friday, 10/12 6:00 am (Thursday 30:00)
Lecture 8 - 10/10/12 - Assignment 6 issues and SQL




8, 9 very beginning of 10
#5 – Fiickr Map Places
Friday, 10/5 6:00 am (Thursday 30:00)
Lecture 7 - 10/03/12 - Assignment 5 issues and questions from videos


Watch before:
Assignment:
Assignment due:
Watch before:
Assignment:
Assignment due:
13, 14
Final Project Proposal
Tuesday, 10/16 6:00 am (Monday 30:00)
Lecture 9 - 10/17/12 - iOS 6



Watch before:
Assignment:
Assignment due:
SEC - 8/22/12
Optional 15, 16
iOS 6 app
Friday, 10/26 6:00 am (Thursday 30:00)
COMP 446 / ELEC 446 - Week 1
43
COMP 446 (tentative) Syllabus

Lecture 10 - 10/24/12 – HTML 5







Assignment:
Assignment due:
Continue working on Final Project
Wednesday, 11/28 2:00pm
Assignment:
Assignment due:
Continue working on Final Project
Wednesday, 11/28 2:00pm
Lecture 14 - 11/21/12 – No class, but continue on final project



Continue working on Final Project
Wednesday, 11/28 2:00pm
Lecture 13 - 11/14/12 - Individual meetings on Final Project


Assignment:
Assignment due:
Lecture 12 - 11/7/12- Android vs. iOS vs. Windows Phone group debate


Optional 17, 18
Major Final Project Feature
Friday, 11/2 6:00 am (Thursday 30:00)
Lecture 11 - 10/31/12 - TBD


Watch before:
Assignment:
Assignment due:
Assignment:
Assignment due:
Continue working on Final Project
Wednesday, 11/28 2:00pm
Lecture 15 - 11/28/12 - Final Presentations


Assignment:
Assignment due:
SEC - 8/22/12
Document Final Project
By time assigned for COMP 446 final (there is NO final exam)
COMP 446 / ELEC 446 - Week 1
44
Final Project
 To be determined by 8th class
 Can target iOS, Android or WP device
 Proposal submitted by 10/10/12
 Full Spec 10/17/12
 Various milestones including presentation to class on 11/28/12
 Final code for project incorporating comments from presentation
due on the official finals date of the course.
 This is VERY important: If you do not have a great project
definition, the 2nd half of the course will suffer. With a great project,
this will be an exciting course.
 Great if your project could have life after the class finishes
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
45
Differences from 2011
 Major pedagogical stumbling blocks from last
year’s course addressed by iOS 5 changes



Memory Management
Life cycle flow
Object oriented database integration
 Strong desire to provide HTML 5 and related
ecosystem exposure


Not really covered in any other course
Kind of super important for any CS person
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
46
Grading
 20% Class participation
 30% Assignments other than the final project
 50% Final Project




10% Project Specification
10% Major Features complete
10% Presentation to the class
20% Overall project as demonstrated by final code
 Assignment #6 will likely have optional elements
required for potential A+
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
47
Expectations
 Have Fun
 I will provide some toys, hardware and software –
make something of it
 Energy beyond one meeting a week


Don’t wait until the night before class to start assignments–
you will not succeed
Team and sub-team meetings on your own
 Please remember that this is still an experimental
class format and mobile technology changes quickly


Things WILL shift as we go along
Feedback highly encouraged
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
48
Week 2
 Watch CS193p lectures #1 and #2

Preferably before Saturday. Definitely before next class.
 Complete CS193p Assignments #1, #1 Walkthrough

Try and complete before next class. Due shortly after next class.
 Submit assignments, review lectures at www.comp446.com
 Start thinking about big project
 Really – start thinking about big project!
 Next week’s lecture – mostly review of first videos and intro to
Objective-C.
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
49
Is COMP 446 for You?
 Do you agree with benefits of the COMP 446 format?
 Lectures, projects and most importantly leveraging the iTunes CS193P
videos
 Are you prepare to spend at least 10 hours a week on the initial
projects?


Are you the sort who really enjoys getting a program to work?
Do you have the time in your schedule?
 Some do not understand or like the format
 If this is you, drop this course and learn iOS from books or iTunes-U
 Most COMP 446 students strongly say yes
 If this is you, you will have a great time in COMP 446
SEC - 8/22/12
COMP 446 / ELEC 446 - Week 1
50
Discussion
Download