mrfioc2  2.3.0
Public Member Functions | List of all members
evgOutput Class Reference

#include <evgOutput.h>

Inheritance diagram for evgOutput:
Inheritance graph
[legend]
Collaboration diagram for evgOutput:
Collaboration graph
[legend]

Public Member Functions

 evgOutput (const std::string &, const epicsUInt32, const evgOutputType, volatile epicsUInt8 *const)
 
 ~evgOutput ()
 
virtual void lock () const
 
virtual void unlock () const
 
void setSource (epicsUInt16)
 
epicsUInt16 getSource () const
 
- Public Member Functions inherited from mrf::ObjectInst< evgOutput >
virtual propertyBasegetPropertyBase (const char *pname, const std::type_info &ptype)
 
virtual void visitProperties (bool(*cb)(propertyBase *, void *), void *arg)
 
- Public Member Functions inherited from mrf::Object
const std::string & name () const
 
const Objectparent () const
 
child_iterator beginChild () const
 
child_iterator endChild () const
 
template<typename P >
mrf::auto_ptr< property< P > > getProperty (const char *pname)
 

Additional Inherited Members

- Public Types inherited from mrf::Object
typedef m_obj_children_t::const_iterator child_iterator
 
typedef std::map< std::string, std::string > create_args_t
 
typedef Object *(* create_factory_t) (const std::string &name, const std::string &klass, const create_args_t &args)
 
- Static Public Member Functions inherited from mrf::ObjectInst< evgOutput >
static int initObject ()
 
- Static Public Member Functions inherited from mrf::Object
static ObjectgetObject (const std::string &name)
 
static ObjectgetCreateObject (const std::string &name, const std::string &klass, const create_args_t &args=create_args_t())
 
static void addFactory (const std::string &klass, create_factory_t fn)
 
static void visitObjects (bool(*)(Object *, void *), void *)
 
- Protected Member Functions inherited from mrf::ObjectInst< evgOutput >
 ObjectInst (const std::string &n)
 
 ObjectInst (const std::string &n, A &a)
 
virtual ~ObjectInst ()
 
- Protected Member Functions inherited from mrf::Object
 Object (const std::string &n, const Object *par=0)
 
virtual ~Object ()=0
 

Detailed Description

Definition at line 13 of file evgOutput.h.

Constructor & Destructor Documentation

◆ evgOutput()

evgOutput::evgOutput ( const std::string &  name,
const epicsUInt32  num,
const evgOutputType  type,
volatile epicsUInt8 * const  pOutReg 
)

Definition at line 12 of file evgOutput.cpp.

13  :
15 m_num(num),
16 m_type(type),
17 m_pOutReg(pOutReg) {
18  switch(m_type) {
19  case(FrontOut):
20  if(m_num >= evgNumFrontOut)
21  throw std::runtime_error("EVG Front panel output ID out of range");
22  break;
23 
24  case(UnivOut):
25  if(m_num >= evgNumUnivOut)
26  throw std::runtime_error("EVG Universal output ID out of range");
27  break;
28 
29  default:
30  throw std::runtime_error("Wrong EVG Output type");
31  }
32 }
#define evgNumUnivOut
Definition: evgRegMap.h:286
#define evgNumFrontOut
Definition: evgRegMap.h:285
const std::string & name() const
Definition: object.h:393

◆ ~evgOutput()

evgOutput::~evgOutput ( )

Definition at line 34 of file evgOutput.cpp.

34  {
35 }

Member Function Documentation

◆ getSource()

epicsUInt16 evgOutput::getSource ( ) const

Definition at line 43 of file evgOutput.cpp.

43  {
44  return nat_ioread16(m_pOutReg);
45 }
INLINE epicsUInt16 nat_ioread16(volatile void *addr)
Definition: mrfIoOpsDef.h:34

◆ lock()

virtual void evgOutput::lock ( ) const
inlinevirtual

Implements mrf::Object.

Definition at line 20 of file evgOutput.h.

20 {};

◆ setSource()

void evgOutput::setSource ( epicsUInt16  map)

Definition at line 38 of file evgOutput.cpp.

38  {
39  nat_iowrite16(m_pOutReg, map);
40 }
INLINE void nat_iowrite16(volatile void *addr, epicsUInt16 val)
Definition: mrfIoOpsDef.h:41

◆ unlock()

virtual void evgOutput::unlock ( ) const
inlinevirtual

Implements mrf::Object.

Definition at line 21 of file evgOutput.h.

21 {};

The documentation for this class was generated from the following files: