SWRA770 august 2023 CC2564C
The following function is responsible for sending a response for an outstanding GET_IDLE Transaction to the remote HID Host. This function returns zero on successful execution and a negative value on all errors.
GetIdleResponse requires two parameters, ResultType, 0= rtSuccessful, 1= rtNotReady, 2= rtErrInvalidReportID, 3= rtErrUnsupportedRequest, 4= rtErrInvalidParameter, 5=rtErrUnknown, 6= rtErrFatal, 7= rtData and IdleRate.
HID_Get_Idle_Response(BluetoothStackID, HIDID, (HID_Result_Type_t)TempParam->Params[0].intParam, (Byte_t)TempParam->Params[1].intParam)
int BTPSAPI HID_Get_Idle_Response(unsigned int BluetoothStackID, unsigned int HIDID, HID_Result_Type_t ResultType, Byte_t IdleRate)
The following function is responsible for sending the appropriate Response to an outstanding GET_IDLE transaction. This function accepts the Bluetooth Stack ID of the BluetoothStack which is to send the response and the HID ID for which the connection has been established. The third parameter to this function is the Result Type that is to be associated with this response. The rtSuccessful Result Type is invalid for use with this function. If the rtNotReady through rtErrFatal Result Types are specified, then this function responds to the GET_IDLE Transaction with a HANDSHAKE response that has a Result Code parameter of the specified error condition. If the ResultType specified is rtData the GET_IDLEtransaction is responded to with a DATA Response that has the Idle Rate specified as the final parameter as the payload. This function returns zero if successful, or a negative return error code if there was an error.