thanks to Zoltan Hudak publish the way to use stm32f103c8t6 on mbed. now you can use it with Wii IRcam

Dependencies:   mbed-STM32F103C8T6 mbed

Fork of Wii_IRCam_Test by Michael Shimniok

Revision:
1:150525e9c21f
Parent:
0:cf1bc7c313b4
Child:
2:43bff54a5f67
diff -r cf1bc7c313b4 -r 150525e9c21f main.cpp
--- a/main.cpp	Thu Dec 30 07:50:11 2010 +0000
+++ b/main.cpp	Fri Dec 31 09:33:30 2010 +0000
@@ -6,6 +6,10 @@
 // obviously mbed is 3.3v so no level translation is needed
 // using built in i2c on pins 9/10
 //
+// PC GUI client here: http://code.google.com/p/wii-cam-blobtrack/
+//
+// Interfacing details here: http://www.bot-thoughts.com/2010/12/connecting-mbed-to-wiimote-ir-camera.html
+//
 
 DigitalOut myled(LED1);
 PwmOut servo(p21);
@@ -39,7 +43,6 @@
 {
     // Init IR Camera sensor
     i2c_write2(addr, 0x30, 0x01);
-    pc.printf("+\n");
     i2c_write2(addr, 0x30, 0x08);    
     i2c_write2(addr, 0x06, 0x90);
     i2c_write2(addr, 0x08, 0xC0);
@@ -59,11 +62,11 @@
     
     // PC serial output    
     pc.baud(115200);
-    pc.printf("Initializing camera...");
+    //pc.printf("Initializing camera...");
 
     cam_init();
   
-    pc.printf("complete\n");
+    //pc.printf("complete\n");
 
     // read I2C stuff
     while(1) {
@@ -100,10 +103,11 @@
         Iy4 += (s & 0xC0) <<2;
         
         // print the coordinate data
-        pc.printf("Ix1: %4d, Iy1: %4d\n", Ix1, Iy1 );
-        pc.printf("Ix2: %4d, Iy2: %4d\n", Ix2, Iy2 );
+        //pc.printf("Ix1: %4d, Iy1: %4d\n", Ix1, Iy1 );
+        //pc.printf("Ix2: %4d, Iy2: %4d\n", Ix2, Iy2 );
+        pc.printf("%d,%d,%d,%d,%d,%d,%d,%d\r\n", Ix1, Iy1, Ix2, Iy2, Ix3, Iy3, Ix4, Iy4);
         
-        wait(0.250);
+        wait(0.050);
     }
 
 }