code: def cmd_rccal(self, args):
          '''start/stop RC calibration'''
          if len(args) < 1:
              self.print_cal_usage()
              return
  
          if (args[0] == "start"):
              if len(args) > 1:
                  self.num_channels = int(args[1])
              print("Calibrating %u channels" % self.num_channels)
              print("WARNING: remove propellers from electric planes!!")
              print("Push return when ready to calibrate.")
              raw_input()
  
              self.clear_rc_cal()
              self.calibrating = True
          elif (args[0] == "done"):
              self.calibrating = False
              self.apply_rc_cal()
          else:
              self.print_cal_usage(f cmd_rccal(self, args):
          '''start/stop RC calibration'''
          if len(args) < 1:
              self.print_cal_usage()
              return
  
          if (args[0] == "start"):
              if len(args) > 1:
                  self.num_channels = int(args[1])
              print("Calibrating %u channels" % self.num_channels)
              print("WARNING: remove propellers from electric planes!!")
              print("Push return when ready to calibrate.")
              raw_input()
  
              self.clear_rc_cal()
              self.calibrating = True
          elif (args[0] == "done"):
              self.calibrating = False
              self.apply_rc_cal()
          else:
              self.print_cal_usage()
docs: start/stop RC calibration