From 176f636ba105d6bab25c7a49e6d80e180b4bfd27 Mon Sep 17 00:00:00 2001 From: Artem30801 Date: Sat, 19 Jan 2019 20:28:14 +0300 Subject: [PATCH] Few minifixes --- Drone/{drone.csv => copter6349.csv} | 0 Drone/play_animation.py | 8 ++++---- 2 files changed, 4 insertions(+), 4 deletions(-) rename Drone/{drone.csv => copter6349.csv} (100%) diff --git a/Drone/drone.csv b/Drone/copter6349.csv similarity index 100% rename from Drone/drone.csv rename to Drone/copter6349.csv diff --git a/Drone/play_animation.py b/Drone/play_animation.py index cc4686e..6289e8b 100644 --- a/Drone/play_animation.py +++ b/Drone/play_animation.py @@ -8,9 +8,9 @@ animation_file_path = 'drone.csv' frames = [] -def takeoff(): +def takeoff(h=1.75): LedLib.wipe_to(0, 255, 0) - FlightLib.takeoff(1.75) + FlightLib.takeoff(h) def land(): @@ -29,8 +29,8 @@ def do_next_animation(current_frame): ) -def read_animation_file(): - with open(animation_file_path) as animation_file: +def read_animation_file(filepath=animation_file_path): + with open(filepath) as animation_file: csv_reader = csv.reader( animation_file, delimiter=',', quotechar='|' )