diff --git a/src/adapter.c b/src/adapter.c
index 93de573..329e9b4 100644
--- a/src/adapter.c
+++ b/src/adapter.c
if (missing_settings & MGMT_SETTING_SECURE_CONN)
set_mode(adapter, MGMT_OP_SET_SECURE_CONN, 0x01);
+ if (main_opts.fast_conn &&
+ (missing_settings & MGMT_SETTING_FAST_CONNECTABLE))
+ set_mode(adapter, MGMT_OP_SET_FAST_CONNECTABLE, 0x01);
+
err = adapter_register(adapter);
if (err < 0) {
error("Unable to register new adapter");
diff --git a/src/hcid.h b/src/hcid.h
index 0c91292..60e2b0a 100644
--- a/src/hcid.h
+++ b/src/hcid.h
gboolean reverse_sdp;
gboolean name_resolv;
gboolean debug_keys;
+ gboolean fast_conn;
uint16_t did_source;
uint16_t did_vendor;
diff --git a/src/main.c b/src/main.c
index f571479..0562b44 100644
--- a/src/main.c
+++ b/src/main.c
g_free(str);
}
+
+ boolean = g_key_file_get_boolean(config, "General",
+ "FastConnectable", &err);
+ if (err)
+ g_clear_error(&err);
+ else
+ main_opts.fast_conn = boolean;
+
}
static void init_defaults(void)
diff --git a/src/main.conf b/src/main.conf
index 9be90af..9b41f8c 100644
--- a/src/main.conf
+++ b/src/main.conf
# Possible values: "off", "single", "multiple"
#MultiProfile = off
+# Permanently enables the Fast Connectable setting for adapters that
+# support it. When enabled other devices can connect faster to us,
+# however the tradeoff is increased power consumptions. Defaults to
+# 'false'.
+#FastConnectable = false
+
#[Policy]
#
# The ReconnectUUIDs defines the set of remote services that should try