BLE HID keyboard with gesture

Dependencies:   BLE_API BLE_HID PAJ7620U2 mbed nRF51822

https://mtmtechblog.files.wordpress.com/2017/01/mtsense04-pi-on-mbed.jpeg We have full tutorial, please visit our blog

Revision:
2:6109e375f9a7
Parent:
0:55c7f79a524c
Child:
3:656f8fb89f05
--- a/main.cpp	Fri Dec 16 10:30:32 2016 +0000
+++ b/main.cpp	Fri Dec 30 08:36:50 2016 +0000
@@ -1,9 +1,26 @@
+/* Copyright (c) 2016 MtM Technology Corporation, MIT License
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software 
+ * and associated documentation files (the "Software"), to deal in the Software without restriction, 
+ * including without limitation the rights to use, copy, modify, merge, publish, distribute, 
+ * sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is 
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all copies or 
+ * substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING 
+ * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, 
+ * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
 #include "mbed.h"
 #include "ble/BLE.h"
 #include "ble/services/BatteryService.h"
 #include "ble/services/DeviceInformationService.h"
 
-#include "PAJ7620.h"
+#include "PAJ7620U2.h"
 
 #include "HIDServiceBase.h"
 //#include "MouseService.h"
@@ -34,7 +51,7 @@
 Serial pc(p5, p4);
 
 /* Sensor */
-PAJ7620 gesture(p3, p2, p0);
+PAJ7620U2 gesture(p3, p2, p0);
 volatile bool gestureHasIntEvent = false;
 
 /* HID service */
@@ -43,7 +60,7 @@
 KeyboardService *kbService = NULL;
 
 /* Device name */
-static const char DEVICE_NAME[] = "MtM_gHID";
+static const char DEVICE_NAME[] = "MtM Gesture";
 static const char SHORT_DEVICE_NAME[] = "gHID";