From f9f01dca55a0458e7881dabe053e022a3660a386 Mon Sep 17 00:00:00 2001 From: Silver Kuusik Date: Mon, 4 Feb 2019 20:46:12 +0100 Subject: [PATCH] add line value and threshold --- main.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index fa4440f..27ca974 100755 --- a/main.py +++ b/main.py @@ -17,10 +17,14 @@ def step(): sumorobot.is_line(RIGHT) # Update scope scope = dict( - line_left = sumorobot.get_line(LEFT), - line_right = sumorobot.get_line(RIGHT), + left_line = sumorobot.get_line(LEFT), + right_line = sumorobot.get_line(RIGHT), opponent = sumorobot.get_opponent_distance(), battery_voltage = sumorobot.get_battery_voltage(), + left_line_value = sumorobot.config["left_line_value"], + right_line_value = sumorobot.config["right_line_value"], + left_line_threshold = sumorobot.config["left_line_threshold"], + right_line_threshold = sumorobot.config["right_line_threshold"] ) # Execute code try: