#include <SpartanPacket.hpp>


Public Member Functions | |
| SpartanPacket (void) | |
| Null constructor. | |
| SpartanPacket (uint32_t inHeader, uint32_t inCount, uint32_t inWord, uint32_t *inWords) | |
| Full constructor. | |
| SpartanPacket (uint32_t inHeader, uint32_t inWord) | |
| Header plus single word constructor. | |
| SpartanPacket (uint32_t inHeader) | |
| Header only constructor. | |
| SpartanPacket (const SpartanPacket &rhs) | |
| Copy constructor. | |
| void | write (std::ostream &inStream) const |
| Write a packet. | |
| uint32_t | operator[] (size_t inIndex) const |
| EPacketType | getType (void) const |
| EOpcode | getOpcode (void) const |
| int | getAddress (void) const |
| uint32_t | getHeader (void) const |
| uint32_t | getWordCount (void) const |
| Returns the number of payload words in the packet, excluding the header word. | |
| uint32_t | getWordSize (void) const |
| Returns the total number of words in the packet, including the header word. | |
| bool | isType1 (void) const |
| bool | isType2 (void) const |
| bool | isNop (void) const |
| bool | isReserved (void) const |
| bool | isRead (void) const |
| bool | isWrite (void) const |
| bool | isDummyWord (void) const |
| bool | isSyncWord (void) const |
| bool | isBusWidthSyncWord (void) const |
| bool | isBusWidthDetectWord (void) const |
Static Public Member Functions | |
| static SpartanPacket | read (std::istream &inStream) |
| Read a packet. | |
| static SpartanPacket | makeNullType1Write (uint32_t inAddress) |
| Construct a null type 1 write packet. | |
| static SpartanPacket | makeType1Write (uint32_t inAddress, uint32_t inWord) |
| Construct a type 1 write packet. | |
| static SpartanPacket | makeType2Write (uint32_t inCount, uint32_t *inWords) |
| Construct a type 2 write packet. | |
| static uint32_t | makeHeader (EPacketType inType, EOpcode inOpcode, uint32_t inAddress, uint32_t inCount) |
| Construct a packet header. | |
Public Attributes | |
| uint32_t | mHeader |
| uint32_t | mCount |
| uint32_t | mWord |
| WordSharedArray | mWords |
| EPacketType | mType |
| EOpcode | mOpcode |
| int | mAddress |
Static Public Attributes | |
| static const char * | sPacketTypeName [ePacketTypeCount] |
| Packet type names. | |
| static const char * | sOpcodeName [eOpcodeCount] |
| Packet opcode names. | |
Protected Types | |
| typedef boost::uint32_t | uint32_t |
| Imported type name. | |
| typedef boost::shared_array < uint32_t > | WordSharedArray |
| Word shared array type. | |
Protected Member Functions | |
| void | initialize (void) |
Friends | |
| class | torc::bitstream::bitstream::SpartanPacketUnitTest |
Definition at line 69 of file SpartanPacket.hpp.
typedef boost::uint32_t torc::bitstream::SpartanPacket::uint32_t [protected] |
typedef boost::shared_array<uint32_t> torc::bitstream::SpartanPacket::WordSharedArray [protected] |
| torc::bitstream::SpartanPacket::SpartanPacket | ( | void | ) | [inline] |
| torc::bitstream::SpartanPacket::SpartanPacket | ( | uint32_t | inHeader | ) | [inline] |
| torc::bitstream::SpartanPacket::SpartanPacket | ( | const SpartanPacket & | rhs | ) | [inline] |
| static SpartanPacket torc::bitstream::SpartanPacket::read | ( | std::istream & | inStream | ) | [inline, static] |
Read a packet.
Definition at line 127 of file SpartanPacket.hpp.
| void torc::bitstream::SpartanPacket::write | ( | std::ostream & | inStream | ) | const [inline] |
| static SpartanPacket torc::bitstream::SpartanPacket::makeNullType1Write | ( | uint32_t | inAddress | ) | [inline, static] |
Construct a null type 1 write packet.
A type 1 write packet to the FDRI register is generally only useful to specify the current register in preparation for a type 2 write. The type 2 write header includes a size but specifies no target register, hence the prior null type 1 packet.
Definition at line 187 of file SpartanPacket.hpp.
| static SpartanPacket torc::bitstream::SpartanPacket::makeType1Write | ( | uint32_t | inAddress, | |
| uint32_t | inWord | |||
| ) | [inline, static] |
| static SpartanPacket torc::bitstream::SpartanPacket::makeType2Write | ( | uint32_t | inCount, | |
| uint32_t * | inWords | |||
| ) | [inline, static] |
| static uint32_t torc::bitstream::SpartanPacket::makeHeader | ( | EPacketType | inType, | |
| EOpcode | inOpcode, | |||
| uint32_t | inAddress, | |||
| uint32_t | inCount | |||
| ) | [inline, static] |
Construct a packet header.
Definition at line 208 of file SpartanPacket.hpp.
| uint32_t torc::bitstream::SpartanPacket::getWordCount | ( | void | ) | const [inline] |
Returns the number of payload words in the packet, excluding the header word.
Definition at line 239 of file SpartanPacket.hpp.
| uint32_t torc::bitstream::SpartanPacket::getWordSize | ( | void | ) | const [inline] |
Returns the total number of words in the packet, including the header word.
Definition at line 241 of file SpartanPacket.hpp.
const char * torc::bitstream::SpartanPacket::sPacketTypeName [static] |
Initial value:
{
"[UNKNOWN TYPE 0]", "TYPE1", "TYPE2", "[UNKNOWN TYPE 3]", "[UNKNOWN TYPE 4]",
"[UNKNOWN TYPE 5]", "[UNKNOWN TYPE 6]", "[UNKNOWN TYPE 7]"
}
Definition at line 95 of file SpartanPacket.hpp.
const char * torc::bitstream::SpartanPacket::sOpcodeName [static] |
Initial value:
{
"NOP", "READ", "WRITE", "RESERVED"
}
Definition at line 97 of file SpartanPacket.hpp.
1.5.6