hidd_set_usage_value()

Set value in report

Synopsis:

#include <sys/hiddi.h>

int hidd_set_usage_value( struct hidd_report_instance *report_instance,
                          struct hidd_collection *collection,
                          _Uint16t usage_page,
                          _Uint16t usage,
                          _Uint32t usage_value,
                          _Uint8t *report_data,
                          _Uint16t len);

Arguments:

report_instance

The HID stack connection handle (from hidd_connect()).

collection

Handle of the collection, as returned by hidd_get_collections() or by hidd_report_collection(). If collection is NULL, all collections are searched, other wise only the collection specified is searched.

usage_page

The usage page of the report (refer to the HID spec and HID usage tables).

usage

The usage page of the report (refer to the HID spec and HID usage tables).

usage_value
The value to set.
report_data

The report buffer you wish to fill in.

len

The length of the provided report buffer.

Description:

The hidd_set_usage_value() function sets the value for the usage defined in the usage_page in the provided report buffer. You would typically use this function to fill in a output/feature report before sending it to a HID device.

Returns:

EOK
Success.
ENOTCONN
The report_instance or report_data is NULL.
ENOENT

There is no entry in the report for usage_page or usage.

Classification:

QNX OS

Safety:
Cancellation point Yes
Signal handler No
Thread Yes
Page updated: