CameraTrackingGeoStatus.parse constructor
CameraTrackingGeoStatus.parse(
- ByteData data_
Implementation
factory CameraTrackingGeoStatus.parse(ByteData data_) {
if (data_.lengthInBytes < CameraTrackingGeoStatus.mavlinkEncodedLength) {
var len =
CameraTrackingGeoStatus.mavlinkEncodedLength - data_.lengthInBytes;
var d = data_.buffer.asUint8List() + List<int>.filled(len, 0);
data_ = Uint8List.fromList(d).buffer.asByteData();
}
var lat = data_.getInt32(0, Endian.little);
var lon = data_.getInt32(4, Endian.little);
var alt = data_.getFloat32(8, Endian.little);
var hAcc = data_.getFloat32(12, Endian.little);
var vAcc = data_.getFloat32(16, Endian.little);
var velN = data_.getFloat32(20, Endian.little);
var velE = data_.getFloat32(24, Endian.little);
var velD = data_.getFloat32(28, Endian.little);
var velAcc = data_.getFloat32(32, Endian.little);
var dist = data_.getFloat32(36, Endian.little);
var hdg = data_.getFloat32(40, Endian.little);
var hdgAcc = data_.getFloat32(44, Endian.little);
var trackingStatus = data_.getUint8(48);
return CameraTrackingGeoStatus(
lat: lat,
lon: lon,
alt: alt,
hAcc: hAcc,
vAcc: vAcc,
velN: velN,
velE: velE,
velD: velD,
velAcc: velAcc,
dist: dist,
hdg: hdg,
hdgAcc: hdgAcc,
trackingStatus: trackingStatus);
}