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: mbed Rejestrator
Diff: main.cpp
- Revision:
- 0:fa31f8461c63
diff -r 000000000000 -r fa31f8461c63 main.cpp
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp Sat Apr 18 17:01:57 2015 +0000
@@ -0,0 +1,45 @@
+#include <MemoryPool.h>
+#include <RtosTimer.h>
+#include <Thread.h>
+#include <Queue.h>
+#include <mbed.h>
+#include "WaitForSwitch.h"
+#include "USBHostMSD.h"
+#include "Rejestrator.h"
+#include "H_IO.h"
+#include "Acquisition.h"
+#include "FileWritter.h"
+
+Serial pc(USBTX, USBRX);
+
+rtos::MemoryPool<struct row_type, 20> data_memory;
+rtos::Queue<struct row_type, 20> data_queue;
+
+enum operating_mode_type operating_mode = Starting;
+
+osStatus ErrorValue = osOK;
+
+int main(void)
+{
+ pc.printf("Starting\n");
+ rtos::Thread HIO(ThreadIO, NULL, osPriorityBelowNormal);
+ pc.printf("Started IO\n");
+ rtos::Thread::wait(500);
+// WaitForSwitch(Switch1, led_green);
+// rtos::Thread FileWriter(ThreadFileWritter, NULL, osPriorityNormal);
+// rtos::Thread FileWriter(ThreadFileWritter, NULL, osPriorityBelowNormal);
+// WaitForSwitch(Switch2, led_red);
+ pc.printf("Starting aquisition\n");
+ rtos::Thread Acquisition(ThreadAcquisition, NULL, osPriorityAboveNormal);
+ pc.printf("Started aquisition\n");
+
+ FileWritter (NULL);
+
+ pc.printf("filewriter stopped\n");
+
+// while (1)
+// {
+// slcd.display ((int)global_time);
+// rtos::Thread::wait(100);
+// }
+}