Rogue

Contents:

  • Introduction
  • Installing & Compiling Rogue
  • PyRogue Tree
  • Stream Interface
  • Memory Interface
  • Built-in Modules
  • Logging In Rogue
  • Using The PyDM GUI
  • Tutorials
  • Cookbook
  • Migration Notes
  • API Reference
    • Python API
    • C++ API
      • rogue
      • rogue::interfaces
      • rogue::protocols
        • rogue::protocols::batcher
        • rogue::protocols::packetizer
        • rogue::protocols::rssi
          • Client
          • Server
          • Header
          • Controller
          • Application
          • Transport
        • rogue::protocols::srp
        • rogue::protocols::udp
        • rogue::protocols::xilinx
      • rogue::hardware
      • rogue::utilities
Rogue
  • API Reference
  • C++ API
  • rogue::protocols
  • rogue::protocols::rssi
  • Header
  • View page source

Header

Header is a helper codec/container for RSSI header fields. It parses frame bytes into structured fields (verify()), and encodes fields back into frame bytes with updated checksum (update()). For conceptual guidance, see RSSI Protocol.

Header objects in C++ are referenced by the following shared pointer typedef:

typedef std::shared_ptr<rogue::protocols::rssi::Header> rogue::protocols::rssi::HeaderPtr
[header]

The class description is shown below:

class Header
[header]

RSSI header container and codec.

Wraps a stream frame and provides helpers for encoding, decoding, and validating RSSI header fields.

Field model:

  • Public members are the decoded/encoded RSSI header fields.

  • verify() parses bytes from the frame into these members and validates checksum/size.

  • update() writes members back to frame bytes and updates checksum.

  • SYN-only fields are meaningful when syn == true.

Public Functions

explicit Header(std::shared_ptr<rogue::interfaces::stream::Frame> frame)
[header] [impl]

Constructs a header wrapper for an existing frame.

Creator.

This constructor is a low-level C++ allocation path. Prefer create() when shared ownership or Python exposure is required.

Parameters:

frame – Frame containing RSSI header bytes.

~Header()
[header] [impl]

Destroys the header wrapper.

Destructor.

std::shared_ptr<rogue::interfaces::stream::Frame> getFrame()
[header] [impl]

Returns the underlying frame.

Get Frame.

Returns:

Frame associated with this header object.

bool verify()
[header] [impl]

Verifies header checksum and initializes cached fields.

Verify header contents.

Returns:

True if the header checksum and format are valid.

void update()
[header] [impl]

Encodes current field values into the frame and updates checksum.

Update checksum, set tx time and increment tx count.

struct timeval &getTime()
[header] [impl]

Returns the last transmit timestamp.

Get time.

Returns:

Reference to timestamp associated with this header.

uint32_t count()
[header] [impl]

Returns the transmit count.

Get Count.

Returns:

Transmit count associated with this header.

void rstTime()
[header] [impl]

Resets transmit timestamp to the current time.

Reset timer.

std::string dump()
[header] [impl]

Returns a formatted string of header contents.

Dump message.

Returns:

Human-readable header dump.

Public Members

bool syn
[header]

SYN flag (synchronization/header-extension present).

bool ack
[header]

ACK flag.

bool rst
[header]

RST flag.

bool nul
[header]

NUL/keepalive flag.

bool busy
[header]

Busy flag.

uint8_t sequence
[header]

Sequence number field.

uint8_t acknowledge
[header]

Acknowledge number field.

uint8_t version
[header]

Protocol version (SYN headers only).

bool chk
[header]

CHK capability flag (SYN headers only).

uint8_t maxOutstandingSegments
[header]

Maximum outstanding segments (SYN headers only).

uint16_t maxSegmentSize
[header]

Maximum segment size (SYN headers only).

uint16_t retransmissionTimeout
[header]

Retransmission timeout (SYN headers only).

uint16_t cumulativeAckTimeout
[header]

Cumulative ACK timeout (SYN headers only).

uint16_t nullTimeout
[header]

NULL/keepalive timeout (SYN headers only).

uint8_t maxRetransmissions
[header]

Maximum retransmissions (SYN headers only).

uint8_t maxCumulativeAck
[header]

Maximum cumulative ACK count (SYN headers only).

uint8_t timeoutUnit
[header]

Timeout unit field (SYN headers only).

uint32_t connectionId
[header]

Connection ID (SYN headers only).

Public Static Functions

static std::shared_ptr<rogue::protocols::rssi::Header> create(std::shared_ptr<rogue::interfaces::stream::Frame> frame)
[header] [impl]

Creates a header wrapper for an existing frame.

Create.

Parameter semantics are identical to the constructor; see Header() for wrapper-construction details. This static factory is the preferred construction path when the object is shared across Rogue graph connections or exposed to Python. It returns std::shared_ptr ownership compatible with Rogue pointer typedefs.

Parameters:

frame – Frame containing RSSI header bytes.

Returns:

Shared pointer to the created header wrapper.

Public Static Attributes

static const int32_t HeaderSize = 8
[header]

Encoded RSSI non-SYN header size in bytes.

static const uint32_t SynSize = 24
[header]

Encoded RSSI SYN header size in bytes.

Previous Next

© Copyright 2026, SLAC National Accelerator Laboratory.

Built with Sphinx using a theme provided by Read the Docs.