History log of /freebsd-11.0-release/usr.sbin/bluetooth/bthidd/hid.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 303975 11-Aug-2016 gjb

Copy stable/11@r303970 to releng/11.0 as part of the 11.0-RELEASE
cycle.

Prune svn:mergeinfo from the new branch, and rename it to RC1.

Update __FreeBSD_version.

Use the quarterly branch for the default FreeBSD.conf pkg(8) repo and
the dvd1.iso packages population.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 302408 08-Jul-2016 gjb

Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle.
Prune svn:mergeinfo from the new branch, as nothing has been merged
here.

Additional commits post-branch will follow.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


# 281210 07-Apr-2015 takawata

Check l2cap socket initialisation and define L2CAP_SOCKET_CHECKED
This will fix build.


# 281146 06-Apr-2015 rakuco

bthidd: Remove unused macros from hid.c.

ASIZE() was never used, and min() stopped being used in r207812.

Differential Revision: https://reviews.freebsd.org/D2230
Reviewed by: emax
Approved by: emax
MFC after: 1 week


# 281116 05-Apr-2015 rakuco

bthidd: Consider usage ranges when dealing with array inputs.

So far, we were always using HID_USAGE() to determine the Usage ID of a
certain HID report input item. This does not work as intended if a field
is an array and the allowed usages are specified with a usage range, as
HID_USAGE() will return 0. We need to use the field value as an index in
the usage range list in this case instead.

This makes the volume keys in a Microsoft Bluetooth Mobile Keyboard
5000 be properly recognized. The relevant part of the HID report looks
like this:

0xA1, 0x01, // Collection (Application)
0x85, 0x07, // Report ID (7)
0x05, 0x0C, // Usage Page (Consumer)
0x19, 0x00, // Usage Minimum (Unassigned)
0x2A, 0xFF, 0x03, // Usage Maximum (0x03FF)
0x95, 0x01, // Report Count (1)
0x75, 0x10, // Report Size (16)
0x15, 0x00, // Logical Minimum (0)
0x27, 0xFF, 0x03, 0x00, 0x00, // Logical Maximum (1023)
0x81, 0x00, // Input (Data,Array,Abs,No Wrap,Linear,Preferred
// State,No Null Position)

When a key such as "volume down" is pressed, the following data is
transferred through Interrupt In:

0x07 0xEA 0x00

Differential Revision: https://reviews.freebsd.org/D2229
Reviewed by: emax
Approved by: emax
MFC after: 1 week


# 221448 04-May-2011 emax

Encode horizontal scroll events (AC Pan) as button presses (bit 5 and 6)

Submitted by: David Demelier demelier dot david at gmail dot com
MFC after: 1 week


# 212335 08-Sep-2010 emax

Make sure to only pickup hid_input items when parsing input reports.
As it turns out, libusbhid(3) also picks up hic_collection items even
though we explicitly requested hid_input items only.

Tested by: Buganini < buganini at gmail dot com >
MFC after: 1 week


# 207812 09-May-2010 kaiw

Catch up with libusbhid merge (rev 205728).

hid_get_data() now expects that the hid data passed in always contains
the report ID byte. Thus we should not skip the the report ID byte in
hid_interrupt(). Also, if HUP_KEYBOARD usage is an array, do not try
to modify the 'data' pointer, instead, increase the hid_item_t field
'pos' by 'report_size' before calling hid_get_data() during each
iteration.

PR: usb/146367
Reported and tested by: Alex Deiter
Pointy hat to: kaiw
Reviewed by: emax


# 163185 09-Oct-2006 markus

Fix a typo introduced in the last commit: WWW Refresh is 0x227, not 0227

Approved by: emax (mentor)
MFC after: 1 day


# 162128 07-Sep-2006 emax

Update bthidd(8) code and hook it up to the build.
bthidd(8) now was integrated with vkbd(4) and supports
multiple keyboards via vkbd(4)/kbdmux(4).

The code was tested with Apple Bluetooth keyboard and
SE k700i cell phone (remote control feature).

MFC after: 1 month


# 156965 21-Mar-2006 emax

Properly map mouse buttons

PR: bin/94577
Submitted by: Krzysztof Jedruczyk < beaker at hot dot pl >
MFC after: 3 days


# 156697 13-Mar-2006 emax

Fix typo

Submitted by: Iain Hibbert < plunky at rya-online dot net >
MFC after: 3 days


# 137868 18-Nov-2004 emax

Check in updated bthidd(8). This is still work in progress.


# 128080 10-Apr-2004 emax

Start committing Bluetooth HID (Human Interface Device) support.
Note: bthidd(8) is still not complete. Need to commit kernel
support (a-la Linux /dev/input) to feed HID events into kernel.
Also need to write bthidd(8) and bthidd.conf(5) man pages.