1
0
mirror of https://github.com/Optiboot/optiboot.git synced 2025-09-04 12:02:07 +03:00

Use STK_SW_MINOR/STK_SW_MAJOR instead of hardcoded 0x81/0x82 values.

This commit is contained in:
majekw
2015-09-26 20:28:03 +02:00
parent fc2368bbf5
commit 185738b801
2 changed files with 4 additions and 2 deletions

View File

@@ -528,9 +528,9 @@ int main(void) {
* Send optiboot version as "SW version"
* Note that the references to memory are optimized away.
*/
if (which == 0x82) {
if (which == STK_SW_MINOR) {
putch(optiboot_version & 0xFF);
} else if (which == 0x81) {
} else if (which == STK_SW_MAJOR) {
putch(optiboot_version >> 8);
} else {
/*

View File

@@ -42,3 +42,5 @@
#define STK_READ_OSCCAL 0x76 // 'v'
#define STK_READ_FUSE_EXT 0x77 // 'w'
#define STK_READ_OSCCAL_EXT 0x78 // 'x'
#define STK_SW_MAJOR 0x81 // ' '
#define STK_SW_MINOR 0x82 // ' '