← 返回命令列表

Linux command

bluetoothctl 命令

文本

复制后可按需替换文件名、目录或参数。

常用示例

Example

bluetoothctl

Example

bluetoothctl devices

Power

bluetoothctl power on

Pair

bluetoothctl pair AA:BB:CC:DD:EE:FF

Connect

bluetoothctl connect AA:BB:CC:DD:EE:FF

Disconnect

bluetoothctl disconnect AA:BB:CC:DD:EE:FF

Remove

bluetoothctl remove AA:BB:CC:DD:EE:FF

说明

bluetoothctl manages Bluetooth devices on Linux. It provides an interactive shell for discovering, pairing, connecting, and managing Bluetooth devices.

参数

-a, --agent _capability_
Register an agent handler with the specified capability.
-e, --endpoints
Register media endpoints.
-m, --monitor
Enable monitor output.
-t, --timeout _seconds_
Timeout for non-interactive mode.
-v, --version
Display version.
-h, --help
Display help.
list
List available controllers
show _ctrl_
Show controller information
select _ctrl_
Set the default controller
devices _filter_
List known devices (filter: Paired, Bonded, Trusted, Connected)
power _on|off_
Turn Bluetooth controller on or off
scan _on|off_
Start or stop device discovery
pair _address_
Pair with device by MAC address
connect _address_
Connect to paired device
disconnect _address_
Disconnect from device
remove _address_
Remove device from known list
trust _address_
Mark device as trusted
untrust _address_
Remove trust from device
info _address_
Show device information
block _address_
Block a device from connecting
unblock _address_
Unblock a previously blocked device
discoverable _on|off_
Set controller discoverability
agent _on|off|capability_
Register or unregister agent
help
Show available commands

FAQ

What is the bluetoothctl command used for?

bluetoothctl manages Bluetooth devices on Linux. It provides an interactive shell for discovering, pairing, connecting, and managing Bluetooth devices.

How do I run a basic bluetoothctl example?

Run `bluetoothctl` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does -a, --agent _capability_ do in bluetoothctl?

Register an agent handler with the specified capability.