serialize method

  1. @override
ByteData serialize()
override

Implementation

@override
ByteData serialize() {
  var data_ = ByteData(mavlinkEncodedLength);
  data_.setFloat32(0, ecuIndex, Endian.little);
  data_.setFloat32(4, rpm, Endian.little);
  data_.setFloat32(8, fuelConsumed, Endian.little);
  data_.setFloat32(12, fuelFlow, Endian.little);
  data_.setFloat32(16, engineLoad, Endian.little);
  data_.setFloat32(20, throttlePosition, Endian.little);
  data_.setFloat32(24, sparkDwellTime, Endian.little);
  data_.setFloat32(28, barometricPressure, Endian.little);
  data_.setFloat32(32, intakeManifoldPressure, Endian.little);
  data_.setFloat32(36, intakeManifoldTemperature, Endian.little);
  data_.setFloat32(40, cylinderHeadTemperature, Endian.little);
  data_.setFloat32(44, ignitionTiming, Endian.little);
  data_.setFloat32(48, injectionTime, Endian.little);
  data_.setFloat32(52, exhaustGasTemperature, Endian.little);
  data_.setFloat32(56, throttleOut, Endian.little);
  data_.setFloat32(60, ptCompensation, Endian.little);
  data_.setUint8(64, health);
  data_.setFloat32(65, ignitionVoltage, Endian.little);
  data_.setFloat32(69, fuelPressure, Endian.little);
  return data_;
}