linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH BlueZ v2] client: Include UUID when listing attributes
@ 2016-08-29 12:10 Per Thomas Jahr
  0 siblings, 0 replies; only message in thread
From: Per Thomas Jahr @ 2016-08-29 12:10 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Per Thomas Jahr

Show the full UUID for services, characteristics and descriptors.

Example output with this change:

[NEW] Primary Service
	/org/bluez/hci0/dev_D1_6E_07_45_B2_36/service0008
	00001801-0000-1000-8000-00805f9b34fb
	Generic Attribute Profile
---
 client/gatt.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/client/gatt.c b/client/gatt.c
index fee1cf9..2dc455f 100644
--- a/client/gatt.c
+++ b/client/gatt.c
@@ -75,13 +75,13 @@ static void print_service(GDBusProxy *proxy, const char *description)
 	if (!text)
 		text = uuid;
 
-	rl_printf("%s%s%s%s Service\n\t%s\n\t%s\n",
+	rl_printf("%s%s%s%s Service\n\t%s\n\t%s\n\t%s\n",
 				description ? "[" : "",
 				description ? : "",
 				description ? "] " : "",
 				primary ? "Primary" : "Secondary",
 				g_dbus_proxy_get_path(proxy),
-				text);
+				uuid, text);
 }
 
 void gatt_add_service(GDBusProxy *proxy)
@@ -118,12 +118,12 @@ static void print_characteristic(GDBusProxy *proxy, const char *description)
 	if (!text)
 		text = uuid;
 
-	rl_printf("%s%s%sCharacteristic\n\t%s\n\t%s\n",
+	rl_printf("%s%s%sCharacteristic\n\t%s\n\t%s\n\t%s\n",
 				description ? "[" : "",
 				description ? : "",
 				description ? "] " : "",
 				g_dbus_proxy_get_path(proxy),
-				text);
+				uuid, text);
 }
 
 static gboolean characteristic_is_child(GDBusProxy *characteristic)
@@ -186,12 +186,12 @@ static void print_descriptor(GDBusProxy *proxy, const char *description)
 	if (!text)
 		text = uuid;
 
-	rl_printf("%s%s%sDescriptor\n\t%s\n\t%s\n",
+	rl_printf("%s%s%sDescriptor\n\t%s\n\t%s\n\t%s\n",
 				description ? "[" : "",
 				description ? : "",
 				description ? "] " : "",
 				g_dbus_proxy_get_path(proxy),
-				text);
+				uuid, text);
 }
 
 static gboolean descriptor_is_child(GDBusProxy *characteristic)
-- 
2.5.5


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2016-08-29 12:10 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-29 12:10 [PATCH BlueZ v2] client: Include UUID when listing attributes Per Thomas Jahr

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).