SWRA770 august 2023 CC2564C
The following function is responsible for sending a response for an outstanding GET_PROTOCOL Transaction to the remote HID Host. This function returns zero upon successful execution and a negative value on all errors.
GetProtocolResponse requires two parameters which are ResultType, 0= rtSuccessful, 1= rtNotReady, 2= rtErrInvalidReportID, 3= rtErrUnsupportedRequest, 4=rtErrInvalidParameter, 5= rtErrUnknown, 6= rtErrFatal, 7= rtData and Protocol, 0= ptReport and 1=ptBoot.
HID_Get_Protocol_Response(BluetoothStackID, HIDID, (HID_Result_Type_t)TempParam->Params[0].intParam, (HID_Protocol_Type_t)TempParam->Params[1].intParam)
int BTPSAPI HID_Get_Protocol_Response(unsigned int BluetoothStackID, unsigned int HIDID, HID_Result_Type_t ResultType, HID_Protocol_Type_t Protocol)
The following function is responsible for sending the appropriate Response to an outstanding GET_PROTOCOL transaction. This function accepts the Bluetooth Stack ID of the Bluetooth Stack 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, this function responds to the GET_PROTOCOL request with a HANDSHAKE response that has a Result Code parameter of the specified Error Condition. If the ResultType specified is rtData, theGET_PROTOCOL transaction is responded to with a DATA Response that has the Protocol type 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.