Updated revision number according to bug report #2

This commit is contained in:
Markus Koch 2014-01-28 15:55:05 +01:00
parent 77818dde76
commit 37d1cb9f2c
1 changed files with 6 additions and 7 deletions

View File

@ -24,7 +24,7 @@ uint8_t keyType[16]; // Will contain whether the key has to be handled as a ...
// MEMORY ARCHITECTURE (INTERNAL)
#define MEM_SERIAL_OFFSET 0
#define MEM_SERIAL_LENGTH 16
#define MEM_SERIAL_LENGTH 8
// MEM. ARCH. (EXTERNAL)
#define MEM_KEY_LENGTH 512 // 512B * 16 -> 8KByte (64Kbit)
@ -36,11 +36,10 @@ uint8_t keyType[16]; // Will contain whether the key has to be handled as a ...
#define CMD_EEREAD 3
#define CMD_EEOPEN 4 // Can be used if errors occour while writing to the device.
#define CMD_RESET 5 // WDT RESET
#define CMD_SERIAL 6 // DEV-Serial PRGKBD0010911001 --> This data sits in the INETRNAL eeprom
// 6B PRGKBD
// 3B HW_REV
// 4B HW_Date (MMYY)
// 3B ID
#define CMD_SERIAL 6 // DEV-Serial 1-"0811"-000 --> This data sits in the INTERNAL eeprom
// 1B HW-Revision (Number/10)
// 4B HW-Date (MMYY)
// 3B HW-ID (Number)
#define CMD_IEEWRITE 7 //internal eeprom
#define CMD_IEEREAD 8 // int. eep.
#define CMD_EXEC 9 // execute from addr.
@ -198,7 +197,7 @@ static uchar reportBuffer[24];
wdt_enable(WDTO_15MS); // faster reboot
while (1); // Wait 'til the watchdog resets our system
}
else if(rq->bRequest == CMD_SERIAL) { // CURRENTLY NOT WORKING!
else if(rq->bRequest == CMD_SERIAL) {
uint8_t x;
for (x=0; x < MEM_SERIAL_LENGTH; x++) {
reportBuffer[x] = eeprom_read_byte(x+MEM_SERIAL_OFFSET);