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: fll mbed-rtos mbed
Diff: fll.cpp
- Revision:
- 16:253d933a7633
- Parent:
- 11:21b3b0494baa
- Child:
- 17:69536d02cb3c
diff -r ed0c2da735c2 -r 253d933a7633 fll.cpp
--- a/fll.cpp Mon Feb 16 07:13:09 2015 +0000
+++ b/fll.cpp Mon Feb 16 12:09:04 2015 +0000
@@ -139,6 +139,8 @@
((Sink*)p)->run();
}
+Serial pc(USBTX, USBRX);
+
void fll_run(Producer* producer) {
Mail<button_t, MAIL_BOX_SIZE>* mail_box = new Mail<button_t, MAIL_BOX_SIZE>();
Mutex* mutex = new Mutex();
@@ -149,6 +151,14 @@
Output* output = new Output(mail_box);
Thread th(invoke_sinkrun, (void *)sink);
+ DigitalIn pin20(p20);
+ wait(1);
+ while (1) {
+ // pc.printf("pin20: %d\r\n", pin20.read());
+ if (pin20.read() == 1) {
+ break;
+ }
+ }
ticker.attach(output, &Output::run, FRAME);
Thread::wait(osWaitForever);
