Commit Graph

32 Commits

Author SHA1 Message Date
huangyulong3 0cf1898d83 bluetooth: fix compilation errors
Fix various compilation errors across bluetooth framework, service,
and stack layers including:
- Add missing function declarations and header includes
- Fix type mismatches and implicit function declarations
- Add missing macro definitions in dfx headers
- Add stub implementation for hid device interface
- Fix list utility inline function issues

Signed-off-by: openvela <openvela@xiaomi.com>
2026-05-08 09:52:38 +08:00
zhangyuan20 a8fa3ba64d CS: add cs socket server and client.
bug: v/80281

Rootcause: Add a socket server and client to enable communication between the user and Bluetooth.

Signed-off-by: zhangyuan20 <zhangyuan20@xiaomi.com>
2026-04-27 23:14:55 +08:00
liuxiang18 35619721a7 bluetooth: implement bt_device_set_bondable_le API to change bond mode.
bug: v/67335

Signed-off-by: liuxiang18 <liuxiang18@xiaomi.com>
2026-04-27 23:14:52 +08:00
liuxiang18 9d7ddc49be bluetooth: implement bt_device_set_security_level API to change bond security level.
bug: v/67009

Signed-off-by: liuxiang18 <liuxiang18@xiaomi.com>
2026-04-27 23:14:52 +08:00
liuxiang18 7fcbecc5cd IPC: fix build error conversion from 'int' to 'bt_message_type_t'.
bug: v/52485

Signed-off-by: liuxiang18 <liuxiang18@xiaomi.com>
2026-04-27 23:14:51 +08:00
openvela-robot 9d0c825cbb Merge commit
Change-Id: If26995eebd18a82ac4cd827e6801458e57a6ead3
2026-04-27 23:14:50 +08:00
zhangyuan20 155520406c fix problem that pair pin command do not send accept
Rootcause: Pair pin command do not send accept, The default value is 0, thus rejecting the pair process, So add accept when send to socket.

Signed-off-by: zhangyuan20 <zhangyuan20@xiaomi.com>
2026-04-20 14:53:05 +08:00
liuxiang18 4baa13a8d1 bluetooth: implement bt_device_set_bondable_le API to change bond mode.
Signed-off-by: liuxiang18 <liuxiang18@xiaomi.com>
2026-04-20 14:52:41 +08:00
liuxiang18 55147e63ba bluetooth: implement bt_device_set_security_level API to change bond security level.
Signed-off-by: liuxiang18 <liuxiang18@xiaomi.com>
2026-04-20 14:52:40 +08:00
liuxiang18 cf465cabaf IPC: fix build error conversion from 'int' to 'bt_message_type_t'.
Signed-off-by: liuxiang18 <liuxiang18@xiaomi.com>
2026-04-20 14:51:55 +08:00
liuxiang18 26713e976d bluetooth:connect/disconnect profile API
Signed-off-by: liuxiang18 <liuxiang18@xiaomi.com>
2026-04-20 14:51:35 +08:00
chejinxian1 489bf05c8a Bluetooth: Add API for supplying enhanced mode for application calling.
Rootcause: Due to the diversity of application scenarios, the API for invoking the Connection Enhanced Mode is provided for applications to call. Applications can enable or disable specific enhanced modes according to their own needs.

Signed-off-by: chejinxian1 <chejinxian1@xiaomi.com>
2026-04-20 14:51:24 +08:00
zhangyuan20 3dbe72ae1c framework/bluetooth: Fixed the problem that bt_device_get_alias method returns wrong alias.
bt_device_get_alias method returns 62 bytes when alias length is 63 bytes, because the length is reduced by 1 when using strlcpy.

Signed-off-by: zhangyuan20 <zhangyuan20@xiaomi.com>
2026-04-20 14:51:24 +08:00
chejinxian1 901f11ef41 Bluetooth: Remove API about getting ACL handle.
Rootcause: Application does not need to know the Bluetooth ACL handle. Therefore, the corresponding API needs to be removed.

Signed-off-by: chejinxian1 <chejinxian1@xiaomi.com>
2026-04-20 14:51:14 +08:00
duqunbo 369868f0e2 Fixed assignment issues on structs
Signed-off-by: duqunbo <duqunbo@xiaomi.com>
2026-04-20 14:51:02 +08:00
Haishen Zhang 6ed1e5e080 Vela-Android: Porting Vela Bluetooth Framework Socket Client to Android x86_64
1. Port Vela Bluetooth Framework Socket Client onto Android.
2. For Socket Server, Service, SAL, we didn't port them onto Android.
3. For bttool, the function is not ready yet.
4. With this libbt-framework-client.so, we can start working on BTIF wrapper over Vela BT Framework Socket Client API.
5. And, we can also start working on bttool over Vela BT Framework Socket Client API later.

Signed-off-by: Haishen Zhang <zhanghaishen@xiaomi.com>
2026-04-20 14:51:00 +08:00
shenyangsi 6720de665c BLE: support LE OOB pairing
Signed-off-by: shenyangsi <shenyangsi@xiaomi.com>
2026-04-20 14:50:59 +08:00
Haishen Zhang 19bc307ac2 Clang-format: Update format of all files based on new .clang-format
1. Update format of all files based on new .clang-format

Signed-off-by: Haishen Zhang <zhanghaishen@xiaomi.com>
2026-04-20 14:50:50 +08:00
gaozihao e795aec05d Bluetooth: fix coverity issue.
Signed-off-by: gaozihao <gaozihao@xiaomi.com>
2026-04-20 14:50:40 +08:00
fangzhenwei 8942bceb4c Merge dev-bt and rel-4.0 --> dev
Signed-off-by: fangzhenwei <fangzhenwei@xiaomi.com>
2026-04-20 14:50:36 +08:00
shenyangsi 69261b9470 gap: add link connect request callback and reply
Signed-off-by: shenyangsi <shenyangsi@xiaomi.com>
Signed-off-by: fangzhenwei <fangzhenwei@xiaomi.com>
2026-04-20 14:50:33 +08:00
gaozihao c0034de2b2 Bluetooth: fix coverity issues.
Signed-off-by: gaozihao <gaozihao@xiaomi.com>
2026-04-20 14:50:22 +08:00
gaozihao 5ab4dc6f8c Bluetooth: Code formatted without head file sorted.
Signed-off-by: gaozihao <gaozihao@xiaomi.com>
2026-04-20 14:50:21 +08:00
shenyangsi 568dd80610 bluetooth: add le_set_oob_data feature
Signed-off-by: shenyangsi <shenyangsi@xiaomi.com>
2026-04-20 14:50:16 +08:00
shenyangsi 8b22660e92 support get identity address of bonded ble device
Signed-off-by: shenyangsi <shenyangsi@xiaomi.com>
2026-04-20 14:50:15 +08:00
fangzhenwei 1db4b91dd5 add ipc instance check
Signed-off-by: fangzhenwei <fangzhenwei@xiaomi.com>
2026-04-20 14:50:15 +08:00
duqunbo 91f5a31588 fix bug when get alias
Signed-off-by: duqunbo <duqunbo@xiaomi.com>
2026-04-20 14:50:14 +08:00
zhaobinchao 723dd50dc4 device: fix cannot get device name issue
Signed-off-by: zhaobinchao <zhaobinchao@xiaomi.com>
2026-04-20 14:50:11 +08:00
shenyangsi 66f7070963 gap: add link connect request callback and reply
Signed-off-by: shenyangsi <shenyangsi@xiaomi.com>
2026-04-20 14:50:10 +08:00
yangjian11 fb5432b9a5 support le connect
Signed-off-by: yangjian11 <yangjian11@xiaomi.com>
2026-04-20 14:50:09 +08:00
fangzhenwei 348cb134dd Interface optimization
Signed-off-by: fangzhenwei <fangzhenwei@xiaomi.com>
2026-04-20 14:50:08 +08:00
chao an 08eef4e8fe service/socket: add lightweight socket ipc layer
Signed-off-by: fangzhenwei <fangzhenwei@xiaomi.com>
Signed-off-by: chao an <anchao@xiaomi.com>
2026-04-20 14:50:05 +08:00