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: Encoder HIDScope MODSERIAL TouchButton mbed-dsp mbed
Fork of Robot2mooiemanier by
Revision 27:b58e10cbd35b, committed 2014-11-01
- Comitter:
- Tanja2211
- Date:
- Sat Nov 01 12:07:37 2014 +0000
- Parent:
- 24:a165dcd86710
- Child:
- 28:bee27c74a835
- Commit message:
- pid positie: waardes 0.2 en 0.02
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Fri Oct 31 14:54:49 2014 +0000
+++ b/main.cpp Sat Nov 01 12:07:37 2014 +0000
@@ -80,6 +80,7 @@
float highpass_states[4];
bool stop;
+float new_pos;
float new_pwm;
float PWM2 = 0.3; //PWM voor instellen hoek batje
int toestand = WACHTEN; //terugkeren?
@@ -719,7 +720,8 @@
}
if (toestand == WACHTEN) {
pwm_motor1.write(0);
- pidpositie(ANGLEMIN, motor1.getPosition());
+ new_pos=pidpositie(ANGLEMIN, motor1.getPosition());
+ pc.printf("new position %f\r\n", new_pos);
//pc.printf("ifwachten2\n");
}
//sturen naar HID Scope
