Release v2.7.1

This commit is contained in:
slimih
2020-08-31 09:19:23 +01:00
parent d1a9b6baea
commit 60d163f271
12 changed files with 406 additions and 26 deletions

View File

@@ -448,6 +448,11 @@ static uint8_t USBD_CUSTOM_HID_Setup(USBD_HandleTypeDef *pdev,
uint16_t status_info = 0U;
USBD_StatusTypeDef ret = USBD_OK;
if (hhid == NULL)
{
return (uint8_t)USBD_FAIL;
}
switch (req->bmRequest & USB_REQ_TYPE_MASK)
{
case USB_REQ_TYPE_CLASS:
@@ -713,6 +718,11 @@ static uint8_t USBD_CUSTOM_HID_EP0_RxReady(USBD_HandleTypeDef *pdev)
{
USBD_CUSTOM_HID_HandleTypeDef *hhid = (USBD_CUSTOM_HID_HandleTypeDef *)pdev->pClassData;
if (hhid == NULL)
{
return (uint8_t)USBD_FAIL;
}
if (hhid->IsReportAvailable == 1U)
{
((USBD_CUSTOM_HID_ItfTypeDef *)pdev->pUserData)->OutEvent(hhid->Report_buf[0],