Fixed TeensyHID bootloader so that it works with the official TeensyLoader GUI applic...
[pub/lufa.git] / Bootloaders / TeensyHID / TeensyHID.c
index 5431a57..4e287bc 100644 (file)
@@ -120,7 +120,7 @@ void EVENT_USB_Device_UnhandledControlRequest(void)
                                boot_spm_busy_wait();\r
                                \r
                                /* Write each of the FLASH page's bytes in sequence */\r
-                               for (uint8_t PageByte = 0; PageByte < SPM_PAGESIZE; PageByte += 2)\r
+                               for (uint16_t PageByte = 0; PageByte < SPM_PAGESIZE; PageByte += 2)\r
                                {\r
                                        /* Check if endpoint is empty - if so clear it and wait until ready for next packet */\r
                                        if (!(Endpoint_BytesInEndpoint()))\r