@ -276,7 +276,7 @@ uint8_t USB_ProcessHIDReport(const uint8_t* ReportData,
{
{
UsageMinMax . Minimum = 0 ;
UsageMinMax . Minimum = 0 ;
UsageMinMax . Maximum = 0 ;
UsageMinMax . Maximum = 0 ;
UsageListSize = 0 ;
UsageListSize = 0 ;
}
}
}
}
@ -293,9 +293,6 @@ bool USB_GetHIDReportItemInfo(const uint8_t* ReportData,
uint16_t CurrentBit = ReportItem - > BitOffset ;
uint16_t CurrentBit = ReportItem - > BitOffset ;
uint32_t BitMask = ( 1 < < 0 ) ;
uint32_t BitMask = ( 1 < < 0 ) ;
ReportItem - > PreviousValue = ReportItem - > Value ;
ReportItem - > Value = 0 ;
if ( ReportItem - > ReportID )
if ( ReportItem - > ReportID )
{
{
if ( ReportItem - > ReportID ! = ReportData [ 0 ] )
if ( ReportItem - > ReportID ! = ReportData [ 0 ] )
@ -304,6 +301,9 @@ bool USB_GetHIDReportItemInfo(const uint8_t* ReportData,
ReportData + + ;
ReportData + + ;
}
}
ReportItem - > PreviousValue = ReportItem - > Value ;
ReportItem - > Value = 0 ;
while ( DataBitsRem - - )
while ( DataBitsRem - - )
{
{
if ( ReportData [ CurrentBit / 8 ] & ( 1 < < ( CurrentBit % 8 ) ) )
if ( ReportData [ CurrentBit / 8 ] & ( 1 < < ( CurrentBit % 8 ) ) )