public override void ParseData(List<byte> data)
 {
     Data = ControllerData.FromBytes(data);
 }
 public SetControllerData(KFlyCommandType setControllerType, ControllerData data)
     : base(setControllerType)
 {
     Data = data;
 }
 public static ControllerData FromBytes(List<byte> bytes)
 {
     var c = new ControllerData();
     c.SetBytes(bytes);
     return c;
 }
 public SetControllerData(KFlyCommandType setControllerType)
     : base(setControllerType)
 {
     Data = new ControllerData();
 }
Exemple #5
0
 private ControllerData GetRateControllerData()
 {
     ControllerData cd = new ControllerData();
     cd.Pitch.PGain = (float)rate_pkp.Value;
     cd.Pitch.IGain = (float)rate_pki.Value;
     cd.Pitch.ILimit = (float)rate_pil.Value;
     cd.Roll.PGain = (float)rate_rkp.Value;
     cd.Roll.IGain = (float)rate_rki.Value;
     cd.Roll.ILimit = (float)rate_ril.Value;
     cd.Yaw.PGain = (float)rate_ykp.Value;
     cd.Yaw.IGain = (float)rate_yki.Value;
     cd.Yaw.ILimit = (float)rate_yil.Value;
     return cd;
 }