serialize method

  1. @override
ByteData serialize()
override

Implementation

@override
ByteData serialize() {
  var data_ = ByteData(mavlinkEncodedLength);
  data_.setUint64(0, status, Endian.little);
  data_.setFloat32(8, batteryCurrent, Endian.little);
  data_.setFloat32(12, loadCurrent, Endian.little);
  data_.setFloat32(16, powerGenerated, Endian.little);
  data_.setFloat32(20, busVoltage, Endian.little);
  data_.setFloat32(24, batCurrentSetpoint, Endian.little);
  data_.setUint32(28, runtime, Endian.little);
  data_.setInt32(32, timeUntilMaintenance, Endian.little);
  data_.setUint16(36, generatorSpeed, Endian.little);
  data_.setInt16(38, rectifierTemperature, Endian.little);
  data_.setInt16(40, generatorTemperature, Endian.little);
  return data_;
}