Bitstream Interpretation Library (BIL)
0.1
|
A register for executing commands. More...
#include <packetprocessor/V5CMDRegister.hpp>
Public Member Functions | |
V5CMDRegister (V5CRCRegister &crcReg) | |
Constructs a V5CMDRegister instance. | |
virtual void | write (const boost::uint32_t *words, size_t wordCount) |
When writing a word, it will be set as current command code and executed immediately (by calling commandCode() and execute()). | |
virtual void | read (boost::uint32_t *words, size_t wordCount) const |
When reading a word, the current command code will be returned. | |
void | commandCode (V5CommandCode::command_t code) |
Sets command code. | |
V5CommandCode::command_t | commandCode () const |
Gets current command code. | |
void | execute () const |
Executes current command code. | |
V5CRCRegister & | crcRegister () const |
Gets linked V5CRCRegister register instance. | |
Public Member Functions inherited from bil::Register | |
Register (RegisterAddress::address_t address, const std::string &name, bool writable=true, bool readable=true) | |
Constructs a Register instance. | |
virtual | ~Register ()=0 |
Destructs a Register instance. | |
RegisterAddress::address_t | address () const |
Gets register address. | |
const std::string & | name () const |
Gets register name. | |
bool | writable () const |
Tells if register is writable. | |
bool | readable () const |
Tells if register is readable. |
A register for executing commands.
The command register is an one word write- and readable register. Writes will set a command code and execute it. Reads will return the current command code.
Definition at line 26 of file V5CMDRegister.hpp.
|
explicit |
Constructs a V5CMDRegister instance.
crcReg | V5CRCRegister instance reference that should be linked to this register (e.g. for being controlled). |
Definition at line 14 of file V5CMDRegister.cpp.
|
virtual |
When writing a word, it will be set as current command code and executed immediately (by calling commandCode() and execute()).
words | Pointer to data words to write. |
wordCount | Number of data words to write. |
. |
Reimplemented from bil::Register.
Definition at line 23 of file V5CMDRegister.cpp.
|
virtual |
When reading a word, the current command code will be returned.
words | Pointer to data buffer. |
wordCount | Number of data words to read. |
. |
Reimplemented from bil::Register.
Definition at line 35 of file V5CMDRegister.cpp.
void V5CMDRegister::commandCode | ( | V5CommandCode::command_t | code | ) |
Sets command code.
code | The new command code. |
. |
Definition at line 46 of file V5CMDRegister.cpp.
V5CommandCode::command_t V5CMDRegister::commandCode | ( | ) | const |
Gets current command code.
Definition at line 72 of file V5CMDRegister.cpp.
void V5CMDRegister::execute | ( | ) | const |
Executes current command code.
Definition at line 78 of file V5CMDRegister.cpp.
V5CRCRegister & V5CMDRegister::crcRegister | ( | ) | const |
Gets linked V5CRCRegister register instance.
Definition at line 85 of file V5CMDRegister.cpp.