Sample program of PS_PAD. ( https://developer.mbed.org/users/okini3939/code/PS_PAD/ ) Special thanks to Suga koubou(okini3939). Available for PlayStationController, VS-C1, VS-C3, etc...

Dependencies:   PS_PAD mbed

Revision:
0:1ede48b6ea40
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Tue Sep 01 15:00:42 2015 +0000
@@ -0,0 +1,31 @@
+/*
+ * ======================
+ * VS-C3/VS-RCV3 PIN
+ * ======================
+ * 1:NC  2:NC
+ * 3:DAT 4:CMD
+ * 5:SEL 6:CLK
+ * 7:+5~7V 8:NC
+ * 9:+3V 10:GND
+ *
+ */
+
+#include "mbed.h"
+#include "PS_PAD.h"
+
+PS_PAD vsc3(p5, p6, p7, p21); 
+
+DigitalOut myled[] = {LED1, LED2, LED3, LED4};
+
+int main() {
+    vsc3.init();
+    printf("START\n");
+    while(1) {
+        vsc3.poll();
+        myled[0] = vsc3.read(PS_PAD::PAD_CIRCLE);
+        myled[1] = vsc3.read(PS_PAD::PAD_SQUARE);
+        myled[2] = vsc3.read(PS_PAD::PAD_TRIANGLE);
+        myled[3] = vsc3.read(PS_PAD::PAD_X);
+        wait(0.05);
+    }
+}