Skip to content

Commit

Permalink
not on pedal chip
Browse files Browse the repository at this point in the history
  • Loading branch information
geohot committed May 23, 2019
1 parent 0a9f8eb commit 881b1f4
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions board/spi_flasher.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,14 +48,16 @@ int usb_cb_control_msg(USB_Setup_TypeDef *setup, uint8_t *resp, int hardwired) {
break;
// **** 0xd0: fetch serial number
case 0xd0:
// addresses are OTP
if (setup->b.wValue.w == 1) {
memcpy(resp, (void *)0x1fff79c0, 0x10);
resp_len = 0x10;
} else {
get_provision_chunk(resp);
resp_len = PROVISION_CHUNK_LEN;
}
#ifdef STM32F4
// addresses are OTP
if (setup->b.wValue.w == 1) {
memcpy(resp, (void *)0x1fff79c0, 0x10);
resp_len = 0x10;
} else {
get_provision_chunk(resp);
resp_len = PROVISION_CHUNK_LEN;
}
#endif
break;
// **** 0xd1: enter bootloader mode
case 0xd1:
Expand Down

0 comments on commit 881b1f4

Please sign in to comment.