1 /* 2 * Copyright 2007 Oliver Ruiz Dorantes, oliver.ruiz.dorantes_at_gmail.com 3 * 4 * All rights reserved. Distributed under the terms of the MIT License. 5 * 6 */ 7 8 #ifndef _BDADDR_UTILS_H 9 #define _BDADDR_UTILS_H 10 11 #include <bluetooth/bluetooth.h> 12 13 namespace Bluetooth { 14 15 class bdaddrUtils { 16 17 public: 18 static inline bdaddr_t NullAddress() 19 { 20 21 return ((bdaddr_t) {{0, 0, 0, 0, 0, 0}}); 22 } 23 24 25 static inline bdaddr_t LocalAddress() 26 { 27 28 return ((bdaddr_t) {{0, 0, 0, 0xff, 0xff, 0xff}}); 29 } 30 31 32 static inline bdaddr_t BroadcastAddress() 33 { 34 35 return ((bdaddr_t) {{0xff, 0xff, 0xff, 0xff, 0xff, 0xff}}); 36 } 37 38 39 static const char* ToString(bdaddr_t bdaddr) 40 { 41 // TODO: 42 static char str[12]; 43 44 return str; 45 } 46 47 }; 48 49 } 50 51 #endif 52