![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
..
Dependencies: HIDScope MODSERIAL biquadFilter mbed
main.cpp@4:fbea05c8fe2b, 2018-09-16 (annotated)
- Committer:
- MarijkeZondag
- Date:
- Sun Sep 16 13:49:23 2018 +0000
- Revision:
- 4:fbea05c8fe2b
- Parent:
- 3:a3ad58758696
- Child:
- 5:107eb09fb095
assignment 2c nu wel goed;
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
vsluiter | 0:c8f15874531b | 1 | #include "mbed.h" |
vsluiter | 0:c8f15874531b | 2 | #include "MODSERIAL.h" |
vsluiter | 0:c8f15874531b | 3 | |
MarijkeZondag | 4:fbea05c8fe2b | 4 | DigitalOut gpo(D0); |
vsluiter | 0:c8f15874531b | 5 | DigitalOut myled(LED_GREEN); |
vsluiter | 0:c8f15874531b | 6 | MODSERIAL pc(USBTX, USBRX); |
MarijkeZondag | 2:2f4444f1504d | 7 | DigitalIn button(PTA4); |
vsluiter | 0:c8f15874531b | 8 | |
vsluiter | 0:c8f15874531b | 9 | int main() |
MarijkeZondag | 3:a3ad58758696 | 10 | { |
vsluiter | 0:c8f15874531b | 11 | pc.baud(115200); |
Gijsvanoort | 1:40470bc517f1 | 12 | pc.printf("Hello World!\r\n"); |
MarijkeZondag | 4:fbea05c8fe2b | 13 | char c; |
MarijkeZondag | 4:fbea05c8fe2b | 14 | c = pc.getc(); |
MarijkeZondag | 4:fbea05c8fe2b | 15 | pc.printf(" %c \n",c); |
vsluiter | 0:c8f15874531b | 16 | |
MarijkeZondag | 2:2f4444f1504d | 17 | while (true) |
MarijkeZondag | 2:2f4444f1504d | 18 | { |
MarijkeZondag | 4:fbea05c8fe2b | 19 | gpo = !gpo; |
MarijkeZondag | 4:fbea05c8fe2b | 20 | myled = !myled; // toggle a led |
MarijkeZondag | 4:fbea05c8fe2b | 21 | wait (0.2f); |
vsluiter | 0:c8f15874531b | 22 | } |
vsluiter | 0:c8f15874531b | 23 | } |
MarijkeZondag | 4:fbea05c8fe2b | 24 |