EMG project for Biorobotics, works with 2 EMG inputs

Dependencies:   USBDevice

Fork of HIDScope by Tom Tom

Revision:
1:e44574634162
Parent:
0:79e3f3072f3b
Child:
2:9c9226db4fb1
diff -r 79e3f3072f3b -r e44574634162 HIDScope.h
--- a/HIDScope.h	Mon Sep 08 09:26:53 2014 +0000
+++ b/HIDScope.h	Mon Sep 08 09:38:36 2014 +0000
@@ -4,10 +4,34 @@
 #include "mbed.h"
 #include "USBHID.h"
 
-/**A simple HID (Human Interface Device) scope
-- Up to 6 channels of float data is transmitted in a single HID message (64 byte)
-- Theoretical maximum samplerate of 1kHz
-- Data can be parsed using a client-side server like NodeJS
+/** A simple HID (Human Interface Device) scope
+ * - Up to 6 channels of float data is transmitted in a single HID message (64 byte)
+ * - Theoretical maximum samplerate of 1kHz
+ * - Data can be parsed using a client-side server like NodeJS
+ * 
+ * Example:
+ * @code
+ * #include "mbed.h"
+ * #include "HIDScope.h"
+ *
+ * HIDScope    scope(2);
+ * Ticker      scopeTimer;
+ * 
+ * AnalogIn    a0(A0);
+ * 
+ * int main()
+ * {
+ *   
+ *   scopeTimer.attach_us(&scope, &HIDScope::send, 1e4); // Send data at 100 Hz
+ *   
+ *   while(1){  // Generate some data
+ *       scope.set(0, a0.read());
+ *       scope.set(1, a0.read());
+ *       wait_us(1000);
+ *   };    
+ *   
+ * }
+ * @endcode
 */
 class HIDScope {
     public: