hidd_set_protocol()

Set device protocol

Synopsis:

#include <sys/hiddi.h>

int hidd_set_protocol( struct hidd_connection *connection,
                       struct hidd_device_instance * device_instance,
                       _Uint8t protocol );

Arguments:

connection

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

device_instance

A pointer to hidd_device_instance_t instance containing the number of the device.

protocol

Value indicating the protocol to use; either HID_PROTOCOL_BOOT or HID_PROTOCOL_REPORT.

Description:

The hidd_set_protocol() function sets the device protocol.

Returns:

EOK
Success.
ENOTCONN
The connection is NULL.
EINVAL

The device_instance is NULL.

ENODEV

The device was removed.

ENOTSUP

The device doesn't implement this feature.

This function can also return a device-specific error code.

Classification:

QNX OS

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