return OAL_STATUS_SUCCESS;
}
+oal_status_t adapter_set_le_static_random_address(int enable)
+{
+ int ret;
+
+ CHECK_OAL_INITIALIZED();
+ API_TRACE("%d", enable);
+
+#ifdef TIZEN_BT_HAL
+ ret = blued_api->set_le_static_random_address((enable ? 1 : 0));
+ if (ret != BT_STATUS_SUCCESS)
+ BT_ERR("Static address set failed: [%s]", status2string(ret));
+ ret = convert_to_oal_status(ret);
+#else
+ BT_INFO("Not Supported");
+ ret = OAL_STATUS_NOT_SUPPORT;
+#endif
+
+ return ret;
+}
+
+oal_status_t adapter_set_white_list(bt_address_t *device_address, int address_type, bool is_add)
+{
+ int ret;
+ bdstr_t bdstr;
+
+ CHECK_OAL_INITIALIZED();
+ API_TRACE();
+
+ BT_INFO("BT remote device Address: %s", bdt_bd2str(device_address, &bdstr));
+
+ ret = blued_api->adapter_le_set_white_list((bt_bdaddr_t*)device_address, address_type, is_add);
+ if (ret != BT_STATUS_SUCCESS) {
+ if(is_add)
+ BT_ERR("Add to White List Failed: [%s]",status2string(ret));
+ else
+ BT_ERR("Remove from White List Failed: [%s]",status2string(ret));
+ }
+ ret = convert_to_oal_status(ret);
+ return ret;
+}
+
+oal_status_t adapter_ble_set_privacy(int set_privacy)
+{
+ int res;
+
+ CHECK_OAL_INITIALIZED();
+ API_TRACE();
+
+ res = blued_api->adapter_le_set_privacy(set_privacy);
+ if (res != BT_STATUS_SUCCESS)
+ BT_ERR("Setting LE Privacy Failed: [%s]", status2string(res));
+ res = convert_to_oal_status(res);
+
+ return res;
+}
+
static void cb_adapter_properties(bt_status_t status,
int num_properties,
bt_property_t *properties)
sizeof(event_adapter_le_features_t));
break;
}
+ case BT_PROPERTY_ADAPTER_LE_DISCOVERY_FINISHED: {
+ gboolean le_discovering = *(gboolean *)properties[i].val;
+ if (le_discovering == FALSE) {
+ BT_INFO("LE Discovery finished");
+ send_event(OAL_EVENT_BLE_DISCOVERY_FINISHED, NULL, 0);
+ }
+ break;
+ }
default:
BT_WARN("Unhandled property: %d", properties[i].type);
break;