SSP ROBOT DESIGN A. DEAN 11/29/05 LAB: ROBOT OBJECTS IN LEJOS
|
|
- Bartholomew Baker
- 6 years ago
- Views:
Transcription
1 SSP ROBOT DESIGN A. DEAN 11/29/05 LAB: ROBOT OBJECTS IN LEJOS As we saw in class last Tuesday (well, as at least a few of us saw the rest should check the web for the slides), everything in Java is based on objects. A quick review before you start the lab: An object has both data and methods (functions), sometimes one but not the other. An object must first be defined. This is what the class structure does. So each program we write is actually considered an object. Some objects have been predefined in a Java or lejos library that we import at the beginning of our program. For us the most important library is josx.platform.rcx, which contains all the robot object classes, but there are two others we may also use, java.lang (for math functions and other stuff) and java.util (for random numbers and other stuff). The predefined robot objects include the motors, the various sensors, the buttons on the RCX (except for the on/off button), and the LCD display on the RCX. In this lab you ll focus on the motor and sensor objects. PART 0 STARTING UP For this lab you will need your TankBot, and you ll be using both JCreator and the web, so please start up JCreator and Internet Explorer. You should also open a browser window, in which you should open your folder on Datastor. Create a new folder in there named lejos_programs. PART 1 THE Motor OBJECT 1. In Internet Explorer, open the website (From the SourceForge website: SourceForge.net is the world's largest Open Source software development web site, hosting more than 100,000 projects and over 1,000,000 registered users. ). 2. The website you ve opened is the home page for lejos. On the left are nine yellow buttons click the one named API (an acronym for Application Programming Interface). This brings you to a page where you can find all the predefined objects in lejos, and descriptions of their data and methods. 3. In the lower left window, scroll down and click on Motor. The large right-hand window now displays information and examples about the Motor class. As you scroll down this window, you see a short table named Field Summary, which gives the names of the three specific motor objects, A, B, and C. Below that is the table Method Summary, which lists all the methods (functions) that can be used by the Motor object. Finally, beneath these two tables are detailed descriptions of both the fields and each of the methods. 4. We want to create a new Java program, to try out using the Motor object, but here s a simpler way than creating (or finding) a workspace and project, as we did in the last Page 1 of 5
2 lejos lab. Check that the File View window on the upper left says No workspace loaded. If a workspace is loaded, then go to the File menu and select Close All Workspaces. 5. Now select File-New File, and a window will come up. For the name, enter MotorFunctions. For the location, click on the button at the right and find the folder you created in Part 0, named lejos_programs. Click Finish, and JCreator will set up a default workspace and open an editing window for your program. 6. Recall that every Java program must contain a class with the same name as the file. Type in the following code, remembering that when you type a left curly bracket, JCreator automatically types the right for you. After you type it in, use tool number 1 to compile it so you know there are no errors. Don t use tool #2 to download it yet: import josx.platform.rcx.*; public class MotorFunctions public static void main(string[] args) 7. We are going to add some void functions to make the robot move in different directions, as a way of seeing how to use some of the Motor class methods. Underneath the main function, but still inside the class MotorFunctions, add the following void function. Again, compile using tool #1: public static void goforward(int msecs) Motor.A.forward(); Motor.C.forward(); Thread.sleep(msecs); Note: The Thread.sleep() method requires any function that uses it, directly or indirectly, to throw and interrupted exception. Page 2 of 5
3 8. Finally, add the following single line to main: goforward(2500); Then compile and download the function. Your robot should go forward for 2.5 seconds, because the units for the Thread.sleep() method are in milliseconds. 9. Add a function gobackward(), similar to goforward() (feel free to copy and paste!), and modify the main function so that the robot goes forward for 3.2 seconds and backwards for 2.3 seconds. Look in the API for the Motor methods that you need to do this. By the way, you can use motors without using void functions by simply typing commands such as Motor.A.forward() directly into the main function. I wanted you to see the use of void functions in Java, as well as trying out the Motor class. PART 2 The Sensor Object: using a touch sensor 1. In Internet Explorer, scroll down the left window to Sensor, and then look over the information that comes up in the main window. The first thing you may notice is that, just as Motor has fields A, B, and C, the object Sensor has fields S1, S2, and S3. Using sensors is more complicated than using motors, and using sensors in lejos is more complicated than using sensors in NQC, so we ll learn about them in stages. Now look at the class SensorConstants, which contains the constants we ll need to set type and mode. 2. Without closing your MotorFunctions program, create a new program named TouchSensor, typing in the basic shell much as in step 6 of Part 1. Feel free to copy and paste from the other program, by clicking its tab at the top of the editing screen, but be sure to change the name. 3. As in NQC, we must set the type and mode of a sensor before we can use it. In order to use the SensorConstant names, you must modify the name of your program as follows: public class TouchSensor implements SensorConstants Inside the main function type the following lines, which configure sensor 1 as a touch sensor in bool mode (i.e., 0 or 1). Compile and run it to test it: Page 3 of 5
4 Sensor.S1.setTypeAndMode (SENSOR_TYPE_TOUCH, SENSOR_MODE_BOOL); while (true) int val = Sensor.S1.readValue(); if (val == 1) Sound.beepSequence(); else if (val == 0) Sound.buzz(); else Sound.twoBeeps(); //Wait a second before checking sensor again Thread.sleep(1000); 4. Now change the sensor mode to RAW. Recall that the range of raw mode is 0 to 1023 with lower numbers corresponding to harder press than higher numbers. See if you can modify the program so it can use the sounds to distinguish between no touch, medium touch, and hard touch. (For me, using 50 for hard, between 50 and 300 for medium, and above 300 for no touch, worked pretty well.) PART 3 The Sensor Object: using a light sensor 1. Now create another new file named LightSensor, and type in the following code, which is quite similar to the code in TouchSensor, but with at least one important difference. If you cut and paste, be sure to make all the appropriate changes: Page 4 of 5
5 import josx.platform.rcx.*; public class LightSensor implements SensorConstants public static void main(string[] args) Sensor.S2.setTypeAndMode (SENSOR_TYPE_LIGHT, SENSOR_MODE_PCT); Sensor.S2.activate(); while (true) int val = Sensor.S2.readValue(); if (val >= 40) Sound.beepSequence(); else Sound.buzz(); //Wait a second before checking sensor again Thread.sleep(1000); 2. This program uses a touch sensor on port 2, in percent mode (values from 0 to 100, with 0 dark and 100 bright). Note the extra line: Sensor.S2.activate(); Unlike the touch sensor, the light sensor requires electricity to operate, since it emits light and measures the reflected light to detect bright and dark. Compile and run this program. PART 4 PUTTING IT ALL TOGETHER If time permits, do the following exercises, which use both the sensors and the motors. 1. Write a program LineFollower, that does just that, using a light sensor. 2. Write a program that goes forward unless the robot runs into a wall, in which case it backs up, makes a left turn and goes forward again. That s plenty for today! Page 5 of 5
Robotic Behaviors What makes a robot a robot? It is the ability of the robot to independently accomplish complex tasks. Being able to independently
Robotic Behaviors What makes a robot a robot? It is the ability of the robot to independently accomplish complex tasks. Being able to independently do things is commonly thought of as a sign of intelligence.
More informationRelationship of class to object
Relationship of class to object Writing and programming Writing a program is similar to many other kinds of writing. The purpose of any kind of writing is to take your thoughts and let other people see
More informationPROGRAMMING ROBOTS AN ABSTRACT VIEW
ROBOTICS AND AUTONOMOUS SYSTEMS Simon Parsons Department of Computer Science University of Liverpool LECTURE 3 comp329-2013-parsons-lect03 2/50 Today Before the labs start on Monday, we will look a bit
More informationToday. Robotics and Autonomous Systems. The scenario (again) Basic control loop
Today Robotics and Autonomous Systems Lecture 3 Programming robots Richard Williams Department of Computer Science University of Liverpool Before the labs start on Monday, we will look a bit at programming
More informationCS 177 Week 5 Recitation Slides. Loops
CS 177 Week 5 Recitation Slides Loops 1 Announcements Project 1 due tonight at 9PM because of evac. Project 2 is posted and is due on Oct. 8th 9pm Exam 1 Wednesday Sept 30 6:30 7:20 PM Please see class
More informationLego Robots and Software Design. CITS1220 Software Engineering
Lego Robots and Software Design CITS1220 Software Engineering Lecture Overview 1. Designing NXT Robots 2. NXT Hardware 3. Sensors and Actuator API 4. The Behaviour Interface 2 Software Design is a problem-solving
More informationToday. Robotics and Autonomous Systems. Today. Communication on the NXT. Lecture 14: Communication and other useful things.
Today Robotics and Autonomous Systems Lecture 14: Communication and other useful things Richard Williams Department of Computer Science University of Liverpool We will cover things from all parts of robotics
More informationRobotics and Autonomous Systems
Robotics and Autonomous Systems Lecture 14: Communication and other useful things Simon Parsons Department of Computer Science University of Liverpool 1 / 43 Today We will cover things from all parts of
More informationCOMMUNICATION AND OTHER USEFUL THINGS
ROBOTICS AND AUTONOMOUS SYSTEMS Simon Parsons Department of Computer Science University of Liverpool LECTURE 14 comp329-2013-parsons-lect14 2/42 Today We will cover things from all parts of robotics COMMUNICATION
More informationJava using LEGO Mindstorms and LeJOS. University of Idaho
Java using LEGO Mindstorms and LeJOS University of Idaho 2 Contents 1 Introduction 1 1.1 Setting up Java and Eclipse................................ 1 1.2 Setting up the Lego Brick to work with LeJOS.....................
More informationINTRODUCTION TO ARTIFICIAL INTELLIGENCE
DATA15001 INTRODUCTION TO ARTIFICIAL INTELLIGENCE THE FINAL EPISODE (11): ROBOTICS TODAY S MENU 1. "GRAND CHALLENGE" 2. LEGO MIND- STORMS 3. ROBO WORKSHOPS ROBOTICS AS A "GRAND CHALLENGE" OF AI actuators:
More informationAgreement. Objectives. General Guidelines for Labs. Reading Assignment
1 CMPSC 111 Introduction to Computer Science I Fall 2016 Janyl Jumadinova Lab 9 for Section 1 17 November 2016 Due: 1 December, by 2:30 pm This is a team-based assignment. You have to work in teams of
More information5.6 Rational Equations
5.6 Rational Equations Now that we have a good handle on all of the various operations on rational expressions, we want to turn our attention to solving equations that contain rational expressions. The
More informationIntro to Programming the Lego Robots
Intro to Programming the Lego Robots Hello Byng Roboticists! I'm writing this introductory guide will teach you the basic commands to control your Lego NXT Robots. Keep in mind there are many more commands
More informationProgramming Techniques Workshop for Mindstorms EV3. Opening doors to the worlds of science and technology for Oregon s youth
Oregon Robotics Tournament and Outreach Program Programming Techniques Workshop for Mindstorms EV3 2018 Opening doors to the worlds of science and technology for Oregon s youth 1 Instructor Contacts Terry
More informationBaggage Sorting Facility
02224 Modelling and Analysis of Real-Time Systems Spring 2018 1 Overview Mandatory Assignment 1 Baggage Sorting Facility This assignment deals with a baggage sorting facility such as the ones found in
More informationEQ-ROBO Programming : Ladybird Robot
EQ-ROBO Programming : Ladybird Robot Program begin Input port setting Output port setting a b Robot goes forward if there is no obstacle in front of robot. If the robot detect the obstacle in front side
More informationRTMS - Software Setup
RTMS - Software Setup These instructions are for setting up the RTMS (Robot Tracking & Management System) software. This software will run on your PC/MAC and will be used for various labs in order to allow
More informationIntroduction to Robots and the Mind - Programming Basics -
Introduction to Robots and the Mind - Programming Basics - Bert Wachsmuth & Michael Vigorito Seton Hall University Programming Groups Albrecht Brittney & Lino Jennifer Bie Jennifer & Guida David & De Clerico
More informationPatterns, frameworks & Lejos: part 1: Behavior control
Patterns, frameworks & Lejos: part 1: Behavior control How robots are like insects Insects are highly successful in the world, managing to perform the necessary functions of life despite the fact that
More informationRobotics and Autonomous Systems
1 / 38 Robotics and Autonomous Systems Lecture 10: Threads and Multitasking Robots Simon Parsons Department of Computer Science University of Liverpool 2 / 38 Today Some more programming techniques that
More informationMobile Agents. Uwe Lämmel. Hochschule Wismar Wismar University of Technology, Business, and Design Business School. Mobile Agents LEGO RCX -1 -
Mobile Agents Hochschule Wismar Wismar University of Technology, Business, and Design Business School u.laemmel@wi.hs-wismar.de www.wi.hs-wismar.de/~laemmel/ -1 - Contents RCX-LEGO-Robot: The Hardware
More informationRCX Tutorial. Commands Sensor Watchers Stack Controllers My Commands
RCX Tutorial Commands Sensor Watchers Stack Controllers My Commands The following is a list of commands available to you for programming the robot (See advanced below) On Turns motors (connected to ports
More informationLaboratory 1: Eclipse and Karel the Robot
Math 121: Introduction to Computing Handout #2 Laboratory 1: Eclipse and Karel the Robot Your first laboratory task is to use the Eclipse IDE framework ( integrated development environment, and the d also
More informationLesson 10: Quiz #1 and Getting User Input (W03D2)
Lesson 10: Quiz #1 and Getting User Input (W03D2) Balboa High School Michael Ferraro September 1, 2015 1 / 13 Do Now: Prep GitHub Repo for PS #1 You ll need to submit the 5.2 solution on the paper form
More informationCOMP 202 Java in one week
COMP 202 Java in one week... Continued CONTENTS: Return to material from previous lecture At-home programming exercises Please Do Ask Questions It's perfectly normal not to understand everything Most of
More informationTHREADS AND MULTITASKING ROBOTS
ROBOTICS AND AUTONOMOUS SYSTEMS Simon Parsons Department of Computer Science University of Liverpool LECTURE 10 comp329-2013-parsons-lect10 2/37 Today Some more programming techniques that will be helpful
More informationROBOTICS AND AUTONOMOUS SYSTEMS
ROBOTICS AND AUTONOMOUS SYSTEMS Simon Parsons Department of Computer Science University of Liverpool LECTURE 10 THREADS AND MULTITASKING ROBOTS comp329-2013-parsons-lect10 2/37 Today Some more programming
More informationBASIC COMPUTATION. public static void main(string [] args) Fundamentals of Computer Science I
BASIC COMPUTATION x public static void main(string [] args) Fundamentals of Computer Science I Outline Using Eclipse Data Types Variables Primitive and Class Data Types Expressions Declaration Assignment
More informationChapter Two Bonus Lesson: JavaDoc
We ve already talked about adding simple comments to your source code. The JDK actually supports more meaningful comments as well. If you add specially-formatted comments, you can then use a tool called
More informationIntroduction to Internet of Things Prof. Sudip Misra Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur
Introduction to Internet of Things Prof. Sudip Misra Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur Lecture - 23 Introduction to Arduino- II Hi. Now, we will continue
More informationLesson 12: OOP #2, Accessor Methods (W03D4)
Lesson 12: OOP #2, Accessor Methods (W03D4) Balboa High School Michael Ferraro September 3, 2015 1 / 29 Do Now In your driver class from last class, create another new Person object with these characteristics:
More informationCoding Workshop. Learning to Program with an Arduino. Lecture Notes. Programming Introduction Values Assignment Arithmetic.
Coding Workshop Learning to Program with an Arduino Lecture Notes Table of Contents Programming ntroduction Values Assignment Arithmetic Control Tests f Blocks For Blocks Functions Arduino Main Functions
More informationMidterms Save the Dates!
University of British Columbia CPSC 111, Intro to Computation Alan J. Hu (Using the Scanner and String Classes) Anatomy of a Java Program Readings This Week s Reading: Ch 3.1-3.8 (Major conceptual jump
More informationName: Checked: Access the Java API at the link above. Why is it abbreviated to Java SE (what does the SE stand for)?
Lab 6 Name: Checked: Objectives: Learn about the Java API Test code snippets interactively to explore data representation and casts Practice using Math, Random, String, and other classes from the Java
More informationEV3 Programming Workshop for FLL Coaches
EV3 Programming Workshop for FLL Coaches Tony Ayad 2017 Outline This workshop is intended for FLL coaches who are interested in learning about Mindstorms EV3 programming language. Programming EV3 Controller
More information- 1 - Handout #33 March 14, 2014 JAR Files. CS106A Winter
CS106A Winter 2013-2014 Handout #33 March 14, 2014 JAR Files Handout by Eric Roberts, Mehran Sahami, and Brandon Burr Now that you ve written all these wonderful programs, wouldn t it be great if you could
More informationThe name of our class will be Yo. Type that in where it says Class Name. Don t hit the OK button yet.
Mr G s Java Jive #2: Yo! Our First Program With this handout you ll write your first program, which we ll call Yo. Programs, Classes, and Objects, Oh My! People regularly refer to Java as a language that
More informationCOMP327 Mobile Computing Session:
COMP327 Mobile Computing Session: 2018-2019 Lecture Set 5a - + Comments on Lab Work & Assignments [ last updated: 22 October 2018 ] 1 In these Slides... We will cover... Additional Swift 4 features Any
More informationHi. I m a three. I m always a three. I never ever change. That s why I m a constant.
Lesson 1-1: 1 1: Evaluating Expressions Hi. I m a three. I m always a three. I never ever change. That s why I m a constant. 3 Real life changes, though. So to talk about real life, math needs things that
More informationEven though we created a folder for the workspace, we still have to let JCreator do the same. So click File, New, and then Blank Workspace.
Getting Started With JCreator The first thing to do with JCreator is to create a workspace. A workspace is an area where you can store a project or a set of related projects. For me, the best way to create
More informationExperiment 7: Robotics++ V3 Robot BlueToothbot
Experiment 7: Robotics++ V3 Robot BlueToothbot 1 Two different ways to control your robot via Bluetooth 1. Android phone wire your robot, download apps from the Google Play Store or install an APK (app
More informationCOMP 250 Winter 2011 Reading: Java background January 5, 2011
Almost all of you have taken COMP 202 or equivalent, so I am assuming that you are familiar with the basic techniques and definitions of Java covered in that course. Those of you who have not taken a COMP
More informationHTML/CSS Lesson Plans
HTML/CSS Lesson Plans Course Outline 8 lessons x 1 hour Class size: 15-25 students Age: 10-12 years Requirements Computer for each student (or pair) and a classroom projector Pencil and paper Internet
More information6.S189 Homework 1. What to turn in. Exercise 1.1 Installing Python. Exercise 1.2 Hello, world!
6.S189 Homework 1 http://web.mit.edu/6.189/www/materials.html What to turn in Do the warm-up problems for Days 1 & 2 on the online tutor. Complete the problems below on your computer and get a checkoff
More informationLab - Task Manager in Windows 8
Lab - Task Manager in Windows 8 Introduction In this lab, you will explore Task Manager and manage processes from within Task Manager. Recommended Equipment The following equipment is required for this
More informationInf1-OOP. OOP Exam Review. Perdita Stevens, adapting earlier version by Ewan Klein. March 16, School of Informatics
Inf1-OOP OOP Exam Review Perdita Stevens, adapting earlier version by Ewan Klein School of Informatics March 16, 2015 Overview Overview of examinable material: Lectures Topics S&W sections Week 1 Compilation,
More informationLesson 5C MyClass Methods. By John B. Owen All rights reserved 2011, revised 2014
Lesson 5C MyClass Methods By John B. Owen All rights reserved 2011, revised 2014 Table of Contents Objectives Defining your own class Defining and calling a static method Method structure String return
More informationCS 152: Data Structures with Java Hello World with the IntelliJ IDE
CS 152: Data Structures with Java Hello World with the IntelliJ IDE Instructor: Joel Castellanos e-mail: joel.unm.edu Web: http://cs.unm.edu/~joel/ Office: Electrical and Computer Engineering building
More informationComputers for Beginners. Tuesday, July 7, p.m. Instructor: Anne Swanson
Computers for Beginners Tuesday, July 7, 2015 2-4 p.m. Instructor: Anne Swanson If you are new to computers, it can be difficult to start because many people have grown up with them and there isn t always
More informationCOMPUTER FOR BEGINNERS
COMPUTER FOR BEGINNERS INTRODUCTION Class Objective: This class will familiarize you with using computers. By the end of the session you will be familiar with: Starting programs Quitting programs Saving
More informationRobotics and Autonomous Systems
Robotics and Autonomous Systems Lecture 13: Navigation in LeJOS Richard Williams Department of Computer Science University of Liverpool 1 / 40 Today From navigation to motion control. 2 / 40 Navigation
More informationName: Checked: Access the Java API at the link above. Why is it abbreviated to Java SE (what does the SE stand for)?
Lab 5 Name: Checked: Objectives: Learn about the Java API Practice using Math, Random, String, and other classes from the Java API Practice writing code to do basic String processing Preparation: Complete
More informationJava Programming Constructs Java Programming 2 Lesson 1
Java Programming Constructs Java Programming 2 Lesson 1 Course Objectives Welcome to OST's Java 2 course! In this course, you'll learn more in-depth concepts and syntax of the Java Programming language.
More informationTutorials. Inf1-OP. Learning Outcomes for this week. A Foundation for Programming. Conditionals and Loops 1
Tutorials Inf1-OP Conditionals and Loops 1 Volker Seeker, adapting earlier version by Perdita Stevens and Ewan Klein Start this week please let the ITO know if you need to switch tutorial groups. Labs
More informationJava Bytecode (binary file)
Java is Compiled Unlike Python, which is an interpreted langauge, Java code is compiled. In Java, a compiler reads in a Java source file (the code that we write), and it translates that code into bytecode.
More informationLast Time. University of British Columbia CPSC 111, Intro to Computation Alan J. Hu. Readings
University of British Columbia CPSC 111, Intro to Computation Alan J. Hu Writing a Simple Java Program Intro to Variables Readings Your textbook is Big Java (3rd Ed). This Week s Reading: Ch 2.1-2.5, Ch
More informationIntermediate Programming, Spring Misha Kazhdan
600.120 Intermediate Programming, Spring 2017 Misha Kazhdan Outline Unix/Linux command line Basics of the Emacs editor Compiling and running a simple C program Cloning a repository Connecting to ugrad
More informationintroduction to RoboCupJunior Rescue vocabulary materials
robotics.edu agents lab, Brooklyn College, CUNY c 2007 http://agents.sci.brooklyn.cuny.edu/robotics.edu introduction to RoboCupJunior Rescue Name: vocabulary task multi-tasking hardware conflicts obstacle
More informationSchool of Computer Science CPS109 Course Notes 5 Alexander Ferworn Updated Fall 15
Table of Contents 1 INTRODUCTION... 1 2 IF... 1 2.1 BOOLEAN EXPRESSIONS... 3 2.2 BLOCKS... 3 2.3 IF-ELSE... 4 2.4 NESTING... 5 3 SWITCH (SOMETIMES KNOWN AS CASE )... 6 3.1 A BIT ABOUT BREAK... 7 4 CONDITIONAL
More informationWhat you will need. 1 P a g e
Windows 7 Professional/Ultimate Scan to Folder setup (Windows 7 Home is not supported) (Other versions of Windows may be different) (You may need to refer to your Windows documentation) What you will need
More informationCOMP-202: Foundations of Programming. Lecture 2: Java basics and our first Java program! Jackie Cheung, Winter 2016
COMP-202: Foundations of Programming Lecture 2: Java basics and our first Java program! Jackie Cheung, Winter 2016 Learn about cutting-edge research over lunch with cool profs January 18-22, 2015 11:30
More information16-Dec-10. Consider the following method:
Boaz Kantor Introduction to Computer Science IDC Herzliya Exception is a class. Java comes with many, we can write our own. The Exception objects, along with some Java-specific structures, allow us to
More informationThe first program: Little Crab
Chapter 2 The first program: Little Crab topics: concepts: writing code: movement, turning, reacting to the screen edges source code, method call, parameter, sequence, if-statement In the previous chapter,
More informationCS 106 Introduction to Computer Science I
CS 106 Introduction to Computer Science I 05 / 31 / 2017 Instructor: Michael Eckmann Today s Topics Questions / Comments? recap and some more details about variables, and if / else statements do lab work
More informationThis is a tutorial about sensing the environment using a Raspberry Pi. measure a digital input (from a button) output a digital signal (to an LED)
Practical 2 - Overview This is a tutorial about sensing the environment using a Raspberry Pi and a GrovePi+. You will learn: digital input and output measure a digital input (from a button) output a digital
More informationInf1-OP. Inf1-OP Exam Review. Timothy Hospedales, adapting earlier version by Perdita Stevens and Ewan Klein. March 20, School of Informatics
Inf1-OP Inf1-OP Exam Review Timothy Hospedales, adapting earlier version by Perdita Stevens and Ewan Klein School of Informatics March 20, 2017 Overview Overview of examinable material: Lectures Week 1
More information1.00 Lecture 2. What s an IDE?
1.00 Lecture 2 Interactive Development Environment: Eclipse Reading for next time: Big Java: sections 3.1-3.9 (Pretend the method is main() in each example) What s an IDE? An integrated development environment
More informationCOSC 2P95. Procedural Abstraction. Week 3. Brock University. Brock University (Week 3) Procedural Abstraction 1 / 26
COSC 2P95 Procedural Abstraction Week 3 Brock University Brock University (Week 3) Procedural Abstraction 1 / 26 Procedural Abstraction We ve already discussed how to arrange complex sets of actions (e.g.
More informationComputer Science 62 Lab 8
Computer Science 62 Lab 8 Wednesday, March 26, 2014 Today s lab has two purposes: it is a continuation of the binary tree experiments from last lab and an introduction to some command-line tools. The Java
More informationProject Compiler. CS031 TA Help Session November 28, 2011
Project Compiler CS031 TA Help Session November 28, 2011 Motivation Generally, it s easier to program in higher-level languages than in assembly. Our goal is to automate the conversion from a higher-level
More information1. What is the name of the control unit in Robotics? a. R2D2 b. MSN c. Pilot d. XJ7 e. RCX
Quiz Name: Robotics Pilot/ Inventor Quiz Teacher: Mr. Famighetti Class: Robotics Instructions: Choose the best answer. Work with the members of your team only! 1. What is the name of the control unit in
More informationRAD-IT Tool Training. June 2017
Welcome to overview of the RAD-IT Output. This training is designed for transportation professionals who want to understand how to use RAD-IT tool to create regional and project ITS architectures. The
More informationAP CS Unit 3: Control Structures Notes
AP CS Unit 3: Control Structures Notes The if and if-else Statements. These statements are called control statements because they control whether a particular block of code is executed or not. Some texts
More informationpublic class Foo { private int var; public int Method1() { // var accessible anywhere here } public int MethodN() {
Scoping, Static Variables, Overloading, Packages In this lecture, we will examine in more detail the notion of scope for variables. We ve already indicated that variables only exist within the block they
More informationMidterm 1 Review Document
Midterm 1 Review Document CS61B Fall 2016 Antares Chen Introduction This document is meant to provide you supplementary practice questions for the upcoming midterm. It reflects all material that you will
More informationlejos NXJ Problem Solving with Robots [PRSOCO601]
lejos NXJ Problem Solving with Robots [PRSOCO601] Thomas Devine http://noucamp thomas.devine@lyit.ie February 20, 2008 1 Contents 1 lejos NXJ 4 1.1 Introducing the Java Development.......................
More informationJava Programming. What is a program? Programs Recipes. Programs as Recipes 8/16/12. Pancakes In one bowl. mix: 1½ cup flour
What is a program? Java Programming CS 160, Fall Semester 2012 TOPICS Computer Programs Using Eclipse Program Program Components Definition: a sequence of instructions telling a computer what to do Analogy:
More informationIntro to Programming. Unit 7. What is Programming? What is Programming? Intro to Programming
Intro to Programming Unit 7 Intro to Programming 1 What is Programming? 1. Programming Languages 2. Markup vs. Programming 1. Introduction 2. Print Statement 3. Strings 4. Types and Values 5. Math Externals
More informationAP Computer Science Unit 1. Writing Programs Using BlueJ
AP Computer Science Unit 1. Writing Programs Using BlueJ 1. Open up BlueJ. Click on the Project menu and select New Project. You should see the window on the right. Navigate to wherever you plan to save
More information11 Coding Standards CERTIFICATION OBJECTIVES. Use Sun Java Coding Standards
11 Coding Standards CERTIFICATION OBJECTIVES Use Sun Java Coding Standards 2 Chapter 11: Coding Standards CERTIFICATION OBJECTIVE Use Sun Java Coding Standards Spacing Standards The Developer exam is challenging.
More informationCS/IT 114 Introduction to Java, Part 1 FALL 2016 CLASS 2: SEP. 8TH INSTRUCTOR: JIAYIN WANG
CS/IT 114 Introduction to Java, Part 1 FALL 2016 CLASS 2: SEP. 8TH INSTRUCTOR: JIAYIN WANG 1 Notice Class Website http://www.cs.umb.edu/~jane/cs114/ Reading Assignment Chapter 1: Introduction to Java Programming
More informationHands-on Lab. Lego Programming BricxCC Basics
Hands-on Lab Lego Programming BricxCC Basics This lab reviews the installation of BricxCC and introduces a C-like programming environment (called NXC) for the Lego NXT system. Specific concepts include:
More informationCreating objects TOPIC 3 INTRODUCTION TO PROGRAMMING. Making things to program with.
1 Outline TOPIC 3 INTRODUCTION TO PROGRAMMING Notes adapted from Introduction to Computing and Programming with Java: A Multimedia Approach by M. Guzdial and B. Ericson, and instructor materials prepared
More informationSmall rectangles (and sometimes squares like this
Lab exercise 1: Introduction to LabView LabView is software for the real time acquisition, processing and visualization of measured data. A LabView program is called a Virtual Instrument (VI) because it,
More informationOutline. Turtles. Creating objects. Turtles. Turtles in Java 1/27/2011 TOPIC 3 INTRODUCTION TO PROGRAMMING. Making things to program with.
1 Outline 2 TOPIC 3 INTRODUCTION TO PROGRAMMING Notes adapted from Introduction to Computing and Programming with Java: A Multimedia Approach by M. Guzdial and B. Ericson, and instructor materials prepared
More informationCS1083 Week 2: Arrays, ArrayList
CS1083 Week 2: Arrays, ArrayList mostly review David Bremner 2018-01-08 Arrays (1D) Declaring and using 2D Arrays 2D Array Example ArrayList and Generics Multiple references to an array d o u b l e prices
More informationAP Computer Science Unit 1. Writing Programs Using BlueJ
AP Computer Science Unit 1. Writing Programs Using BlueJ 1. Open up BlueJ. Click on the Project menu and select New Project. You should see the window on the right. Navigate to wherever you plan to save
More informationMath 2250 Lab #3: Landing on Target
Math 2250 Lab #3: Landing on Target 1. INTRODUCTION TO THE LAB PROGRAM. Here are some general notes and ideas which will help you with the lab. The purpose of the lab program is to expose you to problems
More informationArray. Array Declaration:
Array Arrays are continuous memory locations having fixed size. Where we require storing multiple data elements under single name, there we can use arrays. Arrays are homogenous in nature. It means and
More informationHands-on Lab. Lego Programming BricxCC Basics
Hands-on Lab Lego Programming BricxCC Basics This lab reviews the installation of BricxCC and introduces a C-like programming environment (called NXC) for the Lego NXT system. Specific concepts include:
More informationCSCI 1100L: Topics in Computing Lab Lab 1: Introduction to the Lab! Part I
CSCI 1100L: Topics in Computing Lab Lab 1: Introduction to the Lab! Part I Welcome to your CSCI-1100 Lab! In the fine tradition of the CSCI-1100 course, we ll start off the lab with the classic bad joke
More informationCSCI 1103: Introduction
CSCI 1103: Introduction Chris Kauffman Last Updated: Wed Sep 13 10:43:47 CDT 2017 1 Logistics Reading Eck Ch 1 Available online: http://math.hws.edu/javanotes/ Reading ahead is encouraged Goals Basic Model
More information03. DECORATOR PATTERN. Design Eye for the Inheritance Guy
BIM492 DESIGN PATTERNS 03. DECORATOR PATTERN Design Eye for the Inheritance Guy Welcome to Starbuzz Coffee Starbuzz Coffee is the fastest growing coffee shop around --> if you see one, look across the
More informationLab 6 Vectors and functions
CMSC160 Intro to Algorithmic Design Blaheta Lab 6 Vectors and functions 11 October 2016 The drill for this lab is another part of the Chapter 4 drill. Come to lab on Tuesday either with it completed or
More informationThe Java Language The Java Language Reference (2 nd ed.) is the defining document for the Java language. Most beginning programming students expect
The Java Language The Java Language Reference (2 nd ed.) is the defining document for the Java language. Most beginning programming students expect such a document to be totally beyond them. That expectation
More informationBlackfin Online Learning & Development
Presentation Title: Multimedia Starter Kit Presenter Name: George Stephan Chapter 1: Introduction Sub-chapter 1a: Overview Chapter 2: Blackfin Starter Kits Sub-chapter 2a: What is a Starter Kit? Sub-chapter
More informationSELENIUM - REMOTE CONTROL
http://www.tutorialspoint.com/selenium/selenium_rc.htm SELENIUM - REMOTE CONTROL Copyright tutorialspoint.com Selenium Remote Control RC was the main Selenium project that sustained for a long time before
More informationLecture 5: Implementing Lists, Version 1
CS18 Integrated Introduction to Computer Science Fisler, Nelson Lecture 5: Implementing Lists, Version 1 Contents 1 Implementing Lists 1 2 Methods 2 2.1 isempty...........................................
More information2SKILL. Variables Lesson 6. Remembering numbers (and other stuff)...
Remembering numbers (and other stuff)... Let s talk about one of the most important things in any programming language. It s called a variable. Don t let the name scare you. What it does is really simple.
More information