Capture

Capture-related classes and enumerations.

class excentis.xra31.capture.PacketType(value)

An enumeration of the packet types used for filtering.

DATA = 0

Data.

BURST = 1

Burst.

OTHER = 2

Other.

RANGING = 3

Ranging.

BW_REQ = 4

Bandwidth Request.

SYNC = 5

SYNC.

MAP_REFERENCE = 6

MAP on reference channel.

MAP_NON_REFERENCE = 7

MAP on non-reference channel.

class excentis.xra31.capture.OfdmStream(value)

An enumeration of the OFDM streams that can be added or removed.

PLC = 0

Physical Layer Link Channel.

NCP = 1

Next Codeword Pointer.

class excentis.xra31.capture.OfdmProfile(value)

An enumeration of the OFDM Profiles.

A = 0

Profile A.

B = 1

Profile B.

C = 2

Profile C.

D = 3

Profile D.

E = 4

Profile E.

F = 5

Profile F.

G = 6

Profile G.

H = 7

Profile H.

I = 8

Profile I.

J = 9

Profile J.

K = 10

Profile K.

L = 11

Profile L.

M = 12

Profile M.

N = 13

Profile N.

O = 14

Profile O.

P = 15

Profile P.

class excentis.xra31.capture.Channels(xra31)

Access and manipulate the capture channel selection.

property ofdm: Iterable[OfdmChannel]

Get the OFDM channels.

property sc_qam: Iterable[ScQamChannel]

Get the downstream SC-QAM channels.

property downstream: Iterable[Channel]

Get the downstream channels.

property ofdma: Iterable[OfdmaChannel]

Get the OFDMA channels.

property a_tdma: Iterable[ATdmaChannel]

Get the A-TDMA channels.

property upstream: Iterable[Channel]

Get the upstream channels.

property channels: Iterable[Channel]

Get all channels.

add(channel_parameters: Channel = None, *, channel_type: ChannelType = None, xra31_id: int = - 1, ucid: int = - 1, frequency: float = 0.0) bool

Include a channel in the capture.

Parameters
  • channel_parameters (core.Channel, optional) – A channel containing the relevant parameters.

  • channel_type (core.ChannelType, optional) – The channel’s type.

  • xra31_id (int, optional) – ID on the XRA-31.

  • ucid (int, optional) – DOCSIS Upstream Channel ID.

  • frequency (float, optional) – PLC (OFDM) or center frequency (MHz).

Returns

True if successful, False otherwise.

Return type

bool

remove(channel_parameters: Channel = None, *, channel_type: ChannelType = None, xra31_id: int = - 1, ucid: int = - 1, frequency: float = 0.0) bool

Don’t include a channel in the capture.

Parameters
  • channel_parameters (core.Channel, optional) – A channel containing the relevant parameters.

  • channel_type (core.ChannelType, optional) – The channel’s type.

  • xra31_id (int, optional) – ID on the XRA-31.

  • ucid (int, optional) – DOCSIS Upstream Channel ID.

  • frequency (float, optional) – PLC (OFDM) or center frequency (MHz).

Returns

True if successful, False otherwise.

Return type

bool

clear() None

Ignore all channels.

describe() Dict[str, Any]

Get a minimal representation of the capture channel selection.

Returns

Description listing frequencies for downstream, and UCIDs for upstream.

Return type

dict

apply(description: dict) None

Apply a capture channel selection.

Parameters

description (dict) – The selection description (describe()).

class excentis.xra31.capture.Filtering(xra31)

Access the capture filtering parameters, including the packet types, OFDM profiles and OFDM streams.

property packet_types: List[PacketType]

The packet types, as listed in PacketType.

add_packet_type(packet_type: PacketType) None

Add a packet type.

remove_packet_type(packet_type: PacketType) None

Remove a packet type.

clear_packet_types() None

Remove all packet types.

property ofdm_streams: List[OfdmStream]

The OFDM streams, as listed in OfdmStream.

add_ofdm_stream(stream: OfdmStream) None

Add an OFDM stream.

remove_ofdm_stream(stream: OfdmStream) None

Remove an OFDM stream.

clear_ofdm_streams() None

Remove all OFDM streams.

property ofdm_profiles: List[OfdmProfile]

The OFDM profiles, as listed in OfdmProfile.

add_ofdm_profile(profile: OfdmProfile) None

Add an OFDM profile.

remove_ofdm_profile(profile: OfdmProfile) None

Remove an OFDM profile.

clear_ofdm_profiles() None

Remove all OFDM profiles.

describe() Dict[str, Any]

Get a minimal representation of the capture filtering.

Returns

Description listing packet types, OFDM profiles and OFDM streams.

Return type

dict

apply(description: dict) None

Apply a filtering configuration.

Parameters

description (dict) – The filtering description (describe()).

class excentis.xra31.capture.Output(xra31)

Access the capture output parameters.

property directory: str

The directory in which the capture is stored.

Deprecated since version v5.0.0: Use path instead, accessing property pathlib.PurePath.parent.

property filename: str

The filename of the capture.

Deprecated since version v5.0.0: Use path instead, accessing property pathlib.PurePath.name.

property path: PurePosixPath

The path (pathlib.PurePosixPath) of the capture.

New in version v5.0.0.

property duration: Optional[float]

The maximum duration of the capture (s), None for unlimited. Setting the maximum capture duration resets the maximum capture size.

property size: Optional[float]

The maximum size of the capture (MB), None for unlimited. Setting the maximum capture size resets the maximum capture duration.

property number_of_files: int

The number of files in a rolling file capture.

property file_duration: Optional[float]

The maximum file duration before rolling over to the next file in a rolling file capture (s), None for unlimited. Setting the maximum file duration resets the maximum file size in a rolling file capture.

property file_size: Optional[float]

The file size before rolling over to the next file in a rolling file capture (MB), None for unlimited. Setting the maximum file size resets the maximum file duration in a rolling file capture.

describe() Dict[str, Any]

Get a minimal representation of the capture output configuration.

Returns

A full description of the output configuration.

Return type

dict

apply(description: dict) None

Apply a capture output configuration.

Parameters

description (dict) – The output configuration description (describe()).

class excentis.xra31.capture.Capture(xra31)

Access capture-related settings and actions.

property channels: Channels

Get the list of channels.

property active: bool

Indicates if the capture is recording.

property filename: Optional[str]

The active, or latest when inactive, capture filename.

Deprecated since version v5.0.0: Use active_path and captured_path instead, accessing property pathlib.PurePath.name.

property active_path: Optional[PurePosixPath]

The path to the active capture, if available.

New in version v5.0.0.

property captured_path: Optional[PurePosixPath]

The path to the most recently completed capture, if available.

New in version v5.0.0.

property duration: float

The duration of the current capture.

property size: float

The file size of the current capture.

start() None

Start a capture.

wait_for_end(timeout: float = None) Optional[PurePosixPath]

Wait for a capture to end.

Parameters

timeout (float, optional) – Number of seconds to wait before giving up; by default it will wait indefinitely.

Returns

The path of the most recent capture if successful, None otherwise.

Return type

pathlib.PurePosixPath

Changed in version v5.0.0: return type.

wait_for_file_end(timeout: float = None) Optional[PurePosixPath]

Wait for a file rollover in a rolling file capture.

Parameters

timeout (float, optional) – Number of seconds to wait before giving up; by default it will wait indefinitely.

Returns

The path of the most recent capture if successful, None otherwise.

Return type

pathlib.PurePosixPath

Changed in version v5.0.0: return type.

stop() None

Stop a capture.

describe() Dict[str, Any]

Get a minimal representation of the capture configuration.

Returns

Description listing channels, filtering and output.

Return type

dict

apply(description: dict) None

Apply a capture configuration.

Parameters

description (dict) – The capture description (describe()).