klvdata package

Submodules

klvdata.common module

klvdata.common.ber_decode(value)

Return decoded BER length as integer given bytes.

klvdata.common.ber_encode(value)

Return encoded BER length as bytes given integer.

klvdata.common.bytes_to_datetime(value)

Return datetime from microsecond bytes.

klvdata.common.bytes_to_float(value, _domain, _range)

Convert the fixed point value self.value to a floating point value.

klvdata.common.bytes_to_hexstr(value, start='', sep=' ')

Return string of hexadecimal numbers separated by spaces from a bytes object.

klvdata.common.bytes_to_int(value, signed=False)

Return integer given bytes.

klvdata.common.bytes_to_str(value)

Return UTF-8 formatted string from bytes object.

klvdata.common.datetime_to_bytes(value)

Return bytes representing UTC time in microseconds.

klvdata.common.float_to_bytes(value, _domain, _range)

Convert the fixed point value self.value to a floating point value.

klvdata.common.hexstr_to_bytes(value)

Return bytes object and filter out formatting characters from a string of hexadecimal numbers.

klvdata.common.int_to_bytes(value, length=1, signed=False)

Return bytes given integer

klvdata.common.linear_map(src_value, src_domain, dst_range)

Maps source value (src_value) in the source domain (source_domain) onto the destination range (dest_range) using linear interpretation.

Except that at the moment src_value is a bytes value that once converted to integer that it then is on the src_domain.

Ideally would like to move the conversion from bytes to int externally.

Once value is same base and format as src_domain (i.e. converted from bytes), it should always fall within the src_domain. If not, that’s a problem.

klvdata.common.packet_checksum(data)

Return two byte checksum from a SMPTE ST 336 KLV structured bytes object.

klvdata.common.str_to_bytes(value)

Return bytes object from UTF-8 formatted string.

klvdata.element module

class klvdata.element.Element(key, value)

Bases: object

Construct a key, length, value tuplet.

Elements provide the basic mechanisms to constitute the basic encoding requirements of key, length, value tuplet as specified by STMPE 336.

The length is dynamically calculated based off the value.

Attributes:

key value

Properties:

name: If name is set return name, else return class name. length: Length is calculated based off value.

property length

bytes: Return the BER encoded byte length of self.value.

property name
class klvdata.element.UnknownElement(key, value)

Bases: klvdata.element.Element

klvdata.elementparser module

class klvdata.elementparser.BaseValue

Bases: object

Abstract base class (superclass) used to insure internal interfaces are maintained.

class klvdata.elementparser.BytesElementParser(value)

Bases: klvdata.elementparser.ElementParser

class klvdata.elementparser.BytesValue(value)

Bases: klvdata.elementparser.BaseValue

class klvdata.elementparser.DateTimeElementParser(value)

Bases: klvdata.elementparser.ElementParser

class klvdata.elementparser.DateTimeValue(value)

Bases: klvdata.elementparser.BaseValue

class klvdata.elementparser.ElementParser(value)

Bases: klvdata.element.Element

Construct a Element Parser base class.

Element Parsers are used to enforce the convention that all Element Parsers already know the key of the element they are constructing.

Element Parser is a helper class that simplifies known element definition and makes a layer of abstraction for functionality that all known elements can share. The parsing interfaces are cleaner and require less coding as their definitions (subclasses of Element Parser) do not need to call init on super with class key and instance value.

abstract property key

classmethod(function) -> method

Convert a function to be a class method.

A class method receives the class as implicit first argument, just like an instance method receives the instance. To declare a class method, use this idiom:

class C:

@classmethod def f(cls, arg1, arg2, …):

It can be called either on the class (e.g. C.f()) or on an instance (e.g. C().f()). The instance is ignored except for its class. If a class method is called for a derived class, the derived class object is passed as the implied first argument.

Class methods are different than C++ or Java static methods. If you want those, see the staticmethod builtin.

class klvdata.elementparser.MappedElementParser(value)

Bases: klvdata.elementparser.ElementParser

class klvdata.elementparser.MappedValue(value, _domain, _range)

Bases: klvdata.elementparser.BaseValue

class klvdata.elementparser.StringElementParser(value)

Bases: klvdata.elementparser.ElementParser

class klvdata.elementparser.StringValue(value)

Bases: klvdata.elementparser.BaseValue

klvdata.klvparser module

class klvdata.klvparser.KLVParser(source, key_length)

Bases: object

Return key, value pairs parsed from an SMPTE ST 336 source.

klvdata.misb0102 module

class klvdata.misb0102.SecurityClassification(value)

Bases: klvdata.elementparser.BytesElementParser

MISB ST0102 Security Classification value interpretation parser.

The Security Classification metadata element contains a value representing the entire security classification of the file in accordance with U.S. and NATO classification guidance.

key = b'\x01'
class klvdata.misb0102.SecurityLocalMetadataSet(value, key_length=1)

Bases: klvdata.setparser.SetParser

MISB ST0102 Security Metadata nested local set parser.

The Security Metdata set comprise information needed to comply with CAPCO, DoD Information Security Program and other normatively referenced security directives.

Must be a subclass of Element or duck type Element.

key = b'0'
name = 'Security Local Metadata Set'
parsers = {b'\x01': <class 'klvdata.misb0102.SecurityClassification'>}
class klvdata.misb0102.UnknownElement(key, value)

Bases: klvdata.element.UnknownElement

klvdata.misb0601 module

class klvdata.misb0601.AirfieldBarometricPressure(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Airfield Barometric Pressure'
TAG = 53
UDSKey = '-'
UDSName = ''
key = b'5'
units = 'millibar'
class klvdata.misb0601.AirfieldElevation(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Airfield Elevation'
TAG = 54
UDSKey = '-'
UDSName = ''
key = b'6'
units = 'meters'
class klvdata.misb0601.AlternatePlatformAltitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Alternate Platform Altitude'
TAG = 69
UDSKey = '-'
UDSName = ''
key = b'E'
units = 'meters'
class klvdata.misb0601.AlternatePlatformEllipsoidHeight(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Alternate Platform Ellipsoid Height'
TAG = 76
UDSKey = '-'
UDSName = ''
key = b'L'
units = 'meters'
class klvdata.misb0601.AlternatePlatformEllipsoidHeightExtended(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = ' Alternate Platform Ellipsoid Height Extended'
TAG = 105
UDSKey = '06 0E 2B 34 01 01 01 01 0E 01 02 01 82 48 00 00'
UDSName = ''
key = b'i'
units = 'meters'
class klvdata.misb0601.AlternatePlatformHeading(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Alternate Platform Heading'
TAG = 71
UDSKey = '-'
UDSName = ''
key = b'G'
units = 'degrees'
class klvdata.misb0601.AlternatePlatformLatitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Alternate Platform Latitude'
TAG = 67
UDSKey = '-'
UDSName = ''
key = b'C'
units = 'degrees'
class klvdata.misb0601.AlternatePlatformLongitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Alternate Platform Longitude'
TAG = 68
UDSKey = '-'
UDSName = ''
key = b'D'
units = 'degrees'
class klvdata.misb0601.AlternatePlatformName(value)

Bases: klvdata.elementparser.StringElementParser

ESDName = ''
LDSName = 'Alternate Platform Name'
TAG = 70
UDSKey = '-'
UDSName = ''
key = b'F'
max_length = 127
min_length = 0
class klvdata.misb0601.Checksum(value)

Bases: klvdata.elementparser.BytesElementParser

Checksum used to detect errors within a UAV Local Set packet.

Checksum formed as lower 16-bits of summation performed on entire LS packet, including 16-byte US key and 1-byte checksum length.

Initialized from bytes value as BytesValue.

ESDName = ''
LDSName = 'Checksum'
TAG = 1
UDSKey = '-'
UDSName = ''
key = b'\x01'
class klvdata.misb0601.CornerLatitudePoint1Full(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Latitude 4'
LDSName = 'Corner Latitude Point 1 (Full)'
TAG = 82
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 07 01 00'
UDSName = 'Corner Latitude Point 1 (Decimal Degrees)'
key = b'R'
units = 'degrees'
class klvdata.misb0601.CornerLatitudePoint2Full(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Latitude 1'
LDSName = 'Corner Latitude Point 2 (Full)'
TAG = 84
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 08 01 00'
UDSName = 'Corner Latitude Point 2 (Decimal Degrees)'
key = b'T'
units = 'degrees'
class klvdata.misb0601.CornerLatitudePoint3Full(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Latitude 2'
LDSName = 'Corner Latitude Point 3 (Full)'
TAG = 86
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 09 01 00'
UDSName = 'Corner Latitude Point 3 (Decimal Degrees)'
key = b'V'
units = 'degrees'
class klvdata.misb0601.CornerLatitudePoint4Full(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Latitude 3'
LDSName = 'Corner Latitude Point 4 (Full)'
TAG = 88
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0A 01 00'
UDSName = 'Corner Latitude Point 4 (Decimal Degrees)'
key = b'X'
units = 'degrees'
class klvdata.misb0601.CornerLongitudePoint1Full(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Longitude 4'
LDSName = 'Corner Longitude Point 1 (Full)'
TAG = 83
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0B 01 00'
UDSName = 'Corner Longitude Point 1 (Decimal Degrees)'
key = b'S'
units = 'degrees'
class klvdata.misb0601.CornerLongitudePoint2Full(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Longitude 1'
LDSName = 'Corner Longitude Point 2 (Full)'
TAG = 85
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0C 01 00'
UDSName = 'Corner Longitude Point 2 (Decimal Degrees)'
key = b'U'
units = 'degrees'
class klvdata.misb0601.CornerLongitudePoint3Full(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Longitude 2'
LDSName = 'Corner Longitude Point 3 (Full)'
TAG = 87
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0D 01 00'
UDSName = 'Corner Longitude Point 3 (Decimal Degrees)'
key = b'W'
units = 'degrees'
class klvdata.misb0601.CornerLongitudePoint4Full(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Longitude 3'
LDSName = 'Corner Longitude Point 4 (Full)'
TAG = 89
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0E 01 00'
UDSName = 'Corner Longitude Point 4 (Decimal Degrees)'
key = b'Y'
units = 'degrees'
class klvdata.misb0601.DensityAltitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Density Altitude'
LDSName = 'Density Altitude'
TAG = 38
UDSKey = '-'
UDSName = ''
key = b'&'
units = 'meters'
class klvdata.misb0601.DensityAltitudeExtended(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Density Altitude'
LDSName = 'Density Altitude Extended'
TAG = 103
UDSKey = '06 0E 2B 34 01 01 01 01 0E 01 01 01 10 00 00 00'
UDSName = ''
key = b'g'
units = 'meters'
class klvdata.misb0601.DifferentialPressure(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Differential Pressure'
TAG = 49
UDSKey = '-'
UDSName = ''
key = b'1'
units = 'millibar'
class klvdata.misb0601.EventStartTime(value)

Bases: klvdata.elementparser.DateTimeElementParser

ESDName = 'Mission Start Time, Date, and Date of Collection'
LDSName = 'Event Start Time - UTC'
TAG = 72
UDSKey = '06 0E 2B 34 01 01 01 01 07 02 01 02 07 01 00 00'
UDSName = 'Event Start Date Time - UTC'
key = b'H'
class klvdata.misb0601.FrameCenterElevation(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Frame Center Elevation'
LDSName = 'Frame Center Elevation'
TAG = 25
UDSKey = '-'
UDSName = ''
key = b'\x19'
units = 'meters'
class klvdata.misb0601.FrameCenterHeightAboveEllipsoid(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Frame Center Height Above Ellipsoid'
TAG = 78
UDSKey = '-'
UDSName = ''
key = b'N'
units = 'meters'
class klvdata.misb0601.FrameCenterLatitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Target Latitude'
LDSName = 'Frame Center Latitude'
TAG = 23
UDSKey = '06 0E 2B 34 01 01 01 01 07 01 02 01 03 02 00 00'
UDSName = 'Frame Center Latitude'
key = b'\x17'
units = 'degrees'
class klvdata.misb0601.FrameCenterLongitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Target Longitude'
LDSName = 'Frame Center Longitude'
TAG = 24
UDSKey = '06 0E 2B 34 01 01 01 01 07 01 02 01 03 04 00 00'
UDSName = 'Frame Center Longitude'
key = b'\x18'
units = 'degrees'
class klvdata.misb0601.GenericFlagData01(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Generic Flag Data 01'
TAG = 47
UDSKey = '-'
UDSName = ''
key = b'/'
class klvdata.misb0601.GroundRange(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Ground Range'
LDSName = 'Ground Range'
TAG = 57
UDSKey = '-'
UDSName = ''
key = b'9'
units = 'meters'
class klvdata.misb0601.IcingDetected(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Icing Detected'
LDSName = 'Icing Detected'
TAG = 34
UDSKey = ''
UDSName = ''
key = b'"'
units = 'flag'
class klvdata.misb0601.ImageCoordinateSystem(value)

Bases: klvdata.elementparser.StringElementParser

ESDName = 'Image Coordinate System'
LDSName = 'Image Coordinate System'
TAG = 12
UDSKey = '06 0E 2B 34 01 01 01 01 07 01 01 01 00 00 00 00'
UDSName = 'Image Coordinate System'
key = b'\x0c'
max_length = 127
min_length = 0
class klvdata.misb0601.ImageSourceSensor(value)

Bases: klvdata.elementparser.StringElementParser

ESDName = 'Sensor Name'
LDSName = 'Image Source Sensor'
TAG = 11
UDSKey = '06 0E 2B 34 01 01 01 01 04 20 01 02 01 01 00 00'
UDSName = 'Image Source Device'
key = b'\x0b'
max_length = 127
min_length = 0
class klvdata.misb0601.LaserPRFCode(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Laser PRF Code'
LDSName = 'Laser PRF Code'
TAG = 62
UDSKey = '-'
UDSName = ''
key = b'>'
class klvdata.misb0601.MissionID(value)

Bases: klvdata.elementparser.StringElementParser

Mission ID is the descriptive mission identifier.

Mission ID value field free text with maximum of 127 characters describing the event.

ESDName = 'Mission Number'
LDSName = 'Mission ID'
TAG = 3
UDSKey = '06 0E 2B 34 01 01 01 01 01 05 05 00 00 00 00 00'
UDSName = 'Episode Number'
key = b'\x03'
max_length = 127
min_length = 0
class klvdata.misb0601.OffsetCornerLatitudePoint1(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Latitude 4'
LDSName = 'Offset Corner Latitude Point 1'
TAG = 26
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 07 01 00'
UDSName = 'Corner Latitude Point 1'
key = b'\x1a'
units = 'degrees'
class klvdata.misb0601.OffsetCornerLatitudePoint2(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Latitude 1'
LDSName = 'Offset Corner Latitude Point 2'
TAG = 28
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 08 01 00'
UDSName = 'Corner Latitude Point 2'
key = b'\x1c'
units = 'degrees'
class klvdata.misb0601.OffsetCornerLatitudePoint3(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Latitude 2'
LDSName = 'Offset Corner Latitude Point 3'
TAG = 30
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 09 01 00'
UDSName = 'Corner Latitude Point 3'
key = b'\x1e'
units = 'degrees'
class klvdata.misb0601.OffsetCornerLatitudePoint4(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Latitude 3'
LDSName = 'Offset Corner Latitude Point 4'
TAG = 32
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0A 01 00'
UDSName = 'Corner Latitude Point 4'
key = b' '
units = 'degrees'
class klvdata.misb0601.OffsetCornerLongitudePoint1(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Longitude 4'
LDSName = 'Offset Corner Longitude Point 1'
TAG = 27
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0B 01 00'
UDSName = 'Corner Longitude Point 1'
key = b'\x1b'
units = 'degrees'
class klvdata.misb0601.OffsetCornerLongitudePoint2(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Longitude 1'
LDSName = 'Offset Corner Longitude Point 2'
TAG = 29
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0C 01 00'
UDSName = 'Corner Longitude Point 2'
key = b'\x1d'
units = 'degrees'
class klvdata.misb0601.OffsetCornerLongitudePoint3(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Longitude 2'
LDSName = 'Offset Corner Longitude Point 3'
TAG = 31
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0D 01 00'
UDSName = 'Corner Longitude Point 3'
key = b'\x1f'
units = 'degrees'
class klvdata.misb0601.OffsetCornerLongitudePoint4(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'SAR Longitude 3'
LDSName = 'Offset Corner Longitude Point 4'
TAG = 33
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 03 0E 01 00'
UDSName = 'Corner Longitude Point 4'
key = b'!'
units = 'degrees'
class klvdata.misb0601.OperationalMode(value)

Bases: klvdata.elementparser.StringElementParser

ESDName = ''
LDSName = 'Operational Mode'
TAG = 77
UDSKey = '-'
UDSName = ''
key = b'M'
class klvdata.misb0601.OutsideAirTemperature(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Air Temperature'
LDSName = 'Outside Air Temperature'
TAG = 39
UDSKey = '-'
UDSName = ''
key = b"'"
units = 'celcius'
class klvdata.misb0601.PlatformAngleOfAttack(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Platform Angle of Attack'
TAG = 50
UDSKey = '-'
UDSName = ''
key = b'2'
units = 'degrees'
class klvdata.misb0601.PlatformAngleOfAttackFull(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Platform Angle of Attack (Full)'
TAG = 92
UDSKey = '-'
UDSName = ''
key = b'\\'
units = 'degrees'
class klvdata.misb0601.PlatformCallSign(value)

Bases: klvdata.elementparser.StringElementParser

ESDName = 'Platform Call Sign'
LDSName = 'Platform Call Sign'
TAG = 59
UDSKey = '-'
UDSName = ''
key = b';'
class klvdata.misb0601.PlatformDesignation(value)

Bases: klvdata.elementparser.StringElementParser

ESDName = 'Project ID Code'
LDSName = 'Platform Designation'
TAG = 10
UDSKey = '06 0E 2B 34 01 01 01 01 01 01 20 01 00 00 00 00'
UDSName = 'Device Designation'
key = b'\n'
max_length = 127
min_length = 0
class klvdata.misb0601.PlatformFuelRemaining(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Platform Fuel Remaining'
LDSName = 'Platform Fuel Remaining'
TAG = 58
UDSKey = '-'
UDSName = ''
key = b':'
units = 'kilograms'
class klvdata.misb0601.PlatformGroundSpeed(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Platform Ground Speed'
LDSName = 'Platform Ground Speed'
TAG = 56
UDSKey = '-'
UDSName = ''
key = b'8'
units = 'meters/second'
class klvdata.misb0601.PlatformHeadingAngle(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'UAV Heading (INS)'
LDSName = 'Platform Heading Angle'
TAG = 5
UDSKey = '06 0E 2B 34 01 01 01 07 07 01 10 01 06 00 00 00'
UDSName = 'Platform Heading Angle'
key = b'\x05'
class klvdata.misb0601.PlatformIndicatedAirspeed(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Indicated Airspeed'
LDSName = 'Platform Indicated Airspeed'
TAG = 9
UDSKey = '-'
UDSName = ''
key = b'\t'
units = 'meters/second'
class klvdata.misb0601.PlatformMagneticHeading(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Platform Magnetic Heading'
LDSName = 'Platform Magnetic Heading'
TAG = 64
UDSKey = '-'
UDSName = ''
key = b'@'
units = 'degrees'
class klvdata.misb0601.PlatformPitchAngle(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'UAV Pitch (INS)'
LDSName = 'Platform Pitch Angle'
TAG = 6
UDSKey = '06 0E 2B 34 01 01 01 07 07 01 10 01 05 00 00 00'
UDSName = 'Platform Pitch Angle'
key = b'\x06'
class klvdata.misb0601.PlatformPitchAngleFull(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'UAV Pitch (INS)'
LDSName = 'Platform Pitch Angle (Full)'
TAG = 90
UDSKey = '06 0E 2B 34 01 01 01 07 07 01 10 01 05 00 00 00'
UDSName = 'Platform Pitch Angle'
key = b'Z'
units = 'degrees'
class klvdata.misb0601.PlatformRollAngle(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'UAV Roll (INS)'
LDSName = 'Platform Roll Angle'
TAG = 7
UDSKey = ' 06 0E 2B 34 01 01 01 07 07 01 10 01 04 00 00 00'
UDSName = 'Platform Roll Angle'
key = b'\x07'
units = 'degrees'
class klvdata.misb0601.PlatformRollAngleFull(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'UAV Roll (INS)'
LDSName = 'Platform Roll Angle (Full)'
TAG = 91
UDSKey = '06 0E 2B 34 01 01 01 07 07 01 10 01 04 00 00 00'
UDSName = 'Platform Roll Angle'
key = b'['
units = 'degrees'
class klvdata.misb0601.PlatformSideslipAngle(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Platform Sideslip Angle'
TAG = 52
UDSKey = '-'
UDSName = ''
key = b'4'
units = 'degrees'
class klvdata.misb0601.PlatformSideslipAngleFull(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Platform Sideslip Angle (Full)'
TAG = 93
UDSKey = '-'
UDSName = ''
key = b']'
units = 'degrees'
class klvdata.misb0601.PlatformTailNumber(value)

Bases: klvdata.elementparser.StringElementParser

ESDName = 'Platform Tail Number'
LDSName = 'Platform Tail Number'
TAG = 4
UDSKey = '-'
UDSName = ''
key = b'\x04'
max_length = 127
min_length = 0
class klvdata.misb0601.PlatformTrueAirspeed(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'True Airspeed'
LDSName = 'Platform True Airspeed'
TAG = 8
UDSKey = '-'
UDSName = ''
key = b'\x08'
units = 'meters/second'
class klvdata.misb0601.PlatformVerticalSpeed(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Platform Vertical Speed'
TAG = 51
UDSKey = '-'
UDSName = ''
key = b'3'
units = 'meters/second'
class klvdata.misb0601.PrecisionTimeStamp(value)

Bases: klvdata.elementparser.DateTimeElementParser

Precision Timestamp represented in microseconds.

Precision Timestamp represented in the number of microseconds elapsed since midnight (00:00:00), January 1, 1970 not including leap seconds.

See MISB ST 0601.11 for additional details.

ESDName = ''
LDSName = 'Precision Time Stamp'
TAG = 2
UDSKey = '06 0E 2B 34 01 01 01 03 07 02 01 01 01 05 00 00'
UDSName = 'User Defined Time Stamp'
key = b'\x02'
class klvdata.misb0601.RVTLocalSet(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'RVT Local Data Set'
TAG = 73
UDSKey = '06 0E 2B 34 01 01 01 01 07 02 01 02 07 01 00 00'
UDSName = 'Remote Video Terminal Local Set'
key = b'I'
class klvdata.misb0601.RelativeHumidity(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Relative Humidity'
TAG = 55
UDSKey = '-'
UDSName = ''
key = b'7'
units = '%'
class klvdata.misb0601.SensorEastVelocity(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Sensor East Velocity'
TAG = 80
UDSKey = '-'
UDSName = ''
key = b'P'
units = 'meters/second'
class klvdata.misb0601.SensorEllipsoidHeightConversion(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Sensor Ellipsoid Height'
TAG = 75
UDSKey = '-'
UDSName = ''
key = b'K'
units = 'meters'
class klvdata.misb0601.SensorEllipsoidHeightExtended(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Sensor Ellipsoid Height Extended'
TAG = 104
UDSKey = '06 0E 2B 34 01 01 01 01 0E 01 02 01 82 47 00 00'
UDSName = ''
key = b'h'
units = 'meters'
class klvdata.misb0601.SensorFieldOfViewName(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Sensor Field of View Name'
LDSName = 'Sensor Field of View Name'
TAG = 63
UDSKey = '-'
UDSName = ''
key = b'?'
class klvdata.misb0601.SensorHorizontalFieldOfView(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Field of View'
LDSName = 'Sensor Horizontal Field of View'
TAG = 16
UDSKey = '06 0E 2B 34 01 01 01 02 04 20 02 01 01 08 00 00'
UDSName = 'Field of View (FOVHorizontal)'
key = b'\x10'
units = 'degrees'
class klvdata.misb0601.SensorLatitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Sensor Latitude'
LDSName = 'Sensor Latitude'
TAG = 13
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 02 04 02 00'
UDSName = 'Device Latitude'
key = b'\r'
units = 'degrees'
class klvdata.misb0601.SensorLongitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Sensor Longitude'
LDSName = 'Sensor Longitude'
TAG = 14
UDSKey = '06 0E 2B 34 01 01 01 03 07 01 02 01 02 06 02 00'
UDSName = 'Device Longitude'
key = b'\x0e'
units = 'degrees'
class klvdata.misb0601.SensorNorthVelocity(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Sensor North Velocity'
TAG = 79
UDSKey = '-'
UDSName = ''
key = b'O'
units = 'meters/second'
class klvdata.misb0601.SensorRelativeAzimuthAngle(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Sensor Relative Azimuth Angle'
LDSName = 'Sensor Relative Azimuth Angle'
TAG = 18
UDSKey = '-'
UDSName = ''
key = b'\x12'
units = 'degrees'
class klvdata.misb0601.SensorRelativeElevationAngle(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Sensor Relative Elevation Angle'
LDSName = 'Sensor Relative Elevation Angle'
TAG = 19
UDSKey = '-'
UDSName = ''
key = b'\x13'
units = 'degrees'
class klvdata.misb0601.SensorRelativeRollAngle(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Sensor Relative Roll Angle'
LDSName = 'Sensor Relative Roll Angle'
TAG = 20
UDSKey = '-'
UDSName = ''
key = b'\x14'
units = 'degrees'
class klvdata.misb0601.SensorTrueAltitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Sensor Altitude'
LDSName = 'Sensor True Altitude'
TAG = 15
UDSKey = '06 0E 2B 34 01 01 01 01 07 01 02 01 02 02 00 00'
UDSName = 'Device Altitude'
key = b'\x0f'
units = 'meters'
class klvdata.misb0601.SensorVerticalFieldOfView(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Vertical Field of View'
LDSName = 'Sensor Vertical Field of View'
TAG = 17
UDSKey = '-'
UDSName = ''
key = b'\x11'
units = 'degrees'
class klvdata.misb0601.SlantRange(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Slant Range'
LDSName = 'Slant Range'
TAG = 21
UDSKey = '06 0E 2B 34 01 01 01 01 07 01 08 01 01 00 00 00'
UDSName = 'Slant Range'
key = b'\x15'
units = 'meters'
class klvdata.misb0601.StaticPressure(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Static Pressure'
LDSName = 'Static Pressure'
TAG = 37
UDSKey = '-'
UDSName = ''
key = b'%'
units = 'millibar'
class klvdata.misb0601.TargetErrorEstimateCE90(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Target Error Estimate - CE90'
TAG = 45
UDSKey = '-'
UDSName = ''
key = b'-'
units = 'meters'
class klvdata.misb0601.TargetErrorEstimateLE90(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Target Error Estimate - LE90'
TAG = 46
UDSKey = '-'
UDSName = ''
key = b'.'
units = 'meters'
class klvdata.misb0601.TargetLocationElevation(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Target Location Elevation'
TAG = 42
UDSKey = '-'
UDSName = ''
key = b'*'
units = 'meters'
class klvdata.misb0601.TargetLocationLatitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Target Location Latitude'
TAG = 40
UDSKey = '-'
UDSName = ''
key = b'('
units = 'degrees'
class klvdata.misb0601.TargetLocationLongitude(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Target Location Longitude'
TAG = 41
UDSKey = '-'
UDSName = ''
key = b')'
units = 'degrees'
class klvdata.misb0601.TargetTrackGateHeight(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Target Track Gate Height'
TAG = 44
UDSKey = '-'
UDSName = ''
key = b','
units = 'pixels'
class klvdata.misb0601.TargetTrackGateWidth(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'Target Track Gate Width'
TAG = 43
UDSKey = '-'
UDSName = ''
key = b'+'
units = 'pixels'
class klvdata.misb0601.TargetWidth(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Target Width'
LDSName = 'Target Width'
TAG = 22
UDSKey = '06 0E 2B 34 01 01 01 01 07 01 09 02 01 00 00 00'
UDSName = 'Target Width'
key = b'\x16'
units = 'meters'
class klvdata.misb0601.TargetWidthExtended(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Target Width'
LDSName = 'Target Width Extended'
TAG = 96
UDSKey = '06 0E 2B 34 01 01 01 01 07 01 09 02 01 00 00 00'
UDSName = 'Target Width'
key = b'`'
units = 'meters'
class klvdata.misb0601.UASLSVersionNumber(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'ESD ICD Version'
LDSName = 'UAS Datalink LS Version Number'
TAG = 65
UDSKey = '-'
UDSName = ''
key = b'A'
units = 'number'
class klvdata.misb0601.UASLocalMetadataSet(value, key_length=1)

Bases: klvdata.setparser.SetParser

MISB ST0601 UAS Local Metadata Set

key = b'\x06\x0e+4\x02\x0b\x01\x01\x0e\x01\x03\x01\x01\x00\x00\x00'
name = 'UAS Datalink Local Set'
parsers = {b'\x01': <class 'klvdata.misb0601.Checksum'>, b'\x02': <class 'klvdata.misb0601.PrecisionTimeStamp'>, b'\x03': <class 'klvdata.misb0601.MissionID'>, b'\x04': <class 'klvdata.misb0601.PlatformTailNumber'>, b'\x05': <class 'klvdata.misb0601.PlatformHeadingAngle'>, b'\x06': <class 'klvdata.misb0601.PlatformPitchAngle'>, b'\x07': <class 'klvdata.misb0601.PlatformRollAngle'>, b'\x08': <class 'klvdata.misb0601.PlatformTrueAirspeed'>, b'\t': <class 'klvdata.misb0601.PlatformIndicatedAirspeed'>, b'\n': <class 'klvdata.misb0601.PlatformDesignation'>, b'\x0b': <class 'klvdata.misb0601.ImageSourceSensor'>, b'\x0c': <class 'klvdata.misb0601.ImageCoordinateSystem'>, b'\r': <class 'klvdata.misb0601.SensorLatitude'>, b'\x0e': <class 'klvdata.misb0601.SensorLongitude'>, b'\x0f': <class 'klvdata.misb0601.SensorTrueAltitude'>, b'\x10': <class 'klvdata.misb0601.SensorHorizontalFieldOfView'>, b'\x11': <class 'klvdata.misb0601.SensorVerticalFieldOfView'>, b'\x12': <class 'klvdata.misb0601.SensorRelativeAzimuthAngle'>, b'\x13': <class 'klvdata.misb0601.SensorRelativeElevationAngle'>, b'\x14': <class 'klvdata.misb0601.SensorRelativeRollAngle'>, b'\x15': <class 'klvdata.misb0601.SlantRange'>, b'\x16': <class 'klvdata.misb0601.TargetWidth'>, b'\x17': <class 'klvdata.misb0601.FrameCenterLatitude'>, b'\x18': <class 'klvdata.misb0601.FrameCenterLongitude'>, b'\x19': <class 'klvdata.misb0601.FrameCenterElevation'>, b'\x1a': <class 'klvdata.misb0601.OffsetCornerLatitudePoint1'>, b'\x1b': <class 'klvdata.misb0601.OffsetCornerLongitudePoint1'>, b'\x1c': <class 'klvdata.misb0601.OffsetCornerLatitudePoint2'>, b'\x1d': <class 'klvdata.misb0601.OffsetCornerLongitudePoint2'>, b'\x1e': <class 'klvdata.misb0601.OffsetCornerLatitudePoint3'>, b'\x1f': <class 'klvdata.misb0601.OffsetCornerLongitudePoint3'>, b' ': <class 'klvdata.misb0601.OffsetCornerLatitudePoint4'>, b'!': <class 'klvdata.misb0601.OffsetCornerLongitudePoint4'>, b'"': <class 'klvdata.misb0601.IcingDetected'>, b'#': <class 'klvdata.misb0601.WindDirection'>, b'$': <class 'klvdata.misb0601.WindSpeed'>, b'%': <class 'klvdata.misb0601.StaticPressure'>, b'&': <class 'klvdata.misb0601.DensityAltitude'>, b"'": <class 'klvdata.misb0601.OutsideAirTemperature'>, b'(': <class 'klvdata.misb0601.TargetLocationLatitude'>, b')': <class 'klvdata.misb0601.TargetLocationLongitude'>, b'*': <class 'klvdata.misb0601.TargetLocationElevation'>, b'+': <class 'klvdata.misb0601.TargetTrackGateWidth'>, b',': <class 'klvdata.misb0601.TargetTrackGateHeight'>, b'-': <class 'klvdata.misb0601.TargetErrorEstimateCE90'>, b'.': <class 'klvdata.misb0601.TargetErrorEstimateLE90'>, b'/': <class 'klvdata.misb0601.GenericFlagData01'>, b'0': <class 'klvdata.misb0102.SecurityLocalMetadataSet'>, b'1': <class 'klvdata.misb0601.DifferentialPressure'>, b'2': <class 'klvdata.misb0601.PlatformAngleOfAttack'>, b'3': <class 'klvdata.misb0601.PlatformVerticalSpeed'>, b'4': <class 'klvdata.misb0601.PlatformSideslipAngle'>, b'5': <class 'klvdata.misb0601.AirfieldBarometricPressure'>, b'6': <class 'klvdata.misb0601.AirfieldElevation'>, b'7': <class 'klvdata.misb0601.RelativeHumidity'>, b'8': <class 'klvdata.misb0601.PlatformGroundSpeed'>, b'9': <class 'klvdata.misb0601.GroundRange'>, b':': <class 'klvdata.misb0601.PlatformFuelRemaining'>, b';': <class 'klvdata.misb0601.PlatformCallSign'>, b'<': <class 'klvdata.misb0601.WeaponLoad'>, b'=': <class 'klvdata.misb0601.WeaponFired'>, b'>': <class 'klvdata.misb0601.LaserPRFCode'>, b'?': <class 'klvdata.misb0601.SensorFieldOfViewName'>, b'@': <class 'klvdata.misb0601.PlatformMagneticHeading'>, b'A': <class 'klvdata.misb0601.UASLSVersionNumber'>, b'C': <class 'klvdata.misb0601.AlternatePlatformLatitude'>, b'D': <class 'klvdata.misb0601.AlternatePlatformLongitude'>, b'E': <class 'klvdata.misb0601.AlternatePlatformAltitude'>, b'F': <class 'klvdata.misb0601.AlternatePlatformName'>, b'G': <class 'klvdata.misb0601.AlternatePlatformHeading'>, b'H': <class 'klvdata.misb0601.EventStartTime'>, b'I': <class 'klvdata.misb0601.RVTLocalSet'>, b'J': <class 'klvdata.misb0601.VMTILocalSet'>, b'K': <class 'klvdata.misb0601.SensorEllipsoidHeightConversion'>, b'L': <class 'klvdata.misb0601.AlternatePlatformEllipsoidHeight'>, b'M': <class 'klvdata.misb0601.OperationalMode'>, b'N': <class 'klvdata.misb0601.FrameCenterHeightAboveEllipsoid'>, b'O': <class 'klvdata.misb0601.SensorNorthVelocity'>, b'P': <class 'klvdata.misb0601.SensorEastVelocity'>, b'R': <class 'klvdata.misb0601.CornerLatitudePoint1Full'>, b'S': <class 'klvdata.misb0601.CornerLongitudePoint1Full'>, b'T': <class 'klvdata.misb0601.CornerLatitudePoint2Full'>, b'U': <class 'klvdata.misb0601.CornerLongitudePoint2Full'>, b'V': <class 'klvdata.misb0601.CornerLatitudePoint3Full'>, b'W': <class 'klvdata.misb0601.CornerLongitudePoint3Full'>, b'X': <class 'klvdata.misb0601.CornerLatitudePoint4Full'>, b'Y': <class 'klvdata.misb0601.CornerLongitudePoint4Full'>, b'Z': <class 'klvdata.misb0601.PlatformPitchAngleFull'>, b'[': <class 'klvdata.misb0601.PlatformRollAngleFull'>, b'\\': <class 'klvdata.misb0601.PlatformAngleOfAttackFull'>, b']': <class 'klvdata.misb0601.PlatformSideslipAngleFull'>, b'`': <class 'klvdata.misb0601.TargetWidthExtended'>, b'g': <class 'klvdata.misb0601.DensityAltitudeExtended'>, b'h': <class 'klvdata.misb0601.SensorEllipsoidHeightExtended'>, b'i': <class 'klvdata.misb0601.AlternatePlatformEllipsoidHeightExtended'>}
class klvdata.misb0601.UnknownElement(key, value)

Bases: klvdata.element.UnknownElement

class klvdata.misb0601.VMTILocalSet(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = ''
LDSName = 'VMTI Local Set'
TAG = 74
UDSKey = '06 0E 2B 34 02 0B 01 01 0E 01 03 03 06 00 00 00'
UDSName = 'Video Moving Target Indicator Local Set'
key = b'J'
class klvdata.misb0601.WeaponFired(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Weapon Fired'
LDSName = 'Weapon Fired'
TAG = 61
UDSKey = '-'
UDSName = ''
key = b'='
class klvdata.misb0601.WeaponLoad(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Weapon Load'
LDSName = 'Weapon Load'
TAG = 60
UDSKey = '-'
UDSName = ''
key = b'<'
class klvdata.misb0601.WindDirection(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Wind Direction'
LDSName = 'Wind Direction'
TAG = 35
UDSKey = '-'
UDSName = ''
key = b'#'
units = 'meters/second'
class klvdata.misb0601.WindSpeed(value)

Bases: klvdata.elementparser.MappedElementParser

ESDName = 'Wind Speed'
LDSName = 'Wind Speed'
TAG = 36
UDSKey = '-'
UDSName = ''
key = b'$'
units = 'meters/second'

klvdata.setparser module

class klvdata.setparser.SetParser(value, key_length=1)

Bases: klvdata.element.Element

Parsable Element. Not intended to be used directly. Always as super class.

MetadataList()

Return metadata dictionary

classmethod add_parser(obj)

Decorator method used to register a parser to the class parsing repertoire.

obj is required to implement key attribute supporting bytes as returned by KLVParser key.

parse()

Parse the parent into items. Called on init and modification of parent value.

If a known parser is not available for key, parse as generic KLV element.

abstract property parsers

classmethod(function) -> method

Convert a function to be a class method.

A class method receives the class as implicit first argument, just like an instance method receives the instance. To declare a class method, use this idiom:

class C:

@classmethod def f(cls, arg1, arg2, …):

It can be called either on the class (e.g. C.f()) or on an instance (e.g. C().f()). The instance is ignored except for its class. If a class method is called for a derived class, the derived class object is passed as the implied first argument.

Class methods are different than C++ or Java static methods. If you want those, see the staticmethod builtin.

structure()
klvdata.setparser.str_dict(values)

klvdata.streamparser module

class klvdata.streamparser.StreamParser(source)

Bases: object

classmethod add_parser(obj)

Decorator method used to register a parser to the class parsing repertoire.

obj is required to implement key attribute supporting bytes as returned by KLVParser key.

parsers = {b'\x06\x0e+4\x02\x0b\x01\x01\x0e\x01\x03\x01\x01\x00\x00\x00': <class 'klvdata.misb0601.UASLocalMetadataSet'>}

Module contents