ble nano hid over gatt

Dependencies:   BLE_API mbed-dev nRF51822

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers config.h Source File

config.h

00001 #ifndef __CONFIG_H__
00002 #define __CONFIG_H__
00003 
00004 #include "RawSerial.h"
00005 extern RawSerial serial;
00006 
00007 #define DEBUG 1
00008 #define DEBUG_KEYEVENT 0
00009 #define DEBUG_BLE 1
00010 #define DEBUG_BLE_INTERRUPT 0
00011 
00012 #if DEBUG_KEYEVENT
00013 #define DEBUG_PRINTF_KEYEVENT(...) serial.printf(__VA_ARGS__)
00014 #else
00015 #define DEBUG_PRINTF_KEYEVENT(...)
00016 #endif
00017 
00018 #if DEBUG_BLE
00019 #define DEBUG_PRINTF_BLE(...) serial.printf(__VA_ARGS__)
00020 #else
00021 #define DEBUG_PRINTF_BLE(...)
00022 #endif
00023 
00024 #if DEBUG_BLE_INTERRUPT
00025 #define DEBUG_PRINTF_BLE_INTERRUPT(...) serial.printf(__VA_ARGS__)
00026 #else
00027 #define DEBUG_PRINTF_BLE_INTERRUPT(...)
00028 #endif
00029 
00030 // Generic DEBUG_PRINTF must not used at any interrupt
00031 #if DEBUG
00032 #define DEBUG_PRINTF(...) serial.printf(__VA_ARGS__)
00033 #else
00034 #define DEBUG_PRINTF(...)
00035 #endif
00036 
00037 #endif