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: EMG HIDScope PID QEI mbed TextLCD
Diff: main.cpp
- Revision:
- 7:572e7f3e184a
- Parent:
- 6:ae2ce89dd695
- Child:
- 8:b0971033dc41
--- a/main.cpp Tue Oct 20 07:52:45 2015 +0000
+++ b/main.cpp Tue Oct 20 08:21:50 2015 +0000
@@ -63,8 +63,8 @@
// **************
// get emg signal
if(initposition_go){
- leftRequest=pot1.read()*10-5;
- rightRequest=pot2.read()*10-5;
+ leftRequest=pot1.read()*20-10;
+ rightRequest=pot2.read()*20-10;
}
else {
sample_filter();
@@ -147,6 +147,8 @@
leftRequest=(toLeftAngle-leftAngle)/RATE;
rightRequest=(toRightAngle-rightAngle)/RATE;
}
+ pc.printf("leftrequest: %f, rightrequest: %f \n\r",leftRequest, rightRequest);
+
// set the setpoint to the pid controller
leftController.setSetPoint(leftRequest);
rightController.setSetPoint(rightRequest);