From 27358b6d8c92f11455fda44e611021946ade7403 Mon Sep 17 00:00:00 2001 From: Arman Uguray Date: Wed, 25 Mar 2015 19:52:34 -0700 Subject: [PATCH] tools/btmgmt: Better usage info for add-adv This patch improves the usage string that gets printed for the add-adv command to provide more details about the possible options. --- tools/btmgmt.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/tools/btmgmt.c b/tools/btmgmt.c index 19eeda1d6..bd83ac760 100644 --- a/tools/btmgmt.c +++ b/tools/btmgmt.c @@ -3687,8 +3687,18 @@ static void add_adv_rsp(uint8_t status, uint16_t len, const void *param, static void add_adv_usage(void) { - print("Usage: add-adv [-u uuid] [-d adv_data] [-s scan_rsp] " - "[-t timeout] [-c] [-d] [-e] [-l] [-m] [-p] "); + print("Usage: add-adv [options] \nOptions:\n" + "\t -u, --uuid Service UUID\n" + "\t -d, --adv-data Advertising Data bytes\n" + "\t -s, --scan-rsp Scan Response Data bytes\n" + "\t -t, --timeout Timeout in seconds\n" + "\t -c, --connectable \"connectable\" flag\n" + "\t -g, --general-discov \"general-discoverable\" flag\n" + "\t -l, --limited-discov \"limited-discoverable\" flag\n" + "\t -m, --managed-flags \"managed-flags\" flag\n" + "\t -p, --tx-power \"tx-power\" flag\n" + "e.g.:\n" + "\tadd-adv -u 180d -u 180f -d 080954657374204C45 1"); } static struct option add_adv_options[] = { -- 2.47.3