mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-06-07 00:42:50 +00:00
Renamed all driver termination *_ShutDown() functions to the more logical name *_Disable().
This commit is contained in:
parent
9051d3beb0
commit
43b9d552bb
@ -155,7 +155,7 @@ void SetupHardware(void)
|
|||||||
void ResetHardware(void)
|
void ResetHardware(void)
|
||||||
{
|
{
|
||||||
/* Shut down the USB subsystem */
|
/* Shut down the USB subsystem */
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
/* Relocate the interrupt vector table back to the application section */
|
/* Relocate the interrupt vector table back to the application section */
|
||||||
MCUCR = (1 << IVCE);
|
MCUCR = (1 << IVCE);
|
||||||
|
@ -81,7 +81,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -219,7 +219,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -211,7 +211,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -237,7 +237,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -243,7 +243,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -280,7 +280,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -198,7 +198,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -228,7 +228,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -202,7 +202,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -227,7 +227,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -196,7 +196,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -172,7 +172,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -114,7 +114,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -105,7 +105,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -108,7 +108,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -104,7 +104,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -103,7 +103,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
printf_P(PSTR(ESC_FG_RED "Host Mode Error\r\n"
|
||||||
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
" -- Error Code %d\r\n" ESC_FG_WHITE), ErrorCode);
|
||||||
|
@ -421,8 +421,8 @@
|
|||||||
/** Turns off the ADC. If this is called, any further ADC operations will require a call to
|
/** Turns off the ADC. If this is called, any further ADC operations will require a call to
|
||||||
* \ref ADC_Init() before the ADC can be used again.
|
* \ref ADC_Init() before the ADC can be used again.
|
||||||
*/
|
*/
|
||||||
static inline void ADC_ShutDown(void) ATTR_ALWAYS_INLINE;
|
static inline void ADC_Disable(void) ATTR_ALWAYS_INLINE;
|
||||||
static inline void ADC_ShutDown(void)
|
static inline void ADC_Disable(void)
|
||||||
{
|
{
|
||||||
ADCSRA = 0;
|
ADCSRA = 0;
|
||||||
}
|
}
|
||||||
|
@ -175,8 +175,8 @@
|
|||||||
/** Turns off the TWI driver hardware. If this is called, any further TWI operations will require a call to
|
/** Turns off the TWI driver hardware. If this is called, any further TWI operations will require a call to
|
||||||
* \ref TWI_Init() before the TWI can be used again.
|
* \ref TWI_Init() before the TWI can be used again.
|
||||||
*/
|
*/
|
||||||
static inline void TWI_ShutDown(void) ATTR_ALWAYS_INLINE;
|
static inline void TWI_Disable(void) ATTR_ALWAYS_INLINE;
|
||||||
static inline void TWI_ShutDown(void)
|
static inline void TWI_Disable(void)
|
||||||
{
|
{
|
||||||
TWCR &= ~(1 << TWEN);
|
TWCR &= ~(1 << TWEN);
|
||||||
}
|
}
|
||||||
|
@ -172,7 +172,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** Turns off the SPI driver, disabling and returning used hardware to their default configuration. */
|
/** Turns off the SPI driver, disabling and returning used hardware to their default configuration. */
|
||||||
static inline void SPI_ShutDown(void)
|
static inline void SPI_Disable(void)
|
||||||
{
|
{
|
||||||
DDRB &= ~((1 << 1) | (1 << 2));
|
DDRB &= ~((1 << 1) | (1 << 2));
|
||||||
PORTB &= ~((1 << 0) | (1 << 3));
|
PORTB &= ~((1 << 0) | (1 << 3));
|
||||||
|
@ -145,7 +145,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** Turns off the USART driver, disabling and returning used hardware to their default configuration. */
|
/** Turns off the USART driver, disabling and returning used hardware to their default configuration. */
|
||||||
static inline void Serial_ShutDown(void)
|
static inline void Serial_Disable(void)
|
||||||
{
|
{
|
||||||
UCSR1B = 0;
|
UCSR1B = 0;
|
||||||
UCSR1A = 0;
|
UCSR1A = 0;
|
||||||
|
@ -83,7 +83,7 @@ void USB_Init(
|
|||||||
USB_ResetInterface();
|
USB_ResetInterface();
|
||||||
}
|
}
|
||||||
|
|
||||||
void USB_ShutDown(void)
|
void USB_Disable(void)
|
||||||
{
|
{
|
||||||
USB_INT_DisableAllInterrupts();
|
USB_INT_DisableAllInterrupts();
|
||||||
USB_INT_ClearAllInterrupts();
|
USB_INT_ClearAllInterrupts();
|
||||||
|
@ -292,7 +292,7 @@
|
|||||||
* memory, endpoints and pipes. When turned off, no USB functionality can be used until the interface
|
* memory, endpoints and pipes. When turned off, no USB functionality can be used until the interface
|
||||||
* is restarted with the \ref USB_Init() function.
|
* is restarted with the \ref USB_Init() function.
|
||||||
*/
|
*/
|
||||||
void USB_ShutDown(void);
|
void USB_Disable(void);
|
||||||
|
|
||||||
/** Resets the interface, when already initialized. This will re-enumerate the device if already connected
|
/** Resets the interface, when already initialized. This will re-enumerate the device if already connected
|
||||||
* to a host, or re-enumerate an already attached device when in host mode.
|
* to a host, or re-enumerate an already attached device when in host mode.
|
||||||
|
@ -48,6 +48,7 @@
|
|||||||
* value if no character is received (to remain consistent with the CDC class driver byte reception routines)
|
* value if no character is received (to remain consistent with the CDC class driver byte reception routines)
|
||||||
* - Renamed the PRNT_Host_SendString(), CDC_Host_SendString() and CDC_Device_SendString() functions to *_SendData(), and
|
* - Renamed the PRNT_Host_SendString(), CDC_Host_SendString() and CDC_Device_SendString() functions to *_SendData(), and
|
||||||
* added new versions of the *_SendString() routines that expect a null terminated string instead
|
* added new versions of the *_SendString() routines that expect a null terminated string instead
|
||||||
|
* - Renamed all driver termination *_ShutDown() functions to the more logical name *_Disable()
|
||||||
* - Library Applications:
|
* - Library Applications:
|
||||||
* - Changed the XPLAINBridge software UART to use the regular timer CTC mode instead of the alternative CTC mode
|
* - Changed the XPLAINBridge software UART to use the regular timer CTC mode instead of the alternative CTC mode
|
||||||
* via the Input Capture register, to reduce user confusion
|
* via the Input Capture register, to reduce user confusion
|
||||||
|
@ -44,8 +44,8 @@
|
|||||||
*
|
*
|
||||||
* void Jump_To_Bootloader(void)
|
* void Jump_To_Bootloader(void)
|
||||||
* {
|
* {
|
||||||
* // If USB is used, detach from the bus
|
* // If USB is used, detach from the bus and reset it
|
||||||
* USB_ShutDown();
|
* USB_Disable();
|
||||||
*
|
*
|
||||||
* // Disable all interrupts
|
* // Disable all interrupts
|
||||||
* cli();
|
* cli();
|
||||||
|
@ -172,7 +172,7 @@ void ISPTarget_DisableTargetISP(void)
|
|||||||
{
|
{
|
||||||
if (HardwareSPIMode)
|
if (HardwareSPIMode)
|
||||||
{
|
{
|
||||||
SPI_ShutDown();
|
SPI_Disable();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -204,7 +204,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
|
LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
|
||||||
for(;;);
|
for(;;);
|
||||||
|
@ -163,7 +163,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
|
|||||||
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
|
||||||
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
|
||||||
{
|
{
|
||||||
USB_ShutDown();
|
USB_Disable();
|
||||||
|
|
||||||
LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
|
LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
|
||||||
for(;;);
|
for(;;);
|
||||||
|
Loading…
Reference in New Issue
Block a user