summaryrefslogtreecommitdiffstats
path: root/Kod/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'Kod/scripts')
-rw-r--r--Kod/scripts/test_givare.m20
1 files changed, 5 insertions, 15 deletions
diff --git a/Kod/scripts/test_givare.m b/Kod/scripts/test_givare.m
index 5ad8afd..726fe82 100644
--- a/Kod/scripts/test_givare.m
+++ b/Kod/scripts/test_givare.m
@@ -26,6 +26,10 @@ while 1
[car1.new_lap, car1.new_check_point, car1.time] = get_car_position(1);
[car2.new_lap, car2.new_check_point, car2.time] = get_car_position(2);
+ if car1.new_lap || car1.new_check_point == true || car2.new_lap == true || car2.new_check_point == true
+ disp('###')
+ end
+
if car1.new_check_point
beep;
disp('car 1 cp')
@@ -42,22 +46,8 @@ while 1
beep;
disp('car 2 lap')
end
- % KOMPENSERA FÖR TRASIG BANA
- if car1.new_lap && car2.new_check_point
- car2.new_lap = 0;
- end
- pause(0.1)
-
- if car2.new_lap
- disp('NEW LAP CAR 2!')
- end
- if car2.new_check_point
- disp('NEW CHECKPOINT CAR 2!')
- end
-
pause(0.1)
end
-
%%
terminate(1)
-terminate(2) \ No newline at end of file
+terminate(2)