xref: /freebsd/usr.sbin/bluetooth/hccontrol/hccontrol.8 (revision 0b3105a37d7adcadcb720112fed4dc4e8040be99)
1.\" Copyright (c) 2001-2002 Maksim Yevmenkin <m_evmenkin@yahoo.com>
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\"    notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\"    notice, this list of conditions and the following disclaimer in the
11.\"    documentation and/or other materials provided with the distribution.
12.\"
13.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23.\" SUCH DAMAGE.
24.\"
25.\" $Id: hccontrol.8,v 1.6 2003/08/06 21:26:38 max Exp $
26.\" $FreeBSD$
27.\"
28.Dd February 7, 2015
29.Dt HCCONTROL 8
30.Os
31.Sh NAME
32.Nm hccontrol
33.Nd Bluetooth HCI configuration utility
34.Sh SYNOPSIS
35.Nm
36.Op Fl hN
37.Op Fl n Ar HCI_node_name
38.Ar command
39.Op Ar parameters ...
40.Sh DESCRIPTION
41The
42.Nm
43utility connects to the specified Netgraph node of type
44.Dv HCI
45or the first one found if none is specified and attempts to send the specified
46command to the HCI Netgraph node or to the associated Bluetooth device.
47The
48.Nm
49utility will print results to the standard output and error messages to
50the standard error.
51.Pp
52The options are as follows:
53.Bl -tag -width indent
54.It Fl h
55Display usage message and exit.
56.It Fl N
57Show Bluetooth addresses as numbers.
58Normally
59.Nm
60attempts to resolve Bluetooth addresses, and display them symbolically.
61.It Fl n Ar HCI_node_name
62Connect to the specified HCI Netgraph node.
63.It Ar command
64One of the supported commands (see below).
65The special command
66.Cm help
67can be used to obtain the list of all supported commands.
68To get more information about a specific command use
69.Cm help Ar command .
70.It Ar parameters
71One or more optional space separated command parameters.
72Many commands require a remote device address as one of the parameters.
73The remote device address can be specified as BD_ADDR or a name.
74If a name was specified then the
75.Nm
76utility will attempt to resolve the name via
77.Xr bt_gethostbyname 3 .
78.El
79.Sh COMMANDS
80The currently supported HCI commands in
81.Nm
82are:
83.Pp
84.Bl -tag -width 40n -offset indent -compact
85.It Cm Inquiry
86.It Cm Create_Connection
87.It Cm Disconnect
88.It Cm Add_SCO_Connection
89.It Cm Change_Connection_Packet_Type
90.It Cm Remote_Name_Request
91.It Cm Read_Remote_Supported_Features
92.It Cm Read_Remote_Version_Information
93.It Cm Read_Clock_Offset
94.It Cm Role_Discovery
95.It Cm Switch_Role
96.It Cm Read_Link_Policy_Settings
97.It Cm Write_Link_Policy_Settings
98.It Cm Reset
99.It Cm Read_Pin_Type
100.It Cm Write_Pin_Type
101.It Cm Read_Stored_Link_Key
102.It Cm Write_Stored_Link_Key
103.It Cm Delete_Stored_Link_Key
104.It Cm Change_Local_Name
105.It Cm Read_Local_Name
106.It Cm Read_Connection_Accept_Timeout
107.It Cm Write_Connection_Accept_Timeout
108.It Cm Read_Page_Timeout
109.It Cm Write_Page_Timeout
110.It Cm Read_Scan_Enable
111.It Cm Write_Scan_Enable
112.It Cm Read_Page_Scan_Activity
113.It Cm Write_Page_Scan_Activity
114.It Cm Read_Inquiry_Scan_Activity
115.It Cm Write_Inquiry_Scan_Activity
116.It Cm Read_Authentication_Enable
117.It Cm Write_Authentication_Enable
118.It Cm Read_Encryption_Mode
119.It Cm Write_Encryption_Mode
120.It Cm Read_Class_Of_Device
121.It Cm Write_Class_Of_Device
122.It Cm Read_Voice_Settings
123.It Cm Write_Voice_Settings
124.It Cm Read_Number_Broadcast_Retransmissions
125.It Cm Write_Number_Broadcast_Retransmissions
126.It Cm Read_Hold_Mode_Activity
127.It Cm Write_Hold_Mode_Activity
128.It Cm Read_SCO_Flow_Control_Enable
129.It Cm Write_SCO_Flow_Control_Enable
130.It Cm Read_Link_Supervision_Timeout
131.It Cm Write_Link_Supervision_Timeout
132.It Cm Read_Page_Scan_Period_Mode
133.It Cm Write_Page_Scan_Period_Mode
134.It Cm Read_Page_Scan_Mode
135.It Cm Write_Page_Scan_Mode
136.It Cm Read_Local_Version_Information
137.It Cm Read_Local_Supported_Features
138.It Cm Read_Buffer_Size
139.It Cm Read_Country_Code
140.It Cm Read_BD_ADDR
141.It Cm Read_Failed_Contact_Counter
142.It Cm Reset_Failed_Contact_Counter
143.It Cm Get_Link_Quality
144.It Cm Read_RSSI
145.El
146.Pp
147The currently supported node commands in
148.Nm
149are:
150.Pp
151.Bl -tag -width 40n -offset indent -compact
152.It Cm Read_Node_State
153.It Cm Initialize
154.It Cm Read_Debug_Level
155.It Cm Write_Debug_Level
156.It Cm Read_Node_Buffer_Size
157.It Cm Read_Node_BD_ADDR
158.It Cm Read_Node_Features
159.It Cm Read_Node_Stat
160.It Cm Reset_Node_Stat
161.It Cm Flush_Neighbor_Cache
162.It Cm Read_Neighbor_Cache
163.It Cm Read_Connection_List
164.It Cm Read_Node_Link_Policy_Settings_Mask
165.It Cm Write_Node_Link_Policy_Settings_Mask
166.It Cm Read_Node_Packet_Mask
167.It Cm Write_Node_Packet_Mask
168.It Cm Read_Node_Role_Switch
169.It Cm Write_Node_Role_Switch
170.It Cm Read_Node_List
171.El
172.Sh EXIT STATUS
173.Ex -std
174.Sh SEE ALSO
175.Xr bluetooth 3 ,
176.Xr netgraph 3 ,
177.Xr netgraph 4 ,
178.Xr ng_hci 4 ,
179.Xr hcseriald 8
180.Sh AUTHORS
181.An Maksim Yevmenkin Aq Mt m_evmenkin@yahoo.com
182.Sh BUGS
183Most likely.
184Please report if found.
185