summaryrefslogtreecommitdiff
path: root/i/marvin/src/motor
diff options
context:
space:
mode:
Diffstat (limited to 'i/marvin/src/motor')
-rw-r--r--i/marvin/src/motor/motor.cc8
-rw-r--r--i/marvin/src/motor/motor.hh2
2 files changed, 10 insertions, 0 deletions
diff --git a/i/marvin/src/motor/motor.cc b/i/marvin/src/motor/motor.cc
index af3d29f..2664df0 100644
--- a/i/marvin/src/motor/motor.cc
+++ b/i/marvin/src/motor/motor.cc
@@ -30,6 +30,14 @@ Motor::Motor (void)
{
}
+/// Reset.
+void
+Motor::reset (void)
+{
+ finish_ = false;
+ asserv_.reset ();
+}
+
/// Linear and angular move. T(mm) is the linear distance. A(mm) is the
/// angular distance which means the arc length.
void
diff --git a/i/marvin/src/motor/motor.hh b/i/marvin/src/motor/motor.hh
index 509ed8b..5770ebb 100644
--- a/i/marvin/src/motor/motor.hh
+++ b/i/marvin/src/motor/motor.hh
@@ -54,6 +54,8 @@ class Motor : public Asserv::Receiver
void findHole (void);
/// Stop now.
void stop (void);
+ /// Reset.
+ void reset (void);
private:
/// Next seq number.
inline void nextSeq (void);