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.
Dependents: Line_Trace_No_collision_Light_control_longer_dis
Fork of m3pi by
Diff: m3pi.cpp
- Revision:
- 4:54c673c71fc0
- Parent:
- 3:c38d2f980494
- Child:
- 5:09fb0636207b
--- a/m3pi.cpp Mon Nov 01 23:30:09 2010 +0000
+++ b/m3pi.cpp Sun Nov 07 09:57:11 2010 +0000
@@ -24,7 +24,8 @@
#include "mbed.h"
#include "m3pi.h"
-m3pi::m3pi(PinName nrst, PinName tx, PinName rx) : Stream("m3pi"), _nrst(nrst), _ser(tx, rx) {
+m3pi::m3pi(PinName nrst, PinName tx, PinName rx) : Stream("m3pi"), _nrst(nrst), _ser(tx, rx), _leds(p20,p19,p18,p17,p16,p15,p14,p13) {
+ _leds = 0;
_ser.baud(115200);
reset();
}
@@ -33,6 +34,7 @@
_nrst = 0;
wait (0.01);
_nrst = 1;
+ wait (0.01);
}
void m3pi::left_motor (float speed) {
