Move the declaration of the HID Get Report Limit function and provide its definition

This commit is contained in:
mbanth
2021-11-29 17:09:26 +00:00
parent 65b1b41ec4
commit 0892ff9a8b
3 changed files with 15 additions and 11 deletions

View File

@@ -55,17 +55,6 @@ typedef struct hidEvent_t {
*/
size_t UserHIDGetData( const unsigned id, unsigned char hidData[ HID_MAX_DATA_BYTES ]);
/**
* \brief Get the upper limit of HID Report identifiers
*
* This function returns the upper limit of the HID Report identifiers.
* The upper limit has a value one greater than the maximum HID Report identifier.
* In the case that HID Report identifiers are not in use, this function returns the value 1.
*
* \returns The upper limit of HID Report identifiers
*/
unsigned UserHIDGetReportIdLimit ( void );
/**
* \brief Initialize HID processing
*/

View File

@@ -179,6 +179,10 @@ size_t hidGetReportDescriptorLength( void )
return retVal;
}
unsigned hidGetReportIdLimit ( void ) {
return HID_REPORT_COUNT;
}
#define HID_CONFIGURABLE_ELEMENT_COUNT ( sizeof hidConfigurableElements / sizeof ( USB_HID_Report_Element_t* ))
unsigned hidGetReportItem(
const unsigned id,

View File

@@ -115,6 +115,17 @@ unsigned char* hidGetReportDescriptor( void );
*/
size_t hidGetReportDescriptorLength( void );
/**
* \brief Get the upper limit of HID Report identifiers
*
* This function returns the upper limit of the HID Report identifiers.
* The upper limit has a value one greater than the maximum HID Report identifier.
* In the case that HID Report identifiers are not in use, this function returns the value 1.
*
* \returns The upper limit of HID Report identifiers
*/
unsigned hidGetReportIdLimit ( void );
/**
* @brief Get a HID Report descriptor item
*