Dependencies:   mbed lwip

Files at this revision

API Documentation at this revision

Comitter:
chris
Date:
Sat Sep 19 07:47:37 2009 +0000
Commit message:

Changed in this revision

lwip.lib Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/lwip.lib	Sat Sep 19 07:47:37 2009 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_unsupported/code/lwip/
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Sat Sep 19 07:47:37 2009 +0000
@@ -0,0 +1,22 @@
+#include "DemoBoard.h"
+
+/*
+ * This project uses the USB interface configured as a mouse, using the HID device class
+ * Thw X,Y pots give the mouse control, and the buttons are the mouse buttons
+ */
+
+int main() {
+
+    while(1) {
+    
+        // read the pots, use them to offset and scale the X,Y values
+        float mx = ((potx.read()-0.50f) * 100.0f);
+        float my = ((poty.read()-0.54f) * 130.0f);
+        
+        // Call the mouse function with the X,Y and button status        
+        hid.mouse(mx, -my, RedButton.read());        
+    }
+
+}
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Sat Sep 19 07:47:37 2009 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/f63353af7be8