rohc

package
v0.16.12 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 19, 2026 License: BSD-3-Clause, GPL-3.0 Imports: 3 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CRC

func CRC(data []byte, width uint) byte

CRC uses the reflected ROHC polynomial and no final complement (RFC 3095 5.9).

func PacketCID

func PacketCID(wire []byte, large bool) (id byte, first, after int, err error)

PacketCID implements the ATSC small/one-octet large CID channel configurations.

Types

type Context

type Context struct {
	Version                     byte
	Source, Destination         [16]byte
	SourcePort, DestinationPort uint16
	Flow                        uint32
	Traffic, Hop, Flags         byte
	ID, Checksum, SN            uint16
	Static, Dynamic             bool
}

func DecodeUDP

func DecodeUDP(previous Context, wire []byte, first, afterCID int) (Context, []byte, error)

DecodeUDP takes the original wire header so CID octets remain CRC-covered. first points to the packet-type octet; afterCID points past an optional large CID.

func Dynamic

func Dynamic(c Context, data []byte) (Context, int, error)

func Static

func Static(data []byte) (Context, int, error)

type Description

type Description struct {
	PLP, MaxCID, Mode, Config uint8
	Contexts                  []DescriptionContext
}

func ParseRDT

func ParseRDT(data []byte) (Description, error)

func (Description) InitialStates

func (d Description) InitialStates() (map[byte]Context, error)

type DescriptionContext

type DescriptionContext struct {
	ID, Profile uint8
	ChainLength int
	Chain       []byte `json:"-"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL