Fix missing bitshift in the AVR8 Pipe_GetBoundEndpointAddress() function.
authorDean Camera <dean@fourwalledcubicle.com>
Tue, 14 May 2013 14:31:29 +0000 (16:31 +0200)
committerDean Camera <dean@fourwalledcubicle.com>
Tue, 14 May 2013 14:31:29 +0000 (16:31 +0200)
LUFA/DoxygenPages/ChangeLog.txt
LUFA/Drivers/USB/Core/AVR8/Pipe_AVR8.h

index bf2a236..16d3fe6 100644 (file)
@@ -25,7 +25,7 @@
   *  - Core:
   *   - Fixed Low Speed USB devices broken when using the library HID Class driver (thanks to Michael)
   *   - Fixed possible register corruption in USB Host mode on AVR8 devices when ORDERED_EP_CONFIG is used (thanks to Martin Aakerberg)
-  *   - Fixed Pipe_GetBoundEndpointAddress() returning invalid endpoint directions on AVR8 architecture devices
+  *   - Fixed Pipe_GetBoundEndpointAddress() returning invalid endpoint directions on AVR8 architecture devices (thanks to decerri)
   *     under some circumstances
   *  - Library Applications:
   *   - Added handler for SCSI_CMD_START_STOP_UNIT in demos using the Mass Storage class, to prevent ejection errors on *nix systems due to an
index 82664f5..b396263 100644 (file)
                                uint8_t UPCFG0X_Temp = UPCFG0X;
 
                                return (((UPCFG0X_Temp >> PEPNUM0) & PIPE_EPNUM_MASK) |
-                                       ((UPCFG0X_Temp & PTOKEN1) ? ENDPOINT_DIR_IN : ENDPOINT_DIR_OUT));
+                                       ((UPCFG0X_Temp & (1 << PTOKEN1)) ? ENDPOINT_DIR_IN : ENDPOINT_DIR_OUT));
                        }
 
                        /** Sets the period between interrupts for an INTERRUPT type pipe to a specified number of milliseconds.