H-brug test op cny70
Dependencies: HC_SR04_Ultrasonic_Library Servo mbed
Revision 0:aa2655f3bcb1, committed 2017-05-24
- Comitter:
- Markoenema
- Date:
- Wed May 24 19:02:11 2017 +0000
- Commit message:
- CNY70+Motor
Changed in this revision
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/HC_SR04_Ultrasonic_Library.lib Wed May 24 19:02:11 2017 +0000 @@ -0,0 +1,1 @@ +http://developer.mbed.org/users/ejteb/code/HC_SR04_Ultrasonic_Library/#e0f9c9fb4cf3
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Servo.lib Wed May 24 19:02:11 2017 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/simon/code/Servo/#36b69a7ced07
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp Wed May 24 19:02:11 2017 +0000
@@ -0,0 +1,30 @@
+#include "mbed.h"
+DigitalOut pin1(D11);
+DigitalOut pin2(D12);
+
+float p;
+
+int main() {
+ while(1){
+
+ pin1=1;
+ pin2=0;
+ printf("Pin1: %d\n", pin1);
+ printf("Pin2: %d\n", pin2);
+ wait(5);
+ pin1=1;
+ pin2=1;
+ printf("Pin1: %d\n", pin1);
+ printf("Pin2: %d\n", pin2);
+ wait(5);
+ pin1=0;
+ pin2=1;
+ printf("Pin1: %d\n", pin1);
+ printf("Pin2: %d\n", pin2);
+ wait(5);
+
+ }
+
+
+
+}
\ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Wed May 24 19:02:11 2017 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/99b5ccf27215 \ No newline at end of file