Rulbus Device Class Library for Microsoft Windows: Main Page

Rulbus Device Class Library for Microsoft Windows Documentation

0.2.0 (stable)

The Rulbus Device Class Library (RDCL) is a Borland C++ library (rulbusdcl.lib) for the Microsoft Windows 95/98/NT/2000/XP platform. It contains classes to use the most popular Rulbus modules and it supports the ISA Rulbus Interface as well as the EPP Rulbus Interface.

This manual contains the following sections:

  • User Manual
  • Reference Manual
  • Developer Manual

The User Manual tells you more about Rulbus and Rulbus Interfaces and it describes how to use this class library.

The Reference Manual describes the classes and functions available for the various Rulbus modules supported. To discover how to use a certain Rulbus module, look up its documentation page by Rulbus number in the Contents pane at the left, for example Modules | Reference Manual | RB8510 12-bit DAC for the dual 12-bit DAC and read the documentation of the module and its class.

To learn about the implementation of the Rulbus Device Class Library, explore the Developer Manual. It describes the setup of the library and it describes the underpinnigs of the Rulbus devices and of the Rulbus interfaces. Furthermore it explains how to write a class for a Rulbus device.

RDCL License

Copyright © 2003-2004, by Leiden University.

RDCL is written by Martin J. Moene <m.j.moene@eld.physics.LeidenUniv.nl>

Permission to use, copy, modify, and distribute this software and its documentation under the terms of the GNU General Public License is hereby granted. No representations are made about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty. See the GNU General Public License for more details.

Web page: http://www.eld.leidenuniv.nl/~moene/software/rdcl/

Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: File Index

Rulbus Device Class Library for Microsoft Windows File List

Here is a list of all documented files with brief descriptions:
Assertion.h [code]
canio.h [code]
Common.h [code]
ConfigBuilder.h [code]
ConfigContext.h [code]
ConfigParser.h [code]
ConfigScanner.h [code]
EppRulbusInterface.h [code]
Exception.h [code]
IoFormat.h [code]
IsaRulbusInterface.h [code]
PiaVia.h [code]
Portio.h [code]
rb8506_pport.h [code]
rb8506_sifu.h [code]
rb8509_adc12.h [code]
rb8510_dac12.h [code]
rb8513_timebase.h [code]
rb8514_delay.h [code]
rb8515_clock.h [code]
rb8905_adc12.h [code]
rb9005_amplifier.h [code]
rb9603_monochromator.h [code]
RulbusDevice.h [code]
RulbusDeviceFactory.h [code]
RulbusDeviceList.h [code]
RulbusDeviceProxy.h [code]
RulbusInterface.h [code]
RulbusInterfaceFactory.h [code]
Shims.h [code]
Singleton.h [code]
version.h [code]
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Annotated Index

Rulbus Device Class Library for Microsoft Windows Class List

Here are the classes, structs, unions and interfaces with brief descriptions:
AssertException | Design-by-contract general assertion
Assertion | Base for design-by-contract assert exception
BoundIoFormat | Bind collected formatting information to a value
ConfigBuilder | Abstract base class for configuration builders
ConfigContext | Context for ConfigParser (empty)
ConfigEofToken | Token indicating end-of-file
ConfigErrorToken | Token indicating an unrecognized token (error)
ConfigKeyword | Table containg token code, token string pairs
ConfigListBuilder | Rulbus device list configuration builder
ConfigNumberToken | Token that reads and represents an integral or floating point number
ConfigParser | Parse a Rulbus configuration file
ConfigParser::ParseError | Parser error used internally by ConfigParser
ConfigPrinter | Rulbus configuration printer
ConfigScanner | Scan input and return lexical tokens
ConfigSpecialToken | Token that reads and represents a special token, like brace and semicolon
ConfigStringToken | Token that reads and represents a string
ConfigToken | Abstract base class for concrete tokens, like keywords, numbers, strings
ConfigWordToken | Token that reads and represents a keyword
DbcException | Design-by-contract exception
EnsureException | Design-by-contract postcondition exception
EppRulbusInterface | EPP Rulbus Interface
IoFormat | Formatting manipulator
IsaRulbusInterface | ISA Rulbus Interface
isEqual | Predicate for apgorithms to compare floating types like Volt, Time and Freq
NeverGetHereException | Design-by-contract never reach this location
Pia | Pia implementation
PiaVia | Interface for Pia and Via
PportAddresses | Determine if a parallel port base addresses is valid
RB8506_Pia | Dual parallel interface (Pia)
RB8506_Sifu | Input-output controller box (SIFU)
RB8506_Via | Dual parallel interface (Via)
RB8509_Adc12 | 8-channel 12-bit ADC (RB8509)
RB8510_Dac12 | Dual 12-bit DAC (RB8510)
RB8513_timebase | Programmable timebase (RB8513)
RB8514_delay | Programmable time delay (RB8514)
RB8515_clock | Clock for delay module RB8514 (RB8515)
RB8515_clock::FreqTable | The frequency--code mapping table
RB8905_Adc12 | High speed 12-bit ADC (BF)
RB9005_amplifier |
RB9005_amplifier::RegInfo | < type for gain register masks and shifts
RB9603_monochromator |
RequireException | Design-by-contract precondition exception
RulbusAddressError | Rulbus addressing error
RulbusCloseError | Rulbus device close (remove) error
RulbusConfigError | Rulbus configuration file error
RulbusContextError | Rulbus context error
RulbusDataError | Rulbus data error
RulbusDevice | Rulbus device base class, Bridge(151)
RulbusDeviceFactory | Create Rulbus devices from configuration file; may throw RulbusConfigError
RulbusDeviceProxy | Rulbus device access-protecting proxy
RulbusError | Rulbus errors base class
RulbusHandleError | Rulbus device handle error
RulbusInterfaceError | Rulbus Interface error
RulbusInterfaceFactory | The Rulbus Interface Abstract Factory(87) Singleton(127)
RulbusOpenError | Rulbus device open error
RulbusParseError | Configuration file parser error
RulbusRangeError | Rulbus parameter range error
RulbusScanError | Configuration file scanner error
RulbusTimeoutError | Rulbus timeout error
Singleton | Template base class for singleton pattern
TheRulbusDeviceList | The Rulbus device list Singleton(127)
TheRulbusInterface | Rulbus Interface abstract base class
Via | Via implementation
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: AssertException class Reference

AssertException Class Reference

#include <Assertion.h>

Inherits DbcException.

List of all members.

Detailed Description

AssertException is a general assertion exception.

See also design-by-contract assertions.

Public Member Functions

AssertException (CharCptr aExpression, CharCptr aFile, int aLine)
constructor.

The documentation for this class was generated from the following file:
  • Assertion.h
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Assertion class Reference

Assertion Class Reference
[Assertion]

#include <Assertion.h>

Inherited by DbcException.

List of all members.

Detailed Description

Class Assertion provides the fundament for design-by-contract exception classes that are based on std::exception.

See also design-by-contract assertions.

Public Member Functions

Construction
Assertion (CharCptr aReason, CharCptr aFile, int aLine)
constructor.

Assertion (AssertionCref rhs)
copy constructor.

virtual | ~Assertion ()
destructor.

Operators
AssertionRef | operator= (AssertionCref rhs)
copy assignment.

bool | operator== (AssertionCref rhs)
test for equality.

Accessors
virtual CharCptr | what () const
return a description of the assertion, as reason().

String | reason () const
return the assertion expression as a string.

String | file () const
return the filename.

int | line () const
return the linenumber.

Protected Attributes

String theReason
the expression as a string

String theFile
the filename

int | theLine
the linenumber

The documentation for this class was generated from the following file:
  • Assertion.h
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: TemplateBoundIoFormat class Reference

BoundIoFormat Class Template Reference

#include <IoFormat.h>

List of all members.

Detailed Description

template<typename T>
class Rulbus::BoundIoFormat< T >

BoundIoFormat forms a <formatting, value> tuple that can be written to a stream with operator<<(ostream&,const BoundIoFormat&) .

Public Member Functions

BoundIoFormat (const IoFormat< T > &f, const T &v)
Constructor.

Public Attributes

const IoFormat< T > & | theFormat
the IoFormat

T | theValue
the value

The documentation for this class was generated from the following file:
  • IoFormat.h
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigBuilder class Reference

ConfigBuilder Class Reference

#include <ConfigBuilder.h>

Inherited by ConfigListBuilder, and ConfigPrinter.

List of all members.

Detailed Description

Abstract class ConfigBuilder is used by class ConfigParser to 'add' Rulbus devices to what is being built.

Concrete builders are classes ConfigListBuilder and ConfigPrinter.

A ConfigListBuilder adds the Rulbus device to TheRulbusDeviceList, whereas a ConfigPrinter lets the Rulbus device print itself.

Public Member Functions

virtual void | add (RulbusDevicePtr ptr)=0
add a Rulbus device to the object being built.

virtual void | check () const
check the built object for consistency; default implementation: do nothing.

The documentation for this class was generated from the following file:
  • ConfigBuilder.h
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigContext class Reference

ConfigContext Class Reference

#include <ConfigContext.h>

Detailed Description

Class ConfigContext is used by class ConfigParser.

For other language compilers, the context may contain information on the variables in the current scope. However for the Rulbus device configuration compiler, context is not used (now).

The documentation for this class was generated from the following file:
  • ConfigContext.h
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigEofToken class Reference

ConfigEofToken Class Reference

#include <ConfigScanner.h>

Inherits ConfigToken.

List of all members.

Detailed Description

Class ConfigEofToken indicates that end-of-file has been reached.

Public Member Functions

void | get (std::istream *is)
read the next token (abstract)

void | print () const
print an end-of-file token.

The documentation for this class was generated from the following files:
  • ConfigScanner.h
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigErrorToken class Reference

ConfigErrorToken Class Reference

#include <ConfigScanner.h>

Inherits ConfigToken.

List of all members.

Detailed Description

Class ConfigErrorToken indicates that the token could not be recognized.

Public Member Functions

void | get (std::istream *is)
scan an unrecognized (error) token, throw logic_error.

void | print () const
print an error token.

The documentation for this class was generated from the following files:
  • ConfigScanner.h
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigKeyword struct Reference

ConfigKeyword Struct Reference

List of all members.

Detailed Description

ConfigScanner uses a ConfigKeyword table to look up the the keywords that can appear in a Rulbus configuration file.

Public Attributes

ConfigToken::TokenCode c
the token code

const char * s
the token string representation

The documentation for this struct was generated from the following file:
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigListBuilder class Reference

ConfigListBuilder Class Reference

#include <ConfigBuilder.h>

Inherits ConfigBuilder.

List of all members.

Detailed Description

Class ConfigListBuilder is a concrete builder that adds Rulbus devices to TheRulbusDeviceList.

Public Member Functions

ConfigListBuilder ()
constructor.

void | add (RulbusDevicePtr ptr)
add a Rulbus device to the list.

void | check () const
check the list for valid rack and Rulbus addresses and if no addresses do overlap.

The documentation for this class was generated from the following files:
  • ConfigBuilder.h
  • ConfigBuilder.cpp
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigNumberToken class Reference

ConfigNumberToken Class Reference

#include <ConfigScanner.h>

Inherits ConfigToken.

List of all members.

Detailed Description

Class ConfigNumberToken reads and represents numbers.

Public Member Functions

void | get (std::istream *is)
scan a number token.

void | print () const
print a number token.

Protected Member Functions

Real | suffix (char chr)

The documentation for this class was generated from the following files:
  • ConfigScanner.h
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigParser class Reference

ConfigParser Class Reference

#include <ConfigParser.h>

List of all members.

Detailed Description

Class ConfigParser is used by class RulbusDeviceFactory to process a Rulbus configuration file.

A ConfigParser reads a Rulbus configuration file that specifies Rulbus devices and it creates these devices and makes them accessible via the Rulbus Device List.

The parser uses a lexical analyzer, or scanner to read the configuration file a token at a time and it uses a builder to create the Rulbus devices specified in this configuration file. Currently the context is not used. (In other language compilers it may contain information on the variables in the current scope.)

A parser can be used as follows.

 ConfigScanner     scanner( cin );
 ConfigListBuilder builder;
 ConfigContext     context;
 ConfigParser      parser( scanner, builder, context );

 parser.parse();

Here is a simple Rulbus configuration file.

# rulbus-small.conf - example rulbus device configuration file.

rack "top"
{
    address = 0

    rb8509_adc12 "adc"
    rb8510_dac12 "dac-ch0" { address = 0xD0 }
    rb8510_dac12 "dac-ch1" { address = 0xD2; bipolar = false; volt_per_bit = 1.25m }
}

rack "bottom"
{
   address = 1

   // still empty
}

And here is a longer example Rulbus configuration file.

The syntax recognized by the ConfigParser is specified by the following grammar.

Grammar (simplified) for Rulbus configuration file, 05-Feb-2004

program  : rack-declaration-sequence? file-assignment? rack-declaration-sequence?

file-assignment
         : 'file' optassign path optdelim

rack-declaration-sequence
         : rack-declaration
         | rack-declaration-sequence rack-declaration

rack-declaration
         : 'rack' identifier rack-initializer? optdelim

rack-initializer
         : optassign '{' rack-initializer-list? '}'

rack-initializer-list
         : address-initializer? card-declaration-sequence?

card-declaration-sequence
         : card-declaration
         | card-declaration-sequence card-declaration

card-declaration
         : card-type-specifier identifier card-initializer? optdelim

card-initializer
         : optassign '{' property-initializer-list? optdelim '}'

property-initializer-list
         : property-initializer
         | property-initializer-list optdelim property-initializer

card-type-specifier
         : 'rb_generic'
         | 'rb8506_pia'
         | 'rb8506_sifu'
         | 'rb8506_via'
         | 'rb8509_adc12'
         | 'rb8510_dac12'
         | 'rb8513_timebase'
         | 'rb8514_delay'
         | 'rb8515_clock'
         | 'rb8905_adc12'
         | 'rb9005_amplifier'
         | 'rb9603_monochromator'

address-initializer
         : 'address' optassign integer-literal optdelim

property-initializer
         : property optassign literal

property : 'address'                     ; takes integer-literal
         | 'bipolar'                     ; takes boolean literal
         | 'has_ext_trigger'             ; takes boolean-literal
         | 'intr_delay'                  ; takes floating-literal,
                                         ;   integer multiple of 10 ns
         | 'num_channels'                ; takes integer-literal
         | 'volt_per_bit'                ; takes floating-literal

path     : string-literal

identifier
         : string-literal

literal  : boolean-literal
         | integer-literal
         | floating-literal
         | string-literal

boolean-literal
         : 'true'
         | 'false'
         | 'yes'
         | 'no'
         | integer-literal               ; zero: false, non-zero: true

integer-literal
         : octal-literal suffix?
         | decimal-literal suffix?
         | hexadecimal-literal suffix?

floating-literal
         : fraction exponent? suffix?
         | [0-9]+ exponent suffix?

fraction : [0-9]* '.' [0-9]+
         | [0-9]+ '.'

exponent : [eE] [-+]? [0-9]+

string-literal
         : '\'' {printable} '\''
         |  '"' {printable} '"'

octal-literal
         : '0' [0-7]*

decimal-literal
         : [1-9][0-9]*

hex-literal
         : '0' [xX] [0-9a-fA-F]+

suffix   : [fpnumkMGT]                  ; femto..Tera multiplication factor

optassign: [=:]?

optdelim : [,;]?

Lexical behaviour of the Rulbus configuration file parser

There are three comment-variants:

  • single-line comments: '#' and '//'
  • multi-line comments: '/*' ... '*/', no nesting

Semantics of the Rulbus configuration file

Properties take different value-types. This is not specified by the grammar, but only indicated there with a comment.

It is allowed for a property of a card to be specified multiple times with the same value. It is an error though if the property of a card is specified with different values.

The list below gives the properties that each type accepts with their default values.

  • rack defaults:
    address = 0xF meaning: rack is always selected

  • rb_generic:
    { address = 0 } default and at the same time the only allowed value

  • rb8506_sifu:
    { address = 0x94 }

  • rb8509_adc12:
    { address = 0xC0, has_ext_trigger = false, num_channels = 8, bipolar = true, volt_per_bit = 5e-3 }

  • rb8510_dac12:
    { address = 0xD0, bipolar = true, volt_per_bit = 5e-3 }

  • rb8513_timebase:
    { address = 0xB0 }

  • rb8514_delay:
    { address = 0xC4, intr_delay = 0 }

  • rb8515_clock:
    { address = 0xC8 }

  • rb8905_adc12:
    { address = 0xBC, volt_per_bit = 2.442002e-3 }

  • rb9005_amplifier:
    { address = 0xB3 }

  • rb9603_monochromator:
    { address = 0xCE }

Public Member Functions

ConfigParser (ConfigScanner &scanner, ConfigBuilder &builder, ConfigContext &context)
constructor.

void | parse ()
get first token and parse the program.

Protected Member Functions

void | parseProgram ()
parse the complete program.

void | parseFileAssignment ()
parse and ignore the optional file entry.

void | parseRackDeclarationSequence ()
parse the rack sequence.

void | parseRackDeclaration ()
parse a rack entry.

void | parseRackInitializer ()
parse an optional rack initializer.

void | parseRackAddressAssignment ()
parse an optional rack address assignment.

void | parseCardDeclarationSequence ()
parse optional card declarations.

void | parseCardDeclaration ()
parse a card entry.

void | parseCardInitializer (ConfigToken::TokenCode card)
parse an optional card initializer.

void | parseRB8509 (bool scanProperties=true)
parse properties for RB8509 Adc12.

void | parseRB8510 (bool scanProperties=true)
parse properties for RB8510 Dac12.

void | parseRB8514 (bool scanProperties=true)
parse properties for RB8514 delay.

void | parseRB8905 (bool scanProperties=true)
parse properties for RB8905 Adc12.

void | parseGenericCard (ConfigToken::TokenCode card, bool scanProperties=true)
parse cards that only needs name, address and rack.

Int | parseAddress (ConfigToken::TokenCode token=ConfigToken::tcCARD)
parse address property.

bool | parseHasExtTrigger ()
parse has_ext_trigger property.

Int parseNumChannels ()
parse num_channels property.

bool | parseBipolar ()
parse bipolar property.

Real parseVoltPerBit ()
parse volt_per_bit property.

Real parseIntrDelay ()
parse intrinsic delay property.

bool | parseBooleanProperty (ConfigToken::TokenCode token)
parse boolean property.

Int | parseIntegerProperty (ConfigToken::TokenCode token)
parse integer property.

Real | parseRealProperty (ConfigToken::TokenCode token)
parse real property.

Real | parseOptUnit (ConfigToken::TokenCode token)
return factor for optional unit suffix.

void | parseOptDelimiter ()
parse optional delimiter.

void | parseOptAssignOp ()
parse optional assignment operator.

void | checkRackAllowed ()
check if no rack with address 0xF exists so that another rack may exist.

void | checkDuplicateRackName ()
check if rack name is already defined.

void | checkDuplicateCardName ()
check if card name is already defined.

void | checkRackDeclaration ()
check the rack declaration just parsed.

void | checkCardDeclarations ()
check the card declarations parsed thus far.

void | checkDuplicateRackAddr (bool withline=false)
check if rack address is already use.

void | checkOverlapCardAddr (bool withline=false)
check if card addresses overlap; traverses theCardList i.e.

void | addCard (RulbusDevicePtr card)
add a new card toe the list of cards in a rack and to the list of all cards.

void | clearRackCardList ()
empty the list of cards in a rack.

void | updateRackCardList ()
update the rack address of the cards in a rack and offer the cards to theBuilder.

void | getToken ()
get the next token, unless end of file already reached.

bool | test (ConfigToken::TokenCode token, bool require=true)
check for specified token; throws ParseError if require is true and the token is not there or on end of file.

void | expect (ConfigToken::TokenCode token, bool require=true)
check for and consume specified token; throws ParseError if require is true and the token is not there.

Private Types

typedef std::vector< RulbusDevicePtr > | CardList
list for RulbusDevicePtr-s

typedef std::vector< String > | NameList
'set' for rack names or list for device names

typedef std::vector< bool > | AddrList
'set' for rack addresses

typedef std::vector< int > | LineList
'set' or list for declaration linenumbers

Private Attributes

ConfigToken::TokenCode t
the current token code

ConfigScanner * theScanner
the scanner

ConfigBuilder & theBuilder
the builder

ConfigContext & theContext
the context

ConfigToken * theToken
the current token

String theRackName
the current rack's name

Int theRackAddress
the current rack's address

Int theRackLine
the current rack's declaration linenumber

String theCardName
the current card's name

Int theCardAddress
the current card's address

CardList theCardList
temporary list of all cards

NameList theCardNameList
temporary list of all card names

LineList theCardLineList
card declarations linenumber

CardList theRackCardList
temporary list of cards in a rack

AddrList theRackAddrSet
rack addresses in use

NameList theRackNameSet
rack names in use

LineList theRackLineSet
rack declarations linenumber

Static Private Attributes

const int | DEF_CARDS = 32
const int | LIM_RACKS = 16
initial guess for number of cards

CharCptr | already_assigned = " already assigned a different value"
optimaization.

Member Function Documentation

void checkOverlapCardAddr ( bool withline = false ) [protected]

device must already have been created; based on code by Jens Thoms Törring.

The documentation for this class was generated from the following files:
  • ConfigParser.h
  • ConfigParser.cpp
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigParser::ParseError class Reference

ConfigParser::ParseError Class Reference

#include <ConfigParser.h>

List of all members.

Detailed Description

ParseError is used within ConfigParser and it is transformed to a RulbusParseError in parse().

Public Member Functions

ParseError (StringCref msg)
constructor.

The documentation for this class was generated from the following file:
  • ConfigParser.h
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigPrinter class Reference

ConfigPrinter Class Reference

#include <ConfigBuilder.h>

Inherits ConfigBuilder.

List of all members.

Detailed Description

Class ConfigPrinter is a concrete builder that lets the Rulbus devices print themselves to the stream specified at construction time.

Public Member Functions

ConfigPrinter (std::ostream &aStream)
constructor.

void | add (RulbusDevicePtr ptr)
add (print) a Rulbus device.

Private Attributes

std::ostream & | theStream
the stream

The documentation for this class was generated from the following files:
  • ConfigBuilder.h
  • ConfigBuilder.cpp
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigScanner class Reference

ConfigScanner Class Reference

#include <ConfigScanner.h>

List of all members.

Detailed Description

Class ConfigScanner is used by class ConfigParser to obtain the contents of a Rulbus configuration file one token at a time.

Class ConfigScanner analyzes the text from the Rulbus configuration file specified as stream with the constructor and breaks it into tokens.

The scanner ignores whitespace (spaces, tabs and newlines) and it recognizes the following Tokens:

             words :  keywords, e.g. rack, address, bipolar, rb8510_dac12
           numbers : octal, decimal, hexadecimal, floating point
           strings : '...' and "..."
           special : {}=;
  end-of-file : end of file indicator
             error : unrecognized token

Public Member Functions

virtual | ~ConfigScanner ()
destructor.

ConfigScanner (std::istream &stream, String aFilename="")
constructor.

ConfigToken * get ()
return next token; may throw RulbusScanError.

String | filename () const
return the filename.

Int | linenumber () const
return curernt linenumber.

Protected Member Functions

void | skipWhitespace ()
skip whitespace, keep track of linenumber.

bool | seechar (char &chr)
look ahead one character.

Protected Attributes

ConfigWordToken wordToken
the keyword scanner

ConfigNumberToken numberToken
the number scanner

ConfigStringToken stringToken
the string scanner

ConfigSpecialToken specialToken
the special token scanner

ConfigEofToken eofToken
the end-of-file token

ConfigErrorToken errorToken
the unrecognized token scanner

Private Attributes

std::istream * | is
the stream

String theFilename
the filename

Int theLinenumber
the current linenumber

The documentation for this class was generated from the following files:
  • ConfigScanner.h
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigSpecialToken class Reference

ConfigSpecialToken Class Reference

#include <ConfigScanner.h>

Inherits ConfigToken.

List of all members.

Detailed Description

Class ConfigSpecialToken reads and represents tokens like brace and semicolon.

Public Member Functions

void | get (std::istream *is)
scan a special token.

void | print () const
print a special token.

The documentation for this class was generated from the following files:
  • ConfigScanner.h
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigStringToken class Reference

ConfigStringToken Class Reference

#include <ConfigScanner.h>

Inherits ConfigToken.

List of all members.

Detailed Description

Class ConfigStringToken reads and represents strings.

Public Member Functions

void | get (std::istream *is)
scan a string token; may throw logic_error on unterminated string.

void | print () const
print a string token.

The documentation for this class was generated from the following files:
  • ConfigScanner.h
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigToken class Reference

ConfigToken Class Reference

#include <ConfigScanner.h>

Inherited by ConfigEofToken, ConfigErrorToken, ConfigNumberToken, ConfigSpecialToken, ConfigStringToken, and ConfigWordToken.

List of all members.

Detailed Description

Class ConfigToken and its descendants are used by class ConfigScanner to hand one token at a time to an object of class ConfigParser.

Public Types

enum TokenCode {
a, b, c, a, b, c,
a, b, c, tcLAST
}
token codes.

Public Member Functions

virtual void | get (std::istream *is)=0
read the next token (abstract)

virtual void | print () const =0
print the current token (abstract)

bool | isBool () const
predicate to check if token represents a boolean literal.

bool | isAsnop () const
predicate to check if token represents an assignment operator.

bool | isCard () const
predicate to check if token represents a card.

bool | isDelim () const
predicate to check if token represents a delimiter.

bool | isUnit () const
predicate to check if token represents a unit.

bool | isKind (TokenCode t) const
predicate to check if token represents a delimiter.

TokenCode | code () const
return current token code.

bool | toBool () const
return as boolean.

Int | toInt () const
return as integer value.

Real | toReal () const
return as real value.

String | toString () const
return as string.

String | tokenString () const
return string for this token.

String | tokenString (TokenCode t) const
return string for specified token.

Protected Attributes

TokenCode theTokenCode
the token code

Int theIntValue
the integer value

Real theRealValue
the real value

String theString
the string

Static Private Attributes

CharCptr | stringTable []
table containg a string representation of the tokens.

TokenCode kindTable []
table specifying kind (rack, card, number etc.) of token.

The documentation for this class was generated from the following files:
  • ConfigScanner.h
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigWordToken class Reference

ConfigWordToken Class Reference

#include <ConfigScanner.h>

Inherits ConfigToken.

List of all members.

Detailed Description

Class ConfigWordToken reads and represents keywords.

Public Member Functions

void | get (std::istream *is)
scan a keyword token; may throw logic_error on unrecognized keyword.

void | print () const
print a keyword token.

The documentation for this class was generated from the following files:
  • ConfigScanner.h
  • ConfigScanner.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: DbcException class Reference

DbcException Class Reference
[Assertion]

#include <Assertion.h>

Inherits Assertion.

Inherited by AssertException, EnsureException, NeverGetHereException, and RequireException.

List of all members.

Detailed Description

Class DbcException is the base class for design-by-contract exception classes, like RequireException and EnsureException.

See also design-by-contract assertions.

Public Types

enum | Type { REQUIRE, ENSURE, ASSERT, NEVERGETHERE }
type of assertion.

Public Member Functions

Construction
DbcException (Type aType, CharCptr aDescription, CharCptr aExpression, CharCptr aFile, int aLine)
constructor.

DbcException (DbcExceptionCref rhs)
copy constructor.

virtual | ~DbcException ()
destructor.

Operators
DbcExceptionRef | operator= (DbcExceptionCref rhs)
copy assignment.

bool | operator== (DbcExceptionCref rhs)
test equality.

Accessors
virtual CharCptr | what () const
return message describing the exception.

Type | type () const
return the type of assertion: require, ensure etc.

String | description () const
return the assertion type's description.

Private Attributes

Type theType
the type

String theDescription
the type description

String theMessage
the message cache for what()

The documentation for this class was generated from the following files:
  • Assertion.h
  • Assertion.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: EnsureException class Reference

EnsureException Class Reference

#include <Assertion.h>

Inherits DbcException.

List of all members.

Detailed Description

EnsureException is the design-by-contract postcondition exception.

See also design-by-contract assertions.

Public Member Functions

EnsureException (CharCptr aExpression, CharCptr aFile, int aLine)
constructor.

The documentation for this class was generated from the following file:
  • Assertion.h
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: EppRulbusInterface class Reference

EppRulbusInterface Class Reference
[Rulbus Interface]

#include <EppRulbusInterface.h>

Inherits TheRulbusInterface.

List of all members.

Detailed Description

Class EppRulbusInterface implements getReg() and putReg() for the Enhanced Printer Port (EPP) Rulbus Interface. At construction time it checks for a valid PC parallel port port-I/O base address using validBase() and it checks if the EPP Rulbus Interface is present using interfacePresent().

Note:
For proper operation, you must configure the parallel printer port for EPP mode in the BIOS!
For more information on programming the EPP, see Jan Axelson's Parallel Port Central [PPCNTRL] and Paul Rademacher's Programming the Enhanced Parallel Port [PRGEPP]. Yet another source of information is the Linux driver module for the PC's parallel port: parport_pc.c. This file can be found at the Linux Cross Reference [LXR].

Public Member Functions

Construction
EppRulbusInterface (Quad base=DEF_EPP_BASE, bool docheck=true)
(default) constructor - setup EPP Rulbus Interface, check if present.

Accessors
Quad | base () const
the interface's base address.

bool | invariant () const
check class invariant.

Printer
bool | printOn (std::ostream &stream) const
report configuration.

Static Public Attributes

const Quad | DEF_EPP_BASE = 0x0378
default EPP Rulbus Interface base address.

Protected Member Functions

Construction
EppRulbusInterface (EppRulbusInterfaceRef)
prevent copying.

EppRulbusInterfaceRef operator= (EppRulbusInterfaceRef)
prevent copying.

Provider interface
int | putReg (int offset, int byte) const
write a byte to the Rulbus.

int | getReg (int offset) const
read a byte from the Rulbus.

Accessors
bool | interfacePresent (int *pCode) const
check if EPP Rulbus Interface is present.

int | readAddress () const
read current EPP address from the EPP.

int | readData () const
read a databyte from the EPP.

bool | EppTimedOut () const
get EPP timeout status.

Mutators
void | writeAddress (int addr) const
write an address to the EPP.

void | writeData (int byte) const
write a databyte to the EPP.

void | resetInterface () const
reset EPP Rulbus Interface by asserting nReset control bit; allow for reset signal to pass through RC filter.

void | initializeEpp () const
initialize EPP port control lines.

bool | clearEppTimeout () const
clear EPP timeout state, return true if timeout persists.

Private Attributes

Quad theBase
parallel printer port base address

Static Private Attributes

CharCptr | msgtitle = "Initialize EPP Rulbus Interface"
title for error message boxes concerning initialization errors.

SPP register offsets
const int | OFF_SPP_DATA = 0
SPP data register.

const int | OFF_SPP_STAT = 1
SPP status register.

const int | OFF_SPP_CTRL = 2
SPP control register.

const int | OFF_EPP_ADDR = 3
EPP address register.

const int | OFF_EPP_DATA = 4
EPP data register.

SPP status bits
const int | MSK_EPP_Timeout = 0x01
EPP extension to SPP (was Reserved1)!

const int | MSK_SPP_Reserved2 = 0x02
SPP reserved2 mask.

const int | MSK_SPP_nIRQ = 0x04
SPP !IRQ mask.

const int | MSK_SPP_nError = 0x08
SPP !error mask.

const int | MSK_SPP_SelectIn = 0x10
SPP select in mask.

const int | MSK_SPP_PaperOut = 0x20
SPP paper out mask.

const int | MSK_SPP_nAck = 0x40
SPP !acknowledge mask.

const int | MSK_SPP_nBusy = 0x80
SPP !busy mask.

SPP control bits
const int | MSK_SPP_Strobe = 0x01
SPP strobe mask.

const int | MSK_SPP_AutoLF = 0x02
SPP auto linefeed mask.

const int | MSK_SPP_nReset = 0x04
SPP !reset mask.

const int | MSK_SPP_SelectPrinter = 0x08
SPP select printer mask.

const int | MSK_SPP_EnaIRQVAL = 0x10
SPP enable IRQ mask.

const int | MSK_SPP_EnaBiDirect = 0x20
SPP enable bidirectional mask.

const int | MSK_SPP_Unused1 = 0x40
SPP unused1 mask.

const int | MSK_SPP_Unused2 = 0x80
SPP unused2 mask.

Constructor & Destructor Documentation

EppRulbusInterface | ( | Quad | aBase = DEF_EPP_BASE,
 |  | bool | checkIfPresent = true
 | ) |

The (default) constructor does the following:

  • check for valid EPP base address, using class PportAddresses
  • if CanIO is used for port-I/O, the constructor opens the I/O port range used by the EPP, before it accesses the EPP (see openIO()).
  • initialize the PC EPP
  • reset the EPP Rulbus Interface
  • optionally check if EPP Rulbus Interface is present

The constructor throws a RulbusInterfaceError if the base address is invalid, if the address range could not be opened, or if the EPP Interface is not present.

Member Function Documentation

bool clearEppTimeout ( ) const [inline, protected]

clearEppTimeout() clears the EPP timeout state. Some chips reset the timeout by writing a 1, some by writing a 0 in to the EPP Timeout bit (MSK_EPP_Timeout).

Documentation we found for the SMC 665/666 chips (and UMC, WinBond) tells to clear the timeout by writing a one (1) to this bit, whereas the bit is cleared for National Semiconductor chips by reading it.

Also, there are chips that require a double status-register read to reset.

We chose to do the following in the hope that it will do the job irrespective of the chip used for the EPP:

  • read status byte twice (trice actually);
  • write a one (1), then
  • write a zero (0) to the timeout bit.

See also Linux drivers parallel port module, file parport_pc.c [LXR].

int getReg ( int offset ) const [protected, virtual]

Reading a byte from the Rulbus via the EPP Rulbus Interface consists of:

  • writing the Rulbus address to the EPP address register, writeAddress()
  • reading the Rulbus data from the EPP data register, readData()

To be sure the EPP is not in a timeout state, we first clear a possible EPP timeout with clearEppTimeout(). Then after write address and read data, we check if a timeout persists and if so, we throw a RulbusTimeoutError to indicate failure.

 int getReg(int offset)
 {
    clearEppTimeout();

    writeAddress( offset );

    if ( clearEppTimeout() )
       throw RulbusTimeoutError( "EPP Rulbus Interface", "writing address in getReg()" );

    int data = readData();

    if ( clearEppTimeout() )
       throw RulbusTimeoutError( "EPP Rulbus Interface", "reading data in getReg()" );

    return data;
 }

Implements TheRulbusInterface.

void initializeEpp ( ) const [protected]

Function initializeEPP() sets the SPP control line as follows:

  • ~MSK_SPP_Strobe no strobe
  • ~MSK_SPP_AutoLF no autolinefeed
  • ~MSK_SPP_SelectPrinter no select printer
  • ~MSK_SPP_EnaIRQVAL irq disabled
  • ~MSK_SPP_EnaBiDirect unidirectional
  • MSK_SPP_nReset non-resetting

bool interfacePresent ( int * pResult ) const [protected]

interfacePresent() returns true if

  • the PC Parallel port is properly configured in EPP mode, AND
  • the proper PC Parallel port address is used/specified, AND
  • the EPP Rulbus Interface is connected and working.

To check for the presence of the EPP Rulbus Interface, we write two different patterns (0xA5 and 0x5A) to the EPP address register and check if we can read these patterns again and check if no EPP timeouts occurred.

If parameter pResult is not null (0), interfacePresent() sets *pCode to the result of the check as a bitpattern with the following meaning:

    8 4 2 1
    | | | |_ timeout pattern 1
    | | |___ pattern 1 read != pattern 1 written
    | |_____ timeout pattern 2
    |_______ pattern 2 read != pattern 2 written

int putReg | ( | int | offset,
 |  | int | byte
 | ) | const [protected, virtual]

Writing a byte to the Rulbus via the EPP Rulbus Interface consists of:

  • writing the Rulbus address to the EPP address register, writeAddress()
  • writing the Rulbus data to the EPP data register, writeData()

To be sure the EPP is not in a timeout state, we first clear a possible EPP timeout with clearEppTimeout(). Then after each write, we check if a timeout persists and if so, we throw a RulbusTimeoutError to indicate failure.

 int putReg(int offset, int byte)
 {
    clearEppTimeout();       // clear timeout just to be sure

    writeAddress( offset );

    if ( clearEppTimeout() )
       throw RulbusTimeoutError( "EPP Rulbus Interface", "writing address in putReg()" );

    writeData( byte );

    if ( clearEppTimeout() )
       throw RulbusTimeoutError( "EPP Rulbus Interface", "writing data in putReg()" );

    return byte;
 }

Implements TheRulbusInterface.

The documentation for this class was generated from the following files:
  • EppRulbusInterface.h
  • EppRulbusInterface.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: TemplateIoFormat class Reference

IoFormat Class Template Reference

#include <IoFormat.h>

List of all members.

Detailed Description

template<typename T>
class Rulbus::IoFormat< T >

IoFormat together with BoundIoFormat form a class of manipulators for working with streams.

These classes are based on Bjarne Stroustrup's The C++ Programming Language 3rd Ed. Special Edition, p.635, User-Defined Manipulators [2000].

Here is an example of its use.

   Rulbus::IoFormat<double> sci;
   Rulbus::IoFormat<double> alt;

   sci.scientific().width(12).precision(3);
   alt.showplus().width(12).right().fill('#');

   double d = 1234.5678;

   std::cout << d << "  '" << sci(d) << "'" << "  '" << alt(d) << "'" << std::endl;

This produces the following output.

   1234.57  '   1.235e+03'  '+####1234.57'

Public Types

typedef std::ios_base::fmtflags | fmtflags
shorthand type definition.

Public Member Functions

Construction
IoFormat (int precision=6)
(default) constructor.

Operators
BoundIoFormat< T > | operator() (const T &d) const
bind a value to a format.

Accessors
int | fill () const
the fill character.

int | flags () const
the format flags.

int | width () const
the minimum field width.

int | precision () const
the precision.

Mutators
IoFormat< T > & | left ()
adjust left.

IoFormat< T > & | right ()
adjust right.

IoFormat< T > & | internal ()
adjust right, but sign is left.

IoFormat< T > & | boolalpha (bool alpha=true)
show boolean as true, false.

IoFormat< T > & | uppercase (bool upper=true)
use uppercase for X and E and for hexadecimal characters.

IoFormat< T > & | general ()
use default format.

IoFormat< T > & | fixed ()
use fixed format.

IoFormat< T > & | scientific ()
use scientific format.

IoFormat< T > & | oct ()
use octal representation.

IoFormat< T > & | dec ()
use decimal representation.

IoFormat< T > & | hex ()
use hexadecimal representation.

IoFormat< T > & | showplus (bool show=true)
show plus sign.

IoFormat< T > & | showbase (bool show=true)
show representation base (0, for octal, 0x for hexadecimal).

IoFormat< T > & | showpoint (bool show=true)
always show point.

IoFormat< T > & | fill (int c= ' ')
set fill character.

IoFormat< T > & | width (int w)
set minimum field width.

IoFormat< T > & | precision (int p)
set precision.

Protected Member Functions

void | setf (fmtflags f)
set format flag.

void | setf (fmtflags f, fmtflags msk)
set format flag(s) within field.

void | unsetf (fmtflags msk=~0)
clear format flag(s).

Private Attributes

Data
int | thePrecision
precision

int | theWidth
width

int | theFillChar
fill character

fmtflags theFlags
flags

The documentation for this class was generated from the following file:
  • IoFormat.h
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: IsaRulbusInterface class Reference

IsaRulbusInterface Class Reference
[Rulbus Interface]

#include <IsaRulbusInterface.h>

Inherits TheRulbusInterface.

List of all members.

Detailed Description

Class IsaRulbusInterface implements getReg() and putReg() for the ISA Rulbus Interface. At construction time it checks for a valid PC port-I/O base address. The base address may range from 0x200 to 0xFF00 in steps of 0x0100.

Public Member Functions

Construction
IsaRulbusInterface (long aBase=DEF_ISA_BASE)
(default) constructor; checks for valid ISA Rulbus Interface base address.

Accessors
long | base () const
return the converters Rulbus base address.

bool | invariant () const
check class invariant.

Printer
bool | printOn (std::ostream &stream) const
report configuration.

Static Public Attributes

const long | DEF_ISA_BASE = 0x0200
default ISA Rulbus Interface base address.

Protected Member Functions

Construction
IsaRulbusInterface (IsaRulbusInterfaceRef)
prevent copying.

IsaRulbusInterfaceRef operator= (IsaRulbusInterfaceRef)
prevent copying.

Predicates
bool | validBase (long base) const
check for valid base address.

Provider interface
int | getReg (int offset) const
read a byte from the Rulbus.

int | putReg (int offset, int byte) const
write a byte to the Rulbus.

Private Attributes

long | theBase
interface port-i/o base address

Static Private Attributes

const long | baseMin = 0x0200
lowest acceptable base address

const long | baseMax = 0xFF00
highest acceptable base address

const long | baseStp = 0x0100
base address delta

CharCptr | msgtitle = "Initialize ISA Rulbus Interface"
title for error message boxes concerning initialization errors.

Constructor & Destructor Documentation

IsaRulbusInterface ( long aBase = DEF_ISA_BASE )

The (default) constructor does the following:

  • check for valid ISA base address
  • if CanIO is used for port-I/O, the constructor opens the I/O port range used by the ISA Rulbus Interface (see openIO()).

The constructor throws a RulbusInterfaceError if the base address is invalid, or if the address range could not be opened.

Member Function Documentation

int getReg ( int offset ) const [protected, virtual]

Reading a byte from the ISA Rulbus Interface is simple:

 int getReg(int offset)
 {
    return inp( base + offset );
 }

Implements TheRulbusInterface.

int putReg | ( | int | offset,
 |  | int | byte
 | ) | const [protected, virtual]

Writing a byte to the ISA Rulbus Interface is simple:

 int putReg(int offset, int byte)
 {
    outp( base + offset, byte );
    return byte;
 }

Implements TheRulbusInterface.

The documentation for this class was generated from the following files:
  • IsaRulbusInterface.h
  • IsaRulbusInterface.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: TemplateisEqual struct Reference

isEqual Struct Template Reference
[Common]

#include <Common.h>

List of all members.

template<typename aType>
struct Rulbus::isEqual< aType >

Public Member Functions

isEqual (aType a)
constructor.

bool | operator() (aType b)
apply comparison.

Public Attributes

aType | m_a
the value to compare to.

The documentation for this struct was generated from the following file:
  • Common.h
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: NeverGetHereException class Reference

NeverGetHereException Class Reference

#include <Assertion.h>

Inherits DbcException.

List of all members.

Detailed Description

NeverGetHereException is used to mark execution paths that should not occur.

See also design-by-contract assertions.

Public Member Functions

NeverGetHereException (CharCptr aFile, int aLine)
constructor.

The documentation for this class was generated from the following file:
  • Assertion.h
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Pia class Reference

Pia Class Reference
[PIA/VIA]

#include <PiaVia.h>

Inherits PiaVia.

Inherited by RB8506_Pia, and RB8506_Sifu.

List of all members.

Detailed Description

This is the driver for the Parallel Interface module with the Motorola MC6821 Peripheral Interface Adapter (PIA).

A PIA has the following registers:

   Registers       Offset  Rd/Wr   Description
   ------------------------------------------------------------------------------
   PRDA            0       rd/wr   port A peripheral data register (CRA bit 2 = 1)
   DDRA            0       rd/wr   port A data direction register  (CRA bit 2 = 0)
   CRA             1       rd/wr   port A control register
   PRDB            2       rd/wr   port B peripheral data register (CRB bit 2 = 1)
   DDRB            2       rd/wr   port B data direction register  (CRB bit 2 = 0)
   CRB             3       rd/wr   port B control register

Each of the peripheral data lines (PA0..PA7, PB0..PB7) can be programmed to act as an input or as an output. This is accomplished by setting a "1" in the corresponding Data Direction Register bit for those lines which are to be outputs. A "0" in a bit of the Data Direction Register causes the corresponding peripheral data line to act as an input.

Peripheral Data Register:

   76543210 : data bits 0..7, 0 for low, 1 for high output.

Data Direction Register:

   76543210 : data direction bits, 0 for input, 1 for output.

Control Register (CRA):

   76543210

   7        : IRQA1 interrupt flag
              Goes high on active transition of CA1.
              Automatically cleared by MPU read of output register A.
              May also be cleared by hardware reset.

    6       : IRQA2 interrupt flag
              When CA2 is an input, IRQA2 goes high on active transition of CA2.
              Automatically cleared by MPU read of output register A.
              May also be cleared by hardware reset.

     543    : CA2 control
              543 : CA2 input
              5   : 0 : CA2 input
               4  : CA2 active transition for setting IRQA2 flag
                    0 : IRQA2 set by high-to-low transition on CA2
                    1 : IRQA2 set by low-to-high transition on CA2
                3 : CA2 interrupt request enable
                    0 : disable IRQA2 interrupt on active transition of CA2
                    1 : enable  IRQA2 interrupt on active transition of CA2

              543 : CA2 output
              5   : 1 : CA2 output
               43 : CA2 output control
                    0x: strobed CA2 output (operation of CB2 is not identical)
                    1x: programmed CA2 output with level of bit 3
                    00: CA2 Read Strobe with CA1 restore
                    01: CA2 Read Strobe with E   restore
                   (00: CB2 Read Strobe with CB1 restore)
                   (01: CB2 Read Strobe with E   restore)
                    10: CA2 low
                    11: CA2 high

        2   : data direction register access
              0 : Data Direction Register selected
              1 : Peripheral Data Register selected

         1  : CA1 active transition for setting IRQA1
              0 : IRQA1 set by high-to-low transition on CA1
              1 : IRQA1 set by low-to-high transition on CA1

          0 : CA1 interrupt enable
              0 : CA1 interrupt disabled
              1 : CA1 interrupt enabled

Public Member Functions

Construction
Pia (NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK)
constructor; may throw RulbusOpenError

virtual | ~Pia ()
destructor (no-op)

Accessors -- port A
int | getIrqCA1 ()
CA1 input: test for interrupt request pending.

char | getEdgeCA1 ()
CA1 input: get active edge ['p','n'].

int | getIntrCA1 ()
CA1 input: get interrupt enable state.

char | getDirCA2 ()
CA2 i/o: get data direction ['i','o'].

int | getLevelCA2 ()
CA2 i/o: get level [0,1].

Accessors -- port B
int | getIrqCB1 ()
CB1 input: test for interrupt request pending.

char | getEdgeCB1 ()
CB1 input: get active edge ['p','n'].

int | getIntrCB1 ()
CB1 input: get interrupt enable state.

char | getDirCB2 ()
CB2 i/o: get data direction ['i','o'].

int | getLevelCB2 ()
CB2 i/o: get level [0,1].

Mutators -- port A
void | setEdgeCA1 (char edge)
CA1 input: set active edge ['p','n']; may throw RulbusRangeError.

int | setIntrCA1 (int enable)
CA1 input: enable/disable interrupt.

void | setDirCA2 (char dir)
CA2 i/o: set data direction ['i','o']; may throw RulbusRangeError.

void | setLevelCA2 (int lvl)
CA2 i/o: set level [0,!0]; may throw RulbusContextError.

Mutators -- port B
void | setEdgeCB1 (char edge)
CB1 input: set active edge ['p','n']; may throw RulbusRangeError.

int | setIntrCB1 (int enable)
CB1 input: enable/disable interrupt.

void | setDirCB2 (char dir)
CB2 i/o: set data direction ['i','o']; may throw RulbusRangeError.

void | setLevelCB2 (int lvl)
CB2 i/o: set level [0,!0]; may throw RulbusContextError.

Static Public Attributes

Defaults
const int | DEF_ADDR = 0x90
default rulbus address

const int | DEF_RACK = 0
default rack

Protected Member Functions

Accessors -- port A, B
int | getDDRA ()
Port A: get data direction register.

int | getPDRA ()
Port A: get peripheral data register.

int | getDDRB ()
Port B: get data direction register.

int | getPDRB ()
Port B: get peripheral data register.

Mutators -- port A, B
void | setDDRA (int dir)
Port A: set data direction register.

void | setPDRA (int dat)
Port A: set peripheral data register.

void | setDDRB (int dir)
Port B: set data direction register.

void | setPDRB (int dat)
Port B: set peripheral data register.

Private Member Functions

Register selectors -- port A, B
void | select_ddra ()
Port A: provide access to data direction register.

void | select_pdra ()
Port A: provide access to peripheral data register.

void | select_ddrb ()
Port B: provide access to data direction register.

void | select_pdrb ()
Port B: provide access to peripheral data register.

Control ports A/B, C1 (input only)
int | getIrqC1 (int offset)
C[AB]1: test for interrupt request pending.

char | getEdgeC1 (int offset)
C[AB]1: get active edge ['p','n'].

void | setEdgeC1 (int offset, char edge, char port)
C[AB]1: set active edge ['p','n']; may throw RulbusRangeError.

int | getIntrC1 (int offset)
C[AB]1: get interrupt enable state.

int | setIntrC1 (int offset, int enable)
C[AB]1: enable/disable interrupt.

Control port A/B, C2 (input and output)
char | getDirC2 (int offset)
C[AB]2: get data direction.

void | setDirC2 (int offset, char dir, char port)
C[AB]2: set data direction; may throw RulbusRangeError.

int | getLevelC2 (int offset)
C[AB]2: get line level.

void | setLevelC2 (int offset, int lvl, char port)
C[AB]2: set line level; may throw RulbusContextError.

Static Private Attributes

Register offsets
const int | OFF_DDRA = 0
data direction register A

const int | OFF_PDRA = 0
peripheral data register A

const int | OFF_CRA = 1
control register A

const int | OFF_DDRB = 2
data direction register B

const int | OFF_PDRB = 2
peripheral data register B

const int | OFF_CRB = 3
control register B

const int | ADR_WIDTH = OFF_CRB + 1
address with

Bit masks for CA1/CB1
const int | MSK_EIC1 = 0x01
enable interrupt on active transition of CA1/CB1

const int | MSK_ATC1 = 0x02
active transition of CA1/CB1 if ...

const int | MSK_SPDR = 0x04
select peripheral data register A/B

Bit masks for CA2/CB2: NOTE: Read/Write strobe not supported
const int | MSK_DIRC2 = 0x20
CA2/CB2 direction (0:in, 1:out).

CA2/CB2 input:
const int | MSK_ATC2 = 0x10
active transition of CA2/CB2 if ...

const int | MSK_EIC2 = 0x08
enable interrupt on active transition of CA2/CB2

CA2/CB2 output:
const int | MSK_POC2 = 0x10
CA2/CB2 programmed output.

const int | MSK_OLC2 = 0x08
CA2/CB2 output level.

CA1/CB1, CA2/CB2 interrupt request
const int | MSK_IRQ1 = 0x80
interrupt request for CA1/CB1

const int | MSK_IRQ2 = 0x40
interrupt request for CA2/CB2

The documentation for this class was generated from the following files:
  • PiaVia.h
  • PiaVia.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: PiaVia class Reference

PiaVia Class Reference
[PIA/VIA]

#include <PiaVia.h>

Inherits RulbusDevice.

Inherited by Pia, and Via.

List of all members.

Detailed Description

Pia and Via have roughly the same capabilities with respect to their inputs and outputs. Interface class PiaVia expresses this simlarity and it captures the properties common to Pia and Via.

PIA and VIA offer the following interface pins.

    port       pin   direction  description
       A  PA0..PA7      i/o     level inputs and outputs
       A       CA1     input    active edge transition sets interrupt flag
       A       CA2      i/o     complex operation
       B  PB0..PB7      i/o     level inputs and outputs
       B       CB1     input    active edge transition sets interrupt flag
       B       CB2      i/o     complex operation

See Pia and Via for a more detailed description of the IC's capabilities.

Methods

The PiaVia interface contains the following groups of peripheral i/o methods:

  • unified port-related methods, like getPortData():
    port names are "CA", "CB", "PA" and "PB"
  • unified line-related methods, like setLineDir():
    line names are "CA1", "CA2" "PA0".."PA7" and "CB1", "CB2" "PB0".."PB7"
  • specific-port methods, like setDirPA()
  • specific-line methods, like getLevelCA2()

The port-related functions allow you to read or write a complete port at one time, or to get or set its data direction.

However, if you want to act on a single line, the line-related functions are more convenient to use.

The following tables show the port names and the bit-positions for the various peripheral lines as used in the unified port-related functions and the line names and data-direction specifications for the unified line- related functions.

           bit                                    direction   active edge
    port   7  6  5  4  3  2  1  0          line   in    out    neg   pos
    -------------------------------        -------------------------------
    "PA"  PA7 .  .  .  .  .  .  PA0        "PAn"  'i'   'o'
    "CA"                    CA2 CA1        "CA1"               'n'   'p'
                                           "CA2"  'i'   'o'
    "PB"  PB7 .  .  .  .  .  .  PB0        "PBn"  'i'   'o'
    "CB"                    CB2 CB1        "CB1"               'n'   'p'
                                           "CB2"  'i'   'o'

     peripheral lines bit-positions        peripheral lines data-direction
         for port-related functions        for line-related functions
           (i/o and data-direction)        (n: 0..7)

When setting data direction, a 0 in the bitmask makes a line input, whereas a 1 makes it an output. For CA1 and CB1, a 0 makes the input act on the negative edge, a 1 makes it sensitive to the positive, upgoing edge.

When setting output, a 0 in the bitmask makes the line level low, whereas a 1 makes it high.

When reading data-direction from port CA or CB, the CA1 and CA2 (CB1 and CB2) data-direction settings are combined as follows:

 int dir = ( getDirCA2() != 'i' ) << 1 ) | getEdgeCA1() != 'n';

When reading port CA, or CB the CA1 and CA2 (CB1 and CB2) lines are combined as follows:

 int data = ( getLevelCA2() << 1 ) | getIrqCA1();

So to set PB0..PB1 and CB2 to output and to set PB2..PB3 to input, you may write (pia already created):

   pia.setPortDir( "PB", 0x03 );
   pia.setPortDir( "CB", 0x02 );

Note that this ignores the previous data-direction setting: it also sets PB4..PB7 to input.

The following code also sets PB0..PB1 and CB2 to output and PB2..PB3 to input, but leaves the other lines unaffected.

   pia.setLineDir( "PB0", 'o' );
   pia.setLineDir( "PB1", 'o' );
   pia.setLineDir( "CB2", 'o' );
   pia.setLineDir( "PB2", 'i' );
   pia.setLineDir( "PB3", 'i' );

To do the equivalent with the port-related functions you could write:

   int32 dir = pia.getPortDir( "PB" ); pia.setPortDir( "PB", (dir & ~0x0F ) | 0x03 );
         dir = pia.getPortDir( "CB" ); pia.setPortDir( "CB",  dir |  0x02 );

With dir & ~0x0F we first clear the bits for lines we want to define, PB0..PB3 (0x0F is 00001111 binary).

Note that for CB2 we just as well could write pia.setPortDir( "CB", 0x02 ) as before, since it is the only output-capable line of port CB (setting CB1's data-direction is silently ignored).

Bitmasks

To address specific pins in port data, you need to use a bitmask. For example, a bitmask of 0x21 specifies pin 0 and pin 5. The mask can also be made with:

 1 << 5 | 1 << 0

Having read direction or data, you use the bitmask to select the pin(s) you are interested in, for example:

 char dir_pin5 = ( direction_read & (1 << 5) ) ? 'o' : 'i';

See par.cpp for an example program. It contains several bit-manipulation functions.

Examples:

pport.cpp.

Public Member Functions

Construction
PiaVia (NameCref aName, Addr aAddr, Addr aWidth, Rack aRack)
virtual | ~PiaVia ()
destructor (empty)

Accessors -- generic ports
virtual int | getPortDir (CharCptr prt)
get port data direction; may throw RulbusRangeError.

virtual int | getPortData (CharCptr ptr)
get port data; may throw RulbusRangeError.

virtual char | getLineDir (CharCptr lin)
get line direction; may throw RulbusRangeError.

virtual int | getLineLevel (CharCptr lin)
get linelevel; may throw RulbusRangeError.

Accessors -- port A
virtual int | getDirPA ()
Port A: get data direction.

virtual int | getDataPA ()
Port A: get peripheral data.

virtual char | getLineDirPA (int pin)
Port A: get peripheral line direction; may throw RulbusRangeError.

virtual int | getLineLevelPA (int pin)
Port A: get peripheral line; may throw RulbusRangeError.

Accessors -- port B
virtual int | getDirPB ()
Port B: get data direction.

virtual int | getDataPB ()
Port B: get peripheral data.

virtual char | getLineDirPB (int pin)
Port B: get peripheral line direction; may throw RulbusRangeError.

virtual int | getLineLevelPB (int pin)
Port B: get peripheral line; may throw RulbusRangeError.

Accessors -- port CA
virtual int | getIrqCA1 ()=0
CA1 input: interrupt request pending.

virtual char | getEdgeCA1 ()=0
CA1 input: get active edge ['p','n'].

virtual int | getIntrCA1 ()=0
CA1 input: get interrupt enable state.

virtual char | getDirCA2 ()=0
CA2 i/o: get data direction ['i','o'].

virtual int | getLevelCA2 ()=0
CA2 i/o: get level [0,1].

Accessors -- port CB
virtual int | getIrqCB1 ()=0
CB1 input: interrupt request pending.

virtual char | getEdgeCB1 ()=0
CB1 input: get active edge ['p','n'].

virtual int | getIntrCB1 ()=0
CB1 input: get interrupt enable state.

virtual char | getDirCB2 ()=0
CB2 i/o: get data direction ['i','o'].

virtual int | getLevelCB2 ()=0
CB2 i/o: get level [0,1].

Mutators -- generic ports
virtual void | setPortDir (CharCptr prt, int msk)
set port data direction; may throw RulbusRangeError.

virtual void | setPortData (CharCptr prt, int dat)
set port data; may throw RulbusContextError (CA2, CB2), RulbusRangeError.

virtual void | setLineDir (CharCptr lin, char dir)
set line direction; may throw RulbusRangeError.

virtual void | setLineLevel (CharCptr lin, int lvl)
set specified ouput linelevel; may throw RulbusContextError, RulbusRangeError.

Mutators -- port A
virtual void | setDirPA (int msk)
Port A: set data direction; may throw RulbusRangeError.

virtual void | setDataPA (int dat)
Port A: set peripheral data; may throw RulbusRangeError.

virtual void | setLineDirPA (int pin, char dir)
Port A: set peripheral line direction; may throw RulbusRangeError.

virtual void | setLineLevelPA (int pin, int lvl)
Port A: set peripheral line; may throw RulbusContextError, RulbusRangeError.

Mutators -- port B
virtual void | setDirPB (int msk)
Port B: set data direction; may throw RulbusRangeError.

virtual void | setDataPB (int dat)
Port B: set peripheral data; may throw RulbusRangeError.

virtual void | setLineDirPB (int pin, char dir)
Port B: set peripheral line direction; may throw RulbusRangeError.

virtual void | setLineLevelPB (int pin, int lvl)
Port B: set peripheral line; may throw RulbusContextError, RulbusRangeError.

Mutators -- port CA
virtual void | setEdgeCA1 (char edge)=0
CA1 input: set active edge ['p','n'].

virtual int | setIntrCA1 (int enable)=0
CA1 input: enable/disable interrupt.

virtual void | setDirCA2 (char dir)=0
CA2 i/o: set data direction ['i','o']; may throw RulbusRangeError.

virtual void | setLevelCA2 (int lvl)=0
CA2 i/o: set level [0,!0]; may throw RulbusContextError.

Mutators -- port CB
virtual void | setEdgeCB1 (char edge)=0
CB1 input: set active edge ['p','n']; may throw RulbusRangeError.

virtual int | setIntrCB1 (int enable)=0
CB1 input: enable/disable interrupt.

virtual void | setDirCB2 (char dir)=0
CB2 i/o: set data direction ['i','o']; may throw RulbusRangeError.

virtual void | setLevelCB2 (int lvl)=0
CB2 i/o: set level [0,!0]; may throw RulbusContextError.

Protected Member Functions

Checkers
void | checkPin (int pin)
check for valid pin ([0-7]; may throw RulbusRangeError

void | checkDir (char dir)
check for valid dir ([iIoO]; may throw RulbusRangeError

void | checkData (int dat)
check for valid data ([0-0xFF]; may throw RulbusRangeError

void | checkMask (int msk)
check for valid mask ([0-0xFF]; may throw RulbusRangeError

Accessors -- port A, B
virtual int | getDDRA ()=0
Port A: get data direction register.

virtual int | getPDRA ()=0
Port A: get peripheral data register.

virtual int | getDDRB ()=0
Port B: get data direction register.

virtual int | getPDRB ()=0
Port B: get peripheral data register.

Mutators -- port A, B
virtual void | setDDRA (int dir)=0
Port A: set data directionregister.

virtual void | setPDRA (int dat)=0
Port A: set peripheral data register.

virtual void | setDDRB (int dir)=0
Port B: set data direction register.

virtual void | setPDRB (int dat)=0
Port B: set peripheral data register.

The documentation for this class was generated from the following files:
  • PiaVia.h
  • PiaVia.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: PportAddresses class Reference

PportAddresses Class Reference

List of all members.

Detailed Description

Determine if a parallel port base addresses is valid.

Class PportAddresses is a helper class for EppRulbusInterface.

Public Types

typedef QuadCptr | const_iterator
const iterator type

Public Member Functions

bool | isValid (Quad base) const
true if specified parallel port base address is valid.

const_iterator | begin () const
first element of iteration.

const_iterator | end () const
past the last element of iteration.

Static Private Attributes

Quad kPportAddresses []
(default) list of valid base addresses.

const Quad | basePCIMin = 0x0D00
lowest acceptable base address

const Quad | basePCIMax = 0xFFF8
highest acceptable base address

const Quad | basePCIStp = 8
base address delta

Member Data Documentation

Quad kPportAddresses [static, private]

Initial value:

   {
      0x378, 0x278
   }

The documentation for this class was generated from the following file:
  • EppRulbusInterface.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8506_Pia class Reference

RB8506_Pia Class Reference
[RB8506 PIA/VIA]

#include <rb8506_pport.h>

Inherits Pia.

List of all members.

Detailed Description

The implementation of the Dual Parallel Interface (Pia) is completely covered by the PiaVia, Pia classes. For more informations on the available methods, see class Rulbus::PiaVia.
Examples:

pport.cpp.

Public Member Functions

RB8506_Pia (NameCref name, Addr addr=Pia::DEF_ADDR, Rack rack=Pia::DEF_RACK)
constructor; may throw RulbusOpenError

The documentation for this class was generated from the following file:
  • rb8506_pport.h
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8506_Sifu class Reference

RB8506_Sifu Class Reference
[RB8506 SIFU]

#include <rb8506_sifu.h>

Inherits Pia.

List of all members.

Detailed Description

Purpose

Provide digital inputs and outputs.

Description

Module RB8506, SIFU variant, is a digital input-output interface. It has four level-sensitive inputs, four negative-edge-sensitive inputs, four level outputs and four outputs that can be pulsed as a group.

There is also a provision to check if any of both the negative-edge-sensitive inputs and the level-sensitive inputs have changed state since it was last checked.

Inputs and outputs are available in TTL and in CMOS: TTL or CMOS can be selected with a switch on the front, two inputs or two outputs at the time. A LED indicates if TLL (red) or CMOS (green) is selected.

The SIFU module consists of a PIA parallel interface (see Pia) and a Sense Interrupt Flag Unit (SIFU) board.

The table below indicates which lines are pulse or level inputs-ouputs.

    line | kind of input-output
   ------+----------------------
      0  |  ]
      1  |  ] level
      2  |  ]
      3  |  ]
         |
      4  |  ]
      5  |  ] negative pulse
      6  |  ]           note 1
      7  |  ]

Note 1: contrary to what the hardware documentation states, I think that the pulse inputs are sensitive to a high-low transition.

When SIFU is created, its parallel interface (PIA) is configured as follows:

  • the input port is read to clear any history
  • the ouput port is set to zero

Usage

The class provides methods to read all inputs at a time or to read each input line individually. It also allows to check if any line has changed since the last time it was checked. Ouputs may be read or written all at once or each output may be read or written individually. Four pulse outputs can be pulsed at one time.

   RB8506_Sifu sifu( "sifu" );

   if ( sifu.inputLineHasChanged() )
   {
      sifu.setOuputPortData( sifu.getInputPortData() );
   }

Implementation

The following tables show how the SIFU input-output lines are connected to the PIA of the parallel interface.

    output line | PIA port A
   -------------+---------------------------------
       level 0  | PA0
             1  | PA1
             2  | PA2
             3  | PA3
                |
       pulse 4  | PA4  ]
             5  | PA5  ]
             6  | PA6  ] pulsed via CA2
             7  | PA7  ]

The pulse outputs are pulsed via control line CA2 (see enablePulseOutputs()).

     input line | PIA port B
   -------------+---------------------------------
       level 0  | PB4                      note 1
             1  | PB5
             2  | PB6
             3  | PB7
                |
       pulse 4  | PB0  ]
             5  | PB1  ] high-low transition
             6  | PB2  ]    recorded via CB1
             7  | PB3  ]                   note 2

Note 1: lines 0--3 connect to PB4--PB7 and that lines 4--7 connect to PB0--PB3.

Note 2: contrary to what the hardware documentation states, I think that CB1 must act on a high-low transistion.

Changes in one or more of the level inputs or a negative transition on one or more of the pulse inputs are recorded via CB1 (see isChangedInputLine()).

Public Member Functions

Construction
~RB8506_Sifu ()
destructor.

RB8506_Sifu (NameCref name, Addr addr=DEF_ADDR, Rack rack=DEF_RACK)
constructor.

Accessors
int | getInputPortData ()
the input data bit-pattern; also clears input flip-flops.

int | getOutputPortData ()
the bit-pattern of the outputs.

bool | isChangedInputLine ()
true if the level of one or more input lines have changed; clears input-has-changed flag; see also tstInputLineLevel().

int | tstInputLineLevel (int line)
the level of the specified input line; clears input-has-changed flag, retains state of input flip-flops; see also inputLineHasChanged(); may throw RulbusRangeError.

int | getInputLineLevel (int line)
the level of the specified input line; clears input flip-flops; may throw RulbusRangeError.

int | getOutputLineLevel (int line)
the line level of the specified output line; may throw RulbusRangeError.

bool | isEnabledPulseOutputs ()
true if the pulse outputs are enabled.

Mutators
void | setOutputPortData (int data)
set the outputs to the specified bit-pattern; may throw RulbusRangeError.

void | setOutputLineLevel (int line, bool set)
set or clear specified output line; may throw RulbusRangeError.

void | enablePulseOutputs (bool enable=true)
enable or disable the pulse outputs.

Static Public Attributes

Defaults
const Addr | DEF_ADDR = Pia::DEF_ADDR + 4
default address (second PIA)

const int | DEF_DIRPA = 0xFF
port A is output

const int | DEF_DIRPB = 0x00
port B is input

const char | DEF_EDGECB1 = 'p'
positive active edge

const char | DEF_DIRCA2 = 'o'
CA2 output.

const char | DEF_DIRCB2 = 'o'
CB2 output.

const char | DEF_LVLCA2 = 0
CA2 0.

const char | DEF_LVLCB2 = 1
CB2 1.

const bool | DEF_INTRCB1 = true
enable CB1 interrupt flag

const int | DEF_OUTDATA = 0
default output levels

Protected Member Functions

Construction and Assignment
RB8506_Sifu ()
prevent default construction

RB8506_Sifu (RB8506_SifuCref rhs)
prevent copying

RB8506_SifuRef | operator= (RB8506_SifuCref rhs)
prevent copying

Tools
void | clearFlipFlops ()
clear pulse input flip-flops.

Static Protected Member Functions

Class tools
int | swapNibbles (int byte)
swap input data for line 0..3 with line 4..7.

int | swapLines (int line)
swap input linenumber 0..3 with lne 4..7.

The documentation for this class was generated from the following files:
  • rb8506_sifu.h
  • rb8506_sifu.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8506_Via class Reference

RB8506_Via Class Reference
[RB8506 PIA/VIA]

#include <rb8506_pport.h>

Inherits Via.

List of all members.

Detailed Description

The implementation of the Dual Parallel Interface (Via) is completely covered by the PiaVia and Via classes. For more informations on the available methods, see class Rulbus::PiaVia.

Public Member Functions

RB8506_Via (NameCref name, Addr addr=Via::DEF_ADDR, Rack rack=Via::DEF_RACK)
constructor; may throw RulbusOpenError

The documentation for this class was generated from the following file:
  • rb8506_pport.h
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8509_Adc12 class Reference

RB8509_Adc12 Class Reference
[RB8509 12-bit ADC]

#include <rb8509_adc12.h>

Inherits RulbusDevice.

List of all members.

Detailed Description

Purpose

Measure a voltage.

Description

Module RB8509 is a 8-channel 12-bit analog to digital converter (ADC).

The module has eight analog inputs and a trigger input to start a data acquisition. A data acquisition can also be started by a software trigger.

Module RB8509 contains the following parts:

  • a channel selector to select one of the eight inputs [Ch0..Ch7]
  • a gain selector to select one of the four gains [1, 2, 4, 8]
  • a 12-bit data Analog to Digital Converter

At production time, the ADC is configured for unipolar or bipolar operation and its input voltage range is defined as 10 or 20V.

The module cannot be queried about these settings, so they must be specified when the ADC is created through its constructor. When a ADC is created, it is configured with the following defaults:

  • address 0xC0 *)
  • rack 0 *)
  • bipolar operation *)
  • 5 mV volt-per-bit *)
  • multiplexer enabled
  • external trigger disabled
  • Rulbus interrupt disabled
  • gain 1 selected
  • channel 0 selected

.*) via constructor default argument

The following table shows the volt-per-bit values for the various input voltage ranges.

      Voltage range      |  volt-per-bit   bipolar
   ----------------------+--------------------------
      0    .. 10.2375  V |    2.5  mV        0
     -5.12 ..  5.1175  V |    2.5  mV        1
    -10.24 .. 10.235   V |    5    mV        1

Usage

The class provides methods to select the input-channel and gain and to obtain these settings and it provides methods to read the input as (raw) ADC-value or as voltage at the channel's input.

   Rulbus::RB8510_Adc12 adc( "adc" );

   adc.setChannel( 3 );
   adc.autoscale();

   std::cout << adc.name() <<
      ": channel " << adc.channel() <<
      ", gain "    << adc.gain()    << ": " << adc.voltage() << std::endl;

Implementation

Module RB8509 contains an input multiplexer, a programmable amplifier and a 12-bit ADC. The table below shows how these parts can be controlled and how information can be obtained from them.

   Register        Offset    Rd/Wr     Description
   ----------------------------------------------------------------------------
   adclsb          0         read      ADC least significant byte;
                                       resets the end of conversion flip-flop.

   control         0        write      control register
                                       76543210
                                       7        : interrupt enable    (active high)
                                        6       : ext. trigger enable (active high)
                                         54     : gain number selector (1,2,4,8)
                                           3    : multiplexer enable  (active low)
                                            210 : channel selector

   status          1         read      data and status register
                                       76543210
                                       7        : external trigger
                                        6       : interrupt pending
                                         5      : end of conversion (EOC)
                                          4     : ADC busy flag
                                           3210 : high order nibble

   convert         1        write      (start conversion)
                                       76543210 : don't care

Public Types

typedef Int | Value
ADC conversion data type.

Public Member Functions

Construction
RB8509_Adc12 (NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK, bool aBipolarFlag=DEF_BIP, Real aVoltPerBit=DEF_VPB, bool aExtTrigInpFlag=DEF_ETI)
constructor.

~RB8509_Adc12 ()
destructor.

Accessors
int | channel () const
the current channel number [0..7].

int | gain () const
the current gain [1,2,4,8].

Volt voltage ()
issue software trigger and return input-voltage measured; may throw RulbusTimeoutError; or wait for external trigger and return input-voltage measured.

Value value ()
issue software trigger and return conversion value; may throw RulbusTimeoutError; or wait for external trigger and return conversion value.

Value result ()
return last (bipolar) conversion result; requires preceding external trigger or software trigger; when using the latter, it may throw RulbusTimeoutError.

Value rawresult ()
return last raw conversion result; requires preceding external trigger or software trigger; when using latter, it may throw RulbusTimeoutError.

bool | hasExtTriggerInput () const
true if ADC has trigger input available.

bool | extTriggerLevel () const
the current external trigger level; requesting the level for a non-available trigger input throws a RulbusContextError.

bool | isEnabledExtTrigger () const
true if external trigger-input is enabled.

bool | isEnabledMultiplexer () const
true if multiplexer is enabled.

bool | isEnabledInterrupt () const
true if interrupt is enabled.

bool | isBusyAdc () const
true while ADC is converting.

bool | isReady () const
true if result is available; flag is reset by reading result.

bool | isBipolar () const
true if ADC has bipolar configuration.

bool | isPendingInterrupt () const
true if an interrupt is pending; flag is reset by reading result.

Real | voltperbit () const
the ADC's input sensitivity configuration.

Predicates
bool | isValidChannel (int aChannel) const
true if channel is valid.

bool | isValidGain (int aGain) const
true if gain is valid.

Mutators
void | setChannel (int aChannel)
select a new channel [0..7]; may throw RulbusRangeError.

void | setGain (int aGain)
select new amplifier gain [1,2,4,8]; may throw RulbusRangeError.

void | autoscale ()
determine amplifier gain to fit current signal.

void | convert ()
start an analog to digital conversion.

bool | enableMultiplexer (bool enable=true)
enable or disable multiplexer.

bool | enableExtTrigger (bool enable=true)
enable or disable external trigger-input; enabling a non-available trigger input throws a RulbusContextError.

bool | enableInterrupt (bool enable=true)
enable or disable interrupt.

Static Public Attributes

Defaults
const Addr | DEF_ADDR = 0xC0
default address

const int | DEF_GAIN = 1
default gain value

const int | DEF_CHAN = 0
default channel number

const bool | DEF_BIP = true
default bipolar

const Real | DEF_VPB = 5e-3
default bipolar, -10.24..+10.23V

const bool | DEF_ETI = false
default no external trigger input

Limits
const int | LIM_MINCHAN = 0
min. value for channel selection

const int | LIM_MAXCHAN = 7
max. value for channel selection

const int | LIM_MINGAIN = 1
min. value for gain selection

const int | LIM_MAXGAIN = 8
max. value for gain selection

const Real | LIM_MINVPB
min. value for volt per bit

const Real | LIM_MAXVPB
max. value for volt per bit

const int | LIM_TIMOUT = 1000
maximum conversion-ready testloops

const Value | LIM_MINVAL = 0x0000
min. value for unipolar ADC-code

const Value | LIM_MAXVAL = 0x0FFF
max. value for unipolar ADC-code

const Value | LIM_BIPVAL = 0x0800
offset value for bipolar ADC-code

Protected Member Functions

Construction and Assignment
RB8509_Adc12 ()
prevent default construction

RB8509_Adc12 (RB8509_Adc12Cref rhs)
prevent copying

RB8509_Adc12Ref | operator= (RB8509_Adc12Cref rhs)
prevent copying

Checkers
void | checkChannel (int aChannel) const
check if channel is valid; may throw RulbusRangeError.

void | checkGain (int aGain) const
check if channel is valid; may throw RulbusRangeError.

Private Attributes

Data
Byte theControlRegister
control-register contents

bool | theExtTrigInpFlag
ADC has external trigger input.

bool | theBipolarFlag
ADC is bipolar.

Real theVoltPerBit
ADC input sensitivity.

Static Private Attributes

Register offsets
const int | OFF_ADCLSB = 0
data low order byte

const int | OFF_CONTROL = 0
control-register

const int | OFF_STATUS = 1
data high orde nibble and status

const int | OFF_CONVERT = 1
start conversion

const int | ADR_WIDTH = OFF_CONVERT + 1
address with

Signal masks and shifts
const int | MSK_CTLCHAN = 0x07
mask byte for channel selection

const int | MSK_CTLMPLX = 0x08
mask byte for multiplexer enable

const int | MSK_CTLGAIN = 0x30
mask byte for gain selection

const int | MSK_CTLTRIG = 0x40
mask byte for external trigger

const int | MSK_CTLINTR = 0x80
mask byte for interrupt

const int | MSK_STSBSY = 0x10
mask byte for busy status

const int | MSK_STSEOC = 0x20
mask byte for EOC

const int | MSK_STSINTR = 0x40
mask byte for interrupt

const int | MSK_STSTRIG = 0x80
mask byte for external trigger

const int | MSK_VALMSN = 0x0F
mask byte for high order data bits

const int | SHL_CTLCHAN = 0
shift for channel selection

const int | SHL_CTLGAIN = 4
shift for gain selection

The documentation for this class was generated from the following files:
  • rb8509_adc12.h
  • rb8509_adc12.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8510_Dac12 class Reference

RB8510_Dac12 Class Reference
[RB8510 12-bit DAC]

#include <rb8510_dac12.h>

Inherits RulbusDevice.

List of all members.

Detailed Description

Purpose

Generate a unipolar or bipolar voltage.

Description

Module RB8510 is a dual 12-bit Digital to Analog Converter. It contains two 12-bit Digital to Analog Converters (DACs), each connecting to a BNC connector on the front panel. There are no inputs.

At production time, each DAC is configured for unipolar or bipolar operation and its output voltage range is defined as 5, 10 or 20V.

The module cannot be queried about these settings, so they must be specified when the DAC is created through its constructor. When a DAC is created, its output is set to 0 Volt.

The following table shows the volt-per-bit values for the various output voltage ranges.

      Voltage range      |  volt-per-bit   bipolar
   ----------------------+--------------------------
      0    ..  5.11875 V |    1.25 mV        0
      0    .. 10.2375  V |    2.5  mV        0
      0    .. 20.475   V |    5    mV        0
     -5.12 ..  5.1175  V |    2.5  mV        1
    -10.24 .. 10.235   V |    5    mV        1

Usage

The class provides methods to set and get the output voltage and methods to set and get the DAC-register code.

   Rulbus::RB8510_Dac12 dac_ch0( "dac:channel-0" );
   Rulbus::RB8510_Dac12 dac_ch1( "dac:channel-1", def_addr + 2 );
   dac_ch0.setVoltage( 1.23 );
   dac_ch1.setVoltage( 5.12 );

For each channel of the DAC module, a separate object must be created.

See dac.cpp for a complete example.

Implementation

Module RB8510 contains two 12-bit DACs. Each DAC has two byte-wide registers to which to write the 12-bit code to in order to set the DAC- output to a certain voltage.

   Register      | Offset  Rd/Wr   Description
   --------------+-----------------------------------------------------------
   MSB           | 0       write   write high order byte to DAC-msb
   LSB           | 1       write   write low order byte to DAC-lsb

The DAC's configuration determines what output voltage a certain code gives. The following table shows the translation of DAC-codes into output voltage ranges.

   DAC-code      |  volt-per-bit   bipolar     Voltage range
   --------------+---------------------------------------------
   0 .. 0xFFF    |    1.25 mV        0         0    ..  5.11875 V
   0 .. 0xFFF    |    2.5  mV        0         0    .. 10.2375  V
   0 .. 0xFFF    |    5    mV        0         0    .. 20.475   V
   0 .. 0xFFF    |    2.5  mV        1        -5.12 ..  5.1175  V
   0 .. 0xFFF    |    5    mV        1       -10.24 .. 10.235   V

The DAC module may or may not have a sample & hold at its output. In the latter case the output voltage is not set in an atomic operation and the voltage may show unintended spikes when changed.

Examples:

dac.cpp.

Public Types

typedef Int | Value
register value type

Public Member Functions

Construction
RB8510_Dac12 (NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK, bool aBipolarFlag=DEF_BIP, Real aVoltPerBit=DEF_VPB)
constructor; set output voltage to 0V; may throw RulbusOpenError.

~RB8510_Dac12 ()
destructor.

Accessors
Volt | voltage () const
the current DAC output voltage.

Value | value () const
the current DAC-register value.

bool | isBipolar () const
true if DAC is configured for bipolar operation.

float | voltperbit () const
the DAC's volt-per-bit configuration.

Mutators
void | setVoltage (Volt aVoltage)
set DAC output to specified voltage; may throw RulbusRangeError.

void | setValue (Value aValue)
set DAC-register to specified value; may throw RulbusRangeError.

Static Public Attributes

Defaults
const Addr | DEF_ADDR = 0xD0
default address

const bool | DEF_BIP = true
default bipolar

const Real | DEF_VPB = 5e-3
default bipolar, -10.24..+10.23V

Limits
const Value | LIM_MINVAL = 0x0000
min. value for unipolar DAC-code

const Value | LIM_MAXVAL = 0x0FFF
max. value for unipolar DAC-code

const Value | LIM_BIPVAL = 0x0800
offset value for bipolar DAC-code

Protected Member Functions

Construction and Assignment
RB8510_Dac12 ()
prevent default construction

RB8510_Dac12 (RB8510_Dac12Cref rhs)
prevent copying

RB8510_Dac12Ref | operator= (RB8510_Dac12Cref rhs)
prevent copying

Private Attributes

Data
Value theRegister
last code sent to DAC register

bool | theBipolarFlag
DAC is bipolar.

Real theVoltPerBit
DAC output sensitivity.

Static Private Attributes

Register offsets
const int | OFF_MSB = 0
MSB register offset.

const int | OFF_LSB = 1
LSB register offset.

const int | ADR_WIDTH = OFF_LSB + 1
address with

The documentation for this class was generated from the following files:
  • rb8510_dac12.h
  • rb8510_dac12.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8513_timebase class Reference

RB8513_timebase Class Reference
[RB8513 Timebase]

#include <rb8513_timebase.h>

Inherits RulbusDevice.

List of all members.

Detailed Description

Purpose

Generate short pulses with a programmable interval time.

Description

Module RB8513 is a clock signal generator with a programmable interval time. It has a TTL trigger input and a TTL clock output.

The module can generate a clock signal with the following programmable interval times.

    Programmable interval times
   --------------------------------
     50 ns
    100 ns
    200 ns
    500 ns
      1 us -  99   us, step   1 us
    100 us -   9.9 ms, step 100 us
     10 ms - 990   ms, step  10 ms

When a timebase is opened, it is configured as follows:

  • the interval time is set to 1us

Usage

Here is a small example how you may use a timebase module.

   Rulbus::RB8513_timebase timebase( "timebase" );

   timebase.setIntervalTime( 1e-3 );

Implementation

Module RB8515 contains a 20 MHz oscillator, several divider ICs and logic to select the output frequency.

The module has two registers:

  • a register to select the interval time (four fixed, three ranges)
  • a register to specify a multiplication factor of 1--99 in BCD for the three interval time ranges

   Register      | Offset  Rd/Wr   Description
   --------------+--------------------------------------------------------------
   Multiplier    | 0       write   to set the clock rate multiplier (BCD)
                 |                 76543210
                 |                 7654     : tens
                 |                     3210 : units
                 |
   Selector      | 1       write   clock rate selector
                 |                 76543210
                 |                 765      : (not used)
                 |                    4     : write 0 to reset clock gate,
                 |                     3    : (not used)
                 |                      210 : 0-7 (bit 4 must be 1)
                 |                            0: 1..99 us
                 |                            1: 0.1..9.9 ms
                 |                            2: 10..990 ms
                 |                            3: (not used)
                 |                            4: 50 ns
                 |                            5: 100 ns
                 |                            6: 200 ns
                 |                            7: 500 ns

Public Types

typedef Int | Value
register value type

Public Member Functions

Construction
RB8513_timebase (NameCref name, Addr addr=DEF_ADDR, Rack rack=DEF_RACK)
constructor; may throw RulbusOpenError.

~RB8513_timebase ()
destructor.

Accessors
Time | intervalTime () const
the current interval time in s.

Value | clockRateMultiplier () const
the current clock rate multiplier value (0..99).

Value | clockRateSelector () const
the current clock rate selector value (0..6, for 50 ns, 100 ns, 200 ns, 500 ns, 1..99 us, 0.1..9.9 ms, 10..990 ms).

Mutators
void | stop ()
stop generating pulses.

void | setIntervalTime (Time aTime)
set interval time to 50 ns, 100 ns, 200 ns, 500 ns, 1..99 us, 0.1..9.9 ms, 10..990 ms; may throw RulbusRangeError.

void | setClockRateMultiplier (Value aValue)
set the clock rate multiplier to the specified value (0..99); may throw RulbusRangeError.

void | setClockRateSelector (Value aValue)
set the clock rate selector to the specified value (0..6, for 50 ns, 100 ns, 200 ns, 500 ns, 1..99 us, 0.1..9.9 ms, 10..990 ms); may throw RulbusRangeError.

Static Public Attributes

Defaults
const Addr | DEF_ADDR = 0xB0
default address

const int | DEF_MUL = 1
default clock rate multiplier contents

const int | DEF_SEL = 4
default clock rate selector contents

Limits
const int | LIM_MULMIN = 0
lowest valid clock rate multiplier

const int | LIM_MULMAX = 99
highest valid clock rate multiplier

const int | LIM_SELMIN = 0
lowest valid clock rate selector

const int | LIM_SELMAX = 6
highest valid clock rate selector

const int | LIM_SELMAXFIXED = 3
highest fixed time clock rate selector

Protected Member Functions

Construction and Assignment
RB8513_timebase ()
prevent default construction

RB8513_timebase (RB8513_timebaseCref rhs)
prevent copying

RB8513_timebaseRef | operator= (RB8513_timebaseCref rhs)
prevent copying

Private Attributes

Data
Value theMutiplyReg
current clock rate multiplier register contents

Value theSelectorReg
current clock rate selector register contents

Static Private Attributes

Register offsets
const int | OFF_MUL = 0
clock rate multiplier register offset

const int | OFF_SEL = 1
clock rate selector register offset

const int | ADR_WIDTH = OFF_SEL + 1
address width

Selector-register masks
const int | MSK_SELSTP = 0x10
reset clock gate

Constant values
const Time | timeList []
list of fixed interval times and of base interval times [s]

const Value | selectorList []
list of selector register codes

Member Data Documentation

const RB8513_timebase::Value selectorList [static, private]

Initial value:

   {
      0x14, 0x15, 0x16, 0x17, 0x10, 0x11, 0x12
   }

const Time timeList [static, private]

Initial value:

   {
      50e-9, 100e-9, 200e-9, 500e-9, 1e-6, 100e-6, 10e-3,
   }

The documentation for this class was generated from the following files:
  • rb8513_timebase.h
  • rb8513_timebase.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8514_delay class Reference

RB8514_delay Class Reference
[RB8514 Time Delay]

#include <rb8514_delay.h>

Inherits RulbusDevice.

List of all members.

Detailed Description

Purpose

Generate a programmable time delay.

Description

Module RB8515 is a programmable delay time generator.

The module has a clock input, a trigger input, two delay outputs, a gate and a gate-not output, and a Rulbus interrupt output.

The delay is made with a 24-bit down counter that counts a programmable number of clock-pulses, when started by a trigger-pulse on the trigger input. See setClockFrequency(), setIntrinsicDelayTime(), setDelayTime(), setDelayCount(), isBusy().

The trigger input can be made positive or negative edge sensitive. Besides triggering the delay with the trigger-input, it is also possible to trigger the delay with the software command. See setTriggerEdge(), trigger().

Each of the two delay outputs (1 and 2) can be programmed to generate a short pulse (15 ns) at the start of the delay, at the end of it, both or to generate no pulse at all. See for example enableStart1().

The level of the start- and end-pulses of output 1 and 2 can be made positive or negative. The restriction is that both outputs have the same polarity for the same pulse. See for example setStart12Direction().

An additional restriction with negative pulses is, that only the start- or the end-pulse may be enabled on an output.

The gate and gate-not outputs generate a pulse from the start of the delay time upto the end of it. The gate-output is active high, the gate-not output is active low.

The Rulbus interrupt output can be enabled or disabled to generate an interrupt at the end of the delay time. It can be checked if an interrupt is pending, and a pending interrupt can be cleared. See enableInterrupt(), isPendingInterrupt().

Methods setSignalDirection() and enableSignal() and their accessor counterparts let you specify the signal through a parameter. They are added for the Rubus Device Library (RDL).

Usage

Here is a small example how you may use a delay module.

   Rulbus::RB8514_delay delay( "delay" );

   delay.setClockFrequency(  10e6  );
   delay.setDelayTime     ( 132e-3 );

Implementation

Module RB8514 contains a three-byte register to load the delay-count from and it contains a control-status register to select the output pulses and to see if a counting operation is going on. Further it contains the logic to read the trigger signal, to create the output pulses and to interface to the Rulbus.

   Input           Description
   ---------------------------------------------------------------------------
   clock           clock input for 24-bit down counter
   trigger         input to start delay

   Output          Description
   ---------------------------------------------------------------------------
   out1            output with start- and endpulse
   out2            output with start- and endpulse
   gate            this output is high during the delay
   /gate           inverse of gate output
   interrupt       Rulbus interrupt

   Register        Offset  Rd/Wr   Description
   ---------------------------------------------------------------------------
   CountByte2      0       write   delay count most significant byte
   CountByte1      1       write   ...
   CountByte0      2       write   delay count least significant byte

   Control         3       write   76543210
                                   7        : level end 1,2  : 0:neg, 1:pos
                                    6       : level start 1,2: 0:neg, 1:pos
                                     5      : edge trigger   : 0:pos, 1:neg
                                              soft trigger   : 1 -> 0
                                      4     : enable and /clear interrupt
                                       3    : enable end 2
                                        2   : enable start 2
                                         1  : enable end 1
                                          0 : enable start 1

   Status          3       read    76543210
                                   765432   : not used
                                         1  : delay busy
                                          0 : interrupt pending

Public Types

typedef Int32 | Count
the delay-count type

Public Member Functions

Construction
RB8514_delay (NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK)
constructor; may throw RulbusOpenError

~RB8514_delay ()
destructor.

Accessors
Freq | clockFrequency () const
the current clock frequency.

Time | intrinsicDelayTime () const
the current intrinsic delay time (it is subtracted from requested delay time).

Time | delayTime () const
the current delay time.

Count | delayCount () const
the current delay count.

char | signalDirection (CharCptr signal) const
the current signal direction: signal in [t s1 s2 e1 e2], result: [p n].

bool | isEnabledSignal (CharCptr signal) const
true if signal enabled: signal in [i s1 s2 e1 e2].

char | triggerEdge () const
return active trigger edge: positive or negative active [pn].

char | start12Direction () const
return current start12 signal direction [pn].

char | end12Direction () const
return current end12 signal direction [pn].

bool | isEnabledStart1 () const
true if start1 signal is enabled.

bool | isEnabledEnd1 () const
true if end1 signal is enabled.

bool | isEnabledStart2 () const
true if start2 signal is enabled.

bool | isEnabledEnd2 () const
true if end2 signal is enabled.

bool | isBusy () const
true if delaying.

bool | isPendingInterrupt ()
true if an interrupt is pending; also clears interrupt.

bool | isEnabledInterrupt () const
true if interrupt is enabled.

Mutators
void | setClockFrequency (Freq freq)
set clock frequency.

void | setIntrinsicDelayTime (Time time)
set intrinsic delay time (will be subtracted from requested delay time).

void | setDelayTime (Time time)
set new delay time.

void | setDelayCount (Count count)
set new delay count.

void | trigger ()
trigger or start delay.

void | setSignalDirection (CharCptr signal, char dir)
set new signal direction: signal in [t s1 s2 e1 e2], dir in [p n i] for positive, negative and invert.

void | enableSignal (CharCptr signal, bool enable)
enable signal: signal in [i s1 s2 e1 e2], i for interrupt.

void | setTriggerEdge (char edge)
set new active trigger edge: positive or negative [pn].

void | setStart12Direction (char dir)
set start12 signal direction [pni].

void | setEnd12Direction (char dir)
set end12 signal direction [pn].

bool | enableStart1 (bool enable=true)
enable start1 signal.

bool | enableEnd1 (bool enable=true)
enable end1 signal.

bool | enableStart2 (bool enable=true)
enable start2 signal.

bool | enableEnd2 (bool enable=true)
enable end2 signal.

void | clearInterrupt ()
clear (pending) interrupt.

bool | enableInterrupt (bool enable=true)
enable interrupt.

Static Public Attributes

Defaults
const Addr | DEF_ADDR = 0xC4
default address

const Freq | DEF_FRQ = 1.0
clock frequency (1 Hz)

const Time | DEF_IDT = 0.0
intrinsic delay time (0 s)

const Time | DEF_DLY = 1.0
delay time (1 s)

const Count | DEF_CNT = (DEF_DLY - DEF_IDT) * DEF_FRQ
intrinsic delay count

const bool | DEF_EINT = false
enable interrupt

const char | DEF_ETRG = 'p'
edge trigger

const char | DEF_LS12 = 'p'
dir start 1,2

const char | DEF_LE12 = 'p'
dir end 1,2

const bool | DEF_ES1 = true
enable start 1

const bool | DEF_EE1 = true
enable end 1

const bool | DEF_ES2 = true
enable start 2

const bool | DEF_EE2 = true
enable end 2

Limits
const Count | LIM_CNTMIN = 0
minimum count limit

const Count | LIM_CNTMAX = 16777215
maximum count limit

const Freq | LIM_FRQMIN = 1.0
minimum frequency limit

const Freq | LIM_FRQMAX = 100e6
maximum frequency limit

const Time | LIM_IDTMIN = 0.0
minimum intrinsic delay time limit

const Time | LIM_IDTMAX = 100e-9
maximum intrinsic delay time limit

Protected Member Functions

Construction and Assignment
RB8514_delay ()
prevent default construction

RB8514_delay (RB8514_delayCref rhs)
prevent copying

RB8514_delayRef | operator= (RB8514_delayCref rhs)
prevent copying

Validation
bool | isValidSignalName (CharCptr aSignal, CharCptr aExtra) const
true if specified signal name is in [aExtra s1 s2 e1 e2].

bool | isValidSignalDirection (Char aDirection) const
true if specified signal direction is in [p n i].

bool | isValidDelayCount (Count aCount) const
true if specified count is a valid delay register value.

bool | isValidClockFrequency (Freq aFreq) const
true if specified frequency is a valid clock frequency.

bool | isValidIntrinsicTime (Time aTime) const
true if specified time is a valid delay time.

Private Member Functions

int | countByte2 () const
return 3rd byte of delay register.

int | countByte1 () const
return 2nd byte of delay register.

int | countByte0 () const
return 1st byte of delay register.

char | getDirection (int mask) const
return direction for signal specified by mask.

void | setDirection (char dir, int mask, CharCptr description)
set direction for signal specified by mask to dir.

bool | getEnable (int mask) const
true if signal specified by mask is enabled.

void | setEnable (bool enable, int mask)
set enable state of signal specified by mask to enable.

Private Attributes

Data
Byte theControlRegister
control register contents

Count theDelayRegister
delay register contents

Freq theClockFrequency
clock frequency

Time theIntrinsicDelayTime
intrinsic delay time

Static Private Attributes

Register offsets
const int | OFF_BT2 = 0
delay count BT2-register

const int | OFF_BT1 = 1
delay count BT1-register

const int | OFF_BT0 = 2
delay count BT0-register

const int | OFF_CTL = 3
control-register

const int | OFF_STS = 3
status-register

const int | ADR_WIDTH = OFF_STS + 1
address with

Status-register masks
const int | MSK_STSINT = 0x01
interrupt pending

const int | MSK_STSBSY = 0x02
busy status

Control-register masks
const int | MSK_CTLES1 = 0x01
enable start 1

const int | MSK_CTLEE1 = 0x02
enable end 1

const int | MSK_CTLES2 = 0x04
enable start 2

const int | MSK_CTLEE2 = 0x08
enable end 2

const int | MSK_CTLINT = 0x10
enable interrupt

const int | MSK_CTLTRG = 0x20
trigger edge

const int | MSK_CTLLS12 = 0x40
dir start 1,2

const int | MSK_CTLLE12 = 0x80
dir end 1,2

Delay count mask and shifts
const int | MSK_BYTE = 0xFF
a byte

const int | SHR_BT2 = 16
msb

const int | SHR_BT1 = 8
...

const int | SHR_BT0 = 0
lsb

The documentation for this class was generated from the following files:
  • rb8514_delay.h
  • rb8514_delay.cpp
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8515_clock class Reference

RB8515_clock Class Reference
[RB8515 Clock for Time Delay]

#include <rb8515_clock.h>

Inherits RulbusDevice.

List of all members.

Detailed Description

Purpose

Generate a clock signal for the time delay module RB8514.

Description

Module RB8515 is a clock signal generator for time delay module RB8514.

It provides four fixed frequency outputs, three identical clock outputs with programmable frequency and a Rulbus interrupt output with programmable frequency.

   Output        | Description
   --------------+-----------------------------------------------------------
   Ffixed        | fixed frequencies:
                 | 100 kHz, 1 MHz, 10 MHz and 100 MHz
                 |
   Fprogrammable | programmable frequencies:
                 | 0 Hz (disabled), 100 Hz, 1 kHz, 10 kHz, 100 kHz, 1 MHz, 10 MHz and 100 MHz.
                 |
   Finterrupt    | programmable Rulbus interrupt frequency:
                 | 0 Hz (disabled), 1 Hz, 5 Hz, 10 Hz, 50 Hz, 100 Hz, 500 Hz, 1 kHz.

When a clock is opened, it is configured as follows:

  • clock frequency is 1 kHz,
  • interrupt frequency is 0 Hz,
  • rulbus interrupt request is cleared,
  • rulbus interrupt output is disabled.

Usage

Here is a small example how you may use a clock module.

   Rulbus::RB8515_clock clock( "clock" );

   clock.setClockFrequency(  10e6  );

Implementation

Module RB8515 contains a 100 MHz oscillator, a 10 MHz oscillator, several divider ICs and logic to select the output frequency and to select the interrupt frequency. An on-board jumper selects the oscillator used.

The module has a a control-register to select the programmable clock- and interrupt frequencies and it has a status-registers to read the interrupt status.

   Register      | Offset  Rd/Wr   Description
   --------------+-----------------------------------------------------------
   Status        | 0       read    status register
                 |                 76543210
                 |                 7        : interrupt pending
                 |                  6543210 : not used
                 |
   Control       | 0       write   control register
                 |                 76543210
                 |                 7        : interrupt enable and /clear pending interrupt
                 |                  6       : interrupt enable
                 |                   543    : interrupt frequency
                 |                            0: disabled
                 |                            1:   1  Hz
                 |                            2:   5  Hz
                 |                            3:  10  Hz
                 |                            4:  50  Hz
                 |                            5: 100  Hz
                 |                            6: 500  Hz
                 |                            7:   1 kHz
                 |                      210 : clock frequency
                 |                            0: disabled
                 |                            1: 100  Hz
                 |                            2:   1 kHz
                 |                            3:  10 kHz
                 |                            4: 100 kHz
                 |                            5:   1 MHz
                 |                            6:  10 MHz
                 |                            7: 100 MHz

Public Member Functions

Construction
public methods

RB8515_clock (NameCref name, Addr addr=DEF_ADDR, Rack rack=DEF_RACK)
constructor; may throw RulbusOpenError.

~RB8515_clock ()
destructor.

Accessors
Freq | clockFrequency () const
the current clock frequency.

Freq | interruptFrequency () const
the current interrupt frequency.

bool | isPendingInterrupt ()
true if interrupt is pending; a pending interrupt is cleared.

bool | isEnabledInterrupt () const
true if interrupt is enabled.

Mutators
void | setClockFrequency (Freq aFrequency)
set clock frequency; may throw RulbusRangeError.

void | setInterruptFrequency (Freq aFrequency)
set interrupt frequency; may throw RulbusRangeError.

void | clearInterrupt ()
clear pending interrupt.

bool | disableInterrupt ()
disable interrupt.

bool | enableInterrupt (bool enable=true)
enable or disable interrupt.

Protected Member Functions

void | getClkFreqCode (Freq aFrequency, IntPtr pCode) const
map clock frequency to register code; may throw RulbusRangeError.

void | getIntFreqCode (Freq aFrequency, IntPtr pCode) const
map interrupt frequency to register code; may throw RulbusRangeError.

void | getFreqCode (Freq aFrequency, const FreqTable *tablePtr, IntPtr pCode) const
using specified table, map frequency to register code; may throw RulbusRangeError.

Construction and Assignment
RB8515_clock ()
prevent default construction

RB8515_clock (RB8515_clockCref rhs)
prevent copying

RB8515_clockRef | operator= (RB8515_clockCref rhs)
prevent copying

Private Types

Clock frequency codes
enum {
FC_INVALID = -1, FC_0Hz = 0, FC_100Hz, FC_1kHz, FC_10kHz, FC_100kHz,
FC_1MHz, FC_10MHz, FC_100MHz
}
Interrupt frequency codes
enum {
FI_INVALID = -1, FI_0Hz = 0, FI_1Hz, FI_5kHz, FI_10Hz, FI_50Hz,
FI_100Hz, FI_500Hz, FI_1kHz
}

Private Attributes

Data
Byte theCtlByte
control byte

Static Private Attributes

Register offsets
const int | OFF_CR = 0
control-register offset

const int | OFF_SR = 0
status-register offset

const int | ADR_WIDTH = OFF_SR + 1
address with

Masks and shifts
const int | MSK_CLKFRQ = 0x07
bit-mask clock frequency

const int | MSK_INTFRQ = 0x38
interrupt frequency

const int | MSK_INTENA = 0x40
interrupt enable

const int | MSK_INTCLRn = 0x80
interrupt enable & /clear

const int | MSK_INTSTS = 0x80
interrupt status

const int | SHL_CLKFRQ = 0x00
shift left # bits clock freq.

const int | SHL_INTFRQ = 0x03
shift left # bits interrupt freq.

Defaults
const Addr | DEF_ADDR = 0xC8
default address

const Freq | DEF_CLKFRQ = 1e3
default clock freq. (1 kHz)

const Freq | DEF_INTFRQ = 0e0
default interrupt freq. (disable)

Tables for frequency--code mapping
FreqTable clkTable []
table to map clock frequency to register code.

FreqTable intTable []
table to map interrupt frequency to register code.

Member Enumeration Documentation

anonymous enum [private]

Enumeration values:
FC_INVALID | sentinel
FC_0Hz | disabled
FC_100Hz | 100 Hz
FC_1kHz | 1 kHz
FC_10kHz | 10 kHz
FC_100kHz | 100 kHz
FC_1MHz | 1 MHz
FC_10MHz | 10 MHz
FC_100MHz | 100 MHz

anonymous enum [private]

Enumeration values:
FI_INVALID | sentinel
FI_0Hz | disabled
FI_1Hz | 1 Hz
FI_5kHz | 5 Hz
FI_10Hz | 10 Hz
FI_50Hz | 50 Hz
FI_100Hz | 100 Hz
FI_500Hz | 500 Hz
FI_1kHz | 1 kHz

Member Data Documentation

RB8515_clock::FreqTable clkTable [static, private]

Initial value:

   {
        0  ,  FC_0Hz    << SHL_CLKFRQ,
      100e0,  FC_100Hz  << SHL_CLKFRQ,
        1e3,  FC_1kHz   << SHL_CLKFRQ,
       10e3,  FC_10kHz  << SHL_CLKFRQ,
      100e3,  FC_100kHz << SHL_CLKFRQ,
        1e6,  FC_1MHz   << SHL_CLKFRQ,
       10e6,  FC_10MHz  << SHL_CLKFRQ,
      100e6,  FC_100MHz << SHL_CLKFRQ,
        0  ,  FC_INVALID,
   }

RB8515_clock::FreqTable intTable [static, private]

Initial value:

   {
        0  ,  FI_0Hz   << SHL_INTFRQ,
        1e0,  FI_1Hz   << SHL_INTFRQ,
        5e0,  FI_5kHz  << SHL_INTFRQ,
       10e0,  FI_10Hz  << SHL_INTFRQ,
       50e0,  FI_50Hz  << SHL_INTFRQ,
      100e0,  FI_100Hz << SHL_INTFRQ,
      500e0,  FI_500Hz << SHL_INTFRQ,
        1e3,  FI_1kHz  << SHL_INTFRQ,
        0  ,  FI_INVALID,
   }

The documentation for this class was generated from the following files:
  • rb8515_clock.h
  • rb8515_clock.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8515_clock::FreqTable struct Reference

RB8515_clock::FreqTable Struct Reference

List of all members.

Detailed Description

RB8515_clock uses FreqTable to look up the control-register code for a specific clock or interrupt frequency.

Public Attributes

Freq freq
the frequency

Int code
the register code

The documentation for this struct was generated from the following file:
  • rb8515_clock.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8905_Adc12 class Reference

RB8905_Adc12 Class Reference
[RB8905 12-bit ADC]

#include <rb8905_adc12.h>

Inherits RulbusDevice.

List of all members.

Detailed Description

Purpose

Measure a voltage trace.

Description

Module RB8905 is a 1 Mega-sample per second 12-bit analog to digital converter with a 32 kByte on-board data buffer.

The module has a single analog input and a clock input to do a series of data acquisitions. The number of samples to store on-board is programmable. Also, the ADC can be programmed for bipolar or unipolar use.

Module RB8905 contains the following parts:

  • a track and hold
  • a 12-bit ADC
  • an address counter
  • a 32 kByte on-board data buffer

The analog to digital converter IC is an ADC601 manufactured by Burr-Brown. This 12-bit ADC normally converts samples at a rate of 1 Ms/s (900 ns), but it also can convert at a rate of 2 Ms/s (400 ns). In the latter case, only eight bits are determined and this mode of operation is called short-cycle mode (fast mode, 8-bit result).

When the fast conversion mode (8-bit result) is used, the data bytes are put in the on-board buffer at consecutive addresses. With the normal conversion mode (12-bit result), the order is low order byte, high order byte.

The number of samples to store on-board can be specified in one of two ways (normal conversion mode assumed):

  • 1--128 samples: specified by JMP3 on the module's board (see jmp3BufferCapacity() )
  • 256--16384 samples: specified programmatically (see setBufferCapacity() )

The number of samples is a power of two: 256, 512, 1024, etc.

At production time, the input voltage span of the ADC is configured for 10 V or 20 V.

The module cannot be queried about this setting, so the voltage span must be specified through the constructor when an ADC object is created. An ADC is created with the following defaults:

  • address 0xBC *)
  • rack 0 *)
  • 2.442002 mV volt-per-bit *)
  • normal conversion mode
  • bipolar mode
  • 256 samples
  • Rulbus interrupt disabled

.*) via constructor default argument

The following table shows the volt-per-bit values for the various input voltage spans.

    Voltage span  | volt-per-bit   bipolar
   ---------------+--------------------------
       0 .. 10 V  |  2.442002 mV   no
      -5 ..  5 V  |  2.442002 mV   yes
     -10 .. 10 V  |  4.884004 mV   yes

Note that when the ADC's fast conversion mode (8-bit result) is used, the input voltage span is reduced with a factor of 16 (2^4). See minInputVoltage() and maxInputVoltage().

Usage

Among other methods, the class provides methods to set the conversion mode, to set the input voltage polarity, to set the number of samples to acquire and to read the input as ADC-value or as voltage at the ADC's input.

   const int N = 512;
   Rulbus::Volt32 trace[ N ];

   Rulbus::RB8905_Adc12 adc( "adc" );

   adc.setBufferCapacity( N );
   adc.arm();

   while ( !adc.isReady() )
      wait();

   int n = adc.readVoltage( trace, N );

Implementation

The key parts of module RB8905 are the sample and hold, ADC, address counter and memory IC. The table below shows how these parts can be controlled and how information can be obtained from them.

   Register  Offset     Rd/Wr   Description
   ------------------------------------------------------------------------------
   Data	        0       read    ADC data from buffer

   Status       1       read    Status register
                                76543210
                                7        : end of data acquisition / end of read-out
                                           1: ready
                                           0: busy
                                 6543210 : not used

   Control      0       write   Control register
                                76543210
                                7        : ADC polarity
                                           1: unipolar
                                           0: bipolar
                                 6       : Rulbus interrupt enable
                                           1: enable
                                           0: disable
                                  5      : clear address counter
                                           1: clear
                                           0: count
                                   4     : ADC data size
                                           1: 8-bit short-cyle, fast mode
                                           0: 12-bit
                                    3    : read/write memory
                                           1: read
                                           0: write
                                     210 : buffer size [byte]
                                           0 2..256  (size selected with JMP3)
                                           1    512
                                           2   1024
                                           3   2048
                                           4   4096
                                           5   8192
                                           6  16384
                                           7  32768

The Burr-Brown ADC601 analog to digital converter presents the conversion data as follows:

  • 1's complement for unipolar operation
  • offset binary for bipolar operation

         Scale | Offset Binary   1's Complement
   ------------+--------------------------------
   +full scale |  1111...1111     0111...1111
         +zero |  1000...0000     0000...0000
         -zero |      ---         1111...1111
   -full scale |  0000...0000     1000...0000

   Information from Intersil Application Note AN9657.1, may 1997.

Please note that method getValue() returns the unipolar samples as (unsigned) binary magnitude codes and that it returns bipolar samples as offset binary codes.

Public Types

typedef Int | Value
conversion sample value type

Public Member Functions

Construction
RB8905_Adc12 (NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK, Real aVoltPerBit=DEF_VPB)
constructor.

~RB8905_Adc12 ()
destructor.

Data acquisition
void | arm ()
arm ADC for data-acquisition; a sample is taken each clock-pulse.

bool | isReady () const
true if all samples have been measured or if all samples have been read-out.

int | readVoltage (Volt32 *pVoltage, int nelem)
read nelem elements as voltage from the on-board data buffer, return number of elements actually read; note the voltage type Rulbus::Volt32.

int | readValue (Int16 *pValue, int nelem)
read nelem elements as value from the on-board data buffer, return number of elements actually read; note the value type Rulbus::Int16; see also getValue().

Value getValue ()
the next 8-bit/12-bit unipolar/bipolar sample from the on-board buffer; unipolar samples are presented as (unsigned) magnitude codes, bipolar values are presented as offset binary codes.

Value getRawValue ()
the next raw 8-bit or 12-bit sample from the on-board buffer.

Accessors
bool | isFastMode () const
true if fast (short-cycle) mode is selected (8-bit data).

bool | isUnipolarMode () const
true if unipolar mode is selected.

bool | isEnabledInterrupt () const
true if Rulbus interrupt is enabled.

int | bufferCapacity () const
the number of samples to acquire in the on-board buffer.

int | jmp3BufferCapacity () const
the JMP3 setting for the number of samples to store on-board.

Real | voltperbit () const
the ADC's input sensitivity configuration.

Volt | voltageSpan () const
the ADC input voltage span.

Volt | offsetVoltage () const
the ADC offset voltage.

Volt | minInputVoltage () const
the lowest acceptable ADC input voltage; takes mode settings into account.

Volt | maxInputVoltage () const
the highest acceptable ADC input voltage; takes mode settings into account.

Mutators
void | setFastMode ()
set converter to fast or short-cycle mode (8-bit data).

void | setNormalMode ()
set converter to normal mode (12-bit data).

void | setBipolarMode ()
set converter to bipolar mode.

void | setUnipolarMode ()
set converter to unipolar mode.

bool | enableInterrupt (bool enable=true)
enable (disable) Rulbus interrupt, return true if interrupt was enabled.

void | setBufferCapacity (int nelem=CON_JMP3)
set the number of samples to acquire in the buffer; use JMP3 setting when no length (or zero) is specified; value cached here, used in arm().

Static Public Attributes

Defaults
const Addr | DEF_ADDR = 0xBC
default address

const float | DEF_VPB = 10.0 / 4095.0
the default ADC input sensitivity (10.0 V full scale).

const int | DEF_SAMPLES = 256
default number of samples

Constants
const int | CON_JMP3 = 0
JMP3 selector for number of samples to store in on-board buffer.

const int | CON_TRELAIS = 20
ms to wait for polarity reed-relais to statbilize

Protected Member Functions

Construction and assignment
RB8905_Adc12 ()
prevent default construction

RB8905_Adc12 (RB8905_Adc12Cref rhs)
prevent copying

RB8905_Adc12Ref | operator= (RB8905_Adc12Cref rhs)
prevent copying

Read & write mode
void | setReadMode ()
select data read mode and clear address counter.

void | setWriteMode ()
select data write mode and clear address counter.

Tools
void | clearAddress ()
clear on-board buffer address counter.

int | elemSize () const
the number of bytes per sample.

int | bufferSize () const
the number of bytes to acquire in the on-board buffer.

void | setBufferSize (int aSize=CON_JMP3)
set the number of bytes to acquire in the on-board buffer; use Jmp3 setting when no size (or zero) specified.

void | setBufferCode (int aCode)
set buffer size selector to specifieed value.

int | jmp3BufferSize () const
the JMP3 setting for the number of bytes to store on-board.

int | detectJmp3BufferSize ()
detect the JMP3 determined number of bytes setting.

void | checkRead (int nelem)
throw RulbusContextError if requested number of elements is smaller than one or if it exceeds number available.

void | waitRelais ()
enable unipolar/bipolar mode reed-relais to stabilize.

Private Attributes

Data
Byte theControlRegister
control-register contents

Real theVoltPerBit
ADC input sensitivity.

int | theJmp3BufferSize
number of bytes to buffer for JMP3 setting (cached), obtained in constructor with detectJmp3BufferSize()

int | theBufferCapacity
number of samples as requested via setBufferCapacity(); used in arm()

Static Private Attributes

Register offsets
const int | OFF_CTL = 0
control-register

const int | OFF_ADC = 0
ADC data.

const int | OFF_STS = 1
status-register

const int | ADR_WIDTH = OFF_STS + 1
address width

Limits
const Value | LIM_MINVAL8 = 0x000
minimum value

const Value | LIM_MAXVAL8 = 0x0FF
maximum value

const Value | LIM_MINVAL12 = 0x000
minimum value

const Value | LIM_MAXVAL12 = 0xFFF
maximum value

const int | LIM_MINJMP3SIZE = 2
lowest valid JMP3 buffer size

const int | LIM_MAXJMP3SIZE = 256
highest valid JMP3 buffer size

const int | LIM_MINBUFSIZE = 512
lowest valid non-JMP3 buffer size

const int | LIM_MAXBUFSIZE = 32768
highest valid non-JMP3 buffer size

Signal masks and shifts
const int | MSK_CTLBSIZE = 0x07
mask for number of bytes to buffer

const int | MSK_CTLREAD = 0x08
mask for read/write

const int | MSK_CTLFAST = 0x10
mask for fast (short-cycle) mode (8-bit data)

const int | MSK_CTLCLEAR = 0x20
mask for clear address counter

const int | MSK_CTLINTR = 0x40
mask for interrupt enable

const int | MSK_CTLUNIP = 0x80
mask for unipolar mode

const int | MSK_STSREADY = 0x80
mask for status:ready

const int | MSK_ADCALL12 = 0x0FFF
mask for significant bits in ADC code (12-bit)

const int | MSK_ADCALL8 = 0x00FF
mask for significant bits in ADC code (8-bit)

const int | MSK_ADCMSB12 = 0x0800
mask for most significant bit in ADC code (12-bit)

const int | MSK_ADCMSB8 = 0x0080
mask for most significant bit in ADC code (8-bit)

The documentation for this class was generated from the following files:
  • rb8905_adc12.h
  • rb8905_adc12.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB9005_amplifier class Reference

RB9005_amplifier Class Reference
[RB9005 Instrumentation Amplifier]

#include <rb9005_amplifier.h>

Inherits RulbusDevice.

List of all members.

Detailed Description

Purpose

Provide programmable amplifiers and filters to form a data-acquisition system with the high speed 12-bit ADC RB8905.

Description

Module RB9005 is a 4-channel programmable amplifier-filter module.

It contains

  • two differential programmable amplifiers followed by a programmable filter
  • two unbalanced input (single-ended) programmable amplifiers
  • an ouput multiplexer to present one, two, three or all four inputs in sequence
  • a clock multiplexer to present a clock signal that may alternate over two outputs

When an amplifier is created, it is configured as follows:

  • channel 1 selected
  • gain channel 1 and 2 set to 10
  • gain channel 3 and 4 set to 1
  • low pass frequency channel 1 and 2 set to >= 1 MHz (no filter)
  • channel sequence disabled
  • clock sequence disabled

Usage

Here is a small example how you may use an amplifier module.

   Rulbus::RB9005_amplfier amplfier( "amplfier" );

   amplfier.setChannel( 1 );
   amplfier.setGain   ( 1, 1000 );
   amplfier.setLowPassFrequency( 1, 10e3 );

Implementation

The programmable amplfiers, filters and multiplexer are controlled via four registers. The following table gives an overview of the module's registers.

   Registers    Offset  Rd/Wr   Description
   -----------------------------------------------------------------------------

   gain12       0       write   register to control gain of differential amplifiers
                                7654     : gain code of channel 1
                                    3210 : gain code of channel 2

   multiplexer  1       write   register to control clock and multiplexer
                                7        : clock sequence (alternate)
                                 6       : channel sequence (autoscan)
                                  543    : channel(s) for sequence
                                     210 : channel on the output

   gain34       2       write   register for gain factor of the single end amplifier.
                                7654     : not used
                                    32   : gain of channel 4
                                      10 : gain of channel 3

   lowpass1     3       write   register for low pass filter channel 1
                                7654     : not used
                                    3210 : low pass frequency

   lowpass2     4       write   register for low pass filter channel 2
                                7654     : not used
                                    3210 : low pass frequency

The following tables describe the meaning of the bits of the fours registers.

   Register   g a i n 1 2

   Code          Gain                   Code          Gain
   ch 1 ch 2                            ch 1 ch 2
   -----------------------------------------------------------------------------
   0000 0000       10                   1000 1000     1000
   0001 0001       20                   1001 1001     2000
   0010 0010       40                   1010 1010     4000
   0011 0011       80                   1011 1011     8000
   0100 0100      100                   1100 1100    10000
   0101 0101      200                   1101 1101    20000
   0110 0110      400                   1110 1110    40000
   0111 0111      800                   1111 1111    80000

   Register   l o w p a s s 1,2         Register   g a i n 3 4

   Code         Flp [kHz]               Code           Gain
                                        chan  3  4
   --------------------------------     ----------------------------------------
   xxxx 0000  >= 1000                   xxxx 00 00        1
   xxxx 0001      100                   xxxx 01 01       10
   xxxx 0010       10                   xxxx 10 10      100
   xxxx 0100        1                   xxxx 11 11     1000
   xxxx 1000        0.1

   Register   m u l t i p l e x e r

   Code         channel and clock       Code         channel and clock sequence
   -----------------------------------------------------------------------------
   x0xx x000    1                       x100 0xxx    1-> 1-> 1-> 1
   x0xx x001    2                       x100 1xxx    2-> 1-> 2-> 1
   x0xx x010    3                       x101 0xxx    3-> 2-> 1-> 3
   x0xx x011    4                       x101 1xxx    4-> 3-> 2-> 1

   0xxx xxxx    clock out1 = out2       1xxx xxxx    clock out1/out2 alternating

Note: non-sequence selection of channel 4 differs from the original documentation (that specifies pattern x0xx x100).

Method setChannel() sets both the sequence and non-sequence channel bits at the same time and sequencing is enabled or disabled with enableChannelSequence() and enableClockSequence() by setting and clearing the appropriate sequencing bit. Note that the bit-patterns for both channel selections differ!

Public Types

typedef Int | Value
register value type

Public Member Functions

Construction
RB9005_amplifier (NameCref name, Addr addr=DEF_ADDR, Rack rack=DEF_RACK)
constructor.

~RB9005_amplifier ()
destructor.

Accessors
int | channel () const
the current channel (1..4).

int | gain (int aChannel) const
the channel's current gain.

Freq | lowPassFrequency (int aChannel) const
the channel's current low pass frequency (channel 1 & 2 only).

bool | isChannelSequenceMode () const
true if a channel sequence is active.

bool | isClockSequenceMode () const
true if a clock sequence is active.

Mutators
void | setChannel (int aChannel)
select specified channel, or channel sequence (1..4).

void | setGain (int aChannel, int aGain)
set gain for specified channel.

void | setLowPassFrequency (int aChannel, Freq aFrequency)
set low pass frequency (channel 1 & 2 only).

void | enableChannelSequenceMode (bool enable=true)
enable or disable channel sequencing.

void | enableClockSequenceMode (bool enable=true)
enable or disable clock sequencing.

Static Public Attributes

Defaults
const Addr | DEF_ADDR = 0xB3
default address

Limits
const Value | LIM_MINCHN = 1
lowest channel number

const Value | LIM_MAXCHN = 4
highest channel number

Protected Member Functions

Construction and Assignment
RB9005_amplifier ()
prevent default construction

RB9005_amplifier (RB9005_amplifierCref rhs)
prevent copying

RB9005_amplifierRef | operator= (RB9005_amplifierCref rhs)
prevent copying

Tools
void | checkChannel (int aChannel) const
check for valid channel number; may throw RulbusRangeError.

int | gain12 (int aChannel) const
the current gain for channel 1 or 2.

int | gain34 (int aChannel) const
the current gain for channel 3 or 4.

Freq | lpf12 (int aChannel) const
the current low pass frequency for channel 1 or 2.

Freq | lpf34 (int aChannel) const
cannot set/obtain low pass frequency for channels 3 & 4: throws RulbusRangeError.

void | setGain12 (int aChannel, int aGain)
set gain for channel 1 or 2.

void | setGain34 (int aChannel, int aGain)
set gain for channel 3 or 4.

void | setLpf12 (int aChannel, Freq aFrequency)
set low pass frequency for channel 1 or 2; may throw RulbusRangeError.

void | setLpf34 (int aChannel, Freq aFrequency)
cannot set low pass frequency for channels 3 & 4: throws RulbusRangeError.

Private Attributes

Data
Byte theGain12Register
Channel 1,2 amplifier gain setting.

Byte theGain34Register
Channel 1,2 amplifier gain setting.

Byte theFreq1Register
Channel 1 filter setting.

Byte theFreq2Register
Channel 2 filter setting.

Byte theMuxRegister
Channel and clock multiplexer setting.

Static Private Attributes

Register offsets
const int | OFF_GAIN12 = 0
Channel 1,2 amplifier gain register offset.

const int | OFF_MUX = 1
Channel and clock multiplexer register offset.

const int | OFF_GAIN34 = 2
Channel 3,4 amplifier gain register offset.

const int | OFF_FREQ1 = 3
Channel 1 filter register offset.

const int | OFF_FREQ2 = 4
Channel 2 filter register offset.

const int | ADR_WIDTH = OFF_FREQ2 + 1
address width

Channel 1,2 gain register
const int | MSK_GAIN1 = 0x0F
1st channel gain selection mask

const int | MSK_GAIN2 = 0xF0
2nd channel gain selection mask

const int | SHL_GAIN1 = 0
1st channel gain shift

const int | SHL_GAIN2 = 4
2nd channel gain shift

Channel 3,4 gain register
const int | MSK_GAIN3 = 0x03
3rd channel gain selection mask

const int | MSK_GAIN4 = 0x0C
4th channel gain selection mask

const int | SHL_GAIN3 = 0
3rd channel gain shift

const int | SHL_GAIN4 = 2
4th channel gain shift

Channel 1,2 filter registers
const int | MSK_LPF12 = 0x0F
1st, 2nd channel low pass filter selection mask

const int | SHL_LPF12 = 0
1st, 2nd channel low pass filter shift

Multiplexer register
const int | MSK_CHN1 = 0x07
1st channel selection mask

const int | MSK_CHN2 = 0x38
2nd channel selection mask

const int | MSK_CHNSEQ = 0x40
channel sequence selection mask

const int | MSK_CLKSEQ = 0x80
clock sequence selection mask

const int | SHL_CHN1 = 0
1st channel shift

const int | SHL_CHN2 = 3
2nd channel shift

Gain & filter tables
const RegInfo | GainInfoTable []
gain masks and shifts for channel 1..4.

const int | gain12Table []
valid gains for channel 1 & 2.

const int | gain34Table []
valid gains for channel 3 & 4.

const Freq | freq12Table []
valid low pass frequencies for channel 1 & 2.

Member Data Documentation

const Freq freq12Table [static, private]

Initial value:

   {
      1e6, 100e3, 10e3, 1e3, 0.1e3,
   }

const int gain12Table [static, private]

Initial value:

   {
      10, 20, 40, 80,
      100, 200, 400, 800,
      1000, 2000, 4000, 8000,
      10000, 20000, 40000, 80000,
   }

const int gain34Table [static, private]

Initial value:

   {
      1, 10, 100, 1000,
   }

const RB9005_amplifier::RegInfo GainInfoTable [static, private]

Initial value:

   {
      {       -1,         -1, },
      { MSK_GAIN1, SHL_GAIN1, },
      { MSK_GAIN2, SHL_GAIN2, },
      { MSK_GAIN3, SHL_GAIN3, },
      { MSK_GAIN4, SHL_GAIN4, },
   }

The documentation for this class was generated from the following files:
  • rb9005_amplifier.h
  • rb9005_amplifier.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB9005_amplifier::RegInfo struct Reference

RB9005_amplifier::RegInfo Struct Reference

List of all members.

Public Attributes

int | mask
int | shift
The documentation for this struct was generated from the following file:
  • rb9005_amplifier.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB9603_monochromator class Reference

RB9603_monochromator Class Reference
[RB9603 Monochromator Controller]

#include <rb9603_monochromator.h>

Inherits RulbusDevice.

List of all members.

Detailed Description

Purpose

Control a Bausch & Lomb monochromator remotely.

Description

The RB9603 Rulbus module enables remote control of a Bausch & Lomb monochromator by driving its nonius with a stepping motor.

The target wavelength can be set manually with Up and Down keys on the Rulbus module and programmatically via the Rulbus computer interface.

The module has a one-line display that shows the target wavelength along with indications if the monochromator is still moving up or down and if the wavelength was set manually or via program control.

Besides setting the wavelength, several properties may be requested from the controller via the computer interface: the target wavelength, the current wavelength, the minimum and maximum wavelengths and the current wavelength as seen by the potentiometer on the stepping motor--potentiometer assembly (see omplementation).

When a monochromator is created, no configuration steps are made with respect to the monochromator Rulbus module.

Usage

Here is a small example how you may use an amplifier module.

   Rulbus::RB603_monochromator lamp( "lamp" );

   lamp.setWavelength( 333.5e-9 );      // yes its in [m]

Implementation

The controller module itself sits in a Rulbus rack. A stepping motor--potentiometer assembly is located on the Bausch & Lomb monochromator to drive it. Via a cable the assembly is connected to the MOTOR connector on the controller.

The potentiometer in the assembly records the absolute position of the monochromator. It is used to calibrate the monochromator wavelength at 500 nm initially and to check the position when a new wavelength has been reached.

The minimum wavelength that can be used can be set at production time with jumper CN4 to be 0 nm or 100 nm. Minimum and maximum wavelength may be obtained with methods minWavelength() and maxWavelength().

Remote operation

The messages exchanged between computer and monochromator controller consist of two-letter commands and an optional argument or response of six uppercase hexadecimal characters. The argument and response values are four times the wavelength in nm.

Thus messages look like:

   SW<sp>0007D0<eot>    # set wavelength to code

   GW<eot>              # request current wavelength code
   0007D0<eot>          # read current wavelength code

Here <sp> is a space character and <eot> is the end-of-text character (see below).

The following table lists the commands that can be sent to the monochromator controller via the computer interface.

   Cmd   Arg    Resp     Remark
   -----------------------------------------------------------------------------
    GW          WLact    get current wavelength
    GS          WLset    get wavelength setvalue
    GA          WLadc    get measured wavelength (ADC)
    GM          WLmean   get 4-sample mean measured wavelength (ADC)
    GN          WLmin    get minimum wavelength
    GX          WLmax    get maximum wavelength
    SW   WLset           set wavelength setvalue
    CW                   calibrate, move to 500 nm

The Rulbus processor--monochromator controller is a master--slave combination. The master controls the communication. It writes to the controller's command register and reads from the status register. These registers are both at the same Rulbus address, normally 0xCE.

Command communication

The commands sent are two-letter strings optionally followed by a space and an argument. The command-argument string is terminated by the end-of-text character COMEOT (see the table below). If a result is returned, the master must collect its characters. Arguments and results consist of six uppercase hexadecimal characters. Like command-argument strings, results are terminated with the COMEOT character.

   write a command-argument string   for each character in string do:
                                        write character
                                     write COMEOT

                   read a response   read character
                                     while character <> COMEOT:
                                        string = string + character
                                        read character

Character communication

Exchanging characters with the monochromator controller is done as follows.

                 write a character   write COMRDY

                                     read tempchar
                                     until tempchar = COMRDY

                                     write character

                                     read tempchar
                                     until tempchar = character

                                     write COMRDY

                  read a character   write COMRDY

                                     read tempchar
                                     until tempchar = COMRDY

                                     write COMGET

                                     read character
                                     until character <> COMRDY

                                     read character     # note 1.

                                     write COMRDY

Note 1. In a real implementation, the character must be read again because, although the character previously read differs from COMRDY, it is not necessarily stabilized to the character sent by the controller (the loop terminates when datalines begin to change).

The table below lists the codes used for communication with the monochromator controller.

   Code    Value  Remark
   COMRDY    0    character accepted / ready to accept a character.
   COMGET    1    request from master for a character of a response.
   COMEOT    2    end of command-argument or response string.
   other     -    command, argument, or response character.

And here are the module's registers.

   Registers    Offset  Read/Write    Description
   -----------------------------------------------------------------------------
   command        0       write       write command string
   status         0       read        read response

Public Types

typedef Int | Value
step count type; holds 3-byte number

Public Member Functions

Construction
RB9603_monochromator (NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK)
constructor.

~RB9603_monochromator ()
destructor.

Predicate and ...
bool | isReady () const
true if monochromator is at target wavelength; may throw RulbusTimeoutError.

void | wait () const
wait until monochromator is at wavelength set; may throw RulbusTimeoutError.

Accessors
Length | adcWavelength () const
the current wavelength according to the measured voltage; may throw RulbusTimeoutError.

Length | adcMeanWavelength () const
the current wavelength according to the mean-measured voltage; may throw RulbusTimeoutError.

Length | currentWavelength () const
the current wavelength; may throw RulbusTimeoutError.

Length | targetWavelength () const
the target wavelength; may throw RulbusTimeoutError.

Length | minWavelength () const
the lowest valid wavelength; may throw RulbusTimeoutError.

Length | maxWavelength () const
the highest valid wavelength; may throw RulbusTimeoutError.

Mutators
void | calibrate (bool and_wait=true) const
move monochromator to 500 nm for calibration; may throw RulbusTimeoutError.

void | setWavelength (Length aWavelength, bool and_wait=true) const
set target wavelength; may throw RulbusRangeError, RulbusTimeoutError.

Static Public Attributes

Defaults
const Addr | DEF_ADDR = 0xCE
default address

Protected Types

enum | ComCodes { COM_RDY = 0, COM_GET = 1, COM_EOT = 2, COM_LEN = 15, COM_CNT = 500, COM_SLPMS = 1 }
communication codes. More...

Protected Member Functions

Construction and Assignment
RB9603_monochromator ()
prevent default construction

RB9603_monochromator (RB9603_monochromatorCref rhs)
prevent copying

RB9603_monochromatorRef | operator= (RB9603_monochromatorCref rhs)
prevent copying

Checker
void | checkWavelength (Length aWavelength) const
check for valid wavelength; may throw RulbusRangeError.

Communication
Value | read (CharCptr aName, CharCptr aCmd) const
issue command, read and return response; may throw RulbusTimeoutError.

void | write (CharCptr aName, CharCptr aCmd, Value aPos=-1) const
write a command with optional value; may throw RulbusTimeoutError.

String | getString () const
read a string; may throw RulbusTimeoutError.

void | putString (StringCref aString) const
write a string; may throw RulbusTimeoutError.

char | getCharacter () const
read a character; may throw RulbusTimeoutError.

void | putCharacter (char ch) const
write a character; may throw RulbusTimeoutError.

Private Attributes

Data
Length | theMinWL
cached minimum valid wavelength

Length | theMaxWL
cached maximum valid wavelength

Static Private Attributes

Register offsets
const int | OFF_CMD = 0
command register offset

const int | OFF_STS = 0
status register offset

const int | ADR_WIDTH = OFF_STS + 1
address width

Conversion
const Length | CON_MPS = 0.25e-9
meter-per-step conversion value (4 nm per step).

Member Enumeration Documentation

enum ComCodes [protected]

Enumeration values:
COM_RDY | ready code
COM_GET | get character code
COM_EOT | end-of-transmission code
COM_LEN | maximum string length
COM_CNT | number of retries for character communication (500 ms)
COM_SLPMS | ms sleep between retries

The documentation for this class was generated from the following files:
  • rb9603_monochromator.h
  • rb9603_monochromator.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RequireException class Reference

RequireException Class Reference

#include <Assertion.h>

Inherits DbcException.

List of all members.

Detailed Description

RequireException is the design-by-contract precondition exception.

See also design-by-contract assertions.

Public Member Functions

RequireException (CharCptr aExpression, CharCptr aFile, int aLine)
constructor.

The documentation for this class was generated from the following file:
  • Assertion.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusAddressError class Reference

RulbusAddressError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusAddressError creates an error with the following message:
Rulbus: address violation, device 'name', address [d:0xHH]

Public Member Functions

RulbusAddressError (StringCref name, int rack, int addr)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusCloseError class Reference

RulbusCloseError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusCloseError creates an error with the following message:
Rulbus: cannot close rulbus device with handle 'd'

Public Member Functions

RulbusCloseError (int handle)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusConfigError class Reference

RulbusConfigError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusConfigError is thrown by class TheRulbusDeviceList if it finds an error when it checks the configuration. It may warn for a device name that appears more than once and it may warn for overlapping Rulbus addresses.

Public Member Functions

RulbusConfigError (StringCref msg)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusContextError class Reference

RulbusContextError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusContextError creates an error with the following message:
Rulbus: device 'name', context error: msg

Public Member Functions

RulbusContextError (StringCref name, StringCref msg)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusDataError class Reference

RulbusDataError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusDataError creates an error with the following message:
Rulbus: data violation, device 'name', address [d:0xHH], data [0xHH]

Public Member Functions

RulbusDataError (StringCref name, int rack, int addr, int data)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusDevice class Reference

RulbusDevice Class Reference
[Rulbus Device]

#include <RulbusDevice.h>

Inherited by PiaVia, RB8509_Adc12, RB8510_Dac12, RB8513_timebase, RB8514_delay, RB8515_clock, RB8905_Adc12, RB9005_amplifier, and RB9603_monochromator.

List of all members.

Detailed Description

Class RulbusDevice is the base class for all Rulbus devices. Its functions are to:
  • contain Rulbus device information -- the class contains information that each Rulbus device needs: a name and the module's Rulbus address (rack:addr)
  • provide Rulbus access -- the class provides methods getByte() and putByte() to access the Rulbus

A Note on Access Protection

getByte() and putByte() are made public so that they can be used from a dummy Rulbus device ( see RulbusDevice_getByte() ). Normally these functions would be only used from derived classes and therefore would be made protected.

Thread Safety

For getByte() and putByte(), see TheRulbusInterface, section Thread Safety.

Public Member Functions

Construction
RulbusDevice (Name aName, Addr aAddr, Addr aWidth, Rack aRack)
constructor.

virtual | ~RulbusDevice ()
destructor.

Accessors
Name | name () const
return device's name.

Rack | rack () const
return device's rack.

Addr | addr () const
return device's address.

Addr | width () const
return device's address width.

Predicates
bool | eqRack (RulbusDeviceCref rhs) const
true if racks are active at the same time.

bool | eqAddr (RulbusDeviceCref rhs) const
true if cards have overlapping address ranges.

Modifiers
void | setRack (Rack aRack)
set device's rack.

void | setAddr (Addr aAddr)
set device's address.

Printer
virtual int | printOn (std::ostream &stream) const
report this device's name and Rulbus addres.

Rulbus interface access
int | getByte (int offset) const
read a byte from the Rulbus via theRulbus().

int | putByte (int offset, int byte) const
write a byte to the Rulbus via theRulbus().

Static Public Attributes

const int | ANY_RACK = 0xF
always selected

const int | DEF_RACK = ANY_RACK
default rack address

Protected Member Functions

Construction and assignment
RulbusDevice ()
prevent default construction

RulbusDevice (RulbusDeviceCref)
prevent copying

RulbusDeviceRef operator= (RulbusDeviceCref)
prevent copying

Checkers
void | checkValidAddress (int offset=0) const
check for valid Rulbus address and data.

void | checkBusViolation (int offset, int byte) const
check for valid Rulbus address and data.

Static Protected Member Functions

Delegator
TheRulbusInterfaceRef theRulbus ()
return the Rulbus Interface implementation, using TheRulbusInterface::instance().

Private Attributes

Name theName
device name

Rack theRack
device Rulbus rack number [0..15]

Addr theAddr
device Rulbus address [1..$FE]

Addr theWidth
device Rulbus address width

Member Function Documentation

void checkBusViolation | ( | int | offset,
 |  | int | byte
 | ) | const [protected]

checkBusViolation() checks if parameter offset combined with the device's rack and base address specifies a valid Rulbus address, and it checks if parameter byte specifies a valid Rulbus data value:

  • rack:address -- [0..15:0..0xFF]
  • data -- [0..0xFF]

method checkBusViolation() is part of RulbusDevice -- and not of RulbusInterface, so that it can use the device's name in the error message.

void checkValidAddress ( int offset = 0 ) const [protected]

checkBusViolation() checks if parameter offset combined with the device's rack and base address specifies a valid Rulbus address, and it checks if parameter byte specifies a valid Rulbus data value:

  • rack:address -- [0..15:0..0xFF]
  • data -- [0..0xFF]

method checkBusViolation() is part of RulbusDevice -- and not of RulbusInterface, so that it can use the device's name in the error message.

int getByte ( int offset ) const

getByte() delegates this request via theRulbus() to the actual RulbusInterface object.

If the DFLAG_BUSVIOLATION flag is set in DEBUG, putByte() first checks for a bus address violation via checkBusViolation(). If a busviolation occurs, putBuyte() throws a RulbusAddressError.

int putByte | ( | int | offset,
 |  | int | byte
 | ) | const

putByte() delegates this request via theRulbus() to the actual RulbusInterface object.

If the DFLAG_BUSVIOLATION flag is set in DEBUG, putByte() first checks for bus address and data violations via checkBusViolation(). If a busviolation occurs, putBuyte() throws a RulbusAddressError, or a RulbusDataError.

The documentation for this class was generated from the following files:
  • RulbusDevice.h
  • RulbusDevice.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusDeviceFactory class Reference

RulbusDeviceFactory Class Reference

#include <RulbusDeviceFactory.h>

List of all members.

Detailed Description

Class RulbusDeviceFactory creates the Rulbus devices as specified in a Rulbus configuration file and adds them to TheRulbusDeviceList.

RulbusDeviceFactory uses class ConfigParser to process and check a Rulbus configuration file.

The name of the Rulbus configuration file to process is determined as follows and in the order given:

  1. contents of the rulbus_config_file argument of createDevices()
  2. contents of the RULBUS_CONFIG_FILE environment variable
  3. the file rulbus.conf in the current directory
  4. the file C:\etc\rulbus.conf

If the argument is not specified or specified as the empty string, the contents of the environment variable RULBUS_CONFIG_FILE is used as the name of the configuration file to read.

If the name is an empty string or the RULBUS_CONFIG_FILE environment variable does not exist, createDevices() tries to open file rulbus.conf in the current directory and if that fails it tries file C:\etc\rulbus.conf.

If createDevices() fails to open a specified file, or it fails to open one of the default files if no file has been specified, it throws RulbusConfigError.

Static Public Member Functions

void | createDevices (String rulbus_config_file="")
create the Rulbus devices from the configuration file specified by the rulbus_config_file argument, or else by the RULBUS_CONFIG_FILE environment variable.

void | destroyDevices ()
remove all Rulbus devices from the list and delete them, clear the list.

Protected Member Functions

RulbusDeviceFactory ()
prevent instantiation

RulbusDeviceFactory (RulbusDeviceFactoryCref)
prevent copying

The documentation for this class was generated from the following files:
  • RulbusDeviceFactory.h
  • RulbusDeviceFactory.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusDeviceProxy class Reference

RulbusDeviceProxy Class Reference

#include <RulbusDeviceProxy.h>

List of all members.

Detailed Description

Class RulbusDeviceProxy is returned by class TheRulbusDeviceList as a resource protecting proxy: it is used to protect the Rulbus device from simultaneous access from different threads of execution.

The proxy returned can be used as follows.

 Rulbus::to_rb8510( Rulbus::TheRulbusDeviceList::get( handle ) ).setVoltage( 1.25 );

Class RulbusDeviceProxy uses the initialization-is-acquisition idiom. When the proxy goes out of scope at the end of the expression, the resource is released.

Class RulbusDeviceProxy also uses move semantics on the copy(-assignment) constructors to transfer the ownership of the Rulbus device from the right-hand side to the left-hand side.

For more information on move-constructors, see [MVCTOR].

Public Member Functions

RulbusDeviceProxy (RulbusDevicePtr aPtr)
constructor.

RulbusDeviceProxy (RulbusDeviceProxyRef rhs)
move constructor.

~RulbusDeviceProxy ()
destructor.

RulbusDeviceProxyRef | operator= (RulbusDeviceProxyRef rhs)
move-assignment constructor.

operator RulbusDevicePtr ()
return pointer to 'this' Rulbus device.

operator RulbusDeviceRef ()
return reference to 'this' Rulbus device.

RulbusDevicePtr operator-> ()
dereference 'this' Rulbus device.

RulbusDeviceRef operator * ()
dereference 'this' Rulbus device.

RulbusDeviceRef get ()
return reference to 'this' Rulbus device.

Protected Member Functions

RulbusDevicePtr transfer ()
'move' pointer to calling method.

Protected Attributes

RulbusDevicePtr thePtr
the Rulbus device pointer

Static Protected Attributes

WindowsUtils::Semaphore | s
guard Rulbus device access

The documentation for this class was generated from the following files:
  • RulbusDeviceProxy.h
  • RulbusDeviceProxy.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusError class Reference

RulbusError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherited by RulbusAddressError, RulbusCloseError, RulbusConfigError, RulbusContextError, RulbusDataError, RulbusHandleError, RulbusInterfaceError, RulbusOpenError, RulbusParseError, RulbusRangeError, RulbusScanError, and RulbusTimeoutError.

List of all members.

Detailed Description

For each kind of error that we want to handle, we create a class that derives from RulbusError. RulbusError provides the means to record a message that can be retrieved lateron via what() and via getLastError().

RulbusError acts for the whole library, but can only remember a single error for all threads. If the message was recorded by a another thread than the one that retrieves the message, the message returned says so. See getLastError().

Accessors

virtual CharCptr | what () const
return message.

virtual unsigned long | lasttid () const
return thread id for current message

bool | getLastError (char *msg, int maxlen)
format last error into message buffer.

Public Member Functions

Construction
RulbusError ()
default constructor.

RulbusError (CharCptr fmt...)
format a Rulbus error.

RulbusError (StringCref string)
set a Rulbus error.

RulbusError (StdExceptionCref e)
constructor taking exception& .

RulbusError (RulbusErrorCref e)
constructor taking RulbusError& .

virtual | ~RulbusError ()
destructor.

Private Attributes

String msg
error message

unsigned long | tid
thread id for this error

Static Private Attributes

RulbusError theError
save the last Rulbus error.

Member Function Documentation

bool getLastError | ( | char * | msg,
 |  | int | maxlen
 | ) | [static]

getLastError() formats the last error into message buffer.

It copies at most maxlen characters (including the terminating \0) of the last error message into the buffer specified by msg.

Only one message is retained for all threads using the Rulbus Device Class Library. If the error message for the thread calling getLastError() is not available (anymore), the following message is returned:

[Rulbus: error message not available for this thread]

Parameters:
msg | the message buffer
maxlen | the size of the message buffer msg
Returns:
false, true (Ok, error)
getLastError() returns false if the message could be copied, it returns true in the following situations:
  • msg is NULL
  • maxlen is zero or less
  • the message was not available for this thread

The documentation for this class was generated from the following files:
  • Exception.h
  • Exception.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusHandleError class Reference

RulbusHandleError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusHandleError creates an error with the following message:
Rulbus: invalid handle 'd'

Public Member Functions

RulbusHandleError (int handle)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusInterfaceError class Reference

RulbusInterfaceError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusInterfaceError creates an error with the following message:
Rulbus: msg

Public Member Functions

RulbusInterfaceError (StringCref msg)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusInterfaceFactory class Reference

RulbusInterfaceFactory Class Reference
[Rulbus Interface]

#include <RulbusInterfaceFactory.h>

List of all members.

Detailed Description

Class RulbusDevice delegates creation of the Rulbus Interface object to this class, member createInterface().

Class RulbusInterfaceFactory determines the type of interface to create from the presence and contents of the RULBUS environment variable.

If the rulbus environment variable does not exist, createInterface() creates an EppRulbusInterface at parallel port address EppRulbusInterface::DEF_EPP_BASE.

If the rulbus environment variable does exist, createInterface() interpretes it as follows:

   rulbus         : interface-name ','?
                  | interface-name ',' base-address?
                  | interface-name ',' base-address ';' nocheck?

   interface-name : isa
                  | epp

   isa            : [iI][sS][aA]   # 'ISA', case insensitive

   epp            : [eE][pP][pP]   # 'EPP', case insensitive

   base-address   : dec-number
                  | hex-number

   dec-number     : [0-9]+

   hex-number     : hex-prefix [0-9a-fA-F]+

   hex-prefix     : '0' [xX]

   nocheck        : 'nocheck'
                  | {other than 'check'}

Examples of valid entries as set in the command interpreter are:

  • RULBUS=isa
  • RULBUS=ISA,0x200, creating an IsaRulbusInterface
  • RULBUS=EPP
  • RULBUS=epp,0x378;nocheck, creating an EppRulbusInterface, not checking for presence

Static Public Member Functions

TheRulbusInterfacePtr createInterface ()
create the Rulbus Interface based on the information from the rulbus environment variable.

Protected Member Functions

RulbusInterfaceFactory ()
prevent instantiation

RulbusInterfaceFactory (RulbusInterfaceFactoryCref)
prevent copying

The documentation for this class was generated from the following files:
  • RulbusInterfaceFactory.h
  • RulbusInterfaceFactory.cpp
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusOpenError class Reference

RulbusOpenError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusCloseError creates an error with the following message:
Rulbus: cannot open rulbus device 'name' at [d:0xHH]

Public Member Functions

RulbusOpenError (StringCref submsg)
constructor.

RulbusOpenError (StringCref name, int rack, int addr)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusParseError class Reference

RulbusParseError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusParseError is thrown by ConfigParser when it cannot recognize the input. It contains the following message:
Rulbus: filename linenumber: msg

Public Member Functions

RulbusParseError (StringCref msg)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusRangeError class Reference

RulbusRangeError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusRangeError creates an error with the following message:
Rulbus: device 'name', range error: parameter value not in [from..to]

Public Member Functions

RulbusRangeError ()
default constructor.

RulbusRangeError (StringCref name, StringCref parameter, int data, int min, int max)
constructor.

RulbusRangeError (StringCref name, StringCref parameter, long data, long min, long max)
constructor.

RulbusRangeError (StringCref name, StringCref parameter, Real data, Real min, Real max)
constructor.

RulbusRangeError (StringCref name, StringCref parameter, StringCref data, StringCref set)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusScanError class Reference

RulbusScanError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusScanError is thrown by ConfigScanner when it cannot recognize the input. It contains the following message:
Rulbus: filename linenumber: msg

Public Member Functions

RulbusScanError (StringCref msg)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusTimeoutError class Reference

RulbusTimeoutError Class Reference
[Rulbus Errors]

#include <Exception.h>

Inherits RulbusError.

List of all members.

Detailed Description

RulbusTimeoutError creates an error with the following message:
Rulbus: device 'name', timeout: msg

Public Member Functions

RulbusTimeoutError ()
default constructor.

RulbusTimeoutError (StringCref name, StringCref msg)
constructor.

The documentation for this class was generated from the following file:
  • Exception.h
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: TemplateSingleton class Reference

Singleton Class Template Reference

#include <Singleton.h>

List of all members.

Detailed Description

template<typename T>
class Rulbus::Singleton< T >

Template class Singleton is the base for classes that follow the singleton pattern.

It is used as follows.

 class TheRulbusDeviceList : public Singleton<TheRulbusDeviceList>
 {
    friend class Singleton<TheRulbusDeviceList>;

    // implementation
 };

If the instance cannot be created via the default constructor, static function instance() must be overridden to create the (single) instance, for example:

 inline TheRulbusInterfaceRef TheRulbusInterface::instance()
 {
    if ( 0 == theInstance )
    {
       theInstance = RulbusInterfaceFactory::createInterface();
    }

    return *theInstance;
 }

Static Public Member Functions

T & | instance ()
return the instance, creating it if necessary.

Static Protected Attributes

T * | theInstance = 0
the single instance.

The documentation for this class was generated from the following file:
  • Singleton.h
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: TheRulbusDeviceList class Reference

TheRulbusDeviceList Class Reference

#include <RulbusDeviceList.h>

Inherits Singleton< TheRulbusDeviceList >.

List of all members.

Detailed Description

Class TheRulbusDeviceList maintains the handle -- RulbusDevice relationship. The DLL interface functions use it as follows:
  • add -- a new Rulbus device object is added to the list
  • open -- a Rulbus device object is looked-up by its name, a handle that corresponds to this device object is returned
  • use -- given the handle, member get() returns a RulbusDeviceProxy to the device object from the list
  • close -- this is a no-op (it leaves the device on the list)
  • remove -- given a handle, the corresponding device object is removed from the list and it is destroyed (not implemented)

So, the TheRulbusDeviceList owns the Rulbus devices on its list: When a Rulbus device is removed from the list, it is also destroyed.

Thread Safety

Access to the list is guarded with a semaphore, so that calls to add() and remove() from different threads of execution cannot interact destructively on the list.

Public Member Functions

void | clear ()
destruct all devices and empty the list.

void | add (RulbusDevicePtr deviceptr)
add a device to the list.

void | remove (RulbusDevicePtr deviceptr)
remove a device from the list.

void | remove (int handle)
remove a device from the list.

int | open (Name aName)
return a handle to the device specified by aName.

void | close (int handle)
close device represented by handle (no-op).

RulbusDeviceProxy | get (int handle)
return Rulbus device proxy for handle; may throw RulbusHandleError.

void | check ()
check configuration for name and address conflicts, used by ConfigParser; based on code by Jens Thoms Törring.

bool | printOn (std::ostream &stream)
print contents of device list to specified stream.

Protected Member Functions

TheRulbusDeviceList ()
constructor.

~TheRulbusDeviceList ()
destructor.

TheRulbusDeviceList (TheRulbusDeviceListCref rhs)
prevent copying

TheRulbusDeviceList | operator= (TheRulbusDeviceListCref rhs)
prevent copying

Private Attributes

List theList
the Rulbus device list

WindowsUtils::SemaphorePtr | s
semaphore to guard table access

Friends

class | Singleton< TheRulbusDeviceList >

The documentation for this class was generated from the following files:
  • RulbusDeviceList.h
  • RulbusDeviceList.cpp
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: TheRulbusInterface class Reference

TheRulbusInterface Class Reference
[Rulbus Interface]

#include <RulbusInterface.h>

Inherits Singleton< TheRulbusInterface >.

Inherited by EppRulbusInterface, and IsaRulbusInterface.

List of all members.

Detailed Description

Class TheRulbusInterface provides two interfaces:
  • a client interface for Rulbus Devices:
    it consists of the primitive operations to read a byte from and to write a byte to the Rulbus of a specific Rulbus rack, getByte() and putByte().
  • a provider interface for Rulbus Interfaces:
    this interface consists of the funtions to read a byte from and to write a byte to the Rulbus for the Rulbus Interface they represent, getReg() and putReg().

TheRulbusInterface implements the client interface and publishes the provider interface (pure abstract function declarations).

The client interface implemented by functions getByte() and putByte() builds on getReg() and putReg(), for which implementations are given by classes that implement the provider interface.

Thread safety

getByte() and putByte() do complete Rulbus addressing as one atomic operation: select the device's rack and read a byte from or write a byte to the Rulbus. The operation must be atomic (may not be done partially) to prevent different threads of execution to hinder each other's access to the Rulbus.

Public Member Functions

Client interface
int | getByte (int rack, int offset) const
read a byte from Rulbus address [rack,offset] (concrete).

int | putByte (int rack, int offset, int byte) const
write a byte to Rulbus address [rack,offset] (concrete).

Accessor
virtual bool | invariant () const
check class invariant.

Printer
virtual bool | printOn (std::ostream &stream) const =0
print a string describing the Rulbus Interface (abstract).

Static Public Member Functions

Construction
TheRulbusInterfaceRef instance ()
return the instance, creating it if needed.

Static Public Attributes

const int | ANY_RACK = 0xF
always selected

Protected Member Functions

Construction
TheRulbusInterface ()
default constructor.

~TheRulbusInterface ()
destructor.

Provider interface
virtual int | getReg (int offset) const =0
read a byte from the Rulbus (abstract).

virtual int | putReg (int offset, int byte) const =0
write a byte to the Rulbus (abstract).

Private Attributes

WindowsUtils::SemaphorePtr | s
guard Rulbus access

Friends

class | Singleton< TheRulbusInterface >

The documentation for this class was generated from the following files:
  • RulbusInterface.h
  • RulbusInterface.cpp
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Via class Reference

Via Class Reference
[PIA/VIA]

#include <PiaVia.h>

Inherits PiaVia.

Inherited by RB8506_Via.

List of all members.

Detailed Description

This is the driver for the Parallel Interface module with the the Rockwell R6522 Versatile Interface Adapter (VIA).

A VIA has the following registers:

   Registers       Offset  Rd/Wr   Description
   ------------------------------------------------------------------------------
   PDRB             0      rd/wr   Port B Peripheral Data Register
   PDRA             1      rd/wr   Port A Peripheral Data Register
   DDRB             2      rd/wr   Port B Data Direction Register
   DDRA             3      rd/wr   Port A Data Direction Register
   T1CL             4      rd/wr   Timer 1 counter LSB
   T1CH             5      rd/wr   Timer 1 counter MSB
   T1LL             6      rd/wr   Timer 1 latch   LSB
   T1LH             7      rd/wr   Timer 1 latch   MSB
   T2L              8      rd/wr   Timer 2 LSB, write latch, read counter
   T2H              9      rd/wr   Timer 2 MSB, write latch, read counter
   SR              10      rd/wr   Shift Register
   ACR             11      rd/wr   Auxiliary Control Register
   PCR             12      rd/wr   Peripheral Control Register
   IFR             13      rd/wr   Interrupt Flag Register
   IER             14      rd/wr   Interrupt Enable Register
   PDRA            15      rd/wr   Port A Peripheral Data Register, no handshake

Each of the peripheral data lines (PA0..PA7, PB0..PB7) can be programmed to act as input or output. This is accomplished by setting a "1" in the corresponding Data Direction Register bit for those lines which are to be outputs. A "0" in a bit of the Data Direction Register causes the corresponding peripheral data line to act as an input.

Peripheral Data Register:

   76543210 : data bits 0..7, 0 for low, 1 for high output.

Data Direction Register:

   76543210 : data direction bits, 0 for input, 1 for output.

Peripheral Control Register (PCR):

   76543210

   765      : CB2 control; see CA2 control (bits 321)
      4     : CB2 interrupt control; see CA2 interrupt control (bit 0)

       321  : CA2 control
              321 : CA2 input
              3   : 0 : CA2 input
               2  : CA2 active transition for setting IRQA2 flag
                    0 : IRQA2 set by high-to-low transition on CA2
                    1 : IRQA2 set by low-to-high transition on CA2
                1 : independent interrupt
                    0 : CA1 dependent interrupt
                    1 : independent interrupt; see *), IFR

              321 : CA2 output
              3   : 1 : CA2 output
               21 : CA2 output control
                    0x: strobed CA2 output
                    1x: programmed CA2 output with level of bit 3
                    00: CA2 Handshake output
                    01: CA2 Pulse output
                    10: CA2 low
                    11: CA2 high

                 0: CA1 active transition for setting IRQA1
                    0 : IRQA1 set by high-to-low transition on CA1
                    1 : IRQA1 set by low-to-high transition on CA1

Auxiliary Control Register (ACR):

   76543210 : timer control (not used)

Interrupt Flag Register (IFR):

   76543210 : what  set                    cleared
   7        : CA2   CA2 active edge        read or write PDRA *)
    6       : CA1   CA1 active edge        read or write PDRA *)
     5      : SR    complete 8 shifts      read or write SR
      4     : CB2   CB2 active edge        read or write PDRB *)
       3    : CB1   CB1 active edge        read or write PDRB
        2   : T2    time out of T2         read T2L or write T2H
         1  : T1    time out of T1         read T1L or write T1H
          0 : IRQ   any enabled interrupt  clear all interrupts

          *): if the CA2/CB2 control in the PCR is selected as "independent"
              interrupt input, then reading or writing the output register
              PDRA/PDRB will NOT clear the flag bit. Instead, the bit must
              be cleared by writing a one into the appropriate bit of the IFR.

Interrupt Enable Register (IER):

   76543210
   7        : set/clear (reads as "1")
              0 : disable interrupts corresponding to bits set
              1 : enable  interrupts corresponding to bits set
    6       : T1
     5      : T2
      4     : CB1
       3    : CB2
        2   : SR
         1  : CA1
          0 : CA2

Public Member Functions

Construction
Via (NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK)
constructor; may throw RulbusOpenError

virtual | ~Via ()
destructor (no-op)

Accessors -- port A
int | getIrqCA1 ()
CA1 input: interrupt request pending.

char | getEdgeCA1 ()
CA1 input: get active edge ['p','n'].

int | getIntrCA1 ()
CA1 input: get interrupt enable state.

char | getDirCA2 ()
CA2 i/o: get data direction ['i','o'].

int | getLevelCA2 ()
CA2 i/o: get level [0,1].

Accessors -- port B
int | getIrqCB1 ()
CB1 input: interrupt request pending.

char | getEdgeCB1 ()
CB1 input: get active edge ['p','n'].

int | getIntrCB1 ()
CB1 input: get interrupt enable state.

char | getDirCB2 ()
CB2 i/o: get data direction ['i','o'].

int | getLevelCB2 ()
CB2 i/o: get level [0,1].

Mutators -- port A
void | setEdgeCA1 (char edge)
CA1 input: set active edge ['p','n']; may throw RulbusRangeError.

int | setIntrCA1 (int enable)
CA1 input: enable/disable interrupt.

void | setDirCA2 (char dir)
CA2 i/o: set data direction ['i','o']; may throw RulbusRangeError.

void | setLevelCA2 (int lvl)
CA2 i/o: set level [0,!0]; may throw RulbusContextError.

Mutators -- port B
void | setEdgeCB1 (char edge)
CB1 input: set active edge ['p','n']; may throw RulbusRangeError.

int | setIntrCB1 (int enable)
CB1 input: enable/disable interrupt.

void | setDirCB2 (char dir)
CB2 i/o: set data direction ['i','o']; may throw RulbusRangeError.

void | setLevelCB2 (int lvl)
CB2 i/o: set level [0,!0]; may throw RulbusContextError.

Static Public Attributes

Defaults
const int | DEF_ADDR = 0x90
default rulbus address

const int | DEF_RACK = 0
default rack

Protected Member Functions

Accessors -- port A, B
int | getDDRA ()
Port A: get data direction register.

int | getPDRA ()
Port A: get peripheral data register.

int | getDDRB ()
Port B: get data direction register.

int | getPDRB ()
Port B: get peripheral data register.

Mutators -- port A, B
void | setDDRA (int dir)
Port A: set data direction register.

void | setPDRA (int dat)
Port A: set peripheral data register.

void | setDDRB (int dir)
Port B: set data direction register.

void | setPDRB (int dat)
Port B: set peripheral data register.

Private Member Functions

Mutators -- port A, B
int | getIrqC1 (int mask)
C[AB]1: test for interrupt request pending.

char | getEdgeC1 (int shift)
C[AB]1: get active edge ['p','n'].

void | setEdgeC1 (int shift, char edge, char port)
C[AB]1: set active edge ['p','n']; may throw RulbusRangeError.

int | getIntrC1 (int mask)
C[AB]1: get interrupt enable state.

int | setIntrC1 (int mask, int enable)
C[AB]1: enable/disable interrupt.

Mutators -- port A, B
char | getDirC2 (int shift)
C[AB]2: get data direction.

void | setDirC2 (int shift, char dir, char port)
C[AB]2: set data direction; may throw RulbusRangeError.

int | getLevelC2 (int shift, char port)
C[AB]2: get line level.

void | setLevelC2 (int shift, int lvl, char port)
C[AB]2: set line level; may throw RulbusContextError.

Static Private Attributes

Register offsets
const int | OFF_PDRB = 0
peripheral data register B

const int | OFF_PDRA = 1
peripheral data register A

const int | OFF_DDRB = 2
data direction register B

const int | OFF_DDRA = 3
data direction register A

const int | OFF_T1CL = 4
timer 1 counter low order byte

const int | OFF_T1CH = 5
timer 1 counter high order byte

const int | OFF_T1LL = 6
timer 1 latch low order byte

const int | OFF_T1LH = 7
timer 1 latch high order byte

const int | OFF_T2CL = 8
timer 1 latch high order byte

const int | OFF_T2CH = 9
timer 1 counter low order byte

const int | OFF_SR = 10
shift register

const int | OFF_ACR = 11
auxiliary control register

const int | OFF_PCR = 12
peripheral control register

const int | OFF_IFR = 13
interrupt flag register

const int | OFF_IER = 14
interrupt enable register

const int | OFF_PDRA_NH = 15
peripheral data register A, no handshake

const int | ADR_WIDTH = OFF_PDRA_NH + 1
address with

Shift control bits left for CA/CB
const int | SHL_CA = 0
zero bit shift left for CA

const int | SHL_CB = 4
four bit shift left for CB

Bit masks for CA1/CB1
const int | MSK_ATC1 = 0x01
active transition CA1/CB1 (0:neg, 1:pos)

Bit masks for CA2/CB2: NOTE: Read/Write strobe not supported
const int | MSK_DIRC2 = 0x08
C2 i/o direction.

const int | MSK_POC2 = 0x04
C2 programmed output.

const int | MSK_OLC2 = 0x02
C2 output level.

IFR -- interrupt flag register
const int | MSK_IFCA2 = 0x01
CA2.

const int | MSK_IFCA1 = 0x02
CA1.

const int | MSK_IFSR = 0x04
Shift Register.

const int | MSK_IFCB2 = 0x08
CB2.

const int | MSK_IFCB1 = 0x10
CB1.

const int | MSK_IFCT2 = 0x20
Timer 2.

const int | MSK_IFCT1 = 0x40
Timer 1.

const int | MSK_IFIRQ = 0x80
any interrupt request

IER -- interrupt enable register
const int | MSK_IECA2 = 0x01
CA2.

const int | MSK_IECA1 = 0x02
CA1.

const int | MSK_IESR = 0x04
Shift Register.

const int | MSK_IECB2 = 0x08
CB2.

const int | MSK_IECB1 = 0x10
CB1.

const int | MSK_IECT2 = 0x20
Timer 2.

const int | MSK_IECT1 = 0x40
Timer 1.

const int | MSK_IESC = 0x80
Set/Clear.

The documentation for this class was generated from the following files:
  • PiaVia.h
  • PiaVia.cpp
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Hierarchical Index

Rulbus Device Class Library for Microsoft Windows Class Hierarchy

This inheritance list is sorted roughly, but not completely, alphabetically:
  • Assertion
    • DbcException
      • AssertException
      • EnsureException
      • NeverGetHereException
      • RequireException
  • BoundIoFormat
  • ConfigBuilder
    • ConfigListBuilder
    • ConfigPrinter
  • ConfigContext
  • ConfigKeyword
  • ConfigParser
  • ConfigParser::ParseError
  • ConfigScanner
  • ConfigToken
    • ConfigEofToken
    • ConfigErrorToken
    • ConfigNumberToken
    • ConfigSpecialToken
    • ConfigStringToken
    • ConfigWordToken
  • IoFormat
  • isEqual
  • PportAddresses
  • RB8515_clock::FreqTable
  • RB9005_amplifier::RegInfo
  • RulbusDevice
    • PiaVia
      • Pia
        • RB8506_Pia
        • RB8506_Sifu
      • Via
        • RB8506_Via
    • RB8509_Adc12
    • RB8510_Dac12
    • RB8513_timebase
    • RB8514_delay
    • RB8515_clock
    • RB8905_Adc12
    • RB9005_amplifier
    • RB9603_monochromator
  • RulbusDeviceFactory
  • RulbusDeviceProxy
  • RulbusError
    • RulbusAddressError
    • RulbusCloseError
    • RulbusConfigError
    • RulbusContextError
    • RulbusDataError
    • RulbusHandleError
    • RulbusInterfaceError
    • RulbusOpenError
    • RulbusParseError
    • RulbusRangeError
    • RulbusScanError
    • RulbusTimeoutError
  • RulbusInterfaceFactory
  • Singleton
  • Singleton< TheRulbusDeviceList >
    • TheRulbusDeviceList
  • Singleton< TheRulbusInterface >
    • TheRulbusInterface
      • EppRulbusInterface
      • IsaRulbusInterface
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Compound Member Index

Here is a list of all documented class members with links to the class documentation for each member:

- a -

  • adcMeanWavelength() : RB9603_monochromator
  • adcWavelength() : RB9603_monochromator
  • add() : TheRulbusDeviceList, ConfigPrinter, ConfigListBuilder, ConfigBuilder
  • addCard() : ConfigParser
  • addr() : RulbusDevice
  • AddrList : ConfigParser
  • ADR_WIDTH : RB9603_monochromator, RB9005_amplifier, RB8905_Adc12, RB8515_clock, RB8514_delay, RB8513_timebase, RB8510_Dac12, RB8509_Adc12, Via, Pia
  • already_assigned : ConfigParser
  • ANY_RACK : TheRulbusInterface, RulbusDevice
  • arm() : RB8905_Adc12
  • AssertException() : AssertException
  • Assertion() : Assertion
  • autoscale() : RB8509_Adc12

- b -

  • base() : IsaRulbusInterface, EppRulbusInterface
  • baseMax : IsaRulbusInterface
  • baseMin : IsaRulbusInterface
  • basePCIMax : PportAddresses
  • basePCIMin : PportAddresses
  • basePCIStp : PportAddresses
  • baseStp : IsaRulbusInterface
  • begin() : PportAddresses
  • boolalpha() : IoFormat
  • BoundIoFormat() : BoundIoFormat
  • bufferCapacity() : RB8905_Adc12
  • bufferSize() : RB8905_Adc12

- c -

  • c : ConfigKeyword
  • calibrate() : RB9603_monochromator
  • CardList : ConfigParser
  • channel() : RB9005_amplifier, RB8509_Adc12
  • check() : TheRulbusDeviceList, ConfigListBuilder, ConfigBuilder
  • checkBusViolation() : RulbusDevice
  • checkCardDeclarations() : ConfigParser
  • checkChannel() : RB9005_amplifier, RB8509_Adc12
  • checkData() : PiaVia
  • checkDir() : PiaVia
  • checkDuplicateCardName() : ConfigParser
  • checkDuplicateRackAddr() : ConfigParser
  • checkDuplicateRackName() : ConfigParser
  • checkGain() : RB8509_Adc12
  • checkMask() : PiaVia
  • checkOverlapCardAddr() : ConfigParser
  • checkPin() : PiaVia
  • checkRackAllowed() : ConfigParser
  • checkRackDeclaration() : ConfigParser
  • checkRead() : RB8905_Adc12
  • checkValidAddress() : RulbusDevice
  • checkWavelength() : RB9603_monochromator
  • clear() : TheRulbusDeviceList
  • clearAddress() : RB8905_Adc12
  • clearEppTimeout() : EppRulbusInterface
  • clearFlipFlops() : RB8506_Sifu
  • clearInterrupt() : RB8515_clock, RB8514_delay
  • clearRackCardList() : ConfigParser
  • clkTable : RB8515_clock
  • clockFrequency() : RB8515_clock, RB8514_delay
  • clockRateMultiplier() : RB8513_timebase
  • clockRateSelector() : RB8513_timebase
  • close() : TheRulbusDeviceList
  • code : ConfigToken, RB8515_clock::FreqTable
  • COM_CNT : RB9603_monochromator
  • COM_EOT : RB9603_monochromator
  • COM_GET : RB9603_monochromator
  • COM_LEN : RB9603_monochromator
  • COM_RDY : RB9603_monochromator
  • COM_SLPMS : RB9603_monochromator
  • ComCodes : RB9603_monochromator
  • CON_JMP3 : RB8905_Adc12
  • CON_MPS : RB9603_monochromator
  • CON_TRELAIS : RB8905_Adc12
  • ConfigListBuilder() : ConfigListBuilder
  • ConfigParser() : ConfigParser
  • ConfigPrinter() : ConfigPrinter
  • ConfigScanner() : ConfigScanner
  • const_iterator : PportAddresses
  • convert() : RB8509_Adc12
  • Count : RB8514_delay
  • countByte0() : RB8514_delay
  • countByte1() : RB8514_delay
  • countByte2() : RB8514_delay
  • createDevices() : RulbusDeviceFactory
  • createInterface() : RulbusInterfaceFactory
  • currentWavelength() : RB9603_monochromator

- d -

  • DbcException() : DbcException
  • dec() : IoFormat
  • DEF_ADDR : RB9603_monochromator, RB9005_amplifier, RB8905_Adc12, RB8515_clock, RB8514_delay, RB8513_timebase, RB8510_Dac12, RB8509_Adc12, RB8506_Sifu, Via, Pia
  • DEF_BIP : RB8510_Dac12, RB8509_Adc12
  • DEF_CHAN : RB8509_Adc12
  • DEF_CLKFRQ : RB8515_clock
  • DEF_CNT : RB8514_delay
  • DEF_DIRCA2 : RB8506_Sifu
  • DEF_DIRCB2 : RB8506_Sifu
  • DEF_DIRPA : RB8506_Sifu
  • DEF_DIRPB : RB8506_Sifu
  • DEF_DLY : RB8514_delay
  • DEF_EDGECB1 : RB8506_Sifu
  • DEF_EE1 : RB8514_delay
  • DEF_EE2 : RB8514_delay
  • DEF_EINT : RB8514_delay
  • DEF_EPP_BASE : EppRulbusInterface
  • DEF_ES1 : RB8514_delay
  • DEF_ES2 : RB8514_delay
  • DEF_ETI : RB8509_Adc12
  • DEF_ETRG : RB8514_delay
  • DEF_FRQ : RB8514_delay
  • DEF_GAIN : RB8509_Adc12
  • DEF_IDT : RB8514_delay
  • DEF_INTFRQ : RB8515_clock
  • DEF_INTRCB1 : RB8506_Sifu
  • DEF_ISA_BASE : IsaRulbusInterface
  • DEF_LE12 : RB8514_delay
  • DEF_LS12 : RB8514_delay
  • DEF_LVLCA2 : RB8506_Sifu
  • DEF_LVLCB2 : RB8506_Sifu
  • DEF_MUL : RB8513_timebase
  • DEF_OUTDATA : RB8506_Sifu
  • DEF_RACK : RulbusDevice, Via, Pia
  • DEF_SAMPLES : RB8905_Adc12
  • DEF_SEL : RB8513_timebase
  • DEF_VPB : RB8905_Adc12, RB8510_Dac12, RB8509_Adc12
  • delayCount() : RB8514_delay
  • delayTime() : RB8514_delay
  • description() : DbcException
  • destroyDevices() : RulbusDeviceFactory
  • detectJmp3BufferSize() : RB8905_Adc12
  • disableInterrupt() : RB8515_clock

- e -

  • elemSize() : RB8905_Adc12
  • enableChannelSequenceMode() : RB9005_amplifier
  • enableClockSequenceMode() : RB9005_amplifier
  • enableEnd1() : RB8514_delay
  • enableEnd2() : RB8514_delay
  • enableExtTrigger() : RB8509_Adc12
  • enableInterrupt() : RB8905_Adc12, RB8515_clock, RB8514_delay, RB8509_Adc12
  • enableMultiplexer() : RB8509_Adc12
  • enablePulseOutputs() : RB8506_Sifu
  • enableSignal() : RB8514_delay
  • enableStart1() : RB8514_delay
  • enableStart2() : RB8514_delay
  • end() : PportAddresses
  • end12Direction() : RB8514_delay
  • EnsureException() : EnsureException
  • eofToken : ConfigScanner
  • EppRulbusInterface() : EppRulbusInterface
  • EppTimedOut() : EppRulbusInterface
  • eqAddr() : RulbusDevice
  • eqRack() : RulbusDevice
  • errorToken : ConfigScanner
  • expect() : ConfigParser
  • extTriggerLevel() : RB8509_Adc12

- f -

  • FC_0Hz : RB8515_clock
  • FC_100Hz : RB8515_clock
  • FC_100kHz : RB8515_clock
  • FC_100MHz : RB8515_clock
  • FC_10kHz : RB8515_clock
  • FC_10MHz : RB8515_clock
  • FC_1kHz : RB8515_clock
  • FC_1MHz : RB8515_clock
  • FC_INVALID : RB8515_clock
  • FI_0Hz : RB8515_clock
  • FI_100Hz : RB8515_clock
  • FI_10Hz : RB8515_clock
  • FI_1Hz : RB8515_clock
  • FI_1kHz : RB8515_clock
  • FI_500Hz : RB8515_clock
  • FI_50Hz : RB8515_clock
  • FI_5kHz : RB8515_clock
  • FI_INVALID : RB8515_clock
  • file() : Assertion
  • filename() : ConfigScanner
  • fill() : IoFormat
  • fixed() : IoFormat
  • flags() : IoFormat
  • fmtflags : IoFormat
  • freq : RB8515_clock::FreqTable
  • freq12Table : RB9005_amplifier

- g -

  • gain() : RB9005_amplifier, RB8509_Adc12
  • gain12() : RB9005_amplifier
  • gain12Table : RB9005_amplifier
  • gain34() : RB9005_amplifier
  • gain34Table : RB9005_amplifier
  • GainInfoTable : RB9005_amplifier
  • general() : IoFormat
  • get() : RulbusDeviceProxy, TheRulbusDeviceList, ConfigScanner, ConfigErrorToken, ConfigEofToken, ConfigSpecialToken, ConfigStringToken, ConfigNumberToken, ConfigWordToken, ConfigToken
  • getByte() : TheRulbusInterface, RulbusDevice
  • getCharacter() : RB9603_monochromator
  • getClkFreqCode() : RB8515_clock
  • getDataPA() : PiaVia
  • getDataPB() : PiaVia
  • getDDRA() : Via, Pia, PiaVia
  • getDDRB() : Via, Pia, PiaVia
  • getDirC2() : Via, Pia
  • getDirCA2() : Via, Pia, PiaVia
  • getDirCB2() : Via, Pia, PiaVia
  • getDirection() : RB8514_delay
  • getDirPA() : PiaVia
  • getDirPB() : PiaVia
  • getEdgeC1() : Via, Pia
  • getEdgeCA1() : Via, Pia, PiaVia
  • getEdgeCB1() : Via, Pia, PiaVia
  • getEnable() : RB8514_delay
  • getFreqCode() : RB8515_clock
  • getInputLineLevel() : RB8506_Sifu
  • getInputPortData() : RB8506_Sifu
  • getIntFreqCode() : RB8515_clock
  • getIntrC1() : Via, Pia
  • getIntrCA1() : Via, Pia, PiaVia
  • getIntrCB1() : Via, Pia, PiaVia
  • getIrqC1() : Via, Pia
  • getIrqCA1() : Via, Pia, PiaVia
  • getIrqCB1() : Via, Pia, PiaVia
  • getLastError() : RulbusError
  • getLevelC2() : Via, Pia
  • getLevelCA2() : Via, Pia, PiaVia
  • getLevelCB2() : Via, Pia, PiaVia
  • getLineDir() : PiaVia
  • getLineDirPA() : PiaVia
  • getLineDirPB() : PiaVia
  • getLineLevel() : PiaVia
  • getLineLevelPA() : PiaVia
  • getLineLevelPB() : PiaVia
  • getOutputLineLevel() : RB8506_Sifu
  • getOutputPortData() : RB8506_Sifu
  • getPDRA() : Via, Pia, PiaVia
  • getPDRB() : Via, Pia, PiaVia
  • getPortData() : PiaVia
  • getPortDir() : PiaVia
  • getRawValue() : RB8905_Adc12
  • getReg() : TheRulbusInterface, IsaRulbusInterface, EppRulbusInterface
  • getString() : RB9603_monochromator
  • getToken() : ConfigParser
  • getValue() : RB8905_Adc12

- h -

  • hasExtTriggerInput() : RB8509_Adc12
  • hex() : IoFormat

- i -

  • initializeEpp() : EppRulbusInterface
  • instance() : Singleton, TheRulbusInterface
  • interfacePresent() : EppRulbusInterface
  • internal() : IoFormat
  • interruptFrequency() : RB8515_clock
  • intervalTime() : RB8513_timebase
  • intrinsicDelayTime() : RB8514_delay
  • intTable : RB8515_clock
  • invariant() : TheRulbusInterface, IsaRulbusInterface, EppRulbusInterface
  • IoFormat() : IoFormat
  • is : ConfigScanner
  • IsaRulbusInterface() : IsaRulbusInterface
  • isAsnop() : ConfigToken
  • isBipolar() : RB8510_Dac12, RB8509_Adc12
  • isBool() : ConfigToken
  • isBusy() : RB8514_delay
  • isBusyAdc() : RB8509_Adc12
  • isCard() : ConfigToken
  • isChangedInputLine() : RB8506_Sifu
  • isChannelSequenceMode() : RB9005_amplifier
  • isClockSequenceMode() : RB9005_amplifier
  • isDelim() : ConfigToken
  • isEnabledEnd1() : RB8514_delay
  • isEnabledEnd2() : RB8514_delay
  • isEnabledExtTrigger() : RB8509_Adc12
  • isEnabledInterrupt() : RB8905_Adc12, RB8515_clock, RB8514_delay, RB8509_Adc12
  • isEnabledMultiplexer() : RB8509_Adc12
  • isEnabledPulseOutputs() : RB8506_Sifu
  • isEnabledSignal() : RB8514_delay
  • isEnabledStart1() : RB8514_delay
  • isEnabledStart2() : RB8514_delay
  • isEqual() : isEqual
  • isFastMode() : RB8905_Adc12
  • isKind() : ConfigToken
  • isPendingInterrupt() : RB8515_clock, RB8514_delay, RB8509_Adc12
  • isReady() : RB9603_monochromator, RB8905_Adc12, RB8509_Adc12
  • isUnipolarMode() : RB8905_Adc12
  • isUnit() : ConfigToken
  • isValid() : PportAddresses
  • isValidChannel() : RB8509_Adc12
  • isValidClockFrequency() : RB8514_delay
  • isValidDelayCount() : RB8514_delay
  • isValidGain() : RB8509_Adc12
  • isValidIntrinsicTime() : RB8514_delay
  • isValidSignalDirection() : RB8514_delay
  • isValidSignalName() : RB8514_delay

- j -

  • jmp3BufferCapacity() : RB8905_Adc12
  • jmp3BufferSize() : RB8905_Adc12

- k -

  • kindTable : ConfigToken
  • kPportAddresses : PportAddresses

- l -

  • lasttid() : RulbusError
  • left() : IoFormat
  • LIM_BIPVAL : RB8510_Dac12, RB8509_Adc12
  • LIM_CNTMAX : RB8514_delay
  • LIM_CNTMIN : RB8514_delay
  • LIM_FRQMAX : RB8514_delay
  • LIM_FRQMIN : RB8514_delay
  • LIM_IDTMAX : RB8514_delay
  • LIM_IDTMIN : RB8514_delay
  • LIM_MAXBUFSIZE : RB8905_Adc12
  • LIM_MAXCHAN : RB8509_Adc12
  • LIM_MAXCHN : RB9005_amplifier
  • LIM_MAXGAIN : RB8509_Adc12
  • LIM_MAXJMP3SIZE : RB8905_Adc12
  • LIM_MAXVAL : RB8510_Dac12, RB8509_Adc12
  • LIM_MAXVAL12 : RB8905_Adc12
  • LIM_MAXVAL8 : RB8905_Adc12
  • LIM_MAXVPB : RB8509_Adc12
  • LIM_MINBUFSIZE : RB8905_Adc12
  • LIM_MINCHAN : RB8509_Adc12
  • LIM_MINCHN : RB9005_amplifier
  • LIM_MINGAIN : RB8509_Adc12
  • LIM_MINJMP3SIZE : RB8905_Adc12
  • LIM_MINVAL : RB8510_Dac12, RB8509_Adc12
  • LIM_MINVAL12 : RB8905_Adc12
  • LIM_MINVAL8 : RB8905_Adc12
  • LIM_MINVPB : RB8509_Adc12
  • LIM_MULMAX : RB8513_timebase
  • LIM_MULMIN : RB8513_timebase
  • LIM_RACKS : ConfigParser
  • LIM_SELMAX : RB8513_timebase
  • LIM_SELMAXFIXED : RB8513_timebase
  • LIM_SELMIN : RB8513_timebase
  • LIM_TIMOUT : RB8509_Adc12
  • line() : Assertion
  • LineList : ConfigParser
  • linenumber() : ConfigScanner
  • lowPassFrequency() : RB9005_amplifier
  • lpf12() : RB9005_amplifier
  • lpf34() : RB9005_amplifier

- m -

  • m_a : isEqual
  • maxInputVoltage() : RB8905_Adc12
  • maxWavelength() : RB9603_monochromator
  • minInputVoltage() : RB8905_Adc12
  • minWavelength() : RB9603_monochromator
  • msg : RulbusError
  • msgtitle : IsaRulbusInterface, EppRulbusInterface
  • MSK_ADCALL12 : RB8905_Adc12
  • MSK_ADCALL8 : RB8905_Adc12
  • MSK_ADCMSB12 : RB8905_Adc12
  • MSK_ADCMSB8 : RB8905_Adc12
  • MSK_ATC1 : Via, Pia
  • MSK_ATC2 : Pia
  • MSK_BYTE : RB8514_delay
  • MSK_CHN1 : RB9005_amplifier
  • MSK_CHN2 : RB9005_amplifier
  • MSK_CHNSEQ : RB9005_amplifier
  • MSK_CLKFRQ : RB8515_clock
  • MSK_CLKSEQ : RB9005_amplifier
  • MSK_CTLBSIZE : RB8905_Adc12
  • MSK_CTLCHAN : RB8509_Adc12
  • MSK_CTLCLEAR : RB8905_Adc12
  • MSK_CTLEE1 : RB8514_delay
  • MSK_CTLEE2 : RB8514_delay
  • MSK_CTLES1 : RB8514_delay
  • MSK_CTLES2 : RB8514_delay
  • MSK_CTLFAST : RB8905_Adc12
  • MSK_CTLGAIN : RB8509_Adc12
  • MSK_CTLINT : RB8514_delay
  • MSK_CTLINTR : RB8905_Adc12, RB8509_Adc12
  • MSK_CTLLE12 : RB8514_delay
  • MSK_CTLLS12 : RB8514_delay
  • MSK_CTLMPLX : RB8509_Adc12
  • MSK_CTLREAD : RB8905_Adc12
  • MSK_CTLTRG : RB8514_delay
  • MSK_CTLTRIG : RB8509_Adc12
  • MSK_CTLUNIP : RB8905_Adc12
  • MSK_DIRC2 : Via, Pia
  • MSK_EIC1 : Pia
  • MSK_EIC2 : Pia
  • MSK_EPP_Timeout : EppRulbusInterface
  • MSK_GAIN1 : RB9005_amplifier
  • MSK_GAIN2 : RB9005_amplifier
  • MSK_GAIN3 : RB9005_amplifier
  • MSK_GAIN4 : RB9005_amplifier
  • MSK_IECA1 : Via
  • MSK_IECA2 : Via
  • MSK_IECB1 : Via
  • MSK_IECB2 : Via
  • MSK_IECT1 : Via
  • MSK_IECT2 : Via
  • MSK_IESC : Via
  • MSK_IESR : Via
  • MSK_IFCA1 : Via
  • MSK_IFCA2 : Via
  • MSK_IFCB1 : Via
  • MSK_IFCB2 : Via
  • MSK_IFCT1 : Via
  • MSK_IFCT2 : Via
  • MSK_IFIRQ : Via
  • MSK_IFSR : Via
  • MSK_INTCLRn : RB8515_clock
  • MSK_INTENA : RB8515_clock
  • MSK_INTFRQ : RB8515_clock
  • MSK_INTSTS : RB8515_clock
  • MSK_IRQ1 : Pia
  • MSK_IRQ2 : Pia
  • MSK_LPF12 : RB9005_amplifier
  • MSK_OLC2 : Via, Pia
  • MSK_POC2 : Via, Pia
  • MSK_SELSTP : RB8513_timebase
  • MSK_SPDR : Pia
  • MSK_SPP_AutoLF : EppRulbusInterface
  • MSK_SPP_EnaBiDirect : EppRulbusInterface
  • MSK_SPP_EnaIRQVAL : EppRulbusInterface
  • MSK_SPP_nAck : EppRulbusInterface
  • MSK_SPP_nBusy : EppRulbusInterface
  • MSK_SPP_nError : EppRulbusInterface
  • MSK_SPP_nIRQ : EppRulbusInterface
  • MSK_SPP_nReset : EppRulbusInterface
  • MSK_SPP_PaperOut : EppRulbusInterface
  • MSK_SPP_Reserved2 : EppRulbusInterface
  • MSK_SPP_SelectIn : EppRulbusInterface
  • MSK_SPP_SelectPrinter : EppRulbusInterface
  • MSK_SPP_Strobe : EppRulbusInterface
  • MSK_SPP_Unused1 : EppRulbusInterface
  • MSK_SPP_Unused2 : EppRulbusInterface
  • MSK_STSBSY : RB8514_delay, RB8509_Adc12
  • MSK_STSEOC : RB8509_Adc12
  • MSK_STSINT : RB8514_delay
  • MSK_STSINTR : RB8509_Adc12
  • MSK_STSREADY : RB8905_Adc12
  • MSK_STSTRIG : RB8509_Adc12
  • MSK_VALMSN : RB8509_Adc12

- n -

  • name() : RulbusDevice
  • NameList : ConfigParser
  • NeverGetHereException() : NeverGetHereException
  • numberToken : ConfigScanner

- o -

  • oct() : IoFormat
  • OFF_ACR : Via
  • OFF_ADC : RB8905_Adc12
  • OFF_ADCLSB : RB8509_Adc12
  • OFF_BT0 : RB8514_delay
  • OFF_BT1 : RB8514_delay
  • OFF_BT2 : RB8514_delay
  • OFF_CMD : RB9603_monochromator
  • OFF_CONTROL : RB8509_Adc12
  • OFF_CONVERT : RB8509_Adc12
  • OFF_CR : RB8515_clock
  • OFF_CRA : Pia
  • OFF_CRB : Pia
  • OFF_CTL : RB8905_Adc12, RB8514_delay
  • OFF_DDRA : Via, Pia
  • OFF_DDRB : Via, Pia
  • OFF_EPP_ADDR : EppRulbusInterface
  • OFF_EPP_DATA : EppRulbusInterface
  • OFF_FREQ1 : RB9005_amplifier
  • OFF_FREQ2 : RB9005_amplifier
  • OFF_GAIN12 : RB9005_amplifier
  • OFF_GAIN34 : RB9005_amplifier
  • OFF_IER : Via
  • OFF_IFR : Via
  • OFF_LSB : RB8510_Dac12
  • OFF_MSB : RB8510_Dac12
  • OFF_MUL : RB8513_timebase
  • OFF_MUX : RB9005_amplifier
  • OFF_PCR : Via
  • OFF_PDRA : Via, Pia
  • OFF_PDRA_NH : Via
  • OFF_PDRB : Via, Pia
  • OFF_SEL : RB8513_timebase
  • OFF_SPP_CTRL : EppRulbusInterface
  • OFF_SPP_DATA : EppRulbusInterface
  • OFF_SPP_STAT : EppRulbusInterface
  • OFF_SR : RB8515_clock, Via
  • OFF_STATUS : RB8509_Adc12
  • OFF_STS : RB9603_monochromator, RB8905_Adc12, RB8514_delay
  • OFF_T1CH : Via
  • OFF_T1CL : Via
  • OFF_T1LH : Via
  • OFF_T1LL : Via
  • OFF_T2CH : Via
  • OFF_T2CL : Via
  • offsetVoltage() : RB8905_Adc12
  • open() : TheRulbusDeviceList
  • operator *() : RulbusDeviceProxy
  • operator RulbusDevicePtr() : RulbusDeviceProxy
  • operator RulbusDeviceRef() : RulbusDeviceProxy
  • operator()() : IoFormat, isEqual
  • operator->() : RulbusDeviceProxy
  • operator=() : RulbusDeviceProxy, TheRulbusDeviceList, RulbusDevice, RB9603_monochromator, RB9005_amplifier, RB8905_Adc12, RB8515_clock, RB8514_delay, RB8513_timebase, RB8510_Dac12, RB8509_Adc12, RB8506_Sifu, IsaRulbusInterface, EppRulbusInterface, DbcException, Assertion
  • operator==() : DbcException, Assertion

- p -

  • parse() : ConfigParser
  • parseAddress() : ConfigParser
  • parseBipolar() : ConfigParser
  • parseBooleanProperty() : ConfigParser
  • parseCardDeclaration() : ConfigParser
  • parseCardDeclarationSequence() : ConfigParser
  • parseCardInitializer() : ConfigParser
  • ParseError() : ConfigParser::ParseError
  • parseFileAssignment() : ConfigParser
  • parseGenericCard() : ConfigParser
  • parseHasExtTrigger() : ConfigParser
  • parseIntegerProperty() : ConfigParser
  • parseIntrDelay() : ConfigParser
  • parseNumChannels() : ConfigParser
  • parseOptAssignOp() : ConfigParser
  • parseOptDelimiter() : ConfigParser
  • parseOptUnit() : ConfigParser
  • parseProgram() : ConfigParser
  • parseRackAddressAssignment() : ConfigParser
  • parseRackDeclaration() : ConfigParser
  • parseRackDeclarationSequence() : ConfigParser
  • parseRackInitializer() : ConfigParser
  • parseRB8509() : ConfigParser
  • parseRB8510() : ConfigParser
  • parseRB8514() : ConfigParser
  • parseRB8905() : ConfigParser
  • parseRealProperty() : ConfigParser
  • parseVoltPerBit() : ConfigParser
  • Pia() : Pia
  • precision() : IoFormat
  • print() : ConfigErrorToken, ConfigEofToken, ConfigSpecialToken, ConfigStringToken, ConfigNumberToken, ConfigWordToken, ConfigToken
  • printOn() : TheRulbusInterface, TheRulbusDeviceList, RulbusDevice, IsaRulbusInterface, EppRulbusInterface
  • putByte() : TheRulbusInterface, RulbusDevice
  • putCharacter() : RB9603_monochromator
  • putReg() : TheRulbusInterface, IsaRulbusInterface, EppRulbusInterface
  • putString() : RB9603_monochromator

- r -

  • rack() : RulbusDevice
  • rawresult() : RB8509_Adc12
  • RB8506_Pia() : RB8506_Pia
  • RB8506_Sifu() : RB8506_Sifu
  • RB8506_Via() : RB8506_Via
  • RB8509_Adc12() : RB8509_Adc12
  • RB8510_Dac12() : RB8510_Dac12
  • RB8513_timebase() : RB8513_timebase
  • RB8514_delay() : RB8514_delay
  • RB8515_clock() : RB8515_clock
  • RB8905_Adc12() : RB8905_Adc12
  • RB9005_amplifier() : RB9005_amplifier
  • RB9603_monochromator() : RB9603_monochromator
  • read() : RB9603_monochromator
  • readAddress() : EppRulbusInterface
  • readData() : EppRulbusInterface
  • readValue() : RB8905_Adc12
  • readVoltage() : RB8905_Adc12
  • reason() : Assertion
  • remove() : TheRulbusDeviceList
  • RequireException() : RequireException
  • resetInterface() : EppRulbusInterface
  • result() : RB8509_Adc12
  • right() : IoFormat
  • RulbusAddressError() : RulbusAddressError
  • RulbusCloseError() : RulbusCloseError
  • RulbusConfigError() : RulbusConfigError
  • RulbusContextError() : RulbusContextError
  • RulbusDataError() : RulbusDataError
  • RulbusDevice() : RulbusDevice
  • RulbusDeviceFactory() : RulbusDeviceFactory
  • RulbusDeviceProxy() : RulbusDeviceProxy
  • RulbusError() : RulbusError
  • RulbusHandleError() : RulbusHandleError
  • RulbusInterfaceError() : RulbusInterfaceError
  • RulbusInterfaceFactory() : RulbusInterfaceFactory
  • RulbusOpenError() : RulbusOpenError
  • RulbusParseError() : RulbusParseError
  • RulbusRangeError() : RulbusRangeError
  • RulbusScanError() : RulbusScanError
  • RulbusTimeoutError() : RulbusTimeoutError

- s -

  • s : TheRulbusInterface, RulbusDeviceProxy, TheRulbusDeviceList, ConfigKeyword
  • scientific() : IoFormat
  • seechar() : ConfigScanner
  • select_ddra() : Pia
  • select_ddrb() : Pia
  • select_pdra() : Pia
  • select_pdrb() : Pia
  • selectorList : RB8513_timebase
  • setAddr() : RulbusDevice
  • setBipolarMode() : RB8905_Adc12
  • setBufferCapacity() : RB8905_Adc12
  • setBufferCode() : RB8905_Adc12
  • setBufferSize() : RB8905_Adc12
  • setChannel() : RB9005_amplifier, RB8509_Adc12
  • setClockFrequency() : RB8515_clock, RB8514_delay
  • setClockRateMultiplier() : RB8513_timebase
  • setClockRateSelector() : RB8513_timebase
  • setDataPA() : PiaVia
  • setDataPB() : PiaVia
  • setDDRA() : Via, Pia, PiaVia
  • setDDRB() : Via, Pia, PiaVia
  • setDelayCount() : RB8514_delay
  • setDelayTime() : RB8514_delay
  • setDirC2() : Via, Pia
  • setDirCA2() : Via, Pia, PiaVia
  • setDirCB2() : Via, Pia, PiaVia
  • setDirection() : RB8514_delay
  • setDirPA() : PiaVia
  • setDirPB() : PiaVia
  • setEdgeC1() : Via, Pia
  • setEdgeCA1() : Via, Pia, PiaVia
  • setEdgeCB1() : Via, Pia, PiaVia
  • setEnable() : RB8514_delay
  • setEnd12Direction() : RB8514_delay
  • setf() : IoFormat
  • setFastMode() : RB8905_Adc12
  • setGain() : RB9005_amplifier, RB8509_Adc12
  • setGain12() : RB9005_amplifier
  • setGain34() : RB9005_amplifier
  • setInterruptFrequency() : RB8515_clock
  • setIntervalTime() : RB8513_timebase
  • setIntrC1() : Via, Pia
  • setIntrCA1() : Via, Pia, PiaVia
  • setIntrCB1() : Via, Pia, PiaVia
  • setIntrinsicDelayTime() : RB8514_delay
  • setLevelC2() : Via, Pia
  • setLevelCA2() : Via, Pia, PiaVia
  • setLevelCB2() : Via, Pia, PiaVia
  • setLineDir() : PiaVia
  • setLineDirPA() : PiaVia
  • setLineDirPB() : PiaVia
  • setLineLevel() : PiaVia
  • setLineLevelPA() : PiaVia
  • setLineLevelPB() : PiaVia
  • setLowPassFrequency() : RB9005_amplifier
  • setLpf12() : RB9005_amplifier
  • setLpf34() : RB9005_amplifier
  • setNormalMode() : RB8905_Adc12
  • setOutputLineLevel() : RB8506_Sifu
  • setOutputPortData() : RB8506_Sifu
  • setPDRA() : Via, Pia, PiaVia
  • setPDRB() : Via, Pia, PiaVia
  • setPortData() : PiaVia
  • setPortDir() : PiaVia
  • setRack() : RulbusDevice
  • setReadMode() : RB8905_Adc12
  • setSignalDirection() : RB8514_delay
  • setStart12Direction() : RB8514_delay
  • setTriggerEdge() : RB8514_delay
  • setUnipolarMode() : RB8905_Adc12
  • setValue() : RB8510_Dac12
  • setVoltage() : RB8510_Dac12
  • setWavelength() : RB9603_monochromator
  • setWriteMode() : RB8905_Adc12
  • SHL_CA : Via
  • SHL_CB : Via
  • SHL_CHN1 : RB9005_amplifier
  • SHL_CHN2 : RB9005_amplifier
  • SHL_CLKFRQ : RB8515_clock
  • SHL_CTLCHAN : RB8509_Adc12
  • SHL_CTLGAIN : RB8509_Adc12
  • SHL_GAIN1 : RB9005_amplifier
  • SHL_GAIN2 : RB9005_amplifier
  • SHL_GAIN3 : RB9005_amplifier
  • SHL_GAIN4 : RB9005_amplifier
  • SHL_INTFRQ : RB8515_clock
  • SHL_LPF12 : RB9005_amplifier
  • showbase() : IoFormat
  • showplus() : IoFormat
  • showpoint() : IoFormat
  • SHR_BT0 : RB8514_delay
  • SHR_BT1 : RB8514_delay
  • SHR_BT2 : RB8514_delay
  • signalDirection() : RB8514_delay
  • skipWhitespace() : ConfigScanner
  • specialToken : ConfigScanner
  • start12Direction() : RB8514_delay
  • stop() : RB8513_timebase
  • stringTable : ConfigToken
  • stringToken : ConfigScanner
  • swapLines() : RB8506_Sifu
  • swapNibbles() : RB8506_Sifu

- t -

  • t : ConfigParser
  • targetWavelength() : RB9603_monochromator
  • test() : ConfigParser
  • theAddr : RulbusDevice
  • theBase : IsaRulbusInterface, EppRulbusInterface
  • theBipolarFlag : RB8510_Dac12, RB8509_Adc12
  • theBufferCapacity : RB8905_Adc12
  • theBuilder : ConfigParser
  • theCardAddress : ConfigParser
  • theCardLineList : ConfigParser
  • theCardList : ConfigParser
  • theCardName : ConfigParser
  • theCardNameList : ConfigParser
  • theClockFrequency : RB8514_delay
  • theContext : ConfigParser
  • theControlRegister : RB8905_Adc12, RB8514_delay, RB8509_Adc12
  • theCtlByte : RB8515_clock
  • theDelayRegister : RB8514_delay
  • theDescription : DbcException
  • theError : RulbusError
  • theExtTrigInpFlag : RB8509_Adc12
  • theFile : Assertion
  • theFilename : ConfigScanner
  • theFillChar : IoFormat
  • theFlags : IoFormat
  • theFormat : BoundIoFormat
  • theFreq1Register : RB9005_amplifier
  • theFreq2Register : RB9005_amplifier
  • theGain12Register : RB9005_amplifier
  • theGain34Register : RB9005_amplifier
  • theInstance : Singleton
  • theIntrinsicDelayTime : RB8514_delay
  • theIntValue : ConfigToken
  • theJmp3BufferSize : RB8905_Adc12
  • theLine : Assertion
  • theLinenumber : ConfigScanner
  • theList : TheRulbusDeviceList
  • theMaxWL : RB9603_monochromator
  • theMessage : DbcException
  • theMinWL : RB9603_monochromator
  • theMutiplyReg : RB8513_timebase
  • theMuxRegister : RB9005_amplifier
  • theName : RulbusDevice
  • thePrecision : IoFormat
  • thePtr : RulbusDeviceProxy
  • theRack : RulbusDevice
  • theRackAddress : ConfigParser
  • theRackAddrSet : ConfigParser
  • theRackCardList : ConfigParser
  • theRackLine : ConfigParser
  • theRackLineSet : ConfigParser
  • theRackName : ConfigParser
  • theRackNameSet : ConfigParser
  • theRealValue : ConfigToken
  • theReason : Assertion
  • theRegister : RB8510_Dac12
  • theRulbus() : RulbusDevice
  • TheRulbusDeviceList() : TheRulbusDeviceList
  • TheRulbusInterface() : TheRulbusInterface
  • theScanner : ConfigParser
  • theSelectorReg : RB8513_timebase
  • theStream : ConfigPrinter
  • theString : ConfigToken
  • theToken : ConfigParser
  • theTokenCode : ConfigToken
  • theType : DbcException
  • theValue : BoundIoFormat
  • theVoltPerBit : RB8905_Adc12, RB8510_Dac12, RB8509_Adc12
  • theWidth : RulbusDevice, IoFormat
  • tid : RulbusError
  • timeList : RB8513_timebase
  • toBool() : ConfigToken
  • toInt() : ConfigToken
  • TokenCode : ConfigToken
  • tokenString() : ConfigToken
  • toReal() : ConfigToken
  • toString() : ConfigToken
  • transfer() : RulbusDeviceProxy
  • trigger() : RB8514_delay
  • triggerEdge() : RB8514_delay
  • tstInputLineLevel() : RB8506_Sifu
  • Type : DbcException
  • type() : DbcException

- u -

  • unsetf() : IoFormat
  • updateRackCardList() : ConfigParser
  • uppercase() : IoFormat

- v -

  • validBase() : IsaRulbusInterface
  • Value : RB9603_monochromator, RB9005_amplifier, RB8905_Adc12, RB8513_timebase, RB8510_Dac12, RB8509_Adc12
  • value() : RB8510_Dac12, RB8509_Adc12
  • Via() : Via
  • voltage() : RB8510_Dac12, RB8509_Adc12
  • voltageSpan() : RB8905_Adc12
  • voltperbit() : RB8905_Adc12, RB8510_Dac12, RB8509_Adc12

- w -

  • wait() : RB9603_monochromator
  • waitRelais() : RB8905_Adc12
  • what() : RulbusError, DbcException, Assertion
  • width() : RulbusDevice, IoFormat
  • wordToken : ConfigScanner
  • write() : RB9603_monochromator
  • writeAddress() : EppRulbusInterface
  • writeData() : EppRulbusInterface

- ~ -

  • ~Assertion() : Assertion
  • ~ConfigScanner() : ConfigScanner
  • ~DbcException() : DbcException
  • ~Pia() : Pia
  • ~PiaVia() : PiaVia
  • ~RB8506_Sifu() : RB8506_Sifu
  • ~RB8509_Adc12() : RB8509_Adc12
  • ~RB8510_Dac12() : RB8510_Dac12
  • ~RB8513_timebase() : RB8513_timebase
  • ~RB8514_delay() : RB8514_delay
  • ~RB8515_clock() : RB8515_clock
  • ~RB8905_Adc12() : RB8905_Adc12
  • ~RB9005_amplifier() : RB9005_amplifier
  • ~RB9603_monochromator() : RB9603_monochromator
  • ~RulbusDevice() : RulbusDevice
  • ~RulbusDeviceProxy() : RulbusDeviceProxy
  • ~RulbusError() : RulbusError
  • ~TheRulbusDeviceList() : TheRulbusDeviceList
  • ~TheRulbusInterface() : TheRulbusInterface
  • ~Via() : Via
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Namespace Index

Rulbus Device Class Library for Microsoft Windows Namespace List

Here is a list of all documented namespaces with brief descriptions:
Rulbus Namespace Rulbus
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Rulbus Namespace Reference

Rulbus Namespace Reference

Classes

class | AssertException
design-by-contract general assertion. More...

class | Assertion
base for design-by-contract assert exception. More...

class | BoundIoFormat
bind collected formatting information to a value. More...

class | ConfigBuilder
abstract base class for configuration builders. More...

class | ConfigContext
context for ConfigParser (empty). More...

class | ConfigEofToken
token indicating end-of-file. More...

class | ConfigErrorToken
token indicating an unrecognized token (error). More...

struct | ConfigKeyword
table containg token code, token string pairs. More...

class | ConfigListBuilder
Rulbus device list configuration builder. More...

class | ConfigNumberToken
token that reads and represents an integral or floating point number. More...

class | ConfigParser
parse a Rulbus configuration file. More...

class | ConfigParser::ParseError
parser error used internally by ConfigParser. More...

class | ConfigPrinter
Rulbus configuration printer. More...

class | ConfigScanner
scan input and return lexical tokens. More...

class | ConfigSpecialToken
token that reads and represents a special token, like brace and semicolon. More...

class | ConfigStringToken
token that reads and represents a string. More...

class | ConfigToken
abstract base class for concrete tokens, like keywords, numbers, strings. More...

class | ConfigWordToken
token that reads and represents a keyword. More...

class | DbcException
design-by-contract exception. More...

class | EnsureException
design-by-contract postcondition exception. More...

class | EppRulbusInterface
EPP Rulbus Interface. More...

class | IoFormat
formatting manipulator. More...

class | IsaRulbusInterface
ISA Rulbus Interface. More...

struct | isEqual
predicate for apgorithms to compare floating types like Volt, Time and Freq.

class | NeverGetHereException
design-by-contract never reach this location. More...

class | Pia
Pia implementation. More...

class | PiaVia
interface for Pia and Via. More...

class | PportAddresses
Determine if a parallel port base addresses is valid. More...

class | RB8506_Pia
dual parallel interface (Pia). More...

class | RB8506_Sifu
input-output controller box (SIFU). More...

class | RB8506_Via
dual parallel interface (Via). More...

class | RB8509_Adc12
8-channel 12-bit ADC (RB8509). More...

class | RB8510_Dac12
dual 12-bit DAC (RB8510). More...

class | RB8513_timebase
programmable timebase (RB8513). More...

class | RB8514_delay
programmable time delay (RB8514). More...

class | RB8515_clock
clock for delay module RB8514 (RB8515). More...

struct | RB8515_clock::FreqTable
the frequency--code mapping table. More...

class | RB8905_Adc12
high speed 12-bit ADC (BF). More...

class | RB9005_amplifier
. More...

struct | RB9005_amplifier::RegInfo
< type for gain register masks and shifts

class | RB9603_monochromator
. More...

class | RequireException
design-by-contract precondition exception. More...

class | RulbusAddressError
Rulbus addressing error. More...

class | RulbusCloseError
Rulbus device close (remove) error. More...

class | RulbusConfigError
Rulbus configuration file error. More...

class | RulbusContextError
Rulbus context error. More...

class | RulbusDataError
Rulbus data error. More...

class | RulbusDevice
Rulbus device base class, Bridge(151). More...

class | RulbusDeviceFactory
create Rulbus devices from configuration file; may throw RulbusConfigError. More...

class | RulbusDeviceProxy
Rulbus device access-protecting proxy. More...

class | RulbusError
Rulbus errors base class. More...

class | RulbusHandleError
Rulbus device handle error. More...

class | RulbusInterfaceError
Rulbus Interface error. More...

class | RulbusInterfaceFactory
the Rulbus Interface Abstract Factory(87) Singleton(127). More...

class | RulbusOpenError
Rulbus device open error. More...

class | RulbusParseError
configuration file parser error. More...

class | RulbusRangeError
Rulbus parameter range error. More...

class | RulbusScanError
configuration file scanner error. More...

class | RulbusTimeoutError
Rulbus timeout error. More...

class | Singleton
template base class for singleton pattern. More...

class | TheRulbusDeviceList
the Rulbus device list Singleton(127). More...

class | TheRulbusInterface
Rulbus Interface abstract base class. More...

class | Via
Via implementation. More...

Typedefs

typedef Assertion * | AssertionPtr
typedef const Assertion * | AssertionCptr
typedef Assertion & | AssertionRef
typedef const Assertion & | AssertionCref
typedef DbcException * | DbcExceptionPtr
typedef const DbcException * | DbcExceptionCptr
typedef DbcException & | DbcExceptionRef
typedef const DbcException & | DbcExceptionCref
typedef RequireException * | RequireExceptionPtr
typedef const RequireException * | RequireExceptionCptr
typedef RequireException & | RequireExceptionRef
typedef const RequireException & | RequireExceptionCref
typedef EnsureException * | EnsureExceptionPtr
typedef const EnsureException * | EnsureExceptionCptr
typedef EnsureException & | EnsureExceptionRef
typedef const EnsureException & | EnsureExceptionCref
typedef AssertException * | AssertExceptionPtr
typedef const AssertException * | AssertExceptionCptr
typedef AssertException & | AssertExceptionRef
typedef const AssertException & | AssertExceptionCref
typedef NeverGetHereException * | NeverGetHereExceptionPtr
typedef const NeverGetHereException * | NeverGetHereExceptionCptr
typedef NeverGetHereException & | NeverGetHereExceptionRef
typedef const NeverGetHereException & | NeverGetHereExceptionCref
typedef signed char | int8
the compiler's signed 8-bit integral type.

typedef signed char * | int8Ptr
typedef const int8 * | int8Cptr
typedef int8 & | int8Ref
typedef const int8 & | int8Cref
typedef unsigned char | uInt8
the compiler's unsigned 8-bit integral type.

typedef unsigned char * | uInt8Ptr
typedef const uInt8 * | uInt8Cptr
typedef uInt8 & | uInt8Ref
typedef const uInt8 & | uInt8Cref
typedef signed short int | int16
the compiler's signed 16-bit integral type.

typedef signed short int * | int16Ptr
typedef const int16 * | int16Cptr
typedef int16 & | int16Ref
typedef const int16 & | int16Cref
typedef unsigned short int | uInt16
the compiler's unsigned 16-bit integral type.

typedef unsigned short int * | uInt16Ptr
typedef const uInt16 * | uInt16Cptr
typedef uInt16 & | uInt16Ref
typedef const uInt16 & | uInt16Cref
typedef signed int | int32
the compiler's signed 32-bit integral type.

typedef signed int * | int32Ptr
typedef const int32 * | int32Cptr
typedef int32 & | int32Ref
typedef const int32 & | int32Cref
typedef unsigned int | uInt32
the compiler's unsigned 32-bit integral type.

typedef unsigned int * | uInt32Ptr
typedef const uInt32 * | uInt32Cptr
typedef uInt32 & | uInt32Ref
typedef const uInt32 & | uInt32Cref
typedef float | float32
the compiler's 32-bit real type.

typedef float * | float32Ptr
typedef const float32 * | float32Cptr
typedef float32 & | float32Ref
typedef const float32 & | float32Cref
typedef double | float64
the compiler's 64-bit real type.

typedef double * | float64Ptr
typedef const float64 * | float64Cptr
typedef float64 & | float64Ref
typedef const float64 & | float64Cref
typedef uInt8 | Byte
the libraries' byte type.

typedef uInt8 * | BytePtr
typedef const Byte * | ByteCptr
typedef Byte & | ByteRef
typedef const Byte & | ByteCref
typedef uInt16 | Word
the libraries' word (2-Byte) type.

typedef uInt16 * | WordPtr
typedef const Word * | WordCptr
typedef Word & | WordRef
typedef const Word & | WordCref
typedef uInt32 | Quad
the libraries' double word (4-Byte) type.

typedef uInt32 * | QuadPtr
typedef const Quad * | QuadCptr
typedef Quad & | QuadRef
typedef const Quad & | QuadCref
typedef char | Char
the libraries' character type.

typedef char * | CharPtr
typedef const Char * | CharCptr
typedef Char & | CharRef
typedef const Char & | CharCref
typedef int | Int
the libraries' signed integral type.

typedef int * | IntPtr
typedef const Int * | IntCptr
typedef Int & | IntRef
typedef const Int & | IntCref
typedef int16 | Int16
the libraries' 16-bit signed integral type.

typedef int16 * | Int16Ptr
typedef const Int16 * | Int16Cptr
typedef Int16 & | Int16Ref
typedef const Int16 & | Int16Cref
typedef int32 | Int32
the libraries' 32-bit signed integral type.

typedef int32 * | Int32Ptr
typedef const Int32 * | Int32Cptr
typedef Int32 & | Int32Ref
typedef const Int32 & | Int32Cref
typedef double | Real
the libraries' real type.

typedef double * | RealPtr
typedef const Real * | RealCptr
typedef Real & | RealRef
typedef const Real & | RealCref
typedef float32 | Real32
the libraries' 32-bit real type.

typedef float32 * | Real32Ptr
typedef const Real32 * | Real32Cptr
typedef Real32 & | Real32Ref
typedef const Real32 & | Real32Cref
typedef float64 | Real64
the libraries' 64-bit real type.

typedef float64 * | Real64Ptr
typedef const Real64 * | Real64Cptr
typedef Real64 & | Real64Ref
typedef const Real64 & | Real64Cref
typedef std::string | String
the libraries' string type.

typedef std::string * | StringPtr
typedef const String * | StringCptr
typedef String & | StringRef
typedef const String & | StringCref
typedef std::exception | StdException
the std::exception type.

typedef std::exception * | StdExceptionPtr
typedef const StdException * | StdExceptionCptr
typedef StdException & | StdExceptionRef
typedef const StdException & | StdExceptionCref
typedef String | Name
the Rulbus device name type.

typedef String * | NamePtr
typedef const Name * | NameCptr
typedef Name & | NameRef
typedef const Name & | NameCref
typedef Int | Addr
the Rulbus address type.

typedef Int * | AddrPtr
typedef const Addr * | AddrCptr
typedef Addr & | AddrRef
typedef const Addr & | AddrCref
typedef Int | Rack
the Rulbus rack number type.

typedef Int * | RackPtr
typedef const Rack * | RackCptr
typedef Rack & | RackRef
typedef const Rack & | RackCref
typedef Real | Volt
the voltage type.

typedef Real * | VoltPtr
typedef const Volt * | VoltCptr
typedef Volt & | VoltRef
typedef const Volt & | VoltCref
typedef Real32 | Volt32
the 32-bit voltage type.

typedef Real32 * | Volt32Ptr
typedef const Volt32 * | Volt32Cptr
typedef Volt32 & | Volt32Ref
typedef const Volt32 & | Volt32Cref
typedef Real | Time
the time type.

typedef Real * | TimePtr
typedef const Time * | TimeCptr
typedef Time & | TimeRef
typedef const Time & | TimeCref
typedef Real | Freq
the frequency type.

typedef Real * | FreqPtr
typedef const Freq * | FreqCptr
typedef Freq & | FreqRef
typedef const Freq & | FreqCref
typedef Real | Length
typedef Real * | LengthPtr
typedef const Length * | LengthCptr
typedef Length & | LengthRef
typedef const Length & | LengthCref
typedef isEqual< Volt > | isEqualVolt
predicate to compare Volt

typedef isEqual< Time > | isEqualTime
predicate to compare Time

typedef isEqual< Freq > | isEqualFreq
predicate to compare Freq

typedef ConfigBuilder * | ConfigBuilderPtr
typedef const ConfigBuilder * | ConfigBuilderCptr
typedef ConfigBuilder & | ConfigBuilderRef
typedef const ConfigBuilder & | ConfigBuilderCref
typedef ConfigPrinter * | ConfigPrinterPtr
typedef const ConfigPrinter * | ConfigPrinterCptr
typedef ConfigPrinter & | ConfigPrinterRef
typedef const ConfigPrinter & | ConfigPrinterCref
typedef ConfigListBuilder * | ConfigListBuilderPtr
typedef const ConfigListBuilder * | ConfigListBuilderCptr
typedef ConfigListBuilder & | ConfigListBuilderRef
typedef const ConfigListBuilder & | ConfigListBuilderCref
typedef RulbusDevice * | RulbusDevicePtr
typedef const RulbusDevice * | RulbusDeviceCptr
typedef RulbusDevice & | RulbusDeviceRef
typedef const RulbusDevice & | RulbusDeviceCref
typedef RulbusConfigContext * | RulbusConfigContextPtr
typedef const RulbusConfigContext * | RulbusConfigContextCptr
typedef RulbusConfigContext & | RulbusConfigContextRef
typedef const RulbusConfigContext & | RulbusConfigContextCref
typedef ConfigParser * | ConfigParserPtr
typedef const ConfigParser * | ConfigParserCptr
typedef ConfigParser & | ConfigParserRef
typedef const ConfigParser & | ConfigParserCref
typedef ConfigScanner * | ConfigScannerPtr
typedef const ConfigScanner * | ConfigScannerCptr
typedef ConfigScanner & | ConfigScannerRef
typedef const ConfigScanner & | ConfigScannerCref
typedef ConfigContext * | ConfigContextPtr
typedef const ConfigContext * | ConfigContextCptr
typedef ConfigContext & | ConfigContextRef
typedef const ConfigContext & | ConfigContextCref
typedef ConfigToken * | ConfigTokenPtr
typedef const ConfigToken * | ConfigTokenCptr
typedef ConfigToken & | ConfigTokenRef
typedef const ConfigToken & | ConfigTokenCref
typedef EppRulbusInterface * | EppRulbusInterfacePtr
typedef const EppRulbusInterface * | EppRulbusInterfaceCptr
typedef EppRulbusInterface & | EppRulbusInterfaceRef
typedef const EppRulbusInterface & | EppRulbusInterfaceCref
typedef RulbusError * | RulbusErrorPtr
typedef const RulbusError * | RulbusErrorCptr
typedef RulbusError & | RulbusErrorRef
typedef const RulbusError & | RulbusErrorCref
typedef RulbusScanError * | RulbusScanErrorPtr
typedef const RulbusScanError * | RulbusScanErrorCptr
typedef RulbusScanError & | RulbusScanErrorRef
typedef const RulbusScanError & | RulbusScanErrorCref
typedef RulbusParseError * | RulbusParseErrorPtr
typedef const RulbusParseError * | RulbusParseErrorCptr
typedef RulbusParseError & | RulbusParseErrorRef
typedef const RulbusParseError & | RulbusParseErrorCref
typedef RulbusConfigError * | RulbusConfigErrorPtr
typedef const RulbusConfigError * | RulbusConfigErrorCptr
typedef RulbusConfigError & | RulbusConfigErrorRef
typedef const RulbusConfigError & | RulbusConfigErrorCref
typedef RulbusInterfaceError * | RulbusInterfaceErrorPtr
typedef const RulbusInterfaceError * | RulbusInterfaceErrorCptr
typedef RulbusInterfaceError & | RulbusInterfaceErrorRef
typedef const RulbusInterfaceError & | RulbusInterfaceErrorCref
typedef RulbusOpenError * | RulbusOpenErrorPtr
typedef const RulbusOpenError * | RulbusOpenErrorCptr
typedef RulbusOpenError & | RulbusOpenErrorRef
typedef const RulbusOpenError & | RulbusOpenErrorCref
typedef RulbusCloseError * | RulbusCloseErrorPtr
typedef const RulbusCloseError * | RulbusCloseErrorCptr
typedef RulbusCloseError & | RulbusCloseErrorRef
typedef const RulbusCloseError & | RulbusCloseErrorCref
typedef RulbusHandleError * | RulbusHandleErrorPtr
typedef const RulbusHandleError * | RulbusHandleErrorCptr
typedef RulbusHandleError & | RulbusHandleErrorRef
typedef const RulbusHandleError & | RulbusHandleErrorCref
typedef RulbusAddressError * | RulbusAddressErrorPtr
typedef const RulbusAddressError * | RulbusAddressErrorCptr
typedef RulbusAddressError & | RulbusAddressErrorRef
typedef const RulbusAddressError & | RulbusAddressErrorCref
typedef RulbusRangeError * | RulbusRangeErrorPtr
typedef const RulbusRangeError * | RulbusRangeErrorCptr
typedef RulbusRangeError & | RulbusRangeErrorRef
typedef const RulbusRangeError & | RulbusRangeErrorCref
typedef RulbusContextError * | RulbusContextErrorPtr
typedef const RulbusContextError * | RulbusContextErrorCptr
typedef RulbusContextError & | RulbusContextErrorRef
typedef const RulbusContextError & | RulbusContextErrorCref
typedef RulbusTimeoutError * | RulbusTimeoutErrorPtr
typedef const RulbusTimeoutError * | RulbusTimeoutErrorCptr
typedef RulbusTimeoutError & | RulbusTimeoutErrorRef
typedef const RulbusTimeoutError & | RulbusTimeoutErrorCref
typedef IsaRulbusInterface * | IsaRulbusInterfacePtr
typedef const IsaRulbusInterface * | IsaRulbusInterfaceCptr
typedef IsaRulbusInterface & | IsaRulbusInterfaceRef
typedef const IsaRulbusInterface & | IsaRulbusInterfaceCref
typedef Pia * | PiaPtr
typedef const Pia * | PiaCptr
typedef Pia & | PiaRef
typedef const Pia & | PiaCref
typedef Via * | ViaPtr
typedef const Via * | ViaCptr
typedef Via & | ViaRef
typedef const Via & | ViaCref
typedef PiaVia * | PiaViaPtr
typedef const PiaVia * | PiaViaCptr
typedef PiaVia & | PiaViaRef
typedef const PiaVia & | PiaViaCref
typedef RB8506_Pia * | RB8506_PiaPtr
typedef const RB8506_Pia * | RB8506_PiaCptr
typedef RB8506_Pia & | RB8506_PiaRef
typedef const RB8506_Pia & | RB8506_PiaCref
typedef RB8506_Via * | RB8506_ViaPtr
typedef const RB8506_Via * | RB8506_ViaCptr
typedef RB8506_Via & | RB8506_ViaRef
typedef const RB8506_Via & | RB8506_ViaCref
typedef PiaVia | RB8506_PiaVia
typedef PiaVia * | RB8506_PiaViaPtr
typedef const RB8506_PiaVia * | RB8506_PiaViaCptr
typedef RB8506_PiaVia & | RB8506_PiaViaRef
typedef const RB8506_PiaVia & | RB8506_PiaViaCref
typedef RB8506_Sifu * | RB8506_SifuPtr
typedef const RB8506_Sifu * | RB8506_SifuCptr
typedef RB8506_Sifu & | RB8506_SifuRef
typedef const RB8506_Sifu & | RB8506_SifuCref
typedef RB8509_Adc12 * | RB8509_Adc12Ptr
typedef const RB8509_Adc12 * | RB8509_Adc12Cptr
typedef RB8509_Adc12 & | RB8509_Adc12Ref
typedef const RB8509_Adc12 & | RB8509_Adc12Cref
typedef RB8510_Dac12 * | RB8510_Dac12Ptr
typedef const RB8510_Dac12 * | RB8510_Dac12Cptr
typedef RB8510_Dac12 & | RB8510_Dac12Ref
typedef const RB8510_Dac12 & | RB8510_Dac12Cref
typedef RB8513_timebase * | RB8513_timebasePtr
typedef const RB8513_timebase * | RB8513_timebaseCptr
typedef RB8513_timebase & | RB8513_timebaseRef
typedef const RB8513_timebase & | RB8513_timebaseCref
typedef RB8514_delay * | RB8514_delayPtr
typedef const RB8514_delay * | RB8514_delayCptr
typedef RB8514_delay & | RB8514_delayRef
typedef const RB8514_delay & | RB8514_delayCref
typedef RB8515_clock * | RB8515_clockPtr
typedef const RB8515_clock * | RB8515_clockCptr
typedef RB8515_clock & | RB8515_clockRef
typedef const RB8515_clock & | RB8515_clockCref
typedef RB8905_Adc12 * | RB8905_Adc12Ptr
typedef const RB8905_Adc12 * | RB8905_Adc12Cptr
typedef RB8905_Adc12 & | RB8905_Adc12Ref
typedef const RB8905_Adc12 & | RB8905_Adc12Cref
typedef RB9005_amplifier * | RB9005_amplifierPtr
typedef const RB9005_amplifier * | RB9005_amplifierCptr
typedef RB9005_amplifier & | RB9005_amplifierRef
typedef const RB9005_amplifier & | RB9005_amplifierCref
typedef RB9603_monochromator * | RB9603_monochromatorPtr
typedef const RB9603_monochromator * | RB9603_monochromatorCptr
typedef RB9603_monochromator & | RB9603_monochromatorRef
typedef const RB9603_monochromator & | RB9603_monochromatorCref
typedef TheRulbusInterface * | TheRulbusInterfacePtr
typedef const TheRulbusInterface * | TheRulbusInterfaceCptr
typedef TheRulbusInterface & | TheRulbusInterfaceRef
typedef const TheRulbusInterface & | TheRulbusInterfaceCref
typedef RulbusDeviceFactory * | RulbusDeviceFactoryPtr
typedef const RulbusDeviceFactory * | RulbusDeviceFactoryCptr
typedef RulbusDeviceFactory & | RulbusDeviceFactoryRef
typedef const RulbusDeviceFactory & | RulbusDeviceFactoryCref
typedef TheRulbusDeviceList * | TheRulbusDeviceListPtr
typedef const TheRulbusDeviceList * | TheRulbusDeviceListCptr
typedef TheRulbusDeviceList & | TheRulbusDeviceListRef
typedef const TheRulbusDeviceList & | TheRulbusDeviceListCref
typedef std::vector< RulbusDevicePtr > | List
the implementation list type

typedef RulbusDeviceProxy * | RulbusDeviceProxyPtr
typedef const RulbusDeviceProxy * | RulbusDeviceProxyCptr
typedef RulbusDeviceProxy & | RulbusDeviceProxyRef
typedef const RulbusDeviceProxy & | RulbusDeviceProxyCref
typedef RulbusInterfaceFactory * | RulbusInterfaceFactoryPtr
typedef const RulbusInterfaceFactory * | RulbusInterfaceFactoryCptr
typedef RulbusInterfaceFactory & | RulbusInterfaceFactoryRef
typedef const RulbusInterfaceFactory & | RulbusInterfaceFactoryCref

Functions

bool | eq (Real lhs, Real rhs)
true if two Real values are equal.

int | isletter (char chr)
predicate for characters that can start a word.

int | isnumeric (char chr)
predicate for characters that can start a number.

int | isspecial (char chr)
predicate for characters that are special.

int | isquote (char chr)
predicate for characters that can start a string.

int | kwcmp (const void *a, const void *b)
compare the strings of two keyword table entries.

int | backslash (int c)
return character for escape sequence.

String | fmtstring (String s, size_t maxlen)
clip string if necessay, indicate clip with ... .

short | inp (unsigned short port)
read a byte from an input-output port

short | outp (unsigned short port, unsigned char value)
write a byte to an input-output port.

bool | openIO (long base, int len)
open port input-output address range on Windows NT type operating systems using CanIO. CanIO consists of canio.dll and canio.sys. openIO() first dynamically loads canio.dll and then calls AddMultiPort() to provide access to the requested input-output range.

String | to_string (Real x, Int ndec)
convert Real to string, default number of digits 7.

String | to_string_pfx (Int n, Int radix, Int width)
convert long integer to string with radix prefix, default base 10.

String | to_string (long n, Int radix, Int width, Char fillchar)
convert long integer to string without radix prefix, default base 10.

Real | to_real (String aString)
convert String to Real.

Int | to_int (String aString)
convert String to integer.

Int | to_bcd (Int aBinaryValue)
convert binary value to bcd value.

CharCptr | to_cstr (const String &s)
convert String to c-string.

template<typename T> std::ostream & | operator<< (std::ostream &os, const Rulbus::BoundIoFormat< T > &bf)
write <format, value> tuple to output stream.

PiaViaRef | to_rb8506 (RulbusDevicePtr p)
conversion shim; may throw bad_cast.

PiaViaPtr | to_rb8506_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8506_PiaRef | to_rb8506_pia (RulbusDevicePtr p)
conversion shim; may throw bad_cast.

RB8506_PiaPtr | to_rb8506_pia_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8506_ViaRef | to_rb8506_via (RulbusDevicePtr p)
conversion shim; may throw bad_cast.

RB8506_ViaPtr | to_rb8506_via_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8506_SifuRef | to_rb8506_sifu (RulbusDevicePtr p)
conversion shim; may throw bad_cast exception.

RB8506_SifuPtr | to_rb8506_sifu_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8509_Adc12Ref | to_rb8509 (RulbusDevicePtr p)
conversion shim; may throw bad_cast exception.

RB8509_Adc12Ptr | to_rb8509_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8510_Dac12Ref | to_rb8510 (RulbusDevicePtr p)
conversion shim; may throw bad_cast.

RB8510_Dac12Ptr | to_rb8510_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8513_timebaseRef | to_rb8513 (RulbusDevicePtr p)
conversion shim; may throw bad_cast.

RB8513_timebasePtr | to_rb8513_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8514_delayRef | to_rb8514 (RulbusDevicePtr p)
conversion shim; may throw bad_cast exception.

RB8514_delayPtr | to_rb8514_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8515_clockRef | to_rb8515 (RulbusDevicePtr p)
conversion shim; may throw bad_cast.

RB8515_clockPtr | to_rb8515_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB8905_Adc12Ref | to_rb8905 (RulbusDevicePtr p)
conversion shim; may throw bad_cast exception.

RB8905_Adc12Ptr | to_rb8905_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB9005_amplifierRef | to_rb9005 (RulbusDevicePtr p)
conversion shim; may throw bad_cast exception.

RB9005_amplifierPtr | to_rb9005_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RB9603_monochromatorRef | to_rb9603 (RulbusDevicePtr p)
conversion shim; may throw bad_cast exception.

RB9603_monochromatorPtr | to_rb9603_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

RulbusDeviceRef | to_rb (RulbusDevicePtr p)
conversion shim; may throw bad_cast.

RulbusDevicePtr | to_rb_ptr (RulbusDevicePtr p)
conversion shim; may return 0.

template<typename T> T | to (RulbusDeviceProxyRef proxy)
conversion shim.

String | to_string (int n, Int radix=10, Int width=0, Char fillchar= ' ')
convert integer to string without radix prefix, default base 10.

String | to_string2 (Int n)
convert long integer to string, base 2, without radix prefix.

String | to_string8 (Int n)
convert long integer to string, base 8, without radix prefix.

String | to_string16 (Int n)
convert long integer to string, base 16, without radix prefix.

Variables

const int | CTRL_Z = 0x1A
Rulbus::ConfigKeyword kwTable []
table containg token code, token string pairs.

Variable Documentation

struct Rulbus::ConfigKeyword kwTable[] [static]

ConfigScanner uses a ConfigKeyword table to look up the the keywords that can appear in a Rulbus configuration file.

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Module Index

Rulbus Device Class Library for Microsoft Windows Modules

Here is a list of all modules:
  • User Manual
    • Rulbus -- RijksUniversiteit Leiden BUS
    • Defining Interface and Modules
    • Creating a Program
    • Threads and the Rulbus Device Class Library
    • Compilers and the Rulbus Device Class Library
    • Support for the Rulbus Device Library (DLL)
  • Reference Manual
    • RB8506 PIA/VIA
    • RB8506 SIFU
    • RB8509 12-bit ADC
    • RB8510 12-bit DAC
    • RB8513 Timebase
    • RB8514 Time Delay
    • RB8515 Clock for Time Delay
    • RB8905 12-bit ADC
    • RB9005 Instrumentation Amplifier
    • RB9603 Monochromator Controller
    • PIA/VIA
  • Developer Manual
    • Developing a Device Class
    • Style Guide
    • Implementation
      • Common
      • Assertion
      • Rulbus Errors
      • Rulbus Device
      • Rulbus Interface
        • CanIO I/O-port access
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: User Manual

User Manual

Detailed Description

The Rulbus Device Class Library (RDCL) is a Borland C++ library (rulbusdcl.lib) for the Microsoft Windows 95/98/NT/2000/XP platform. It contains classes to use the most popular Rulbus modules and it supports the ISA Rulbus Interface as well as the EPP Rulbus Interface.

Modules

Rulbus -- RijksUniversiteit Leiden BUS
computer-indepedent I/O bus -- modules -- racks -- computer--Rulbus interfaces.

Defining Interface and Modules
computer--Rulbus interface -- module configuration file -- setrulbus utility.

Creating a Program
structure -- compilation -- error handling -- example.

Threads and the Rulbus Device Class Library
multithreading -- example.

Compilers and the Rulbus Device Class Library
Borland C++ -- compiling programs.

Support for the Rulbus Device Library (DLL)
module configuration file -- device list -- example.

Generated on Tue Oct 12 14:11:59 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Rulbus -- RijksUniversiteit Leiden BUS

Rulbus -- RijksUniversiteit Leiden BUS
[User Manual]

I/O bus for peripherals

The Rulbus is a simple input-output bus for peripherals, like an analog to digital converter. It is designed such that peripheral cards have a simple interface to the bus. Also, it is designed such that many microprocessor types can be connected to the Rulbus via a simple Rulbus Interface. Thus a single version of a peripheral card can be used with various types of microprocessors and microcomputer systems. more...

Rulbus Modules or Cards

There are circa 100 different Rulbus modules. Some of the most popular are:

  • parallel interface module for digital input-output, RB8506 with PIA or VIA
  • 12-bit analog to digital converter module, RB8509
  • 12-bit digital to analog converter module, RB8510
  • delay module, RB8514
  • clock module, RB8515

Several properties of a Rulbus module are:

  • the printed-circuit board has Euro-card format
  • the card has a 50-pin Rulbus connector on its rear side that connects to the Rulbus flatcable
  • most cards have input-output connectors on the front side
  • the card is enclosed in a metal case

Rulbus Racks

Based on an application's measurement and control requirements, various Rulbus modules are collected in one or more 14-inch racks. A rack may contain up to 12 single-width (35 mm) modules.

The picture below shows several Rulbus modules in a half-width rack.

Several racks may be chained and then be connected to a computer via a computer--Rulbus interface.

The bus-part of the Rulbus

The Rulbus as a bus is a collection of several lines that make communication between a computer and the various Rulbus cards possible.

The bus consists of the following lines:

  • 8 lines to carry data (one data byte at a time)
  • 8 lines to address a data byte
  • 5 lines for control (enable, read-write, reset, interrupt and a 4 MHz clock signal)
  • many lines for +5 Volt, +15 Volt and -15 Volt power supply

The Rulbus address space is thus 256 bytes (2^8). Two of these addresses are reserved:

  • 0x00 or 0 is reserved to extend the range of available addresses (see further)
  • 0xFF or 255 is reserved for the `bus inactive' state.

There are Rulbus modules that only use one byte of the Rulbus address space, but there are also modules that occupy 32 bytes of the address space of 254 bytes. The address range a module uses, is determined when the module is made: it is programmed in the card's address GAL or PAL (programmable array logic).

Secondary Address

If many modules are used together it may be difficult to assign all modules a proper address range and prevent address conflicts. To overcome this problem, the Rulbus addressing scheme is extended by giving each rack its own address.

When more than one rack is used, each rack must have a unique address. The address of a rack is defined at its rear side via a 4-bit DIP-switch, so that rack addresses fall in the range 0--15.

Address 15 has a special meaning: the rack is always selected or active. In this case it must be the only rack connected to the computer--Rulbus interface.

If a rack has an address in the range 0--14, the rack must be specifically selected by a program before the cards it contains can be accessed. Note that the Rulbus Device Class Library takes care of this.

So with rack addressing, the range of available addresses is extended to 15 times 254, or 3810.

The figure above shows a rack with secondary address 3: binary 0011, 0*2^3 + 0*2^2 + 1*2^1 + 1*2^0 .

Rulbus Interfaces

Nowadays, only two Rulbus Interfaces that connect to a PC are of interest:

  • the ISA Rulbus Interface
  • the EPP Rulbus Interface

The ISA Rulbus Interface is designed for the Industry Standard Architecture (ISA) slots of a PC. New PCs may not include ISA slots anymore, so a new Rulbus Interface was developed: the EPP Rulbus Interface.

The EPP Rulbus Interface is connnected to the parallel port of a computer (PC). For the interface to work, the parallel port must be configured to work in Enhanced Printer Port mode in the PC's BIOS, hence the EPP [IEEE1284].

The Rulbus Device Library supports both Rulbus Interfaces. At default the library assumes that the EPP Rulbus Interface is being used with the parallel port at address 0x378. If this assumption is not valid, the library must be informed what the proper interface type and address are. To this end the RULBUS environment variable can be defined. See section Defining the Interface.

previous top next

Generated on Tue Oct 12 14:12:00 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Defining Interface and Modules

Defining Interface and Modules
[User Manual]

Defining the Interface

The Rulbus Device Library supports the ISA Rulbus Interface as well as the EPP Rulbus Interface. At default the library assumes that the EPP Rulbus Interface is being used with the parallel port at address 0x378. If this assumption is not valid, the library must be informed what the proper interface type and address are. To this end the RULBUS environment variable can be defined as follows, here shown as shell commands:

  • set RULBUS=isa,0x200
  • set RULBUS=epp,0x278

You can add ;nocheck to disable checking if the Rulbus Interface is present (EPP only). See also Setrulbus Utility.

Remember to configure the PC's parallel port to work in Enhanced Printer Port mode in the PC's BIOS, if you use the EPP Rulbus Interface.

Defining the Modules

Programs that use the Rulbus Device Library (RDL), define the Rulbus modules they use via a Rulbus device configuration file. See Support for the Rulbus Device Library (DLL) for more information. The path to the configuration file can be specified via the RULBUS_CONFIG_FILE environment variable. See also Setrulbus Utility below.

Setrulbus Utility

For Windows 95 types of operating system (Windows 95/98/me) the RULBUS and RULBUS_CONFIG_FILE environment variables must be recorded in autoexec.bat by editing it. For Windows NT types of operating system (Windows NT/2000/XP) they must be recorded in the registry, for example via System Properties, Environment.

To make it easy to select the proper Rulbus Interface and to define the path to the Rulbus configuration file on either operating system type, a small GUI program has been made: setrulbus.exe.

Open setrulbus via Start | Rulbus Device Class Library | Tools | Set Rulbus Environment. Program setrulbus is located in the programs subdirectory of the Rulbus Device Class Library installation directory.

previous top next

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Creating a Program

Creating a Program
[User Manual]

Writing a Program

The Rulbus Device Class Library consists of one or more classes for each Rulbus module. These classes are published in C++ header files, one for each Rulbus module, for example rb8510_dac12.h. You normally need to only call methods for the Rulbus modules you want to use (but also see Handling Errors).

Rulbus modules are used according to the pattern: create -- use -- destroy, for example:

#include "rdcl/rb8510_dac12.h"

int main()
{
   Rulbus::RB8510_Dac12 dac( "mydac", ... );    // create device

   dac.setVoltage( ... );                       // use it
   ...                                          //    even more

   //
   // dac goes out of scope here; it is destroyed automatically
   //
}

Note that the classes reside in the namespace Rulbus.

Besides the Rulbus module related classes, there are general Rulbus device methods. The latter are part of class RulbusDevice. Class names appear in the following forms:

  • RByydd_... -- specific Rulbus module related classes, like RB8510_Dac12
  • RulbusDevice -- general Rulbus device methods, like RulbusDevice::printInterface()

Another way to create and use Rulbus devices is presented in Support for the Rulbus Device Library (DLL).

Compiling the Program

In the following command, {include-path} specifies the directory with the header files and {library-path} specifies the directory with rulbusdcl-omf-static.lib and winutils-omf-static.lib.

To create the program, compile as follows:

C:\>bcc32 -tWM -I(include-path) -L{library-path} {program}.cpp  \
               rulbusdcl-omf-static.lib winutils-omf-static.lib

Option -tWM specifies that the program must be linked with the multi-threaded C runtime library.

Handling Errors

All classes in the Rulbus Device Class Library use the same error handling pattern: they throw an exception when something is not in order. Exceptions may be divided into:

  1. environmental or usage related errors, for example RulbusOpenError
  2. programming or design-by-contract errors, for example RequireException
  3. system errors, for example bad_alloc exception for out-of-memory

A properly written program should always catch the exceptions that may arise to see if the method calls where successful and it should act accordingly. Failing to do so may crudely abort the program giving an "Abnormal program termination" message.

When an error occurred, a string explaining the error condition may be obtained from the exception with method what(). The exception can also be printed on a stream as in the following example.

#include <iostream>             // for std::cerr
#include "rdcl/rb8510_dac12.h"  // for class RB8510_Dac12

int main()
{
   try
   {
      /*
       * create a dac at an invalid Rulbus address (0x123),
       * an environmental error:
       */

      Rulbus::RB8510_Dac12 dac( "mydac", 0x123, 7 );

      // ...
   }
   catch ( const std::exception& e )
   {
      std::cerr << e;
   }
}

The program gives:

Rulbus: cannot open rulbus device 'mydac' at [7:0x123]

For more information on design-by-contract, see [DBC]

Typenames

Several fundamental types and std namespace classes and all classes of this library are made available with standardized names for (const) pointer types and (const) reference types.

typedef       type   Type;
typedef       type*  TypePtr;
typedef const type*  TypeCptr;
typedef       type&  TypeRef;
typedef const type&  TypeCref;

The following compiler dependent types are defined:

int8, uInt8
int16, uInt16
int32, uInt32
float32, float64

The following fundamental library types are defined:

DECLARE_TYPE( uInt8  , Byte   );
DECLARE_TYPE( uInt16 , Word   );
DECLARE_TYPE( uInt32 , Quad   );

DECLARE_TYPE( char   , Char   );
DECLARE_TYPE( int    , Int    );
DECLARE_TYPE( int16  , Int16  );
DECLARE_TYPE( int32  , Int32  );
DECLARE_TYPE( double , Real   );
DECLARE_TYPE( float32, Real32 );
DECLARE_TYPE( float64, Real64 );

The following convenience types are defined:

DECLARE_TYPE( std::string   , String );
DECLARE_TYPE( std::exception, StdException );

For each class 'myClass', the following types are defined via macro DECLARE_CLASS():

class myClass;
typedef       myClass* myClassPtr;
typedef const myClass* myClassCptr;
typedef       myClass& myClassRef;
typedef const myClass& myClassCref;

Complete Example

The following example program creates (opens) a DAC, generates a staircase voltage and destroys (closes) the DAC again.

/*
 * dac.cpp - generate a staircase voltage.
 *
 * Compile: bcc32 -tWM dac.cpp rulbusdcl-omf-static.lib winutils-omf-static.lib
 */

#include <iostream>             // for std::cout etc.
#include <cstdlib>              // for std::strtol()
#include <windows.h>            // for Sleep()
#include "rdcl/rb8510_dac12.h"  // header

static int usage();             // print program usage, return EXIT_FAILURE

/*
 * main - handle commandline arguments and generate staircase voltage on DAC.
 */

int main( int argc, char *argv[] )
{
   try
   {
      /*
       * handle commandline arguments:
       */

      if ( argc < 4 )
         return usage();

      /*
       * for rack and Rulbus address, let strtol() determine the radix of the input:
       *   octal for 012, decimal for 12, hexadecimal for 0x12.
       */

      char *name = argv[1];
      int   rack = std::strtol( argv[2], 0, 0 );
      int   addr = std::strtol( argv[3], 0, 0 );

      const int   bipolar = 1;                // bipolar
      const float vpb     = 5e-3;             // volt-per-bit

      /*
       * create the DAC:
       */

      Rulbus::RB8510_Dac12 dac( name, addr, rack, bipolar, vpb );

      /*
       * generate 11 one volt steps, one per second:
       *
       * Note that the last step generates a RulbusRangeError, because the
       * voltage is outside [-10.235 .. +10.24 V].
       */

      for ( int i = 0; i <= 11; i++ )
      {
         std::cout << '[' << i << ']';

         dac.setVoltage( i );

         Sleep( 1000 );                    // delay one second
      }

      /*
       * dac goes out of scope and is destroyed:
       */
   }
   catch ( const std::exception& e )
   {
      std::cout << std::endl << e << std::endl;
   }

   return EXIT_SUCCESS;
}

/*
 * usage - print program usage.
 */

static int usage()
{
   std::cout << "Usage: dac device-name rulbus-rack rulbus-address" << std::endl;
   return EXIT_FAILURE;
}

previous top next

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Threads and the Rulbus Device Class Library

Threads and the Rulbus Device Class Library
[User Manual]

Multithreading

Because the Rulbus Device Class Library is used on a multitasking--multithreading operating system, attention must be given to the effects this may have. For example, it should not be possible that in one thread a Rulbus device just selected its rack, followed by a second device in another thread setting one of its registers, assuming that its rack still is selected.

The Rulbus Device Class Library enforces the following:

  • selecting a rack and reading a byte from or writing a byte to the Rulbus is serialized

Serialized means that an operation is completed before it will be performed again. To this end semaphores are used.

Access to the Rulbus devices is not protected, so programs must adhere to the following rule:

  • a specific Rulbus device may only be used from one single thread

It is allowed to create a Rulbus device in one thread (process) and use it from another thread (process).

Example

The following program example shows the use of three threads, two of which control their own DAC. One thread generates a square wave voltage, the other thread generates a sawtooth voltage. Error handling has been omitted for clarity.

/*
 * threads.cpp - use Rulbus Device Library from three threads.
 *
 * Compile: bcc32 -tWM threads.cpp rulbusdcl-omf-static.lib winutils-omf-static.lib
 */

#include <conio.h>                      // for kbhit()
#include <cstring>                      // for std::stricmp()
#include <iostream>                     // for std::cout
#include <windows.h>                    // for DWORD HANDLE, Sleep()

#include "rdcl/rb8510_dac12.h"          // for class RB8510_Dac12 etc.
#include "rdcl/RulbusInterface.h"       // for class TheRulbusInterface etc.

const char *title = "Threads  1.0  use Rulbus DLL from three threads.\n";

enum { E_OK, E_OPT, E_ARG, };           // program return codes

static int           threads   ( );
static HANDLE        mkThread  ( const char *msg, DWORD WINAPI (*ThreadFunc)(LPVOID), Rulbus::RB8510_Dac12Ptr pDac );
static DWORD  WINAPI SquareWave( LPVOID arg );
static DWORD  WINAPI SawTooth  ( LPVOID arg );

/*
 * main - the program.
 */

int main( int argc, char *argv[] )
{
   std::cout << title << std::endl;

   return threads();
}

/*
 * threads - create a separate thread for each of two DAC channels
 *           and generate a square wave and a sawtooth.
 *
 *      100% |--    --    --
 *           |  |  |  |  |  |
 *       50% |   --    --
 *           | /| /| /| /| /
 *        0% |/_|/_|/_|/_|/___
 */

static volatile int runthread = 1;

static int threads()
{
   Rulbus::TheRulbusInterface::instance().printOn( std::cout );

   std::cout << "\nGenerating waveforms on DAC channels 0 & 1.\n";

   /*
    * open two DACs:
    */

   const int    rack = 0, adr0 = 0xD0, adr1 = 0xD2;
   const int bipolar = 1; const float  vpb  = 5e-3;

   Rulbus::RB8510_Dac12 dac0( "dac-0", adr0, rack, bipolar, vpb );
   Rulbus::RB8510_Dac12 dac1( "dac-1", adr1, rack, bipolar, vpb );

   /*
    * create and resume threads:
    */

   HANDLE thread0 = mkThread( "DAC channel-0", SquareWave, &dac0 );
   HANDLE thread1 = mkThread( "DAC channel-1", SawTooth  , &dac1 );

   std::cout << "\n\nPress a key to stop...\n\n";

   ResumeThread( thread0 );
   ResumeThread( thread1 );

   /*
    * wait for key pressed; eat character:
    */

   while (!kbhit() )
     Sleep( 10 );

   (void) getch();

   /*
    *  stop and remove threads and close DACs:
    */

   runthread = 0; Sleep( 10 );

   CloseHandle( thread0 );
   CloseHandle( thread1 );

   return E_OK;
}

/*
 * mkThread - create a thread.
 */

static HANDLE mkThread( const char *msg, DWORD WINAPI (*ThreadFunc)(LPVOID), Rulbus::RB8510_Dac12Ptr pDac )
{
   std::cout << "\ncreating thread for " << msg;

   DWORD id;

   return CreateThread(
      NULL,             // pointer to thread security attributes
      0,                // initial thread stack size, in bytes
      ThreadFunc,       // pointer to thread function
      pDac,             // argument for new thread
      CREATE_SUSPENDED, // creation flags
      &id               // pointer to returned thread identifier
   );
}

/*
 * SquareWave - generate a square wave voltage.
 */

static DWORD WINAPI SquareWave( LPVOID arg )
{
   Rulbus::RB8510_Dac12Ref dac = *reinterpret_cast<Rulbus::RB8510_Dac12Ptr>( arg );

   std::cout << "thread function: squarewave on "; dac.printOn( std::cout );

   while ( runthread )
   {
      dac.setValue( 2048 ); Sleep(50);
      dac.setValue( 4095 ); Sleep(50);
   }

   return 0;
}

/*
 * SawTooth - generate a sawtooth voltage.
 */

static DWORD WINAPI SawTooth( LPVOID arg )
{
   Rulbus::RB8510_Dac12Ref dac = *reinterpret_cast<Rulbus::RB8510_Dac12Ptr>( arg );

   std::cout << "thread function: sawtooth on "; dac.printOn( std::cout );

   while ( runthread )
   {
      for( int n = 0; n <= 2047; n = (n + 50) % 2048 )
      {
         dac.setValue( n ); Sleep(1);
      }
   }

   return 0;
}

/*
 * End of file
 */

previous top next

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Compilers and the Rulbus Device Class Library

Compilers and the Rulbus Device Class Library
[User Manual]

This section describes some implementation details, that nonetheless may be important if you want to use the library with another compiler than Borland C++.

Compiler

The Rulbus Device Class Library (RDCL) has been developed together with the Rulbus LabVIEW Library (RLL) and the the Rulbus Device Library (RDL).

RDL and RDCL have been developed with Borland C++ 5.6.
Some reasons to use Borland C++ are:

  • it is a 32-bit Windows native compiler that supports the creation of DLLs well
  • it supports standard C++ exception handling

See section "Compilers and the Rulbus Device Library" of the Rulbus Device Library manual for more information on the implications of this choice.

Compiling programs with Borland C++

Here, {include-path} specifies the directory with the header files and {library-path} specifies the directory with rulbusdcl-omf-static.lib and winutils-omf-static.lib.

bcc32 -tWM -I(include-path) -L{library-path} {program}.cpp  \
           rulbusdcl-omf-static.lib winutils-omf-static.lib

Option -tWM specifies that the program must be linked with the multi-threaded C runtime library.

previous top next

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Support for the Rulbus Device Library (DLL)

Support for the Rulbus Device Library (DLL)
[User Manual]

Defining the Modules

In the Rulbus Device Library (RDL) DLL, Rulbus device objects are handled a bit differently from the devices in the Rulbus Device Class Library (RDCL).

Reasons for this are:

  • a C-language interface is required for the DLL (no access to classes)
  • it enables sharing of Rulbus device objects among different threads of the same process

To meet these requirements, the Rulbus device objects are created from a description in a configuration file and are accessed via a handle (number).

Here is a small Rulbus device configuration file.

# rulbus-small.conf - example rulbus device configuration file.

rack "top"
{
    address = 0

    rb8509_adc12 "adc"
    rb8510_dac12 "dac-ch0" { address = 0xD0 }
    rb8510_dac12 "dac-ch1" { address = 0xD2; bipolar = false; volt_per_bit = 1.25m }
}

rack "bottom"
{
   address = 1

   // still empty
}

And here is a longer configuration file.

The configuration file defines racks that contain modules (cards). Besides card declarations, a rack declaration usually contains an address specification (See secondary address).

Card Declarations

The card declarations specify the type of the card and the name by which it is referenced from the program. All card types can specify the address property and several card types can specify other properties, like bipolar for card type rb8510_dac12. The available properties and their default values are given in the section Default configuration in the Rulbus Device Library Reference manual for the various card types.

Note 1. The Rulbus Interface cannot be specified in the Rulbus device configuration file. The rationale behind this is, that the Rulbus Interface is related to the computer, whereas the items in the Rulbus device configuration file are related to the application. When a PC is replaced by another one, the application and the Rulbus device configuration file should move to the new computer, but not the Rulbus Interface specification.

Note 2. Because of the way DLLs use memory, the following applies:

  • Rulbus devices can be shared among different threads of the same process
  • Rulbus devices cannot be shared among different processes, although different Rulbus devices can be used from different processes

Which Configuration File

The path of the configuration file to read is determined as follows:

  1. contents of environment variable RULBUS_CONFIG_FILE, or
  2. file .\rulbus.conf (current directory), or
  3. file C:\etc\rulbus.conf

You can set the environment variable RULBUS_CONFIG_FILE in a command shell temporarily as follows (see also Setrulbus Utility):

  • set RULBUS_CONFIG_FILE=M:\myexperiment\etc\rulbus.conf

Device List

To make it possible to access Rulbus device objects that live in the Rulbus Device Library DLL from an application, a handle (number) is used in application software to refer to the actual device object.

The handle--device object relation is maintained by a list: TheRulbusDeviceList. An application obtains the handle to a device by opening the device by its name as given in the Rulbus configuration file.

The Rulbus device objects are accessed via the list in such a way, that they are protected from simultaneous access from different threads or processes (see RulbusDeviceProxy).

Example

The following code excerpts give an example of how DLL interface functions would use the classes from the Rulbus Device Class Library (RDCL).

// DLL

using namespace Rulbus;

int open_card( const char* name )
{
   return TheRulbusDeviceList::instance().open( name );
}

void close_card( handle )
{
   TheRulbusDeviceList::instance().close( handle );
}

int setVoltage( int handle, double voltage )
{
   to_rb8510( TheRulbusDeviceList::instance().get( handle ) ).setVoltage( voltage );
}

Functions open_card(), close_card() and setVoltage() are functions that are exported by the DLL.

// application

int main()
{
   int handle = open_card( "dac-ch0" );

   setVoltage( handle, 1.25 );

   close_card( handle );
}

It is assumed that the Rulbus devices are created and put on the list when the DLL is loaded (see RulbusDeviceFactory).

previous top next

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Reference Manual

Reference Manual

Detailed Description

The Rulbus Device Class Library contains two groups of classes:
  • Rulbus module related classes, for example RB8510_Dac12
  • classes related to the implementation of the library, see implementation

When you want to use a specific Rulbus module, look up its documentation page by Rulbus number in the Contents pane at the left, for example Modules | Reference Manual | RB8510 12-bit DAC for the dual 12-bit DAC and read the documentation for the module and its class(es).

Modules

RB8506 PIA/VIA
dual parallel interface (PIA/VIA).

RB8506 SIFU
sense interrupt flag unit (BF).

RB8509 12-bit ADC
8-channel 12-bit ADC (RB8509).

RB8510 12-bit DAC
dual 12-bit DAC (RB8510).

RB8513 Timebase
programmable timebase.

RB8514 Time Delay
programmable time delay.

RB8515 Clock for Time Delay
clock for delay module RB8514.

RB8905 12-bit ADC
high speed 12-bit ADC (BF).

RB9005 Instrumentation Amplifier
programmable instrumentation amplifier for RB8905 12-bit ADC (BF).

RB9603 Monochromator Controller
monochromator controller (BF).

PIA/VIA
PIA/VIA base for RB8506 and Sifu.

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8506 PIA/VIA

RB8506 PIA/VIA
[Reference Manual]

Detailed Description

Purpose

Provide digital inputs and outputs.

Description

Module RB8506 is a (dual) parallel interface. Internally the module may contain Motorola Peripheral Interface Adapter MC6821 (Pia) ICs or Rockwell Versatile Interface Adapater R6522 (Via) ICs or a combination of both.

The following variations of this module are known to exist:

  • dual with two Pia's
  • dual with a Pia and a Via
  • dual with two Via's
  • single Pia (small front)

You should create a separate object for each Pia/Via in a Parallel Interface module.

The Parallel Interface front-panels look as follows.

                       dual               single

    +----------------------+             +-----------+
    |  Parallel Interface  |             |  Parallel |
    |                      |             | Interface |
    |  Pia 1     Pia 2     |             |           |
    |         pb0    pb4   |             |     pb0   |
    |   ==    (o)    (o)   |             |     (o)   |
    |  |..|   pb1    pb5   |             |     pb1   |
    |  |..|   (o)    (o)   |             |     (o)   |
    |  |..|   pb2    pb6   |             |  P  pb2   |
    |  |..|   (o)    (o)   |             |  I  (o)   |
    |  |..|   pb3    pb7   |             |  A  pb3   |
    |  |..|   (o)    (o)   |             |  2  (o)   |
    |   ==    cb1    cb2   |             |     cb1   |
    |         (o)    (o)   |             |     (o)   |
    |                      |             |           |
    |  RULBUS              |             |    RULBUS |
    +----------------------+             +-----------+

PIA and VIA offer the following interface pins.

    port       pin   direction  description
       A  PA0..PA7      i/o     level inputs and outputs
       A       CA1     input    active edge transition sets interrupt flag
       A       CA2      i/o     complex operation
       B  PB0..PB7      i/o     level inputs and outputs
       B       CB1     input    active edge transition sets interrupt flag
       B       CB2      i/o     complex operation

See Pia and Via for a more detailed description of the IC's capabilities.

The 50-pin connector for Pia 1 makes all its pins of Port A and Port B available. Of Pia 2, the BNC-connectors provide access to only Port B pins.

A Pia parallel interface is created using class Rulbus::RB8506_Pia. A Via parallel interface is created using class Rulbus::RB8506_Via.

See pport.cpp for an example program. It contains several bit-manipulation functions.

For more informations on the available methods, see class Rulbus::PiaVia.

Classes

class | RB8506_Pia
dual parallel interface (Pia). More...

class | RB8506_Via
dual parallel interface (Via). More...

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8506 SIFU

RB8506 SIFU
[Reference Manual]

Detailed Description

Purpose

Provide digital inputs and outputs.

Description

Module RB8506, SIFU variant, is a digital input-output interface. It has four level-sensitive inputs, four negative-edge-sensitive inputs, four level outputs and four outputs that can be pulsed as a group.

There is also a provision to check if any of both the negative-edge-sensitive inputs and the level-sensitive inputs have changed state since it was last checked.

Inputs and outputs are available in TTL and in CMOS: TTL or CMOS can be selected with a switch on the front, two inputs or two outputs at the time. A LED indicates if TLL (red) or CMOS (green) is selected.

The SIFU module consists of a PIA parallel interface (see Pia) and a Sense Interrupt Flag Unit (SIFU) board.

The module's front-panel looks as follows.

     +-------------------------------------------------+
     |             I/O CONTROLLER BOX                  |
     |                      Input                      |
     |         5    puls   4      1   level   0        |
     |               C                  A              |
     |        (O)   (X)   (O)    (O)   (X)   (O)       |
     |  M                                              |
     |  O      o   o   o   o      o   o   o   o        |
     |  N      7           6      3           2        |
     |  O            D                  B              |
     |  C     (O)   (X)   (O)    (O)   (X)   (O)       |
     |  H                                              |
     |  R      H   G    F   E    D   C    B   A  CMOS  |
     |  O      %   %    %   %    %   %    %   %        |
     |  M                                        TTL   |
     |  A                                              |
     |  T     (O)   (X)   (O)    (O)   (X)   (O)       |
     |  O            G                  E              |
     |  R      5           4      1           0        |
     |         o   o   o   o      o   o   o   o        |
     |  C      7           6      3           2        |
     |  A                                              |
     |  B     (O)   (X)   (O)    (O)   (X)   (O)       |
     |  L            H                  F              |
     |  E      7    puls   6      3   level   2        |
     |                      Output                     |
     |                                                 |
     |   RULBUS                                        |
     +-------------------------------------------------+

     (O) BNC connector  ·  (X) red-green LED  · o mini plug  ·  % switch

Classes

class RB8506_Sifu
input-output controller box (SIFU). More...

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8509 12-bit ADC

RB8509 12-bit ADC
[Reference Manual]

Detailed Description

Purpose

Measure a voltage.

Description

Module RB8509 is a 8-channel 12-bit analog to digital converter (ADC).

The module has eight analog inputs and a trigger input to start a data acquisition. A data acquisition can also be started by a software trigger.

Module RB8509 contains the following parts:

  • a channel selector to select one of the eight inputs [ch0..ch7]
  • a gain selector to select one of the four gains [1, 2, 4, 8]
  • a 12-bit data Analog to Digital Converter

At production time, the ADC is configured for unipolar or bipolar operation and its input voltage range is defined as 10 or 20V.

The following variations of this module are known to exist:

  • 8-channel input, no external trigger input
  • 4-channel input,

The module's front-panels look as follows.

                  8-channel               4-channel

    +----------------------+             +-----------+
    | A/D Converter 12-bit |             | 12-bit ADC|
    |                      |             |           |
    |    Adc 0     Adc 4   |             |           |
    |     (o) x     (o) x  |             |           |
    |                      |             | ch0 (o)   |
    |    Adc 1     Adc 5   |             |           |
    |     (o) x     (o) x  |             | ch1 (o)   |
    |                      |             |           |
    |    Adc 2     Adc 6   |             | ch2 (o)   |
    |     (o) x     (o) x  |             |           |
    |                      |             | ch3 (o)   |
    |    Adc 3     Adc 7   |             |           |
    |     (o) x     (o) x  |             | trg (o)   |
    |                      |             |           |
    |  RULBUS              |             |    RULBUS |
    +----------------------+             +-----------+

Classes

class RB8509_Adc12
8-channel 12-bit ADC (RB8509). More...

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8510 12-bit DAC

RB8510 12-bit DAC
[Reference Manual]

Detailed Description

Purpose

Generate a unipolar or bipolar voltage.

Description

Module RB8510 is a dual 12-bit Digital to Analog Converter. It contains two 12-bit Digital to Analog Converters (DACs), each connecting to a BNC connector on the front panel. There are no inputs.

At production time, each DAC is configured for unipolar or bipolar operation and its output voltage range is defined as 5, 10 or 20V.

The module's front-panel looks as follows.

     +-----------+
     | CONVERTER |
     |   12-bit  |
     |           |
     |    dac1   |
     |     (o)   |
     |           |
     |           |
     |           |
     |           |
     |    dac0   |
     |     (o)   |
     |           |
     |           |
     |           |
     |    RULBUS |
     +-----------+

Classes

class RB8510_Dac12
dual 12-bit DAC (RB8510). More...

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8513 Timebase

RB8513 Timebase
[Reference Manual]

Detailed Description

Purpose

Generate short pulses with a programmable interval time.

Description

Module RB8513 is a clock signal generator with a programmable interval time. It has a TTL trigger input and a TTL clock output.

The module can generate a clock signal with the following programmable interval times.

    Programmable interval times
   --------------------------------
     50 ns
    100 ns
    200 ns
    500 ns
      1 us -  99   us, step   1 us
    100 us -   9.9 ms, step 100 us
     10 ms - 990   ms, step  10 ms

The module's front-panel looks as follows.

     +-----------+
     |TIME BASE  |
     |prog 50n-1s|
     |    output |
     |     (o)   |
     |     TTL   |
     |           |
     |           |
     |           |
     |           |
     |    input  |
     |     (o)   |
     |     TTL   |
     |           |
     |    RULBUS |
     +-----------+

Classes

class RB8513_timebase
programmable timebase (RB8513). More...

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8514 Time Delay

RB8514 Time Delay
[Reference Manual]

Detailed Description

Purpose

Generate a programmable time delay.

Description

Module RB8515 is a programmable delay time generator.

It has a clock input, a trigger input, two delay outputs, a gate and a gate-not output, and a Rulbus interrupt output.

The module's front-panel looks as follows.

     +-----------+
     |   DELAY   |
     |           |
     |           |
     |           |
     |  (o) CLOCK|
     |  (o) TRIG |
     |  (o) OUT1 |
     |  (o) OUT2 |
     |  (o) GATE |
     |  (o)/GATE |
     |           |
     |           |
     |           |
     |    RULBUS |
     +-----------+

Classes

class RB8514_delay
programmable time delay (RB8514). More...

Generated on Tue Oct 12 14:12:01 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8515 Clock for Time Delay

RB8515 Clock for Time Delay
[Reference Manual]

Detailed Description

Purpose

Generate a clock signal for the time delay module RB8514.

Description

Module RB8515 is a clock signal generator for time delay module RB8514.

It provides fixed frequency outputs, clock outputs with programmable frequency and a Rulbus interrupt output with programmable frequency via SMB connectors on the front panel. There are no inputs.

The following front-panel variations of this module exist:

  • seven identical outputs with programmable frequency
  • four different fixed-frequency output and three identical outputs with programmable frequency

The module's front-panels look as follows.

   fixed & programmable     programmable only
     +-----------+            +-----------+
     |   CLOCK   |            |   CLOCK   |
     |           |            |           |
     |           |            |           |
     |   (o) 100M|            |   (o)     |
     |   (o) 10M |            |   (o)     |
     |   (o) 1M  |            |   (o)     |
     |   (o) 100k|            |   (o)     |
     |SELECTABLE |            |   (o)     |
     |   (o)     |            |   (o)     |
     |   (o)     |            |   (o)     |
     |   (o)     |            |           |
     |           |            |           |
     |           |            |           |
     |    RULBUS |            |    RULBUS |
     +-----------+            +-----------+

Classes

class RB8515_clock
clock for delay module RB8514 (RB8515). More...

Generated on Tue Oct 12 14:12:02 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB8905 12-bit ADC

RB8905 12-bit ADC
[Reference Manual]

Detailed Description

Purpose

Measure a voltage trace.

Description

Module RB8905 is a 1 Mega-sample per second 12-bit analog to digital converter with a 32 kByte on-board data buffer.

The module has a single analog input and a clock input to do a series of data acquisitions. The number of samples to store on-board is programmable.

Module RB8905 contains the following parts:

  • a track and hold
  • a 12-bit ADC
  • an address counter
  • a 32 kByte on-board data buffer

The ADC can be programmed for bipolar or unipolar use. The input voltage span of the ADC is configured at production time for 10 V or 20 V.

The module's front-panels look as follows.

     +-----------+                +-----------+
     |   ADC12HS |                |   ADC12HS |
     |           |                |           |
     |     clock |                |     clock |
     |      (o)  |                |      (o)  |
     |           |                |           |
     |           |                |           |
     |           |                |     bit07 |
     |           |                |      (o)  |
     |           |                |           |
     |           |                |           |
     |     input |                |     input |
     |      (o)  |                |      (o)  |
     |           |                |           |
     |    RULBUS |                |    RULBUS |
     +-----------+                +-----------+

Note that bit07 on the right front-panel provides the signal that indicates the end of a series of data acquisitions, or that indicates that all samples have been read, when reading.

Classes

class RB8905_Adc12
high speed 12-bit ADC (BF). More...

Generated on Tue Oct 12 14:12:02 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB9005 Instrumentation Amplifier

RB9005 Instrumentation Amplifier
[Reference Manual]

Detailed Description

Purpose

Provide programmable amplifiers and filters to form a data-acquisition system with the high speed 12-bit ADC RB8905.

Description

Module RB9005 is a 4-channel programmable amplifier-filter module.

The module's front-panel looks as follows.

    +----------------------+
    |     Programable      |
    |  Differential Amp.   |
    |   +input1   input3   |
    |     (o)       (o)    |
    |                      |
    |   -input1   input4   |
    |     (o)       (o)    |
    |                      |
    |   +input2    ouput   |
    |     (o)       (o)    |
    |              clock   |
    |   -input2   in o1 o2 |
    |     (o)    (o)(o)(o) |
    |                      |
    |  RULBUS              |
    +----------------------+

It has two differential programmable amplifiers followed by a programmable filter, two unbalanced input (single-ended) programmable amplifiers and an ouput multiplexer to present one, two, three or all four inputs in sequence.

            1-1-1-1   ·   2-1-2-1   ·   3-2-1-3   ·   4-3-2-1

Further the module has a clock input and two clock outputs that can be programmed to duplicate the clock input or to follow an alternating sequence so that out1 presents a clock signal for the odd channels and out2 presents a clock signal for the even channels in the selected channel sequence. (Apparently this is not very useful for the 3-2-1-3 sequence where channel 3 appears at odd and even positions in the sequence.)

             Amplifiers       Low Pass Filters        Multiplexer

             _                                       .------------.
   in1+ o---| = _               .------.             |            |
            |G1 _>--------------| LPF1 |-------------| Ch1        |
   in1- o---|_=                 `------'             |            |
              |                     |                |            |
              |   _                 |                |            |
   in2+ o--------| = _              | .------.       |            |
              |  |G2 _>---------------| LPF2 |-------| Ch2        |---o output
   in2- o--------|_=                | `------'       |            |
              |    |                |    |           |            |
              |    |   _            |    |           |            |
              |    |  | = _         |    |           |            |
   in3+ o-------------|G3 _>-------------------------| Ch3        |
              |    |  |_=           |    |           |       .----|     Clock
              |    |    |           |    |           |       |    |
              |    |    |   _       |    |           |       |    |-<-o input
              |    |    |  | = _    |    |           |       |    |
   in4+ o------------------|G4 _>--------------------| Ch4   |    |->-o out1
              |    |    |  |_=      |    |           |-------'    |
              |    |    |    |      |    |           |            |->-o out2
              |    |    |    |      |    |           `------------'
              |    |    |    |      |    |              |   |   |
              ^    ^    ^    ^      ^    ^              ^   |   ^
              G1   G2   G3   G4     F1   F2       Channel   ^   doClockSequence
                                                   doChannnelsequence
             \_________________ software control ______________________/

The following table shows the module's gain and low-pass filter characteristics.

   Channel |  Gain                   F-LowPass [kHz] programmable
   --------+------------------------------------------------------
     1, 2  |    10, 20, 40, 80           >= 1000     (no filter)
           |   100, 200, 400, 800            100         yes
           |  1000, 2000, 4000, 8000          10         yes
           | 10000, 20000, 40000, 80000        1         yes
           |                                   0.1       yes
           |
     3, 4  |     1                          3000         no
           |    10                            :          no
           |   100                            :          no
           |  1000                           312         no

Classes

class RB9005_amplifier
. More...

Generated on Tue Oct 12 14:12:02 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RB9603 Monochromator Controller

RB9603 Monochromator Controller
[Reference Manual]

Detailed Description

Purpose

Control a Bausch & Lomb monochromator remotely.

Description

The RB9603 Rulbus module enables remote control of a Bausch & Lomb monochromator by driving its nonius with a stepping motor.

The target wavelength can be set manually with Up and Down keys on the Rulbus module and programmatically via the Rulbus computer interface.

The module has a one-line display that shows the target wavelength along with indications if the monochromator is still moving up or down and if the wavelength was set manually or via program control.

Besides setting the wavelength, several properties may be requested from the controller via the computer interface: the target wavelength, the current wavelength, the minimum and maximum wavelengths and the current wavelength as seen by the potentiometer on the stepping motor--potentiometer assembly.

The module's front-panel looks as follows.

     +--------------------------+
     | MONOCHROMATOR CONTROLLER |
     | .----------------------. |
     | | ^ 123.0 nm   manual  | |
     | `----------------------' |
     |                          |
     |                          |
     |   MOTOR    RESET   UP    |
     |                   .--.   |
     |       o      O    |  |   |
     |       /|          `--'   |
     |      | |          DOWN   |
     |      | |          .--.   |
     |       \|          |  |   |
     |       o           `--'   |
     |                          |
     |  RULBUS                  |
     +--------------------------+

Classes

class RB9603_monochromator
. More...

Generated on Tue Oct 12 14:12:02 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: PIA/VIA

PIA/VIA
[Reference Manual]

Detailed Description

The PiaVia, Pia and Via classes are separated from the implementation of the RB8506 Dual Parallel Interface so that they may be reused for the SIFU sense interrupt flag unit.

Classes

class | Pia
Pia implementation. More...

class | PiaVia
interface for Pia and Via. More...

class | Via
Via implementation. More...

Generated on Tue Oct 12 14:12:02 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Developer Manual

Developer Manual

Detailed Description

The Rulbus Device Class Library contains two groups of classes:
  • implementation related classes, Implementation
  • Rulbus module related classes, for example RB8510_Dac12

When you want to develop a driver for a Rulbus module, please first read Developing a Device Class.

Modules

Developing a Device Class
class definition -- class implementation.

Style Guide
source code style.

Implementation
Rulbus interface and device classes -- exceptions -- port-I/O.

Generated on Tue Oct 12 14:12:02 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Developing a Device Class

Developing a Device Class
[Developer Manual]

For each Rulbus module a class is defined to encapsulate the module's settings and behavior.

The class declaration is placed in a .h file and the implementation is placed in a .cpp file. The names of the files follow the pattern rbyydd_name. For example: rdcl_rb8510_dac12.h and rdcl_rb8510_dac12.cpp

These sourcefiles are located in the subdirectory {project-root}/rulbus-rdcl/src/.

Please take a look at the creation of the RB8510_Dac12 driver. The doxygen documentation is omitted for clarity, see section Rulbus Device Class Template of the Style Guide for that.

Class Declaration

First we declare the class for the DAC and add inline implementation for the simplest accessor methods.

#include "rdcl/RulbusDevice.h"  // classes RulbusDevice, RulbusInterface, RulbusError

namespace Rulbus
{
   DECLARE_CLASS( RB8510_Dac12 );               // the 12-bit DAC class type

   class RB8510_Dac12 : public RulbusDevice
   {
   public:                              // public methods
      typedef Int  Value;

      RB8510_Dac12(
         NameCref aName,
         Addr     aAddr        = DEF_ADDR,
         Rack     aRack        = DEF_RACK,
         bool     aBipolarFlag = DEF_BIP,
         Real     aVoltPerBit  = DEF_VPB );

      ~RB8510_Dac12();

      Volt    voltage() const;
      Value   value() const;

      bool    isBipolar() const;
      float   voltperbit() const;

      void    setVoltage ( Volt  aVoltage );
      void    setValue   ( Value aValue   );

   protected:                                   // protected methods
      RB8510_Dac12();
      RB8510_Dac12( RB8510_Dac12Cref rhs );
      RB8510_Dac12Ref operator= ( RB8510_Dac12Cref rhs );

   public:                                      // public data
      static const Addr  DEF_ADDR = 0xD0;
      static const Rack  DEF_RACK = 0;
      static const bool  DEF_BIP  = true;
      static const Real  DEF_VPB  /* = 5e-3 */;

      static const Value LIM_MINVAL = 0x0000;
      static const Value LIM_MAXVAL = 0x0FFF;
      static const Value LIM_BIPVAL = 0x0800;

   private:                                     // private data
      Value theRegister;
      bool  theBipolarFlag;
      Real  theVoltPerBit;

      static const int   OFF_MSB = 0;
      static const int   OFF_LSB = 1;

      static const int ADR_WIDTH = OFF_LSB + 1;
   };

   /*
 the current DAC-register value.
    */

   inline RB8510_Dac12::Value RB8510_Dac12::value() const
   {
      return theRegister;
   }

   /*
 the current DAC output voltage.
    */

   inline bool RB8510_Dac12::isBipolar() const
   {
      return theBipolarFlag;
   }

   /*
 the DAC's output sensitivity configuration.
    */

   inline Real RB8510_Dac12::voltperbit() const
   {
      return theVoltPerBit;
   }

} // namespace Rulbus

The class derives from class RulbusDevice and it contains a constructor to create an object of this class in a defined state, it contains selector methods and modifier methods and it contains state information.

Candidates for constructor parameters are characteristics fixed at production-time, like the Rulbus address and, for the DAC, the ouput polarity (bipolar / unipolar) and sensitivity (volt-per-bit, or vpb).

Candidates for selector and modifier methods are the modifiable characteristics of the Rulbus module, like the output voltage of a DAC.

The datamembers of the class hold the state information for the Rulbus module that it cannot memorize itself. Most Rulbus modules cannot be queried for their settings at all.

Further the class holds constant values we need for the class methods, like register offsets and minimum and maximum values. Constants are declared static const type name.

The constructor above is defined inline. It saves the fixed characteristics polarity and sensitivity to the respective datamembers, delegates the name and address information to the constructor of the RulbusDevice base class and finally sets the DAC ouput voltage to zero volt.

Class Implementation

Finally, we define the contents of the non-inline method bodies in the .cpp file, contained in the Rulbus namespace.

namespace Rulbus
{
   // the implementation goes here...
}

Data that requires a location or requires initialization in the .cpp file.

const Real RB8510_Dac12::DEF_VPB = 5e-3f;      ///< default bipolar, -10.24..+10.23V

The constructor.

RB8510_Dac12::RB8510_Dac12(
   NameCref aName,
   Addr     aAddr        /* = DEF_ADDR */,
   Rack     aRack        /* = DEF_RACK */,
   bool     aBipolarFlag /* = DEF_BIP */,
   Real     aVoltPerBit  /* = DEF_VPB */)
   :
   RulbusDevice  ( aName, aAddr, aRack ),
   theBipolarFlag( aBipolarFlag ),
   theVoltPerBit ( aVoltPerBit  )
{
   setVoltage( 0 );
}

The destructor.

RB8510_Dac12::~RB8510_Dac12()
{
   ; // do nothing
}

Method voltage() returns the saved DAC-register value transformed into the voltage.

Volt RB8510_Dac12::voltage() const
{
   Value code = value();

   if ( isBipolar() )
      code -= LIM_BIPVAL;

   return voltperbit() * code;
}

Method setValue() first checks if the value specified is valid, saves the value in the datamember theRegister and updates the DAC-register. If the value specified is invalid, setValue() throws a RulbusRangeError.

void RB8510_Dac12::setValue( Value aValue )
{
   if ( aValue < LIM_MINVAL || aValue > LIM_MAXVAL )
      throw RulbusRangeError( name(), "value", aValue, LIM_MINVAL, LIM_MAXVAL );

   theRegister = aValue;

   putByte( OFF_MSB, aValue / 256 );
   putByte( OFF_LSB, aValue % 256 );
}

Method setVoltage() transforms the specified voltage into a DAC-code and delegates the remaining work to method setValue(). If the voltage specified is not within the capablilities if the DAC, setValue() will throw a RulbusRangeError. setVoltage() catches this error and transforms it into a new RulbusRangeError now specifying the range error in terms of voltage.

void RB8510_Dac12::setVoltage( Volt aVoltage )
{
   Value code = ( aVoltage < 0 ? -0.5 : +0.5) + aVoltage / voltperbit();

   if ( isBipolar() )
      code += LIM_BIPVAL;

   try
   {
      setValue( code );
   }
   catch ( RulbusRangeErrorCref e )
   {
      Volt offset = isBipolar() ? -LIM_BIPVAL * voltperbit(): 0;

      throw RulbusRangeError( name(), "voltage", aVoltage,
         offset + voltperbit() * LIM_MINVAL, offset + voltperbit() * LIM_MAXVAL );
   }

   ensure( std::fabs( voltage() - aVoltage ) < voltperbit() / 2 + std::numeric_limits<Volt>::epsilon() );
}

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Style Guide

Style Guide
[Developer Manual]

Style Guide

This section describes some of the not directly obvious aspects of the coding style used for the Rulbus Device Class Library.

As a start, please take a look at the existing code.

Names

  • Types start with an upper case letter and use mixed case to separate name segments.
  • Variables and objects names that are data members of a class start with a `the' and use mixed case thereafter.
  • Abbreviations, like EPP, are spelled Epp when used as part of a name.

Rulbus device class names look like RB8510_Dac12 and RB8515_clock. Note the suffix Dac, it's not spelled DAC or dac.

Function and method names follow the following convention:

  • bool isBipolar(); for a method that returns a boolean value (accessors)
  • float frequency(); for a method that returns a value (accessors)
  • void setFrequency(float f); for a method that defines a value (mutators)
  • void getFrequency(float *f); for a method that obtains a value via an argument

Class constants

Declare constants (e.g. for register offsets) in the class as static const type name = value;, for example

class Aclass
{
   ...
private:
   static const int OFF_CTRL = 2;
   ...
};

This makes their documentation available in the same location as the other members. Otherwise it would appear in the devices' implementation page. There's no need to define the constant as long its location is not needed. The alternative of using enums does not provide type information.

Rulbus Device Class Template

Here is a template to create a Rulbus Device Class from.

/**
 * \brief ...
 *
 * <h3>Purpose</h3>
 * ...
 *
 * <h3>Description</h3>
 * ...
 *
 * <h3>Usage</h3>
 * ...
 * \code
 * \endcode
 *
 * <h3>Implementation</h3>
 * ...
 *
 */

class myClass : public RulbusDevice
{
public:                                 // public interface
   typedef int Value;

   /// \name Construction
   /// @{

   myClass( CharCptr name, int addr = DEF_ADDR, int rack = DEF_RACK );
   ~myClass();

   /// @}
   /// \name Operators
   /// @{

   myClassRef operator= ( myClassCref rhs );

   /// @}
   /// \name Accessors
   /// @{

   Value value( );

   /// @}
   /// \name Mutators
   /// @{

   void setValue( Value aValue );

   /// @}

protected:                              // protected interface
   /// \name Construction and Assignment
   /// @{

   myClass();                                   ///< prevent default construction
   myClass( myClassCref rhs );                  ///< prevent copying
   myClassRef operator= ( myClassCref rhs );    ///< prevent copying

   /// @}
   /// \name Checkers
   /// @{

   void checkValue( Value value );

   /// @}

private:                                // private methods

public:                                 // public member data
   /// \name Defaults
   /// @{

   static const int DEF_ADDR = 0x..;
   static const int DEF_RACK = 0;

   /// @}

protected:                              // protected member data

private:                                // private member data
   Value theValue;

   /// \name Defaults
   /// @{

   static const int DEF_ADDR = 0x..;
   static const int DEF_RACK = 0;

   /// \name Register offsets
   /// @{

   static const int OFF_STS  = 0;
   static const int OFF_CTRL = 0;

   /// @}
   /// \name Limits
   /// @{

   static const int LIM_xxxx = 0xFF;

   /// @}
};

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Implementation

Implementation
[Developer Manual]

Detailed Description

This section describes the base class for all Rulbus Devices. and it describes the classes that implement the ISA Rulbus Interface and the EPP Rulbus Interface

It also describes the exception classes for programming errors and the exception classes for usage errors.

Further it contains the functions for port-I/O, inp() and outp().

Use cases

Create device -- A Rulbus device comes into existence by defining a variable of its type or creating it dynamically via new.

Another way to create Rulbus devices is to read a Rulbus configuration file by calling RulbusDeviceFactory::createDevices(). The latter method is used by the Rulbus Device Library DLL.

Use device -- When a Rulbus device wants to access the Rulbus to read or write a byte ( getByte(), putByte() ), the access is delegated via theRulbus() to an object that implements the interface RulbusInterface: IsaRulbusInterface or EppRulbusInterface.

When the Rulbus devices have been created from a Rulbus configuration file, they can be accessed from TheRulbusDeviceList. In this case, access to the Rulbus devices is done via a RulbusDeviceProxy that protects the device against simultaneous access from different threads of execution (or from different processes in case of the Rulbus Device Library DLL).

Destroy Device -- A Rulbus device ceases to exist when it goes out-of-scope, or is deleted via delete.

Create Rulbus interface -- The proper Rulbus Interface can be created via RulbusInterfaceFactory::createInterface(), which uses environment variable RULBUS to determine the Rulbus Interface object to create.

If the Rulbus interface has not been created via an excplicit call to RulbusInterfaceFactory::createInterface(), then TheRulbusInterface::instance() will take care of it the first time the Rulbus is accessed.

Architecture

Class RulbusDevice is the central point of the library: from it the concrete classes for the various Rulbus modules are built and it forms the link to the Rulbus Interfaces to actually access the Rulbus.

The architecture of the Rulbus Device Class Library uses several software design patterns as published by Gamma and associates [1995]. The architecture is depicted in the UML diagram .

Modules

Common
common types and macro's.

Assertion
exceptions for programming errors.

Rulbus Errors
exceptions for the Rulbus Device Class Library.

Rulbus Device
Rulbus Device related classes.

Rulbus Interface
Rulbus Interface related classes.

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Common

Common
[Implementation]

Detailed Description

Common.h provides macro's and classes that must be available to the other files that make up the Rulbus Device Class Library.

It defines the following:

  • a DEBUG flag that specifies which items to include
  • macro's to declare types and classes
  • predefined types
  • Assertion and design-by-contract exception classes with accompanying macro's

Common.h must be included by all source files either directly, or indirectly.

Common.h and Assertion draw on the work provided by the CoreLinux++ consortium [CORELINUX++].

Classes

struct | isEqual
predicate for apgorithms to compare floating types like Volt, Time and Freq.

Defines

#define | DEBUG DFLAG_NONE
define the subjects to include in debugging.

#define | DFLAG_NONE 0x0000
include no debug subjects.

#define | DFLAG_ALL 0xFFFF
include all debug subjects.

#define | DFLAG_PRODUCTION (DFLAG_ALL & ~DFLAG_ENSURE)
include all but ensure debug subjects.

#define | DFLAG_GENERAL 0x0001
debug subjects combined in one group.

#define | DFLAG_INTERFACE 0x0002
report more details on Rulbus Interface errors.

#define | DFLAG_BUSVIOLATION 0x0004
check for Rulbus address/data violations.

#define | DFLAG_REQUIRE 0x0010
design-by-contract: require pre-condition.

#define | DFLAG_ENSURE 0x0020
design-by-contract: ensure post-condition.

#define | DFLAG_NEVER_GET_HERE 0x0040
design-by-contract: ensure never reached.

#define | dim(a) (sizeof(a)/sizeof((a)[0]))
array dimension.

#define | DECLARE_TYPE(mydecl, mytype)
declare a new type and its pointer, const pointer, reference, and const reference types.

#define | DECLARE_CLASS(tag)
declare class, class pointer, const pointer, class reference and const class reference types for classes.

#define | PROXY_CAST dynamic_cast
use dynamic_cast to cast RulbusDevice to actual class type.

Typedefs

typedef isEqual< Volt > | Rulbus::isEqualVolt
predicate to compare Volt

typedef isEqual< Time > | Rulbus::isEqualTime
predicate to compare Time

typedef isEqual< Freq > | Rulbus::isEqualFreq
predicate to compare Freq

typedef signed char | Rulbus::int8
the compiler's signed 8-bit integral type.

typedef unsigned char | Rulbus::uInt8
the compiler's unsigned 8-bit integral type.

typedef signed short int | Rulbus::int16
the compiler's signed 16-bit integral type.

typedef unsigned short int | Rulbus::uInt16
the compiler's unsigned 16-bit integral type.

typedef signed int | Rulbus::int32
the compiler's signed 32-bit integral type.

typedef unsigned int | Rulbus::uInt32
the compiler's unsigned 32-bit integral type.

typedef float | Rulbus::float32
the compiler's 32-bit real type.

typedef double | Rulbus::float64
the compiler's 64-bit real type.

typedef uInt8 | Rulbus::Byte
the libraries' byte type.

typedef uInt16 | Rulbus::Word
the libraries' word (2-Byte) type.

typedef uInt32 | Rulbus::Quad
the libraries' double word (4-Byte) type.

typedef char | Rulbus::Char
the libraries' character type.

typedef int | Rulbus::Int
the libraries' signed integral type.

typedef int16 | Rulbus::Int16
the libraries' 16-bit signed integral type.

typedef int32 | Rulbus::Int32
the libraries' 32-bit signed integral type.

typedef double | Rulbus::Real
the libraries' real type.

typedef float32 | Rulbus::Real32
the libraries' 32-bit real type.

typedef float64 | Rulbus::Real64
the libraries' 64-bit real type.

typedef std::string | Rulbus::String
the libraries' string type.

typedef std::exception | Rulbus::StdException
the std::exception type.

typedef String | Rulbus::Name
the Rulbus device name type.

typedef Int | Rulbus::Addr
the Rulbus address type.

typedef Int | Rulbus::Rack
the Rulbus rack number type.

typedef Real | Rulbus::Volt
the voltage type.

typedef Real32 | Rulbus::Volt32
the 32-bit voltage type.

typedef Real | Rulbus::Time
the time type.

typedef Real | Rulbus::Freq
the frequency type.

Define Documentation

#define DEBUG DFLAG_NONE

DEBUG contains a bit-pattern that specifies which subjects must be included in the debugging:

  • DFLAG_NONE include no debug subjects
  • DFLAG_ALL include all debug subjects
  • DFLAG_PRODUCTION include all but ensure debug subjects
  • DFLAG_GENERAL debug subjects combined in one group
  • DFLAG_INTERFACE report more details on Rulbus Interface errors
  • DFLAG_BUSVIOLATION check for Rulbus address/data violations
  • DFLAG_REQUIRE design-by-contract: require pre-condition.
  • DFLAG_ENSURE design-by-contract: ensure post-condition.
  • DFLAG_NEVER_GET_HERE design-by-contract: ensure never reached.

Following Kernighan & Pike [1999], page 200, we use DEBUG in an if statement:

 if ( DEBUG & DFLAG_BUSVIOLATION )
    // action...

By using an if statement as opposed to a preprocessor #if line, the syntax of the debug code is also checked when the debug code is inactivated.

If the (constant) condition evaluates to zero, the Borland C++ 5.6 compiler optimization process will change the test into an unconditional jump, so the debugging code incurs little execution overhead if not used. However the (unreachable) code for the if-statement is retained in the generated code. (Other compilers may remove the if-statement completely.)

/*
 * debug.cpp - determine presence of debugging code.
 */

#define DFLAG_NONE    0x0000
#define DFLAG_GENERAL 0x0001

#define DEBUG DFLAG_NONE

void debug( const char *msg );

int main()
{
   if ( DEBUG & DFLAG_GENERAL )
   {
      debug( "general debugging" );
   }

   return 0;
}

Generates the following assembly code:

        .386p
        ifdef ??version
        if ??version GT 500H
        .mmx
        endif
        endif
        model flat
        ifndef  ??version
        ?debug  macro
        endm
        endif
        ?debug  S "debug.cpp"
        ?debug  T "debug.cpp"
_TEXT   segment dword public use32 'CODE'
_TEXT   ends
_DATA   segment dword public use32 'DATA'
_DATA   ends
_BSS    segment dword public use32 'BSS'
_BSS    ends
DGROUP  group   _BSS,_DATA
_TEXT   segment dword public use32 'CODE'
_main   segment virtual
@_main  proc    near
?live16385@0:
 ;
 ;      int main()
 ;
        push ebp
        mov ebp,esp
 ;
 ;      {
 ;         if ( DEBUG & DFLAG_GENERAL )
 ;
@1:
        jmp short @2
 ;
 ;         {
 ;            debug( "general debugging" );
 ;
        push offset s@
        call @@debug$qpxc
        pop ecx
 ;
 ;         }
 ;
 ;         return 0;
 ;
@2:
        xor eax,eax
 ;
 ;      }
 ;
@4:
@3:
        pop ebp
        ret
@_main  endp
_main   ends
_TEXT   ends
_DATA   segment dword public use32 'DATA'
s@      label   byte
        ;       s@+0:
        db      "general debugging",0
        align   4
_DATA   ends
_TEXT   segment dword public use32 'CODE'
_TEXT   ends
@@debug$qpxc equ @debug$qpxc
 extrn @debug$qpxc:near
        ?debug  D "debug.cpp" 12620 28747
        end

#define DECLARE_CLASS ( tag )

Value:

class   tag;                         \
   typedef tag *       tag ## Ptr;      \
   typedef const tag * tag ## Cptr;     \
   typedef tag &       tag ## Ref;      \
   typedef const tag & tag ## Cref;

#define DECLARE_TYPE | ( | mydecl,
 |  | mytype | )

Value:

typedef mydecl         mytype;          \
typedef mytype *       mytype ## Ptr;   \
typedef const mytype * mytype ## Cptr;  \
typedef mytype &       mytype ## Ref;   \
typedef const mytype & mytype ## Cref;

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Assertion

Assertion
[Implementation]

Detailed Description

This module describes the classes and supporting macro's used to catch programming errors.

The following rules form a method to prevent such errors:

  • require a precondition: validate input before using it
  • ensure a postcondition: validate result after producing it
  • ensure a class invariant: validate that the class state is valid

For example:

 double sqrt( double x )
 {
    require( x >= 0 );        // precondition: x may not be negative

    double result = ... ;
                              // postcondition: check result value
    ensure ( abs( x - result * result ) <= DBL_EPSILON );
    return result;
 }

This method is known as design-by-contract. For more information, see [DBC]

Checking of preconditions and postconditions may be included or excluded from the source independendly. See DEBUG.

Classes

class | Assertion
base for design-by-contract assert exception. More...

class | DbcException
design-by-contract exception. More...

Defines

#define | LOCATION __FILE__, __LINE__
(file,linenumber) tuple used by require() and ensure() macros.

#define | require(exp)
require expression to be true, otherwise throw DbcException(REQUIRE).

#define | require_e(exp)
require expression to be true, otherwise throw specified exception.

#define | ensure(exp)
ensure expression to be true, otherwise throw DbcException(ENSURE).

#define | ensure_e(exp, ecxpt)
ensure expression to be true, otherwise throw specified exception.

#define | NEVER_GET_HERE
may not get here: throw DbcException(NEVER_GET_HERE).

#define | BASE_INVARIANT(base) base::invariant()
execute base class invariant.

Functions

std::ostream & | operator<< (std::ostream &stream, Rulbus::StdExceptionCref rhs)
write exception to stream.

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Rulbus Errors

Rulbus Errors
[Implementation]

Detailed Description

This section describes the errors that we categorize as usage, or environmental errors: for example invalid input that is not the result of a programming error.

Such errors that occur in the Rulbus Device Class Library are handled using the try {...} catch( ) {...} exception handling mechanism. If an error occurs, a descendant of RulbusError is thrown that ultimately must be catched in the Rulbus interface function that led to the exception. For example:

 #include "rdcl/rb8510_Dac12.h"

 int main()
 {
    try
    {
       Rulbus::RB8510_Dac12 dac( "mydac" );
       dac.setVoltage( 123 );
    }
    catch( const std::exception& e )
    {
       std::cerr << e;
    }
 }

RulbusError itself descends from std::exception (StdException).

Classes

class | RulbusAddressError
Rulbus addressing error. More...

class | RulbusCloseError
Rulbus device close (remove) error. More...

class | RulbusConfigError
Rulbus configuration file error. More...

class | RulbusContextError
Rulbus context error. More...

class | RulbusDataError
Rulbus data error. More...

class | RulbusError
Rulbus errors base class. More...

class | RulbusHandleError
Rulbus device handle error. More...

class | RulbusInterfaceError
Rulbus Interface error. More...

class | RulbusOpenError
Rulbus device open error. More...

class | RulbusParseError
configuration file parser error. More...

class | RulbusRangeError
Rulbus parameter range error. More...

class | RulbusScanError
configuration file scanner error. More...

class | RulbusTimeoutError
Rulbus timeout error. More...

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Rulbus Device

Rulbus Device
[Implementation]

Detailed Description

Class RulbusDevice is the base class for all Rulbus devices. It contains the common information, like device name and Rulbus address. Further it provides the operations to read from and write to the Rulbus.

Classes

class RulbusDevice
Rulbus device base class, Bridge(151). More...

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Rulbus Interface

Rulbus Interface
[Implementation]

Detailed Description

The Rulbus Device Class Library supports two Rulbus Interface cards:
  • ISA Rulbus Interface card
  • EPP Rulbus Interface card

The Rulbus interface class provides the means to read and write to the Rulbus that is connected to the specific Rulbus Interface card.

The proper interface class to use is created by the RulbusInterfaceFactory, based on the presence and contents of the Rulbus environment variable.

The responsibility to create the interface class is with class RulbusDevice. You can either request class RulbusDevice to create the Rulbus interface class, or let it create the Rulbus interface class automatically the first time a Rulbus device accesses the Rulbus.

Access to I/O-Ports

The Rulbus Interfaces are accessed via the computer's input/output ports. Windows NT type operating systems require that you have the privilege to access these ports. To give you that right, we use function AddMultiPort() of CanIO [CANIO] to open the address range required for the Rulbus Interface used.

See [DRIVERLINX] and [UNIIO] for other products that can provide access to input/output ports.

Modules

CanIO I/O-port access
provide access to computer's i/o-ports.

Classes

class | EppRulbusInterface
EPP Rulbus Interface. More...

class | IsaRulbusInterface
ISA Rulbus Interface. More...

class | RulbusInterfaceFactory
the Rulbus Interface Abstract Factory(87) Singleton(127). More...

class | TheRulbusInterface
Rulbus Interface abstract base class. More...

Defines

#define | SPORTIO "CanIO"
string representation for PORTIO used.

Functions

short | Rulbus::inp (unsigned short port)
read a byte from an input-output port

short | Rulbus::outp (unsigned short port, unsigned char value)
write a byte to an input-output port.

bool | Rulbus::openIO (long base, int len)
open port input-output address range on Windows NT type operating systems using CanIO. CanIO consists of canio.dll and canio.sys. openIO() first dynamically loads canio.dll and then calls AddMultiPort() to provide access to the requested input-output range.

Function Documentation

short inp ( unsigned short port )

read a byte from an input-output port

 short inp(unsigned short port)
 {
    asm  mov  dx, port
    asm  in   al, dx
    asm  xor  ah, ah
    return _AX;
 }

Parameters:
port portnumber
Returns:
byte read

short outp | ( | unsigned short | port,
 |  | unsigned char | value
 | ) |

write a byte to an input-output port.

 short outp(unsigned short port, unsigned char value)
 {
    asm  mov  dx, port
    asm  mov  al, value
    asm  out  dx, al
    asm  xor  ah, ah
    return (_AX);
 }

Parameters:
port | portnumber
value | byte to write
Returns:
value

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: CanIO I/O-port access

CanIO I/O-port access
[Rulbus Interface]

Detailed Description

Documentation for CANIO

Copyright © 2002 CanSoft

The CanIO software is a 2-file combination utility: a DLL and SYS kernel mode driver [CANIO].

The DLL can be loaded like any other DLL and the routines are outlined below. The purpose of the application is to open up port access (for example the CMOS at port 0x70) anywhere in the 64k IO space through Windows NT/2000/XP and .Net applications. Windows 95, 98, ME do not block access to these ports but the other MS operating systems do. My utility will assign rights to your application to read and write from these ports in these applications.

How it works

You load the DLL and call the AddMultiPort routine as needed. The DLL will check your OS (or you can do this yourself in your own application if you want) and if you have NT/2000/XP/.Net installed it will then call the kernel mode driver which will in turn give to your calling application the rights to read/write from the requested ports. If it is Win95/98/ME then the DLL won't call the SYS, as it won't even be installed, and will just do nothing, as your app already has rights in this environment.

Installation

Your application should detect OS and then install the CanIO. SYS driver if needed through your own install process depending upon your development language.

For testing purposes, however, there are two ways you can install the kernel mode driver:

Method 1

With the instdrv.exe application, type at the command prompt: instdrv canio c:\pathtocaniosys\canio.sys The "pathtocaniosys" directory is whatever directory you have copied the CanIO.sys driver to. If you use this method, the CanIO.dll does not have to be in the same directory as the CanIO.sys file.

Method 2

Everytime you load the CanIO.DLL library, it will detect the OS type installed and then if it is WinNT/2000/XP/.Net it will try to get a handle to the CanIO service (CanIO.sys). If it cannot get a handle to the CanIO service (meaning it is not installed or is not running), it will attempt to locate the CanIO.sys file and attempt to install and start the service automatically for you.

This will work if and only if you are logged into the machine with administrative privileges. Also, the CanIO. sys file MUST be in the same directory as the CanIO.dll file because that is where it will look for it. So this method actually requires that you do nothing other than making sure you have admin privileges on the machine and that the .sys file is on the same directory as the .dll.

ROUTINES

  1. BOOL AddMultiPort(ULONG, INT)
    This routine returns true or false and requires two parameters - the first is a 32bit integer which is the starting port address (In Delphi it would be "Longword"). The second is a standard integer type, which outlines how many bytes to open starting from the passed address.

    So, if you wanted to read a word from port 0x400 you would call:
    AddMultiPort(0x400, 2);

    To read just one byte from port 0x70 you would call:
    AddMultiPort(0x70, 1);

    NOTE Make SURE when declaring the routine in your application that you match the parameters correctly. In other words, don't declare AddMultiport as AddMultiPort(Word, int) or something like that. This WILL give you problems.

  2. BOOL UnloadDrvr()
    This call is optional and it will attempt to unload the .sys driver IF AND ONLY IF the running instance of the DLL also installed it. This means that if you are running your machine with admin privileges, the CanIO.DLL will install and start the CanIO service for you when it loads and when you are done reading from the various ports you need to, you can unload the driver from memory by calling this routine. This way the driver only stays in memory for a brief period.

Defines

#define | IMPORT __declspec(dllimport)
use function from DLL

#define | CANIO_API __stdcall
CanIO dynamic-link library calling convention.

Functions

IMPORT BOOL CANIO_API | AddMultiPort (ULONG base, int length)
provide access privilege to a range of I/O-port addresses.

Define Documentation

#define CANIO_API __stdcall

It's not stated in the documentation, but CanIO uses the Pascal calling convention (like WinAPI).

Initially I defined CANIO_API as empty and could use the Rulbus Device Library DLL succesfully (that is without access violation exceptions). After some code changes, rulbus.dll started to give access violation exceptions.

Debugging with fprintf() statements finally pointed to AddMultiPort() and I started to suspect its prototype.

Changing the empty CANIO_API to __stdcall solved the problem.

Martin J. Moene, 4 June 2003.

Function Documentation

IMPORT BOOL CANIO_API AddMultiPort | ( | ULONG | base,
 |  | int | length
 | ) |

this function provides port access to the number of i/o-ports specified by length and starting at address base.

Parameters:
base | first address to open
length | number of i/o-ports to open
Returns:
it's not documented, but the function appears to behave like other Windows API functions and return 0 for failure, !0 for success.

Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Example Index

Rulbus Device Class Library for Microsoft Windows Examples

Here is a list of all examples:
  • dac.cpp
  • pport.cpp
  • rulbus.conf
  • template.h
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Example Documentation

dac.cpp

This is an example that shows how the RB8510 12-bit DAC may be used.
/*
 * dac.cpp - generate a staircase voltage.
 *
 * Compile: bcc32 -tWM dac.cpp rulbusdcl-omf-static.lib winutils-omf-static.lib
 */

#include <iostream>             // for std::cout etc.
#include <cstdlib>              // for std::strtol()
#include <windows.h>            // for Sleep()
#include "rdcl/rb8510_dac12.h"  // header

static int usage();             // print program usage, return EXIT_FAILURE

/*
 * main - handle commandline arguments and generate staircase voltage on DAC.
 */

int main( int argc, char *argv[] )
{
   try
   {
      /*
       * handle commandline arguments:
       */

      if ( argc < 4 )
         return usage();

      /*
       * for rack and Rulbus address, let strtol() determine the radix of the input:
       *   octal for 012, decimal for 12, hexadecimal for 0x12.
       */

      char *name = argv[1];
      int   rack = std::strtol( argv[2], 0, 0 );
      int   addr = std::strtol( argv[3], 0, 0 );

      const int   bipolar = 1;                // bipolar
      const float vpb     = 5e-3;             // volt-per-bit

      /*
       * create the DAC:
       */

      Rulbus::RB8510_Dac12 dac( name, addr, rack, bipolar, vpb );

      /*
       * generate 11 one volt steps, one per second:
       *
       * Note that the last step generates a RulbusRangeError, because the
       * voltage is outside [-10.235 .. +10.24 V].
       */

      for ( int i = 0; i <= 11; i++ )
      {
         std::cout << '[' << i << ']';

         dac.setVoltage( i );

         Sleep( 1000 );                    // delay one second
      }

      /*
       * dac goes out of scope and is destroyed:
       */
   }
   catch ( const std::exception& e )
   {
      std::cout << std::endl << e << std::endl;
   }

   return EXIT_SUCCESS;
}

/*
 * usage - print program usage.
 */

static int usage()
{
   std::cout << "Usage: dac device-name rulbus-rack rulbus-address" << std::endl;
   return EXIT_FAILURE;
}
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Example Documentation

pport.cpp

This is an example that shows how the RB8506 dual parallel interface (PIA/VIA) may be used.
/*
 * pport.cpp - switch a LED on and off, a parallel interface demonstration.
 *
 * The switch is connected to PB3 of parallel interface, Pia 2,
 * the LED is connected to PB0.
 *
 * The program continuously reads the switch and puts the LED on
 * when the switch is closed and puts the LED off when the switch
 * is open. Note the inverted logic of the switch (pull-up) as
 * well as of the LED (pulled down).
 *
 *  +5V           parallel interface           +5V
 *   +             +------------+               +
 *   |             |    pia2    |   \\          |
 *   +---===---+---| PB3    PB0 |---|<|---===---+
 *        /    |   |            |
 *   +---/  ---+   +------------+
 *   | switch  LED
 *  ---
 *
 * The program uses two methods:
 * 1. mask: read and set the i/o-pins by reading and writing port B
 * 2. line: read and set the i/o-pins by reading and wrting a single line
 *
 * Compile: bcc32 -tWM par.cpp rulbusdcl-omf-static.lib winutils-omf-static.lib
 */

#include <conio.h>              // for kbhit(), getch()
#include <iostream>             // for std::cout
#include <windows.h>            // for Sleep()

#include "rdcl/rb8506_pport.h"  // for class RB8506_Pia etc.

enum  Pin { pin0, pin1, pin2, pin3, pin4, pin5, pin6, pin7, };

const Pin   pinLED     = pin0;  // the LED is at PB0
const Pin   pinSwitch  = pin3;  // the switch is at PB4

const char* portLED    = "PB";  // for port functions
const char* portSwitch = "PB";

const char* lineLED    = "PB0"; // for line functions
const char* lineSwitch = "PB3";

const int   rack       = 0;
const int   address    = 0x94;  // this is the parallel interface, Pia 2

inline int  mask( int pin ) {  return 1 << pin; }

inline int  tstbit( int  byte, int pin ) {  return ( byte &   mask(pin) ) != 0; }
inline int  clrbit( int& byte, int pin ) {  return   byte &= ~mask(pin); }
inline int  setbit( int& byte, int pin ) {  return   byte |=  mask(pin); }
inline int  xorbit( int& byte, int pin ) {  return   byte ^=  mask(pin); }

static void setPortDirection( Rulbus::RB8506_PiaViaRef port );
static void setLineDirection( Rulbus::RB8506_PiaViaRef port );
static void switchLED_mask  ( Rulbus::RB8506_PiaViaRef port );
static void switchLED_line  ( Rulbus::RB8506_PiaViaRef port );

/*
 * the program
 */

int main()
{
   std::cout << "Switch a LED on and off, a parallel interface demonstration.";

   Rulbus::RB8506_Pia pia( "lamp-control", address, rack );

   // using port functions:

   std::cout << "\nsetting port direction..." ;
   setPortDirection( pia );

   std::cout << "\nusing port data with bitmasks; press a key to contine...";
   switchLED_mask( pia );

   // using line functions:

   std::cout << "\nsetting line direction..." ;
   setLineDirection( pia );

   std::cout << "\nusing single line functions; press a key to contine...";
   switchLED_line( pia );

   std::cout << std::endl;
}

//--- solution using port-i/o with bitmasks

/*
 * Set data direction, using bitmasks.
 */

static void setPortDirection( Rulbus::RB8506_PiaViaRef port )
{
   int dataSwitch = port.getPortDir( portSwitch );
   int dataLED    = port.getPortDir( portLED    );

   port.setPortDir( portSwitch, dataSwitch & ~mask(pinSwitch) );
   port.setPortDir( portLED   , dataLED    |  mask(pinLED   ) );
}

/*
 * Read the switch and control the LED using bit-masks.
 */

static void switchLED_mask( Rulbus::RB8506_PiaViaRef port )
{
   while ( !kbhit() )
   {
      int dataSwitch = port.getPortData( portSwitch );
      int dataLED    = port.getPortData( portLED    );

      if ( tstbit( dataSwitch, pinSwitch ) ) setbit( dataLED, pinLED );
      else                                   clrbit( dataLED, pinLED );

      port.setPortData( portLED, dataLED );

      Sleep( 10 );
   }

   (void) getch();
}

//--- solution using line-i/o

/*
 * Set data direction, using line-functions.
 */

static void setLineDirection( Rulbus::RB8506_PiaViaRef port )
{
   port.setLineDir( lineSwitch, 'i' );
   port.setLineDir( lineLED   , 'o' );
}

/*
 * Read the switch and control the LED using single line i/o-functions.
 */

static void switchLED_line( Rulbus::RB8506_PiaViaRef port )
{
   while ( !kbhit() )
   {
      int switchOpen = port.getLineLevel( lineSwitch );
                       port.setLineLevel( lineLED, switchOpen );

      Sleep( 10 );
   }

   (void) getch();
}
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Example Documentation

rulbus.conf

This example shows what a Rulbus configuration file may look like. See also ConfigParser.
/*
 * rulbus.conf - Rulbus rack and cards configuration file.
 *
 * This file is part of the Rulbus Device Class Library (RDCL).
 *
 * Copyright (C) 2003-2004, Leiden University.
 * This library is free software, see below.
 *
 * $Revision: $
 * $Date: $
 * $Source: $
 * %Author: Martin J. Moene %
 *
 * Compiler        : Borland-C++ 5.5.1
 * Operating system: 32-bit Windows
 * Hardware system : PC
 *
 * This library is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * The library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with mngdriver; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */

/*
 * //
 * // small example rulbus.conf:
 * //
 *
 * rack "toprack"
 * {
 *    address = 7                               // this rack has address 7
 *    rb8509_adc12 "adc"                        // uses defaults
 *    rb8509_dac12 "dac-ch0"                    // uses defaults
 *    rb8509_dac12 "dac-ch1" { address = 0xD2 } // address specified
 * }
 *
 * rack "bottomrack"
 * {
 *    address = 8                               // this rack has address 8
 *    rb8515_clock "clock"   { }                // uses defaults
 *    rb8514_delay "delay0"  { }                // uses defaults
 *    rb8514_delay "delay1"  { address = 0xA4 } // address specified
 * }
 */

/*
 * keywords (case sensitive):
 *
 * - rack
 * - rb_generic
 * - rb8506_pia
 * - rb8506_sifu
 * - rb8506_via
 * - rb8509_adc12
 * - rb8510_dac12
 * - rb8513_timebase
 * - rb8514_delay
 * - rb8515_clock
 * - rb8905_adc12
 * - rb9005_amplifier
 * - rb9603_monochromator
 *
 * - address          (all cards)
 * - bipolar          (rb8509_adc12, rb8510_dac12)
 * - has_ext_trigger  (rb8509_adc12)
 * - intr_delay       (rb8514_delay)
 * - num_channels     (rb8509_adc12)
 * - volt_per_bit     (rb8509_adc12, rb8510_dac12)
 *
 * - false, no
 * - true, yes
 *
 * - [fpnumkMGT] characters used as suffix on a number (unit) have the
 *   following meaning
 *
 *   sfx | meaning
 *   ----+-------------
 *    f  | femto  1e-15
 *    p  | femto  1e-12
 *    n  | pico   1e-9
 *    u  | micro  1e-6
 *    m  | milli  1e-3
 *    k  | kilo   1e+3
 *    M  | mega   1e+6
 *    G  | giga   1e+9
 *    T  | tera   1e+12
 */

/*
 * Rulbus rack address
 *
 * The address of a Rulbus rack can be set via a 4-bit DIP-switch on its
 * rear-side.
 *
 *
 *    Secondary Address                    Secondary Address
 *            1  0                                 1  0
 *   weight +------+  bit                 weight +------+  bit
 *        1 | .  o | DS 0                      1 | o  . | DS 0
 *        2 | .  o | DS 1                      2 | o  . | DS 1
 *        4 | .  o | DS 2                      4 | o  . | DS 2
 *        8 | .  o | DS 3                      8 | o  . | DS 3
 *          +------+                             +------+
 *
 *  0: 0*8 + 0*4 + 0*2 + 0*1            15: 1*8 + 1*4 + 1*2 + 1*1
 *
 *
 * So there are 16 addresses to select from [0..0xF].
 *
 * Address 15 (0xF) is a special address: when a Rulbus rack has its
 * DIP-switch set to 15, it is always selected, no matter what the
 * computer tells the rack-selector.
 *
 * Please specify the DIP-switch setting for the address in a rack's
 * declaration.
 *
 * When you do not specify a rack address it will be 0xF.
 */

rack "top" =                    // this is a line comment, the '//' starts it
{
   address = 3                  // the required rack address [0..0xF]

   rb8506_pia "pport"           // the simplest card definition, using default properties

   rb8509_adc12 "adc12" =       // the most verbose card definition ( with '=' and ';' )
   {                            // the initializer
      address = 0xC0;           // the card address property

      has_ext_trigger = false   // or: no; no external trigger input on front
      num_channels    = 8;      // or: 4 on some modules
      bipolar         = true;   // or: yes
      volt_per_bit    = 5e-3;   // or: 5m, or 5 m
   };                           // end of initializer

   rb8510_dac12 "dac12-ch0"     // the simplest card definition with initializer
   {
   }

   rb8510_dac12 "dac12-ch1" =
   {
      address      = 0xD2
      bipolar      = true
      volt_per_bit = 5 m
   }

   rb8514_delay "delay0" =
   {
      /* address = 0xA0 */
   }

   rb8514_delay "delay1" =
   {
      address    = 0xA4
      intr_delay = 50 n         // 50 ns intrinsic delay
   }

   rb8515_clock "clock1";       // using defaults
}

/*
 * end of file
 */
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Example Documentation

template.h

A template to create a Rulbus Device Class from. See also Style Guide.
class myClass : public RulbusDevice
{
public:                                 // public interface
   typedef int Value;

   myClass( CharCptr name, int addr = DEF_ADDR, int rack = DEF_RACK );
   ~myClass();

   myClassRef operator= ( myClassCref rhs );

   Value value( );

   void setValue( Value aValue );

protected:                              // protected interface

   myClass();
   myClass( myClassCref rhs );
   myClassRef operator= ( myClassCref rhs );

   void checkValue( Value value );

private:                                // private methods

public:                                 // public member data

   static const int DEF_ADDR = 0x..;
   static const int DEF_RACK = 0;

protected:                              // protected member data

private:                                // private member data
   Value theValue;

   static const int DEF_ADDR = 0x..;
   static const int DEF_RACK = 0;

   static const int OFF_STS  = 0;
   static const int OFF_CTRL = 0;

   static const int LIM_xxxx = 0xFF;

};
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Namespace Member Index

Here is a list of all documented namespace members with links to the namespaces they belong to:

- a -

  • Addr : Rulbus

- b -

  • backslash() : Rulbus
  • Byte : Rulbus

- c -

  • Char : Rulbus

- e -

  • eq() : Rulbus

- f -

  • float32 : Rulbus
  • float64 : Rulbus
  • fmtstring() : Rulbus
  • Freq : Rulbus

- i -

  • inp() : Rulbus
  • Int : Rulbus
  • int16 : Rulbus
  • Int16 : Rulbus
  • Int32 : Rulbus
  • int32 : Rulbus
  • int8 : Rulbus
  • isEqualFreq : Rulbus
  • isEqualTime : Rulbus
  • isEqualVolt : Rulbus
  • isletter() : Rulbus
  • isnumeric() : Rulbus
  • isquote() : Rulbus
  • isspecial() : Rulbus

- k -

  • kwcmp() : Rulbus
  • kwTable : Rulbus

- l -

  • List : Rulbus

- n -

  • Name : Rulbus

- o -

  • openIO() : Rulbus
  • operator<<() : Rulbus
  • outp() : Rulbus

- q -

  • Quad : Rulbus

- r -

  • Rack : Rulbus
  • Real : Rulbus
  • Real32 : Rulbus
  • Real64 : Rulbus

- s -

  • StdException : Rulbus
  • String : Rulbus

- t -

  • Time : Rulbus
  • to() : Rulbus
  • to_bcd() : Rulbus
  • to_cstr() : Rulbus
  • to_int() : Rulbus
  • to_rb() : Rulbus
  • to_rb8506() : Rulbus
  • to_rb8506_pia() : Rulbus
  • to_rb8506_pia_ptr() : Rulbus
  • to_rb8506_ptr() : Rulbus
  • to_rb8506_sifu() : Rulbus
  • to_rb8506_sifu_ptr() : Rulbus
  • to_rb8506_via() : Rulbus
  • to_rb8506_via_ptr() : Rulbus
  • to_rb8509() : Rulbus
  • to_rb8509_ptr() : Rulbus
  • to_rb8510() : Rulbus
  • to_rb8510_ptr() : Rulbus
  • to_rb8513() : Rulbus
  • to_rb8513_ptr() : Rulbus
  • to_rb8514() : Rulbus
  • to_rb8514_ptr() : Rulbus
  • to_rb8515() : Rulbus
  • to_rb8515_ptr() : Rulbus
  • to_rb8905() : Rulbus
  • to_rb8905_ptr() : Rulbus
  • to_rb9005() : Rulbus
  • to_rb9005_ptr() : Rulbus
  • to_rb9603() : Rulbus
  • to_rb9603_ptr() : Rulbus
  • to_rb_ptr() : Rulbus
  • to_real() : Rulbus
  • to_string() : Rulbus
  • to_string16() : Rulbus
  • to_string2() : Rulbus
  • to_string8() : Rulbus
  • to_string_pfx() : Rulbus

- u -

  • uInt16 : Rulbus
  • uInt32 : Rulbus
  • uInt8 : Rulbus

- v -

  • Volt : Rulbus
  • Volt32 : Rulbus

- w -

  • Word : Rulbus
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Page Index

Rulbus Device Class Library for Microsoft Windows Related Pages

Here is a list of all related documentation pages:
  • UML Diagram showing interface and implementation
  • Acknowledgements
  • References
  • Todo List
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: UML Diagram showing interface and implementation

UML Diagram showing interface and implementation

Todo:
Add TheRulbusDeviceList singleton class.
The architecture of the Rulbus Device Class Library uses several software design patterns as published by Gamma and associates [1995]. Pattern names appear at the top of several classes, like <<bridge(151)>> in the RulbusDevice class. The number between parentheses after the pattern name refers to the page where that pattern is described in this book

Generated on Tue Oct 12 14:11:59 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Acknowledgements

Acknowledgements

It was Henk Klein Wolterink's vision in 1985 to design the Rulbus architecture and bridge the worlds of different microprocessors that existed at the various electronic departments of Leiden University (then Rijksuniversiteit Leiden) and at the same time bring the departments closer to each other by means of the meetings held to achieve the goal. That Rulbus is still actively used is a clear indicator of the quality of his vision. So is the fact that the University now has a united electronic department. Many thanks. In 1999 Henk Klein Wolterink established Applied Instruments [APPLINSTR].

Jens Thoms Törring designed a Rulbus configuration file for the Rulbus support in his fsc2 [FSC2] spectrometer application. Thanks for his idea and support to create a common format for it after I copied and altered it for the RDL.

Thanks to Joris Slob who reported `strange behaviour' of various modules that turned out to be real bugs.

Generated on Tue Oct 12 14:11:59 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: References

References

URL catalog

[APPLINSTR]
Henk Klein Wolterink's Applied Instruments.
http://www.applied-instruments.com/

[BCBDEVDLL]
Harold Howe's Creating DLLs in BCB that can be used from Visual C++.
http://www.bcbdev.com/articles/bcbdll.htm

[CANIO]
Can Soft. CanIO is a DLL and kernel mode driver combination (.SYS) that allows Win32 applications to get port access in Windows NT/2000/XP/. Net.
http://cansoft.livewiredev.com/

[CORELINUX++]
CoreLinux++ is an initiative to normalize methods and conventions for OOA/OOD/C++ development for Linux. Standard, guidelines, process, vision, and implementation are materialized in documentation and set of Open Source C++ class libraries.
http://corelinux.sourceforge.net/

[DBC]
Bertrand Meyer's An introduction to Design by ContractTM.
http://archive.eiffel.com/doc/manuals/technology/contract/, see also http://en.wikipedia.org/wiki/Design_by_contract

[DRIVERLINX]
Scientific Software Tools, Inc. Windows 95/NT Port I/O Driver. Simple user mode DLL and NT kernel driver to allow direct hardware I/O access. Works under Windows 95, 98, Me, 2000, and XP.
http://www.driverlinx.com/

[IEEE1284]
IEEE Standard Signaling Method for a Bidirectional Parallel Peripheral Interface for Personal Computers (1284-2000).
http://www.ieee.org/

[FSC2]
Jens Thoms Törring's software package for remote control of spectrometers.
http://www.physik.fu-berlin.de/~toerring/fsc2.phtml

[LXR]
Cross-Referencing Linux; Browse the code.
http://lxr.linux.no/

[MSDLL]
Microsoft. Dynamic-Link Libraries.
http://msdn.microsoft.com/library/en-us/dllproc/base/dynamic_link_libraries.asp

[MVCTOR]
M.D. Wilson's Move Constructors.
http://www.synesis.com.au/resources/articles/cpp/movectors.pdf

[PPCNTRL]
Jan Axelson's Parallel Port Central.
A collection of files and links to material about the PC's parallel port, including ECP, EPP, bidirectional, and IEEE-1284 modes (and other I/O ports as well).
http://www.lvr.com/parport.htm .

[PRGEPP]
Paul Rademacher's Programming the Enhanced Parallel Port.
http://www.tlmat.unican.es/asignat/labtxdatos/links/EPP.htm

[RULBUS]
Leiden University. Rulbus specifications and modules.
http://www.eld.LeidenUniv.nl/~moene/rulbus/

[SINIST]
NIST. International System of Units from NIST.
http://physics.nist.gov/cuu/Units/

[UNIIO]
BBDSoft. Unified IO -- C++ interface for industrial IO cards
http://www.bbdsoft.com/interface.html

Book references

[Axelson, 1997]
Jan Axelson. 1997. Parallel Port Complete Programming, Interfacing, and Using the PC's. Madison, WI 53704: Lakeview Research. ISBN 0-9650819-1-5.

[Gamma et al., 1995]
Erick Gamma, Richard Helm, Ralph Johnson, and John Vlissides. 1995. Design Patterns; Elements of Reusable Object-Oriented Software. Reading, Massachusetts: Addison-Wesley. ISBN 0-201-63361-2.

[Kernighan & Pike, 1999]
Brian W. Kernighan and Rob Pike. 1999. The Practice of Programming. Reading, Massachusetts: Addison-Wesley. ISBN 0-201-61586-X.

[Stroustrup, 2000]
Bjarne Stroustrup. 2000. The C++ Programming Language: Special Edition, 3/E. Boston: Addison Wesley Professional. ISBN 0-201-70073-5.

Generated on Tue Oct 12 14:11:59 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Todo List

Todo List

Page UML Diagram showing interface and implementation
Add TheRulbusDeviceList singleton class.
Generated on Tue Oct 12 14:11:59 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Assertion.h Source File

Assertion.h

00001 /*
00002  * Assertion.h - design-by-contract, assertions.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: Assertion.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __ASSERTION_H
00026 #define __ASSERTION_H
00027
00028 #ifndef __IN_COMMON_H
00029    #error assertion.h is included by common.h only.
00030 #endif
00031
00032 #include <iosfwd>       // for std::ostream
00033 #include <stdexcept>    // for std::exception
00034
00074 #define LOCATION __FILE__, __LINE__
00075
00091 #if DEBUG & DFLAG_REQUIRE
00092    #define require(exp)           \
00093       if (!(exp))                 \
00094          throw Rulbus::RequireException( _T(#exp), LOCATION )
00095
00096    #define require_e(exp, ecxpt)  \
00097       if (!(exp))                 \
00098          throw excpt
00099 #else
00100    #define require(exp)
00101    #define require_e(exp)
00102 #endif // DEBUG & DFLAG_REQUIRE
00103
00114 #if DEBUG & DFLAG_ENSURE
00115    #define ensure(exp)          \
00116       if (!(exp))               \
00117          throw Rulbus::EnsureException( _T(#exp), LOCATION )
00118
00119    #define ensure_e(exp, ecxpt) \
00120       if (!(exp))               \
00121          throw excpt
00122 #else
00123    #define ensure(exp)
00124    #define ensure_e(exp, ecxpt)
00125 #endif // DEBUG & DFLAG_ENSURE
00126
00132 #if DEBUG & DFLAG_NEVER_GET_HERE
00133    #define NEVER_GET_HERE  throw Rulbus::NeverGetHereException( LOCATION )
00134 #else
00135    #define NEVER_GET_HERE
00136 #endif
00137
00142 #define BASE_INVARIANT( base )  base::invariant()
00143
00145
00146 namespace Rulbus
00147 {
00148    DECLARE_CLASS( Assertion );
00149    DECLARE_CLASS( DbcException );
00150    DECLARE_CLASS( RequireException );
00151    DECLARE_CLASS( EnsureException );
00152    DECLARE_CLASS( AssertException );
00153    DECLARE_CLASS( NeverGetHereException );
00154
00165    class Assertion : public StdException
00166    {
00167    public:
00170
00171       Assertion( CharCptr aReason, CharCptr aFile, int aLine );
00172
00173       Assertion( AssertionCref rhs );
00174
00175       virtual ~Assertion();
00176
00180
00181       AssertionRef operator=( AssertionCref rhs );
00182
00183       bool operator==( AssertionCref rhs );
00184
00188
00189       virtual CharCptr what() const;
00190
00191       String  reason() const;
00192       String  file() const;
00193       int     line() const;
00194
00196
00197    protected:
00198       String  theReason;
00199       String  theFile;
00200       int     theLine;
00201    };
00202
00207    inline Assertion::Assertion( CharCptr aReason, CharCptr aFile, int aLine ):
00208       theReason( aReason ), theFile( aFile ), theLine( aLine )
00209    {
00210       ; // do nothing
00211    }
00212
00217    inline Assertion::Assertion( AssertionCref rhs ):
00218       theReason( rhs.theReason ), theFile( rhs.theFile ), theLine( rhs.theLine )
00219    {
00220       ; // do nothing
00221    }
00222
00227    inline Assertion::~Assertion()
00228    {
00229       ; // do nothing
00230    }
00231
00236    inline AssertionRef Assertion::operator=( AssertionCref rhs )
00237    {
00238       if( this != &rhs )
00239       {
00240          theReason = rhs.theReason;
00241          theFile = rhs.theFile;
00242          theLine = rhs.theLine;
00243       }
00244       else
00245       {
00246          ;  // do nothing
00247       }
00248
00249       return *this;
00250    }
00251
00256    inline bool Assertion::operator==( AssertionCref rhs )
00257    {
00258       return theReason == rhs.reason() &&
00259              theFile   == rhs.file()   &&
00260              theLine   == rhs.line();
00261    }
00262
00267    inline String Assertion::reason() const
00268    {
00269       return theReason;
00270    }
00271
00276    inline String Assertion::file() const
00277    {
00278       return theFile;
00279    }
00280
00285    inline int Assertion::line() const
00286    {
00287       return theLine;
00288    }
00289
00294    inline CharCptr Assertion::what() const
00295    {
00296       return reason().c_str();
00297    }
00298
00309    class DbcException : public Assertion
00310    {
00311    public:
00316       enum Type
00317       {
00318          REQUIRE,
00319          ENSURE,
00320          ASSERT,
00321          NEVERGETHERE,
00322       };
00323
00326
00327       DbcException( Type aType, CharCptr aDescription, CharCptr aExpression, CharCptr aFile, int aLine );
00328
00329       DbcException( DbcExceptionCref rhs );
00330
00331       virtual ~DbcException();
00332
00336
00337       DbcExceptionRef operator=( DbcExceptionCref rhs );
00338
00339       bool operator==( DbcExceptionCref rhs );
00340
00344
00345       virtual CharCptr what() const;
00346
00347       Type    type() const;
00348       String  description() const;
00349
00351
00352    private:
00353       Type    theType;
00354       String  theDescription;
00355       mutable String theMessage;
00356    };
00357
00362    inline DbcException::DbcException( DbcException::Type aType, CharCptr aDescription, CharCptr aExpression, CharCptr aFile, int aLine ):
00363       Assertion( aExpression, aFile, aLine ), theType( aType ), theDescription( aDescription )
00364    {
00365       ; // do nothing
00366    }
00367
00372    inline DbcException::DbcException( DbcExceptionCref rhs ):
00373       Assertion( rhs ), theType( rhs.type() ), theDescription( rhs.description() )
00374    {
00375       ; // do nothing
00376    }
00377
00382    inline DbcException::~DbcException()
00383    {
00384       ; // do nothing
00385    }
00386
00391    inline DbcExceptionRef DbcException::operator=( DbcExceptionCref rhs )
00392    {
00393       if( this != &rhs )
00394       {
00395          (void) Assertion::operator=( rhs );
00396          theType = rhs.type();
00397          theDescription = rhs.description();
00398       }
00399       else
00400       {
00401          ;  // do nothing
00402       }
00403
00404       return *this;
00405    }
00406
00411    inline bool DbcException::operator==( DbcExceptionCref rhs )
00412    {
00413       return Assertion::operator==( rhs ) &&
00414                          type() == rhs.type() &&
00415                   description() == rhs.description();
00416    }
00417
00422    inline DbcException::Type DbcException::type() const
00423    {
00424       return theType;
00425    }
00426
00431    inline String DbcException::description() const
00432    {
00433       return theDescription;
00434    }
00435
00444    class RequireException : public DbcException
00445    {
00446    public:
00448       RequireException( CharCptr aExpression, CharCptr aFile, int aLine ) :
00449          DbcException( REQUIRE, "require", aExpression, aFile, aLine ) { ; }
00450    };
00451
00460    class EnsureException : public DbcException
00461    {
00462    public:
00464       EnsureException( CharCptr aExpression, CharCptr aFile, int aLine ) :
00465          DbcException( ENSURE, "promised", aExpression, aFile, aLine ) { ; }
00466    };
00467
00476    class AssertException : public DbcException
00477    {
00478    public:
00480       AssertException( CharCptr aExpression, CharCptr aFile, int aLine ) :
00481          DbcException( ASSERT, "assert", aExpression, aFile, aLine ) { ; }
00482    };
00483
00493    class NeverGetHereException : public DbcException
00494    {
00495    public:
00497       NeverGetHereException( CharCptr aFile, int aLine ) :
00498          DbcException( NEVERGETHERE, "shall never get here", "", aFile, aLine ) { ; }
00499    };
00500
00501 } // namespace Rulbus
00502
00508 std::ostream& operator<<( std::ostream& stream, Rulbus::StdExceptionCref rhs );
00509
00510 #endif  // __ASSERTION_H
00511
00512 /*
00513  * end of file
00514  */
00515
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: canio.h Source File

canio.h

00001 /*
00002    canio.h - header for canIO DLL
00003
00004    See Also: http://cansoft.livewiredev.com/projects.htm
00005
00006    Rulbus device drivers for LabVIEW.
00007
00008    (C) Copyright 2002, by Universiteit Leiden.
00009
00010    $Revision: $
00011    $Date: $
00012    $Source: $
00013    %Author: M.J. Moene %
00014
00015    Compiler        : Borland-C++ 5.5.1
00016    Operating system: Windows 95/NT/2000
00017    Hardware system : PC XT, AT
00018 */
00019
00020 #ifndef __CANIO_H
00021 #define __CANIO_H
00022
00023 #include <windows.h>          // for BOOL, ULONG
00024
00121 #ifndef IMPORT
00122    #define IMPORT __declspec(dllimport)
00123 #endif
00124
00143 #define CANIO_API  __stdcall    // Pascal calling convention
00144
00145 /* -----------------------------------------------------------------------
00146  * CanIO DLL API functions
00147  * -----------------------------------------------------------------------
00148  */
00149
00162 extern "C" IMPORT BOOL CANIO_API AddMultiPort(ULONG base, int length);
00163
00166 #endif // __CANIO_H
00167
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Alphabetical index

Rulbus Device Class Library for Microsoft Windows Class Index

A
EppRulbusInterface (Rulbus) RequireException (Rulbus)
AssertException (Rulbus)
I
RulbusAddressError (Rulbus)
Assertion (Rulbus) IoFormat (Rulbus) RulbusCloseError (Rulbus)
B
IsaRulbusInterface (Rulbus) RulbusConfigError (Rulbus)
BoundIoFormat (Rulbus) isEqual (Rulbus) RulbusContextError (Rulbus)
C
N
RulbusDataError (Rulbus)
ConfigBuilder (Rulbus) NeverGetHereException (Rulbus) RulbusDevice (Rulbus)
ConfigContext (Rulbus)
P
RulbusDeviceFactory (Rulbus)
ConfigEofToken (Rulbus) Pia (Rulbus) RulbusDeviceProxy (Rulbus)
ConfigErrorToken (Rulbus) PiaVia (Rulbus) RulbusError (Rulbus)
ConfigKeyword (Rulbus) PportAddresses (Rulbus) RulbusHandleError (Rulbus)
ConfigListBuilder (Rulbus)
R
RulbusInterfaceError (Rulbus)
ConfigNumberToken (Rulbus) RB8506_Pia (Rulbus) RulbusInterfaceFactory (Rulbus)
ConfigParser (Rulbus) RB8506_Sifu (Rulbus) RulbusOpenError (Rulbus)
ConfigParser::ParseError (Rulbus) RB8506_Via (Rulbus) RulbusParseError (Rulbus)
ConfigPrinter (Rulbus) RB8509_Adc12 (Rulbus) RulbusRangeError (Rulbus)
ConfigScanner (Rulbus) RB8510_Dac12 (Rulbus) RulbusScanError (Rulbus)
ConfigSpecialToken (Rulbus) RB8513_timebase (Rulbus) RulbusTimeoutError (Rulbus)
ConfigStringToken (Rulbus) RB8514_delay (Rulbus)
S
ConfigToken (Rulbus) RB8515_clock (Rulbus) Singleton (Rulbus)
ConfigWordToken (Rulbus) RB8515_clock::FreqTable (Rulbus)
T
D
RB8905_Adc12 (Rulbus) TheRulbusDeviceList (Rulbus)
DbcException (Rulbus) RB9005_amplifier (Rulbus) TheRulbusInterface (Rulbus)
E
RB9005_amplifier::RegInfo (Rulbus)
V
EnsureException (Rulbus) RB9603_monochromator (Rulbus) Via (Rulbus)
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

AssertException Member List

This is the complete list of members for AssertException, including all inherited members.
ASSERT enum value (defined in DbcException) | DbcException |
AssertException(CharCptr aExpression, CharCptr aFile, int aLine) | AssertException | [inline]
Assertion(CharCptr aReason, CharCptr aFile, int aLine) | Assertion | [inline]
Assertion(AssertionCref rhs) | Assertion | [inline]
DbcException(Type aType, CharCptr aDescription, CharCptr aExpression, CharCptr aFile, int aLine) | DbcException | [inline]
DbcException(DbcExceptionCref rhs) | DbcException | [inline]
description() const | DbcException | [inline]
ENSURE enum value (defined in DbcException) | DbcException |
file() const | Assertion | [inline]
line() const | Assertion | [inline]
NEVERGETHERE enum value (defined in DbcException) | DbcException |
operator=(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator=(AssertionCref rhs) | Assertion | [inline]
operator==(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator==(AssertionCref rhs) | Assertion | [inline]
reason() const | Assertion | [inline]
REQUIRE enum value (defined in DbcException) | DbcException |
theFile | Assertion | [protected]
theLine | Assertion | [protected]
theReason | Assertion | [protected]
type() const | DbcException | [inline]
Type enum name | DbcException |
what() const | DbcException | [virtual]
~Assertion() | Assertion | [inline, virtual]
~DbcException() | DbcException | [inline, virtual]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

Assertion Member List

This is the complete list of members for Assertion, including all inherited members.
Assertion(CharCptr aReason, CharCptr aFile, int aLine) | Assertion | [inline]
Assertion(AssertionCref rhs) | Assertion | [inline]
file() const | Assertion | [inline]
line() const | Assertion | [inline]
operator=(AssertionCref rhs) | Assertion | [inline]
operator==(AssertionCref rhs) | Assertion | [inline]
reason() const | Assertion | [inline]
theFile | Assertion | [protected]
theLine | Assertion | [protected]
theReason | Assertion | [protected]
what() const | Assertion | [inline, virtual]
~Assertion() | Assertion | [inline, virtual]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

BoundIoFormat Member List

This is the complete list of members for BoundIoFormat, including all inherited members.
BoundIoFormat(const IoFormat< T > &f, const T &v) | BoundIoFormat | [inline]
theFormat | BoundIoFormat |
theValue | BoundIoFormat |
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigBuilder Member List

This is the complete list of members for ConfigBuilder, including all inherited members.
add(RulbusDevicePtr ptr)=0 | ConfigBuilder | [pure virtual]
check() const | ConfigBuilder | [inline, virtual]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigEofToken Member List

This is the complete list of members for ConfigEofToken, including all inherited members.
a enum value (defined in ConfigToken) | ConfigToken |
b enum value (defined in ConfigToken) | ConfigToken |
c enum value (defined in ConfigToken) | ConfigToken |
code() const | ConfigToken | [inline]
ConfigEofToken() (defined in ConfigEofToken) | ConfigEofToken | [inline]
ConfigToken() (defined in ConfigToken) | ConfigToken | [inline]
get(std::istream *is) | ConfigEofToken | [inline, virtual]
isAsnop() const | ConfigToken | [inline]
isBool() const | ConfigToken | [inline]
isCard() const | ConfigToken | [inline]
isDelim() const | ConfigToken | [inline]
isKind(TokenCode t) const | ConfigToken |
isUnit() const | ConfigToken | [inline]
print() const | ConfigEofToken | [virtual]
tcLAST enum value (defined in ConfigToken) | ConfigToken |
theIntValue | ConfigToken | [protected]
theRealValue | ConfigToken | [protected]
theString | ConfigToken | [protected]
theTokenCode | ConfigToken | [protected]
toBool() const | ConfigToken | [inline]
toInt() const | ConfigToken | [inline]
TokenCode enum name | ConfigToken |
tokenString() const | ConfigToken |
tokenString(TokenCode t) const | ConfigToken |
toReal() const | ConfigToken | [inline]
toString() const | ConfigToken | [inline]
~ConfigToken() (defined in ConfigToken) | ConfigToken | [inline, virtual]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigErrorToken Member List

This is the complete list of members for ConfigErrorToken, including all inherited members.
a enum value (defined in ConfigToken) | ConfigToken |
b enum value (defined in ConfigToken) | ConfigToken |
c enum value (defined in ConfigToken) | ConfigToken |
code() const | ConfigToken | [inline]
ConfigErrorToken() (defined in ConfigErrorToken) | ConfigErrorToken | [inline]
ConfigToken() (defined in ConfigToken) | ConfigToken | [inline]
get(std::istream *is) | ConfigErrorToken | [virtual]
isAsnop() const | ConfigToken | [inline]
isBool() const | ConfigToken | [inline]
isCard() const | ConfigToken | [inline]
isDelim() const | ConfigToken | [inline]
isKind(TokenCode t) const | ConfigToken |
isUnit() const | ConfigToken | [inline]
print() const | ConfigErrorToken | [virtual]
tcLAST enum value (defined in ConfigToken) | ConfigToken |
theIntValue | ConfigToken | [protected]
theRealValue | ConfigToken | [protected]
theString | ConfigToken | [protected]
theTokenCode | ConfigToken | [protected]
toBool() const | ConfigToken | [inline]
toInt() const | ConfigToken | [inline]
TokenCode enum name | ConfigToken |
tokenString() const | ConfigToken |
tokenString(TokenCode t) const | ConfigToken |
toReal() const | ConfigToken | [inline]
toString() const | ConfigToken | [inline]
~ConfigToken() (defined in ConfigToken) | ConfigToken | [inline, virtual]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigListBuilder Member List

This is the complete list of members for ConfigListBuilder, including all inherited members.
add(RulbusDevicePtr ptr) | ConfigListBuilder | [virtual]
check() const | ConfigListBuilder | [virtual]
ConfigListBuilder() | ConfigListBuilder |
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigNumberToken Member List

This is the complete list of members for ConfigNumberToken, including all inherited members.
a enum value (defined in ConfigToken) | ConfigToken |
b enum value (defined in ConfigToken) | ConfigToken |
c enum value (defined in ConfigToken) | ConfigToken |
code() const | ConfigToken | [inline]
ConfigNumberToken() (defined in ConfigNumberToken) | ConfigNumberToken | [inline]
ConfigToken() (defined in ConfigToken) | ConfigToken | [inline]
get(std::istream *is) | ConfigNumberToken | [virtual]
isAsnop() const | ConfigToken | [inline]
isBool() const | ConfigToken | [inline]
isCard() const | ConfigToken | [inline]
isDelim() const | ConfigToken | [inline]
isKind(TokenCode t) const | ConfigToken |
isUnit() const | ConfigToken | [inline]
print() const | ConfigNumberToken | [virtual]
suffix(char chr) (defined in ConfigNumberToken) | ConfigNumberToken | [protected]
tcLAST enum value (defined in ConfigToken) | ConfigToken |
theIntValue | ConfigToken | [protected]
theRealValue | ConfigToken | [protected]
theString | ConfigToken | [protected]
theTokenCode | ConfigToken | [protected]
toBool() const | ConfigToken | [inline]
toInt() const | ConfigToken | [inline]
TokenCode enum name | ConfigToken |
tokenString() const | ConfigToken |
tokenString(TokenCode t) const | ConfigToken |
toReal() const | ConfigToken | [inline]
toString() const | ConfigToken | [inline]
~ConfigToken() (defined in ConfigToken) | ConfigToken | [inline, virtual]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigParser Member List

This is the complete list of members for ConfigParser, including all inherited members.
addCard(RulbusDevicePtr card) | ConfigParser | [protected]
AddrList typedef | ConfigParser | [private]
already_assigned | ConfigParser | [private, static]
CardList typedef | ConfigParser | [private]
checkCardDeclarations() | ConfigParser | [protected]
checkDuplicateCardName() | ConfigParser | [protected]
checkDuplicateRackAddr(bool withline=false) | ConfigParser | [protected]
checkDuplicateRackName() | ConfigParser | [protected]
checkOverlapCardAddr(bool withline=false) | ConfigParser | [protected]
checkRackAllowed() | ConfigParser | [protected]
checkRackDeclaration() | ConfigParser | [protected]
clearRackCardList() | ConfigParser | [protected]
ConfigParser(ConfigScanner &scanner, ConfigBuilder &builder, ConfigContext &context) | ConfigParser |
DEF_CARDS (defined in ConfigParser) | ConfigParser | [private, static]
expect(ConfigToken::TokenCode token, bool require=true) | ConfigParser | [protected]
getToken() | ConfigParser | [protected]
LIM_RACKS | ConfigParser | [private, static]
LineList typedef | ConfigParser | [private]
NameList typedef | ConfigParser | [private]
parse() | ConfigParser |
parseAddress(ConfigToken::TokenCode token=ConfigToken::tcCARD) | ConfigParser | [protected]
parseBipolar() | ConfigParser | [protected]
parseBooleanProperty(ConfigToken::TokenCode token) | ConfigParser | [protected]
parseCardDeclaration() | ConfigParser | [protected]
parseCardDeclarationSequence() | ConfigParser | [protected]
parseCardInitializer(ConfigToken::TokenCode card) | ConfigParser | [protected]
parseFileAssignment() | ConfigParser | [protected]
parseGenericCard(ConfigToken::TokenCode card, bool scanProperties=true) | ConfigParser | [protected]
parseHasExtTrigger() | ConfigParser | [protected]
parseIntegerProperty(ConfigToken::TokenCode token) | ConfigParser | [protected]
parseIntrDelay() | ConfigParser | [protected]
parseNumChannels() | ConfigParser | [protected]
parseOptAssignOp() | ConfigParser | [protected]
parseOptDelimiter() | ConfigParser | [protected]
parseOptUnit(ConfigToken::TokenCode token) | ConfigParser | [protected]
parseProgram() | ConfigParser | [protected]
parseRackAddressAssignment() | ConfigParser | [protected]
parseRackDeclaration() | ConfigParser | [protected]
parseRackDeclarationSequence() | ConfigParser | [protected]
parseRackInitializer() | ConfigParser | [protected]
parseRB8509(bool scanProperties=true) | ConfigParser | [protected]
parseRB8510(bool scanProperties=true) | ConfigParser | [protected]
parseRB8514(bool scanProperties=true) | ConfigParser | [protected]
parseRB8905(bool scanProperties=true) | ConfigParser | [protected]
parseRealProperty(ConfigToken::TokenCode token) | ConfigParser | [protected]
parseVoltPerBit() | ConfigParser | [protected]
t | ConfigParser | [private]
test(ConfigToken::TokenCode token, bool require=true) | ConfigParser | [protected]
theBuilder | ConfigParser | [private]
theCardAddress | ConfigParser | [private]
theCardLineList | ConfigParser | [private]
theCardList | ConfigParser | [private]
theCardName | ConfigParser | [private]
theCardNameList | ConfigParser | [private]
theContext | ConfigParser | [private]
theRackAddress | ConfigParser | [private]
theRackAddrSet | ConfigParser | [private]
theRackCardList | ConfigParser | [private]
theRackLine | ConfigParser | [private]
theRackLineSet | ConfigParser | [private]
theRackName | ConfigParser | [private]
theRackNameSet | ConfigParser | [private]
theScanner | ConfigParser | [private]
theToken | ConfigParser | [private]
updateRackCardList() | ConfigParser | [protected]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigParser::ParseError Member List

This is the complete list of members for ConfigParser::ParseError, including all inherited members.
ParseError(StringCref msg) ConfigParser::ParseError [inline]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigPrinter Member List

This is the complete list of members for ConfigPrinter, including all inherited members.
add(RulbusDevicePtr ptr) | ConfigPrinter | [virtual]
check() const | ConfigBuilder | [inline, virtual]
ConfigPrinter(std::ostream &aStream) | ConfigPrinter |
theStream | ConfigPrinter | [private]
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigScanner Member List

This is the complete list of members for ConfigScanner, including all inherited members.
ConfigScanner(std::istream &stream, String aFilename="") | ConfigScanner |
eofToken | ConfigScanner | [protected]
errorToken | ConfigScanner | [protected]
filename() const | ConfigScanner | [inline]
get() | ConfigScanner |
is | ConfigScanner | [private]
linenumber() const | ConfigScanner | [inline]
numberToken | ConfigScanner | [protected]
seechar(char &chr) | ConfigScanner | [protected]
skipWhitespace() | ConfigScanner | [protected]
specialToken | ConfigScanner | [protected]
stringToken | ConfigScanner | [protected]
theFilename | ConfigScanner | [private]
theLinenumber | ConfigScanner | [private]
wordToken | ConfigScanner | [protected]
~ConfigScanner() | ConfigScanner | [virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigSpecialToken Member List

This is the complete list of members for ConfigSpecialToken, including all inherited members.
a enum value (defined in ConfigToken) | ConfigToken |
b enum value (defined in ConfigToken) | ConfigToken |
c enum value (defined in ConfigToken) | ConfigToken |
code() const | ConfigToken | [inline]
ConfigToken() (defined in ConfigToken) | ConfigToken | [inline]
get(std::istream *is) | ConfigSpecialToken | [virtual]
isAsnop() const | ConfigToken | [inline]
isBool() const | ConfigToken | [inline]
isCard() const | ConfigToken | [inline]
isDelim() const | ConfigToken | [inline]
isKind(TokenCode t) const | ConfigToken |
isUnit() const | ConfigToken | [inline]
print() const | ConfigSpecialToken | [virtual]
tcLAST enum value (defined in ConfigToken) | ConfigToken |
theIntValue | ConfigToken | [protected]
theRealValue | ConfigToken | [protected]
theString | ConfigToken | [protected]
theTokenCode | ConfigToken | [protected]
toBool() const | ConfigToken | [inline]
toInt() const | ConfigToken | [inline]
TokenCode enum name | ConfigToken |
tokenString() const | ConfigToken |
tokenString(TokenCode t) const | ConfigToken |
toReal() const | ConfigToken | [inline]
toString() const | ConfigToken | [inline]
~ConfigToken() (defined in ConfigToken) | ConfigToken | [inline, virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigStringToken Member List

This is the complete list of members for ConfigStringToken, including all inherited members.
a enum value (defined in ConfigToken) | ConfigToken |
b enum value (defined in ConfigToken) | ConfigToken |
c enum value (defined in ConfigToken) | ConfigToken |
code() const | ConfigToken | [inline]
ConfigStringToken() (defined in ConfigStringToken) | ConfigStringToken | [inline]
ConfigToken() (defined in ConfigToken) | ConfigToken | [inline]
get(std::istream *is) | ConfigStringToken | [virtual]
isAsnop() const | ConfigToken | [inline]
isBool() const | ConfigToken | [inline]
isCard() const | ConfigToken | [inline]
isDelim() const | ConfigToken | [inline]
isKind(TokenCode t) const | ConfigToken |
isUnit() const | ConfigToken | [inline]
print() const | ConfigStringToken | [virtual]
tcLAST enum value (defined in ConfigToken) | ConfigToken |
theIntValue | ConfigToken | [protected]
theRealValue | ConfigToken | [protected]
theString | ConfigToken | [protected]
theTokenCode | ConfigToken | [protected]
toBool() const | ConfigToken | [inline]
toInt() const | ConfigToken | [inline]
TokenCode enum name | ConfigToken |
tokenString() const | ConfigToken |
tokenString(TokenCode t) const | ConfigToken |
toReal() const | ConfigToken | [inline]
toString() const | ConfigToken | [inline]
~ConfigToken() (defined in ConfigToken) | ConfigToken | [inline, virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigToken Member List

This is the complete list of members for ConfigToken, including all inherited members.
a enum value (defined in ConfigToken) | ConfigToken |
b enum value (defined in ConfigToken) | ConfigToken |
c enum value (defined in ConfigToken) | ConfigToken |
code() const | ConfigToken | [inline]
ConfigToken() (defined in ConfigToken) | ConfigToken | [inline]
get(std::istream *is)=0 | ConfigToken | [pure virtual]
isAsnop() const | ConfigToken | [inline]
isBool() const | ConfigToken | [inline]
isCard() const | ConfigToken | [inline]
isDelim() const | ConfigToken | [inline]
isKind(TokenCode t) const | ConfigToken |
isUnit() const | ConfigToken | [inline]
kindTable | ConfigToken | [private, static]
print() const =0 | ConfigToken | [pure virtual]
stringTable | ConfigToken | [private, static]
tcLAST enum value (defined in ConfigToken) | ConfigToken |
theIntValue | ConfigToken | [protected]
theRealValue | ConfigToken | [protected]
theString | ConfigToken | [protected]
theTokenCode | ConfigToken | [protected]
toBool() const | ConfigToken | [inline]
toInt() const | ConfigToken | [inline]
TokenCode enum name | ConfigToken |
tokenString() const | ConfigToken |
tokenString(TokenCode t) const | ConfigToken |
toReal() const | ConfigToken | [inline]
toString() const | ConfigToken | [inline]
~ConfigToken() (defined in ConfigToken) | ConfigToken | [inline, virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigWordToken Member List

This is the complete list of members for ConfigWordToken, including all inherited members.
a enum value (defined in ConfigToken) | ConfigToken |
b enum value (defined in ConfigToken) | ConfigToken |
c enum value (defined in ConfigToken) | ConfigToken |
code() const | ConfigToken | [inline]
ConfigToken() (defined in ConfigToken) | ConfigToken | [inline]
get(std::istream *is) | ConfigWordToken | [virtual]
isAsnop() const | ConfigToken | [inline]
isBool() const | ConfigToken | [inline]
isCard() const | ConfigToken | [inline]
isDelim() const | ConfigToken | [inline]
isKind(TokenCode t) const | ConfigToken |
isUnit() const | ConfigToken | [inline]
print() const | ConfigWordToken | [virtual]
tcLAST enum value (defined in ConfigToken) | ConfigToken |
theIntValue | ConfigToken | [protected]
theRealValue | ConfigToken | [protected]
theString | ConfigToken | [protected]
theTokenCode | ConfigToken | [protected]
toBool() const | ConfigToken | [inline]
toInt() const | ConfigToken | [inline]
TokenCode enum name | ConfigToken |
tokenString() const | ConfigToken |
tokenString(TokenCode t) const | ConfigToken |
toReal() const | ConfigToken | [inline]
toString() const | ConfigToken | [inline]
~ConfigToken() (defined in ConfigToken) | ConfigToken | [inline, virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

DbcException Member List

This is the complete list of members for DbcException, including all inherited members.
ASSERT enum value (defined in DbcException) | DbcException |
Assertion(CharCptr aReason, CharCptr aFile, int aLine) | Assertion | [inline]
Assertion(AssertionCref rhs) | Assertion | [inline]
DbcException(Type aType, CharCptr aDescription, CharCptr aExpression, CharCptr aFile, int aLine) | DbcException | [inline]
DbcException(DbcExceptionCref rhs) | DbcException | [inline]
description() const | DbcException | [inline]
ENSURE enum value (defined in DbcException) | DbcException |
file() const | Assertion | [inline]
line() const | Assertion | [inline]
NEVERGETHERE enum value (defined in DbcException) | DbcException |
operator=(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator=(AssertionCref rhs) | Assertion | [inline]
operator==(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator==(AssertionCref rhs) | Assertion | [inline]
reason() const | Assertion | [inline]
REQUIRE enum value (defined in DbcException) | DbcException |
theDescription | DbcException | [private]
theFile | Assertion | [protected]
theLine | Assertion | [protected]
theMessage | DbcException | [mutable, private]
theReason | Assertion | [protected]
theType | DbcException | [private]
type() const | DbcException | [inline]
Type enum name | DbcException |
what() const | DbcException | [virtual]
~Assertion() | Assertion | [inline, virtual]
~DbcException() | DbcException | [inline, virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

EnsureException Member List

This is the complete list of members for EnsureException, including all inherited members.
ASSERT enum value (defined in DbcException) | DbcException |
Assertion(CharCptr aReason, CharCptr aFile, int aLine) | Assertion | [inline]
Assertion(AssertionCref rhs) | Assertion | [inline]
DbcException(Type aType, CharCptr aDescription, CharCptr aExpression, CharCptr aFile, int aLine) | DbcException | [inline]
DbcException(DbcExceptionCref rhs) | DbcException | [inline]
description() const | DbcException | [inline]
ENSURE enum value (defined in DbcException) | DbcException |
EnsureException(CharCptr aExpression, CharCptr aFile, int aLine) | EnsureException | [inline]
file() const | Assertion | [inline]
line() const | Assertion | [inline]
NEVERGETHERE enum value (defined in DbcException) | DbcException |
operator=(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator=(AssertionCref rhs) | Assertion | [inline]
operator==(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator==(AssertionCref rhs) | Assertion | [inline]
reason() const | Assertion | [inline]
REQUIRE enum value (defined in DbcException) | DbcException |
theFile | Assertion | [protected]
theLine | Assertion | [protected]
theReason | Assertion | [protected]
type() const | DbcException | [inline]
Type enum name | DbcException |
what() const | DbcException | [virtual]
~Assertion() | Assertion | [inline, virtual]
~DbcException() | DbcException | [inline, virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

EppRulbusInterface Member List

This is the complete list of members for EppRulbusInterface, including all inherited members.
ANY_RACK | TheRulbusInterface | [static]
base() const | EppRulbusInterface | [inline]
clearEppTimeout() const | EppRulbusInterface | [inline, protected]
DEF_EPP_BASE | EppRulbusInterface | [static]
EppRulbusInterface(Quad base=DEF_EPP_BASE, bool docheck=true) | EppRulbusInterface |
EppRulbusInterface(EppRulbusInterfaceRef) | EppRulbusInterface | [protected]
EppTimedOut() const | EppRulbusInterface | [inline, protected]
getByte(int rack, int offset) const | TheRulbusInterface |
getReg(int offset) const | EppRulbusInterface | [protected, virtual]
initializeEpp() const | EppRulbusInterface | [protected]
instance() | TheRulbusInterface | [inline, static]
interfacePresent(int *pCode) const | EppRulbusInterface | [protected]
invariant() const | EppRulbusInterface | [inline, virtual]
msgtitle | EppRulbusInterface | [private, static]
MSK_EPP_Timeout | EppRulbusInterface | [private, static]
MSK_SPP_AutoLF | EppRulbusInterface | [private, static]
MSK_SPP_EnaBiDirect | EppRulbusInterface | [private, static]
MSK_SPP_EnaIRQVAL | EppRulbusInterface | [private, static]
MSK_SPP_nAck | EppRulbusInterface | [private, static]
MSK_SPP_nBusy | EppRulbusInterface | [private, static]
MSK_SPP_nError | EppRulbusInterface | [private, static]
MSK_SPP_nIRQ | EppRulbusInterface | [private, static]
MSK_SPP_nReset | EppRulbusInterface | [private, static]
MSK_SPP_PaperOut | EppRulbusInterface | [private, static]
MSK_SPP_Reserved2 | EppRulbusInterface | [private, static]
MSK_SPP_SelectIn | EppRulbusInterface | [private, static]
MSK_SPP_SelectPrinter | EppRulbusInterface | [private, static]
MSK_SPP_Strobe | EppRulbusInterface | [private, static]
MSK_SPP_Unused1 | EppRulbusInterface | [private, static]
MSK_SPP_Unused2 | EppRulbusInterface | [private, static]
OFF_EPP_ADDR | EppRulbusInterface | [private, static]
OFF_EPP_DATA | EppRulbusInterface | [private, static]
OFF_SPP_CTRL | EppRulbusInterface | [private, static]
OFF_SPP_DATA | EppRulbusInterface | [private, static]
OFF_SPP_STAT | EppRulbusInterface | [private, static]
operator=(EppRulbusInterfaceRef) | EppRulbusInterface | [protected]
printOn(std::ostream &stream) const | EppRulbusInterface | [virtual]
putByte(int rack, int offset, int byte) const | TheRulbusInterface |
putReg(int offset, int byte) const | EppRulbusInterface | [protected, virtual]
readAddress() const | EppRulbusInterface | [inline, protected]
readData() const | EppRulbusInterface | [inline, protected]
resetInterface() const | EppRulbusInterface | [protected]
theBase | EppRulbusInterface | [private]
theInstance | Singleton< TheRulbusInterface > | [protected, static]
TheRulbusInterface() | TheRulbusInterface | [protected]
writeAddress(int addr) const | EppRulbusInterface | [inline, protected]
writeData(int byte) const | EppRulbusInterface | [inline, protected]
~TheRulbusInterface() | TheRulbusInterface | [protected]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

IoFormat Member List

This is the complete list of members for IoFormat, including all inherited members.
boolalpha(bool alpha=true) | IoFormat | [inline]
dec() | IoFormat | [inline]
fill() const | IoFormat | [inline]
fill(int c= ' ') | IoFormat | [inline]
fixed() | IoFormat | [inline]
flags() const | IoFormat | [inline]
fmtflags typedef | IoFormat |
general() | IoFormat | [inline]
hex() | IoFormat | [inline]
internal() | IoFormat | [inline]
IoFormat(int precision=6) | IoFormat | [inline, explicit]
left() | IoFormat | [inline]
oct() | IoFormat | [inline]
operator()(const T &d) const | IoFormat | [inline]
precision() const | IoFormat | [inline]
precision(int p) | IoFormat | [inline]
right() | IoFormat | [inline]
scientific() | IoFormat | [inline]
setf(fmtflags f) | IoFormat | [inline, protected]
setf(fmtflags f, fmtflags msk) | IoFormat | [inline, protected]
showbase(bool show=true) | IoFormat | [inline]
showplus(bool show=true) | IoFormat | [inline]
showpoint(bool show=true) | IoFormat | [inline]
theFillChar | IoFormat | [private]
theFlags | IoFormat | [private]
thePrecision | IoFormat | [private]
theWidth | IoFormat | [private]
unsetf(fmtflags msk=~0) | IoFormat | [inline, protected]
uppercase(bool upper=true) | IoFormat | [inline]
width() const | IoFormat | [inline]
width(int w) | IoFormat | [inline]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

IsaRulbusInterface Member List

This is the complete list of members for IsaRulbusInterface, including all inherited members.
ANY_RACK | TheRulbusInterface | [static]
base() const | IsaRulbusInterface | [inline]
baseMax | IsaRulbusInterface | [private, static]
baseMin | IsaRulbusInterface | [private, static]
baseStp | IsaRulbusInterface | [private, static]
DEF_ISA_BASE | IsaRulbusInterface | [static]
getByte(int rack, int offset) const | TheRulbusInterface |
getReg(int offset) const | IsaRulbusInterface | [protected, virtual]
instance() | TheRulbusInterface | [inline, static]
invariant() const | IsaRulbusInterface | [inline, virtual]
IsaRulbusInterface(long aBase=DEF_ISA_BASE) | IsaRulbusInterface |
IsaRulbusInterface(IsaRulbusInterfaceRef) | IsaRulbusInterface | [protected]
msgtitle | IsaRulbusInterface | [private, static]
operator=(IsaRulbusInterfaceRef) | IsaRulbusInterface | [protected]
printOn(std::ostream &stream) const | IsaRulbusInterface | [virtual]
putByte(int rack, int offset, int byte) const | TheRulbusInterface |
putReg(int offset, int byte) const | IsaRulbusInterface | [protected, virtual]
theBase | IsaRulbusInterface | [private]
theInstance | Singleton< TheRulbusInterface > | [protected, static]
TheRulbusInterface() | TheRulbusInterface | [protected]
validBase(long base) const | IsaRulbusInterface | [protected]
~TheRulbusInterface() | TheRulbusInterface | [protected]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

NeverGetHereException Member List

This is the complete list of members for NeverGetHereException, including all inherited members.
ASSERT enum value (defined in DbcException) | DbcException |
Assertion(CharCptr aReason, CharCptr aFile, int aLine) | Assertion | [inline]
Assertion(AssertionCref rhs) | Assertion | [inline]
DbcException(Type aType, CharCptr aDescription, CharCptr aExpression, CharCptr aFile, int aLine) | DbcException | [inline]
DbcException(DbcExceptionCref rhs) | DbcException | [inline]
description() const | DbcException | [inline]
ENSURE enum value (defined in DbcException) | DbcException |
file() const | Assertion | [inline]
line() const | Assertion | [inline]
NEVERGETHERE enum value (defined in DbcException) | DbcException |
NeverGetHereException(CharCptr aFile, int aLine) | NeverGetHereException | [inline]
operator=(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator=(AssertionCref rhs) | Assertion | [inline]
operator==(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator==(AssertionCref rhs) | Assertion | [inline]
reason() const | Assertion | [inline]
REQUIRE enum value (defined in DbcException) | DbcException |
theFile | Assertion | [protected]
theLine | Assertion | [protected]
theReason | Assertion | [protected]
type() const | DbcException | [inline]
Type enum name | DbcException |
what() const | DbcException | [virtual]
~Assertion() | Assertion | [inline, virtual]
~DbcException() | DbcException | [inline, virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

Pia Member List

This is the complete list of members for Pia, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | Pia | [private, static]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkData(int dat) | PiaVia | [protected]
checkDir(char dir) | PiaVia | [protected]
checkMask(int msk) | PiaVia | [protected]
checkPin(int pin) | PiaVia | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
DEF_ADDR | Pia | [static]
DEF_RACK | Pia | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getDataPA() | PiaVia | [virtual]
getDataPB() | PiaVia | [virtual]
getDDRA() | Pia | [protected, virtual]
getDDRB() | Pia | [protected, virtual]
getDirC2(int offset) | Pia | [private]
getDirCA2() | Pia | [virtual]
getDirCB2() | Pia | [virtual]
getDirPA() | PiaVia | [virtual]
getDirPB() | PiaVia | [virtual]
getEdgeC1(int offset) | Pia | [private]
getEdgeCA1() | Pia | [virtual]
getEdgeCB1() | Pia | [virtual]
getIntrC1(int offset) | Pia | [private]
getIntrCA1() | Pia | [virtual]
getIntrCB1() | Pia | [virtual]
getIrqC1(int offset) | Pia | [private]
getIrqCA1() | Pia | [virtual]
getIrqCB1() | Pia | [virtual]
getLevelC2(int offset) | Pia | [private]
getLevelCA2() | Pia | [virtual]
getLevelCB2() | Pia | [virtual]
getLineDir(CharCptr lin) | PiaVia | [virtual]
getLineDirPA(int pin) | PiaVia | [virtual]
getLineDirPB(int pin) | PiaVia | [virtual]
getLineLevel(CharCptr lin) | PiaVia | [virtual]
getLineLevelPA(int pin) | PiaVia | [virtual]
getLineLevelPB(int pin) | PiaVia | [virtual]
getPDRA() | Pia | [protected, virtual]
getPDRB() | Pia | [protected, virtual]
getPortData(CharCptr ptr) | PiaVia | [virtual]
getPortDir(CharCptr prt) | PiaVia | [virtual]
MSK_ATC1 | Pia | [private, static]
MSK_ATC2 | Pia | [private, static]
MSK_DIRC2 | Pia | [private, static]
MSK_EIC1 | Pia | [private, static]
MSK_EIC2 | Pia | [private, static]
MSK_IRQ1 | Pia | [private, static]
MSK_IRQ2 | Pia | [private, static]
MSK_OLC2 | Pia | [private, static]
MSK_POC2 | Pia | [private, static]
MSK_SPDR | Pia | [private, static]
name() const | RulbusDevice | [inline]
OFF_CRA | Pia | [private, static]
OFF_CRB | Pia | [private, static]
OFF_DDRA | Pia | [private, static]
OFF_DDRB | Pia | [private, static]
OFF_PDRA | Pia | [private, static]
OFF_PDRB | Pia | [private, static]
operator=(RulbusDeviceCref) | RulbusDevice | [protected]
Pia(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK) | Pia | [inline]
PiaVia(NameCref aName, Addr aAddr, Addr aWidth, Rack aRack) (defined in PiaVia) | PiaVia | [inline]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
select_ddra() | Pia | [private]
select_ddrb() | Pia | [private]
select_pdra() | Pia | [private]
select_pdrb() | Pia | [private]
setAddr(Addr aAddr) | RulbusDevice |
setDataPA(int dat) | PiaVia | [virtual]
setDataPB(int dat) | PiaVia | [virtual]
setDDRA(int dir) | Pia | [protected, virtual]
setDDRB(int dir) | Pia | [protected, virtual]
setDirC2(int offset, char dir, char port) | Pia | [private]
setDirCA2(char dir) | Pia | [virtual]
setDirCB2(char dir) | Pia | [virtual]
setDirPA(int msk) | PiaVia | [virtual]
setDirPB(int msk) | PiaVia | [virtual]
setEdgeC1(int offset, char edge, char port) | Pia | [private]
setEdgeCA1(char edge) | Pia | [virtual]
setEdgeCB1(char edge) | Pia | [virtual]
setIntrC1(int offset, int enable) | Pia | [private]
setIntrCA1(int enable) | Pia | [virtual]
setIntrCB1(int enable) | Pia | [virtual]
setLevelC2(int offset, int lvl, char port) | Pia | [private]
setLevelCA2(int lvl) | Pia | [virtual]
setLevelCB2(int lvl) | Pia | [virtual]
setLineDir(CharCptr lin, char dir) | PiaVia | [virtual]
setLineDirPA(int pin, char dir) | PiaVia | [virtual]
setLineDirPB(int pin, char dir) | PiaVia | [virtual]
setLineLevel(CharCptr lin, int lvl) | PiaVia | [virtual]
setLineLevelPA(int pin, int lvl) | PiaVia | [virtual]
setLineLevelPB(int pin, int lvl) | PiaVia | [virtual]
setPDRA(int dat) | Pia | [protected, virtual]
setPDRB(int dat) | Pia | [protected, virtual]
setPortData(CharCptr prt, int dat) | PiaVia | [virtual]
setPortDir(CharCptr prt, int msk) | PiaVia | [virtual]
setRack(Rack aRack) | RulbusDevice |
theRulbus() | RulbusDevice | [inline, protected, static]
width() const | RulbusDevice | [inline]
~Pia() | Pia | [inline, virtual]
~PiaVia() | PiaVia | [inline, virtual]
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

PiaVia Member List

This is the complete list of members for PiaVia, including all inherited members.
addr() const | RulbusDevice | [inline]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkData(int dat) | PiaVia | [protected]
checkDir(char dir) | PiaVia | [protected]
checkMask(int msk) | PiaVia | [protected]
checkPin(int pin) | PiaVia | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
DEF_RACK | RulbusDevice | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getDataPA() | PiaVia | [virtual]
getDataPB() | PiaVia | [virtual]
getDDRA()=0 | PiaVia | [protected, pure virtual]
getDDRB()=0 | PiaVia | [protected, pure virtual]
getDirCA2()=0 | PiaVia | [pure virtual]
getDirCB2()=0 | PiaVia | [pure virtual]
getDirPA() | PiaVia | [virtual]
getDirPB() | PiaVia | [virtual]
getEdgeCA1()=0 | PiaVia | [pure virtual]
getEdgeCB1()=0 | PiaVia | [pure virtual]
getIntrCA1()=0 | PiaVia | [pure virtual]
getIntrCB1()=0 | PiaVia | [pure virtual]
getIrqCA1()=0 | PiaVia | [pure virtual]
getIrqCB1()=0 | PiaVia | [pure virtual]
getLevelCA2()=0 | PiaVia | [pure virtual]
getLevelCB2()=0 | PiaVia | [pure virtual]
getLineDir(CharCptr lin) | PiaVia | [virtual]
getLineDirPA(int pin) | PiaVia | [virtual]
getLineDirPB(int pin) | PiaVia | [virtual]
getLineLevel(CharCptr lin) | PiaVia | [virtual]
getLineLevelPA(int pin) | PiaVia | [virtual]
getLineLevelPB(int pin) | PiaVia | [virtual]
getPDRA()=0 | PiaVia | [protected, pure virtual]
getPDRB()=0 | PiaVia | [protected, pure virtual]
getPortData(CharCptr ptr) | PiaVia | [virtual]
getPortDir(CharCptr prt) | PiaVia | [virtual]
name() const | RulbusDevice | [inline]
operator=(RulbusDeviceCref) | RulbusDevice | [protected]
PiaVia(NameCref aName, Addr aAddr, Addr aWidth, Rack aRack) (defined in PiaVia) | PiaVia | [inline]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setDataPA(int dat) | PiaVia | [virtual]
setDataPB(int dat) | PiaVia | [virtual]
setDDRA(int dir)=0 | PiaVia | [protected, pure virtual]
setDDRB(int dir)=0 | PiaVia | [protected, pure virtual]
setDirCA2(char dir)=0 | PiaVia | [pure virtual]
setDirCB2(char dir)=0 | PiaVia | [pure virtual]
setDirPA(int msk) | PiaVia | [virtual]
setDirPB(int msk) | PiaVia | [virtual]
setEdgeCA1(char edge)=0 | PiaVia | [pure virtual]
setEdgeCB1(char edge)=0 | PiaVia | [pure virtual]
setIntrCA1(int enable)=0 | PiaVia | [pure virtual]
setIntrCB1(int enable)=0 | PiaVia | [pure virtual]
setLevelCA2(int lvl)=0 | PiaVia | [pure virtual]
setLevelCB2(int lvl)=0 | PiaVia | [pure virtual]
setLineDir(CharCptr lin, char dir) | PiaVia | [virtual]
setLineDirPA(int pin, char dir) | PiaVia | [virtual]
setLineDirPB(int pin, char dir) | PiaVia | [virtual]
setLineLevel(CharCptr lin, int lvl) | PiaVia | [virtual]
setLineLevelPA(int pin, int lvl) | PiaVia | [virtual]
setLineLevelPB(int pin, int lvl) | PiaVia | [virtual]
setPDRA(int dat)=0 | PiaVia | [protected, pure virtual]
setPDRB(int dat)=0 | PiaVia | [protected, pure virtual]
setPortData(CharCptr prt, int dat) | PiaVia | [virtual]
setPortDir(CharCptr prt, int msk) | PiaVia | [virtual]
setRack(Rack aRack) | RulbusDevice |
theRulbus() | RulbusDevice | [inline, protected, static]
width() const | RulbusDevice | [inline]
~PiaVia() | PiaVia | [inline, virtual]
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

PportAddresses Member List

This is the complete list of members for PportAddresses, including all inherited members.
basePCIMax | PportAddresses | [private, static]
basePCIMin | PportAddresses | [private, static]
basePCIStp | PportAddresses | [private, static]
begin() const | PportAddresses |
const_iterator typedef | PportAddresses |
end() const | PportAddresses |
isValid(Quad base) const | PportAddresses |
kPportAddresses | PportAddresses | [private, static]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8506_Pia Member List

This is the complete list of members for RB8506_Pia, including all inherited members.
addr() const | RulbusDevice | [inline]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkData(int dat) | PiaVia | [protected]
checkDir(char dir) | PiaVia | [protected]
checkMask(int msk) | PiaVia | [protected]
checkPin(int pin) | PiaVia | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
DEF_ADDR | Pia | [static]
DEF_RACK | Pia | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getDataPA() | PiaVia | [virtual]
getDataPB() | PiaVia | [virtual]
getDDRA() | Pia | [protected, virtual]
getDDRB() | Pia | [protected, virtual]
getDirCA2() | Pia | [virtual]
getDirCB2() | Pia | [virtual]
getDirPA() | PiaVia | [virtual]
getDirPB() | PiaVia | [virtual]
getEdgeCA1() | Pia | [virtual]
getEdgeCB1() | Pia | [virtual]
getIntrCA1() | Pia | [virtual]
getIntrCB1() | Pia | [virtual]
getIrqCA1() | Pia | [virtual]
getIrqCB1() | Pia | [virtual]
getLevelCA2() | Pia | [virtual]
getLevelCB2() | Pia | [virtual]
getLineDir(CharCptr lin) | PiaVia | [virtual]
getLineDirPA(int pin) | PiaVia | [virtual]
getLineDirPB(int pin) | PiaVia | [virtual]
getLineLevel(CharCptr lin) | PiaVia | [virtual]
getLineLevelPA(int pin) | PiaVia | [virtual]
getLineLevelPB(int pin) | PiaVia | [virtual]
getPDRA() | Pia | [protected, virtual]
getPDRB() | Pia | [protected, virtual]
getPortData(CharCptr ptr) | PiaVia | [virtual]
getPortDir(CharCptr prt) | PiaVia | [virtual]
name() const | RulbusDevice | [inline]
operator=(RulbusDeviceCref) | RulbusDevice | [protected]
Pia(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK) | Pia | [inline]
PiaVia(NameCref aName, Addr aAddr, Addr aWidth, Rack aRack) (defined in PiaVia) | PiaVia | [inline]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB8506_Pia(NameCref name, Addr addr=Pia::DEF_ADDR, Rack rack=Pia::DEF_RACK) | RB8506_Pia | [inline]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setDataPA(int dat) | PiaVia | [virtual]
setDataPB(int dat) | PiaVia | [virtual]
setDDRA(int dir) | Pia | [protected, virtual]
setDDRB(int dir) | Pia | [protected, virtual]
setDirCA2(char dir) | Pia | [virtual]
setDirCB2(char dir) | Pia | [virtual]
setDirPA(int msk) | PiaVia | [virtual]
setDirPB(int msk) | PiaVia | [virtual]
setEdgeCA1(char edge) | Pia | [virtual]
setEdgeCB1(char edge) | Pia | [virtual]
setIntrCA1(int enable) | Pia | [virtual]
setIntrCB1(int enable) | Pia | [virtual]
setLevelCA2(int lvl) | Pia | [virtual]
setLevelCB2(int lvl) | Pia | [virtual]
setLineDir(CharCptr lin, char dir) | PiaVia | [virtual]
setLineDirPA(int pin, char dir) | PiaVia | [virtual]
setLineDirPB(int pin, char dir) | PiaVia | [virtual]
setLineLevel(CharCptr lin, int lvl) | PiaVia | [virtual]
setLineLevelPA(int pin, int lvl) | PiaVia | [virtual]
setLineLevelPB(int pin, int lvl) | PiaVia | [virtual]
setPDRA(int dat) | Pia | [protected, virtual]
setPDRB(int dat) | Pia | [protected, virtual]
setPortData(CharCptr prt, int dat) | PiaVia | [virtual]
setPortDir(CharCptr prt, int msk) | PiaVia | [virtual]
setRack(Rack aRack) | RulbusDevice |
theRulbus() | RulbusDevice | [inline, protected, static]
width() const | RulbusDevice | [inline]
~Pia() | Pia | [inline, virtual]
~PiaVia() | PiaVia | [inline, virtual]
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8506_Sifu Member List

This is the complete list of members for RB8506_Sifu, including all inherited members.
addr() const | RulbusDevice | [inline]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkData(int dat) | PiaVia | [protected]
checkDir(char dir) | PiaVia | [protected]
checkMask(int msk) | PiaVia | [protected]
checkPin(int pin) | PiaVia | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
clearFlipFlops() | RB8506_Sifu | [inline, protected]
DEF_ADDR | RB8506_Sifu | [static]
DEF_DIRCA2 | RB8506_Sifu | [static]
DEF_DIRCB2 | RB8506_Sifu | [static]
DEF_DIRPA | RB8506_Sifu | [static]
DEF_DIRPB | RB8506_Sifu | [static]
DEF_EDGECB1 | RB8506_Sifu | [static]
DEF_INTRCB1 | RB8506_Sifu | [static]
DEF_LVLCA2 | RB8506_Sifu | [static]
DEF_LVLCB2 | RB8506_Sifu | [static]
DEF_OUTDATA | RB8506_Sifu | [static]
DEF_RACK | Pia | [static]
enablePulseOutputs(bool enable=true) | RB8506_Sifu | [inline]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getDataPA() | PiaVia | [virtual]
getDataPB() | PiaVia | [virtual]
getDDRA() | Pia | [protected, virtual]
getDDRB() | Pia | [protected, virtual]
getDirCA2() | Pia | [virtual]
getDirCB2() | Pia | [virtual]
getDirPA() | PiaVia | [virtual]
getDirPB() | PiaVia | [virtual]
getEdgeCA1() | Pia | [virtual]
getEdgeCB1() | Pia | [virtual]
getInputLineLevel(int line) | RB8506_Sifu |
getInputPortData() | RB8506_Sifu |
getIntrCA1() | Pia | [virtual]
getIntrCB1() | Pia | [virtual]
getIrqCA1() | Pia | [virtual]
getIrqCB1() | Pia | [virtual]
getLevelCA2() | Pia | [virtual]
getLevelCB2() | Pia | [virtual]
getLineDir(CharCptr lin) | PiaVia | [virtual]
getLineDirPA(int pin) | PiaVia | [virtual]
getLineDirPB(int pin) | PiaVia | [virtual]
getLineLevel(CharCptr lin) | PiaVia | [virtual]
getLineLevelPA(int pin) | PiaVia | [virtual]
getLineLevelPB(int pin) | PiaVia | [virtual]
getOutputLineLevel(int line) | RB8506_Sifu | [inline]
getOutputPortData() | RB8506_Sifu | [inline]
getPDRA() | Pia | [protected, virtual]
getPDRB() | Pia | [protected, virtual]
getPortData(CharCptr ptr) | PiaVia | [virtual]
getPortDir(CharCptr prt) | PiaVia | [virtual]
isChangedInputLine() | RB8506_Sifu | [inline]
isEnabledPulseOutputs() | RB8506_Sifu | [inline]
name() const | RulbusDevice | [inline]
operator=(RB8506_SifuCref rhs) | RB8506_Sifu | [protected]
Rulbus::Pia::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
Pia(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK) | Pia | [inline]
PiaVia(NameCref aName, Addr aAddr, Addr aWidth, Rack aRack) (defined in PiaVia) | PiaVia | [inline]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB8506_Sifu(NameCref name, Addr addr=DEF_ADDR, Rack rack=DEF_RACK) | RB8506_Sifu |
RB8506_Sifu() | RB8506_Sifu | [protected]
RB8506_Sifu(RB8506_SifuCref rhs) | RB8506_Sifu | [protected]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setDataPA(int dat) | PiaVia | [virtual]
setDataPB(int dat) | PiaVia | [virtual]
setDDRA(int dir) | Pia | [protected, virtual]
setDDRB(int dir) | Pia | [protected, virtual]
setDirCA2(char dir) | Pia | [virtual]
setDirCB2(char dir) | Pia | [virtual]
setDirPA(int msk) | PiaVia | [virtual]
setDirPB(int msk) | PiaVia | [virtual]
setEdgeCA1(char edge) | Pia | [virtual]
setEdgeCB1(char edge) | Pia | [virtual]
setIntrCA1(int enable) | Pia | [virtual]
setIntrCB1(int enable) | Pia | [virtual]
setLevelCA2(int lvl) | Pia | [virtual]
setLevelCB2(int lvl) | Pia | [virtual]
setLineDir(CharCptr lin, char dir) | PiaVia | [virtual]
setLineDirPA(int pin, char dir) | PiaVia | [virtual]
setLineDirPB(int pin, char dir) | PiaVia | [virtual]
setLineLevel(CharCptr lin, int lvl) | PiaVia | [virtual]
setLineLevelPA(int pin, int lvl) | PiaVia | [virtual]
setLineLevelPB(int pin, int lvl) | PiaVia | [virtual]
setOutputLineLevel(int line, bool set) | RB8506_Sifu | [inline]
setOutputPortData(int data) | RB8506_Sifu | [inline]
setPDRA(int dat) | Pia | [protected, virtual]
setPDRB(int dat) | Pia | [protected, virtual]
setPortData(CharCptr prt, int dat) | PiaVia | [virtual]
setPortDir(CharCptr prt, int msk) | PiaVia | [virtual]
setRack(Rack aRack) | RulbusDevice |
swapLines(int line) | RB8506_Sifu | [inline, protected, static]
swapNibbles(int byte) | RB8506_Sifu | [inline, protected, static]
theRulbus() | RulbusDevice | [inline, protected, static]
tstInputLineLevel(int line) | RB8506_Sifu |
width() const | RulbusDevice | [inline]
~Pia() | Pia | [inline, virtual]
~PiaVia() | PiaVia | [inline, virtual]
~RB8506_Sifu() | RB8506_Sifu |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8506_Via Member List

This is the complete list of members for RB8506_Via, including all inherited members.
addr() const | RulbusDevice | [inline]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkData(int dat) | PiaVia | [protected]
checkDir(char dir) | PiaVia | [protected]
checkMask(int msk) | PiaVia | [protected]
checkPin(int pin) | PiaVia | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
DEF_ADDR | Via | [static]
DEF_RACK | Via | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getDataPA() | PiaVia | [virtual]
getDataPB() | PiaVia | [virtual]
getDDRA() | Via | [protected, virtual]
getDDRB() | Via | [protected, virtual]
getDirCA2() | Via | [virtual]
getDirCB2() | Via | [virtual]
getDirPA() | PiaVia | [virtual]
getDirPB() | PiaVia | [virtual]
getEdgeCA1() | Via | [virtual]
getEdgeCB1() | Via | [virtual]
getIntrCA1() | Via | [virtual]
getIntrCB1() | Via | [virtual]
getIrqCA1() | Via | [virtual]
getIrqCB1() | Via | [virtual]
getLevelCA2() | Via | [virtual]
getLevelCB2() | Via | [virtual]
getLineDir(CharCptr lin) | PiaVia | [virtual]
getLineDirPA(int pin) | PiaVia | [virtual]
getLineDirPB(int pin) | PiaVia | [virtual]
getLineLevel(CharCptr lin) | PiaVia | [virtual]
getLineLevelPA(int pin) | PiaVia | [virtual]
getLineLevelPB(int pin) | PiaVia | [virtual]
getPDRA() | Via | [protected, virtual]
getPDRB() | Via | [protected, virtual]
getPortData(CharCptr ptr) | PiaVia | [virtual]
getPortDir(CharCptr prt) | PiaVia | [virtual]
name() const | RulbusDevice | [inline]
operator=(RulbusDeviceCref) | RulbusDevice | [protected]
PiaVia(NameCref aName, Addr aAddr, Addr aWidth, Rack aRack) (defined in PiaVia) | PiaVia | [inline]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB8506_Via(NameCref name, Addr addr=Via::DEF_ADDR, Rack rack=Via::DEF_RACK) | RB8506_Via | [inline]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setDataPA(int dat) | PiaVia | [virtual]
setDataPB(int dat) | PiaVia | [virtual]
setDDRA(int dir) | Via | [protected, virtual]
setDDRB(int dir) | Via | [protected, virtual]
setDirCA2(char dir) | Via | [virtual]
setDirCB2(char dir) | Via | [virtual]
setDirPA(int msk) | PiaVia | [virtual]
setDirPB(int msk) | PiaVia | [virtual]
setEdgeCA1(char edge) | Via | [virtual]
setEdgeCB1(char edge) | Via | [virtual]
setIntrCA1(int enable) | Via | [virtual]
setIntrCB1(int enable) | Via | [virtual]
setLevelCA2(int lvl) | Via | [virtual]
setLevelCB2(int lvl) | Via | [virtual]
setLineDir(CharCptr lin, char dir) | PiaVia | [virtual]
setLineDirPA(int pin, char dir) | PiaVia | [virtual]
setLineDirPB(int pin, char dir) | PiaVia | [virtual]
setLineLevel(CharCptr lin, int lvl) | PiaVia | [virtual]
setLineLevelPA(int pin, int lvl) | PiaVia | [virtual]
setLineLevelPB(int pin, int lvl) | PiaVia | [virtual]
setPDRA(int dat) | Via | [protected, virtual]
setPDRB(int dat) | Via | [protected, virtual]
setPortData(CharCptr prt, int dat) | PiaVia | [virtual]
setPortDir(CharCptr prt, int msk) | PiaVia | [virtual]
setRack(Rack aRack) | RulbusDevice |
theRulbus() | RulbusDevice | [inline, protected, static]
Via(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK) | Via | [inline]
width() const | RulbusDevice | [inline]
~PiaVia() | PiaVia | [inline, virtual]
~RulbusDevice() | RulbusDevice | [virtual]
~Via() | Via | [inline, virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8509_Adc12 Member List

This is the complete list of members for RB8509_Adc12, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | RB8509_Adc12 | [private, static]
ANY_RACK | RulbusDevice | [static]
autoscale() | RB8509_Adc12 |
channel() const | RB8509_Adc12 |
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkChannel(int aChannel) const | RB8509_Adc12 | [protected]
checkGain(int aGain) const | RB8509_Adc12 | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
convert() | RB8509_Adc12 |
DEF_ADDR | RB8509_Adc12 | [static]
DEF_BIP | RB8509_Adc12 | [static]
DEF_CHAN | RB8509_Adc12 | [static]
DEF_ETI | RB8509_Adc12 | [static]
DEF_GAIN | RB8509_Adc12 | [static]
DEF_RACK | RulbusDevice | [static]
DEF_VPB | RB8509_Adc12 | [static]
enableExtTrigger(bool enable=true) | RB8509_Adc12 |
enableInterrupt(bool enable=true) | RB8509_Adc12 |
enableMultiplexer(bool enable=true) | RB8509_Adc12 |
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
extTriggerLevel() const | RB8509_Adc12 |
gain() const | RB8509_Adc12 |
getByte(int offset) const | RulbusDevice |
hasExtTriggerInput() const | RB8509_Adc12 | [inline]
isBipolar() const | RB8509_Adc12 | [inline]
isBusyAdc() const | RB8509_Adc12 |
isEnabledExtTrigger() const | RB8509_Adc12 |
isEnabledInterrupt() const | RB8509_Adc12 |
isEnabledMultiplexer() const | RB8509_Adc12 |
isPendingInterrupt() const | RB8509_Adc12 |
isReady() const | RB8509_Adc12 |
isValidChannel(int aChannel) const | RB8509_Adc12 | [inline]
isValidGain(int aGain) const | RB8509_Adc12 | [inline]
LIM_BIPVAL | RB8509_Adc12 | [static]
LIM_MAXCHAN | RB8509_Adc12 | [static]
LIM_MAXGAIN | RB8509_Adc12 | [static]
LIM_MAXVAL | RB8509_Adc12 | [static]
LIM_MAXVPB | RB8509_Adc12 | [static]
LIM_MINCHAN | RB8509_Adc12 | [static]
LIM_MINGAIN | RB8509_Adc12 | [static]
LIM_MINVAL | RB8509_Adc12 | [static]
LIM_MINVPB | RB8509_Adc12 | [static]
LIM_TIMOUT | RB8509_Adc12 | [static]
MSK_CTLCHAN | RB8509_Adc12 | [private, static]
MSK_CTLGAIN | RB8509_Adc12 | [private, static]
MSK_CTLINTR | RB8509_Adc12 | [private, static]
MSK_CTLMPLX | RB8509_Adc12 | [private, static]
MSK_CTLTRIG | RB8509_Adc12 | [private, static]
MSK_STSBSY | RB8509_Adc12 | [private, static]
MSK_STSEOC | RB8509_Adc12 | [private, static]
MSK_STSINTR | RB8509_Adc12 | [private, static]
MSK_STSTRIG | RB8509_Adc12 | [private, static]
MSK_VALMSN | RB8509_Adc12 | [private, static]
name() const | RulbusDevice | [inline]
OFF_ADCLSB | RB8509_Adc12 | [private, static]
OFF_CONTROL | RB8509_Adc12 | [private, static]
OFF_CONVERT | RB8509_Adc12 | [private, static]
OFF_STATUS | RB8509_Adc12 | [private, static]
operator=(RB8509_Adc12Cref rhs) | RB8509_Adc12 | [protected]
Rulbus::RulbusDevice::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
rawresult() | RB8509_Adc12 |
RB8509_Adc12(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK, bool aBipolarFlag=DEF_BIP, Real aVoltPerBit=DEF_VPB, bool aExtTrigInpFlag=DEF_ETI) | RB8509_Adc12 |
RB8509_Adc12() | RB8509_Adc12 | [protected]
RB8509_Adc12(RB8509_Adc12Cref rhs) | RB8509_Adc12 | [protected]
result() | RB8509_Adc12 |
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setChannel(int aChannel) | RB8509_Adc12 |
setGain(int aGain) | RB8509_Adc12 |
setRack(Rack aRack) | RulbusDevice |
SHL_CTLCHAN | RB8509_Adc12 | [private, static]
SHL_CTLGAIN | RB8509_Adc12 | [private, static]
theBipolarFlag | RB8509_Adc12 | [private]
theControlRegister | RB8509_Adc12 | [private]
theExtTrigInpFlag | RB8509_Adc12 | [private]
theRulbus() | RulbusDevice | [inline, protected, static]
theVoltPerBit | RB8509_Adc12 | [private]
value() | RB8509_Adc12 |
Value typedef | RB8509_Adc12 |
voltage() | RB8509_Adc12 |
voltperbit() const | RB8509_Adc12 | [inline]
width() const | RulbusDevice | [inline]
~RB8509_Adc12() | RB8509_Adc12 |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8510_Dac12 Member List

This is the complete list of members for RB8510_Dac12, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | RB8510_Dac12 | [private, static]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
DEF_ADDR | RB8510_Dac12 | [static]
DEF_BIP | RB8510_Dac12 | [static]
DEF_RACK | RulbusDevice | [static]
DEF_VPB | RB8510_Dac12 | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
isBipolar() const | RB8510_Dac12 | [inline]
LIM_BIPVAL | RB8510_Dac12 | [static]
LIM_MAXVAL | RB8510_Dac12 | [static]
LIM_MINVAL | RB8510_Dac12 | [static]
name() const | RulbusDevice | [inline]
OFF_LSB | RB8510_Dac12 | [private, static]
OFF_MSB | RB8510_Dac12 | [private, static]
operator=(RB8510_Dac12Cref rhs) | RB8510_Dac12 | [protected]
Rulbus::RulbusDevice::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB8510_Dac12(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK, bool aBipolarFlag=DEF_BIP, Real aVoltPerBit=DEF_VPB) | RB8510_Dac12 |
RB8510_Dac12() | RB8510_Dac12 | [protected]
RB8510_Dac12(RB8510_Dac12Cref rhs) | RB8510_Dac12 | [protected]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setRack(Rack aRack) | RulbusDevice |
setValue(Value aValue) | RB8510_Dac12 |
setVoltage(Volt aVoltage) | RB8510_Dac12 |
theBipolarFlag | RB8510_Dac12 | [private]
theRegister | RB8510_Dac12 | [private]
theRulbus() | RulbusDevice | [inline, protected, static]
theVoltPerBit | RB8510_Dac12 | [private]
Value typedef | RB8510_Dac12 |
value() const | RB8510_Dac12 | [inline]
voltage() const | RB8510_Dac12 |
voltperbit() const | RB8510_Dac12 | [inline]
width() const | RulbusDevice | [inline]
~RB8510_Dac12() | RB8510_Dac12 |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8513_timebase Member List

This is the complete list of members for RB8513_timebase, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | RB8513_timebase | [private, static]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
clockRateMultiplier() const | RB8513_timebase | [inline]
clockRateSelector() const | RB8513_timebase | [inline]
DEF_ADDR | RB8513_timebase | [static]
DEF_MUL | RB8513_timebase | [static]
DEF_RACK | RulbusDevice | [static]
DEF_SEL | RB8513_timebase | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
intervalTime() const | RB8513_timebase |
LIM_MULMAX | RB8513_timebase | [static]
LIM_MULMIN | RB8513_timebase | [static]
LIM_SELMAX | RB8513_timebase | [static]
LIM_SELMAXFIXED | RB8513_timebase | [static]
LIM_SELMIN | RB8513_timebase | [static]
MSK_SELSTP | RB8513_timebase | [private, static]
name() const | RulbusDevice | [inline]
OFF_MUL | RB8513_timebase | [private, static]
OFF_SEL | RB8513_timebase | [private, static]
operator=(RB8513_timebaseCref rhs) | RB8513_timebase | [protected]
Rulbus::RulbusDevice::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB8513_timebase(NameCref name, Addr addr=DEF_ADDR, Rack rack=DEF_RACK) | RB8513_timebase |
RB8513_timebase() | RB8513_timebase | [protected]
RB8513_timebase(RB8513_timebaseCref rhs) | RB8513_timebase | [protected]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
selectorList | RB8513_timebase | [private, static]
setAddr(Addr aAddr) | RulbusDevice |
setClockRateMultiplier(Value aValue) | RB8513_timebase |
setClockRateSelector(Value aValue) | RB8513_timebase |
setIntervalTime(Time aTime) | RB8513_timebase |
setRack(Rack aRack) | RulbusDevice |
stop() | RB8513_timebase |
theMutiplyReg | RB8513_timebase | [private]
theRulbus() | RulbusDevice | [inline, protected, static]
theSelectorReg | RB8513_timebase | [private]
timeList | RB8513_timebase | [private, static]
Value typedef | RB8513_timebase |
width() const | RulbusDevice | [inline]
~RB8513_timebase() | RB8513_timebase |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8514_delay Member List

This is the complete list of members for RB8514_delay, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | RB8514_delay | [private, static]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
clearInterrupt() | RB8514_delay |
clockFrequency() const | RB8514_delay | [inline]
Count typedef | RB8514_delay |
countByte0() const | RB8514_delay | [private]
countByte1() const | RB8514_delay | [private]
countByte2() const | RB8514_delay | [private]
DEF_ADDR | RB8514_delay | [static]
DEF_CNT | RB8514_delay | [static]
DEF_DLY | RB8514_delay | [static]
DEF_EE1 | RB8514_delay | [static]
DEF_EE2 | RB8514_delay | [static]
DEF_EINT | RB8514_delay | [static]
DEF_ES1 | RB8514_delay | [static]
DEF_ES2 | RB8514_delay | [static]
DEF_ETRG | RB8514_delay | [static]
DEF_FRQ | RB8514_delay | [static]
DEF_IDT | RB8514_delay | [static]
DEF_LE12 | RB8514_delay | [static]
DEF_LS12 | RB8514_delay | [static]
DEF_RACK | RulbusDevice | [static]
delayCount() const | RB8514_delay |
delayTime() const | RB8514_delay |
enableEnd1(bool enable=true) | RB8514_delay |
enableEnd2(bool enable=true) | RB8514_delay |
enableInterrupt(bool enable=true) | RB8514_delay |
enableSignal(CharCptr signal, bool enable) | RB8514_delay |
enableStart1(bool enable=true) | RB8514_delay |
enableStart2(bool enable=true) | RB8514_delay |
end12Direction() const | RB8514_delay |
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getDirection(int mask) const | RB8514_delay | [private]
getEnable(int mask) const | RB8514_delay | [private]
intrinsicDelayTime() const | RB8514_delay | [inline]
isBusy() const | RB8514_delay |
isEnabledEnd1() const | RB8514_delay |
isEnabledEnd2() const | RB8514_delay |
isEnabledInterrupt() const | RB8514_delay |
isEnabledSignal(CharCptr signal) const | RB8514_delay |
isEnabledStart1() const | RB8514_delay |
isEnabledStart2() const | RB8514_delay |
isPendingInterrupt() | RB8514_delay |
isValidClockFrequency(Freq aFreq) const | RB8514_delay | [protected]
isValidDelayCount(Count aCount) const | RB8514_delay | [protected]
isValidIntrinsicTime(Time aTime) const | RB8514_delay | [protected]
isValidSignalDirection(Char aDirection) const | RB8514_delay | [protected]
isValidSignalName(CharCptr aSignal, CharCptr aExtra) const | RB8514_delay | [protected]
LIM_CNTMAX | RB8514_delay | [static]
LIM_CNTMIN | RB8514_delay | [static]
LIM_FRQMAX | RB8514_delay | [static]
LIM_FRQMIN | RB8514_delay | [static]
LIM_IDTMAX | RB8514_delay | [static]
LIM_IDTMIN | RB8514_delay | [static]
MSK_BYTE | RB8514_delay | [private, static]
MSK_CTLEE1 | RB8514_delay | [private, static]
MSK_CTLEE2 | RB8514_delay | [private, static]
MSK_CTLES1 | RB8514_delay | [private, static]
MSK_CTLES2 | RB8514_delay | [private, static]
MSK_CTLINT | RB8514_delay | [private, static]
MSK_CTLLE12 | RB8514_delay | [private, static]
MSK_CTLLS12 | RB8514_delay | [private, static]
MSK_CTLTRG | RB8514_delay | [private, static]
MSK_STSBSY | RB8514_delay | [private, static]
MSK_STSINT | RB8514_delay | [private, static]
name() const | RulbusDevice | [inline]
OFF_BT0 | RB8514_delay | [private, static]
OFF_BT1 | RB8514_delay | [private, static]
OFF_BT2 | RB8514_delay | [private, static]
OFF_CTL | RB8514_delay | [private, static]
OFF_STS | RB8514_delay | [private, static]
operator=(RB8514_delayCref rhs) | RB8514_delay | [protected]
Rulbus::RulbusDevice::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB8514_delay(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK) | RB8514_delay |
RB8514_delay() | RB8514_delay | [protected]
RB8514_delay(RB8514_delayCref rhs) | RB8514_delay | [protected]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setClockFrequency(Freq freq) | RB8514_delay |
setDelayCount(Count count) | RB8514_delay |
setDelayTime(Time time) | RB8514_delay |
setDirection(char dir, int mask, CharCptr description) | RB8514_delay | [private]
setEnable(bool enable, int mask) | RB8514_delay | [private]
setEnd12Direction(char dir) | RB8514_delay |
setIntrinsicDelayTime(Time time) | RB8514_delay |
setRack(Rack aRack) | RulbusDevice |
setSignalDirection(CharCptr signal, char dir) | RB8514_delay |
setStart12Direction(char dir) | RB8514_delay |
setTriggerEdge(char edge) | RB8514_delay |
SHR_BT0 | RB8514_delay | [private, static]
SHR_BT1 | RB8514_delay | [private, static]
SHR_BT2 | RB8514_delay | [private, static]
signalDirection(CharCptr signal) const | RB8514_delay |
start12Direction() const | RB8514_delay |
theClockFrequency | RB8514_delay | [private]
theControlRegister | RB8514_delay | [private]
theDelayRegister | RB8514_delay | [private]
theIntrinsicDelayTime | RB8514_delay | [private]
theRulbus() | RulbusDevice | [inline, protected, static]
trigger() | RB8514_delay |
triggerEdge() const | RB8514_delay |
width() const | RulbusDevice | [inline]
~RB8514_delay() | RB8514_delay |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8515_clock Member List

This is the complete list of members for RB8515_clock, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | RB8515_clock | [private, static]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
clearInterrupt() | RB8515_clock |
clkTable | RB8515_clock | [private, static]
clockFrequency() const | RB8515_clock |
DEF_ADDR | RB8515_clock | [private, static]
DEF_CLKFRQ | RB8515_clock | [private, static]
DEF_INTFRQ | RB8515_clock | [private, static]
DEF_RACK | RulbusDevice | [static]
disableInterrupt() | RB8515_clock |
enableInterrupt(bool enable=true) | RB8515_clock |
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
FC_0Hz enum value | RB8515_clock | [private]
FC_100Hz enum value | RB8515_clock | [private]
FC_100kHz enum value | RB8515_clock | [private]
FC_100MHz enum value | RB8515_clock | [private]
FC_10kHz enum value | RB8515_clock | [private]
FC_10MHz enum value | RB8515_clock | [private]
FC_1kHz enum value | RB8515_clock | [private]
FC_1MHz enum value | RB8515_clock | [private]
FC_INVALID enum value | RB8515_clock | [private]
FI_0Hz enum value | RB8515_clock | [private]
FI_100Hz enum value | RB8515_clock | [private]
FI_10Hz enum value | RB8515_clock | [private]
FI_1Hz enum value | RB8515_clock | [private]
FI_1kHz enum value | RB8515_clock | [private]
FI_500Hz enum value | RB8515_clock | [private]
FI_50Hz enum value | RB8515_clock | [private]
FI_5kHz enum value | RB8515_clock | [private]
FI_INVALID enum value | RB8515_clock | [private]
getByte(int offset) const | RulbusDevice |
getClkFreqCode(Freq aFrequency, IntPtr pCode) const | RB8515_clock | [protected]
getFreqCode(Freq aFrequency, const FreqTable *tablePtr, IntPtr pCode) const | RB8515_clock | [protected]
getIntFreqCode(Freq aFrequency, IntPtr pCode) const | RB8515_clock | [protected]
interruptFrequency() const | RB8515_clock |
intTable | RB8515_clock | [private, static]
isEnabledInterrupt() const | RB8515_clock |
isPendingInterrupt() | RB8515_clock |
MSK_CLKFRQ | RB8515_clock | [private, static]
MSK_INTCLRn | RB8515_clock | [private, static]
MSK_INTENA | RB8515_clock | [private, static]
MSK_INTFRQ | RB8515_clock | [private, static]
MSK_INTSTS | RB8515_clock | [private, static]
name() const | RulbusDevice | [inline]
OFF_CR | RB8515_clock | [private, static]
OFF_SR | RB8515_clock | [private, static]
operator=(RB8515_clockCref rhs) | RB8515_clock | [protected]
Rulbus::RulbusDevice::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB8515_clock(NameCref name, Addr addr=DEF_ADDR, Rack rack=DEF_RACK) | RB8515_clock |
RB8515_clock() | RB8515_clock | [protected]
RB8515_clock(RB8515_clockCref rhs) | RB8515_clock | [protected]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setClockFrequency(Freq aFrequency) | RB8515_clock |
setInterruptFrequency(Freq aFrequency) | RB8515_clock |
setRack(Rack aRack) | RulbusDevice |
SHL_CLKFRQ | RB8515_clock | [private, static]
SHL_INTFRQ | RB8515_clock | [private, static]
theCtlByte | RB8515_clock | [private]
theRulbus() | RulbusDevice | [inline, protected, static]
width() const | RulbusDevice | [inline]
~RB8515_clock() | RB8515_clock |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8905_Adc12 Member List

This is the complete list of members for RB8905_Adc12, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | RB8905_Adc12 | [private, static]
ANY_RACK | RulbusDevice | [static]
arm() | RB8905_Adc12 |
bufferCapacity() const | RB8905_Adc12 | [inline]
bufferSize() const | RB8905_Adc12 | [protected]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkRead(int nelem) | RB8905_Adc12 | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
clearAddress() | RB8905_Adc12 | [protected]
CON_JMP3 | RB8905_Adc12 | [static]
CON_TRELAIS | RB8905_Adc12 | [static]
DEF_ADDR | RB8905_Adc12 | [static]
DEF_RACK | RulbusDevice | [static]
DEF_SAMPLES | RB8905_Adc12 | [static]
DEF_VPB | RB8905_Adc12 | [static]
detectJmp3BufferSize() | RB8905_Adc12 | [protected]
elemSize() const | RB8905_Adc12 | [inline, protected]
enableInterrupt(bool enable=true) | RB8905_Adc12 |
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getRawValue() | RB8905_Adc12 |
getValue() | RB8905_Adc12 |
isEnabledInterrupt() const | RB8905_Adc12 | [inline]
isFastMode() const | RB8905_Adc12 | [inline]
isReady() const | RB8905_Adc12 | [inline]
isUnipolarMode() const | RB8905_Adc12 | [inline]
jmp3BufferCapacity() const | RB8905_Adc12 | [inline]
jmp3BufferSize() const | RB8905_Adc12 | [inline, protected]
LIM_MAXBUFSIZE | RB8905_Adc12 | [private, static]
LIM_MAXJMP3SIZE | RB8905_Adc12 | [private, static]
LIM_MAXVAL12 | RB8905_Adc12 | [private, static]
LIM_MAXVAL8 | RB8905_Adc12 | [private, static]
LIM_MINBUFSIZE | RB8905_Adc12 | [private, static]
LIM_MINJMP3SIZE | RB8905_Adc12 | [private, static]
LIM_MINVAL12 | RB8905_Adc12 | [private, static]
LIM_MINVAL8 | RB8905_Adc12 | [private, static]
maxInputVoltage() const | RB8905_Adc12 |
minInputVoltage() const | RB8905_Adc12 |
MSK_ADCALL12 | RB8905_Adc12 | [private, static]
MSK_ADCALL8 | RB8905_Adc12 | [private, static]
MSK_ADCMSB12 | RB8905_Adc12 | [private, static]
MSK_ADCMSB8 | RB8905_Adc12 | [private, static]
MSK_CTLBSIZE | RB8905_Adc12 | [private, static]
MSK_CTLCLEAR | RB8905_Adc12 | [private, static]
MSK_CTLFAST | RB8905_Adc12 | [private, static]
MSK_CTLINTR | RB8905_Adc12 | [private, static]
MSK_CTLREAD | RB8905_Adc12 | [private, static]
MSK_CTLUNIP | RB8905_Adc12 | [private, static]
MSK_STSREADY | RB8905_Adc12 | [private, static]
name() const | RulbusDevice | [inline]
OFF_ADC | RB8905_Adc12 | [private, static]
OFF_CTL | RB8905_Adc12 | [private, static]
OFF_STS | RB8905_Adc12 | [private, static]
offsetVoltage() const | RB8905_Adc12 |
operator=(RB8905_Adc12Cref rhs) | RB8905_Adc12 | [protected]
Rulbus::RulbusDevice::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB8905_Adc12(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK, Real aVoltPerBit=DEF_VPB) | RB8905_Adc12 |
RB8905_Adc12() | RB8905_Adc12 | [protected]
RB8905_Adc12(RB8905_Adc12Cref rhs) | RB8905_Adc12 | [protected]
readValue(Int16 *pValue, int nelem) | RB8905_Adc12 |
readVoltage(Volt32 *pVoltage, int nelem) | RB8905_Adc12 |
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setBipolarMode() | RB8905_Adc12 | [inline]
setBufferCapacity(int nelem=CON_JMP3) | RB8905_Adc12 | [inline]
setBufferCode(int aCode) | RB8905_Adc12 | [protected]
setBufferSize(int aSize=CON_JMP3) | RB8905_Adc12 | [protected]
setFastMode() | RB8905_Adc12 | [inline]
setNormalMode() | RB8905_Adc12 | [inline]
setRack(Rack aRack) | RulbusDevice |
setReadMode() | RB8905_Adc12 | [protected]
setUnipolarMode() | RB8905_Adc12 | [inline]
setWriteMode() | RB8905_Adc12 | [protected]
theBufferCapacity | RB8905_Adc12 | [private]
theControlRegister | RB8905_Adc12 | [private]
theJmp3BufferSize | RB8905_Adc12 | [private]
theRulbus() | RulbusDevice | [inline, protected, static]
theVoltPerBit | RB8905_Adc12 | [private]
Value typedef | RB8905_Adc12 |
voltageSpan() const | RB8905_Adc12 |
voltperbit() const | RB8905_Adc12 | [inline]
waitRelais() | RB8905_Adc12 | [protected]
width() const | RulbusDevice | [inline]
~RB8905_Adc12() | RB8905_Adc12 |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB9005_amplifier Member List

This is the complete list of members for RB9005_amplifier, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | RB9005_amplifier | [private, static]
ANY_RACK | RulbusDevice | [static]
channel() const | RB9005_amplifier |
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkChannel(int aChannel) const | RB9005_amplifier | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
DEF_ADDR | RB9005_amplifier | [static]
DEF_RACK | RulbusDevice | [static]
enableChannelSequenceMode(bool enable=true) | RB9005_amplifier |
enableClockSequenceMode(bool enable=true) | RB9005_amplifier |
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
freq12Table | RB9005_amplifier | [private, static]
gain(int aChannel) const | RB9005_amplifier |
gain12(int aChannel) const | RB9005_amplifier | [protected]
gain12Table | RB9005_amplifier | [private, static]
gain34(int aChannel) const | RB9005_amplifier | [protected]
gain34Table | RB9005_amplifier | [private, static]
GainInfoTable | RB9005_amplifier | [private, static]
getByte(int offset) const | RulbusDevice |
isChannelSequenceMode() const | RB9005_amplifier |
isClockSequenceMode() const | RB9005_amplifier |
LIM_MAXCHN | RB9005_amplifier | [static]
LIM_MINCHN | RB9005_amplifier | [static]
lowPassFrequency(int aChannel) const | RB9005_amplifier |
lpf12(int aChannel) const | RB9005_amplifier | [protected]
lpf34(int aChannel) const | RB9005_amplifier | [protected]
MSK_CHN1 | RB9005_amplifier | [private, static]
MSK_CHN2 | RB9005_amplifier | [private, static]
MSK_CHNSEQ | RB9005_amplifier | [private, static]
MSK_CLKSEQ | RB9005_amplifier | [private, static]
MSK_GAIN1 | RB9005_amplifier | [private, static]
MSK_GAIN2 | RB9005_amplifier | [private, static]
MSK_GAIN3 | RB9005_amplifier | [private, static]
MSK_GAIN4 | RB9005_amplifier | [private, static]
MSK_LPF12 | RB9005_amplifier | [private, static]
name() const | RulbusDevice | [inline]
OFF_FREQ1 | RB9005_amplifier | [private, static]
OFF_FREQ2 | RB9005_amplifier | [private, static]
OFF_GAIN12 | RB9005_amplifier | [private, static]
OFF_GAIN34 | RB9005_amplifier | [private, static]
OFF_MUX | RB9005_amplifier | [private, static]
operator=(RB9005_amplifierCref rhs) | RB9005_amplifier | [protected]
Rulbus::RulbusDevice::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RB9005_amplifier(NameCref name, Addr addr=DEF_ADDR, Rack rack=DEF_RACK) | RB9005_amplifier |
RB9005_amplifier() | RB9005_amplifier | [protected]
RB9005_amplifier(RB9005_amplifierCref rhs) | RB9005_amplifier | [protected]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setChannel(int aChannel) | RB9005_amplifier |
setGain(int aChannel, int aGain) | RB9005_amplifier |
setGain12(int aChannel, int aGain) | RB9005_amplifier | [protected]
setGain34(int aChannel, int aGain) | RB9005_amplifier | [protected]
setLowPassFrequency(int aChannel, Freq aFrequency) | RB9005_amplifier |
setLpf12(int aChannel, Freq aFrequency) | RB9005_amplifier | [protected]
setLpf34(int aChannel, Freq aFrequency) | RB9005_amplifier | [protected]
setRack(Rack aRack) | RulbusDevice |
SHL_CHN1 | RB9005_amplifier | [private, static]
SHL_CHN2 | RB9005_amplifier | [private, static]
SHL_GAIN1 | RB9005_amplifier | [private, static]
SHL_GAIN2 | RB9005_amplifier | [private, static]
SHL_GAIN3 | RB9005_amplifier | [private, static]
SHL_GAIN4 | RB9005_amplifier | [private, static]
SHL_LPF12 | RB9005_amplifier | [private, static]
theFreq1Register | RB9005_amplifier | [private]
theFreq2Register | RB9005_amplifier | [private]
theGain12Register | RB9005_amplifier | [private]
theGain34Register | RB9005_amplifier | [private]
theMuxRegister | RB9005_amplifier | [private]
theRulbus() | RulbusDevice | [inline, protected, static]
Value typedef | RB9005_amplifier |
width() const | RulbusDevice | [inline]
~RB9005_amplifier() | RB9005_amplifier |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB9603_monochromator Member List

This is the complete list of members for RB9603_monochromator, including all inherited members.
adcMeanWavelength() const | RB9603_monochromator |
adcWavelength() const | RB9603_monochromator |
addr() const | RulbusDevice | [inline]
ADR_WIDTH | RB9603_monochromator | [private, static]
ANY_RACK | RulbusDevice | [static]
calibrate(bool and_wait=true) const | RB9603_monochromator |
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
checkWavelength(Length aWavelength) const | RB9603_monochromator | [protected]
COM_CNT enum value | RB9603_monochromator | [protected]
COM_EOT enum value | RB9603_monochromator | [protected]
COM_GET enum value | RB9603_monochromator | [protected]
COM_LEN enum value | RB9603_monochromator | [protected]
COM_RDY enum value | RB9603_monochromator | [protected]
COM_SLPMS enum value | RB9603_monochromator | [protected]
ComCodes enum name | RB9603_monochromator | [protected]
CON_MPS | RB9603_monochromator | [private, static]
currentWavelength() const | RB9603_monochromator |
DEF_ADDR | RB9603_monochromator | [static]
DEF_RACK | RulbusDevice | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getCharacter() const | RB9603_monochromator | [protected]
getString() const | RB9603_monochromator | [protected]
isReady() const | RB9603_monochromator |
maxWavelength() const | RB9603_monochromator |
minWavelength() const | RB9603_monochromator |
name() const | RulbusDevice | [inline]
OFF_CMD | RB9603_monochromator | [private, static]
OFF_STS | RB9603_monochromator | [private, static]
operator=(RB9603_monochromatorCref rhs) | RB9603_monochromator | [protected]
Rulbus::RulbusDevice::operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
putCharacter(char ch) const | RB9603_monochromator | [protected]
putString(StringCref aString) const | RB9603_monochromator | [protected]
rack() const | RulbusDevice | [inline]
RB9603_monochromator(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK) | RB9603_monochromator |
RB9603_monochromator() | RB9603_monochromator | [protected]
RB9603_monochromator(RB9603_monochromatorCref rhs) | RB9603_monochromator | [protected]
read(CharCptr aName, CharCptr aCmd) const | RB9603_monochromator | [protected]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setRack(Rack aRack) | RulbusDevice |
setWavelength(Length aWavelength, bool and_wait=true) const | RB9603_monochromator |
targetWavelength() const | RB9603_monochromator |
theMaxWL | RB9603_monochromator | [mutable, private]
theMinWL | RB9603_monochromator | [mutable, private]
theRulbus() | RulbusDevice | [inline, protected, static]
Value typedef | RB9603_monochromator |
wait() const | RB9603_monochromator |
width() const | RulbusDevice | [inline]
write(CharCptr aName, CharCptr aCmd, Value aPos=-1) const | RB9603_monochromator | [protected]
~RB9603_monochromator() | RB9603_monochromator |
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RequireException Member List

This is the complete list of members for RequireException, including all inherited members.
ASSERT enum value (defined in DbcException) | DbcException |
Assertion(CharCptr aReason, CharCptr aFile, int aLine) | Assertion | [inline]
Assertion(AssertionCref rhs) | Assertion | [inline]
DbcException(Type aType, CharCptr aDescription, CharCptr aExpression, CharCptr aFile, int aLine) | DbcException | [inline]
DbcException(DbcExceptionCref rhs) | DbcException | [inline]
description() const | DbcException | [inline]
ENSURE enum value (defined in DbcException) | DbcException |
file() const | Assertion | [inline]
line() const | Assertion | [inline]
NEVERGETHERE enum value (defined in DbcException) | DbcException |
operator=(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator=(AssertionCref rhs) | Assertion | [inline]
operator==(DbcExceptionCref rhs) | DbcException | [inline]
Rulbus::Assertion::operator==(AssertionCref rhs) | Assertion | [inline]
reason() const | Assertion | [inline]
REQUIRE enum value (defined in DbcException) | DbcException |
RequireException(CharCptr aExpression, CharCptr aFile, int aLine) | RequireException | [inline]
theFile | Assertion | [protected]
theLine | Assertion | [protected]
theReason | Assertion | [protected]
Type enum name | DbcException |
type() const | DbcException | [inline]
what() const | DbcException | [virtual]
~Assertion() | Assertion | [inline, virtual]
~DbcException() | DbcException | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusAddressError Member List

This is the complete list of members for RulbusAddressError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusAddressError(StringCref name, int rack, int addr) | RulbusAddressError | [inline]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusCloseError Member List

This is the complete list of members for RulbusCloseError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusCloseError(int handle) | RulbusCloseError | [inline]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusConfigError Member List

This is the complete list of members for RulbusConfigError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusConfigError(StringCref msg) | RulbusConfigError | [inline]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusContextError Member List

This is the complete list of members for RulbusContextError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusContextError(StringCref name, StringCref msg) | RulbusContextError | [inline]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusDataError Member List

This is the complete list of members for RulbusDataError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusDataError(StringCref name, int rack, int addr, int data) | RulbusDataError | [inline]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusDevice Member List

This is the complete list of members for RulbusDevice, including all inherited members.
addr() const | RulbusDevice | [inline]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
DEF_RACK | RulbusDevice | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
name() const | RulbusDevice | [inline]
operator=(RulbusDeviceCref) | RulbusDevice | [protected]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setRack(Rack aRack) | RulbusDevice |
theAddr | RulbusDevice | [private]
theName | RulbusDevice | [private]
theRack | RulbusDevice | [private]
theRulbus() | RulbusDevice | [inline, protected, static]
theWidth | RulbusDevice | [private]
width() const | RulbusDevice | [inline]
~RulbusDevice() | RulbusDevice | [virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusDeviceFactory Member List

This is the complete list of members for RulbusDeviceFactory, including all inherited members.
createDevices(String rulbus_config_file="") | RulbusDeviceFactory | [static]
destroyDevices() | RulbusDeviceFactory | [static]
RulbusDeviceFactory() | RulbusDeviceFactory | [protected]
RulbusDeviceFactory(RulbusDeviceFactoryCref) | RulbusDeviceFactory | [protected]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusDeviceProxy Member List

This is the complete list of members for RulbusDeviceProxy, including all inherited members.
get() | RulbusDeviceProxy |
operator *() | RulbusDeviceProxy | [inline]
operator RulbusDevicePtr() | RulbusDeviceProxy | [inline]
operator RulbusDeviceRef() | RulbusDeviceProxy | [inline]
operator->() | RulbusDeviceProxy | [inline]
operator=(RulbusDeviceProxyRef rhs) | RulbusDeviceProxy |
RulbusDeviceProxy(RulbusDevicePtr aPtr) | RulbusDeviceProxy | [inline]
RulbusDeviceProxy(RulbusDeviceProxyRef rhs) | RulbusDeviceProxy | [inline]
s | RulbusDeviceProxy | [protected, static]
thePtr | RulbusDeviceProxy | [protected]
transfer() | RulbusDeviceProxy | [protected]
~RulbusDeviceProxy() | RulbusDeviceProxy | [inline]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusError Member List

This is the complete list of members for RulbusError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
msg | RulbusError | [private]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
theError | RulbusError | [private, static]
tid | RulbusError | [private]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusHandleError Member List

This is the complete list of members for RulbusHandleError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
RulbusHandleError(int handle) | RulbusHandleError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusInterfaceError Member List

This is the complete list of members for RulbusInterfaceError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
RulbusInterfaceError(StringCref msg) | RulbusInterfaceError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusInterfaceFactory Member List

This is the complete list of members for RulbusInterfaceFactory, including all inherited members.
createInterface() | RulbusInterfaceFactory | [static]
RulbusInterfaceFactory() | RulbusInterfaceFactory | [protected]
RulbusInterfaceFactory(RulbusInterfaceFactoryCref) | RulbusInterfaceFactory | [protected]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusOpenError Member List

This is the complete list of members for RulbusOpenError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
RulbusOpenError(StringCref submsg) | RulbusOpenError | [inline]
RulbusOpenError(StringCref name, int rack, int addr) | RulbusOpenError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusParseError Member List

This is the complete list of members for RulbusParseError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
RulbusParseError(StringCref msg) | RulbusParseError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusRangeError Member List

This is the complete list of members for RulbusRangeError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
RulbusRangeError() | RulbusRangeError | [inline]
RulbusRangeError(StringCref name, StringCref parameter, int data, int min, int max) | RulbusRangeError | [inline]
RulbusRangeError(StringCref name, StringCref parameter, long data, long min, long max) | RulbusRangeError | [inline]
RulbusRangeError(StringCref name, StringCref parameter, Real data, Real min, Real max) | RulbusRangeError | [inline]
RulbusRangeError(StringCref name, StringCref parameter, StringCref data, StringCref set) | RulbusRangeError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusScanError Member List

This is the complete list of members for RulbusScanError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
RulbusScanError(StringCref msg) | RulbusScanError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RulbusTimeoutError Member List

This is the complete list of members for RulbusTimeoutError, including all inherited members.
getLastError(char *msg, int maxlen) | RulbusError | [static]
lasttid() const | RulbusError | [inline, virtual]
RulbusError() | RulbusError | [inline]
RulbusError(CharCptr fmt...) | RulbusError |
RulbusError(StringCref string) | RulbusError |
RulbusError(StdExceptionCref e) | RulbusError | [inline]
RulbusError(RulbusErrorCref e) | RulbusError | [inline]
RulbusTimeoutError() | RulbusTimeoutError | [inline]
RulbusTimeoutError(StringCref name, StringCref msg) | RulbusTimeoutError | [inline]
what() const | RulbusError | [inline, virtual]
~RulbusError() | RulbusError | [inline, virtual]
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

Singleton Member List

This is the complete list of members for Singleton, including all inherited members.
instance() | Singleton | [static]
theInstance | Singleton | [protected, static]
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

TheRulbusDeviceList Member List

This is the complete list of members for TheRulbusDeviceList, including all inherited members.
add(RulbusDevicePtr deviceptr) | TheRulbusDeviceList |
check() | TheRulbusDeviceList |
clear() | TheRulbusDeviceList |
close(int handle) | TheRulbusDeviceList |
get(int handle) | TheRulbusDeviceList |
instance() | Singleton< TheRulbusDeviceList > | [static]
open(Name aName) | TheRulbusDeviceList |
operator=(TheRulbusDeviceListCref rhs) | TheRulbusDeviceList | [protected]
printOn(std::ostream &stream) | TheRulbusDeviceList |
remove(RulbusDevicePtr deviceptr) | TheRulbusDeviceList |
remove(int handle) | TheRulbusDeviceList |
s | TheRulbusDeviceList | [private]
Singleton< TheRulbusDeviceList > (defined in TheRulbusDeviceList) | TheRulbusDeviceList | [friend]
theInstance | Singleton< TheRulbusDeviceList > | [protected, static]
theList | TheRulbusDeviceList | [private]
TheRulbusDeviceList() | TheRulbusDeviceList | [protected]
TheRulbusDeviceList(TheRulbusDeviceListCref rhs) | TheRulbusDeviceList | [protected]
~TheRulbusDeviceList() | TheRulbusDeviceList | [protected]
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

TheRulbusInterface Member List

This is the complete list of members for TheRulbusInterface, including all inherited members.
ANY_RACK | TheRulbusInterface | [static]
getByte(int rack, int offset) const | TheRulbusInterface |
getReg(int offset) const =0 | TheRulbusInterface | [protected, pure virtual]
instance() | TheRulbusInterface | [inline, static]
invariant() const | TheRulbusInterface | [inline, virtual]
printOn(std::ostream &stream) const =0 | TheRulbusInterface | [pure virtual]
putByte(int rack, int offset, int byte) const | TheRulbusInterface |
putReg(int offset, int byte) const =0 | TheRulbusInterface | [protected, pure virtual]
s | TheRulbusInterface | [private]
Singleton< TheRulbusInterface > (defined in TheRulbusInterface) | TheRulbusInterface | [friend]
theInstance | Singleton< TheRulbusInterface > | [protected, static]
TheRulbusInterface() | TheRulbusInterface | [protected]
~TheRulbusInterface() | TheRulbusInterface | [protected]
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

Via Member List

This is the complete list of members for Via, including all inherited members.
addr() const | RulbusDevice | [inline]
ADR_WIDTH | Via | [private, static]
ANY_RACK | RulbusDevice | [static]
checkBusViolation(int offset, int byte) const | RulbusDevice | [protected]
checkData(int dat) | PiaVia | [protected]
checkDir(char dir) | PiaVia | [protected]
checkMask(int msk) | PiaVia | [protected]
checkPin(int pin) | PiaVia | [protected]
checkValidAddress(int offset=0) const | RulbusDevice | [protected]
DEF_ADDR | Via | [static]
DEF_RACK | Via | [static]
eqAddr(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
eqRack(RulbusDeviceCref rhs) const | RulbusDevice | [inline]
getByte(int offset) const | RulbusDevice |
getDataPA() | PiaVia | [virtual]
getDataPB() | PiaVia | [virtual]
getDDRA() | Via | [protected, virtual]
getDDRB() | Via | [protected, virtual]
getDirC2(int shift) | Via | [private]
getDirCA2() | Via | [virtual]
getDirCB2() | Via | [virtual]
getDirPA() | PiaVia | [virtual]
getDirPB() | PiaVia | [virtual]
getEdgeC1(int shift) | Via | [private]
getEdgeCA1() | Via | [virtual]
getEdgeCB1() | Via | [virtual]
getIntrC1(int mask) | Via | [private]
getIntrCA1() | Via | [virtual]
getIntrCB1() | Via | [virtual]
getIrqC1(int mask) | Via | [private]
getIrqCA1() | Via | [virtual]
getIrqCB1() | Via | [virtual]
getLevelC2(int shift, char port) | Via | [private]
getLevelCA2() | Via | [virtual]
getLevelCB2() | Via | [virtual]
getLineDir(CharCptr lin) | PiaVia | [virtual]
getLineDirPA(int pin) | PiaVia | [virtual]
getLineDirPB(int pin) | PiaVia | [virtual]
getLineLevel(CharCptr lin) | PiaVia | [virtual]
getLineLevelPA(int pin) | PiaVia | [virtual]
getLineLevelPB(int pin) | PiaVia | [virtual]
getPDRA() | Via | [protected, virtual]
getPDRB() | Via | [protected, virtual]
getPortData(CharCptr ptr) | PiaVia | [virtual]
getPortDir(CharCptr prt) | PiaVia | [virtual]
MSK_ATC1 | Via | [private, static]
MSK_DIRC2 | Via | [private, static]
MSK_IECA1 | Via | [private, static]
MSK_IECA2 | Via | [private, static]
MSK_IECB1 | Via | [private, static]
MSK_IECB2 | Via | [private, static]
MSK_IECT1 | Via | [private, static]
MSK_IECT2 | Via | [private, static]
MSK_IESC | Via | [private, static]
MSK_IESR | Via | [private, static]
MSK_IFCA1 | Via | [private, static]
MSK_IFCA2 | Via | [private, static]
MSK_IFCB1 | Via | [private, static]
MSK_IFCB2 | Via | [private, static]
MSK_IFCT1 | Via | [private, static]
MSK_IFCT2 | Via | [private, static]
MSK_IFIRQ | Via | [private, static]
MSK_IFSR | Via | [private, static]
MSK_OLC2 | Via | [private, static]
MSK_POC2 | Via | [private, static]
name() const | RulbusDevice | [inline]
OFF_ACR | Via | [private, static]
OFF_DDRA | Via | [private, static]
OFF_DDRB | Via | [private, static]
OFF_IER | Via | [private, static]
OFF_IFR | Via | [private, static]
OFF_PCR | Via | [private, static]
OFF_PDRA | Via | [private, static]
OFF_PDRA_NH | Via | [private, static]
OFF_PDRB | Via | [private, static]
OFF_SR | Via | [private, static]
OFF_T1CH | Via | [private, static]
OFF_T1CL | Via | [private, static]
OFF_T1LH | Via | [private, static]
OFF_T1LL | Via | [private, static]
OFF_T2CH | Via | [private, static]
OFF_T2CL | Via | [private, static]
operator=(RulbusDeviceCref) | RulbusDevice | [protected]
PiaVia(NameCref aName, Addr aAddr, Addr aWidth, Rack aRack) (defined in PiaVia) | PiaVia | [inline]
printOn(std::ostream &stream) const | RulbusDevice | [virtual]
putByte(int offset, int byte) const | RulbusDevice |
rack() const | RulbusDevice | [inline]
RulbusDevice(Name aName, Addr aAddr, Addr aWidth, Rack aRack) | RulbusDevice |
RulbusDevice() | RulbusDevice | [protected]
RulbusDevice(RulbusDeviceCref) | RulbusDevice | [protected]
setAddr(Addr aAddr) | RulbusDevice |
setDataPA(int dat) | PiaVia | [virtual]
setDataPB(int dat) | PiaVia | [virtual]
setDDRA(int dir) | Via | [protected, virtual]
setDDRB(int dir) | Via | [protected, virtual]
setDirC2(int shift, char dir, char port) | Via | [private]
setDirCA2(char dir) | Via | [virtual]
setDirCB2(char dir) | Via | [virtual]
setDirPA(int msk) | PiaVia | [virtual]
setDirPB(int msk) | PiaVia | [virtual]
setEdgeC1(int shift, char edge, char port) | Via | [private]
setEdgeCA1(char edge) | Via | [virtual]
setEdgeCB1(char edge) | Via | [virtual]
setIntrC1(int mask, int enable) | Via | [private]
setIntrCA1(int enable) | Via | [virtual]
setIntrCB1(int enable) | Via | [virtual]
setLevelC2(int shift, int lvl, char port) | Via | [private]
setLevelCA2(int lvl) | Via | [virtual]
setLevelCB2(int lvl) | Via | [virtual]
setLineDir(CharCptr lin, char dir) | PiaVia | [virtual]
setLineDirPA(int pin, char dir) | PiaVia | [virtual]
setLineDirPB(int pin, char dir) | PiaVia | [virtual]
setLineLevel(CharCptr lin, int lvl) | PiaVia | [virtual]
setLineLevelPA(int pin, int lvl) | PiaVia | [virtual]
setLineLevelPB(int pin, int lvl) | PiaVia | [virtual]
setPDRA(int dat) | Via | [protected, virtual]
setPDRB(int dat) | Via | [protected, virtual]
setPortData(CharCptr prt, int dat) | PiaVia | [virtual]
setPortDir(CharCptr prt, int msk) | PiaVia | [virtual]
setRack(Rack aRack) | RulbusDevice |
SHL_CA | Via | [private, static]
SHL_CB | Via | [private, static]
theRulbus() | RulbusDevice | [inline, protected, static]
Via(NameCref aName, Addr aAddr=DEF_ADDR, Rack aRack=DEF_RACK) | Via | [inline]
width() const | RulbusDevice | [inline]
~PiaVia() | PiaVia | [inline, virtual]
~RulbusDevice() | RulbusDevice | [virtual]
~Via() | Via | [inline, virtual]
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Common.h Source File

Common.h

00001 /*
00002  * Common.h - type declarations, (debug) macro's, assertion classes.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: Common.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __COMMON_H
00026 #define __COMMON_H
00027 #define __IN_COMMON_H
00028
00029 #include <math>         // for std::fabs
00030 #include <limits>       // for std::numeric_limits<>
00031 #include <string>       // for std::String
00032
00098 #ifdef DOXYGEN
00099    #define DEBUG DFLAG_ALL
00100 #endif
00101
00102 #define DFLAG_NONE              0x0000
00103 #define DFLAG_ALL               0xFFFF
00104 #define DFLAG_PRODUCTION        (DFLAG_ALL & ~DFLAG_ENSURE)
00105
00106 #define DFLAG_GENERAL           0x0001
00107 #define DFLAG_INTERFACE         0x0002
00108 #define DFLAG_BUSVIOLATION      0x0004
00109 #define DFLAG_REQUIRE           0x0010
00110 #define DFLAG_ENSURE            0x0020
00111 #define DFLAG_NEVER_GET_HERE    0x0040
00112
00113 #if !defined( DEBUG )
00114 #define DEBUG DFLAG_NONE
00115 #endif
00116
00121 #define dim(a) (sizeof(a)/sizeof((a)[0]))
00122
00127 #define DECLARE_TYPE( mydecl, mytype )  \
00128 typedef mydecl         mytype;          \
00129 typedef mytype *       mytype ## Ptr;   \
00130 typedef const mytype * mytype ## Cptr;  \
00131 typedef mytype &       mytype ## Ref;   \
00132 typedef const mytype & mytype ## Cref;
00133
00138 #define DECLARE_CLASS( tag )            \
00139    class   tag;                         \
00140    typedef tag *       tag ## Ptr;      \
00141    typedef const tag * tag ## Cptr;     \
00142    typedef tag &       tag ## Ref;      \
00143    typedef const tag & tag ## Cref;
00144
00145 #if 0
00146
00150    #define PROXY_CAST   static_cast
00151 #else
00152
00156    #define PROXY_CAST   dynamic_cast
00157 #endif
00158
00159
00161
00166 namespace Rulbus
00167 {
00315
00316
00317    //
00318    // compiler types:
00319    //
00320
00321    DECLARE_TYPE(        signed char, int8   );  // signed 8-bit integral type
00322    DECLARE_TYPE(      unsigned char, uInt8  );  // signed 8-bit integral type
00323    DECLARE_TYPE(   signed short int, int16  );  // signed 16-bit integral type
00324    DECLARE_TYPE( unsigned short int, uInt16 );  // unsigned 16-bit integral type
00325    DECLARE_TYPE(         signed int, int32  );  // signed 32-bit integral type
00326    DECLARE_TYPE(       unsigned int, uInt32 );  // unsigned 32-bit integral type
00327    DECLARE_TYPE(              float, float32 ); // 32-bit real type (Real32)
00328    DECLARE_TYPE(             double, float64 ); // 64-bit real type (Real64)
00329
00330    //
00331    // library types:
00332    //
00333
00334    DECLARE_TYPE(              uInt8, Byte   );  // Byte type
00335    DECLARE_TYPE(             uInt16, Word   );  // Word type
00336    DECLARE_TYPE(             uInt32, Quad   );  // Double word type
00337    DECLARE_TYPE(               char, Char   );  // character type
00338    DECLARE_TYPE(                int, Int    );  // integral type
00339    DECLARE_TYPE(              int16, Int16  );  // 16-bit signed integral type
00340    DECLARE_TYPE(              int32, Int32  );  // 32-bit signed integral type
00341    DECLARE_TYPE(             double, Real   );  // real type
00342    DECLARE_TYPE(            float32, Real32 );  // 32-bit real type
00343    DECLARE_TYPE(            float64, Real64 );  // 64-bit real type
00344
00345    DECLARE_TYPE(        std::string, String       );    // String type
00346    DECLARE_TYPE(     std::exception, StdException );    // StdException type
00347
00348    DECLARE_TYPE(             String, Name   );  // Name type
00349    DECLARE_TYPE(                Int, Addr   );  // Addr type
00350    DECLARE_TYPE(                Int, Rack   );  // Rack type
00351
00352    DECLARE_TYPE(               Real, Volt   );  // Voltage type [V]
00353    DECLARE_TYPE(             Real32, Volt32 );  // 32-bit Voltage type [V]
00354    DECLARE_TYPE(               Real, Time   );  // Time type [s]
00355    DECLARE_TYPE(               Real, Freq   );  // Frequency type [Hz]
00356    DECLARE_TYPE(               Real, Length );  // Length type [m]
00357
00369    template <typename aType>
00370    struct isEqual
00371    {
00376       isEqual( aType a ): m_a(a) { }
00377
00382       bool operator()( aType b )
00383       {
00384          return std::fabs( b - m_a ) < std::numeric_limits<aType>::epsilon();
00385       }
00386
00387       aType m_a;
00388    };
00389
00390    typedef isEqual<Volt> isEqualVolt;
00391    typedef isEqual<Time> isEqualTime;
00392    typedef isEqual<Freq> isEqualFreq;
00393
00395
00396 } // namespace Rulbus
00397
00398 #include "Shims.h"              // for to_cstr(), used in Exception.h
00399 #include "Assertion.h"          // for design-by-contract exceptions, assertions
00400 #include "Exception.h"          // for our exceptions
00401
00402 #undef __IN_COMMON_H
00403 #endif  // __COMMON_H
00404
00405 /*
00406  * end of file
00407  */
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigBuilder.h Source File

ConfigBuilder.h

00001 /*
00002  * ConfigBuilder.h - Rulbus Device builder for Rulbus configuration file.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: ConfigBuilder.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __CONFIGBUILDER_H
00026 #define __CONFIGBUILDER_H
00027
00028 #ifndef __COMMON_H
00029 #include "Common.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( ConfigBuilder     );
00035    DECLARE_CLASS( ConfigPrinter     );
00036    DECLARE_CLASS( ConfigListBuilder );
00037    DECLARE_CLASS( RulbusDevice        );        // declare
00038
00051    class ConfigBuilder
00052    {
00053    public:
00058       virtual void add( RulbusDevicePtr ptr ) = 0;
00059
00060       /*
00061        * check the built object for consistency.
00062        */
00063
00064       virtual void check( ) const;
00065    };
00066
00072    inline void ConfigBuilder::check( ) const
00073    {
00074       ; // do nothing
00075    }
00076
00084    class ConfigListBuilder : public ConfigBuilder
00085    {
00086    public:
00087       ConfigListBuilder( );
00088
00089       void add  ( RulbusDevicePtr ptr );
00090       void check(                     ) const;
00091
00092    private:
00093    };
00094
00102    class ConfigPrinter : public ConfigBuilder
00103    {
00104    public:                              // public methods
00105       ConfigPrinter( std::ostream& aStream );
00106
00107       void add( RulbusDevicePtr ptr );
00108
00109    private:
00110       std::ostream& theStream;
00111    };
00112
00113 } // namespace Rulbus
00114
00115 #endif  // __CONFIGBUILDER_H
00116
00117 /*
00118  * end of file
00119  */
00120
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigContext.h Source File

ConfigContext.h

00001 /*
00002  * RulbusConfigContext.h - class RulbusConfigContext.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: ConfigContext.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __CONFIGCONTEXT_H
00026 #define __CONFIGCONTEXT_H
00027
00028 #ifndef __COMMON_H
00029 #include "Common.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RulbusConfigContext );
00035
00046    class ConfigContext
00047    {
00048    };
00049
00050 } // namespace Rulbus
00051
00052 #endif  // __CONFIGCONTEXT_H
00053
00054 /*
00055  * end of file
00056  */
00057
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigParser.h Source File

ConfigParser.h

00001 /*
00002  * ConfigParser.h - parser for Rulbus configuration file.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: ConfigParser.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __CONFIGPARSER_H
00026 #define __CONFIGPARSER_H
00027
00028 #include <vector>                       // for CardList
00029
00030 #ifndef __COMMON_H
00031 #include "Common.h"
00032 #endif
00033
00034 #include "ConfigScanner.h"              // header
00035
00036 namespace Rulbus
00037 {
00038    DECLARE_CLASS( ConfigParser  );
00039    DECLARE_CLASS( ConfigScanner );
00040    DECLARE_CLASS( ConfigBuilder );
00041    DECLARE_CLASS( ConfigContext );
00042    DECLARE_CLASS( RulbusDevice  );
00043
00137    class ConfigParser
00138    {
00139    public:
00140       ConfigParser( ConfigScanner& scanner, ConfigBuilder& builder, ConfigContext& context );
00141
00142       void parse();
00143
00144    protected:
00145       void parseProgram();
00146
00147       void parseFileAssignment();
00148
00149       void parseRackDeclarationSequence();
00150       void parseRackDeclaration();
00151       void parseRackInitializer();
00152
00153       void parseRackAddressAssignment();
00154       void parseCardDeclarationSequence();
00155       void parseCardDeclaration();
00156       void parseCardInitializer( ConfigToken::TokenCode card );
00157 //      void parseRB8506 ();    // generic
00158       void parseRB8509 ( bool scanProperties = true );
00159       void parseRB8510 ( bool scanProperties = true );
00160       void parseRB8514 ( bool scanProperties = true );
00161 //      void parseRB8515 ();    // generic
00162       void parseRB8905 ( bool scanProperties = true );
00163 //      void parseRB9005 ( bool scanProperties = true );
00164
00165       void parseGenericCard( ConfigToken::TokenCode card, bool scanProperties = true );
00166
00167       Int  parseAddress        ( ConfigToken::TokenCode token = ConfigToken::tcCARD );
00168       bool parseHasExtTrigger  ( );
00169       Int  parseNumChannels    ( );
00170       bool parseBipolar        ( );
00171       Real parseVoltPerBit     ( );
00172       Real parseIntrDelay      ( );
00173
00174       bool parseBooleanProperty( ConfigToken::TokenCode token );
00175       Int  parseIntegerProperty( ConfigToken::TokenCode token );
00176       Real parseRealProperty   ( ConfigToken::TokenCode token );
00177       Real parseOptUnit        ( ConfigToken::TokenCode token );
00178
00179       void parseOptDelimiter   ( );
00180       void parseOptAssignOp    ( );
00181
00182       void checkRackAllowed      ( );
00183       void checkDuplicateRackName( );
00184       void checkDuplicateCardName( );
00185       void checkRackDeclaration  ( );
00186       void checkCardDeclarations ( );
00187       void checkDuplicateRackAddr( bool withline = false );
00188       void checkOverlapCardAddr  ( bool withline = false );
00189
00190       void addCard( RulbusDevicePtr card );
00191       void clearRackCardList    ( );
00192       void updateRackCardList   ( );
00193
00194       void getToken( );
00195       bool test    ( ConfigToken::TokenCode token, bool require = true );
00196       void expect  ( ConfigToken::TokenCode token, bool require = true );
00197
00205       class ParseError : public std::logic_error
00206       {
00207       public:
00209          ParseError( StringCref msg ) : std::logic_error( to_cstr( msg ) )
00210          {
00211             ; //do nothing
00212          }
00213       };
00214
00215    private:
00216       typedef std::vector<RulbusDevicePtr> CardList;
00217       typedef std::vector<String>          NameList;
00218       typedef std::vector<bool>            AddrList;
00219       typedef std::vector<int>             LineList;
00220
00221       ConfigToken::TokenCode t;
00222
00223       ConfigScanner *theScanner;
00224       ConfigBuilder& theBuilder;
00225       ConfigContext& theContext;
00226       ConfigToken   *theToken;
00227
00228       String         theRackName;
00229       Int            theRackAddress;
00230       Int            theRackLine;
00231
00232       String         theCardName;
00233       Int            theCardAddress;
00234
00235       CardList       theCardList;
00236       NameList       theCardNameList;
00237       LineList       theCardLineList;
00238
00239       CardList       theRackCardList;
00240       AddrList       theRackAddrSet;
00241       NameList       theRackNameSet;
00242       LineList       theRackLineSet;
00243
00244    private:
00245       static const int DEF_CARDS = 32;
00246       static const int LIM_RACKS = 16;
00247
00248       static CharCptr already_assigned;
00249    };
00250
00251 } // namespace Rulbus
00252
00253 #endif  // __CONFIGPARSER_H
00254
00255 /*
00256  * end of file
00257  */
00258
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: ConfigScanner.h Source File

ConfigScanner.h

00001 /*
00002  * ConfigScanner.h - lexical scanner for Rulbus configuration file.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  * This library is free software, see below.
00008  *
00009  * $Revision: $
00010  * $Date: $
00011  * $Source: $
00012  * %Author: Martin J. Moene %
00013  *
00014  * Compiler        : Borland-C++ 5.6
00015  * Operating system: 32-bit Windows
00016  * Hardware system : PC
00017  *
00018  * This library is free software; you can redistribute it and/or modify
00019  * it under the terms of the GNU General Public License as published by
00020  * the Free Software Foundation; either version 2 of the License, or
00021  * (at your option) any later version.
00022  *
00023  * The library is distributed in the hope that it will be useful,
00024  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00025  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00026  * GNU General Public License for more details.
00027  *
00028  * You should have received a copy of the GNU General Public License
00029  * along with mngdriver; if not, write to the Free Software
00030  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00031  */
00032
00033 /*
00034  * $Header: $
00035  *
00036  * $Log: $
00037  */
00038
00039 #ifndef __CONFIGSCANNER_H
00040 #define __CONFIGSCANNER_H
00041
00042 #ifndef __COMMON_H
00043 #include "Common.h"
00044 #endif
00045
00046 #include <iosfwd>                               // for std::istream
00047
00048 namespace Rulbus
00049 {
00050    DECLARE_CLASS( ConfigScanner );
00051    DECLARE_CLASS( ConfigToken   );
00052
00060    class ConfigToken
00061    {
00062    public:
00067       enum TokenCode
00068       {
00069          #define op( a, b, c, d ) a = static_cast<TokenCode>( b ),
00070          #define id( a, b, c, d ) a = static_cast<TokenCode>( b ),
00071          #define kw( a, b, c, d ) a = static_cast<TokenCode>( b ),
00072          #include "ConfigToken.def"
00073          tcLAST,
00074       };
00075
00076                ConfigToken() { ; }
00077       virtual ~ConfigToken() { ; }
00078
00080       virtual  void get  ( std::istream *is ) = 0;
00081
00083       virtual  void print() const = 0;
00084
00085       bool        isBool () const;
00086       bool        isAsnop() const;
00087       bool        isCard () const;
00088       bool        isDelim() const;
00089       bool        isUnit () const;
00090       bool        isKind ( TokenCode t ) const;
00091
00092       TokenCode     code () const;
00093
00094       bool        toBool () const;
00095       Int          toInt () const;
00096       Real        toReal () const;
00097       String    toString () const;
00098
00099       String    tokenString(              ) const;
00100       String    tokenString( TokenCode t  ) const;
00101
00102    protected:
00103       TokenCode theTokenCode;
00104       Int       theIntValue;
00105       Real      theRealValue;
00106       String    theString;
00107
00108    private:
00109       static    CharCptr  stringTable[];
00110       static    TokenCode kindTable[];
00111    };
00112
00117    inline bool ConfigToken::isAsnop() const
00118    {
00119       return isKind( tcASN );
00120    }
00121
00126    inline bool ConfigToken::isBool() const
00127    {
00128       return isKind( tcBOOL );
00129    }
00130
00135    inline bool ConfigToken::isCard() const
00136    {
00137       return isKind( tcCARD );
00138    }
00139
00144    inline bool ConfigToken::isDelim() const
00145    {
00146       return isKind( tcDELIM );
00147    }
00148
00153    inline bool ConfigToken::isUnit () const
00154    {
00155       return isKind( tcUNIT );
00156    }
00157
00162    inline ConfigToken::TokenCode ConfigToken::code () const
00163    {
00164       return theTokenCode;
00165    }
00166
00171    inline bool ConfigToken::toBool() const
00172    {
00173       return tcTRUE == code() || tcYES == code();
00174    }
00175
00180    inline Int ConfigToken::toInt() const
00181    {
00182       return theIntValue;
00183    }
00184
00189    inline Real ConfigToken::toReal() const
00190    {
00191       return theRealValue;
00192    }
00193
00198    inline String ConfigToken::toString() const
00199    {
00200       return theString;
00201    }
00202
00209    class ConfigWordToken: public ConfigToken
00210    {
00211    public:
00212       void  get   (std::istream *is);
00213       void  print (                ) const;
00214    };
00215
00222    class ConfigNumberToken: public ConfigToken
00223    {
00224    public:
00225       ConfigNumberToken() { theTokenCode = tcNUMBER; }
00226
00227       void  get   ( std::istream *is );
00228       void  print (                  ) const;
00229
00230    protected:
00231       Real  suffix(char chr);
00232    };
00233
00240    class ConfigStringToken: public ConfigToken
00241    {
00242    public:
00243       ConfigStringToken() { theTokenCode = tcSTRING; }
00244
00245       void  get   ( std::istream *is );
00246       void  print (                  ) const;
00247    };
00248
00256    class ConfigSpecialToken: public ConfigToken
00257    {
00258    public:
00259       void  get   ( std::istream *is );
00260       void  print (                  ) const;
00261    };
00262
00269    class ConfigEofToken: public ConfigToken
00270    {
00271    public:
00272       ConfigEofToken() { theTokenCode = tcEOF; }
00273
00274    #pragma argsused
00275       void  get   ( std::istream *is )  { }
00276       void  print (                  ) const;
00277    };
00278
00286    class ConfigErrorToken: public ConfigToken
00287    {
00288    public:
00289       ConfigErrorToken() { theTokenCode = tcERROR; }
00290
00291       void  get   ( std::istream *is );
00292       void  print (                  ) const;
00293    };
00294
00317    class ConfigScanner
00318    {
00319    public:
00320       virtual           ~ConfigScanner( );
00321 //                     ConfigScanner( String aFilename );
00322                         ConfigScanner( std::istream& stream, String aFilename = "" );
00323
00324       ConfigToken      *get();
00325       String            filename  () const;
00326       Int               linenumber() const;
00327
00328    protected:
00329       void              skipWhitespace();
00330
00331       bool              seechar( char& chr );
00332
00333       ConfigWordToken   wordToken;
00334       ConfigNumberToken numberToken;
00335       ConfigStringToken stringToken;
00336       ConfigSpecialToken specialToken;
00337       ConfigEofToken    eofToken;
00338       ConfigErrorToken  errorToken;
00339
00340    private:
00341       std::istream     *is;
00342       String            theFilename;
00343       Int               theLinenumber;
00344    };
00345
00350    inline String ConfigScanner::filename() const
00351    {
00352       return theFilename;
00353    }
00354
00356    inline Int ConfigScanner::linenumber() const
00357    {
00358       return theLinenumber;
00359    }
00360
00361 } // namespace Rulbus
00362
00363 #endif  // __CONFIGSCANNER_H
00364
00365 /*
00366  * end of file
00367  */
00368
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: EppRulbusInterface.h Source File

EppRulbusInterface.h

00001 /*
00002  * EppRulbusInterface.h - class EppRulbusInterface.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: EppRulbusInterface.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __EPPRULBUSINTERFACE_H
00026 #define __EPPRULBUSINTERFACE_H
00027
00028 #ifndef __RULBUSINTERFACE_H
00029    #include "RulbusInterface.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( EppRulbusInterface );
00035
00062    class EppRulbusInterface : public TheRulbusInterface
00063    {
00064    public:                                         // P U B L I C
00066
00067       EppRulbusInterface( Quad base = DEF_EPP_BASE, bool docheck = true );
00068
00071
00072       Quad base() const;
00073       bool invariant () const;
00074
00077
00078       bool printOn( std::ostream& stream ) const;
00079
00080    protected:                                      // P R O T E C T E D
00083
00084       EppRulbusInterface( EppRulbusInterfaceRef );
00085       EppRulbusInterfaceRef operator=( EppRulbusInterfaceRef );
00086
00090
00091       int    putReg( int offset, int byte ) const;
00092       int    getReg( int offset           ) const;
00093
00097
00098       bool   interfacePresent( int *pCode ) const;
00099
00100       int    readAddress     () const;
00101       int    readData        () const;
00102
00103       bool   EppTimedOut     () const;
00104
00108
00109       void   writeAddress    ( int addr ) const;
00110       void   writeData       ( int byte ) const;
00111
00112 //      void   setForward      () const;
00113 //      void   setReverse      () const;
00114
00115       void   resetInterface  () const;
00116       void   initializeEpp   () const;
00117       bool   clearEppTimeout () const;
00118
00120
00121    public:                                         // P U B L I C
00122       static const Quad DEF_EPP_BASE = 0x0378;
00123
00124    private:                                        // P R I V A T E
00125       Quad   theBase;
00126
00129
00130       static const int OFF_SPP_DATA  = 0;
00131       static const int OFF_SPP_STAT  = 1;
00132       static const int OFF_SPP_CTRL  = 2;
00133       static const int OFF_EPP_ADDR  = 3;
00134       static const int OFF_EPP_DATA  = 4;
00135
00139
00140       static const int MSK_EPP_Timeout    = 0x01;
00141       static const int MSK_SPP_Reserved2  = 0x02;
00142       static const int MSK_SPP_nIRQ       = 0x04;
00143       static const int MSK_SPP_nError     = 0x08;
00144       static const int MSK_SPP_SelectIn   = 0x10;
00145       static const int MSK_SPP_PaperOut   = 0x20;
00146       static const int MSK_SPP_nAck       = 0x40;
00147       static const int MSK_SPP_nBusy      = 0x80;
00148
00152
00153       static const int MSK_SPP_Strobe       = 0x01;
00154       static const int MSK_SPP_AutoLF       = 0x02;
00155       static const int MSK_SPP_nReset       = 0x04;
00156       static const int MSK_SPP_SelectPrinter= 0x08;
00157       static const int MSK_SPP_EnaIRQVAL    = 0x10;
00158       static const int MSK_SPP_EnaBiDirect  = 0x20;
00159       static const int MSK_SPP_Unused1      = 0x40;
00160       static const int MSK_SPP_Unused2      = 0x80;
00161
00163
00164       static CharCptr  msgtitle;
00165    };
00166
00171    inline Quad EppRulbusInterface::base() const
00172    {
00173       return theBase;
00174    }
00175
00180    inline bool EppRulbusInterface::invariant() const
00181    {
00182       return BASE_INVARIANT( TheRulbusInterface );
00183    }
00184
00185 }       // namespace Rulbus
00186
00187 #endif  // __EPPRULBUSINTERFACE_H
00188
00189 /*
00190  * end of file
00191  */
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Exception.h Source File

Exception.h

00001 /*
00002  * exception.h - environmetal, or usage error Exception classes.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: Exception.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __EXCEPTION_H
00026 #define __EXCEPTION_H
00027
00028 #ifndef __COMMON_H
00029    #include "Common.h"
00030 #endif
00031
00032 #include <stdexcept>            // for standard exceptions
00033
00034 #if __BCPLUSPLUS__ < 0x0560
00035    using std::__threadid;       // needed for Borland C++ 5.5.1; _stddef.h apparently errs
00036 #endif
00037
00038 namespace Rulbus
00039 {
00040    DECLARE_CLASS( RulbusError          );
00041    DECLARE_CLASS( RulbusScanError      );
00042    DECLARE_CLASS( RulbusParseError     );
00043    DECLARE_CLASS( RulbusConfigError    );
00044    DECLARE_CLASS( RulbusInterfaceError );
00045    DECLARE_CLASS( RulbusOpenError      );
00046    DECLARE_CLASS( RulbusCloseError     );
00047    DECLARE_CLASS( RulbusHandleError    );
00048    DECLARE_CLASS( RulbusAddressError   );
00049    DECLARE_CLASS( RulbusRangeError     );
00050    DECLARE_CLASS( RulbusContextError   );
00051    DECLARE_CLASS( RulbusTimeoutError   );
00052
00057    inline CharCptr to_cstr( const String& s )
00058    {
00059       return s.c_str();
00060    }
00061
00111    class RulbusError : public StdException
00112    {
00113    public:
00116
00118       RulbusError() { tid = _threadid; theError = *this; }
00119
00121       RulbusError( CharCptr fmt ... );
00122
00123       // RulbusError(CharCptr fmt, va_list ap );
00124
00126       RulbusError( StringCref string );
00127
00129       RulbusError( StdExceptionCref e ) { msg = e.what(); tid = _threadid; theError = *this; }
00130
00132       RulbusError( RulbusErrorCref e ) { msg = e.msg; tid = e.tid; theError = *this; }
00133
00135       virtual ~RulbusError() { ; }
00136
00140
00142       virtual  CharCptr      what   () const { return to_cstr( msg ); }
00143
00145       virtual  unsigned long lasttid() const { return tid;         }
00146
00147       static   bool     getLastError( char *msg, int maxlen );
00148
00150
00151    private:
00152       String msg;
00153       unsigned long tid;
00154
00155       static RulbusError theError;
00156    };
00157
00166    class RulbusScanError : public RulbusError
00167    {
00168    public:
00170       RulbusScanError( StringCref msg ):
00171          RulbusError( msg ) { ; }
00172    };
00173
00182    class RulbusParseError : public RulbusError
00183    {
00184    public:
00186       RulbusParseError( StringCref msg ):
00187          RulbusError( msg ) { ; }
00188    };
00189
00199    class RulbusConfigError : public RulbusError
00200    {
00201    public:
00203       RulbusConfigError( StringCref msg ):
00204          RulbusError( to_cstr( msg ) ) { ; }
00205    };
00206
00214    class RulbusInterfaceError : public RulbusError
00215    {
00216    public:
00218       RulbusInterfaceError( StringCref msg ):
00219          RulbusError( to_cstr( msg )  ) { ; }
00220    };
00221
00229    class RulbusOpenError : public RulbusError
00230    {
00231    public:
00233       RulbusOpenError( StringCref submsg ):
00234          RulbusError( "cannot open rulbus device: %s", to_cstr( submsg ) ) { ; }
00235
00237       RulbusOpenError( StringCref name, int rack, int addr ):
00238          RulbusError( "cannot open rulbus device '%s' at [%d:0x%02X]", to_cstr( name ), rack, addr ) { ; }
00239    };
00240
00248    class RulbusCloseError : public RulbusError
00249    {
00250    public:
00252       RulbusCloseError( int handle ):
00253          RulbusError("cannot close rulbus device with handle '%d'", handle ) { ; }
00254    };
00255
00263    class RulbusHandleError : public RulbusError
00264    {
00265    public:
00267       RulbusHandleError( int handle ):
00268          RulbusError("invalid handle '%d'", handle ) { ; }
00269    };
00270
00278    class RulbusAddressError : public RulbusError
00279    {
00280    public:
00282       RulbusAddressError( StringCref name, int rack, int addr ):
00283          RulbusError("address violation, device '%s', address [%d:0x%02X]", to_cstr( name ), rack, addr ) { ; }
00284    };
00285
00293    class RulbusDataError : public RulbusError
00294    {
00295    public:
00297       RulbusDataError( StringCref name, int rack, int addr, int data ):
00298          RulbusError("data violation, device '%s', address [%d:0x%02X], data [0x%02X]", to_cstr( name ), rack, addr, data ) { ; }
00299    };
00300
00308    class RulbusRangeError : public RulbusError
00309    {
00310    public:
00312       RulbusRangeError( ):
00313          RulbusError() { ; }
00314
00316       RulbusRangeError( StringCref name, StringCref parameter, int data, int min, int max ):
00317          RulbusError("device '%s', range error: %s %d not in [%d..%d]", to_cstr( name ), to_cstr( parameter ), data, min, max ) { ; }
00318
00320       RulbusRangeError( StringCref name, StringCref parameter, long data, long min, long max ):
00321          RulbusError("device '%s', range error: %s %ld not in [%ld..%ld]", to_cstr( name ), to_cstr( parameter ), data, min, max ) { ; }
00322
00324       RulbusRangeError( StringCref name, StringCref parameter, Real data, Real min, Real max ):
00325          RulbusError("device '%s', range error: %s %g not in [%g..%g]", to_cstr( name ), to_cstr( parameter ), data, min, max ) { ; }
00326
00328       RulbusRangeError( StringCref name, StringCref parameter, StringCref data, StringCref set ):
00329          RulbusError("device '%s', range error: %s %s not in [%s]", to_cstr( name ), to_cstr( parameter ), to_cstr( data ), to_cstr( set ) ) { ; }
00330    };
00331
00339    class RulbusContextError : public RulbusError
00340    {
00341    public:
00343       RulbusContextError( StringCref name, StringCref msg ):
00344          RulbusError("device '%s', context error: %s", to_cstr( name ), to_cstr( msg ) ) { ; }
00345    };
00346
00354    class RulbusTimeoutError : public RulbusError
00355    {
00356    public:
00358       RulbusTimeoutError( ):
00359          RulbusError() { ; }
00360
00362       RulbusTimeoutError( StringCref name, StringCref msg ):
00363          RulbusError("device '%s', timeout: %s", to_cstr( name ), to_cstr( msg ) ) { ; }
00364    };
00365
00368 }       // namespace Rulbus
00369
00370 #endif  // __EXCEPTION_H
00371
00372 /*
00373  * end of file
00374  */
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Compound Member Index

  • ComCodes : RB9603_monochromator
  • TokenCode : ConfigToken
  • Type : DbcException
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Compound Member Index

  • COM_CNT : RB9603_monochromator
  • COM_EOT : RB9603_monochromator
  • COM_GET : RB9603_monochromator
  • COM_LEN : RB9603_monochromator
  • COM_RDY : RB9603_monochromator
  • COM_SLPMS : RB9603_monochromator
  • FC_0Hz : RB8515_clock
  • FC_100Hz : RB8515_clock
  • FC_100kHz : RB8515_clock
  • FC_100MHz : RB8515_clock
  • FC_10kHz : RB8515_clock
  • FC_10MHz : RB8515_clock
  • FC_1kHz : RB8515_clock
  • FC_1MHz : RB8515_clock
  • FC_INVALID : RB8515_clock
  • FI_0Hz : RB8515_clock
  • FI_100Hz : RB8515_clock
  • FI_10Hz : RB8515_clock
  • FI_1Hz : RB8515_clock
  • FI_1kHz : RB8515_clock
  • FI_500Hz : RB8515_clock
  • FI_50Hz : RB8515_clock
  • FI_5kHz : RB8515_clock
  • FI_INVALID : RB8515_clock
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Compound Member Index

- a -

  • adcMeanWavelength() : RB9603_monochromator
  • adcWavelength() : RB9603_monochromator
  • add() : TheRulbusDeviceList, ConfigPrinter, ConfigListBuilder, ConfigBuilder
  • addCard() : ConfigParser
  • addr() : RulbusDevice
  • arm() : RB8905_Adc12
  • AssertException() : AssertException
  • Assertion() : Assertion
  • autoscale() : RB8509_Adc12

- b -

  • base() : IsaRulbusInterface, EppRulbusInterface
  • begin() : PportAddresses
  • boolalpha() : IoFormat
  • BoundIoFormat() : BoundIoFormat
  • bufferCapacity() : RB8905_Adc12
  • bufferSize() : RB8905_Adc12

- c -

  • calibrate() : RB9603_monochromator
  • channel() : RB9005_amplifier, RB8509_Adc12
  • check() : TheRulbusDeviceList, ConfigListBuilder, ConfigBuilder
  • checkBusViolation() : RulbusDevice
  • checkCardDeclarations() : ConfigParser
  • checkChannel() : RB9005_amplifier, RB8509_Adc12
  • checkData() : PiaVia
  • checkDir() : PiaVia
  • checkDuplicateCardName() : ConfigParser
  • checkDuplicateRackAddr() : ConfigParser
  • checkDuplicateRackName() : ConfigParser
  • checkGain() : RB8509_Adc12
  • checkMask() : PiaVia
  • checkOverlapCardAddr() : ConfigParser
  • checkPin() : PiaVia
  • checkRackAllowed() : ConfigParser
  • checkRackDeclaration() : ConfigParser
  • checkRead() : RB8905_Adc12
  • checkValidAddress() : RulbusDevice
  • checkWavelength() : RB9603_monochromator
  • clear() : TheRulbusDeviceList
  • clearAddress() : RB8905_Adc12
  • clearEppTimeout() : EppRulbusInterface
  • clearFlipFlops() : RB8506_Sifu
  • clearInterrupt() : RB8515_clock, RB8514_delay
  • clearRackCardList() : ConfigParser
  • clockFrequency() : RB8515_clock, RB8514_delay
  • clockRateMultiplier() : RB8513_timebase
  • clockRateSelector() : RB8513_timebase
  • close() : TheRulbusDeviceList
  • code() : ConfigToken, RB8515_clock::FreqTable
  • ConfigListBuilder() : ConfigListBuilder
  • ConfigParser() : ConfigParser
  • ConfigPrinter() : ConfigPrinter
  • ConfigScanner() : ConfigScanner
  • convert() : RB8509_Adc12
  • countByte0() : RB8514_delay
  • countByte1() : RB8514_delay
  • countByte2() : RB8514_delay
  • createDevices() : RulbusDeviceFactory
  • createInterface() : RulbusInterfaceFactory
  • currentWavelength() : RB9603_monochromator

- d -

  • DbcException() : DbcException
  • dec() : IoFormat
  • delayCount() : RB8514_delay
  • delayTime() : RB8514_delay
  • description() : DbcException
  • destroyDevices() : RulbusDeviceFactory
  • detectJmp3BufferSize() : RB8905_Adc12
  • disableInterrupt() : RB8515_clock

- e -

  • elemSize() : RB8905_Adc12
  • enableChannelSequenceMode() : RB9005_amplifier
  • enableClockSequenceMode() : RB9005_amplifier
  • enableEnd1() : RB8514_delay
  • enableEnd2() : RB8514_delay
  • enableExtTrigger() : RB8509_Adc12
  • enableInterrupt() : RB8905_Adc12, RB8515_clock, RB8514_delay, RB8509_Adc12
  • enableMultiplexer() : RB8509_Adc12
  • enablePulseOutputs() : RB8506_Sifu
  • enableSignal() : RB8514_delay
  • enableStart1() : RB8514_delay
  • enableStart2() : RB8514_delay
  • end() : PportAddresses
  • end12Direction() : RB8514_delay
  • EnsureException() : EnsureException
  • EppRulbusInterface() : EppRulbusInterface
  • EppTimedOut() : EppRulbusInterface
  • eqAddr() : RulbusDevice
  • eqRack() : RulbusDevice
  • expect() : ConfigParser
  • extTriggerLevel() : RB8509_Adc12

- f -

  • file() : Assertion
  • filename() : ConfigScanner
  • fill() : IoFormat
  • fixed() : IoFormat
  • flags() : IoFormat

- g -

  • gain() : RB9005_amplifier, RB8509_Adc12
  • gain12() : RB9005_amplifier
  • gain34() : RB9005_amplifier
  • general() : IoFormat
  • get() : RulbusDeviceProxy, TheRulbusDeviceList, ConfigScanner, ConfigErrorToken, ConfigEofToken, ConfigSpecialToken, ConfigStringToken, ConfigNumberToken, ConfigWordToken, ConfigToken
  • getByte() : TheRulbusInterface, RulbusDevice
  • getCharacter() : RB9603_monochromator
  • getClkFreqCode() : RB8515_clock
  • getDataPA() : PiaVia
  • getDataPB() : PiaVia
  • getDDRA() : Via, Pia, PiaVia
  • getDDRB() : Via, Pia, PiaVia
  • getDirC2() : Via, Pia
  • getDirCA2() : Via, Pia, PiaVia
  • getDirCB2() : Via, Pia, PiaVia
  • getDirection() : RB8514_delay
  • getDirPA() : PiaVia
  • getDirPB() : PiaVia
  • getEdgeC1() : Via, Pia
  • getEdgeCA1() : Via, Pia, PiaVia
  • getEdgeCB1() : Via, Pia, PiaVia
  • getEnable() : RB8514_delay
  • getFreqCode() : RB8515_clock
  • getInputLineLevel() : RB8506_Sifu
  • getInputPortData() : RB8506_Sifu
  • getIntFreqCode() : RB8515_clock
  • getIntrC1() : Via, Pia
  • getIntrCA1() : Via, Pia, PiaVia
  • getIntrCB1() : Via, Pia, PiaVia
  • getIrqC1() : Via, Pia
  • getIrqCA1() : Via, Pia, PiaVia
  • getIrqCB1() : Via, Pia, PiaVia
  • getLastError() : RulbusError
  • getLevelC2() : Via, Pia
  • getLevelCA2() : Via, Pia, PiaVia
  • getLevelCB2() : Via, Pia, PiaVia
  • getLineDir() : PiaVia
  • getLineDirPA() : PiaVia
  • getLineDirPB() : PiaVia
  • getLineLevel() : PiaVia
  • getLineLevelPA() : PiaVia
  • getLineLevelPB() : PiaVia
  • getOutputLineLevel() : RB8506_Sifu
  • getOutputPortData() : RB8506_Sifu
  • getPDRA() : Via, Pia, PiaVia
  • getPDRB() : Via, Pia, PiaVia
  • getPortData() : PiaVia
  • getPortDir() : PiaVia
  • getRawValue() : RB8905_Adc12
  • getReg() : TheRulbusInterface, IsaRulbusInterface, EppRulbusInterface
  • getString() : RB9603_monochromator
  • getToken() : ConfigParser
  • getValue() : RB8905_Adc12

- h -

  • hasExtTriggerInput() : RB8509_Adc12
  • hex() : IoFormat

- i -

  • initializeEpp() : EppRulbusInterface
  • instance() : Singleton, TheRulbusInterface
  • interfacePresent() : EppRulbusInterface
  • internal() : IoFormat
  • interruptFrequency() : RB8515_clock
  • intervalTime() : RB8513_timebase
  • intrinsicDelayTime() : RB8514_delay
  • invariant() : TheRulbusInterface, IsaRulbusInterface, EppRulbusInterface
  • IoFormat() : IoFormat
  • IsaRulbusInterface() : IsaRulbusInterface
  • isAsnop() : ConfigToken
  • isBipolar() : RB8510_Dac12, RB8509_Adc12
  • isBool() : ConfigToken
  • isBusy() : RB8514_delay
  • isBusyAdc() : RB8509_Adc12
  • isCard() : ConfigToken
  • isChangedInputLine() : RB8506_Sifu
  • isChannelSequenceMode() : RB9005_amplifier
  • isClockSequenceMode() : RB9005_amplifier
  • isDelim() : ConfigToken
  • isEnabledEnd1() : RB8514_delay
  • isEnabledEnd2() : RB8514_delay
  • isEnabledExtTrigger() : RB8509_Adc12
  • isEnabledInterrupt() : RB8905_Adc12, RB8515_clock, RB8514_delay, RB8509_Adc12
  • isEnabledMultiplexer() : RB8509_Adc12
  • isEnabledPulseOutputs() : RB8506_Sifu
  • isEnabledSignal() : RB8514_delay
  • isEnabledStart1() : RB8514_delay
  • isEnabledStart2() : RB8514_delay
  • isEqual() : isEqual
  • isFastMode() : RB8905_Adc12
  • isKind() : ConfigToken
  • isPendingInterrupt() : RB8515_clock, RB8514_delay, RB8509_Adc12
  • isReady() : RB9603_monochromator, RB8905_Adc12, RB8509_Adc12
  • isUnipolarMode() : RB8905_Adc12
  • isUnit() : ConfigToken
  • isValid() : PportAddresses
  • isValidChannel() : RB8509_Adc12
  • isValidClockFrequency() : RB8514_delay
  • isValidDelayCount() : RB8514_delay
  • isValidGain() : RB8509_Adc12
  • isValidIntrinsicTime() : RB8514_delay
  • isValidSignalDirection() : RB8514_delay
  • isValidSignalName() : RB8514_delay

- j -

  • jmp3BufferCapacity() : RB8905_Adc12
  • jmp3BufferSize() : RB8905_Adc12

- l -

  • lasttid() : RulbusError
  • left() : IoFormat
  • line() : Assertion
  • linenumber() : ConfigScanner
  • lowPassFrequency() : RB9005_amplifier
  • lpf12() : RB9005_amplifier
  • lpf34() : RB9005_amplifier

- m -

  • maxInputVoltage() : RB8905_Adc12
  • maxWavelength() : RB9603_monochromator
  • minInputVoltage() : RB8905_Adc12
  • minWavelength() : RB9603_monochromator

- n -

  • name() : RulbusDevice
  • NeverGetHereException() : NeverGetHereException

- o -

  • oct() : IoFormat
  • offsetVoltage() : RB8905_Adc12
  • open() : TheRulbusDeviceList
  • operator *() : RulbusDeviceProxy
  • operator RulbusDevicePtr() : RulbusDeviceProxy
  • operator RulbusDeviceRef() : RulbusDeviceProxy
  • operator()() : IoFormat, isEqual
  • operator->() : RulbusDeviceProxy
  • operator=() : RulbusDeviceProxy, TheRulbusDeviceList, RulbusDevice, RB9603_monochromator, RB9005_amplifier, RB8905_Adc12, RB8515_clock, RB8514_delay, RB8513_timebase, RB8510_Dac12, RB8509_Adc12, RB8506_Sifu, IsaRulbusInterface, EppRulbusInterface, DbcException, Assertion
  • operator==() : DbcException, Assertion

- p -

  • parse() : ConfigParser
  • parseAddress() : ConfigParser
  • parseBipolar() : ConfigParser
  • parseBooleanProperty() : ConfigParser
  • parseCardDeclaration() : ConfigParser
  • parseCardDeclarationSequence() : ConfigParser
  • parseCardInitializer() : ConfigParser
  • ParseError() : ConfigParser::ParseError
  • parseFileAssignment() : ConfigParser
  • parseGenericCard() : ConfigParser
  • parseHasExtTrigger() : ConfigParser
  • parseIntegerProperty() : ConfigParser
  • parseIntrDelay() : ConfigParser
  • parseNumChannels() : ConfigParser
  • parseOptAssignOp() : ConfigParser
  • parseOptDelimiter() : ConfigParser
  • parseOptUnit() : ConfigParser
  • parseProgram() : ConfigParser
  • parseRackAddressAssignment() : ConfigParser
  • parseRackDeclaration() : ConfigParser
  • parseRackDeclarationSequence() : ConfigParser
  • parseRackInitializer() : ConfigParser
  • parseRB8509() : ConfigParser
  • parseRB8510() : ConfigParser
  • parseRB8514() : ConfigParser
  • parseRB8905() : ConfigParser
  • parseRealProperty() : ConfigParser
  • parseVoltPerBit() : ConfigParser
  • Pia() : Pia
  • precision() : IoFormat
  • print() : ConfigErrorToken, ConfigEofToken, ConfigSpecialToken, ConfigStringToken, ConfigNumberToken, ConfigWordToken, ConfigToken
  • printOn() : TheRulbusInterface, TheRulbusDeviceList, RulbusDevice, IsaRulbusInterface, EppRulbusInterface
  • putByte() : TheRulbusInterface, RulbusDevice
  • putCharacter() : RB9603_monochromator
  • putReg() : TheRulbusInterface, IsaRulbusInterface, EppRulbusInterface
  • putString() : RB9603_monochromator

- r -

  • rack() : RulbusDevice
  • rawresult() : RB8509_Adc12
  • RB8506_Pia() : RB8506_Pia
  • RB8506_Sifu() : RB8506_Sifu
  • RB8506_Via() : RB8506_Via
  • RB8509_Adc12() : RB8509_Adc12
  • RB8510_Dac12() : RB8510_Dac12
  • RB8513_timebase() : RB8513_timebase
  • RB8514_delay() : RB8514_delay
  • RB8515_clock() : RB8515_clock
  • RB8905_Adc12() : RB8905_Adc12
  • RB9005_amplifier() : RB9005_amplifier
  • RB9603_monochromator() : RB9603_monochromator
  • read() : RB9603_monochromator
  • readAddress() : EppRulbusInterface
  • readData() : EppRulbusInterface
  • readValue() : RB8905_Adc12
  • readVoltage() : RB8905_Adc12
  • reason() : Assertion
  • remove() : TheRulbusDeviceList
  • RequireException() : RequireException
  • resetInterface() : EppRulbusInterface
  • result() : RB8509_Adc12
  • right() : IoFormat
  • RulbusAddressError() : RulbusAddressError
  • RulbusCloseError() : RulbusCloseError
  • RulbusConfigError() : RulbusConfigError
  • RulbusContextError() : RulbusContextError
  • RulbusDataError() : RulbusDataError
  • RulbusDevice() : RulbusDevice
  • RulbusDeviceFactory() : RulbusDeviceFactory
  • RulbusDeviceProxy() : RulbusDeviceProxy
  • RulbusError() : RulbusError
  • RulbusHandleError() : RulbusHandleError
  • RulbusInterfaceError() : RulbusInterfaceError
  • RulbusInterfaceFactory() : RulbusInterfaceFactory
  • RulbusOpenError() : RulbusOpenError
  • RulbusParseError() : RulbusParseError
  • RulbusRangeError() : RulbusRangeError
  • RulbusScanError() : RulbusScanError
  • RulbusTimeoutError() : RulbusTimeoutError

- s -

  • scientific() : IoFormat
  • seechar() : ConfigScanner
  • select_ddra() : Pia
  • select_ddrb() : Pia
  • select_pdra() : Pia
  • select_pdrb() : Pia
  • setAddr() : RulbusDevice
  • setBipolarMode() : RB8905_Adc12
  • setBufferCapacity() : RB8905_Adc12
  • setBufferCode() : RB8905_Adc12
  • setBufferSize() : RB8905_Adc12
  • setChannel() : RB9005_amplifier, RB8509_Adc12
  • setClockFrequency() : RB8515_clock, RB8514_delay
  • setClockRateMultiplier() : RB8513_timebase
  • setClockRateSelector() : RB8513_timebase
  • setDataPA() : PiaVia
  • setDataPB() : PiaVia
  • setDDRA() : Via, Pia, PiaVia
  • setDDRB() : Via, Pia, PiaVia
  • setDelayCount() : RB8514_delay
  • setDelayTime() : RB8514_delay
  • setDirC2() : Via, Pia
  • setDirCA2() : Via, Pia, PiaVia
  • setDirCB2() : Via, Pia, PiaVia
  • setDirection() : RB8514_delay
  • setDirPA() : PiaVia
  • setDirPB() : PiaVia
  • setEdgeC1() : Via, Pia
  • setEdgeCA1() : Via, Pia, PiaVia
  • setEdgeCB1() : Via, Pia, PiaVia
  • setEnable() : RB8514_delay
  • setEnd12Direction() : RB8514_delay
  • setf() : IoFormat
  • setFastMode() : RB8905_Adc12
  • setGain() : RB9005_amplifier, RB8509_Adc12
  • setGain12() : RB9005_amplifier
  • setGain34() : RB9005_amplifier
  • setInterruptFrequency() : RB8515_clock
  • setIntervalTime() : RB8513_timebase
  • setIntrC1() : Via, Pia
  • setIntrCA1() : Via, Pia, PiaVia
  • setIntrCB1() : Via, Pia, PiaVia
  • setIntrinsicDelayTime() : RB8514_delay
  • setLevelC2() : Via, Pia
  • setLevelCA2() : Via, Pia, PiaVia
  • setLevelCB2() : Via, Pia, PiaVia
  • setLineDir() : PiaVia
  • setLineDirPA() : PiaVia
  • setLineDirPB() : PiaVia
  • setLineLevel() : PiaVia
  • setLineLevelPA() : PiaVia
  • setLineLevelPB() : PiaVia
  • setLowPassFrequency() : RB9005_amplifier
  • setLpf12() : RB9005_amplifier
  • setLpf34() : RB9005_amplifier
  • setNormalMode() : RB8905_Adc12
  • setOutputLineLevel() : RB8506_Sifu
  • setOutputPortData() : RB8506_Sifu
  • setPDRA() : Via, Pia, PiaVia
  • setPDRB() : Via, Pia, PiaVia
  • setPortData() : PiaVia
  • setPortDir() : PiaVia
  • setRack() : RulbusDevice
  • setReadMode() : RB8905_Adc12
  • setSignalDirection() : RB8514_delay
  • setStart12Direction() : RB8514_delay
  • setTriggerEdge() : RB8514_delay
  • setUnipolarMode() : RB8905_Adc12
  • setValue() : RB8510_Dac12
  • setVoltage() : RB8510_Dac12
  • setWavelength() : RB9603_monochromator
  • setWriteMode() : RB8905_Adc12
  • showbase() : IoFormat
  • showplus() : IoFormat
  • showpoint() : IoFormat
  • signalDirection() : RB8514_delay
  • skipWhitespace() : ConfigScanner
  • start12Direction() : RB8514_delay
  • stop() : RB8513_timebase
  • swapLines() : RB8506_Sifu
  • swapNibbles() : RB8506_Sifu

- t -

  • targetWavelength() : RB9603_monochromator
  • test() : ConfigParser
  • theRulbus() : RulbusDevice
  • TheRulbusDeviceList() : TheRulbusDeviceList
  • TheRulbusInterface() : TheRulbusInterface
  • toBool() : ConfigToken
  • toInt() : ConfigToken
  • tokenString() : ConfigToken
  • toReal() : ConfigToken
  • toString() : ConfigToken
  • transfer() : RulbusDeviceProxy
  • trigger() : RB8514_delay
  • triggerEdge() : RB8514_delay
  • tstInputLineLevel() : RB8506_Sifu
  • type() : DbcException

- u -

  • unsetf() : IoFormat
  • updateRackCardList() : ConfigParser
  • uppercase() : IoFormat

- v -

  • validBase() : IsaRulbusInterface
  • value() : RB8510_Dac12, RB8509_Adc12
  • Via() : Via
  • voltage() : RB8510_Dac12, RB8509_Adc12
  • voltageSpan() : RB8905_Adc12
  • voltperbit() : RB8905_Adc12, RB8510_Dac12, RB8509_Adc12

- w -

  • wait() : RB9603_monochromator
  • waitRelais() : RB8905_Adc12
  • what() : RulbusError, DbcException, Assertion
  • width() : RulbusDevice, IoFormat
  • write() : RB9603_monochromator
  • writeAddress() : EppRulbusInterface
  • writeData() : EppRulbusInterface

- ~ -

  • ~Assertion() : Assertion
  • ~ConfigScanner() : ConfigScanner
  • ~DbcException() : DbcException
  • ~Pia() : Pia
  • ~PiaVia() : PiaVia
  • ~RB8506_Sifu() : RB8506_Sifu
  • ~RB8509_Adc12() : RB8509_Adc12
  • ~RB8510_Dac12() : RB8510_Dac12
  • ~RB8513_timebase() : RB8513_timebase
  • ~RB8514_delay() : RB8514_delay
  • ~RB8515_clock() : RB8515_clock
  • ~RB8905_Adc12() : RB8905_Adc12
  • ~RB9005_amplifier() : RB9005_amplifier
  • ~RB9603_monochromator() : RB9603_monochromator
  • ~RulbusDevice() : RulbusDevice
  • ~RulbusDeviceProxy() : RulbusDeviceProxy
  • ~RulbusError() : RulbusError
  • ~TheRulbusDeviceList() : TheRulbusDeviceList
  • ~TheRulbusInterface() : TheRulbusInterface
  • ~Via() : Via
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Compound Member Index

  • AddrList : ConfigParser
  • CardList : ConfigParser
  • const_iterator : PportAddresses
  • Count : RB8514_delay
  • fmtflags : IoFormat
  • LineList : ConfigParser
  • NameList : ConfigParser
  • Value : RB9603_monochromator, RB9005_amplifier, RB8905_Adc12, RB8513_timebase, RB8510_Dac12, RB8509_Adc12
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Compound Member Index

- a -

  • ADR_WIDTH : RB9603_monochromator, RB9005_amplifier, RB8905_Adc12, RB8515_clock, RB8514_delay, RB8513_timebase, RB8510_Dac12, RB8509_Adc12, Via, Pia
  • already_assigned : ConfigParser
  • ANY_RACK : TheRulbusInterface, RulbusDevice

- b -

  • baseMax : IsaRulbusInterface
  • baseMin : IsaRulbusInterface
  • basePCIMax : PportAddresses
  • basePCIMin : PportAddresses
  • basePCIStp : PportAddresses
  • baseStp : IsaRulbusInterface

- c -

  • c : ConfigKeyword
  • clkTable : RB8515_clock
  • code : ConfigToken, RB8515_clock::FreqTable
  • CON_JMP3 : RB8905_Adc12
  • CON_MPS : RB9603_monochromator
  • CON_TRELAIS : RB8905_Adc12

- d -

  • DEF_ADDR : RB9603_monochromator, RB9005_amplifier, RB8905_Adc12, RB8515_clock, RB8514_delay, RB8513_timebase, RB8510_Dac12, RB8509_Adc12, RB8506_Sifu, Via, Pia
  • DEF_BIP : RB8510_Dac12, RB8509_Adc12
  • DEF_CHAN : RB8509_Adc12
  • DEF_CLKFRQ : RB8515_clock
  • DEF_CNT : RB8514_delay
  • DEF_DIRCA2 : RB8506_Sifu
  • DEF_DIRCB2 : RB8506_Sifu
  • DEF_DIRPA : RB8506_Sifu
  • DEF_DIRPB : RB8506_Sifu
  • DEF_DLY : RB8514_delay
  • DEF_EDGECB1 : RB8506_Sifu
  • DEF_EE1 : RB8514_delay
  • DEF_EE2 : RB8514_delay
  • DEF_EINT : RB8514_delay
  • DEF_EPP_BASE : EppRulbusInterface
  • DEF_ES1 : RB8514_delay
  • DEF_ES2 : RB8514_delay
  • DEF_ETI : RB8509_Adc12
  • DEF_ETRG : RB8514_delay
  • DEF_FRQ : RB8514_delay
  • DEF_GAIN : RB8509_Adc12
  • DEF_IDT : RB8514_delay
  • DEF_INTFRQ : RB8515_clock
  • DEF_INTRCB1 : RB8506_Sifu
  • DEF_ISA_BASE : IsaRulbusInterface
  • DEF_LE12 : RB8514_delay
  • DEF_LS12 : RB8514_delay
  • DEF_LVLCA2 : RB8506_Sifu
  • DEF_LVLCB2 : RB8506_Sifu
  • DEF_MUL : RB8513_timebase
  • DEF_OUTDATA : RB8506_Sifu
  • DEF_RACK : RulbusDevice, Via, Pia
  • DEF_SAMPLES : RB8905_Adc12
  • DEF_SEL : RB8513_timebase
  • DEF_VPB : RB8905_Adc12, RB8510_Dac12, RB8509_Adc12

- e -

  • eofToken : ConfigScanner
  • errorToken : ConfigScanner

- f -

  • freq : RB8515_clock::FreqTable
  • freq12Table : RB9005_amplifier

- g -

  • gain12Table : RB9005_amplifier
  • gain34Table : RB9005_amplifier
  • GainInfoTable : RB9005_amplifier

- i -

  • intTable : RB8515_clock
  • is : ConfigScanner

- k -

  • kindTable : ConfigToken
  • kPportAddresses : PportAddresses

- l -

  • LIM_BIPVAL : RB8510_Dac12, RB8509_Adc12
  • LIM_CNTMAX : RB8514_delay
  • LIM_CNTMIN : RB8514_delay
  • LIM_FRQMAX : RB8514_delay
  • LIM_FRQMIN : RB8514_delay
  • LIM_IDTMAX : RB8514_delay
  • LIM_IDTMIN : RB8514_delay
  • LIM_MAXBUFSIZE : RB8905_Adc12
  • LIM_MAXCHAN : RB8509_Adc12
  • LIM_MAXCHN : RB9005_amplifier
  • LIM_MAXGAIN : RB8509_Adc12
  • LIM_MAXJMP3SIZE : RB8905_Adc12
  • LIM_MAXVAL : RB8510_Dac12, RB8509_Adc12
  • LIM_MAXVAL12 : RB8905_Adc12
  • LIM_MAXVAL8 : RB8905_Adc12
  • LIM_MAXVPB : RB8509_Adc12
  • LIM_MINBUFSIZE : RB8905_Adc12
  • LIM_MINCHAN : RB8509_Adc12
  • LIM_MINCHN : RB9005_amplifier
  • LIM_MINGAIN : RB8509_Adc12
  • LIM_MINJMP3SIZE : RB8905_Adc12
  • LIM_MINVAL : RB8510_Dac12, RB8509_Adc12
  • LIM_MINVAL12 : RB8905_Adc12
  • LIM_MINVAL8 : RB8905_Adc12
  • LIM_MINVPB : RB8509_Adc12
  • LIM_MULMAX : RB8513_timebase
  • LIM_MULMIN : RB8513_timebase
  • LIM_RACKS : ConfigParser
  • LIM_SELMAX : RB8513_timebase
  • LIM_SELMAXFIXED : RB8513_timebase
  • LIM_SELMIN : RB8513_timebase
  • LIM_TIMOUT : RB8509_Adc12

- m -

  • m_a : isEqual
  • msg : RulbusError
  • msgtitle : IsaRulbusInterface, EppRulbusInterface
  • MSK_ADCALL12 : RB8905_Adc12
  • MSK_ADCALL8 : RB8905_Adc12
  • MSK_ADCMSB12 : RB8905_Adc12
  • MSK_ADCMSB8 : RB8905_Adc12
  • MSK_ATC1 : Via, Pia
  • MSK_ATC2 : Pia
  • MSK_BYTE : RB8514_delay
  • MSK_CHN1 : RB9005_amplifier
  • MSK_CHN2 : RB9005_amplifier
  • MSK_CHNSEQ : RB9005_amplifier
  • MSK_CLKFRQ : RB8515_clock
  • MSK_CLKSEQ : RB9005_amplifier
  • MSK_CTLBSIZE : RB8905_Adc12
  • MSK_CTLCHAN : RB8509_Adc12
  • MSK_CTLCLEAR : RB8905_Adc12
  • MSK_CTLEE1 : RB8514_delay
  • MSK_CTLEE2 : RB8514_delay
  • MSK_CTLES1 : RB8514_delay
  • MSK_CTLES2 : RB8514_delay
  • MSK_CTLFAST : RB8905_Adc12
  • MSK_CTLGAIN : RB8509_Adc12
  • MSK_CTLINT : RB8514_delay
  • MSK_CTLINTR : RB8905_Adc12, RB8509_Adc12
  • MSK_CTLLE12 : RB8514_delay
  • MSK_CTLLS12 : RB8514_delay
  • MSK_CTLMPLX : RB8509_Adc12
  • MSK_CTLREAD : RB8905_Adc12
  • MSK_CTLTRG : RB8514_delay
  • MSK_CTLTRIG : RB8509_Adc12
  • MSK_CTLUNIP : RB8905_Adc12
  • MSK_DIRC2 : Via, Pia
  • MSK_EIC1 : Pia
  • MSK_EIC2 : Pia
  • MSK_EPP_Timeout : EppRulbusInterface
  • MSK_GAIN1 : RB9005_amplifier
  • MSK_GAIN2 : RB9005_amplifier
  • MSK_GAIN3 : RB9005_amplifier
  • MSK_GAIN4 : RB9005_amplifier
  • MSK_IECA1 : Via
  • MSK_IECA2 : Via
  • MSK_IECB1 : Via
  • MSK_IECB2 : Via
  • MSK_IECT1 : Via
  • MSK_IECT2 : Via
  • MSK_IESC : Via
  • MSK_IESR : Via
  • MSK_IFCA1 : Via
  • MSK_IFCA2 : Via
  • MSK_IFCB1 : Via
  • MSK_IFCB2 : Via
  • MSK_IFCT1 : Via
  • MSK_IFCT2 : Via
  • MSK_IFIRQ : Via
  • MSK_IFSR : Via
  • MSK_INTCLRn : RB8515_clock
  • MSK_INTENA : RB8515_clock
  • MSK_INTFRQ : RB8515_clock
  • MSK_INTSTS : RB8515_clock
  • MSK_IRQ1 : Pia
  • MSK_IRQ2 : Pia
  • MSK_LPF12 : RB9005_amplifier
  • MSK_OLC2 : Via, Pia
  • MSK_POC2 : Via, Pia
  • MSK_SELSTP : RB8513_timebase
  • MSK_SPDR : Pia
  • MSK_SPP_AutoLF : EppRulbusInterface
  • MSK_SPP_EnaBiDirect : EppRulbusInterface
  • MSK_SPP_EnaIRQVAL : EppRulbusInterface
  • MSK_SPP_nAck : EppRulbusInterface
  • MSK_SPP_nBusy : EppRulbusInterface
  • MSK_SPP_nError : EppRulbusInterface
  • MSK_SPP_nIRQ : EppRulbusInterface
  • MSK_SPP_nReset : EppRulbusInterface
  • MSK_SPP_PaperOut : EppRulbusInterface
  • MSK_SPP_Reserved2 : EppRulbusInterface
  • MSK_SPP_SelectIn : EppRulbusInterface
  • MSK_SPP_SelectPrinter : EppRulbusInterface
  • MSK_SPP_Strobe : EppRulbusInterface
  • MSK_SPP_Unused1 : EppRulbusInterface
  • MSK_SPP_Unused2 : EppRulbusInterface
  • MSK_STSBSY : RB8514_delay, RB8509_Adc12
  • MSK_STSEOC : RB8509_Adc12
  • MSK_STSINT : RB8514_delay
  • MSK_STSINTR : RB8509_Adc12
  • MSK_STSREADY : RB8905_Adc12
  • MSK_STSTRIG : RB8509_Adc12
  • MSK_VALMSN : RB8509_Adc12

- n -

  • numberToken : ConfigScanner

- o -

  • OFF_ACR : Via
  • OFF_ADC : RB8905_Adc12
  • OFF_ADCLSB : RB8509_Adc12
  • OFF_BT0 : RB8514_delay
  • OFF_BT1 : RB8514_delay
  • OFF_BT2 : RB8514_delay
  • OFF_CMD : RB9603_monochromator
  • OFF_CONTROL : RB8509_Adc12
  • OFF_CONVERT : RB8509_Adc12
  • OFF_CR : RB8515_clock
  • OFF_CRA : Pia
  • OFF_CRB : Pia
  • OFF_CTL : RB8905_Adc12, RB8514_delay
  • OFF_DDRA : Via, Pia
  • OFF_DDRB : Via, Pia
  • OFF_EPP_ADDR : EppRulbusInterface
  • OFF_EPP_DATA : EppRulbusInterface
  • OFF_FREQ1 : RB9005_amplifier
  • OFF_FREQ2 : RB9005_amplifier
  • OFF_GAIN12 : RB9005_amplifier
  • OFF_GAIN34 : RB9005_amplifier
  • OFF_IER : Via
  • OFF_IFR : Via
  • OFF_LSB : RB8510_Dac12
  • OFF_MSB : RB8510_Dac12
  • OFF_MUL : RB8513_timebase
  • OFF_MUX : RB9005_amplifier
  • OFF_PCR : Via
  • OFF_PDRA : Via, Pia
  • OFF_PDRA_NH : Via
  • OFF_PDRB : Via, Pia
  • OFF_SEL : RB8513_timebase
  • OFF_SPP_CTRL : EppRulbusInterface
  • OFF_SPP_DATA : EppRulbusInterface
  • OFF_SPP_STAT : EppRulbusInterface
  • OFF_SR : RB8515_clock, Via
  • OFF_STATUS : RB8509_Adc12
  • OFF_STS : RB9603_monochromator, RB8905_Adc12, RB8514_delay
  • OFF_T1CH : Via
  • OFF_T1CL : Via
  • OFF_T1LH : Via
  • OFF_T1LL : Via
  • OFF_T2CH : Via
  • OFF_T2CL : Via

- s -

  • s : TheRulbusInterface, RulbusDeviceProxy, TheRulbusDeviceList, ConfigKeyword
  • selectorList : RB8513_timebase
  • SHL_CA : Via
  • SHL_CB : Via
  • SHL_CHN1 : RB9005_amplifier
  • SHL_CHN2 : RB9005_amplifier
  • SHL_CLKFRQ : RB8515_clock
  • SHL_CTLCHAN : RB8509_Adc12
  • SHL_CTLGAIN : RB8509_Adc12
  • SHL_GAIN1 : RB9005_amplifier
  • SHL_GAIN2 : RB9005_amplifier
  • SHL_GAIN3 : RB9005_amplifier
  • SHL_GAIN4 : RB9005_amplifier
  • SHL_INTFRQ : RB8515_clock
  • SHL_LPF12 : RB9005_amplifier
  • SHR_BT0 : RB8514_delay
  • SHR_BT1 : RB8514_delay
  • SHR_BT2 : RB8514_delay
  • specialToken : ConfigScanner
  • stringTable : ConfigToken
  • stringToken : ConfigScanner

- t -

  • t : ConfigParser
  • theAddr : RulbusDevice
  • theBase : IsaRulbusInterface, EppRulbusInterface
  • theBipolarFlag : RB8510_Dac12, RB8509_Adc12
  • theBufferCapacity : RB8905_Adc12
  • theBuilder : ConfigParser
  • theCardAddress : ConfigParser
  • theCardLineList : ConfigParser
  • theCardList : ConfigParser
  • theCardName : ConfigParser
  • theCardNameList : ConfigParser
  • theClockFrequency : RB8514_delay
  • theContext : ConfigParser
  • theControlRegister : RB8905_Adc12, RB8514_delay, RB8509_Adc12
  • theCtlByte : RB8515_clock
  • theDelayRegister : RB8514_delay
  • theDescription : DbcException
  • theError : RulbusError
  • theExtTrigInpFlag : RB8509_Adc12
  • theFile : Assertion
  • theFilename : ConfigScanner
  • theFillChar : IoFormat
  • theFlags : IoFormat
  • theFormat : BoundIoFormat
  • theFreq1Register : RB9005_amplifier
  • theFreq2Register : RB9005_amplifier
  • theGain12Register : RB9005_amplifier
  • theGain34Register : RB9005_amplifier
  • theInstance : Singleton
  • theIntrinsicDelayTime : RB8514_delay
  • theIntValue : ConfigToken
  • theJmp3BufferSize : RB8905_Adc12
  • theLine : Assertion
  • theLinenumber : ConfigScanner
  • theList : TheRulbusDeviceList
  • theMaxWL : RB9603_monochromator
  • theMessage : DbcException
  • theMinWL : RB9603_monochromator
  • theMutiplyReg : RB8513_timebase
  • theMuxRegister : RB9005_amplifier
  • theName : RulbusDevice
  • thePrecision : IoFormat
  • thePtr : RulbusDeviceProxy
  • theRack : RulbusDevice
  • theRackAddress : ConfigParser
  • theRackAddrSet : ConfigParser
  • theRackCardList : ConfigParser
  • theRackLine : ConfigParser
  • theRackLineSet : ConfigParser
  • theRackName : ConfigParser
  • theRackNameSet : ConfigParser
  • theRealValue : ConfigToken
  • theReason : Assertion
  • theRegister : RB8510_Dac12
  • theScanner : ConfigParser
  • theSelectorReg : RB8513_timebase
  • theStream : ConfigPrinter
  • theString : ConfigToken
  • theToken : ConfigParser
  • theTokenCode : ConfigToken
  • theType : DbcException
  • theValue : BoundIoFormat
  • theVoltPerBit : RB8905_Adc12, RB8510_Dac12, RB8509_Adc12
  • theWidth : RulbusDevice, IoFormat
  • tid : RulbusError
  • timeList : RB8513_timebase

- w -

  • wordToken : ConfigScanner
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: IoFormat.h Source File

IoFormat.h

00001 /*
00002  * IoFormat.h - io formatting class.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: IoFormat.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __IOFORMAT_H
00026 #define __IOFORMAT_H
00027
00028 #ifndef __COMMON_H
00029 #include "Common.h"
00030 #endif
00031
00032 //#include <iosfwd>
00033 #include <sstream>
00034
00039 namespace Rulbus
00040 {
00041    template <typename T> class BoundIoFormat;
00042
00076    template <typename T>
00077    class IoFormat
00078    {
00079    public:
00084       typedef std::ios_base::fmtflags fmtflags;
00085
00088
00093       explicit IoFormat( int precision = 6 ):
00094          thePrecision(precision), theFlags(0), theWidth(0), theFillChar(' ')
00095       {
00096          ; // do nothing
00097       }
00098
00102
00107       BoundIoFormat<T> operator()( const T& d ) const;
00108
00112
00117       int fill() const
00118       {
00119          return theFillChar;
00120       }
00121
00126       int flags() const
00127       {
00128          return theFlags;
00129       }
00130
00135       int width() const
00136       {
00137          return theWidth;
00138       }
00139
00144       int precision() const
00145       {
00146          return thePrecision;
00147       }
00148
00152
00157       IoFormat<T>& left()
00158       {
00159          setf( std::ios_base::left, std::ios_base::adjustfield );
00160          return *this;
00161       }
00162
00167       IoFormat<T>& right()
00168       {
00169          setf( std::ios_base::right, std::ios_base::adjustfield );
00170          return *this;
00171       }
00172
00177       IoFormat<T>& internal()
00178       {
00179          setf( std::ios_base::internal, std::ios_base::adjustfield );
00180          return *this;
00181       }
00182
00187       IoFormat<T>& boolalpha( bool alpha = true )
00188       {
00189          if ( alpha )   setf( std::ios_base::boolalpha );
00190          else         unsetf( std::ios_base::boolalpha );
00191          return *this;
00192       }
00193
00198       IoFormat<T>& uppercase( bool upper = true )
00199       {
00200          if ( upper )   setf( std::ios_base::uppercase );
00201          else         unsetf( std::ios_base::uppercase );
00202          return *this;
00203       }
00204
00209       IoFormat<T>& general()
00210       {
00211          setf( 0, std::ios_base::floatfield );
00212          return *this;
00213       }
00214
00219       IoFormat<T>& fixed()
00220       {
00221          setf( std::ios_base::fixed, std::ios_base::floatfield );
00222          return *this;
00223       }
00224
00229       IoFormat<T>& scientific()
00230       {
00231          setf( std::ios_base::scientific, std::ios_base::floatfield );
00232          return *this;
00233       }
00234
00239       IoFormat<T>& oct()
00240       {
00241          setf( std::ios_base::oct, std::ios_base::basefield );
00242          return *this;
00243       }
00244
00249       IoFormat<T>& dec()
00250       {
00251          setf( std::ios_base::dec, std::ios_base::basefield );
00252          return *this;
00253       }
00254
00259       IoFormat<T>& hex()
00260       {
00261          setf( std::ios_base::hex, std::ios_base::basefield );
00262          return *this;
00263       }
00264
00269       IoFormat<T>& showplus( bool show = true )
00270       {
00271          if ( show )   setf( std::ios_base::showpos );
00272          else        unsetf( std::ios_base::showpos );
00273          return *this;
00274       }
00275
00280       IoFormat<T>& showbase( bool show = true )
00281       {
00282          if ( show )   setf( std::ios_base::showbase );
00283          else        unsetf( std::ios_base::showbase );
00284          return *this;
00285       }
00286
00291       IoFormat<T>& showpoint( bool show = true )
00292       {
00293          if ( show )   setf( std::ios_base::showpoint );
00294          else        unsetf( std::ios_base::showpoint );
00295          return *this;
00296       }
00297
00302       IoFormat<T>& fill( int c = ' ' )
00303       {
00304          theFillChar = c;
00305          return *this;
00306       }
00307
00312       IoFormat<T>& width( int w )
00313       {
00314          theWidth = w;
00315          return *this;
00316       }
00317
00322       IoFormat<T>& precision( int p )
00323       {
00324          thePrecision = p;
00325          return *this;
00326       }
00327
00329
00330    protected:
00335       void setf( fmtflags f )
00336       {
00337          theFlags = flags() | f;
00338       }
00339
00344       void setf( fmtflags f, fmtflags msk )
00345       {
00346          theFlags = ( flags() & ~msk ) | f & msk ;
00347       }
00348
00353       void unsetf( fmtflags msk = ~0 )
00354       {
00355          theFlags = flags() & ~msk;
00356       }
00357
00358    private:
00361
00362       int thePrecision;
00363       int theWidth;
00364       int theFillChar;
00365       fmtflags theFlags;
00366
00368    };
00369
00377    template <typename T>
00378    class BoundIoFormat
00379    {
00380    public:
00382
00383       BoundIoFormat( const IoFormat<T>& f, const T& v ): theFormat(f), theValue(v)
00384       {
00385          ; // do nothing
00386       }
00387
00388       const IoFormat<T>& theFormat;
00389       T                  theValue;
00390    };
00391
00396    template <typename T>
00397    inline BoundIoFormat<T> IoFormat<T>::operator()( const T& v ) const
00398    {
00399       return BoundIoFormat<T>( *this, v );
00400    }
00401
00406    template <typename T> std::ostream& operator<< ( std::ostream& os, const Rulbus::BoundIoFormat<T>& bf )
00407    {
00408       std::ostringstream s;
00409
00410       s.fill     ( bf.theFormat.fill()      );
00411       s.width    ( bf.theFormat.width()     );
00412       s.precision( bf.theFormat.precision() );
00413       s.flags    ( bf.theFormat.flags()     );
00414
00415       s << bf.theValue;
00416
00417       return os << s.str();
00418    }
00419
00420 } // namespace Rulbus
00421
00422 #endif  // __IOFORMAT_H
00423
00424 /*
00425  * end of file
00426  */
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: IsaRulbusInterface.h Source File

IsaRulbusInterface.h

00001 /*
00002  * IsaRulbusInterface.h - class IsaRulbusInterface.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: IsaRulbusInterface.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __ISARULBUSINTERFACE_H
00026 #define __ISARULBUSINTERFACE_H
00027
00028 #ifndef __RULBUSINTERFACE_H
00029 #include "rulbusinterface.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( IsaRulbusInterface );
00035
00046    class IsaRulbusInterface: public TheRulbusInterface
00047    {
00048    public:                                         // P U B L I C
00050
00051       IsaRulbusInterface( long aBase = DEF_ISA_BASE );
00052
00055
00056       long base() const;
00057       bool invariant() const;
00058
00061
00062       bool printOn( std::ostream& stream ) const;
00063
00064    protected:                                      // P R O T E C T E D
00067
00068       IsaRulbusInterface( IsaRulbusInterfaceRef );
00069       IsaRulbusInterfaceRef operator=( IsaRulbusInterfaceRef );
00070
00074
00075       bool validBase( long base ) const;
00076
00080
00081       int getReg( int offset           ) const;
00082       int putReg( int offset, int byte ) const;
00083
00085
00086    public:                                         // P U B L I C
00087       static const long DEF_ISA_BASE = 0x0200;
00088
00089    private:                                        // P R I V A T E
00090       long              theBase;
00091       static const long baseMin = 0x0200;
00092       static const long baseMax = 0xFF00;
00093       static const long baseStp = 0x0100;
00094       static CharCptr   msgtitle;
00095    };
00096
00101    inline long IsaRulbusInterface::base() const
00102    {
00103       return theBase;
00104    }
00105
00110    inline bool IsaRulbusInterface::invariant() const
00111    {
00112       return BASE_INVARIANT( TheRulbusInterface );
00113    }
00114
00115 }       // namespace Rulbus
00116
00117 #endif  // __ISARULBUSINTERFACE_H
00118
00119 /*
00120  * end of file
00121  */
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Namespace Member Index

- b -

  • backslash() : Rulbus

- e -

  • eq() : Rulbus

- f -

  • fmtstring() : Rulbus

- i -

  • inp() : Rulbus
  • isletter() : Rulbus
  • isnumeric() : Rulbus
  • isquote() : Rulbus
  • isspecial() : Rulbus

- k -

  • kwcmp() : Rulbus

- o -

  • openIO() : Rulbus
  • operator<<() : Rulbus
  • outp() : Rulbus

- t -

  • to() : Rulbus
  • to_bcd() : Rulbus
  • to_cstr() : Rulbus
  • to_int() : Rulbus
  • to_rb() : Rulbus
  • to_rb8506() : Rulbus
  • to_rb8506_pia() : Rulbus
  • to_rb8506_pia_ptr() : Rulbus
  • to_rb8506_ptr() : Rulbus
  • to_rb8506_sifu() : Rulbus
  • to_rb8506_sifu_ptr() : Rulbus
  • to_rb8506_via() : Rulbus
  • to_rb8506_via_ptr() : Rulbus
  • to_rb8509() : Rulbus
  • to_rb8509_ptr() : Rulbus
  • to_rb8510() : Rulbus
  • to_rb8510_ptr() : Rulbus
  • to_rb8513() : Rulbus
  • to_rb8513_ptr() : Rulbus
  • to_rb8514() : Rulbus
  • to_rb8514_ptr() : Rulbus
  • to_rb8515() : Rulbus
  • to_rb8515_ptr() : Rulbus
  • to_rb8905() : Rulbus
  • to_rb8905_ptr() : Rulbus
  • to_rb9005() : Rulbus
  • to_rb9005_ptr() : Rulbus
  • to_rb9603() : Rulbus
  • to_rb9603_ptr() : Rulbus
  • to_rb_ptr() : Rulbus
  • to_real() : Rulbus
  • to_string() : Rulbus
  • to_string16() : Rulbus
  • to_string2() : Rulbus
  • to_string8() : Rulbus
  • to_string_pfx() : Rulbus
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Namespace Member Index

- a -

  • Addr : Rulbus

- b -

  • Byte : Rulbus

- c -

  • Char : Rulbus

- f -

  • float32 : Rulbus
  • float64 : Rulbus
  • Freq : Rulbus

- i -

  • Int : Rulbus
  • int16 : Rulbus
  • Int16 : Rulbus
  • Int32 : Rulbus
  • int32 : Rulbus
  • int8 : Rulbus
  • isEqualFreq : Rulbus
  • isEqualTime : Rulbus
  • isEqualVolt : Rulbus

- l -

  • List : Rulbus

- n -

  • Name : Rulbus

- q -

  • Quad : Rulbus

- r -

  • Rack : Rulbus
  • Real : Rulbus
  • Real32 : Rulbus
  • Real64 : Rulbus

- s -

  • StdException : Rulbus
  • String : Rulbus

- t -

  • Time : Rulbus

- u -

  • uInt16 : Rulbus
  • uInt32 : Rulbus
  • uInt8 : Rulbus

- v -

  • Volt : Rulbus
  • Volt32 : Rulbus

- w -

  • Word : Rulbus
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Namespace Member Index

  • kwTable : Rulbus
Generated on Tue Oct 12 14:12:06 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: PiaVia.h Source File

PiaVia.h

00001 /*
00002  * piavia.h - PIA/VIA.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: PiaVia.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __PIAVIA_H
00026 #define __PIAVIA_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"       // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( Pia    );    // Pia class
00035    DECLARE_CLASS( Via    );    // Via class
00036    DECLARE_CLASS( PiaVia );    // abstract base class
00037
00181    class PiaVia: public RulbusDevice
00182    {
00183    public:
00186
00187       PiaVia( NameCref aName, Addr aAddr, Addr aWidth, Rack aRack ):
00188          RulbusDevice( aName, aAddr, aWidth, aRack )
00189       {
00190          ; // do nothing
00191       }
00192
00193       virtual ~PiaVia() { ; }
00194
00198
00199       virtual   int   getPortDir    ( CharCptr prt );
00200       virtual   int   getPortData   ( CharCptr ptr );
00201
00202       virtual   char  getLineDir    ( CharCptr lin );
00203       virtual   int   getLineLevel  ( CharCptr lin );
00204
00208
00209       virtual   int   getDirPA      (         );
00210       virtual   int   getDataPA     (         );
00211
00212       virtual   char  getLineDirPA  ( int pin );
00213       virtual   int   getLineLevelPA( int pin );
00214
00218
00219       virtual   int   getDirPB      (         );
00220       virtual   int   getDataPB     (         );
00221
00222       virtual   char  getLineDirPB  ( int pin );
00223       virtual   int   getLineLevelPB( int pin );
00224
00228
00229       // control port A, CA1 (input only):
00230       virtual   int   getIrqCA1     (         ) = 0;
00231       virtual   char  getEdgeCA1    (         ) = 0;
00232       virtual   int   getIntrCA1    (         ) = 0;
00233
00234       // control port A, CA2 (input and output):
00235       virtual   char  getDirCA2     (         ) = 0;
00236       virtual   int   getLevelCA2   (         ) = 0;
00237
00241
00242       // control port B, CB1 (input only):
00243       virtual   int   getIrqCB1     (         ) = 0;
00244       virtual   char  getEdgeCB1    (         ) = 0;
00245       virtual   int   getIntrCB1    (         ) = 0;
00246
00247       // control port B, CB2 (input and output):
00248       virtual   char  getDirCB2     (         ) = 0;
00249       virtual   int   getLevelCB2   (         ) = 0;
00250
00254
00255       virtual   void  setPortDir    ( CharCptr prt, int msk  );
00256       virtual   void  setPortData   ( CharCptr prt, int dat  );
00257
00258       virtual   void  setLineDir    ( CharCptr lin, char dir );
00259       virtual   void  setLineLevel  ( CharCptr lin, int  lvl );
00260
00264
00265       virtual   void  setDirPA      ( int msk );
00266       virtual   void  setDataPA     ( int dat );
00267
00268       virtual   void  setLineDirPA  ( int pin, char dir );
00269       virtual   void  setLineLevelPA( int pin, int  lvl );
00270
00274
00275       virtual   void  setDirPB      ( int msk );
00276       virtual   void  setDataPB     ( int dat );
00277
00278       virtual   void  setLineDirPB  ( int pin, char dir );
00279       virtual   void  setLineLevelPB( int pin, int  lvl );
00280
00284
00285       virtual   void  setEdgeCA1    ( char edge  ) = 0;
00286       virtual   int   setIntrCA1    ( int enable ) = 0;
00287
00288       virtual   void  setDirCA2     ( char dir   ) = 0;
00289       virtual   void  setLevelCA2   ( int  lvl   ) = 0;
00290
00294
00295       virtual   void  setEdgeCB1    ( char edge  ) = 0;
00296       virtual   int   setIntrCB1    ( int enable ) = 0;
00297
00298       virtual   void  setDirCB2     ( char dir   ) = 0;
00299       virtual   void  setLevelCB2   ( int  lvl   ) = 0;
00300
00302
00303    protected:
00306
00307       void            checkPin      ( int  pin );
00308       void            checkDir      ( char dir );
00309       void            checkData     ( int  dat );
00310       void            checkMask     ( int  msk );
00311
00315
00316       virtual   int   getDDRA       (          ) = 0;
00317       virtual   int   getPDRA       (          ) = 0;
00318
00319       virtual   int   getDDRB       (          ) = 0;
00320       virtual   int   getPDRB       (          ) = 0;
00321
00325
00326       virtual   void  setDDRA       ( int dir  ) = 0;
00327       virtual   void  setPDRA       ( int dat  ) = 0;
00328
00329       virtual   void  setDDRB       ( int dir  ) = 0;
00330       virtual   void  setPDRB       ( int dat  ) = 0;
00331
00333
00334    private:
00335    };
00336
00423    class Pia : public PiaVia
00424    {
00425    public:
00428
00430       Pia ( NameCref aName, Addr aAddr = DEF_ADDR, Rack aRack = DEF_RACK ):
00431          PiaVia( aName, aAddr, ADR_WIDTH, aRack ) { ; }
00432
00433       virtual  ~Pia() { ; }
00434
00435
00439
00440       // control port A, CA1 (input only):
00441       int          getIrqCA1  (            );
00442       char         getEdgeCA1 (            );
00443       int          getIntrCA1 (            );
00444
00445       // control port A, CA2 (input and output):
00446       char         getDirCA2  (            );
00447       int          getLevelCA2(            );
00448
00452
00453       // control port B, CB1 (input only):
00454       int          getIrqCB1  (            );
00455       char         getEdgeCB1 (            );
00456       int          getIntrCB1 (            );
00457
00458       // control port B, CB2 (input and output):
00459       char         getDirCB2  (            );
00460       int          getLevelCB2(            );
00461
00465
00466       void         setEdgeCA1 ( char edge  );
00467       int          setIntrCA1 ( int enable );
00468
00469       void         setDirCA2  ( char dir   );
00470       void         setLevelCA2( int  lvl   );
00471
00475
00476       void         setEdgeCB1 ( char edge  );
00477       int          setIntrCB1 ( int enable );
00478
00479       void         setDirCB2  ( char dir   );
00480       void         setLevelCB2( int  lvl   );
00481
00483
00484    protected:
00487
00488       int          getDDRA    (            );
00489       int          getPDRA    (            );
00490
00491       int          getDDRB    (            );
00492       int          getPDRB    (            );
00493
00497
00498       void         setDDRA    ( int dir    );
00499       void         setPDRA    ( int dat    );
00500
00501       void         setDDRB    ( int dir    );
00502       void         setPDRB    ( int dat    );
00503
00505
00506    private:
00509
00510       void         select_ddra();
00511       void         select_pdra();
00512       void         select_ddrb();
00513       void         select_pdrb();
00514
00518
00519       int          getIrqC1   ( int offset );
00520       char         getEdgeC1  ( int offset );
00521       void         setEdgeC1  ( int offset, char edge, char port);
00522       int          getIntrC1  ( int offset );
00523       int          setIntrC1  ( int offset, int enable);
00524
00528
00529       char         getDirC2   ( int offset );
00530       void         setDirC2   ( int offset, char dir, char port );
00531       int          getLevelC2 ( int offset );
00532       void         setLevelC2 ( int offset, int  lvl, char port );
00533
00535
00536    public:
00539
00540       static const int DEF_ADDR = 0x90;
00541       static const int DEF_RACK = 0;
00542
00544
00545    private:
00548
00549       static const int OFF_DDRA = 0;
00550       static const int OFF_PDRA = 0;
00551       static const int OFF_CRA  = 1;
00552       static const int OFF_DDRB = 2;
00553       static const int OFF_PDRB = 2;
00554       static const int OFF_CRB  = 3;
00555       static const int ADR_WIDTH= OFF_CRB + 1;
00556
00560
00561       static const int MSK_EIC1 = 0x01;
00562       static const int MSK_ATC1 = 0x02;
00563       static const int MSK_SPDR = 0x04;
00564
00568
00569       static const int MSK_DIRC2= 0x20;
00570
00574
00575       static const int MSK_ATC2 = 0x10;
00576       static const int MSK_EIC2 = 0x08;
00577
00581
00582       static const int MSK_POC2 = 0x10;
00583       static const int MSK_OLC2 = 0x08;
00584
00588
00589       static const int MSK_IRQ1 = 0x80;
00590       static const int MSK_IRQ2 = 0x40;
00591
00593    };
00594
00712    class Via : public PiaVia
00713    {
00714    public:
00717
00719       Via ( NameCref aName, Addr aAddr = DEF_ADDR, Rack aRack = DEF_RACK ):
00720          PiaVia( aName, aAddr, ADR_WIDTH, aRack ) { ; }
00721
00722       virtual  ~Via() { ; }
00723
00727
00728       // control port A, CA1 (input only):
00729       int          getIrqCA1  (            );
00730       char         getEdgeCA1 (            );
00731       int          getIntrCA1 (            );
00732
00733       // control port A, CA2 (input and output):
00734       char         getDirCA2  (            );
00735       int          getLevelCA2(            );
00736
00740
00741       // control port B, CB1 (input only):
00742       int          getIrqCB1  (            );
00743       char         getEdgeCB1 (            );
00744       int          getIntrCB1 (            );
00745
00746       // control port B, CB2 (input and output):
00747       char         getDirCB2  (            );
00748       int          getLevelCB2(            );
00749
00753
00754       // control port A, CA1 (input only):
00755       void         setEdgeCA1 ( char edge  );
00756       int          setIntrCA1 ( int enable );
00757
00758       // control port A, CA2 (input and output):
00759       void         setDirCA2  ( char dir   );
00760       void         setLevelCA2( int  lvl   );
00761
00765
00766       // control port B, CB1 (input only):
00767       void         setEdgeCB1 ( char edge  );
00768       int          setIntrCB1 ( int enable );
00769
00770       // control port B, CB2 (input and output):
00771       void         setDirCB2  ( char dir   );
00772       void         setLevelCB2( int  lvl   );
00773
00775
00776    protected:
00779
00780       int          getDDRA    (            );
00781       int          getPDRA    (            );
00782
00783       int          getDDRB    (            );
00784       int          getPDRB    (            );
00785
00789
00790       void         setDDRA    ( int dir    );
00791       void         setPDRA    ( int dat    );
00792
00793       void         setDDRB    ( int dir    );
00794       void         setPDRB    ( int dat    );
00795
00797
00798    private:
00801
00802       // control ports A/B, C1 (input only):
00803       int          getIrqC1   ( int mask   );
00804       char         getEdgeC1  ( int shift  );
00805       void         setEdgeC1  ( int shift, char edge, char port );
00806       int          getIntrC1  ( int mask   );
00807       int          setIntrC1  ( int mask, int enable);
00808
00812
00813       // control port A/B, C2 (input and output):
00814       char         getDirC2   ( int shift  );
00815       void         setDirC2   ( int shift, char dir, char port );
00816       int          getLevelC2 ( int shift,           char port );
00817       void         setLevelC2 ( int shift, int  lvl, char port );
00818
00820
00821    public:
00824
00825       static const int DEF_ADDR = 0x90;
00826       static const int DEF_RACK = 0;
00827
00829
00830    private:
00833
00834       static const int OFF_PDRB    =  0;
00835       static const int OFF_PDRA    =  1;
00836       static const int OFF_DDRB    =  2;
00837       static const int OFF_DDRA    =  3;
00838       static const int OFF_T1CL    =  4;
00839       static const int OFF_T1CH    =  5;
00840       static const int OFF_T1LL    =  6;
00841       static const int OFF_T1LH    =  7;
00842       static const int OFF_T2CL    =  8;
00843       static const int OFF_T2CH    =  9;
00844       static const int OFF_SR      = 10;
00845       static const int OFF_ACR     = 11;
00846       static const int OFF_PCR     = 12;
00847       static const int OFF_IFR     = 13;
00848       static const int OFF_IER     = 14;
00849       static const int OFF_PDRA_NH = 15;
00850       static const int ADR_WIDTH   = OFF_PDRA_NH + 1;
00851
00855
00859
00860       static const int SHL_CA    = 0;
00861       static const int SHL_CB    = 4;
00862
00866
00867       static const int MSK_ATC1  = 0x01;
00868
00872
00873       static const int MSK_DIRC2 = 0x08;
00874       static const int MSK_POC2  = 0x04;
00875       static const int MSK_OLC2  = 0x02;
00876
00880
00881       static const int MSK_IFCA2 = 0x01;
00882       static const int MSK_IFCA1 = 0x02;
00883       static const int MSK_IFSR  = 0x04;
00884       static const int MSK_IFCB2 = 0x08;
00885       static const int MSK_IFCB1 = 0x10;
00886       static const int MSK_IFCT2 = 0x20;
00887       static const int MSK_IFCT1 = 0x40;
00888       static const int MSK_IFIRQ = 0x80;
00889
00893
00894       static const int MSK_IECA2 = 0x01;
00895       static const int MSK_IECA1 = 0x02;
00896       static const int MSK_IESR  = 0x04;
00897       static const int MSK_IECB2 = 0x08;
00898       static const int MSK_IECB1 = 0x10;
00899       static const int MSK_IECT2 = 0x20;
00900       static const int MSK_IECT1 = 0x40;
00901       static const int MSK_IESC  = 0x80;
00902
00904    };
00905
00908 }       // namespace Rulbus
00909
00910 #endif // __PIAVIA_H
00911
00912 /*
00913  * end of file
00914  */
00915
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Portio.h Source File

Portio.h

00001 /*
00002  * portio.h - functions for port I/O.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: Portio.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __PORTIO_H
00026 #define __PORTIO_H
00027
00034 #ifdef DOXYGEN
00035    #define CANIO
00036 #endif
00037
00044 #ifdef DOXYGEN
00045    #define DriverLINX
00046 #endif
00047
00054 #if defined(CANIO)                      // CANIO port I/O
00055 //   #include "canio.h"                   // for AddMultiPort() // using LoadLibrary
00056 //   #include "portio.h"                  // for inp() and outp()
00057    #define   SPORTIO "CanIO"
00058    #pragma message ("Note: using CanIO for port I/O.")
00059
00060    namespace Rulbus
00061    {
00086       short inp( unsigned short port );
00087
00108       short outp( unsigned short port, unsigned char value );
00109
00119       bool  openIO( long base, int len );
00120
00123    }       // namespace Rulbus
00124
00125 #elif defined(DriverLINX)               // DriverLINXport I/O
00126    #include "dlportio32.h"              // requires windows.h
00127    #define   inp(port)         DlPortReadPortUchar (port      )
00128    #define   outp(port, byte)  DlPortWritePortUchar(port, byte)
00129    #define   SPORTIO "DriverLinx"
00130    #pragma message ("Note: using DriverLINX for port I/O.")
00131 #else
00132    #error Please specify Port IO selection: CANIO or DriverLINX .
00133 #endif
00134
00135 #endif  // __PORTIO_H
00136
00137 /*
00138  * end of file
00139  */
00140
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb8506_pport.h Source File

rb8506_pport.h

00001 /*
00002  * rb8506_par.h - dual parallel interface (PIA/VIA) (RB8506).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb8506_pport.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB8506_PAR_H
00026 #define __RB8506_PAR_H
00027
00028 #ifndef __PIAVIA_H
00029 #include "PiaVia.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB8506_Pia    );              // the Pia Parallel Interface class type
00035    DECLARE_CLASS( RB8506_Via    );              // the Via Parallel Interface class type
00036
00037    DECLARE_TYPE ( PiaVia, RB8506_PiaVia );      // the PiaVia Parallel Interface class type
00038
00126    class RB8506_Pia : public Pia
00127    {
00128    public:
00129       RB8506_Pia( NameCref name, Addr addr = Pia::DEF_ADDR, Rack rack = Pia::DEF_RACK ):
00130          Pia( name, addr, rack ) { ; }
00131    };
00132
00141    class RB8506_Via : public Via
00142    {
00143    public:
00144       RB8506_Via( NameCref name, Addr addr = Via::DEF_ADDR, Rack rack = Via::DEF_RACK ):
00145          Via( name, addr, rack ) { ; }
00146    };
00147
00151
00156    inline PiaViaRef to_rb8506( RulbusDevicePtr p )
00157    {
00158       return PROXY_CAST<PiaViaRef>( *p );
00159    }
00160
00165    inline PiaViaPtr to_rb8506_ptr( RulbusDevicePtr p )
00166    {
00167       return PROXY_CAST<PiaViaPtr>( p );
00168    }
00169
00174    inline RB8506_PiaRef to_rb8506_pia( RulbusDevicePtr p )
00175    {
00176       return PROXY_CAST<RB8506_PiaRef>( *p );
00177    }
00178
00183    RB8506_PiaPtr to_rb8506_pia_ptr( RulbusDevicePtr p )
00184    {
00185       return PROXY_CAST<RB8506_PiaPtr>( p );
00186    }
00187
00192    inline RB8506_ViaRef to_rb8506_via( RulbusDevicePtr p )
00193    {
00194       return PROXY_CAST<RB8506_ViaRef>( *p );
00195    }
00196
00201    inline RB8506_ViaPtr to_rb8506_via_ptr( RulbusDevicePtr p )
00202    {
00203       return PROXY_CAST<RB8506_ViaPtr>( p );
00204    }
00205
00206 }       // namespace Rulbus
00207
00208 #endif // __RB8506_PAR_H
00209
00210 /*
00211  * end of file
00212  */
00213
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb8506_sifu.h Source File

rb8506_sifu.h

00001 /*
00002  * rb8506_sifu.h -   (RB8506).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb8506_sifu.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB8506_SIFU_H
00026 #define __RB8506_SIFU_H
00027
00028 #ifndef __PIAVIA_H
00029 #include "PiaVia.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB8506_Sifu );  //
00035
00036    /* *
00037     * \example name.cpp
00038     * This is an example that shows ... .
00039     */
00040
00215    class RB8506_Sifu : public Pia
00216    {
00217    public:                              // public methods
00220
00221       ~RB8506_Sifu();
00222       RB8506_Sifu( NameCref name, Addr addr = DEF_ADDR, Rack rack = DEF_RACK );
00223
00227
00228       int   getInputPortData ();
00229       int   getOutputPortData();
00230
00231       bool  isChangedInputLine (          );
00232       int   tstInputLineLevel  ( int line );
00233       int   getInputLineLevel  ( int line );
00234       int   getOutputLineLevel ( int line );
00235
00236       bool  isEnabledPulseOutputs();
00237
00241
00242       void  setOutputPortData ( int data );
00243       void  setOutputLineLevel( int line, bool set );
00244
00245       void  enablePulseOutputs( bool enable = true );
00246
00248
00249    protected:                                   // protected methods
00252
00253       RB8506_Sifu();
00254       RB8506_Sifu( RB8506_SifuCref rhs );
00255       RB8506_SifuRef operator= ( RB8506_SifuCref rhs );
00256
00260
00261       void   clearFlipFlops();
00262
00266
00267       static int swapNibbles( int byte );
00268       static int swapLines  ( int line );
00269
00271
00272    public:                                      // public data
00275
00276       static const Addr DEF_ADDR = Pia::DEF_ADDR + 4;
00277
00278       static const int  DEF_DIRPA   = 0xFF;
00279       static const int  DEF_DIRPB   = 0x00;
00280       static const char DEF_EDGECB1 = 'p';
00281       static const char DEF_DIRCA2  = 'o';
00282       static const char DEF_DIRCB2  = 'o';
00283       static const char DEF_LVLCA2  =  0;
00284       static const char DEF_LVLCB2  =  1;
00285       static const bool DEF_INTRCB1 = true;
00286       static const int  DEF_OUTDATA =  0;
00287
00289    };
00290
00292
00298    inline bool RB8506_Sifu::isChangedInputLine()
00299    {
00300       return getIrqCB1();
00301    }
00302
00307    inline int RB8506_Sifu::getOutputPortData()
00308    {
00309       return getDataPA();
00310    }
00311
00316    inline void RB8506_Sifu::setOutputPortData( int data )
00317    {
00318       setDataPA( data );
00319    }
00320
00325    inline int RB8506_Sifu::getOutputLineLevel( int line )
00326    {
00327       return getLineLevelPA( line );
00328    }
00329
00334    inline void RB8506_Sifu::setOutputLineLevel( int line, bool set )
00335    {
00336       setLineLevelPA( line, set );
00337    }
00338
00343    inline bool RB8506_Sifu::isEnabledPulseOutputs()
00344    {
00345       return getLevelCA2();
00346    }
00347
00352    inline void RB8506_Sifu::enablePulseOutputs( bool enable /* = true */ )
00353    {
00354       setLevelCA2( enable );
00355    }
00356
00361    inline void RB8506_Sifu::clearFlipFlops()
00362    {
00363       setLevelCB2( 0 );
00364       setLevelCB2( 1 );
00365    }
00366
00371    inline int RB8506_Sifu::swapNibbles( int byte )
00372    {
00373       return ( byte >> 4 ) | ( ( byte & 0xF ) << 4 );
00374    }
00375
00380    inline int RB8506_Sifu::swapLines( int line )
00381    {
00382       return ( line < 4 ) ? line + 4 : line - 4;
00383    }
00384
00389    inline RB8506_SifuRef to_rb8506_sifu( RulbusDevicePtr p )
00390    {
00391       return PROXY_CAST<RB8506_SifuRef>( *p );
00392    }
00393
00398    inline RB8506_SifuPtr to_rb8506_sifu_ptr( RulbusDevicePtr p )
00399    {
00400       return PROXY_CAST<RB8506_SifuPtr>( p );
00401    }
00402
00403 } // namespace Rulbus
00404
00405 #endif  // __RB8506_SIFU_H
00406
00407 /*
00408  * end of file
00409  */
00410
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb8509_adc12.h Source File

rb8509_adc12.h

00001 /*
00002  * rb8509_adc12.h - 8-channel 12-bit ADC (RB8509).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb8509_adc12.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB8509_Adc12_ADC12_H
00026 #define __RB8509_Adc12_ADC12_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"       // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB8509_Adc12 );       // the 12-bit ADC class type
00035
00036    /* *
00037     * \example name.cpp
00038     * This is an example that shows ... .
00039     */
00040
00193    class RB8509_Adc12 : public RulbusDevice
00194    {
00195    public:                              // public methods
00196       typedef Int Value;
00197
00200
00201       RB8509_Adc12(
00202          NameCref aName,
00203          Addr     aAddr           = DEF_ADDR,
00204          Rack     aRack           = DEF_RACK,
00205          bool     aBipolarFlag    = DEF_BIP,
00206          Real     aVoltPerBit     = DEF_VPB,
00207          bool     aExtTrigInpFlag = DEF_ETI
00208       );
00209
00210       ~RB8509_Adc12();
00211
00215
00216       int    channel() const;
00217       int    gain() const;
00218
00219       Volt   voltage();
00220       Value  value() ;
00221       Value  result();
00222       Value  rawresult();
00223
00224       bool   hasExtTriggerInput() const;
00225
00226       bool   extTriggerLevel() const;
00227
00228       bool   isEnabledExtTrigger() const;
00229       bool   isEnabledMultiplexer() const;
00230       bool   isEnabledInterrupt() const;
00231
00232       bool   isBusyAdc() const;
00233       bool   isReady() const;
00234       bool   isBipolar() const;
00235       bool   isPendingInterrupt() const;
00236
00237       Real   voltperbit() const;
00238
00242
00243       bool   isValidChannel( int aChannel ) const;
00244       bool   isValidGain   ( int aGain    ) const;
00245
00249
00250       void   setChannel( int aChannel );
00251
00252       void   setGain   ( int aGain    );
00253       void   autoscale ();
00254
00255       void   convert   ();
00256
00257       bool   enableMultiplexer( bool enable = true );
00258       bool   enableExtTrigger ( bool enable = true );
00259       bool   enableInterrupt  ( bool enable = true );
00260
00262
00263    protected:                                   // protected methods
00266
00267       RB8509_Adc12();
00268       RB8509_Adc12( RB8509_Adc12Cref rhs );
00269       RB8509_Adc12Ref operator= ( RB8509_Adc12Cref rhs );
00270
00274
00275       void   checkChannel  ( int aChannel ) const;
00276       void   checkGain     ( int aGain    ) const;
00277
00279
00280    public:                                      // public data
00283
00284       static const Addr  DEF_ADDR    = 0xC0;
00285 //      static const Rack  DEF_RACK    = 0;       ///< default rack
00286       static const int   DEF_GAIN    = 1;
00287       static const int   DEF_CHAN    = 0;
00288       static const bool  DEF_BIP     = true;
00289       static const Real  DEF_VPB  /* = 5e-3 */;
00290       static const bool  DEF_ETI     = false;
00291
00295
00296       static const int   LIM_MINCHAN = 0;
00297       static const int   LIM_MAXCHAN = 7;
00298
00299       static const int   LIM_MINGAIN = 1;
00300       static const int   LIM_MAXGAIN = 8;
00301
00302       static const Real  LIM_MINVPB  /* =  1e-3 */ ;
00303       static const Real  LIM_MAXVPB  /* = 10e-3 */ ;
00304
00305       static const int   LIM_TIMOUT  = 1000;
00306       static const Value LIM_MINVAL  = 0x0000;
00307       static const Value LIM_MAXVAL  = 0x0FFF;
00308       static const Value LIM_BIPVAL  = 0x0800;
00309
00311
00312    private:                                     // private data
00315
00316       Byte  theControlRegister;
00317       bool  theExtTrigInpFlag;
00318       bool  theBipolarFlag;
00319       Real  theVoltPerBit;
00320
00324
00325       static const int  OFF_ADCLSB  = 0;
00326       static const int  OFF_CONTROL = 0;
00327       static const int  OFF_STATUS  = 1;
00328       static const int  OFF_CONVERT = 1;
00329       static const int  ADR_WIDTH   = OFF_CONVERT + 1;
00330
00334
00335       static const int  MSK_CTLCHAN  = 0x07;
00336       static const int  MSK_CTLMPLX  = 0x08;
00337       static const int  MSK_CTLGAIN  = 0x30;
00338       static const int  MSK_CTLTRIG  = 0x40;
00339       static const int  MSK_CTLINTR  = 0x80;
00340
00341       static const int  MSK_STSBSY   = 0x10;
00342       static const int  MSK_STSEOC   = 0x20;
00343       static const int  MSK_STSINTR  = 0x40;
00344       static const int  MSK_STSTRIG  = 0x80;
00345       static const int  MSK_VALMSN   = 0x0F;
00346
00347       static const int  SHL_CTLCHAN  = 0;
00348       static const int  SHL_CTLGAIN  = 4;
00349
00351    };
00352
00354
00359    inline bool RB8509_Adc12::hasExtTriggerInput() const
00360    {
00361       return theExtTrigInpFlag;
00362    }
00363
00368    inline bool RB8509_Adc12::isBipolar() const
00369    {
00370        return theBipolarFlag;
00371    }
00372
00377    inline Real RB8509_Adc12::voltperbit() const
00378    {
00379       return theVoltPerBit;
00380    }
00381
00386    inline bool RB8509_Adc12::isValidChannel( int aChannel ) const
00387    {
00388       return aChannel >= LIM_MINCHAN &&
00389              aChannel <= LIM_MAXCHAN ;
00390    }
00391
00396    inline bool RB8509_Adc12::isValidGain( int aGain ) const
00397    {
00398       return aGain == 1 ||
00399              aGain == 2 ||
00400              aGain == 4 ||
00401              aGain == 8 ;
00402    }
00403
00408    inline RB8509_Adc12Ref to_rb8509( RulbusDevicePtr p )
00409    {
00410       return PROXY_CAST<RB8509_Adc12Ref>( *p );
00411    }
00412
00417    inline RB8509_Adc12Ptr to_rb8509_ptr( RulbusDevicePtr p )
00418    {
00419       return PROXY_CAST<RB8509_Adc12Ptr>( p );
00420    }
00421
00422 } // namespace Rulbus
00423
00424 #endif  // __RB8509_Adc12_ADC12_H
00425
00426 /*
00427  * end of file
00428  */
00429
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb8510_dac12.h Source File

rb8510_dac12.h

00001 /*
00002  * rb8510_dac12.h - dual 12-bit DAC (RB8510).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb8510_dac12.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB8510_DAC12_H
00026 #define __RB8510_DAC12_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"       // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB8510_Dac12 );       // the 12-bit DAC class type
00035
00163    class RB8510_Dac12 : public RulbusDevice
00164    {
00165    public:                              // public methods
00166       typedef Int  Value;
00167
00170
00171       RB8510_Dac12(
00172          NameCref aName,
00173          Addr     aAddr        = DEF_ADDR,
00174          Rack     aRack        = DEF_RACK,
00175          bool     aBipolarFlag = DEF_BIP,
00176          Real     aVoltPerBit  = DEF_VPB );
00177
00178       ~RB8510_Dac12();
00179
00183
00184       Volt    voltage() const;
00185       Value   value() const;
00186
00187       bool    isBipolar() const;
00188       float   voltperbit() const;
00189
00193
00194       void    setVoltage ( Volt  aVoltage );
00195       void    setValue   ( Value aValue   );
00196
00198
00199    protected:                                   // protected methods
00202
00203       RB8510_Dac12();
00204       RB8510_Dac12( RB8510_Dac12Cref rhs );
00205       RB8510_Dac12Ref operator= ( RB8510_Dac12Cref rhs );
00206
00208
00209    public:                                      // public data
00212
00213       static const Addr  DEF_ADDR = 0xD0;
00214 //      static const Rack  DEF_RACK = 0;         ///< default rack
00215       static const bool  DEF_BIP  = true;
00216       static const Real  DEF_VPB  /* = 5e-3 */;
00217
00221
00222       static const Value LIM_MINVAL = 0x0000;
00223       static const Value LIM_MAXVAL = 0x0FFF;
00224       static const Value LIM_BIPVAL = 0x0800;
00225
00227
00228    private:                                     // private data
00231       Value theRegister;
00232       bool  theBipolarFlag;
00233       Real  theVoltPerBit;
00234
00238
00239       static const int   OFF_MSB = 0;
00240       static const int   OFF_LSB = 1;
00241
00242       static const int ADR_WIDTH = OFF_LSB + 1;
00243
00245    };
00246
00248
00253    inline RB8510_Dac12::Value RB8510_Dac12::value() const
00254    {
00255       return theRegister;
00256    }
00257
00262    inline bool RB8510_Dac12::isBipolar() const
00263    {
00264       return theBipolarFlag;
00265    }
00266
00271    inline float RB8510_Dac12::voltperbit() const
00272    {
00273       return theVoltPerBit;
00274    }
00275
00280    inline RB8510_Dac12Ref to_rb8510( RulbusDevicePtr p )
00281    {
00282       return PROXY_CAST<RB8510_Dac12Ref>( *p );
00283    }
00284
00289    inline RB8510_Dac12Ptr to_rb8510_ptr( RulbusDevicePtr p )
00290    {
00291       return PROXY_CAST<RB8510_Dac12Ptr>( p );
00292    }
00293
00294 } // namespace Rulbus
00295
00296 #endif  // __RB8510_DAC12_H
00297
00298 /*
00299  * end of file
00300  */
00301
Generated on Tue Oct 12 14:11:57 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb8513_timebase.h Source File

rb8513_timebase.h

00001 /*
00002  * rb8513_timebase.h - programmable timebase (RB8513).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb8513_timebase.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB8513_TIMEBASE_H
00026 #define __RB8513_TIMEBASE_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"       // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB8513_timebase );  //
00035
00036    /* *
00037     * \example name.cpp
00038     * This is an example that shows ... .
00039     */
00040
00166    class RB8513_timebase : public RulbusDevice
00167    {
00168    public:                              // public methods
00169       typedef Int Value;
00170
00173
00174       RB8513_timebase( NameCref name, Addr addr = DEF_ADDR, Rack rack = DEF_RACK );
00175
00176       ~RB8513_timebase();
00177
00181
00182       Time  intervalTime() const;
00183
00184       Value clockRateMultiplier() const;
00185       Value clockRateSelector  () const;
00186
00187
00191
00192       void stop();
00193
00194       void setIntervalTime        ( Time  aTime      );
00195
00196       void setClockRateMultiplier ( Value aValue     );
00197       void setClockRateSelector   ( Value aValue     );
00198
00200
00201    protected:                                   // protected methods
00204
00205       RB8513_timebase();
00206       RB8513_timebase( RB8513_timebaseCref rhs );
00207       RB8513_timebaseRef operator= ( RB8513_timebaseCref rhs );
00208
00210
00211    public:                                      // public data
00214
00215       static const Addr DEF_ADDR   = 0xB0;
00216
00217       static const int  DEF_MUL    = 1;
00218       static const int  DEF_SEL    = 4;
00219
00223
00224       static const int  LIM_MULMIN =  0;
00225       static const int  LIM_MULMAX = 99;
00226
00227       static const int  LIM_SELMIN =  0;
00228       static const int  LIM_SELMAX =  6;
00229       static const int  LIM_SELMAXFIXED = 3;
00230
00232
00233    private:                                     // private data
00236
00237       Value theMutiplyReg;
00238       Value theSelectorReg;
00239
00243
00244       static const int OFF_MUL     = 0;
00245       static const int OFF_SEL     = 1;
00246       static const int ADR_WIDTH   = OFF_SEL + 1;
00247
00251
00252       static const int MSK_SELSTP  = 0x10;
00253
00257
00258       static const Time  timeList[];
00259       static const Value selectorList[];
00260
00262    };
00263
00265
00270    inline RB8513_timebase::Value RB8513_timebase::clockRateMultiplier() const
00271    {
00272       return theMutiplyReg;
00273    }
00274
00280    inline RB8513_timebase::Value RB8513_timebase::clockRateSelector() const
00281    {
00282       return theSelectorReg;
00283    }
00284
00289    inline RB8513_timebaseRef to_rb8513( RulbusDevicePtr p )
00290    {
00291       return PROXY_CAST<RB8513_timebaseRef>( *p );
00292    }
00293
00298    inline RB8513_timebasePtr to_rb8513_ptr( RulbusDevicePtr p )
00299    {
00300       return PROXY_CAST<RB8513_timebasePtr>( p );
00301    }
00302
00303 } // namespace Rulbus
00304
00305 #endif  // __RB8513_TIMEBASE_H
00306
00307 /*
00308  * end of file
00309  */
00310
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb8514_delay.h Source File

rb8514_delay.h

00001 /*
00002  * rb8514_delay.cpp - programmable time delay (RB8514).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb8514_delay.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB8514_DELAY_H
00026 #define __RB8514_DELAY_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"               // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB8514_delay );       // the delay class type
00035
00182    class RB8514_delay : public RulbusDevice
00183    {
00184    public:                                              // public methods
00185       typedef Int32 Count;
00186
00189
00190       RB8514_delay( NameCref aName, Addr aAddr = DEF_ADDR, Rack aRack = DEF_RACK );
00191
00192       ~RB8514_delay();
00193
00197
00198       Freq   clockFrequency       () const;
00199       Time   intrinsicDelayTime   () const;
00200       Time   delayTime            () const;
00201       Count  delayCount           () const;
00202
00203       char   signalDirection      ( CharCptr signal ) const;    // [t s1 s2 e1 e2] -> [p n i]
00204       bool   isEnabledSignal      ( CharCptr signal ) const;
00205
00206       char   triggerEdge          () const;
00207       char   start12Direction     () const;
00208       char   end12Direction       () const;
00209
00210       bool   isEnabledStart1      () const;
00211       bool   isEnabledEnd1        () const;
00212       bool   isEnabledStart2      () const;
00213       bool   isEnabledEnd2        () const;
00214
00215       bool   isBusy               () const;
00216       bool   isPendingInterrupt   () ;          // non-const: clears pending interrupt
00217       bool   isEnabledInterrupt   () const;
00218
00222
00223       void   setClockFrequency    ( Freq freq );
00224       void   setIntrinsicDelayTime( Time time );
00225       void   setDelayTime         ( Time time );
00226       void   setDelayCount        ( Count count );
00227
00228       void   trigger              ();
00229
00230       void   setSignalDirection   ( CharCptr signal, char dir    );
00231       void   enableSignal         ( CharCptr signal, bool enable );
00232
00233       void   setTriggerEdge       ( char edge          );
00234       void   setStart12Direction  ( char dir           );
00235       void   setEnd12Direction    ( char dir           );
00236
00237       bool   enableStart1         ( bool enable = true );
00238       bool   enableEnd1           ( bool enable = true );
00239       bool   enableStart2         ( bool enable = true );
00240       bool   enableEnd2           ( bool enable = true );
00241
00242       void   clearInterrupt       ();
00243       bool   enableInterrupt      ( bool enable = true );
00244
00246
00247    protected:                                           // protected methods
00250
00251       RB8514_delay();
00252       RB8514_delay( RB8514_delayCref rhs );
00253       RB8514_delayRef operator= ( RB8514_delayCref rhs );
00254
00258
00259       bool   isValidSignalName     ( CharCptr aSignal, CharCptr aExtra ) const;
00260       bool   isValidSignalDirection( Char  aDirection ) const;
00261
00262       bool   isValidDelayCount     ( Count aCount ) const;
00263       bool   isValidClockFrequency ( Freq  aFreq  ) const;
00264       bool   isValidIntrinsicTime  ( Time  aTime  ) const;
00265
00267
00268    private:                                             // private methods
00269       int    countByte2         () const;               // msb
00270       int    countByte1         () const;
00271       int    countByte0         () const;               // lsb
00272
00273       char   getDirection       ( int  mask ) const;
00274       void   setDirection       ( char dir, int mask, CharCptr description );
00275
00276       bool   getEnable          ( int  mask ) const;
00277       void   setEnable          ( bool enable, int mask );
00278
00279    public:                                              // public data
00282
00283       static const Addr  DEF_ADDR  = 0xC4;
00284 //      static const Rack  DEF_RACK  = 0;                 ///< default rack
00285
00286       static const Freq  DEF_FRQ /* = 1.0 */ ;
00287       static const Time  DEF_IDT /* = 0.0 */ ;
00288       static const Time  DEF_DLY /* = 1.0 */ ;
00289       static const Count DEF_CNT /* = (DEF_DLY - DEF_IDT) * DEF_FRQ */ ;  // intrinsic delay count (
00290
00291       static const bool  DEF_EINT  = false;
00292       static const char  DEF_ETRG  = 'p';
00293       static const char  DEF_LS12  = 'p';
00294       static const char  DEF_LE12  = 'p';
00295       static const bool  DEF_ES1   = true;
00296       static const bool  DEF_EE1   = true;
00297       static const bool  DEF_ES2   = true;
00298       static const bool  DEF_EE2   = true;
00299
00303
00304       static const Count LIM_CNTMIN  = 0;
00305       static const Count LIM_CNTMAX  = 16777215;
00306
00307       static const Freq  LIM_FRQMIN /* = 1.0   */ ;
00308       static const Freq  LIM_FRQMAX /* = 100e6 */ ;
00309
00310       static const Time  LIM_IDTMIN /*  = 0.0    */ ;
00311       static const Time  LIM_IDTMAX /*  = 100e-9 */ ;
00312
00314
00315    private:                                             // private data
00318
00319       Byte   theControlRegister;
00320       Count  theDelayRegister;
00321       Freq   theClockFrequency;
00322       Time   theIntrinsicDelayTime;
00323
00327
00328       static const int  OFF_BT2     = 0;
00329       static const int  OFF_BT1     = 1;
00330       static const int  OFF_BT0     = 2;
00331       static const int  OFF_CTL     = 3;
00332       static const int  OFF_STS     = 3;
00333       static const int  ADR_WIDTH   = OFF_STS + 1;
00334
00338
00339       static const int  MSK_STSINT  = 0x01;
00340       static const int  MSK_STSBSY  = 0x02;
00341
00345
00346       static const int  MSK_CTLES1  = 0x01;
00347       static const int  MSK_CTLEE1  = 0x02;
00348       static const int  MSK_CTLES2  = 0x04;
00349       static const int  MSK_CTLEE2  = 0x08;
00350       static const int  MSK_CTLINT  = 0x10;
00351       static const int  MSK_CTLTRG  = 0x20;
00352       static const int  MSK_CTLLS12 = 0x40;
00353       static const int  MSK_CTLLE12 = 0x80;
00354
00358
00359       static const int  MSK_BYTE    = 0xFF;
00360
00361       // delay count shifts
00362
00363       static const int  SHR_BT2     = 16;
00364       static const int  SHR_BT1     =  8;
00365       static const int  SHR_BT0     =  0;
00366
00368    };
00369
00371
00376    inline Freq RB8514_delay::clockFrequency() const
00377    {
00378       return theClockFrequency;
00379    }
00380
00385    inline Time RB8514_delay::intrinsicDelayTime() const
00386    {
00387       return theIntrinsicDelayTime;
00388    }
00389
00394    inline RB8514_delayRef to_rb8514( RulbusDevicePtr p )
00395    {
00396       return PROXY_CAST<RB8514_delayRef>( *p );
00397    }
00398
00403    inline RB8514_delayPtr to_rb8514_ptr( RulbusDevicePtr p )
00404    {
00405       return PROXY_CAST<RB8514_delayPtr>( p );
00406    }
00407
00408 } // namespace Rulbus
00409
00410 #endif // __RB8514_DELAY_H
00411
00412 /*
00413  * end of file
00414  */
00415
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb8515_clock.h Source File

rb8515_clock.h

00001 /*
00002  * rb8515_clock.h - clock for delay module (RB8515).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb8515_clock.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB8515_CLOCK_H
00026 #define __RB8515_CLOCK_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"       // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB8515_clock );       // the clock for delay class type
00035
00166    class RB8515_clock: public RulbusDevice
00167    {
00168    public:
00172
00173       RB8515_clock( NameCref name, Addr addr = DEF_ADDR, Rack rack = DEF_RACK );
00174
00175       ~RB8515_clock();
00176
00180
00181       Freq   clockFrequency      () const;
00182       Freq   interruptFrequency  () const;
00183
00184       bool   isPendingInterrupt  () ;     // clears pending interrupt
00185       bool   isEnabledInterrupt  () const;
00186
00190
00191       void   setClockFrequency      ( Freq aFrequency );
00192       void   setInterruptFrequency  ( Freq aFrequency );
00193
00194       void   clearInterrupt         ();
00195
00196       bool   disableInterrupt       ();
00197       bool   enableInterrupt        ( bool enable = true );
00198
00200
00201    protected:                                           // protected methods
00204
00205       RB8515_clock();
00206       RB8515_clock( RB8515_clockCref rhs );
00207       RB8515_clockRef operator= ( RB8515_clockCref rhs );
00208
00210
00211    private:                                             // private data
00214
00215       Byte   theCtlByte;
00216
00220
00221       enum // ClockFreq
00222       {
00223         FC_INVALID = -1,
00224         FC_0Hz = 0,
00225         FC_100Hz,
00226         FC_1kHz,
00227         FC_10kHz,
00228         FC_100kHz,
00229         FC_1MHz,
00230         FC_10MHz,
00231         FC_100MHz,
00232       };
00233
00237
00238       enum // IntFreq
00239       {
00240          FI_INVALID = -1,
00241          FI_0Hz = 0,
00242          FI_1Hz,
00243          FI_5kHz,
00244          FI_10Hz,
00245          FI_50Hz,
00246          FI_100Hz,
00247          FI_500Hz,
00248          FI_1kHz,
00249       };
00250
00254
00255       static const int  OFF_CR      = 0;
00256       static const int  OFF_SR      = 0;
00257       static const int  ADR_WIDTH   = OFF_SR + 1;
00258
00262
00263       static const int  MSK_CLKFRQ  = 0x07;
00264       static const int  MSK_INTFRQ  = 0x38;
00265       static const int  MSK_INTENA  = 0x40;
00266       static const int  MSK_INTCLRn = 0x80;
00267       static const int  MSK_INTSTS  = 0x80;
00268
00269       static const int  SHL_CLKFRQ  = 0x00;
00270       static const int  SHL_INTFRQ  = 0x03;
00271
00275
00276       static const Addr DEF_ADDR = 0xC8;
00277       static const Freq DEF_CLKFRQ /* = 1e3 */ ;
00278       static const Freq DEF_INTFRQ /* = 0e0 */ ;
00279
00283
00291       struct FreqTable
00292       {
00293          Freq freq;
00294          Int  code;
00295       };
00296
00297       static FreqTable   clkTable[];
00298       static FreqTable   intTable[];
00299
00301
00302    protected:                                           // protected methods
00303       void   getClkFreqCode( Freq aFrequency, IntPtr pCode ) const;
00304       void   getIntFreqCode( Freq aFrequency, IntPtr pCode ) const;
00305       void   getFreqCode   ( Freq aFrequency, const FreqTable *tablePtr, IntPtr pCode ) const;
00306    };
00307
00309
00314    inline RB8515_clockRef to_rb8515( RulbusDevicePtr p )
00315    {
00316       return PROXY_CAST<RB8515_clockRef>( *p );
00317    }
00318
00323    inline RB8515_clockPtr to_rb8515_ptr( RulbusDevicePtr p )
00324    {
00325       return PROXY_CAST<RB8515_clockPtr>( p );
00326    }
00327
00328 } // namespace Rulbus
00329
00330 #endif // __RB8515_CLOCK_H
00331
00332 /*
00333  * end of file
00334  */
00335
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb8905_adc12.h Source File

rb8905_adc12.h

00001 /*
00002  * rb8905_adc12.h - high speed 12-bit ADC (RB8905).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb8905_adc12.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB8905_ADC12_H
00026 #define __RB8905_ADC12_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"       // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB8905_Adc12 );       // the 12-bit ADC class type
00035
00036    /* *
00037     * \example name.cpp
00038     * This is an example that shows ... .
00039     */
00040
00251    class RB8905_Adc12 : public RulbusDevice
00252    {
00253    public:                              // public methods
00254       typedef Int Value;
00255
00258
00259       RB8905_Adc12(
00260          NameCref aName,
00261          Addr     aAddr       = DEF_ADDR,
00262          Rack     aRack       = DEF_RACK,
00263          Real     aVoltPerBit = DEF_VPB
00264       );
00265
00266       ~RB8905_Adc12();
00267
00271
00272       void      arm        ();
00273       bool      isReady    () const;
00274
00275       int       readVoltage( Volt32*  pVoltage, int nelem );
00276       int       readValue  ( Int16*   pValue  , int nelem );
00277       Value     getValue   ();
00278       Value     getRawValue();
00279
00283
00284       bool      isFastMode        () const;
00285       bool      isUnipolarMode    () const;
00286       bool      isEnabledInterrupt() const;
00287
00288       int       bufferCapacity    () const;
00289       int       jmp3BufferCapacity() const;
00290
00291       Real      voltperbit        () const;
00292       Volt      voltageSpan       () const;
00293       Volt      offsetVoltage     () const;
00294       Volt      minInputVoltage   () const;
00295       Volt      maxInputVoltage   () const;
00296
00300
00301       void      setFastMode       ();
00302       void      setNormalMode     ();
00303
00304       void      setBipolarMode    ();
00305       void      setUnipolarMode   ();
00306
00307       bool      enableInterrupt   ( bool enable = true   );
00308
00309       void      setBufferCapacity ( int nelem = CON_JMP3 );
00310
00312
00313    protected:                                   // protected methods
00316
00317       RB8905_Adc12();
00318       RB8905_Adc12( RB8905_Adc12Cref rhs );
00319       RB8905_Adc12Ref operator= ( RB8905_Adc12Cref rhs );
00320
00324
00325       void      setReadMode   ();
00326       void      setWriteMode  ();
00327
00331
00332       void      clearAddress  ();
00333
00334       int       elemSize      () const;
00335       int       bufferSize    () const;
00336       void      setBufferSize ( int aSize = CON_JMP3 );
00337       void      setBufferCode ( int aCode );
00338
00339       int       jmp3BufferSize() const;
00340       int       detectJmp3BufferSize();
00341
00342       void      checkRead     ( int nelem );
00343       void      waitRelais    ();
00344
00346
00347    public:                                      // public data
00350
00351       static const Addr  DEF_ADDR      = 0xBC;
00352       static const float DEF_VPB /* = 10.0/4095.0 */;   // volt per bit (10.0 V full scale)
00353       static const int   DEF_SAMPLES   = 256;
00354
00358
00359       static const int   CON_JMP3      = 0;
00360       static const int   CON_TRELAIS   = 20;
00361
00363
00364    private:                                     // private data
00367
00368       Byte  theControlRegister;
00369       Real  theVoltPerBit;
00370       int   theJmp3BufferSize;
00371       int   theBufferCapacity;
00372
00376
00377       static const int OFF_CTL   = 0;
00378       static const int OFF_ADC   = 0;
00379       static const int OFF_STS   = 1;
00380       static const int ADR_WIDTH = OFF_STS + 1;
00381
00385
00386       static const Value LIM_MINVAL8   = 0x000;
00387       static const Value LIM_MAXVAL8   = 0x0FF;
00388
00389       static const Value LIM_MINVAL12  = 0x000;
00390       static const Value LIM_MAXVAL12  = 0xFFF;
00391
00392       static const int LIM_MINJMP3SIZE = 2;
00393       static const int LIM_MAXJMP3SIZE = 256;
00394
00395       static const int LIM_MINBUFSIZE  = 512;
00396       static const int LIM_MAXBUFSIZE  = 32768;
00397
00401
00402       static const int MSK_CTLBSIZE = 0x07;
00403       static const int MSK_CTLREAD  = 0x08;
00404       static const int MSK_CTLFAST  = 0x10;
00405       static const int MSK_CTLCLEAR = 0x20;
00406       static const int MSK_CTLINTR  = 0x40;
00407       static const int MSK_CTLUNIP  = 0x80;
00408
00409       static const int MSK_STSREADY = 0x80;
00410
00411       static const int MSK_ADCALL12 = 0x0FFF;
00412       static const int MSK_ADCALL8  = 0x00FF;
00413       static const int MSK_ADCMSB12 = 0x0800;
00414       static const int MSK_ADCMSB8  = 0x0080;
00415
00417    };
00418
00422
00427    inline bool RB8905_Adc12::isReady() const
00428    {
00429       return 0 != ( getByte( OFF_STS ) & MSK_STSREADY );
00430    }
00431
00436    inline bool RB8905_Adc12::isFastMode() const
00437    {
00438       return 0 != ( theControlRegister & MSK_CTLFAST );
00439    }
00440
00445    inline bool RB8905_Adc12::isUnipolarMode() const
00446    {
00447       return 0 != ( theControlRegister & MSK_CTLUNIP );
00448    }
00449
00454    inline bool RB8905_Adc12::isEnabledInterrupt() const
00455    {
00456       return 0 != ( theControlRegister & MSK_CTLINTR );
00457    }
00458
00463    inline Real RB8905_Adc12::voltperbit() const
00464    {
00465       return theVoltPerBit;
00466    }
00467
00472    inline int RB8905_Adc12::bufferCapacity() const
00473    {
00474       return theBufferCapacity;
00475    }
00476
00481    inline int RB8905_Adc12::jmp3BufferCapacity() const
00482    {
00483       return jmp3BufferSize() / elemSize();
00484    }
00485
00490    inline int RB8905_Adc12::jmp3BufferSize() const
00491    {
00492       return theJmp3BufferSize;
00493    }
00494
00499    inline int RB8905_Adc12::elemSize() const
00500    {
00501       return isFastMode() ? 1 : 2;
00502    }
00503
00508    inline void RB8905_Adc12::setFastMode()
00509    {
00510       putByte( OFF_CTL, theControlRegister |=  MSK_CTLFAST );
00511    }
00512
00517    inline void RB8905_Adc12::setNormalMode()
00518    {
00519       putByte( OFF_CTL, theControlRegister &= ~MSK_CTLFAST );
00520    }
00521
00526    inline void RB8905_Adc12::setBipolarMode()
00527    {
00528       putByte( OFF_CTL, theControlRegister &= ~MSK_CTLUNIP );
00529       waitRelais();
00530    }
00531
00536    inline void RB8905_Adc12::setUnipolarMode()
00537    {
00538       putByte( OFF_CTL, theControlRegister |= MSK_CTLUNIP );
00539       waitRelais();
00540    }
00541
00547    inline void RB8905_Adc12::setBufferCapacity( int nelem /* = CON_JMP3 */ )
00548    {
00549       theBufferCapacity = nelem;
00550    }
00551
00556    inline RB8905_Adc12Ref to_rb8905( RulbusDevicePtr p )
00557    {
00558       return PROXY_CAST<RB8905_Adc12Ref>( *p );
00559    }
00560
00565    inline RB8905_Adc12Ptr to_rb8905_ptr( RulbusDevicePtr p )
00566    {
00567       return PROXY_CAST<RB8905_Adc12Ptr>( p );
00568    }
00569
00570 } // namespace Rulbus
00571
00572 #endif  // __RB8905_ADC12_H
00573
00574 /*
00575  * end of file
00576  */
00577
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb9005_amplifier.h Source File

rb9005_amplifier.h

00001 /*
00002  * rb9005_amplifier.h - instrumentation amplfier (RB9005).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb9005_amplifier.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB9005_AMPLIFIER_H
00026 #define __RB9005_AMPLIFIER_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"       // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB9005_amplifier );  //
00035
00036    /* *
00037     * \example name.cpp
00038     * This is an example that shows ... .
00039     */
00040
00266    class RB9005_amplifier : public RulbusDevice
00267    {
00268    public:                              // public methods
00269       typedef Int  Value;
00270
00273
00274       RB9005_amplifier( NameCref name, Addr addr = DEF_ADDR, Rack rack = DEF_RACK );
00275
00276       ~RB9005_amplifier();
00277
00281
00282       int  channel              ( ) const;
00283       int  gain                 ( int aChannel ) const;
00284       Freq lowPassFrequency     ( int aChannel ) const;
00285
00286       bool isChannelSequenceMode( ) const;
00287       bool isClockSequenceMode  ( ) const;
00288
00292
00293       void setChannel           ( int aChannel );
00294       void setGain              ( int aChannel, int aGain );
00295       void setLowPassFrequency  ( int aChannel, Freq aFrequency );
00296
00297       void enableChannelSequenceMode( bool enable = true );
00298       void enableClockSequenceMode  ( bool enable = true );
00299
00301
00302    protected:                                   // protected methods
00305
00306       RB9005_amplifier();
00307       RB9005_amplifier( RB9005_amplifierCref rhs );
00308       RB9005_amplifierRef operator= ( RB9005_amplifierCref rhs );
00309
00313
00314       void checkChannel( int aChannel ) const;
00315
00316       int  gain12      ( int aChannel ) const;
00317       int  gain34      ( int aChannel ) const;
00318
00319       Freq lpf12       ( int aChannel ) const;
00320       Freq lpf34       ( int aChannel ) const;
00321
00322       void setGain12   ( int aChannel, int aGain );
00323       void setGain34   ( int aChannel, int aGain );
00324
00325       void setLpf12    ( int aChannel, Freq aFrequency );
00326       void setLpf34    ( int aChannel, Freq aFrequency );
00327
00329
00330    public:                                      // public data
00333
00334       static const Addr  DEF_ADDR = 0xB3;
00335
00339
00340       static const Value LIM_MINCHN = 1;
00341       static const Value LIM_MAXCHN = 4;
00342
00344
00345    private:                                     // private data
00348
00349       Byte theGain12Register;
00350       Byte theGain34Register;
00351       Byte theFreq1Register;
00352       Byte theFreq2Register;
00353       Byte theMuxRegister;
00354
00358
00359       static const int OFF_GAIN12 = 0;
00360       static const int OFF_MUX    = 1;
00361       static const int OFF_GAIN34 = 2;
00362       static const int OFF_FREQ1  = 3;
00363       static const int OFF_FREQ2  = 4;
00364       static const int ADR_WIDTH  = OFF_FREQ2 + 1;
00365
00369
00372
00373       static const int MSK_GAIN1  = 0x0F;
00374       static const int MSK_GAIN2  = 0xF0;
00375
00376       static const int SHL_GAIN1  = 0;
00377       static const int SHL_GAIN2  = 4;
00378
00382
00383       static const int MSK_GAIN3  = 0x03;
00384       static const int MSK_GAIN4  = 0x0C;
00385
00386       static const int SHL_GAIN3  = 0;
00387       static const int SHL_GAIN4  = 2;
00388
00392
00393       static const int MSK_LPF12  = 0x0F;
00394       static const int SHL_LPF12  = 0;
00395
00399
00400       static const int MSK_CHN1   = 0x07;
00401       static const int MSK_CHN2   = 0x38;
00402       static const int MSK_CHNSEQ = 0x40;
00403       static const int MSK_CLKSEQ = 0x80;
00404
00405       static const int SHL_CHN1   = 0;
00406       static const int SHL_CHN2   = 3;
00407
00409
00413
00414       struct RegInfo
00415       {
00416          int mask; int shift;
00417       };
00418
00419       static const RegInfo GainInfoTable[];
00420
00421       static const int     gain12Table[];
00422       static const int     gain34Table[];
00423       static const Freq    freq12Table[];
00424
00425    };
00426
00428
00433    inline RB9005_amplifierRef to_rb9005( RulbusDevicePtr p )
00434    {
00435       return PROXY_CAST<RB9005_amplifierRef>( *p );
00436    }
00437
00442    inline RB9005_amplifierPtr to_rb9005_ptr( RulbusDevicePtr p )
00443    {
00444       return PROXY_CAST<RB9005_amplifierPtr>( p );
00445    }
00446
00447
00448 } // namespace Rulbus
00449
00450 #endif  // __RB9005_AMPLIFIER_H
00451
00452 /*
00453  * end of file
00454  */
00455
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: rb9603_monochromator.h Source File

rb9603_monochromator.h

00001 /*
00002  * rb9603_monochromator.h -   (RB9603).
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: rb9603_monochromator.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RB9603_MONOCHROMATOR_H
00026 #define __RB9603_MONOCHROMATOR_H
00027
00028 #ifndef __RULBUSDEVICE_H
00029 #include "RulbusDevice.h"       // for class RulbusDevice
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RB9603_monochromator );  //
00035
00036    /* *
00037     * \example name.cpp
00038     * This is an example that shows ... .
00039     */
00040
00260    class RB9603_monochromator : public RulbusDevice
00261    {
00262    public:                              // public methods
00263       typedef Int Value;
00264
00267
00268       RB9603_monochromator(
00269          NameCref aName,
00270          Addr     aAddr = DEF_ADDR,
00271          Rack     aRack = DEF_RACK
00272       );
00273
00274       ~RB9603_monochromator();
00275
00279
00280       bool  isReady() const;
00281       void  wait   () const;
00282
00286
00287       Length adcWavelength() const;
00288       Length adcMeanWavelength() const;
00289       Length currentWavelength() const;
00290       Length targetWavelength() const;
00291
00292       Length minWavelength() const;
00293       Length maxWavelength() const;
00294
00298
00299       void  calibrate( bool and_wait = true ) const;
00300
00301       void  setWavelength( Length aWavelength, bool and_wait = true ) const;
00302
00304
00305    protected:                                   // protected methods
00308
00309       RB9603_monochromator();
00310       RB9603_monochromator( RB9603_monochromatorCref rhs );
00311       RB9603_monochromatorRef operator= ( RB9603_monochromatorCref rhs );
00312
00316
00317       void checkWavelength( Length aWavelength ) const;
00318
00322
00323       Value  read ( CharCptr aName, CharCptr aCmd ) const;
00324       void   write( CharCptr aName, CharCptr aCmd, Value aPos = -1 ) const;
00325
00326       String getString   (                    ) const;
00327       void   putString   ( StringCref aString ) const;
00328
00329       char   getCharacter(         ) const;
00330       void   putCharacter( char ch ) const;
00331
00333
00338       enum ComCodes
00339       {
00340          COM_RDY = 0,
00341          COM_GET = 1,
00342          COM_EOT = 2,
00343          COM_LEN = 15,
00344          COM_CNT = 500,
00345          COM_SLPMS = 1,
00346       };
00347
00348    public:                                      // public data
00351
00352       static const Addr DEF_ADDR = 0xCE;
00353
00355
00356    private:                                     // private data
00359
00360       mutable Length theMinWL;
00361       mutable Length theMaxWL;
00362
00366
00367       static const int   OFF_CMD = 0;
00368       static const int   OFF_STS = 0;
00369       static const int ADR_WIDTH = OFF_STS + 1;
00370
00374
00375       static const Length CON_MPS;
00376
00378
00379    };
00380
00382
00387    inline RB9603_monochromatorRef to_rb9603( RulbusDevicePtr p )
00388    {
00389       return PROXY_CAST<RB9603_monochromatorRef>( *p );
00390    }
00391
00396    inline RB9603_monochromatorPtr to_rb9603_ptr( RulbusDevicePtr p )
00397    {
00398       return PROXY_CAST<RB9603_monochromatorPtr>( p );
00399    }
00400
00401 } // namespace Rulbus
00402
00403 #endif  // __RB9603_MONOCHROMATOR_H
00404
00405 /*
00406  * end of file
00407  */
00408
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusDevice.h Source File

RulbusDevice.h

00001 /*
00002  * RulbusDevice.h - class RulbusDevice.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: RulbusDevice.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RULBUSDEVICE_H
00026 #define __RULBUSDEVICE_H
00027
00028 #ifndef __COMMON_H
00029    #include "Common.h"
00030 #endif
00031
00032 #include <iosfwd>               // for std::ostream
00033
00034 namespace Rulbus
00035 {
00036    DECLARE_CLASS( RulbusDevice );
00037    DECLARE_CLASS( TheRulbusInterface );
00038
00039    /* - <em>provide %Rulbus Interface creation</em> -- the class provides
00040     * methods createInterface() and destroyInterface() to create and destroy
00041     * the proper %Rulbus Interface; to this end it uses the
00042     * RulbusInterfaceFactory Singleton(127)
00043     */
00044
00067    class RulbusDevice
00068    {
00069    public:                                         // P U B L I C
00072
00073       RulbusDevice( Name aName, Addr aAddr, Addr aWidth, Rack aRack );
00074 //      RulbusDevice( Name aName = "(empty)", Addr aAddr = 0xFF, Addr aWidth = 0, Rack aRack = 0 );
00075
00076       virtual ~RulbusDevice();
00077
00081
00082       Name          name () const;
00083       Rack          rack () const;
00084       Addr          addr () const;
00085       Addr          width() const;
00086
00090
00091       bool          eqRack( RulbusDeviceCref rhs ) const;
00092       bool          eqAddr( RulbusDeviceCref rhs ) const;
00093
00097
00098       void          setRack( Rack aRack );
00099       void          setAddr( Addr aAddr );
00100
00104
00105       virtual int   printOn( std::ostream& stream ) const;
00106
00110
00111       int           getByte( int offset           ) const;
00112       int           putByte( int offset, int byte ) const;
00113
00115
00116 /*
00117       static  void  createInterface();
00118       static  void  destroyInterface();
00119       static  int   printInterface();
00120 */
00121
00122    protected:                                           // P R O T E C T E D
00125
00126       RulbusDevice( );
00127       RulbusDevice( RulbusDeviceCref );
00128       RulbusDeviceRef operator= ( RulbusDeviceCref );
00129
00133
00134       void   checkValidAddress( int offset = 0       ) const;
00135       void   checkBusViolation( int offset, int byte ) const;
00136
00140
00141       static TheRulbusInterfaceRef theRulbus();
00142
00144
00145    public:
00146       static const int ANY_RACK = 0xF;
00147       static const int DEF_RACK = ANY_RACK;
00148
00149
00150    private:                                     // P R I V A T E
00151       Name   theName;
00152       Rack   theRack;
00153       Addr   theAddr;
00154       Addr   theWidth;
00155
00156 //      static RulbusInterfaceCptr theInterface;  ///< the %Rulbus Interface implementation
00157    };
00158
00163    inline Name RulbusDevice::name() const
00164    {
00165       return theName;
00166    }
00167
00172    inline Rack RulbusDevice::rack() const
00173    {
00174       return theRack;
00175    }
00176
00181    inline Addr RulbusDevice::addr() const
00182    {
00183       return theAddr;
00184    }
00185
00190    inline Addr RulbusDevice::width() const
00191    {
00192       return theWidth;
00193    }
00194
00199    inline bool RulbusDevice::eqRack( RulbusDeviceCref rhs ) const
00200    {
00201       return rack() == ANY_RACK || rhs.rack() == ANY_RACK || rack() == rhs.rack();
00202    }
00203
00208    inline bool RulbusDevice::eqAddr( RulbusDeviceCref rhs ) const
00209    {
00210       return         eqRack( rhs )
00211       && (         addr() == rhs.addr()
00212           || (     addr() <  rhs.addr() &&     addr() +     width() > rhs.addr() )
00213           || ( rhs.addr() <      addr() && rhs.addr() + rhs.width() >     addr() ) );
00214    }
00215
00220    inline RulbusDeviceRef to_rb( RulbusDevicePtr p )
00221    {
00222       return PROXY_CAST<RulbusDeviceRef>( *p );
00223    }
00224
00229    inline RulbusDevicePtr to_rb_ptr( RulbusDevicePtr p )
00230    {
00231       return PROXY_CAST<RulbusDevicePtr>( p );
00232    }
00233
00234 }       // namespace Rulbus
00235
00236 /*------------------------------------------------------------------------
00237  * convenience functions
00238  *------------------------------------------------------------------------
00239  */
00240
00241 inline std::ostream& operator<< ( std::ostream& stream, const Rulbus::RulbusDevice& aDevice )
00242 {
00243    aDevice.printOn( stream );
00244    return stream;
00245 }
00246
00247 inline std::ostream& operator<< ( std::ostream& stream, Rulbus::RulbusDeviceCptr aDevicePtr )
00248 {
00249    aDevicePtr->printOn( stream );
00250    return stream;
00251 }
00252
00253 #endif  // __RULBUSDEVICE_H
00254
00255 /*
00256  * end of file
00257  */
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusDeviceFactory.h Source File

RulbusDeviceFactory.h

00001 /*
00002  * RulbusDeviceFactory.h - class RulbusDeviceFactory.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: RulbusDeviceFactory.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RULBUSDEVICEFACTORY_H
00026 #define __RULBUSDEVICEFACTORY_H
00027
00028 #ifndef __COMMON_H
00029 #include "Common.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( RulbusDeviceFactory );
00035
00067    class RulbusDeviceFactory
00068    {
00069    public:                                              // public methods
00070       static void createDevices( String rulbus_config_file = "" );
00071       static void destroyDevices( );
00072
00073    protected:                                           // protected methods
00074       RulbusDeviceFactory();
00075       RulbusDeviceFactory( RulbusDeviceFactoryCref );
00076
00077    private:                                             // private data
00078 //      static CharCptr msgtitle;
00079    };
00080
00081 } // namespace Rulbus
00082
00083 #endif  // __RULBUSDEVICEFACTORY_H
00084
00085 /*
00086  * end of file
00087  */
00088
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusDeviceList.h Source File

RulbusDeviceList.h

00001 /*
00002  * RulbusDeviceList.h - list to maintain device class -- handle relationship.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: RulbusDeviceList.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RULBUSDEVICELIST_H
00026 #define __RULBUSDEVICELIST_H
00027
00028 #ifndef __COMMON_H
00029    #include "Common.h"
00030 #endif
00031
00032 #include "Singleton.h"          // for template class Singleton
00033 #include "RulbusDeviceProxy.h"  // for class RulbusDeviceProxy
00034
00035 #include <vector>               // for std::vector<>
00036
00037 namespace WindowsUtils
00038 {
00039    DECLARE_CLASS( Semaphore );
00040 }
00041
00042 namespace Rulbus
00043 {
00044    DECLARE_CLASS( RulbusDevice        );
00045    DECLARE_CLASS( TheRulbusDeviceList );
00046
00047    typedef std::vector<RulbusDevicePtr> List;
00048
00073    class TheRulbusDeviceList : public Singleton<TheRulbusDeviceList>
00074    {
00075       friend class Singleton<TheRulbusDeviceList>;
00076
00077    public:                                      // public methods
00078       void             clear( );
00079       void               add( RulbusDevicePtr deviceptr );
00080       void            remove( RulbusDevicePtr deviceptr );
00081       void            remove( int handle );
00082
00083       int               open( Name aName );
00084       void             close( int handle );
00085       RulbusDeviceProxy  get( int handle );
00086
00087       void             check( );
00088       bool           printOn( std::ostream& stream );
00089
00090    protected:                                   // protected methods
00091       TheRulbusDeviceList();
00092       ~TheRulbusDeviceList();
00093       TheRulbusDeviceList( TheRulbusDeviceListCref rhs );
00094       TheRulbusDeviceList operator= ( TheRulbusDeviceListCref rhs );
00095
00096    private:                                     // private data
00097       List theList;
00098       WindowsUtils::SemaphorePtr s;
00099    };
00100
00101 } // namespace Rulbus
00102
00103 #endif  // __RULBUSDEVICELIST_H
00104
00105 /*
00106  * end of file
00107  */
00108
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusDeviceProxy.h Source File

RulbusDeviceProxy.h

00001 /*
00002  * RulbusDeviceProxy.h - class RulbusDeviceProxy.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: RulbusDeviceProxy.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RULBUSDEVICEPROXY_H
00026 #define __RULBUSDEVICEPROXY_H
00027
00028 #ifndef __COMMON_H
00029    #include "Common.h"
00030 #endif
00031
00032 #include "winutils/semaphore.h" // for WindowsUtils::Semaphore
00033 #include <windows.h>            // for InterlockedIncrement()
00034
00035 namespace WindowsUtils
00036 {
00037    DECLARE_CLASS( Semaphore );
00038 }
00039
00040 namespace Rulbus
00041 {
00042    DECLARE_CLASS( RulbusDevice      );
00043    DECLARE_CLASS( RulbusDeviceProxy );
00044
00068    class RulbusDeviceProxy
00069    {
00070    public:
00071       RulbusDeviceProxy  ( RulbusDevicePtr aPtr     );
00072       RulbusDeviceProxy  ( RulbusDeviceProxyRef rhs );
00073       ~RulbusDeviceProxy ( );
00074
00075       RulbusDeviceProxyRef operator= ( RulbusDeviceProxyRef rhs );
00076
00077                            operator RulbusDevicePtr ( );
00078                            operator RulbusDeviceRef ( );
00079
00080       RulbusDevicePtr      operator->( );
00081       RulbusDeviceRef      operator* ( );
00082
00083       RulbusDeviceRef      get( );
00084
00085    protected:
00086       RulbusDevicePtr      transfer();
00087
00088    protected:
00089       RulbusDevicePtr      thePtr;
00090       static WindowsUtils::Semaphore s;
00091    };
00092
00097    inline RulbusDeviceProxy::RulbusDeviceProxy( RulbusDevicePtr aPtr ) :
00098       thePtr( aPtr )
00099    {
00100       s.wait();
00101    }
00102
00107    inline RulbusDeviceProxy::RulbusDeviceProxy( RulbusDeviceProxyRef rhs ) :
00108       thePtr( rhs.transfer() )
00109    {
00110       ; // do nothing
00111    }
00112
00117    inline RulbusDeviceProxy::~RulbusDeviceProxy( )
00118    {
00119       if ( thePtr )
00120       {
00121          s.post();                              // critical section end
00122          thePtr = 0;
00123       }
00124       else
00125       {
00126          ; // do nothing
00127       }
00128    }
00129
00134    RulbusDeviceProxyRef RulbusDeviceProxy::operator=( RulbusDeviceProxyRef rhs )
00135    {
00136       thePtr = rhs.transfer();
00137
00138       return *this;
00139    }
00140
00145    inline RulbusDeviceProxy::operator RulbusDevicePtr( )
00146    {
00147       return &get();
00148    }
00149
00154    inline RulbusDeviceProxy::operator RulbusDeviceRef( )
00155    {
00156       return get();
00157    }
00158
00163    inline RulbusDevicePtr RulbusDeviceProxy::operator->( )
00164    {
00165       return &get();
00166    }
00167
00172    inline RulbusDeviceRef RulbusDeviceProxy::operator*( )
00173    {
00174       return get();
00175    }
00176
00181    RulbusDeviceRef RulbusDeviceProxy::get()
00182    {
00183       return *thePtr;
00184    }
00185
00190    RulbusDevicePtr RulbusDeviceProxy::transfer()
00191    {
00192       RulbusDevicePtr tmpPtr = thePtr;
00193       thePtr                 = 0;
00194
00195       return tmpPtr;
00196    }
00197
00202    template <typename T>
00203    inline T to( RulbusDeviceProxyRef proxy )
00204    {
00205       return PROXY_CAST( T, static_cast<RulbusDevicePtr>( proxy ) );
00206    }
00207
00208 }       // namespace Rulbus
00209
00210 #endif  // __RULBUSDEVICEPROXY_H
00211
00212 /*
00213  * end of file
00214  */
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusInterface.h Source File

RulbusInterface.h

00001 /*
00002  * RulbusInterface.h - abstract class RulbusInterface.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: RulbusInterface.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RULBUSINTERFACE_H
00026 #define __RULBUSINTERFACE_H
00027
00028 #ifndef __COMMON_H
00029 #include "Common.h"
00030 #endif
00031
00032 #include "Singleton.h"
00033 #include "RulbusInterfaceFactory.h"
00034
00035 namespace WindowsUtils
00036 {
00037    DECLARE_CLASS( Semaphore );
00038 }
00039
00040 namespace Rulbus
00041 {
00042    DECLARE_CLASS( TheRulbusInterface );
00043
00072    class TheRulbusInterface : public Singleton<TheRulbusInterface>
00073    {
00074       friend class Singleton<TheRulbusInterface>;
00075
00076    public:                                                      // P U B L I C
00079
00080      static TheRulbusInterfaceRef instance();
00081
00085
00086       int          getByte( int rack, int offset           ) const;
00087       int          putByte( int rack, int offset, int byte ) const;
00088
00092
00093       virtual bool invariant() const;
00094
00098
00099       virtual bool printOn  ( std::ostream& stream ) const = 0;
00100
00102
00103    protected:                                                   // P R O T E C T E D
00106
00107       TheRulbusInterface();
00108      ~TheRulbusInterface();
00109
00112
00113       virtual int  getReg (int offset          ) const = 0;
00114       virtual int  putReg (int offset, int byte) const = 0;
00115
00117
00118    private:                                                     // P R I V A T E
00119       WindowsUtils::SemaphorePtr s;
00120
00121    public:
00122       static const int ANY_RACK = 0xF;
00123    };
00124
00129    inline TheRulbusInterfaceRef TheRulbusInterface::instance()
00130    {
00131       if ( 0 == theInstance )
00132       {
00133          theInstance = RulbusInterfaceFactory::createInterface();
00134       }
00135
00136       return *theInstance;
00137    }
00138
00143    inline bool TheRulbusInterface::invariant() const
00144    {
00145       return true;
00146    }
00147
00148 }       // namespace Rulbus
00149
00150 #endif  // __RULBUSINTERFACE_H
00151
00152 /*
00153  * end of file
00154  */
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: RulbusInterfaceFactory.h Source File

RulbusInterfaceFactory.h

00001 /*
00002  * RulbusInterfaceFactory.h - class RulbusInterfaceFactory.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: RulbusInterfaceFactory.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __RULBUSINTERFACEFACTORY_H
00026 #define __RULBUSINTERFACEFACTORY_H
00027
00028 #ifndef __COMMON_H
00029 #include "Common.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00034    DECLARE_CLASS( TheRulbusInterface        );
00035    DECLARE_CLASS( RulbusInterfaceFactory );
00036
00088    class RulbusInterfaceFactory
00089    {
00090    public:                                         // P U B L I C
00091       static TheRulbusInterfacePtr createInterface();
00092
00093    protected:                                      // P R O T E C T E D
00094       RulbusInterfaceFactory();
00095       RulbusInterfaceFactory( RulbusInterfaceFactoryCref );
00096
00097    private:                                        // P R I V A T E
00098 //      static CharCptr msgtitle;
00099    };
00100
00101 }       // namespace Rulbus
00102
00103 #endif  // __RULBUSINTERFACEFACTORY_H
00104
00105 /*
00106  * end of file
00107  */
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Shims.h Source File

Shims.h

00001 /*
00002  * shims.h - shims.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: Shims.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __SHIMS_H
00026 #define __SHIMS_H
00027
00028 #ifndef __COMMON_H
00029    #include "Common.h"
00030 #endif
00031
00032 namespace Rulbus
00033 {
00038 /*
00039    inline CharCptr to_cstr( const String& s )
00040    {
00041       return s.c_str();
00042    }
00043 */
00044
00049    String to_string( Real x, Int ndec = 7 );
00050
00055    String to_string_pfx( Int n, Int radix = 10, Int width = 0 );
00056
00061    String to_string( long n, Int radix = 10, Int width = 0, Char fillchar = ' ' );
00062
00067    inline String to_string( int n, Int radix = 10, Int width = 0, Char fillchar = ' ' )
00068    {
00069       return to_string( static_cast<long>( n ), radix, width, fillchar );
00070    }
00071
00076    inline String to_string2( Int n )
00077    {
00078       return to_string( n, 2 );
00079    }
00080
00085    inline String to_string8( Int n )
00086    {
00087       return to_string( n, 8 );
00088    }
00089
00094    inline String to_string16( Int n )
00095    {
00096       return to_string( n, 16 );
00097    }
00098
00103    Real to_real( String aString );
00104
00109    Int to_int( String aString );
00110
00115    Int to_bcd( Int aBinaryValue );
00116
00117 }       // namespace Rulbus
00118
00119 #endif  //  __SHIMS_H
00120
00121 /*
00122  * end of file
00123  */
00124
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Singleton.h Source File

Singleton.h

00001 /*
00002  * Singleton - template base class for singleton pattern.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: Singleton.h 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __SINGLETON_H
00026 #define __SINGLETON_H
00027
00028 namespace Rulbus
00029 {
00063    template <typename T>
00064    class Singleton
00065    {
00066    public:
00067       static T& instance();
00068
00069    protected:
00070       static T* theInstance;
00071
00072    };
00073
00078    template <typename T>
00079    T* Singleton<T>::theInstance = 0;
00080
00085    template <typename T>
00086    T& Singleton<T>::instance()
00087    {
00088       if ( 0 == theInstance )
00089       {
00090          theInstance = new T;
00091       }
00092
00093       return *theInstance;
00094    }
00095
00096 } // namespace Rulbus
00097
00098 #endif  // __SINGLETON_H
00099
00100 /*
00101  * end of file
00102  */
00103
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

ConfigKeyword Member List

This is the complete list of members for ConfigKeyword, including all inherited members.
c | ConfigKeyword
s | ConfigKeyword
Generated on Tue Oct 12 14:12:03 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

isEqual Member List

This is the complete list of members for isEqual, including all inherited members.
isEqual(aType a) | isEqual | [inline]
m_a | isEqual |
operator()(aType b) | isEqual | [inline]
Generated on Tue Oct 12 14:12:04 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB8515_clock::FreqTable Member List

This is the complete list of members for RB8515_clock::FreqTable, including all inherited members.
code | RB8515_clock::FreqTable
freq | RB8515_clock::FreqTable
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: Member List

RB9005_amplifier::RegInfo Member List

This is the complete list of members for RB9005_amplifier::RegInfo, including all inherited members.
mask (defined in RB9005_amplifier::RegInfo) | RB9005_amplifier::RegInfo
shift (defined in RB9005_amplifier::RegInfo) | RB9005_amplifier::RegInfo
Generated on Tue Oct 12 14:12:05 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4


Rulbus Device Class Library for Microsoft Windows: version.h Source File

version.h

00001 /*
00002  * version.h.in - version string for Rulbus Device Class Library.
00003  *
00004  * This file is part of the Rulbus Device Class Library (RDCL).
00005  *
00006  * Copyright (C) 2003-2004, Leiden University.
00007  *
00008  * This library is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version.
00012  *
00013  * The library is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License
00019  * along with mngdriver; if not, write to the Free Software
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * $Id: version.h.in 2 2004-10-12 11:54:15Z moene $
00023  */
00024
00025 #ifndef __VERSION_H
00026 #include "../../version.h"
00027 //#define __VERSION_H
00028
00029 #undef  VERSION_STRING
00030 #undef  VERSION_FILE
00031
00032 #define VERSION_STRING "0.2.0 (stable)"
00033 #define VERSION_FILE    0,2,0-20041012,0
00034
00035 #if defined(CANIO)                      // CANIO port I/O
00036    #define   VERSION_PORTIO "CanIO"
00037 #elif defined(DriverLINX)               // DriverLINXport I/O
00038    #define   VERSION_PORTIO "DriverLinx"
00039 #else
00040    #define   VERSION_PORTIO "(Unrecognized Port I/O support)"
00041    #error Please specify Port IO selection: CANIO or DriverLINX .
00042 #endif
00043
00044 #endif
00045
00046 /*
00047  * end of file
00048  */
00049
Generated on Tue Oct 12 14:11:58 2004 for Rulbus Device Class Library for Microsoft Windows by doxygen 1.3.4