MessageInterval.parse constructor
MessageInterval.parse(
- ByteData data_
Implementation
factory MessageInterval.parse(ByteData data_) {
if (data_.lengthInBytes < MessageInterval.mavlinkEncodedLength) {
var len = MessageInterval.mavlinkEncodedLength - data_.lengthInBytes;
var d = data_.buffer.asUint8List() + List<int>.filled(len, 0);
data_ = Uint8List.fromList(d).buffer.asByteData();
}
var intervalUs = data_.getInt32(0, Endian.little);
var messageId = data_.getUint16(4, Endian.little);
return MessageInterval(intervalUs: intervalUs, messageId: messageId);
}