From 9a29545859c8513e48b813804b6fc1ea3ec3aa24 Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Sun, 21 Apr 2013 18:42:49 +0200 Subject: digital/io-hub/src/apbirthday: add follow the cake demo mode --- digital/io-hub/src/apbirthday/robot.cc | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'digital/io-hub/src/apbirthday/robot.cc') diff --git a/digital/io-hub/src/apbirthday/robot.cc b/digital/io-hub/src/apbirthday/robot.cc index 76a26d7a..7137ea3e 100644 --- a/digital/io-hub/src/apbirthday/robot.cc +++ b/digital/io-hub/src/apbirthday/robot.cc @@ -218,6 +218,12 @@ Robot::proto_handle (ucoo::Proto &proto, char cmd, const uint8_t *args, int size // Enter FSM debug mode, then step once. fsm_debug_state_ = FSM_DEBUG_STEP; break; + case c ('d', 2): + // Demo mode. + // 1B: 'f for follow mode. + // 1B: 00 for clockwise, 01 for anti-clockwise + top_demo_follow (args[0] == 1 ? 1 : -1); + break; case c ('m', 5): // Go to position. // 2H: x, y. -- cgit v1.2.3