04 July 2000 CAMAC++ Steve Wotton

Size: px
Start display at page:

Download "04 July 2000 CAMAC++ Steve Wotton"

Transcription

1 04 July 2000 CAMAC++ Steve Wotton

2 1 Introduction This document describes a primitive C++ CAMAC library for systems which utilise the CES CBD8211 CAMAC branch driver. No attempt has been made to preserve the familiar calling sequences of standard CAMAC libraries. The motivation for providing this library is to ease the integration of CAMAC systems into modern data acquisition environments where portability between different operating systems and different hardware environments may be important. The library is incomplete and under development. The library has so far been used on the following systems: HP742 VME SBC running HPUX PC running Windows NT using the National Instruments PCI-to-VME interface. SBCs running OS9 CES RIO running LynxOs The g++ v2.7.2 compiler has been used except on WNT where Borland C++ v5 was used. It should be straightforward to modify the library for use in other similar systems. The main requirement is that the host system should support transparent addressing of the VMEbus. On virtual memory systems (like the HP) this is done by mapping the physical address space of the CBD into the user's virtual address space. On non-virtual addressing systems (eg OS-9) the corresponding address mapping function would simply return the "physical" address of the module. All this architecture dependent stuff is hidden in a vme class for easy portability. 2 About the CAMAC branch driver The CBD can drive a single CAMAC branch containing up to 7 crates. The physical VME base address of the CBD depends on the branch number selected with the front panel switch. The base address is then given by the expression (0x (N<<19)) where N is the selected branch number. This information, and the width of the address space containing the CBD branch registers (0x10000), must be passed to the VME library using the VME configuration file (the National Instruments implementation uses its own VME configuration database). Here is an example VME configuration file for a VME system containing a CBD: # File is read using C-style format " %s %d %i %i %i " # The fields are: # name, logical address, physical address, size, address space( A16,24,32 ) branch1 4 0x x other VME modules Note that in the example the CBD is driving branch 1. Also note that it is only necessary to specify the width of the address space large enough to span the branch registers (0x10000 is the minimum value which satisfies this requirement). The address space corresponding to the individual CAMAC crates is not included in the above but is mapped in by the CAMAC library as required. The description of the CAMAC branch (crates and modules) is contained in a separate configuration file described below. 3 The classes There are three basic classes in the library which describe the logical concepts of CAMAC branch (cbranch), CAMAC crate (ccrate) and CAMAC module (cmodule). cmodule is an abstract class from which concrete classes representing actual CAMAC modules must be derived. The constructors of the above classes take care of doing any desirable initialisation. 3.1 The class cbranch The cbranch constructor has two forms. The recommended form cbranch(vme,file) reads the branch configuration from an ASCII file and causes the ccrate and cmodule constructors to be called as required. Note that the cbranch constructor takes a pointer to an object of class vme as an argument. The vme class takes care of initialising the VME interface. 2

3 3.1.1 Member functions Member function Operation Returns cbranch(vme *VME, const char brname[], const char config[]) Constructor(1) - cbranch(vme *VME, CAMACD *address, unsigned brnumber, Constructor(2) - const char config[]) Description of arguments Name Notes VME Pointer to VME++ object brname Name of branch as identified in VME++ configuration file config Configuration file name or environment variable name address Physical base address of CBD brnumber Physical branch number The following example configuration file describes a system having two camac crates on branch 0 with two CAMAC modules in each crate: branch: 0 0x crate: 1 crate1 module: 16 tdc lrs2228 module: 21 scalar1 lrs2551 crate: 2 crate2 module: 7 scalar2 lrs2551 module: 8 scalar3 lrs2551 Each line has one of the following forms: branch: number CBD_addr crate: number name module: slot_number name type The "name" parameters are arbitrary and are used to locate the named object in the internal lists. The "number" parameters must be consistent with the hardware configuration. The module "type" parameter is used to determine which concrete class of module to instantiate. Refer to the example program for more details. The alternative form of the constructor cbranch(vme,addr,i,file) allows the creation of a branch to which crates and modules may be added later by explicit calls to ccrate and cmodule constructors in the user program. Note that the name of an existing file is still required as this is identified with a semaphore created by the library. However, in this case, the file may be empty - the branch number and physical address of the CAMAC branch driver are passed explicitly as constructor arguments. 3.2 The class ccrate This class represents a CAMAC crate and implements the functions used for crate initialisation and control: Member function Operation Returns ccrate(cbranch *branch, int id, char *name ) Constructor - void reset(void) Crate reset (CCCZ) - void clear(void) Crate clear (CCCC) - int clrinhibit(void) Clear inhibit (CCCI) Inhibit state int setinhibit(void) Set inhibit (CCCI) Inhibit state int testinhibit(void) Test inhibit (CTCI) Inhibit state int clrdemand(void) Clear demand (CCCD) Demand state int setdemand(void) Set demand (CCCD) Demand state int testdemand(void) Test demand (CTCD) Demand state 3.3 The class cmodule This class is an abstraction of a CAMAC module and is used to define the interface functions which all derived classes must provide. Currently the following functions must exist: read, test, clear, execute. See camac.h for implementation details. 3

4 CAMAC defines a set of function s which perform more or less standard operations on all CAMAC modules (although not all functions are implemented on all modules). The following is a suggested convention for the cmodule member function names corresponding to the CAMAC function s F0-31: CAMAC read member function CAMAC control member function CAMAC write member function F0 read F8 testlam F16 write F1 read2 F9 clear F17 write2 F2 readclear F10 clearlam F18 setselective F3 readcomplement F11 clear2 F19 setselective2 F4 - F12 - F20 - F5 - F13 - F21 clearselective F6 - F14 - F22 - F7 - F15 - F23 clearselective2 - - F24 disable F25 execute F26 enable F27 test F28-F CAMAC Q, X and timeout responses are placed into cmodule::errno which should be checked after every CAMAC operation which may affect these flags. If 0, no occurred otherwise bit 0 set indicates CAMAC timeout, bit 1 set indicates no X response and bit 2 set indicates no Q response. 4 Locating modules The class library constructors build internal data structures which are lists of which crates belong to a branch and which modules belong to a crate. Modules may be located by name, the module and crate names being defined in the branch configuration file. The example program illustrates how to locate the module called "scalar" in the crate named "crate2". Note the type cast to the actual type of the located module. This expression should be used as a model for locating other modules. 5 Extending the library Every CAMAC module in a system is represented by a concrete class derived from class cmodule. Adding support for new modules means deriving a new class from cmodule which must implement at least the read, test, clear and execute member functions (although they may be dummy). The simple classes lrs2228 (a D16 module) and lrs2551 (a D24 module) in camac.h serve as simple examples. One should not forget to set cmodule::s depending on the CAMAC response. 6 Error handling For maximum portability C++ exception handling has not been used in this library. Instead, each class contains a public data member, s, which behaves as a trace buffer into which arbitrary text can be placed for later display. This strategy has the advantage of allowing constructors (which cannot return values) to report s in the same way as other member functions and also allows messages to be reported from deeply nested function calls and still allow the to be precisely located. The trace buffer continues to accumulate messages until flushed to cout or cerr using the << operator. The trace buffer is then truncated to zero length. See the example programs for how to test for conditions in this scheme. 7 Advanced features 4

5 8 Multitasking The hardware must be protected against concurrent access which may arise in a multitasking environment where more than one process may try to access a CAMAC branch. One possibility would be to confine all CAMAC operations within a single process. Another possibility would be to protect all CAMAC operations with a semaphore. In order to avoid incurring any unnecessary software penalties the responsibility of protecting the CAMAC operations has been left to the user. The example program illustrates the use of the branch semaphore. This approach has the disadvantage that users can cheat by not protecting CAMAC access with the semaphore either deliberately or inadvertently (e.g. by using an alternative CAMAC library with different or no protection mechanism). Note that the semaphore is used in the library to protect the branch initialisation. Another potential problem in a multi-tasking environment is that of initialisation. Typically the hardware initialisation should be done only once. Since an initialisation function is called from the class constructors and only the first use of a constructor by any process in the system should perform initialisation, a second semaphore is used by the library to guarantee this behaviour. The initialisation routines can always be called from the users program at any time in order to reinitialise part or all of the CAMAC branch. Again, it is possible to cheat the concurrent access protection scheme. 8.1 Interrupts Interrupt handling (generated in response to LAMs) is not implemented. On the HP this would require the implementation of a device driver. On OS9 a device driver already exists but needs to be integrated with this library. The Nat. Inst. PCI-VME interface has user-callable software to install interrupt handlers so implementation of LAM interrupt handlers should be easy here. The main problem is to make the library behave the same on all platforms given the constraints of using the already existing software. 8.2 C-binding These functions are implemented as jacket routines to the C++ API. The CBRANCHID and CMODULEID type arguments are actually pointers to the underlying C++ objects and should never be directly manipulated by a C- d application. They serve as context arguments used by the library. Since these are jacket routines, this is hardware independent and is split off into a separate file, ccamac.cpp Function Operation Returns int opencbranch(cbranchid *cid, VMEID vid, const char *file) Setup CAMAC branch using configuration file int closecbranch(cbranchid cid) Close CAMAC branch int getcbranch(cbranchid cid) Get exclusive access to (lock) branch int releasecbranch(cbranchid cid) Release lock on branch int getcmodule(cbranchid cid, CMODULEID *mid, Get pointer to named module const char *crate, const char *module) int cfnr(cmoduleid mid, int A, int *D, int fn) Perform read operation QXT int cfnw(cmoduleid mid, int A, int D, int fn) Perform write operation QXT int cfnc(cmoduleid mid, int fn) Perform control operation QXT Where the return is indicated as QXT this means a bitmask indicating the status of the CAMAC Q, X and T response in the least significant 3 bits or some other in higher order bits. In addition to these routines it is also necessary to initialise the VME interface using the openvme() and closevme() from the VME library as in the example program. 9 Built in support for CAMAC modules Support for a number of specific common CAMAC modules is included in the library. The following modules are known in addition to generic 16bit and 24bit data modules: Module Description LRS2228 TDC LRS2229 TDC 5

6 LRS2249 ADC LRS2551 Scaler, 12ch. LRS4416 Discriminator LRS4418 Programmable delay, 16ch LRS4516 Programmable Logic Unit LRS4432 Scaler, 32ch. or2027 Output register, 16ch. LRS2341 Input register, 16ch. c85 CAEN Programmable logic unit 10 Example C++ program 11 Example C program 6

Using NCSL DAQ Software to Readout a LeCroy 4300B. Timothy Hoagland

Using NCSL DAQ Software to Readout a LeCroy 4300B. Timothy Hoagland Using NCSL DAQ Software to Readout a LeCroy 4300B Timothy Hoagland January 20, 2005 Abstract This paper s purpose is to assist the reader in setting up and reading out data from a LeCroy 4300B FERA ADC.

More information

Short Notes of CS201

Short Notes of CS201 #includes: Short Notes of CS201 The #include directive instructs the preprocessor to read and include a file into a source code file. The file name is typically enclosed with < and > if the file is a system

More information

RM0327 Reference manual

RM0327 Reference manual Reference manual Multi-Target Trace API version 1.0 Overview Multi-Target Trace (MTT) is an application instrumentation library that provides a consistent way to embed instrumentation into a software application,

More information

CS201 - Introduction to Programming Glossary By

CS201 - Introduction to Programming Glossary By CS201 - Introduction to Programming Glossary By #include : The #include directive instructs the preprocessor to read and include a file into a source code file. The file name is typically enclosed with

More information

Introduction to Programming Using Java (98-388)

Introduction to Programming Using Java (98-388) Introduction to Programming Using Java (98-388) Understand Java fundamentals Describe the use of main in a Java application Signature of main, why it is static; how to consume an instance of your own class;

More information

Chenyu Zheng. CSCI 5828 Spring 2010 Prof. Kenneth M. Anderson University of Colorado at Boulder

Chenyu Zheng. CSCI 5828 Spring 2010 Prof. Kenneth M. Anderson University of Colorado at Boulder Chenyu Zheng CSCI 5828 Spring 2010 Prof. Kenneth M. Anderson University of Colorado at Boulder Actuality Introduction Concurrency framework in the 2010 new C++ standard History of multi-threading in C++

More information

Absolute C++ Walter Savitch

Absolute C++ Walter Savitch Absolute C++ sixth edition Walter Savitch Global edition This page intentionally left blank Absolute C++, Global Edition Cover Title Page Copyright Page Preface Acknowledgments Brief Contents Contents

More information

JAYARAM COLLEGE OF ENGINEERING AND TECHNOLOGY Pagalavadi, Tiruchirappalli (An approved by AICTE and Affiliated to Anna University)

JAYARAM COLLEGE OF ENGINEERING AND TECHNOLOGY Pagalavadi, Tiruchirappalli (An approved by AICTE and Affiliated to Anna University) Estd: 1994 JAYARAM COLLEGE OF ENGINEERING AND TECHNOLOGY Pagalavadi, Tiruchirappalli - 621014 (An approved by AICTE and Affiliated to Anna University) ISO 9001:2000 Certified Subject Code & Name : CS 1202

More information

CE221 Programming in C++ Part 1 Introduction

CE221 Programming in C++ Part 1 Introduction CE221 Programming in C++ Part 1 Introduction 06/10/2017 CE221 Part 1 1 Module Schedule There are two lectures (Monday 13.00-13.50 and Tuesday 11.00-11.50) each week in the autumn term, and a 2-hour lab

More information

QUIZ. What is wrong with this code that uses default arguments?

QUIZ. What is wrong with this code that uses default arguments? QUIZ What is wrong with this code that uses default arguments? Solution The value of the default argument should be placed in either declaration or definition, not both! QUIZ What is wrong with this code

More information

Multiprocessors 2007/2008

Multiprocessors 2007/2008 Multiprocessors 2007/2008 Abstractions of parallel machines Johan Lukkien 1 Overview Problem context Abstraction Operating system support Language / middleware support 2 Parallel processing Scope: several

More information

Overview: The OpenMP Programming Model

Overview: The OpenMP Programming Model Overview: The OpenMP Programming Model motivation and overview the parallel directive: clauses, equivalent pthread code, examples the for directive and scheduling of loop iterations Pi example in OpenMP

More information

JENET C LIBRARY API ver. 3.00

JENET C LIBRARY API ver. 3.00 JENET C LIBRARY API ver. 3.00 Document Version: 2.0 Document Revision: November, 29 2007 FP, UZ, MV Helper function library for developing user applications to control a Jenet Ethernet Camac Crate Controller.

More information

Technical Information Manual

Technical Information Manual Technical Information Manual Revision n. 1 28 September 2009 CAENV1x90 LIBRARY AND DEMO APPLICATION SOFTWARE CAEN will repair or replace any product within the guarantee period if the Guarantor declares

More information

Lecture 18 Tao Wang 1

Lecture 18 Tao Wang 1 Lecture 18 Tao Wang 1 Abstract Data Types in C++ (Classes) A procedural program consists of one or more algorithms that have been written in computerreadable language Input and display of program output

More information

CE221 Programming in C++ Part 2 References and Pointers, Arrays and Strings

CE221 Programming in C++ Part 2 References and Pointers, Arrays and Strings CE221 Programming in C++ Part 2 References and Pointers, Arrays and Strings 19/10/2017 CE221 Part 2 1 Variables and References 1 In Java a variable of primitive type is associated with a memory location

More information

Threads. Threads (continued)

Threads. Threads (continued) Threads A thread is an alternative model of program execution A process creates a thread through a system call Thread operates within process context Use of threads effectively splits the process state

More information

Chapter 13: Reference. Why reference Typing Evaluation Store Typings Safety Notes

Chapter 13: Reference. Why reference Typing Evaluation Store Typings Safety Notes Chapter 13: Reference Why reference Typing Evaluation Store Typings Safety Notes References Computational Effects Also known as side effects. A function or expression is said to have a side effect if,

More information

Jayaram college of Engineering and Technology, Pagalavadi. CS2203 Object Oriented Programming Question Bank Prepared By: S.Gopalakrishnan, Lecturer/IT

Jayaram college of Engineering and Technology, Pagalavadi. CS2203 Object Oriented Programming Question Bank Prepared By: S.Gopalakrishnan, Lecturer/IT CS2203 Object Oriented Programming Question Bank Prepared By: S.Gopalakrishnan, Lecturer/IT Two Mark Questions UNIT - I 1. DEFINE ENCAPSULATION. Encapsulation is the process of combining data and functions

More information

QUIZ How do we implement run-time constants and. compile-time constants inside classes?

QUIZ How do we implement run-time constants and. compile-time constants inside classes? QUIZ How do we implement run-time constants and compile-time constants inside classes? Compile-time constants in classes The static keyword inside a class means there s only one instance, regardless of

More information

C++ Addendum: Inheritance of Special Member Functions. Constructors Destructor Construction and Destruction Order Assignment Operator

C++ Addendum: Inheritance of Special Member Functions. Constructors Destructor Construction and Destruction Order Assignment Operator C++ Addendum: Inheritance of Special Member Functions Constructors Destructor Construction and Destruction Order Assignment Operator What s s Not Inherited? The following methods are not inherited: Constructors

More information

AC OB S. Multi-threaded FW framework (OS) for embedded ARM systems Torsten Jaekel, June 2014

AC OB S. Multi-threaded FW framework (OS) for embedded ARM systems Torsten Jaekel, June 2014 AC OB S Multi-threaded FW framework (OS) for embedded ARM systems Torsten Jaekel, June 2014 ACOBS ACtive OBject (operating) System Simplified FW System for Multi-Threading on ARM embedded systems ACOBS

More information

EMBEDDED SYSTEMS PROGRAMMING More About Languages

EMBEDDED SYSTEMS PROGRAMMING More About Languages EMBEDDED SYSTEMS PROGRAMMING 2015-16 More About Languages JAVA: ANNOTATIONS (1/2) Structured comments to source code (=metadata). They provide data about the code, but they are not part of the code itself

More information

Chapter 10 Introduction to Classes

Chapter 10 Introduction to Classes C++ for Engineers and Scientists Third Edition Chapter 10 Introduction to Classes CSc 10200! Introduction to Computing Lecture 20-21 Edgardo Molina Fall 2013 City College of New York 2 Objectives In this

More information

Ch. 11: References & the Copy-Constructor. - continued -

Ch. 11: References & the Copy-Constructor. - continued - Ch. 11: References & the Copy-Constructor - continued - const references When a reference is made const, it means that the object it refers cannot be changed through that reference - it may be changed

More information

CPSC 427: Object-Oriented Programming

CPSC 427: Object-Oriented Programming CPSC 427: Object-Oriented Programming Michael J. Fischer Lecture 20 November 14, 2016 CPSC 427, Lecture 20 1/19 Templates Casts and Conversions CPSC 427, Lecture 20 2/19 Templates CPSC 427, Lecture 20

More information

DATA STRUCTURES CHAPTER 1

DATA STRUCTURES CHAPTER 1 DATA STRUCTURES CHAPTER 1 FOUNDATIONAL OF DATA STRUCTURES This unit introduces some basic concepts that the student needs to be familiar with before attempting to develop any software. It describes data

More information

Introduction to Programming (Java) 4/12

Introduction to Programming (Java) 4/12 Introduction to Programming (Java) 4/12 Michal Krátký Department of Computer Science Technical University of Ostrava Introduction to Programming (Java) 2008/2009 c 2006 2008 Michal Krátký Introduction

More information

REAL-TIME MULTITASKING KERNEL FOR IBM-BASED MICROCOMPUTERS

REAL-TIME MULTITASKING KERNEL FOR IBM-BASED MICROCOMPUTERS Malaysian Journal of Computer Science, Vol. 9 No. 1, June 1996, pp. 12-17 REAL-TIME MULTITASKING KERNEL FOR IBM-BASED MICROCOMPUTERS Mohammed Samaka School of Computer Science Universiti Sains Malaysia

More information

High-Level Language VMs

High-Level Language VMs High-Level Language VMs Outline Motivation What is the need for HLL VMs? How are these different from System or Process VMs? Approach to HLL VMs Evolutionary history Pascal P-code Object oriented HLL VMs

More information

Motivation was to facilitate development of systems software, especially OS development.

Motivation was to facilitate development of systems software, especially OS development. A History Lesson C Basics 1 Development of language by Dennis Ritchie at Bell Labs culminated in the C language in 1972. Motivation was to facilitate development of systems software, especially OS development.

More information

Chapter 1: Object-Oriented Programming Using C++

Chapter 1: Object-Oriented Programming Using C++ Chapter 1: Object-Oriented Programming Using C++ Objectives Looking ahead in this chapter, we ll consider: Abstract Data Types Encapsulation Inheritance Pointers Polymorphism Data Structures and Algorithms

More information

Java Threads and intrinsic locks

Java Threads and intrinsic locks Java Threads and intrinsic locks 1. Java and OOP background fundamentals 1.1. Objects, methods and data One significant advantage of OOP (object oriented programming) is data encapsulation. Each object

More information

Operating Systems : Overview

Operating Systems : Overview Operating Systems : Overview Bina Ramamurthy CSE421 8/29/2006 B.Ramamurthy 1 Topics for discussion What will you learn in this course? (goals) What is an Operating System (OS)? Evolution of OS Important

More information

UNIX input and output

UNIX input and output UNIX input and output Disk files In UNIX a disk file is a finite sequence of bytes, usually stored on some nonvolatile medium. Disk files have names, which are called paths. We won t discuss file naming

More information

Vpcic32D.VXD, PCICC32.SYS & PCICC32_NI

Vpcic32D.VXD, PCICC32.SYS & PCICC32_NI Vpcic32D.VXD, PCICC32.SYS & PCICC32_NI Windows 95/98 driver, Windows-NT driver for PCI-to-CAMAC Interface User s Manual April 2001 1 *00527.A1 General Remarks The only purpose of this manual is a description

More information

G52CPP C++ Programming Lecture 13

G52CPP C++ Programming Lecture 13 G52CPP C++ Programming Lecture 13 Dr Jason Atkin http://www.cs.nott.ac.uk/~jaa/cpp/ g52cpp.html 1 Last lecture Function pointers Arrays of function pointers Virtual and non-virtual functions vtable and

More information

Operating Systems 2010/2011

Operating Systems 2010/2011 Operating Systems 2010/2011 Input/Output Systems part 1 (ch13) Shudong Chen 1 Objectives Discuss the principles of I/O hardware and its complexity Explore the structure of an operating system s I/O subsystem

More information

TS Thread Library Reference. Version 6.2, December 2004

TS Thread Library Reference. Version 6.2, December 2004 TS Thread Library Reference Version 6.2, December 2004 IONA, IONA Technologies, the IONA logo, Orbix, Orbix/E, Orbacus, Artix, Orchestrator, Mobile Orchestrator, Enterprise Integrator, Adaptive Runtime

More information

Technical Information Manual

Technical Information Manual Technical Information Manual Revision n. 2 21 October 2002 MOD. A1303 PCI CAENET CONTROLLER NPO: 00109/01:A1303.MUTx/02 CAEN will repair or replace any product within the guarantee period if the Guarantor

More information

CERTIFICATE IN WEB PROGRAMMING

CERTIFICATE IN WEB PROGRAMMING COURSE DURATION: 6 MONTHS CONTENTS : CERTIFICATE IN WEB PROGRAMMING 1. PROGRAMMING IN C and C++ Language 2. HTML/CSS and JavaScript 3. PHP and MySQL 4. Project on Development of Web Application 1. PROGRAMMING

More information

Structure of Programming Languages Lecture 10

Structure of Programming Languages Lecture 10 Structure of Programming Languages Lecture 10 CS 6636 4536 Spring 2017 CS 6636 4536 Lecture 10: Classes... 1/23 Spring 2017 1 / 23 Outline 1 1. Types Type Coercion and Conversion Type Classes, Generics,

More information

What s An OS? Cyclic Executive. Interrupts. Advantages Simple implementation Low overhead Very predictable

What s An OS? Cyclic Executive. Interrupts. Advantages Simple implementation Low overhead Very predictable What s An OS? Provides environment for executing programs Process abstraction for multitasking/concurrency scheduling Hardware abstraction layer (device drivers) File systems Communication Do we need an

More information

UNIX Input/Output Buffering

UNIX Input/Output Buffering UNIX Input/Output Buffering When a C/C++ program begins execution, the operating system environment is responsible for opening three files and providing file pointers to them: stdout standard output stderr

More information

Chapter 4: Threads. Overview Multithreading Models Thread Libraries Threading Issues Operating System Examples Windows XP Threads Linux Threads

Chapter 4: Threads. Overview Multithreading Models Thread Libraries Threading Issues Operating System Examples Windows XP Threads Linux Threads Chapter 4: Threads Overview Multithreading Models Thread Libraries Threading Issues Operating System Examples Windows XP Threads Linux Threads Chapter 4: Threads Objectives To introduce the notion of a

More information

Preface... (vii) CHAPTER 1 INTRODUCTION TO COMPUTERS

Preface... (vii) CHAPTER 1 INTRODUCTION TO COMPUTERS Contents Preface... (vii) CHAPTER 1 INTRODUCTION TO COMPUTERS 1.1. INTRODUCTION TO COMPUTERS... 1 1.2. HISTORY OF C & C++... 3 1.3. DESIGN, DEVELOPMENT AND EXECUTION OF A PROGRAM... 3 1.4 TESTING OF PROGRAMS...

More information

System-On-Chip Architecture Modeling Style Guide

System-On-Chip Architecture Modeling Style Guide Center for Embedded Computer Systems University of California, Irvine System-On-Chip Architecture Modeling Style Guide Junyu Peng Andreas Gerstlauer Rainer Dömer Daniel D. Gajski Technical Report CECS-TR-04-22

More information

DAB/MOT Data Carousel System Support Library Interface Definition

DAB/MOT Data Carousel System Support Library Interface Definition DAB/MOT Data Carousel System Support Library Interface Definition D. Knox & O. Gardiner 98-0003-001/1.3 5th Jul 1999 ENSIGMA Ltd Turing House Station Road Chepstow GWENT NP6 5PB Ensigma Ltd. Page 2 of

More information

CS3157: Advanced Programming. Outline

CS3157: Advanced Programming. Outline CS3157: Advanced Programming Lecture #12 Apr 3 Shlomo Hershkop shlomo@cs.columbia.edu 1 Outline Intro CPP Boring stuff: Language basics: identifiers, data types, operators, type conversions, branching

More information

Operating System Architecture. CS3026 Operating Systems Lecture 03

Operating System Architecture. CS3026 Operating Systems Lecture 03 Operating System Architecture CS3026 Operating Systems Lecture 03 The Role of an Operating System Service provider Provide a set of services to system users Resource allocator Exploit the hardware resources

More information

Chapter 9 :: Subroutines and Control Abstraction

Chapter 9 :: Subroutines and Control Abstraction Chapter 9 :: Subroutines and Control Abstraction Programming Language Pragmatics, Fourth Edition Michael L. Scott Copyright 2016 Elsevier 1 Chapter09_Subroutines_and_Control_Abstraction_4e - Tue November

More information

Chapter 1 GETTING STARTED. SYS-ED/ Computer Education Techniques, Inc.

Chapter 1 GETTING STARTED. SYS-ED/ Computer Education Techniques, Inc. Chapter 1 GETTING STARTED SYS-ED/ Computer Education Techniques, Inc. Objectives You will learn: Java platform. Applets and applications. Java programming language: facilities and foundation. Memory management

More information

Motivation was to facilitate development of systems software, especially OS development.

Motivation was to facilitate development of systems software, especially OS development. A History Lesson C Basics 1 Development of language by Dennis Ritchie at Bell Labs culminated in the C language in 1972. Motivation was to facilitate development of systems software, especially OS development.

More information

Outline. Threads. Single and Multithreaded Processes. Benefits of Threads. Eike Ritter 1. Modified: October 16, 2012

Outline. Threads. Single and Multithreaded Processes. Benefits of Threads. Eike Ritter 1. Modified: October 16, 2012 Eike Ritter 1 Modified: October 16, 2012 Lecture 8: Operating Systems with C/C++ School of Computer Science, University of Birmingham, UK 1 Based on material by Matt Smart and Nick Blundell Outline 1 Concurrent

More information

Constants, References

Constants, References CS 246: Software Abstraction and Specification Constants, References Readings: Eckel, Vol. 1 Ch. 8 Constants Ch. 11 References and the Copy Constructor U Waterloo CS246se (Spring 2011) p.1/14 Uses of const

More information

BCS THE CHARTERED INSTITUTE FOR IT. BCS HIGHER EDUCATION QUALIFICATIONS BCS Level 5 Diploma in IT OBJECT ORIENTED PROGRAMMING

BCS THE CHARTERED INSTITUTE FOR IT. BCS HIGHER EDUCATION QUALIFICATIONS BCS Level 5 Diploma in IT OBJECT ORIENTED PROGRAMMING BCS THE CHARTERED INSTITUTE FOR IT BCS HIGHER EDUCATION QUALIFICATIONS BCS Level 5 Diploma in IT OBJECT ORIENTED PROGRAMMING Wednesady 23 rd March 2016 Afternoon Answer any FOUR questions out of SIX. All

More information

Introduction to VME. Laboratory for Data Acquisition and Controls. Last modified on 4/16/18 5:19 PM

Introduction to VME. Laboratory for Data Acquisition and Controls. Last modified on 4/16/18 5:19 PM Introduction to VME Laboratory for Data Acquisition and Controls Last modified on 4/16/18 5:19 PM VMEbus VMEbus is a computer architecture VME = Versa Module Eurocard 1980 Bus is a generic term describing

More information

CSE 160 Lecture 7. C++11 threads C++11 memory model

CSE 160 Lecture 7. C++11 threads C++11 memory model CSE 160 Lecture 7 C++11 threads C++11 memory model Today s lecture C++ threads The C++11 Memory model 2013 Scott B. Baden / CSE 160 / Winter 2013 2 C++11 Threads Via , C++ supports a threading

More information

Brook+ Data Types. Basic Data Types

Brook+ Data Types. Basic Data Types Brook+ Data Types Important for all data representations in Brook+ Streams Constants Temporary variables Brook+ Supports Basic Types Short Vector Types User-Defined Types 29 Basic Data Types Basic data

More information

CSC 533: Organization of Programming Languages. Spring 2005

CSC 533: Organization of Programming Languages. Spring 2005 CSC 533: Organization of Programming Languages Spring 2005 Language features and issues variables & bindings data types primitive complex/structured expressions & assignments control structures subprograms

More information

Stream Computing using Brook+

Stream Computing using Brook+ Stream Computing using Brook+ School of Electrical Engineering and Computer Science University of Central Florida Slides courtesy of P. Bhaniramka Outline Overview of Brook+ Brook+ Software Architecture

More information

Short Term Courses (Including Project Work)

Short Term Courses (Including Project Work) Short Term Courses (Including Project Work) Courses: 1.) Microcontrollers and Embedded C Programming (8051, PIC & ARM, includes a project on Robotics) 2.) DSP (Code Composer Studio & MATLAB, includes Embedded

More information

SmartHeap for Multi-Core

SmartHeap for Multi-Core SmartHeap for Multi-Core Getting Started and Platform Guide for Linux Version 11.2 SmartHeap and HeapAgent are trademarks of Compuware Corporation. All other trademarks are the property of their respective

More information

Using kgdb and the kgdb Internals

Using kgdb and the kgdb Internals Using kgdb and the kgdb Internals Jason Wessel jason.wessel@windriver.com Tom Rini trini@kernel.crashing.org Amit S. Kale amitkale@linsyssoft.com Using kgdb and the kgdb Internals by Jason Wessel by Tom

More information

Generalised User Interface for Embedded Applications using an LCD screen and keypad.

Generalised User Interface for Embedded Applications using an LCD screen and keypad. Generalised User Interface for Embedded Applications using an LCD screen and keypad. This article is concerned with firmware design and implementation for microcontroller-based devices incorporating a

More information

MODEL-BASED DEVELOPMENT -TUTORIAL

MODEL-BASED DEVELOPMENT -TUTORIAL MODEL-BASED DEVELOPMENT -TUTORIAL 1 Objectives To get familiar with the fundamentals of Rational Rhapsody. You start with the simplest example possible. You end with more complex functionality, and a more

More information

What is Polymorphism? Quotes from Deitel & Deitel s. Why polymorphism? How? How? Polymorphism Part 1

What is Polymorphism? Quotes from Deitel & Deitel s. Why polymorphism? How? How? Polymorphism Part 1 Polymorphism Part 1 What is Polymorphism? Polymorphism refers to a programming language s ability to process objects differently depending on their data type or class. Number person real complex kid adult

More information

EL2310 Scientific Programming

EL2310 Scientific Programming (pronobis@kth.se) Overview Overview Wrap Up Introduction to Object Oriented Paradigm More on and Members Operator Overloading Last time Intro to C++ Differences between C and C++ Intro to OOP Today Object

More information

G Programming Languages - Fall 2012

G Programming Languages - Fall 2012 G22.2110-003 Programming Languages - Fall 2012 Lecture 3 Thomas Wies New York University Review Last week Names and Bindings Lifetimes and Allocation Garbage Collection Scope Outline Control Flow Sequencing

More information

Appendix. Grammar. A.1 Introduction. A.2 Keywords. There is no worse danger for a teacher than to teach words instead of things.

Appendix. Grammar. A.1 Introduction. A.2 Keywords. There is no worse danger for a teacher than to teach words instead of things. A Appendix Grammar There is no worse danger for a teacher than to teach words instead of things. Marc Block Introduction keywords lexical conventions programs expressions statements declarations declarators

More information

Using NCSL DAQ Software to Readout a CAEN V792 QDC. Timothy Hoagland

Using NCSL DAQ Software to Readout a CAEN V792 QDC. Timothy Hoagland Using NCSL DAQ Software to Readout a CAEN V792 QDC Timothy Hoagland December 2, 2004 Abstract The paper s purpose is to assist the reader in setting up and reading out data from a CAEN V792. It covers

More information

What are the characteristics of Object Oriented programming language?

What are the characteristics of Object Oriented programming language? What are the various elements of OOP? Following are the various elements of OOP:- Class:- A class is a collection of data and the various operations that can be performed on that data. Object- This is

More information

Chapter 8 :: Subroutines and Control Abstraction. Final Test. Final Test Review Tomorrow

Chapter 8 :: Subroutines and Control Abstraction. Final Test. Final Test Review Tomorrow Chapter 8 :: Subroutines and Control Abstraction Programming Language Pragmatics Michael L. Scott Administrative Notes Final Test Thursday, August 3 2006 at 11:30am No lecture before or after the mid-term

More information

CPSC 427: Object-Oriented Programming

CPSC 427: Object-Oriented Programming CPSC 427: Object-Oriented Programming Michael J. Fischer Lecture 21 November 14, 2018 CPSC 427, Lecture 21, November 14, 2018 1/23 Singleton Design Pattern (revisited) More on Functions Casts and Conversions

More information

Basic memory model Using functions Writing functions. Basics Prototypes Parameters Return types Functions and memory Names and namespaces

Basic memory model Using functions Writing functions. Basics Prototypes Parameters Return types Functions and memory Names and namespaces Basic memory model Using functions Writing functions Basics Prototypes Parameters Return types Functions and memory Names and namespaces When a program runs it requires main memory (RAM) space for Program

More information

Java Threads. COMP 585 Noteset #2 1

Java Threads. COMP 585 Noteset #2 1 Java Threads The topic of threads overlaps the boundary between software development and operation systems. Words like process, task, and thread may mean different things depending on the author and the

More information

Distributed Objects and Remote Invocation. Programming Models for Distributed Applications

Distributed Objects and Remote Invocation. Programming Models for Distributed Applications Distributed Objects and Remote Invocation Programming Models for Distributed Applications Extending Conventional Techniques The remote procedure call model is an extension of the conventional procedure

More information

Orbix TS Thread Library Reference

Orbix TS Thread Library Reference Orbix 6.3.9 TS Thread Library Reference Micro Focus The Lawn 22-30 Old Bath Road Newbury, Berkshire RG14 1QN UK http://www.microfocus.com Copyright Micro Focus 2017. All rights reserved. MICRO FOCUS, the

More information

XerXes: XIA Host Library Specification

XerXes: XIA Host Library Specification XerXes: XIA Host Library Specification Revision 1.01 X-Ray Instrumentation Associates 8450 Central Ave. Newark, CA 94560 USA Tel: (510)494-9020; Fax: (510)494-9040 http://www.xia.com/ For additional information

More information

User VME DAQ. Tools Applications CUSTOM LIBRARY THAT EXPORTS CAENCOM FUNCTIONS. CAEN COMM user implemented CAEN. PCI & PCIe Controllers.

User VME DAQ. Tools Applications CUSTOM LIBRARY THAT EXPORTS CAENCOM FUNCTIONS. CAEN COMM user implemented CAEN. PCI & PCIe Controllers. Tools for Discovery n Rev. 0 - C+ + LabView User VME DAQ C/C++ Tools LabView Tools Applications Libraries CUSTOM LIBRARY THAT EXPORTS CAENCOM FUNCTIONS CAEN COMM user implemented CAEN COMM Library CAENVMElib

More information

Exceptions, Case Study-Exception handling in C++.

Exceptions, Case Study-Exception handling in C++. PART III: Structuring of Computations- Structuring the computation, Expressions and statements, Conditional execution and iteration, Routines, Style issues: side effects and aliasing, Exceptions, Case

More information

AVL 4 4 PDV DECLARE 7 _NEW_

AVL 4 4 PDV DECLARE 7 _NEW_ Glossary Program Control... 2 SAS Variable... 2 Program Data Vector (PDV)... 2 SAS Expression... 2 Data Type... 3 Scalar... 3 Non-Scalar... 3 Big O Notation... 3 Hash Table... 3 Hash Algorithm... 4 Hash

More information

Polymorphism Part 1 1

Polymorphism Part 1 1 Polymorphism Part 1 1 What is Polymorphism? Polymorphism refers to a programming language s ability to process objects differently depending on their data type or class. Number person real complex kid

More information

Programmazione Avanzata e Paradigmi Ingegneria e Scienze Informatiche - UNIBO a.a 2013/2014 Lecturer: Alessandro Ricci

Programmazione Avanzata e Paradigmi Ingegneria e Scienze Informatiche - UNIBO a.a 2013/2014 Lecturer: Alessandro Ricci v1.0 20130323 Programmazione Avanzata e Paradigmi Ingegneria e Scienze Informatiche - UNIBO a.a 2013/2014 Lecturer: Alessandro Ricci [module lab 2.1] CONCURRENT PROGRAMMING IN JAVA: INTRODUCTION 1 CONCURRENT

More information

Concurrency, Thread. Dongkun Shin, SKKU

Concurrency, Thread. Dongkun Shin, SKKU Concurrency, Thread 1 Thread Classic view a single point of execution within a program a single PC where instructions are being fetched from and executed), Multi-threaded program Has more than one point

More information

DISTRIBUTED MEMORY IN A HETEROGENEOUS NETWORK, AS USED IN THE CERN. PS-COMPLEX TIMING SYSTEM

DISTRIBUTED MEMORY IN A HETEROGENEOUS NETWORK, AS USED IN THE CERN. PS-COMPLEX TIMING SYSTEM 1 DISTRIBUTED MEMORY IN A HETEROGENEOUS NETWORK, AS USED IN THE CERN. PS-COMPLEX TIMING SYSTEM ABSTRACT V. Kovaltsov 1, J. Lewis PS Division, CERN, CH-1211 Geneva 23, Switzerland The Distributed Table

More information

Platform Objects. Introduction. Methods. meiplatformalloc meiplatformassertset

Platform Objects. Introduction. Methods. meiplatformalloc meiplatformassertset Platform Objects Platform Objects Introduction The Platform module provides a common interface to platform-specific functionality, such as memory allocation, resource locking, interrupts, signalling, and

More information

2. The object-oriented paradigm!

2. The object-oriented paradigm! 2. The object-oriented paradigm! Plan for this section:! n Look at things we have to be able to do with a programming language! n Look at Java and how it is done there" Note: I will make a lot of use of

More information

Object-oriented programming in...

Object-oriented programming in... Programming Languages Week 12 Object-oriented programming in... College of Information Science and Engineering Ritsumeikan University plan this week intro to Java advantages and disadvantages language

More information

OPERATING SYSTEM. Chapter 4: Threads

OPERATING SYSTEM. Chapter 4: Threads OPERATING SYSTEM Chapter 4: Threads Chapter 4: Threads Overview Multicore Programming Multithreading Models Thread Libraries Implicit Threading Threading Issues Operating System Examples Objectives To

More information

Exercise 7 References, Arrays, Vectors

Exercise 7 References, Arrays, Vectors Exercise 7 References, Arrays, Vectors Informatik I für Mathematiker und Physiker (HS 2015) Yeara Kozlov Slides courtesy of Kaan Yücer & Endri Dibra B. Gaertner, ETH Zürich, 2015 Agenda HW #5 Feedback

More information

Java How to Program, 10/e. Copyright by Pearson Education, Inc. All Rights Reserved.

Java How to Program, 10/e. Copyright by Pearson Education, Inc. All Rights Reserved. Java How to Program, 10/e Education, Inc. All Rights Reserved. Each class you create becomes a new type that can be used to declare variables and create objects. You can declare new classes as needed;

More information

Example problem: Solution of the 2D unsteady heat equation.

Example problem: Solution of the 2D unsteady heat equation. Chapter 1 Example problem: Solution of the 2D unsteady heat equation. This is our first time-dependent example problem. We will demonstrate that, compared to the solution of steady problems, the solution

More information

Processes. Johan Montelius KTH

Processes. Johan Montelius KTH Processes Johan Montelius KTH 2017 1 / 47 A process What is a process?... a computation a program i.e. a sequence of operations a set of data structures a set of registers means to interact with other

More information

Orbix Release Notes

Orbix Release Notes Contents Orbix 2.3.4 Release Notes September 1999 Introduction 2 Development Environments 2 Solaris 2 Year 2000 Compliance 2 Solaris 2.5.1 Y2K Patches 3 NT 3 Compatibility with Other IONA Products 4 New

More information

CS 3305 Intro to Threads. Lecture 6

CS 3305 Intro to Threads. Lecture 6 CS 3305 Intro to Threads Lecture 6 Introduction Multiple applications run concurrently! This means that there are multiple processes running on a computer Introduction Applications often need to perform

More information

JScript Reference. Contents

JScript Reference. Contents JScript Reference Contents Exploring the JScript Language JScript Example Altium Designer and Borland Delphi Run Time Libraries Server Processes JScript Source Files PRJSCR, JS and DFM files About JScript

More information

https://asd-pa.perfplusk12.com/admin/admin_curric_maps_display.aspx?m=5507&c=618&mo=18917&t=191&sy=2012&bl...

https://asd-pa.perfplusk12.com/admin/admin_curric_maps_display.aspx?m=5507&c=618&mo=18917&t=191&sy=2012&bl... Page 1 of 13 Units: - All - Teacher: ProgIIIJavaI, CORE Course: ProgIIIJavaI Year: 2012-13 Intro to Java How is data stored by a computer system? What does a compiler do? What are the advantages of using

More information

mmap: Memory Mapped Files in R

mmap: Memory Mapped Files in R mmap: Memory Mapped Files in R Jeffrey A. Ryan August 1, 2011 Abstract The mmap package offers a cross-platform interface for R to information that resides on disk. As dataset grow, the finite limits of

More information

A process. the stack

A process. the stack A process Processes Johan Montelius What is a process?... a computation KTH 2017 a program i.e. a sequence of operations a set of data structures a set of registers means to interact with other processes

More information