summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/bootloader.c7
-rw-r--r--common/command.c47
2 files changed, 46 insertions, 8 deletions
diff --git a/common/bootloader.c b/common/bootloader.c
index 43a7e47ce2..cda295b181 100644
--- a/common/bootloader.c
+++ b/common/bootloader.c
@@ -71,7 +71,8 @@ void bootloader_jump_after_watchdog_reset(void)
MCUSR &= ~(1<<WDRF);
wdt_disable();
- ((void (*)(void))BOOTLOADER_START)();
+ // This is compled into 'icall', address should be in word unit, not byte.
+ ((void (*)(void))(BOOTLOADER_START/2))();
}
}
@@ -141,7 +142,7 @@ void bootloader_jump(void) {
ADCSRA = 0; TWCR = 0; UCSR0B = 0;
#endif
- // start Bootloader
- ((void (*)(void))BOOTLOADER_START)();
+ // This is compled into 'icall', address should be in word unit, not byte.
+ ((void (*)(void))(BOOTLOADER_START/2))();
}
#endif
diff --git a/common/command.c b/common/command.c
index 7415645b0d..8a8a81d669 100644
--- a/common/command.c
+++ b/common/command.c
@@ -251,11 +251,48 @@ static bool command_common(uint8_t code)
break;
case KC_V: // print version & information
print("\n\n----- Version -----\n");
- print(STR(DESCRIPTION) "\n");
- print("VID: " STR(VENDOR_ID) "(" STR(MANUFACTURER) ") PID: " STR(PRODUCT_ID) "(" STR(PRODUCT) ") VER: " STR(DEVICE_VER) "\n");
- print("SRC: " STR(VERSION) "\n");
- print("GCC: " STR(__GNUC__) "." STR(__GNUC_MINOR__) "." STR(__GNUC_PATCHLEVEL__) "\n");
- print("AVR-LIBC: " __AVR_LIBC_VERSION_STRING__ "\n");
+ print("DESC: " STR(DESCRIPTION) "\n");
+ print("VID: " STR(VENDOR_ID) "(" STR(MANUFACTURER) ") "
+ "PID: " STR(PRODUCT_ID) "(" STR(PRODUCT) ") "
+ "VER: " STR(DEVICE_VER) "\n");
+ print("BUILD: " STR(VERSION) " (" __TIME__ " " __DATE__ ")\n");
+ /* build options */
+ print("OPTIONS:"
+#ifdef PROTOCOL_PJRC
+ " PJRC"
+#endif
+#ifdef PROTOCOL_LUFA
+ " LUFA"
+#endif
+#ifdef PROTOCOL_VUSB
+ " VUSB"
+#endif
+#ifdef BOOTMAGIC_ENABLE
+ " BOOTMAGIC"
+#endif
+#ifdef MOUSEKEY_ENABLE
+ " MOUSEKEY"
+#endif
+#ifdef EXTRAKEY_ENABLE
+ " EXTRAKEY"
+#endif
+#ifdef CONSOLE_ENABLE
+ " CONSOLE"
+#endif
+#ifdef COMMAND_ENABLE
+ " COMMAND"
+#endif
+#ifdef NKRO_ENABLE
+ " NKRO"
+#endif
+#ifdef KEYMAP_SECTION_ENABLE
+ " KEYMAP_SECTION"
+#endif
+ " " STR(BOOTLOADER_SIZE) "\n");
+
+ print("GCC: " STR(__GNUC__) "." STR(__GNUC_MINOR__) "." STR(__GNUC_PATCHLEVEL__)
+ " AVR-LIBC: " __AVR_LIBC_VERSION_STRING__
+ " AVR_ARCH: avr" STR(__AVR_ARCH__) "\n");
break;
case KC_T: // print timer
print_val_hex32(timer_count);