Firmware: Page size for `USB_REQ_CYPRESS_EEPROM_DB` not set
In `firmware/main.c`, `USB_REQ_LIBFX2_PAGE_SIZE` is explicitly ignored (see line 433), but the eeprom write page size is not set in the path for `USB_REQ_CYPRESS_EEPROM_DB` (see line 446). This results in a page size of one byte being used, instead of a page size of 64 bytes.
This is a minor issue because as far as I can tell:
a) this would only be encountered by someone using `write_boot_eeprom` from libfx2
b) it still works, but is slower than it would using a page size of 64.
I'm happy either leaving this alone, or making a pull request to fix it, which would increase the code size by ~8 bytes.
There is also argument to be made for using a constant page size of 64. Since the size of control transfers is at most 64 bytes, there is no benefit to using the full 256 byte page size of the ICE EEPROM.. This would reduce the code size by ~3 bytes.
关闭于 2025-08-03 1 条评论