SerialUdbExtraF8.parse constructor
SerialUdbExtraF8.parse(
- ByteData data_
Implementation
factory SerialUdbExtraF8.parse(ByteData data_) {
if (data_.lengthInBytes < SerialUdbExtraF8.mavlinkEncodedLength) {
var len = SerialUdbExtraF8.mavlinkEncodedLength - data_.lengthInBytes;
var d = data_.buffer.asUint8List() + List<int>.filled(len, 0);
data_ = Uint8List.fromList(d).buffer.asByteData();
}
var sueHeightTargetMax = data_.getFloat32(0, Endian.little);
var sueHeightTargetMin = data_.getFloat32(4, Endian.little);
var sueAltHoldThrottleMin = data_.getFloat32(8, Endian.little);
var sueAltHoldThrottleMax = data_.getFloat32(12, Endian.little);
var sueAltHoldPitchMin = data_.getFloat32(16, Endian.little);
var sueAltHoldPitchMax = data_.getFloat32(20, Endian.little);
var sueAltHoldPitchHigh = data_.getFloat32(24, Endian.little);
return SerialUdbExtraF8(
sueHeightTargetMax: sueHeightTargetMax,
sueHeightTargetMin: sueHeightTargetMin,
sueAltHoldThrottleMin: sueAltHoldThrottleMin,
sueAltHoldThrottleMax: sueAltHoldThrottleMax,
sueAltHoldPitchMin: sueAltHoldPitchMin,
sueAltHoldPitchMax: sueAltHoldPitchMax,
sueAltHoldPitchHigh: sueAltHoldPitchHigh);
}