Statustext.parse constructor
Statustext.parse(
- ByteData data_
Implementation
factory Statustext.parse(ByteData data_) {
if (data_.lengthInBytes < Statustext.mavlinkEncodedLength) {
var len = Statustext.mavlinkEncodedLength - data_.lengthInBytes;
var d = data_.buffer.asUint8List() + List<int>.filled(len, 0);
data_ = Uint8List.fromList(d).buffer.asByteData();
}
var severity = data_.getUint8(0);
var text = MavlinkMessage.asInt8List(data_, 1, 50);
var id = data_.getUint16(51, Endian.little);
var chunkSeq = data_.getUint8(53);
return Statustext(
severity: severity, text: text, id: id, chunkSeq: chunkSeq);
}