teaching machines

CS 491 Lecture 17 – Falling Math

Agenda issue camera and gallery intents recognize speech write a custom speech recognizer write a gesture recognizer Falling Math Our next app will satisfy several of your requests from your apps wish list: a Space Invaders game, incorporation of novel mobile hardware, and some 2-D drawing stuff (though not much). What’s the app? Well, mathematical […]

CS 491 Lecture 16 – Wevents Part V

Agenda Post-haste I never got notes written when this post was first published. These are being written two months later. They won’t flow. Flushing remote changes When a user changes a calendar event, we always commit it to the local database first. This caching scheme is called writeback; we make our changes to the cache […]

CS 145 Lecture 15 – More colliding

Agenda meet JFrame and company collide circles collide rectangles Code CollisionUtilities.java package lecture; import java.io.File; import java.io.FileNotFoundException; import java.util.Scanner; public class CollisionUtilities { public static void main(String[] args) throws FileNotFoundException { Scanner in = new Scanner(new File(“/home/cjohnson/Desktop/lines.txt”)); while (in.hasNextDouble()) { double leftA = in.nextDouble(); double rightA = in.nextDouble(); double leftB = in.nextDouble(); double rightB = […]

CS 145 Lecture 14 – Testing and conditionals via collision detection

Agenda lab switcharoo collision detection test-driven development Collision detection Code CollisionUtilities.java package lecture; import java.io.File; import java.io.FileNotFoundException; import java.util.Scanner; public class CollisionUtilities { public static void main(String[] args) throws FileNotFoundException { Scanner in = new Scanner(new File(“/home/cjohnson/Desktop/lines.txt”)); while (in.hasNextDouble()) { double leftA = in.nextDouble(); double rightA = in.nextDouble(); double leftB = in.nextDouble(); double rightB = […]

CS 491 Lecture 15 – Wevents Part IV

Agenda schedule mobile OS talks inserting and editing adding a cache marshalling compound data detecting a network connection pushing changes Problem We mentioned last time that the advantage of an IntentService + ResultReceiver over an AsyncTask is only seen when the background task does more than update the UI, like maintain a local cache. Such […]

Project configuration

While waiting to hear back from ORSP, we are taking the time to find a sustainable solution for managing our project across multiple platforms and machines. We really want to share code without emailing it. We also want to avoid fiddling with Visual Studio as much as possible. For this, we’ve chosen to use TortoiseSVN […]

CS 491 Lecture 14 – Wevents Part III

Agenda write an AsyncTask AsyncTask vs. IntentService + ResultReceiver handling ResultReceiver configuration changes saving instance state adding a ListActivity hello, JSON add events AsyncTask In these days of big data, complex computation, and networks, we have need to perform background tasks whose results affect the UI. As UI stuff can only be done on the […]

CS 145 Lecture 13 – Loop tricks

Agenda which loop when? conditioning on sentinel values fencepost loops nested loops Code ForAWhile.java package lecture; import java.util.Scanner; public class ForAWhile { public static void main(String[] args) { // String command = “notdone”; // for (Scanner in = new Scanner(System.in); !command.equals(“done”); command = in.next()) { // } String command = “notdone”; Scanner in = new […]

CS 145 Lab 7

Reminder Show your completed lab 6 checkpoints to your instructor or TA in the first 20 minutes of this lab. All code for this lab should go in a package named lab7. Cards Each of today’s problems involves a deck of cards. Though we use card terminology, you do not need to have ever touched […]

CS 145 Exam 1

Exam 5-point summaries of individual question and overall scores.

1 197 198 199 200 201 204