Table Of Contents

BitStructure

class BitStructure(name)

Bases: BitPacket.Container.Container

This class represents an structure formed by bit fields. The resulting structure must be byte-aligned and is to be used with other BitPacket types.

Initialize the bit structure field with the given name. By default an structure field does not contain any fields.

size()

Returns the size of the field in bytes. This function will add all the bit field sizes in order to calculate the byte size of the container.

Structure

class Structure(name)

Bases: BitPacket.Container.Container

This class provides a byte-aligned Container implementation. All the fields added to it should be byte-aligned.

Initialize the structure with the given name. By default, it does not contain any fields.