summaryrefslogtreecommitdiff
path: root/2003/i/buzz/src/busp/busp_servo.h
diff options
context:
space:
mode:
authorschodet2003-05-05 19:20:25 +0000
committerschodet2003-05-05 19:20:25 +0000
commite5deeadfcd0dc50f607e388712f6d349a36c383c (patch)
tree619c28b56c92c1b128da88060dd579538352cfb1 /2003/i/buzz/src/busp/busp_servo.h
parent813f57da6ac8ee65fe32e944de62ec2a27574e83 (diff)
Activations des interruptions.
Ajout de la classe servo et IR.
Diffstat (limited to '2003/i/buzz/src/busp/busp_servo.h')
-rw-r--r--2003/i/buzz/src/busp/busp_servo.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/2003/i/buzz/src/busp/busp_servo.h b/2003/i/buzz/src/busp/busp_servo.h
new file mode 100644
index 0000000..764293b
--- /dev/null
+++ b/2003/i/buzz/src/busp/busp_servo.h
@@ -0,0 +1,23 @@
+#ifndef busp_servo_h
+#define busp_servo_h
+// busp_servo.h
+// buzz - Programme du robot Efrei Robotique I1-I2 2003
+// Copyright (C) 2003 Nicolas Schodet
+
+class BuspServo
+{
+ static const int m_address = 2;
+ int m_pos[8];
+ public:
+ // Constructeur.
+ BuspServo ();
+ // Bouge le servo N en POS.
+ void moveTo (int n, int pos);
+ // Bouge le servo N de DIFF.
+ void move (int n, int diff);
+ private:
+ // Fait le déplacement effectif.
+ void set (int n, int pos);
+};
+
+#endif // busp_servo_h