def __init__( self, frame='', max_speed=20, max_accel=30, wheelbase=0.335, wheeltrack=0.296, max_wheel_turn=35, turning_circle=1.8, skid_turn_rate=140, # degrees/sec skid_steering=False): Aircraft.__init__(self) self.max_speed = max_speed self.max_accel = max_accel self.turning_circle = turning_circle self.wheelbase = wheelbase self.wheeltrack = wheeltrack self.max_wheel_turn = max_wheel_turn self.last_time = self.time_now self.skid_steering = skid_steering self.skid_turn_rate = skid_turn_rate if self.skid_steering: # these are taken from a 6V wild thumper with skid steering, # with a sabertooth controller self.max_accel = 14 self.max_speed = 4
def __init__(self, frame='+', hover_throttle=0.65, terminal_velocity=40.0, frame_height=0.1, hover_lean=8.0, yaw_zero=0.1, rotor_rot_accel=radians(20), mass=2.13): Aircraft.__init__(self) self.mass = mass # Kg self.hover_throttle = hover_throttle self.terminal_velocity = terminal_velocity self.terminal_rotation_rate = 4 * radians(360.0) self.frame_height = frame_height self.last_time = time.time() self.roll_rate_max = radians(1400) self.pitch_rate_max = radians(1400) self.yaw_rate_max = radians(1400) self.rsc_setpoint = 0.8 self.thrust_scale = (self.mass * self.gravity) / self.hover_throttle self.rotor_rot_accel = rotor_rot_accel # calculate lateral thrust ratio for tail rotor self.tail_thrust_scale = sin( radians(hover_lean)) * self.thrust_scale / yaw_zero
def __init__(self, max_speed=2, max_accel=1.5, wheelbase=1.8, wheeltrack=1.3, max_wheel_turn=35, turning_circle=5, skid_turn_rate=9, # degrees/sec accel_by_pds = 4.46, # m/s^2 accel_by_enge = 1.12, accel_by_idle = 0.45, skid_steering=False): Aircraft.__init__(self) self.max_speed = max_speed self.max_accel = max_accel self.turning_circle = turning_circle self.wheelbase = wheelbase self.wheeltrack = wheeltrack self.max_wheel_turn = max_wheel_turn self.last_time = time.time() self.skid_steering = skid_steering self.skid_turn_rate = skid_turn_rate self.accel_by_pds = accel_by_pds self.accel_by_enge = accel_by_enge self.accel_by_idle = accel_by_idle if self.skid_steering: # these are taken from a 6V wild thumper with skid steering, # with a sabertooth controller self.max_accel = 14 self.max_speed = 4
def __init__(self, frame='', max_speed=20, max_accel=30, wheelbase=0.335, wheeltrack=0.296, max_wheel_turn=35, turning_circle=1.8, skid_turn_rate=140, # degrees/sec skid_steering=False): Aircraft.__init__(self) self.max_speed = max_speed self.max_accel = max_accel self.turning_circle = turning_circle self.wheelbase = wheelbase self.wheeltrack = wheeltrack self.max_wheel_turn = max_wheel_turn self.last_time = self.time_now self.skid_steering = skid_steering self.skid_turn_rate = skid_turn_rate if self.skid_steering: # these are taken from a 6V wild thumper with skid steering, # with a sabertooth controller self.max_accel = 14 self.max_speed = 4
def __init__(self, max_speed=10, max_accel=10, max_turn_rate=45): Aircraft.__init__(self) self.max_speed = max_speed self.max_accel = max_accel self.max_turn_rate = max_turn_rate self.last_time = time.time()
def __init__(self, max_speed=10, max_accel=10, max_turn_rate=45, skid_steering=False): Aircraft.__init__(self) self.max_speed = max_speed self.max_accel = max_accel self.max_turn_rate = max_turn_rate self.last_time = time.time() self.skid_steering = skid_steering
def __init__(self, max_speed=13, max_accel=10, max_turn_rate=100, skid_steering=False): Aircraft.__init__(self) self.max_speed = max_speed self.max_accel = max_accel self.max_turn_rate = max_turn_rate self.last_time = time.time() self.skid_steering = skid_steering
def __init__(self, frame="+", hover_throttle=0.65, terminal_velocity=40.0, frame_height=0.1, mass=2.5): Aircraft.__init__(self) self.mass = mass # Kg self.hover_throttle = hover_throttle self.terminal_velocity = terminal_velocity self.terminal_rotation_rate = 4 * radians(360.0) self.frame_height = frame_height self.last_time = time.time() self.roll_rate_max = radians(720) self.pitch_rate_max = radians(720) self.yaw_rate_max = radians(720) self.rsc_setpoint = 0.8 self.thrust_scale = (self.mass * self.gravity) / self.hover_throttle
def __init__(self): Aircraft.__init__(self) self.motor_speed = [ 0.0, 0.0, 0.0, 0.0 ] self.mass = 1.0 # Kg self.hover_throttle = 0.37 self.terminal_velocity = 30.0 self.frame_height = 0.1 # scaling from total motor power to Newtons. Allows the copter # to hover against gravity when each motor is at hover_throttle self.thrust_scale = (self.mass * self.gravity) / (4.0 * self.hover_throttle) self.last_time = time.time()
def __init__(self, frame="generic"): Aircraft.__init__(self) self.sim = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) self.sim.connect(('127.0.0.1', 9002)) self.sim.setblocking(0) self.accel_body = Vector3(0, 0, -self.gravity) self.frame = frame self.last_timestamp = 0 if self.frame.find("heli") != -1: self.decode_servos = self.decode_servos_heli else: self.decode_servos = self.decode_servos_fixed_wing
def __init__(self, frame="+", hover_throttle=0.37, terminal_velocity=30.0, frame_height=0.1, mass=1.0): Aircraft.__init__(self) self.motors = build_motors(frame) self.motor_speed = [0.0] * len(self.motors) self.mass = mass # Kg self.hover_throttle = hover_throttle self.terminal_velocity = terminal_velocity self.terminal_rotation_rate = 4 * radians(360.0) self.frame_height = frame_height # scaling from total motor power to Newtons. Allows the copter # to hover against gravity when each motor is at hover_throttle self.thrust_scale = (self.mass * self.gravity) / (len(self.motors) * self.hover_throttle) self.last_time = time.time()
def __init__(self, max_speed=20, max_accel=30, wheelbase=0.335, wheeltrack=0.296, max_wheel_turn=35, turning_circle=1.8, skid_steering=False): Aircraft.__init__(self) self.max_speed = max_speed self.max_accel = max_accel self.turning_circle = turning_circle self.wheelbase = wheelbase self.wheeltrack = wheeltrack self.max_wheel_turn = max_wheel_turn self.last_time = time.time() self.skid_steering = skid_steering
def __init__(self, frame='+', hover_throttle=0.65, terminal_velocity=40.0, frame_height=0.1, mass=2.5): Aircraft.__init__(self) self.mass = mass # Kg self.hover_throttle = hover_throttle self.terminal_velocity = terminal_velocity self.terminal_rotation_rate = 4*radians(360.0) self.frame_height = frame_height self.last_time = time.time() self.roll_rate_max = radians(720) self.pitch_rate_max = radians(720) self.yaw_rate_max = radians(720) self.rsc_setpoint = 0.8 self.thrust_scale = (self.mass * self.gravity) / self.hover_throttle
def __init__(self): Aircraft.__init__(self) self.max_rpm = 1200 self.have_new_time = False self.have_new_imu = False self.have_new_pos = False topics = { "/clock": (self.clock_cb, rosgraph_msgs.Clock), "/iris/imu": (self.imu_cb, sensor_msgs.Imu), "/iris/vehicle_local_position": (self.pos_cb, px4.vehicle_local_position), } rospy.init_node("ArduPilot", anonymous=True) for topic in topics.keys(): (callback, msgtype) = topics[topic] rospy.Subscriber(topic, msgtype, callback) self.motor_pub = rospy.Publisher("/iris/command/motor_speed", mav_msgs.CommandMotorSpeed, queue_size=1) self.last_time = 0
def __init__(self, rate_controlled=False, pitch_range = 45, yaw_range = 180, zero_yaw = 270, # yaw direction at startup zero_pitch = 10, # pitch at startup turn_rate=20 # servo max turn rate in degrees/sec ): Aircraft.__init__(self) self.rate_controlled = rate_controlled self.turn_rate = turn_rate self.last_time = time.time() self.pitch_range = pitch_range self.yaw_range = yaw_range self.zero_yaw = zero_yaw self.zero_pitch = zero_pitch self.verbose = False self.last_debug = time.time() self.pitch_current = 0 self.yaw_current = 0
def __init__(self, frame='+', hover_throttle=0.45, terminal_velocity=15.0, frame_height=0.1, mass=1.5): Aircraft.__init__(self) self.motors = build_motors(frame) self.motor_speed = [0.0] * len(self.motors) self.mass = mass # Kg self.hover_throttle = hover_throttle self.terminal_velocity = terminal_velocity self.terminal_rotation_rate = 4 * radians(360.0) self.frame_height = frame_height # scaling from total motor power to Newtons. Allows the copter # to hover against gravity when each motor is at hover_throttle self.thrust_scale = (self.mass * self.gravity) / (len(self.motors) * self.hover_throttle) self.last_time = self.time_now
def __init__(self, onoff=False, yawrate=9.0, pitchrate=1.0, pitch_range = 45, yaw_range = 170, zero_yaw = 270, # yaw direction at startup zero_pitch = 10 # pitch at startup ): Aircraft.__init__(self) self.onoff = onoff self.yawrate = yawrate self.pitchrate = pitchrate self.last_time = time.time() self.pitch_range = pitch_range self.yaw_range = yaw_range self.zero_yaw = zero_yaw self.zero_pitch = zero_pitch self.verbose = False self.last_debug = time.time() self.pitch_current = 0 self.yaw_current = 0
def __init__( self, onoff=False, yawrate=9.0, pitchrate=1.0, pitch_range=45, yaw_range=170, zero_yaw=270, # yaw direction at startup zero_pitch=10 # pitch at startup ): Aircraft.__init__(self) self.onoff = onoff self.yawrate = yawrate self.pitchrate = pitchrate self.last_time = time.time() self.pitch_range = pitch_range self.yaw_range = yaw_range self.zero_yaw = zero_yaw self.zero_pitch = zero_pitch self.verbose = False self.last_debug = time.time() self.pitch_current = 0 self.yaw_current = 0
def __init__(self): Aircraft.__init__(self) self.max_rpm = 1200 self.have_new_time = False self.have_new_imu = False self.have_new_pos = False topics = { "/clock": (self.clock_cb, rosgraph_msgs.Clock), "/iris/imu": (self.imu_cb, sensor_msgs.Imu), "/iris/vehicle_local_position": (self.pos_cb, px4.vehicle_local_position), } rospy.init_node('ArduPilot', anonymous=True) for topic in topics.keys(): (callback, msgtype) = topics[topic] rospy.Subscriber(topic, msgtype, callback) self.motor_pub = rospy.Publisher('/iris/command/motor_speed', mav_msgs.CommandMotorSpeed, queue_size=1) self.last_time = 0
def __init__(self, frame='+', hover_throttle=0.65, terminal_velocity=40.0, frame_height=0.1, hover_lean=8.0, yaw_zero=0.1, rotor_rot_accel=radians(20), mass=2.13): Aircraft.__init__(self) self.mass = mass # Kg self.hover_throttle = hover_throttle self.terminal_velocity = terminal_velocity self.terminal_rotation_rate = 4*radians(360.0) self.frame_height = frame_height self.last_time = time.time() self.roll_rate_max = radians(1400) self.pitch_rate_max = radians(1400) self.yaw_rate_max = radians(1400) self.rsc_setpoint = 0.8 self.thrust_scale = (self.mass * self.gravity) / self.hover_throttle self.rotor_rot_accel=rotor_rot_accel # calculate lateral thrust ratio for tail rotor self.tail_thrust_scale = sin(radians(hover_lean)) * self.thrust_scale / yaw_zero
def __init__(self, max_ammo, base_damage): Aircraft.__init__(self, max_ammo, base_damage)