]> git.gir.st - tmk_keyboard.git/blob - protocol/iwrap/iWRAP5.txt
Add support of iWRAP5
[tmk_keyboard.git] / protocol / iwrap / iWRAP5.txt
1 Terminology
2 ===========
3 PSM
4 HIDP HID Protocol
5 L2CAP Logical Link Control Adaptation Protocol
6 MTU Maximum Transmission Unit
7
8
9
10 HID Protocol Messages
11 =====================
12 3 of HID_SPEC_V11.pdf
13
14 Control channel PSM=0x0011
15 Interrupt channel PSM=0x0013
16
17 HANDSHAKE(0)
18 HID_CONTROL(1)
19 GET_REPORT(4)
20 -------------
21 Host requests report(DATA payload on Control channel) from Device
22
23 Size Desc
24 ------------------------------------------------------------------------------
25 HIDP-Hdr 1 7..4: HIDP Message TYpe(4: GET_REPORT)
26 3: Size(1:2-octed buffer size, 0:size of the report)
27 2: 0
28 1..0: Report Type(1:input, 2:output, 3: feature)
29 ReportID 1 Optional
30 BufferSize 2 Optional(specified when Size=1)
31
32 SET_REPORT(5)
33 GET_PROTOCOL(6)
34 SET_PROTOCOL(7)
35 DATA(A)
36 -------
37 Input/Output Report: All DATA payloads flow on Interrupt channel.
38 Other: flows on Control channel.
39
40 Size Desc
41 ------------------------------------------------------------------------------
42 HIDP-Hdr 1 7..4 0xA
43 3..2 Reserved(0)
44 1..0 Report Type(0:Other, 1:Input, 2:Output, 3:Feature)
45 Payload N Data
46
47
48
49
50 Boot Protocol
51 =============
52 3.3.2
53 No report descriptor, fixed report descriptors defined.
54
55 Device ReportID Size
56 ---------------------------------
57 Reserved 0
58 Keyboard 1 9octets
59 Mouse 2 4octets
60 Reserved 3-255
61
62 Report descriptor
63 -----------------
64 Report ID is added to USB HID boot protocol descriptor.
65 Boot Protocol device doesn't need to supply descriptors. and can send extra data on end of boot report this data will be ignored unless host supports report descriptor.
66
67 Report Protocol devices can have specific descriptors. Using Boot protocol descriptor followed by extra data may be useful for compatibility to Boot protocol only supported host.
68
69 NOTE:
70 Bluegiga HID sample say report ID of mouse is 1 but 2?
71 Bluegiga HID sample say report ID of consumer page is 2 but 3?
72 ** mouse.desc and consumer.desc were fixed.
73 size
74 keyboard.desc 67 0x43
75 mouse.desc 60 0x3c
76 consumer.desc 82 0x52
77 combo.desc 209 0xd1
78
79
80
81 SDP
82 ===
83 attributes(3.3.2)
84 ----------
85 HIDDeviceSubclass
86 which type is supported in Boot Protocol Mode
87 7 6
88 ---
89 0 1 Keyboard
90 1 0 Pointing device
91 1 1 Combo keyboard/pointing device
92
93 HIDBootDevice
94 TRUE
95 HIDReconnectInitiate
96 TRUE
97
98
99 Class of Device/Service
100 =======================
101 http://phys.sci.hokudai.ac.jp/LABS/yts/pic/GB002/Bluetooth_assigned_numbers_baseband.pdf
102
103 0x0005C0 Keyboard and Pointing deivce(combo)
104
105
106 23 16 15 8 7 0
107 ---------------------------------
108 Service |Major |Minor |Format
109
110 Format type
111 1 0
112 ---
113 0 0
114
115 Minor Device Class of Peripheral Major
116 7 6
117 ---
118 0 1 Keyboard
119 1 0 Pointing device
120 1 1 Combo keyboard/pointing device
121
122
123 Major device classes
124 12 11 10 9 8
125 --------------
126 0 0 0 0 0 Miscellaneous
127 0 0 0 0 1 Computer
128 0 0 0 1 0 Phone
129 0 0 0 1 1 LAN /Network Access point
130 0 0 1 0 0 Audio/Video (headset,speaker,stereo, video display, vcr.....
131 0 0 1 0 1 *Peripheral (mouse, joystick, keyboards, ..... )
132 0 0 1 1 0 Imaging (printing, scanner, camera, display, ...)
133 1 1 1 1 1 Uncategorized, specific device code not specified
134 X X X X X All other values reserved
135
136
137 Major service classes
138 bit
139 --------------------------------------
140 13 Limited Discoverable Mode [Ref #1]
141 14 (reserved)
142 15 (reserved)
143 16 Positioning (Location identification)
144 17 Networking (LAN, Ad hoc, ...)
145 18 Rendering (Printing, Speaker, ...)
146 19 Capturing (Scanner, Microphone, ...)
147 20 Object Transfer (v-Inbox, v-Folder, ...)
148 21 Audio (Speaker, Microphone, Headset service, ...)
149 22 Telephony (Cordless telephony, Modem, Headset service, ...)
150 23 Information (WEB-server, WAP-server, ...)
151
152
153
154
155 SET PROFILE HID 0d c0 100 0 en 0409 HHKB pro Bluetooth keyboard
156
157 {function bit} uint8
158 {subclass} uint8
159 {version} uint16
160 {country} uint8
161 {BTlang} char[2]
162 {USBlang} uint16
163 {name} string
164
165
166 SET PROFILE HID 0f c0 100 0 en 0409 TMK Bluetooth keyboard
167
168 // composite device: keyboard and mouse
169 SET BT CLASS 005c0
170
171
172
173 Authentication SSP
174 -------------------
175 SET BT SSP 2 0 PASS KEY entering
176 SET BT SSP 3 0 NO PASS KEY entering
177 SET BT SSP <capabilities> <mitm>
178 <capabilities>: 0:display only 1:display+yes/no button 2:keyboard only 3:none
179 SET BT SSP 2 1 # 2:keyboard only 1:Man-in-the-middle protection is needed
180 SET BT SSP 2 0 # 2:keyboard only 0:Man-in-the-middle protection is not needed
181
182
183 SET BT SSP 2 1
184 bond only if MITM protection is supported by host
185 SET BT SSP 2 0
186 bond even if MITM protection is not supported by host
187
188 On Windows 'Add device' causes SSP PASSKEY event on iWRAP
189 SSP PASSKEY 78:dd:08:b7:e4:a2 ?
190
191 If device has display(0 or 1) this event occurs. User should be shown this code on the device.
192 SSP CONFIRM 78:dd:08:b7:e4:a2 517572
193
194
195 SET BT SSP 3 0
196 No input/output, No MITM protection.
197 Without procedure of authentication the divice is bond to host.
198
199
200 Connect
201 =======
202 CALL 78:dd:08:b7:e4:a2 11 HID
203
204
205 Setting
206 ========
207 SET BT PAIR *
208 SET RESET
209
210 SET BT CLASS 0005c0
211 SET BT AUTH * 0000
212 SET BT SSP 2 0
213 SET CONTROL CONFIG 800
214 SET PROFILE HID 0f c0 0100 00 en 0409 Bluetooth keyboard
215 SET PROFILE SPP
216
217 SET CONTROL INIT SET CONTROL MUX 0
218 SET BT NAME TMK Blootooth WT12
219 SET PROFILE HID 0f c0 0100 00 en 0409 TMK Bluetooth keyboard(WT12)
220 SDP ADD 1124 HID
221 SET BT PAIRCOUNT 4
222 SET BT POWER 3 3 3
223 SET BT SNIFF 100 20 1 8
224 RESET
225
226 SET CONTROL BAUD 38400,8n1
227
228 # combo keyboard + mouse
229 HID SET 7f 05010906a1010507850119e029e715002501750195088102950175088101950575010508850119012905910295017503910395067508150025650507190029658100c005010902a1010901a1008502050919012903150025019503750181020501093815f1250f9501750581060501093009311581257f750895028106c0c0
230
231 HID SET d1 05010906a1010507850119e029e715002501750195088102950175088101950575010508850119012905910295017503910395067508150025650507190029658100c005010902a1010901a1008502050919012903150025019503750181020501093815f1250f9501750581060501093009311581257f750895028106c0c0050c0901a1018503050c1500250109e909ea09e209cd19b529b87501950881020a8a010a21020a2a021a23022a27027501950881020a83010a96010a92010a9e010a94010a060209b209b4750195088102c0
232
233
234 ---------------------
235 SET BT BDADDR 00:07:80:47:22:14
236 SET BT NAME TMK BT WT12
237 SET BT CLASS 0005c0
238 SET BT AUTH * 0000
239 SET BT IDENT BT:47 f000 5.0.1 Bluegiga iWRAP
240 SET BT LAP 9e8b33
241 SET BT PAGEMODE 4 2000 1
242 SET BT PAIRCOUNT 4
243 SET BT PAIR 78:dd:08:b7:e4:a2 fe2fd79e86c6bbfa9351a032bceb2648
244 SET BT POWER 3 3 3
245 SET BT ROLE 1 f 12c0
246 SET BT SNIFF 100 20 1 8
247 SET BT SSP 3 0
248 SET BT MTU 672
249 SET CONTROL BAUD 38400,8n1
250 SET CONTROL CD 00 0
251 SET CONTROL ECHO 7
252 SET CONTROL ESCAPE - 20 1
253 SET CONTROL GAIN 0 5
254 SET CONTROL INIT SET CONTROL MUX 0
255 SET CONTROL MSC DTE 00 00 00 00 00 00
256 SET CONTROL PIO 00 00
257 SET CONTROL READY 00
258 SET PROFILE HID 0f c0 0100 00 en 0409 TMK Bluetooth keyboard
259 SET
260 SET control config list
261 SET CONTROL CONFIG 0000 0000 0000 410e CLOCK_CACHE INTERLACED_INQ INTERLACED_PAGE KLUDGE UART_LATENCY
262
263
264
265 WRAP THOR AI (5.0.1 build 620)
266 Copyright (c) 2003-2012 Bluegiga Technologies Inc.
267 Compiled on Oct 1 2012 10:56:21, running on WT12-A module, psr v31
268 BGIO FTP HFP HFP_AG HID HID_CONSUMER_PAGE HSP MAP MDP OTA PBAP PIO=0x00fc SSP SUBRATE TEST VOLUME
269 - BOCK4 version 620 (Oct 1 2012 10:56:03) (max acl/sco 7/1)
270 - Bluetooth version 3.0, Power class 2
271 - Loader 8615, firmware 8825 (56-bit encryption), native execution mode
272 - up 0 days, 00:13, 0 connections (pool 1)
273 - User configuration:
274 &028b = 0000 1388
275 &028c = 0001 0020 0100 0001 0008 0000
276 &028d = 0000
277 &0295 = 0000 0005 000b 0000 0003 0000 0000 0000 0000 0000 0000
278 &0298 = c006
279 &0299 = 0000 0000
280 &02a3 = 0030 0030 0030 0030
281 &02a4 = 009d 0000
282 &02a5 = 0053 0045 0054 0020 0043 004f 004e 0054 0052 004f 004c 0020 004d 0055 0058 0020 0030
283 &02a7 = 0000 05c0
284 &02a8 = 400e 0000 0000
285 &02aa = 0004 2000 0001 0033 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000
286 &02ab = 0001 000f 12c0
287 &02ac = 0000 0020 002b 0000 0000 0000 0000 0000 0000 0000 000a 0000 0000 0000 0004 0000 0000 0000 0000 02a0 0000 0000 0000 0000
288 &02ad = 4d54 204b 5442 5720 3154 0032
289 &02b0 = fa65 b0aa 934a 077b a600 d1cc fe58 8dd5
290 &02b3 = 0004 0004 0004 0000 0003 0003 0003 0003 0003 0003 0003 0003 0003 0003 0003 0003 000d 0007 0005 8afb 0005 0000 1c13 0000 0c3d 0005 b435 0006 b450 0006 0000 1416 000d
291 &02b7 = 000f 00c0 0100 0000 0065 006e 0409 4d54 204b 6c42 6575 6f74 746f 2068 656b 6279 616f 6472 0000
292 ---------------------
293
294
295 ----------
296 after SET RESET
297 ----------
298 WRAP THOR AI (5.0.1 build 620)
299 Copyright (c) 2003-2012 Bluegiga Technologies Inc.
300 READY.
301 set
302 SET BT BDADDR 00:07:80:47:22:14
303 SET BT NAME WT12
304 SET BT CLASS 001f00
305 SET BT IDENT BT:47 f000 5.0.1 Bluegiga iWRAP
306 SET BT LAP 9e8b33
307 SET BT PAGEMODE 4 2000 1
308 SET BT POWER 3 3 3
309 SET BT ROLE 0 f 7d00
310 SET BT SNIFF 0 20 1 8
311 SET BT SSP 3 0
312 SET BT MTU 667
313 SET CONTROL BAUD 115200,8n1
314 SET CONTROL CD 00 0
315 SET CONTROL ECHO 7
316 SET CONTROL ESCAPE 43 00 1
317 SET CONTROL GAIN 0 5
318 SET CONTROL MSC DTE 00 00 00 00 00 00
319 SET CONTROL PIO 00 00
320 SET CONTROL READY 00
321 SET PROFILE SPP Bluetooth Serial Port
322 SET
323
324
325 SET CONTROL CONFIG 0000 0000 0000 0100 KLUDGE
326
327
328 info config
329 WRAP THOR AI (5.0.1 build 620)
330 Copyright (c) 2003-2012 Bluegiga Technologies Inc.
331 Compiled on Oct 1 2012 10:56:21, running on WT12-A module, psr v31
332 BGIO FTP HFP HFP_AG HID HID_CONSUMER_PAGE HSP MAP MDP OTA PBAP PIO=0x00fc SSP SUBRATE TEST VOLUME
333 - BOCK4 version 620 (Oct 1 2012 10:56:03) (max acl/sco 7/1)
334 - Bluetooth version 3.0, Power class 2
335 - Loader 8615, firmware 8825 (56-bit encryption), native execution mode
336 - up 0 days, 00:00, 0 connections (pool 1)
337 - User configuration:
338 &0295 = 0000 0005 000b 0000 0003 0000 0000 0000 0000 0000 0000
339 &0299 = 0000 0000
340 &02aa = 0004 2000 0001 0033 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000
341 &02ac = 0000 0000 002b 0000 0000 0000 0000 0000 0000 0000 0002 0000 0000 0000 0010 0000 0000 0000 0000 029b 0000 0000 0000 0000
342 &02ad = 5457 3231
343 &02b0 = fa65 b0aa 934a 077b a600 d1cc fe58 8dd5
344 READY.
345 ----------
Imprint / Impressum