Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
Fork of RCControlOOP by
Diff: Mousr.h
- Revision:
- 0:78e2af20cbf3
- Child:
- 2:e9042e88abf1
diff -r 000000000000 -r 78e2af20cbf3 Mousr.h
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/Mousr.h Mon Sep 08 11:32:04 2014 +0000
@@ -0,0 +1,34 @@
+#pragma once
+#include "mbed.h"
+class Mousr
+{
+ public:
+ Mousr();
+ void stop();
+ void straight(float speed);
+ void backwards(float speed);
+ void left(float speed);
+ void right(float speed);
+ void flipLeft();
+ void flipRight();
+ float getStraightSpeed();
+ float getRotateSlowSpeed();
+ float getRotateSpeed();
+ float getRotateFastSpeed();
+
+ private:
+ PwmOut m1a;
+ PwmOut m1b;
+ PwmOut m2a;
+ PwmOut m2b;
+
+ float straightSpeed;
+ float rotateSlowSpeed;
+ float rotateSpeed ;
+ float rotateFastSpeed;
+ float flipStraightSpeed;
+ float flipStraightWait;
+ float flipRotateSpeed;
+ float flipRotateWait;
+};
+
