From 74e7db1f43d5511da291050f2ddd5d701bb04258 Mon Sep 17 00:00:00 2001 From: nonailla Date: Wed, 8 Jun 2022 15:45:25 +0200 Subject: tnkrjrf --- robot/mode_chrg.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'robot/mode_chrg.c') diff --git a/robot/mode_chrg.c b/robot/mode_chrg.c index 5b733af..7cf9a9c 100644 --- a/robot/mode_chrg.c +++ b/robot/mode_chrg.c @@ -4,7 +4,7 @@ #include "movement.h" #include "orangutan_shim.h" -int g_w2_charged_status; +int g_w2_charged_status; //used to detect the charging station (once) void w2_short_drive() { set_motors(50, 50); @@ -12,6 +12,7 @@ void w2_short_drive() { set_motors(0, 0); } +//charging station void w2_home() { set_motors(0, 0); delay_ms(150); @@ -28,6 +29,7 @@ void w2_home() { delay_ms(2000); } +//crosswalk from charging station back to maze void w2_charge_cross_walk() { if (g_w2_transition == 0) { set_motors(-30, 30); @@ -59,6 +61,7 @@ void w2_charge_cross_walk() { } } +//main function for charge mode void w2_mode_chrg() { unsigned int last_proportional = 0; long integral = 0; -- cgit v1.2.3