serialize method

  1. @override
ByteData serialize()
override

Implementation

@override
ByteData serialize() {
  var data_ = ByteData(mavlinkEncodedLength);
  data_.setFloat32(0, magDeclination, Endian.little);
  data_.setInt32(4, rawPress, Endian.little);
  data_.setInt32(8, rawTemp, Endian.little);
  data_.setFloat32(12, gyroCalX, Endian.little);
  data_.setFloat32(16, gyroCalY, Endian.little);
  data_.setFloat32(20, gyroCalZ, Endian.little);
  data_.setFloat32(24, accelCalX, Endian.little);
  data_.setFloat32(28, accelCalY, Endian.little);
  data_.setFloat32(32, accelCalZ, Endian.little);
  data_.setInt16(36, magOfsX, Endian.little);
  data_.setInt16(38, magOfsY, Endian.little);
  data_.setInt16(40, magOfsZ, Endian.little);
  return data_;
}