Time Saving Programming. John Markham, Janet Albers
|
|
- Claude Strickland
- 6 years ago
- Views:
Transcription
1 Time Saving Programming John Markham, Janet Albers
2
3 Short Cut
4 Short Cut Basic Measure and Store Programs Sensor Connections Setting up DataTables Cards and the SC115 are supported Wiring Diagrams copy and paste from *.DEF file All new Edlog programs. If it can t be written and maintained completely in Short Cut use a CRBasic datalogger. Multiplexers Calculations & Control
5 Custom Sensors
6 Custom Sensors Article
7 CRBasic Functions and Subroutines
8 About Subroutines and Functions Independent section of code that performs a specific task and can return a value or modify an argument Use when you need to: Develop and/or debug a large program (500 lines) Reuse code (3 or more times) Share code with others, including customers
9 Function Structure A Function returns a value. Write that value to a variable. Function CtoF_Func(TempC) Return (TempC * ) EndFunction PTemp_F01 = CtoF_Func(PTemp_C)
10
11 Subroutine Structure A Subroutine is Called. Sub Units_Sub(TempC, TempF, TempK) TempF = TempC * TempK = TempC EndSub Call Units_Sub(PTemp_C, PTemp_F02, Ptemp_K01)
12
13 Which should I use? Subroutine First choice or you re not sure which to use Multiple values need to be returned An array of values needs to be returned Working with strings holding data containing nulls Function You only want to return a single value, especially inside an expression for ease of use / readability TempF = CtoF(TempC) If CtoF(TempC) > 80 Then ACon = TRUE
14 Do: Use Subroutine unless Function is needed Structure the Subroutine or Function so that it is easily reusable to those already familiar with CRBasic instructions Use local variables whenever possible Initialize your local variables each call Break up complex processing tasks into several simpler ones Get in the habit of using Call when calling a subroutine
15 Don t: These probably work but test thoroughly. Put measurements in Functions Put measurements in Subroutines with arguments Put Scan/NextScan inside Subroutines or Functions Use recursive calls or deep nesting
16 Recycle Code
17 Only sell one kind of station The Easy Way
18 Challenges Different sensor combinations Different data collection requirements Different wiring/physical setup Different communication options
19 Strategies Don t write the same code twice Reduce, Reuse, Recycle Think ahead Start ahead of the game Consolidate settings Make a Master Program Write for everything, use what you need Divide and conquer
20 Don t Write The Same Code Twice: Modular Programming Write code in discrete pieces that can be moved between programs Keep track of all related code Variables/Data Tables Measurements Processing Update code with configuration details of new station
21 Don t Write The Same Code Twice: Using Functions and Subroutines Reuse the same code multiple times in the same program More info in the Function and Subroutine section
22 Think Ahead: CRBasic Templates Generate a cache of basic programs for different station types Establish program structure Create naming conventions
23 Think Ahead: Constant table ConstTable.EndConstTable Give it a name Reference constants where possible in program Use conditionals to select sections of code to run
24 Think Ahead: Constant table Change constants from multiple locations Terminal Table Monitor Keypad Watch out for recompile
25 Make A Master Program: Config File Master program is identical on every station Lock down propriety code Pull constant table out of program Include ( Drive:FileName )
26 Config File
27 Make A Master Program: DLD files CRBasic DLD files Edlog DLD files CRBasic.DLD files can be run on any logger. Beware: Some instructions/parameters are logger specific Select a compiler in CRBasic Editor
28 Make A Master Program: Conditional Compiling Allows only part of a program to be executed at run time #If...#Else...#Endif Allows declaration of parallel variables/constants LoggerType function Combine a DLD program, config file, and conditional compiling to create a Master Program Conditional Compile and Save
29
30 Loops and Logic If Then Else
31 Select Case Basic conditional statements If Then Add additional conditionals with else/else if statements Consolidate similar conditional statements into Select Case statements where possible
32
33 Bitwise Logic: AND, OR, NOT Combine nested or multiple If Then statements with AND, OR, and NOT for brevity and clarity Only performed on Integers. Other types converted before evaluated Beware: True (-1) , False(0)
34 For Next Executes a block of code a specified number of times Great for arrays Multi-dimensional arrays can be handled with nested For Next loops
35 Do.Loop Loops run the same code repeatedly While a condition is true Until a condition is met ExitDo While Wend is still accepted syntax, but not as flexible Watch out for infinite loops
36 Comments And Documentation
37 Need I say more? Put Comments in your CRBasic Programs Short Cut puts comments in. Your successor will thank you! Your favorite Support Engineer will thank you! You will thank yourself!
38 CRBasic Comments Header (Template) Version number Customer/Installation information Author s contact information Date Summary of changes made Wiring (from Short Cut *.DEF file)
39 CRBasic Comments Use comments to explain WHY you added an instruction or a section of code
40 CRBasic Comments Document all expressions or equations Use headings for each program section
41 CRBasic Comments Put comments at the end of Subroutine and Function declarations. They show up in the search.
42 CRBasic Comments When a sensor returns a group of variables (an Array) document what each value is. (And/or use Alias)
43 Readable Results
44 Readable Results
45 Debugging Tips
46 Debugging Tips: Hardware Use terminal window to sniff port traffic Check wiring and cabling If it is a serial problem switch Tx and Rx Does the hardware match the software/code
47 Debugging Tips: Code Use timers around loops Use counters in loops and logic Make all variables Public Slow scan rate or limit the number of runs to see what is happening Create variables to store intermediate values of interest Version programs
48 Debugging Tips: Code Test each 'module' separately (you did write modular code, right?) Comment out code until you find the offending lines
49 Debugging Tips: Rethink The Problem Get someone else to look at it Work on something else for a while and come back later Clearly articulate your problem to someone else (even an imaginary friend)
50 Debugging Tips: Compiler Just because the PC CRBasic compiler says a program can compile OK, doesn't mean it will run, or even compile in a real datalogger. Datalogger may have different (usually older) operating system Timing. PC can t check timing. Check the Status Table Use error line references in compile window Be careful, sometimes the error is precipitated by something going wrong before
51 Debugging Tips: Compiler Status Table Compile Results gives run-time errors Updated as program runs, not just at compile time Variable out of bounds Watchdog info memory errors
52 The End
Programming Style. Quick Look. Features of an Effective Style. Naming Conventions
Programming Style Quick Look An effective programming style helps you write code that is easier to understand, debug, maintain, and port from system to system. This article discusses the general features
More informationWorking with JavaScript
Working with JavaScript Creating a Programmable Web Page for North Pole Novelties 1 Objectives Introducing JavaScript Inserting JavaScript into a Web Page File Writing Output to the Web Page 2 Objectives
More informationIntroduction to Modules. Chapter 3. Defining and Calling a Module. Introduction to Modules. 5 Benefits of Modules. Modules CSUS, Spring 2016
Chapter 3 Introduction to Modules Modules CSUS, Spring 2016 Chapter 3.1 Introduction to Modules Introduction to Modules A module is a group of statements that exists within a program for the purpose of
More informationThe compiler is spewing error messages.
Appendix B Debugging There are a few different kinds of errors that can occur in a program, and it is useful to distinguish between them in order to track them down more quickly. Compile-time errors are
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 informationIntroduction to Python Code Quality
Introduction to Python Code Quality Clarity and readability are important (easter egg: type import this at the Python prompt), as well as extensibility, meaning code that can be easily enhanced and extended.
More informationReliable programming
Reliable programming How to write programs that work Think about reliability during design and implementation Test systematically When things break, fix them correctly Make sure everything stays fixed
More information1) Microcom GTX User s Manual 2) Microcom GTX GUI Software 3) Campbel Scientific CR1000 User s Manual 4) Campbell Scientific LoggerNet Software
Application Note: Microcom GTX Modulator uapp222 (v1.0) July 12,2005 Interfacing the MICROCOM DESIGN GTX Satellite Transmitter to the Campbell Scientific CR1000 Data Logger Author: Richard Schwarz PRELIMINARY
More informationText Input and Conditionals
Text Input and Conditionals Text Input Many programs allow the user to enter information, like a username and password. Python makes taking input from the user seamless with a single line of code: input()
More informationChapter Goals. Contents LOOPS
CHAPTER 4 LOOPS Slides by Donald W. Smith TechNeTrain.com Final Draft Oct 30, 2011 Chapter Goals To implement while, for, and do loops To hand-trace the execution of a program To become familiar with common
More informationPROCEDURAL DATABASE PROGRAMMING ( PL/SQL AND T-SQL)
Technology & Information Management Instructor: Michael Kremer, Ph.D. Class 3 Database Programming PROCEDURAL DATABASE PROGRAMMING ( PL/SQL AND T-SQL) AGENDA 3. Declaring Variables/Constants 4. Flow Control
More informationCSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch
CSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch Purpose: We will take a look at programming this week using a language called Scratch. Scratch is a programming language that was developed
More informationThe Dynamic Typing Interlude
CHAPTER 6 The Dynamic Typing Interlude In the prior chapter, we began exploring Python s core object types in depth with a look at Python numbers. We ll resume our object type tour in the next chapter,
More informationGarbage Collection (1)
Coming up: Today: Finish unit 6 (garbage collection) start ArrayList and other library objects Wednesday: Complete ArrayList, basics of error handling Friday complete error handling Next week: Recursion
More informationTopic 6: A Quick Intro To C
Topic 6: A Quick Intro To C Assumption: All of you know Java. Much of C syntax is the same. Also: Many of you have used C or C++. Goal for this topic: you can write & run a simple C program basic functions
More informationFlowcharts for Picaxe BASIC
Flowcharts for Picaxe BASIC Tech Studies Page 1 of 11 In the college you will use the PICAXE Programming Environment in order to carry out all of your program writing, simulating and downloading to the
More informationThis is the basis for the programming concept called a loop statement
Chapter 4 Think back to any very difficult quantitative problem that you had to solve in some science class How long did it take? How many times did you solve it? What if you had millions of data points
More informationComputing and compilers
Computing and compilers Comp Sci 1570 to Outline 1 2 3 4 5 Evaluate the difference between hardware and software Find out about the various types of software Get a high level understanding of how program
More informationProgramming in C. main. Level 2. Level 2 Level 2. Level 3 Level 3
Programming in C main Level 2 Level 2 Level 2 Level 3 Level 3 1 Programmer-Defined Functions Modularize with building blocks of programs Divide and Conquer Construct a program from smaller pieces or components
More informationCSE200 Lecture 6: RECURSION
Table of Contents Review of functions (using factorial example)... 1 Recursion... 1 Step by step run through of recursive factorial... 2 Recursion vs. iteration (for and while loops)... 3 Helper functions:...
More informationSoftware Development & Education Center C Programming
Software Development & Education Center C Programming Detailed Curriculum History of C Features of C Requirement from C development Turbo C 3 Turbo C 45 Borland C++ 502 Rules for C Programming Writing
More informationMethod & Tools for Program Analysis & Design
Method & Tools for Program Analysis & Design TMB208 Pemrograman Teknik Kredit: 3 (2-3) 1 Programming Logic and Design, Introductory, Fourth Edition 2 1 Programming Methods Based on structures of programming
More informationAn Overview of the BLITZ System
An Overview of the BLITZ System Harry H. Porter III Department of Computer Science Portland State University Introduction The BLITZ System is a collection of software designed to support a university-level
More informationChapter 3: Modules. Starting Out with Programming Logic & Design. Second Edition. by Tony Gaddis
Chapter 3: Modules Starting Out with Programming Logic & Design Second Edition by Tony Gaddis Copyright 2010 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter Topics 3.1 Introduction
More informationExercise 6 - Addressing a Message
Exercise 6 - Addressing a Message All e-mail messages have to include an address for an e-mail to be delivered, just as a normal letter has to have a house address. An e-mail address is made up of: a user
More informationSummer 2017 Discussion 10: July 25, Introduction. 2 Primitives and Define
CS 6A Scheme Summer 207 Discussion 0: July 25, 207 Introduction In the next part of the course, we will be working with the Scheme programming language. In addition to learning how to write Scheme programs,
More informationAbout Codefrux While the current trends around the world are based on the internet, mobile and its applications, we try to make the most out of it. As for us, we are a well established IT professionals
More informationQuiz 1: Functions and Procedures
Quiz 1: Functions and Procedures Outline Basics Control Flow While Loops Expressions and Statements Functions Primitive Data Types 3 simple data types: number, string, boolean Numbers store numerical data
More informationProgramming II (CS300)
1 Programming II (CS300) Chapter 01: Procedural Programming MOUNA KACEM mouna@cs.wisc.edu Fall 2018 Procedural Programming 2 Introduction Procedural Programming: General Overview Procedural Programming:
More informationLesson Seven: Holding Gestures
Lesson Seven: Holding Gestures PAGE 01 Lesson Seven: Holding Gestures Overview In the previous lesson, we made our functions more useful by allowing them to output through the keyboard. By assigning different
More informationImplementing an Algorithm for Boomerang Fraction Sequences in Python
Introduction Implementing an Algorithm for Boomerang Fraction Sequences in Python We ve all encountered maze problems, where the challenge is to find a path through a labyrinth from a starting point to
More informationThe Design Process. General Development Issues. C/C++ and OO Rules of Thumb. Home
A l l e n I. H o l u b & A s s o c i a t e s Home C/C++ and OO Rules of Thumb The following list is essentially the table of contents for my book Enough Rope to Shoot Yourself in the Foot (McGraw-Hill,
More informationLECTURE 0: Introduction and Background
1 LECTURE 0: Introduction and Background September 10, 2012 1 Computational science The role of computational science has become increasingly significant during the last few decades. It has become the
More informationProgramming in the Real World. Dr. Baldassano Yu s Elite Education
Programming in the Real World Dr. Baldassano chrisb@princeton.edu Yu s Elite Education Our programs are getting bigger! Our game was already over 100 lines long - most programs are worked on by teams of
More informationRepetition Through Recursion
Fundamentals of Computer Science I (CS151.02 2007S) Repetition Through Recursion Summary: In many algorithms, you want to do things again and again and again. For example, you might want to do something
More informationTopic 6: A Quick Intro To C. Reading. "goto Considered Harmful" History
Topic 6: A Quick Intro To C Reading Assumption: All of you know basic Java. Much of C syntax is the same. Also: Some of you have used C or C++. Goal for this topic: you can write & run a simple C program
More informationThis section provides some reminders and some terminology with which you might not be familiar.
Chapter 3: Functions 3.1 Introduction The previous chapter assumed that all of your Bali code would be written inside a sole main function. But, as you have learned from previous programming courses, modularizing
More informationCompiling with Multiple Files The Importance of Debugging CS 16: Solving Problems with Computers I Lecture #7
Compiling with Multiple Files The Importance of Debugging CS 16: Solving Problems with Computers I Lecture #7 Ziad Matni Dept. of Computer Science, UCSB Programming in Multiple Files The Magic of Makefiles!
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 informationPROCEDURAL DATABASE PROGRAMMING ( PL/SQL AND T-SQL)
Technology & Information Management Instructor: Michael Kremer, Ph.D. Class 5 Database Programming PROCEDURAL DATABASE PROGRAMMING ( PL/SQL AND T-SQL) AGENDA 7. Stored Procedures 7.1 Introduction to Stored
More informationAssertions, pre/postconditions
Programming as a contract Assertions, pre/postconditions Assertions: Section 4.2 in Savitch (p. 239) Specifying what each method does q Specify it in a comment before method's header Precondition q What
More informationSmaller, simpler, subcomponent of program Provides abstraction
C Function Overview Function Smaller, simpler, subcomponent of program Provides abstraction» hide low-level details» give high-level structure to program, easier to understand overall program flow» enables
More informationClient Code - the code that uses the classes under discussion. Coupling - code in one module depends on code in another module
Basic Class Design Goal of OOP: Reduce complexity of software development by keeping details, and especially changes to details, from spreading throughout the entire program. Actually, the same goal as
More informationA function is a named piece of code that performs a specific task. Sometimes functions are called methods, procedures, or subroutines (like in LC-3).
CIT Intro to Computer Systems Lecture # (//) Functions As you probably know from your other programming courses, a key part of any modern programming language is the ability to create separate functions
More informationOur Strategy for Learning Fortran 90
Our Strategy for Learning Fortran 90 We want to consider some computational problems which build in complexity. evaluating an integral solving nonlinear equations vector/matrix operations fitting data
More informationThe SC receives a public IP address from the DHCP client of the ISP. All traffic is automatically sent out through the WAN interface.
Barracuda NextGen Secure Connectors can connect to the Internet using DHCP client, static, or Wi-Fi client connections. The connections can be configured through the Secure Connector Editor or, for troubleshooting
More informationQ1 Q2 Q3 Q4 Q5 Total 1 * 7 1 * 5 20 * * Final marks Marks First Question
Page 1 of 6 Template no.: A Course Name: Computer Programming1 Course ID: Exam Duration: 2 Hours Exam Time: Exam Date: Final Exam 1'st Semester Student no. in the list: Exam pages: Student's Name: Student
More information9.2 Linux Essentials Exam Objectives
9.2 Linux Essentials Exam Objectives This chapter will cover the topics for the following Linux Essentials exam objectives: Topic 3: The Power of the Command Line (weight: 10) 3.3: Turning Commands into
More informationSimple AngularJS thanks to Best Practices
Simple AngularJS thanks to Best Practices Learn AngularJS the easy way Level 100-300 What s this session about? 1. AngularJS can be easy when you understand basic concepts and best practices 2. But it
More informationError Code. GO Software Pty Limited Map: 27 Tacoma Blvd, Pasadena SA 5042 ABN: ACN:
GO Software Pty Limited Map: 27 Tacoma Blvd, Pasadena SA 5042 Phn: 0403-063-991 Fax: none ABN: 54-008-044-906 ACN: 008-044-906 Eml: support@gosoftware.com.au Web: www.gosoftware.com.au Error Code GW-Basic
More informationCS64 Week 5 Lecture 1. Kyle Dewey
CS64 Week 5 Lecture 1 Kyle Dewey Overview More branches in MIPS Memory in MIPS MIPS Calling Convention More Branches in MIPS else_if.asm nested_if.asm nested_else_if.asm Memory in MIPS Accessing Memory
More informationLesson 1 Python: Interactive Fiction
Lesson 1 Python: Interactive Fiction Introduction Interactive fiction is a story told with software. We will be using the programming language Python. The program will simulate a place and some actions,
More informationIf you don t, it will return the same thing as == But this may not be what you want... Several different kinds of equality to consider:
CS61B Summer 2006 Instructor: Erin Korber Lecture 5, 3 July Reading for tomorrow: Chs. 7 and 8 1 Comparing Objects Every class has an equals method, whether you write one or not. If you don t, it will
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 informationIT 374 C# and Applications/ IT695 C# Data Structures
IT 374 C# and Applications/ IT695 C# Data Structures Module 2.5: Methods A Deeper Look Xianrong (Shawn) Zheng Spring 2017 1 Outline static Methods, static Variables, and Class Math Methods with Multiple
More informationSECTION 5: STRUCTURED PROGRAMMING IN MATLAB. ENGR 112 Introduction to Engineering Computing
SECTION 5: STRUCTURED PROGRAMMING IN MATLAB ENGR 112 Introduction to Engineering Computing 2 Conditional Statements if statements if else statements Logical and relational operators switch case statements
More informationAPPENDIX B. Fortran Hints
APPENDIX B Fortran Hints This appix contains hints on how to find errors in your programs, and how to avoid some common Fortran errors in the first place. The basics on how to invoke the Fortran compiler
More informationLearning vrealize Orchestrator in action V M U G L A B
Learning vrealize Orchestrator in action V M U G L A B Lab Learning vrealize Orchestrator in action Code examples If you don t feel like typing the code you can download it from the webserver running on
More informationModule 10A Lecture - 20 What is a function? Why use functions Example: power (base, n)
Programming, Data Structures and Algorithms Prof. Shankar Balachandran Department of Computer Science and Engineering Indian Institute of Technology, Madras Module 10A Lecture - 20 What is a function?
More informationLesson 2 Variables and I/O
Lesson 2 Variables and I/O Pic 10A Ricardo Salazar Free form layout C++ lets you use spaces and returns (enter key) wherever you see fit. cout
More informationPROBLEM SOLVING 11. July 24, 2012
PROBLEM SOLVING 11 COMPUTER SCIENCE 61A July 24, 2012 Today s section will be a kind of Meta-Section, we are going to walk through some medium to hard-ish problems in Scheme, and we will discuss some methods
More informationChapter 4: Writing and Designing a Complete Program. Programming Logic and Design, Third Edition Introductory
Chapter 4: Writing and Designing a Complete Program Programming Logic and Design, Third Edition Introductory Objectives After studying Chapter 4, you should be able to: Plan the mainline logic for a complete
More informationMobile Computing Professor Pushpendra Singh Indraprastha Institute of Information Technology Delhi Java Basics Lecture 02
Mobile Computing Professor Pushpendra Singh Indraprastha Institute of Information Technology Delhi Java Basics Lecture 02 Hello, in this lecture we will learn about some fundamentals concepts of java.
More informationStarting to Program in C++ (Basics & I/O)
Copyright by Bruce A. Draper. 2017, All Rights Reserved. Starting to Program in C++ (Basics & I/O) On Tuesday of this week, we started learning C++ by example. We gave you both the Complex class code and
More informationChapter 5 Errors. Bjarne Stroustrup
Chapter 5 Errors Bjarne Stroustrup www.stroustrup.com/programming Abstract When we program, we have to deal with errors. Our most basic aim is correctness, but we must deal with incomplete problem specifications,
More informationSCHEME 8. 1 Introduction. 2 Primitives COMPUTER SCIENCE 61A. March 23, 2017
SCHEME 8 COMPUTER SCIENCE 61A March 2, 2017 1 Introduction In the next part of the course, we will be working with the Scheme programming language. In addition to learning how to write Scheme programs,
More informationEclipse CDT Tutorial. Eclipse CDT Homepage: Tutorial written by: James D Aniello
Eclipse CDT Tutorial Eclipse CDT Homepage: http://www.eclipse.org/cdt/ Tutorial written by: James D Aniello Hello and welcome to the Eclipse CDT Tutorial. This tutorial will teach you the basics of the
More informationCSE 142/143 Unofficial Style Guide
CSE 142/143 Unofficial Style Guide Below, things in GREEN are GOOD; things in RED are to be AVOIDED. Commenting Comment well. Follow the commenting rules for header, method, field, and inside-method comments
More informationErrors. Lecture 6. Hartmut Kaiser hkaiser/fall_2011/csc1254.html
Hartmut Kaiser hkaiser@cct.lsu.edu http://www.cct.lsu.edu/ hkaiser/fall_2011/csc1254.html 2 Abstract When we program, we have to deal with errors. Our most basic aim is correctness, but we must deal with
More informationIteration. # a and b are now equal # a and b are no longer equal Multiple assignment
Iteration 6.1. Multiple assignment As you may have discovered, it is legal to make more than one assignment to the same variable. A new assignment makes an existing variable refer to a new value (and stop
More information(Refer Slide Time: 00:26)
Programming, Data Structures and Algorithms Prof. Shankar Balachandran Department of Computer Science and Engineering Indian Institute Technology, Madras Module 07 Lecture 07 Contents Repetitive statements
More informationUnit 8: Working with Actions
Unit 8: Working with Actions Questions Covered What are actions? How are actions triggered? Where can we access actions to create or edit them? How do we automate the sending of email notifications? How
More informationCS 3 Introduction to Software Engineering. 3: Exceptions
CS 3 Introduction to Software Engineering 3: Exceptions Questions? 2 Objectives Last Time: Procedural Abstraction This Time: Procedural Abstraction II Focus on Exceptions. Starting Next Time: Data Abstraction
More informationC++ & Object Oriented Programming Concepts The procedural programming is the standard approach used in many traditional computer languages such as BASIC, C, FORTRAN and PASCAL. The procedural programming
More informationOptimising for the p690 memory system
Optimising for the p690 memory Introduction As with all performance optimisation it is important to understand what is limiting the performance of a code. The Power4 is a very powerful micro-processor
More informationProcess Context & Interrupts. New process can mess up information in old process. (i.e. what if they both use the same register?)
1 Process Context 1.1 What is context? A process is sometimes called a task, subroutine or program. Process context is all the information that the process needs to keep track of its state. Registers Temporary
More informationTips for Reducing Formula Size
Tips for Reducing Formula Size Salesforce, Summer 17 @salesforcedocs Last updated: August 9, 2017 Copyright 2000 2017 salesforce.com, inc. All rights reserved. Salesforce is a registered trademark of salesforce.com,
More informationCOP 1220 Introduction to Programming in C++ Course Justification
Course Justification This course is a required first programming C++ course in the following degrees: Associate of Arts in Computer Science, Associate in Science: Computer Programming and Analysis; Game
More informationWriting to and reading from files
Writing to and reading from files printf() and scanf() are actually short-hand versions of more comprehensive functions, fprintf() and fscanf(). The difference is that fprintf() includes a file pointer
More informationExperiment 3 Introduction to Verilog Programming using Quartus II software Prepared by: Eng. Shatha Awawdeh, Eng.Eman Abu_Zaitoun
Experiment 3 Introduction to Verilog Programming using Quartus II software Prepared by: Eng. Shatha Awawdeh, Eng.Eman Abu_Zaitoun Introduction: Verilog HDL is a hardware description language used to design
More informationFunctions. Computer System and programming in C Prentice Hall, Inc. All rights reserved.
Functions In general, functions are blocks of code that perform a number of pre-defined commands to accomplish something productive. You can either use the built-in library functions or you can create
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 informationChapter 4 Introduction to Control Statements
Introduction to Control Statements Fundamentals of Java: AP Computer Science Essentials, 4th Edition 1 Objectives 2 How do you use the increment and decrement operators? What are the standard math methods?
More informationC Functions. 5.2 Program Modules in C
1 5 C Functions 5.2 Program Modules in C 2 Functions Modules in C Programs combine user-defined functions with library functions - C standard library has a wide variety of functions Function calls Invoking
More informationData paths and control logic
Data paths and control logic! Building larger digital systems " Include data, not just control inputs! An example! Building up toward project - MasterMind Autumn 2014 CSE390C - IX - Data Paths and Control
More informationCOMP1730/COMP6730 Programming for Scientists. Testing and Debugging.
COMP1730/COMP6730 Programming for Scientists Testing and Debugging. Overview * Testing * Debugging * Defensive Programming Overview of testing * There are many different types of testing - load testing,
More informationME 461 C review Session Fall 2009 S. Keres
ME 461 C review Session Fall 2009 S. Keres DISCLAIMER: These notes are in no way intended to be a complete reference for the C programming material you will need for the class. They are intended to help
More informationa b c d a b c d e 5 e 7
COMPSCI 230 Homework 9 Due on April 5, 2016 Work on this assignment either alone or in pairs. You may work with different partners on different assignments, but you can only have up to one partner for
More informationQUIZ Friends class Y;
QUIZ Friends class Y; Is a forward declaration neeed here? QUIZ Friends QUIZ Friends - CONCLUSION Forward (a.k.a. incomplete) declarations are needed only when we declare member functions as friends. They
More information10 C Language Tips for Hardware Engineers
10 C Language Tips for Hardware Engineers Jacob Beningo - March 05, 2013 On its own, the software development process has numerous hazards and obstacles that require navigation in order to successfully
More informationG. Tardiani RoboCup Rescue. EV3 Workshop Part 1 Introduction to RobotC
RoboCup Rescue EV3 Workshop Part 1 Introduction to RobotC Why use RobotC? RobotC is a more traditional text based programming language The more compact coding editor allows for large programs to be easily
More informationVISUAL GUIDE to. RX Scripting. for Roulette Xtreme - System Designer 2.0. L J Howell UX Software Ver. 1.0
VISUAL GUIDE to RX Scripting for Roulette Xtreme - System Designer 2.0 L J Howell UX Software 2009 Ver. 1.0 TABLE OF CONTENTS INTRODUCTION...ii What is this book about?... iii How to use this book... iii
More informationDebugging with gdb and valgrind
Debugging with gdb and valgrind Dr. Axel Kohlmeyer Associate Dean for Scientific Computing, CST Associate Director, Institute for Computational Science Assistant Vice President for High-Performance Computing
More informationMethods. CSE 114, Computer Science 1 Stony Brook University
Methods CSE 114, Computer Science 1 Stony Brook University http://www.cs.stonybrook.edu/~cse114 1 Opening Problem Find multiple sums of integers: - from 1 to 10, - from 20 to 30, - from 35 to 45,... 2
More informationThe %let is a Macro command, which sets a macro variable to the value specified.
Paper 220-26 Structuring Base SAS for Easy Maintenance Gary E. Schlegelmilch, U.S. Dept. of Commerce, Bureau of the Census, Suitland MD ABSTRACT Computer programs, by their very nature, are built to be
More informationTypes and Static Type Checking (Introducing Micro-Haskell)
Types and Static (Introducing Micro-Haskell) Informatics 2A: Lecture 14 John Longley School of Informatics University of Edinburgh jrl@inf.ed.ac.uk 17 October 2017 1 / 21 1 Types 2 3 4 2 / 21 So far in
More informationCall with Current Continuation Patterns
Call with Current Continuation Patterns Darrell Ferguson Dwight Deugo August 24, 2001 Abstract This paper outlines the recurring use of continuations. A brief overview of continuations is given. This is
More informationTypes and Static Type Checking (Introducing Micro-Haskell)
Types and Static (Introducing Micro-Haskell) Informatics 2A: Lecture 13 Alex Simpson School of Informatics University of Edinburgh als@inf.ed.ac.uk 16 October, 2012 1 / 21 1 Types 2 3 4 2 / 21 Thus far
More informationKAREL JR 3 STUDENT JOURNAL REVISED APRIL 19, 2017 NAME SCHOOL, CLASS, PERIOD
KAREL JR 3 STUDENT JOURNAL REVISED APRIL 19, 2017 NAME DATE STARTED DATE COMPLETED SCHOOL, CLASS, PERIOD Copyright 2016, 2017 NCLab Inc. 2 3 TABLE OF CONTENTS: WELCOME TO YOUR JOURNAL 4 SECTION 11: USING
More information4.2 Variations on a Scheme -- Lazy Evaluation
[Go to first, previous, next page; contents; index] 4.2 Variations on a Scheme -- Lazy Evaluation Now that we have an evaluator expressed as a Lisp program, we can experiment with alternative choices in
More information