USB_IsConnected is now cleared before the USB_Disconnect() event is fired in response to VBUS being removed.

Minor documentation improvements.
This commit is contained in:
Dean Camera 2009-05-19 10:33:29 +00:00
parent 2ee9fc7077
commit 4a8ac5e474
8 changed files with 39 additions and 28 deletions

View file

@ -89,6 +89,8 @@ ISR(USB_GEN_vect, ISR_BLOCK)
}
else
{
USB_IsConnected = false;
EVENT_USB_Disconnect();
USB_Detach();
@ -96,8 +98,6 @@ ISR(USB_GEN_vect, ISR_BLOCK)
USB_PLL_Off();
USB_REG_Off();
USB_IsConnected = false;
EVENT_USB_VBUSDisconnect();
USB_INT_Clear(USB_INT_VBUS);