]> git.donarmstrong.com Git - kiibohd-controller.git/blobdiff - Output/pjrcUSB/output_com.c
File and macro modifications for supporting Teensy 3.1
[kiibohd-controller.git] / Output / pjrcUSB / output_com.c
index 06ca58cc21aa8b19840efb8a1b2981cd113cb50c..78c797e93558a8e5a03e4fb446bfc026a11fe7fa 100644 (file)
@@ -22,7 +22,7 @@
 // ----- Includes -----
 
 // Compiler Includes
-#include <Lib/USBLib.h>
+#include <Lib/OutputLib.h>
 
 // Project Includes
 #include <scan_loop.h>
@@ -73,7 +73,7 @@ volatile uint8_t USBKeys_LEDs = 0;
 // ----- Functions -----
 
 // USB Module Setup
-inline void output_setup(void)
+inline void output_setup()
 {
        // Initialize the USB, and then wait for the host to set configuration.
        // If the Teensy is powered without a PC connected to the USB port,
@@ -105,3 +105,13 @@ inline void usb_send(void)
                scan_finishedWithUSBBuffer( USBKeys_Sent <= USBKeys_MaxSize ? USBKeys_Sent : USBKeys_MaxSize );
 }
 
+
+// Sets the device into firmware reload mode
+inline void output_firmwareReload()
+{
+#if defined(_at90usb162_) || defined(_atmega32u4_) || defined(_at90usb646_) || defined(_at90usb1286_)
+#elif defined(_mk20dx128_)
+       usb_device_reload();
+#endif
+}
+