Speed up bit-banged USART code in the AVRISP project.
[pub/USBasp.git] / LUFA / Drivers / USB / LowLevel / Pipe.c
index 3f5272a..fd8f81b 100644 (file)
@@ -78,7 +78,7 @@ bool Pipe_IsEndpointBound(const uint8_t EndpointAddress)
        {\r
                Pipe_SelectPipe(PNum);\r
                \r
-               if (Pipe_IsConfigured() && (Pipe_BoundEndpointNumber() == EndpointAddress))\r
+               if (Pipe_IsConfigured() && (Pipe_BoundEndpointNumber() == (EndpointAddress & PIPE_EPNUM_MASK)))\r
                  return true;\r
        }\r
        \r
@@ -130,7 +130,7 @@ uint8_t Pipe_Discard_Stream(uint16_t Length
 {\r
        uint8_t  ErrorCode;\r
        \r
-       Pipe_SetToken(PIPE_TOKEN_IN);\r
+       Pipe_SetPipeToken(PIPE_TOKEN_IN);\r
 \r
        if ((ErrorCode = Pipe_WaitUntilReady()))\r
          return ErrorCode;\r