# get baseline for acceleration base_acc = baseline_acceleration() last_baseline = datetime.now() while True: # Log data to Senselogg sense_logger.log_data() # show a random animation animation.show_animation() # find thrust thrust_status = find_thrust(base_acc) if thrust_status: logger.log_thrust() # find orientation using yaw orientation = find_orientation_by_yaw() if (orientation != base_orientation_yaw): logger.log_orientation(orientation) base_orientation_yaw = orientation # find orientation using roll orientation = find_orientation_by_roll() if (orientation != base_orientation_roll): logger.log_orientation(orientation) base_orientation_roll = orientation # find compass compass = find_compass()
# show astronaut animation animation.show_astronaut(astronaut_status) # show a trick question, facts or fun text.show_text() # Log raw sensordata to senselogg senselogger.log_data() # find thrust, orientations, compass and log to datalogg # find thrust thrust_status = find_thrust(base_acc) if thrust_status: datalogger.log_thrust() # find orientation using yaw orientation = find_orientation_by_yaw() if (orientation != base_orientation_yaw): datalogger.log_orientation(orientation) base_orientation_yaw = orientation # find orientation using roll orientation = find_orientation_by_roll() if (orientation != base_orientation_roll): datalogger.log_orientation(orientation) base_orientation_roll = orientation # find compass compass = find_compass()