Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

L1394::AvcRegister Class Reference
[L1394_Register]

This class implements the DeviceRegister interface for devices based on the AV/C specification. More...

#include <l1394_avcregister.h>

Inheritance diagram for L1394::AvcRegister:

L1394::DeviceRegister L1394::AvcCameraRegister List of all members.

Public Member Functions

AvcRegister constructor
These functions implement the Register objects for AV/C devices.

 AvcRegister (const FcpNode *parent_node, const int subunit_value)
 This method creates a Register object for AV/C devices.
virtual ~AvcRegister ()
 destructor
Register interface for A/VC devices
These functiosn implement the minimal DeviceRegister interface for A/VC devices

int send () const
 This method sends the command and returns the response code.
bool hasFeature () const
 This method tests, if a command is supported by a node.
bool hasFeature (const int command) const
 This method tests, if a submethod of a command is supported by the device.
QArray status () const
 This method returns the status of subfunction(0xFF normally for the feature itself).
Some internal methods
These methods help to implement the interface.

AvcRegistersetCtype (const int ctype)
 This method sets the command type.
AvcRegistersetSubfunction (const int subfunction)
 This method sets the subfunction.
AvcRegistersetOpcode (const int opcode)
 This method sets the opcode.
AvcRegisterdefaultSet (const int length, const int opcode, const int value)
 This method sets default value for the array. FOR INTERNAL USE ONLY!!
QArraygetData ()
 return the data_array. FOR INTERNAL USE ONLY!!!

Protected Member Functions

AvcRegisterreset (const int size)
 This method resets the data_arry.

Protected Attributes

const FcpNodeparent_node
 pointer to the parent node
QArraydata_array
 the data_array
int opcode
 actual op_code
int subunit_value
 actual subunit_value
int ctype
 actual command type
int subfunction
 actual subfunction
bool restore
 variable to test if the data_array was reset.

Detailed Description

This class implements the DeviceRegister interface for devices based on the AV/C specification.

Author:
Michael Repplinger

Definition at line 36 of file l1394_avcregister.h.


Constructor & Destructor Documentation

L1394::AvcRegister::AvcRegister const FcpNode parent_node,
const int  subunit_value
 

This method creates a Register object for AV/C devices.

Parameters:
FcpNode* : pointer to the parent node.
subunit_value : The subunit value defines the subunit-type and the subunit-id of the device.

Definition at line 22 of file l1394_avcregister.cpp.

References ctype, data_array, opcode, and subfunction.

L1394::AvcRegister::~AvcRegister  )  [virtual]
 

destructor

Definition at line 32 of file l1394_avcregister.cpp.


Member Function Documentation

L1394::AvcRegister::defaultSet const int  length,
const int  opcode,
const int  value
 

This method sets default value for the array. FOR INTERNAL USE ONLY!!

Definition at line 78 of file l1394_avcregister.cpp.

References data_array, reset(), and L1394::QArray::setByte().

Referenced by L1394::AvcVcr::analogAudioOutputMode(), L1394::AvcCamera::autoExposure(), L1394::AvcVcr::backward(), L1394::AvcCamera::brightness(), L1394::AvcVcr::editMode(), L1394::AvcCamera::focus(), L1394::AvcVcr::forward(), L1394::AvcCamera::gain(), L1394::AvcCamera::gamma(), L1394::AvcVcr::getTimeCode(), L1394::AvcCamera::hue(), L1394::AvcVcr::inputSignalMode(), L1394::AvcCamera::iris(), L1394::AvcVcr::loadMedium(), L1394::AvcVcr::marker(), L1394::AvcVcr::mediumInfo(), L1394::AvcVcr::openMic(), L1394::AvcVcr::outputSignalMode(), L1394::AvcVcr::play(), L1394::AvcVcr::preset(), L1394::AvcVcr::record(), L1394::AvcVcr::recordingDate(), L1394::AvcVcr::recordingSpeed(), L1394::AvcCamera::saturation(), L1394::AvcVcr::search(), L1394::AvcCamera::sharpness(), L1394::AvcVcr::timecode(), L1394::AvcCamera::whiteBalance(), L1394::AvcVcr::wind(), L1394::AvcVcr::writeMic(), and L1394::AvcCamera::zoom().

L1394::AvcRegister::getData  )  [inline]
 

return the data_array. FOR INTERNAL USE ONLY!!!

Definition at line 130 of file l1394_avcregister.h.

References data_array.

Referenced by L1394::AvcVcr::getTimeCode(), L1394::AvcVcr::marker(), L1394::AvcVcr::mediumInfo(), L1394::AvcVcr::recordingDate(), L1394::AvcVcr::search(), and L1394::AvcVcr::timecode().

L1394::AvcRegister::hasFeature const int  command  )  const
 

This method tests, if a submethod of a command is supported by the device.

Parameters:
command : value for the subcommand (see the specific AV/C subunit specification for more information)
Returns:
bool : return true, if node report an IMPLEMENTED for this feature, false if not.

Definition at line 55 of file l1394_avcregister.cpp.

References data_array, L1394::Quadlet::getByte(), IMPLEMENTED, opcode, parent_node, L1394::FcpNode::send(), L1394::QArray::setByte(), and SPECIFIC_INQUIRY.

L1394::AvcRegister::hasFeature  )  const [virtual]
 

This method tests, if a command is supported by a node.

For this method the general inquiry command is used.

Returns:
bool : returns true, if a node reports an IMPLEMENTED for this feature, false if not.

Implements L1394::DeviceRegister.

Reimplemented in L1394::AvcCameraRegister.

Definition at line 44 of file l1394_avcregister.cpp.

References data_array, L1394::Quadlet::getByte(), IMPLEMENTED, parent_node, L1394::FcpNode::send(), L1394::QArray::setByte(), and SPECIFIC_INQUIRY.

AvcRegister * L1394::AvcRegister::reset const int  size  )  [protected]
 

This method resets the data_arry.

Definition at line 87 of file l1394_avcregister.cpp.

References CONTROL, data_array, L1394::QArray::insert(), L1394::QArray::setByte(), and subunit_value.

Referenced by defaultSet().

L1394::AvcRegister::send  )  const [virtual]
 

This method sends the command and returns the response code.

After sending, the internal data Array will be restored and set to size 1.

Returns:
QArray : returns the response code.

Implements L1394::DeviceRegister.

Definition at line 38 of file l1394_avcregister.cpp.

References data_array, L1394::Quadlet::getByte(), L1394::Singleton< T, CreationPolicy, LifetimePolicy, ThreadingModel >::getInstance(), parent_node, and L1394::FcpNode::send().

L1394::AvcRegister::setCtype const int  ctype  )  [inline]
 

This method sets the command type.

Parameters:
ctype : new command-type.
Returns:
AvcRegister* : returns a pointer to this object.

Definition at line 106 of file l1394_avcregister.h.

References data_array, and L1394::QArray::setByte().

L1394::AvcRegister::setOpcode const int  opcode  )  [inline]
 

This method sets the opcode.

Parameters:
opcode : new operation code.
Returns:
AvcRegister* : returns a pointer to this object.

Definition at line 120 of file l1394_avcregister.h.

References data_array, and L1394::QArray::setByte().

L1394::AvcRegister::setSubfunction const int  subfunction  )  [inline]
 

This method sets the subfunction.

Parameters:
subfunction : new subfunction value.
Returns:
AvcRegister* : returns a pointer to this object.

Definition at line 113 of file l1394_avcregister.h.

References data_array, and L1394::QArray::setByte().

L1394::AvcRegister::status  )  const [virtual]
 

This method returns the status of subfunction(0xFF normally for the feature itself).

Returns:
QArray : QArray with the response code.

Implements L1394::DeviceRegister.

Definition at line 69 of file l1394_avcregister.cpp.

References data_array, parent_node, L1394::FcpNode::send(), L1394::QArray::setByte(), and STATUS.


Member Data Documentation

int L1394::AvcRegister::ctype [protected]
 

actual command type

Definition at line 150 of file l1394_avcregister.h.

Referenced by AvcRegister().

QArray* L1394::AvcRegister::data_array [protected]
 

the data_array

Definition at line 141 of file l1394_avcregister.h.

Referenced by AvcRegister(), defaultSet(), getData(), L1394::AvcCameraRegister::getValue(), hasFeature(), L1394::AvcCameraRegister::hasFeature(), L1394::AvcCameraRegister::onePush(), reset(), send(), setCtype(), setOpcode(), setSubfunction(), L1394::AvcCameraRegister::setValue(), and status().

int L1394::AvcRegister::opcode [protected]
 

actual op_code

Definition at line 144 of file l1394_avcregister.h.

Referenced by L1394::AvcCameraRegister::automatic(), AvcRegister(), and hasFeature().

const FcpNode* L1394::AvcRegister::parent_node [protected]
 

pointer to the parent node

Definition at line 138 of file l1394_avcregister.h.

Referenced by L1394::AvcCameraRegister::automatic(), L1394::AvcCameraRegister::getValue(), hasFeature(), L1394::AvcCameraRegister::hasFeature(), L1394::AvcCameraRegister::onePush(), send(), L1394::AvcCameraRegister::setValue(), and status().

bool L1394::AvcRegister::restore [protected]
 

variable to test if the data_array was reset.

Definition at line 155 of file l1394_avcregister.h.

int L1394::AvcRegister::subfunction [protected]
 

actual subfunction

Definition at line 153 of file l1394_avcregister.h.

Referenced by AvcRegister().

int L1394::AvcRegister::subunit_value [protected]
 

actual subunit_value

Definition at line 147 of file l1394_avcregister.h.

Referenced by L1394::AvcCameraRegister::automatic(), and reset().


The documentation for this class was generated from the following files:
Generated on Wed Aug 24 00:36:43 2005 for L1394 by doxygen 1.4.2
L1394 library (NMM) grahics.cs.uni-sb.de/~repplix/l1394_home/