[Bug][Core] Fix optical sensor firmware upload (#15919)
This commit is contained in:
parent
24324378a8
commit
6ebb44f17e
5 changed files with 21 additions and 28 deletions
|
@ -135,10 +135,8 @@ void adns9800_init() {
|
|||
wait_us(15);
|
||||
|
||||
// send all bytes of the firmware
|
||||
unsigned char c;
|
||||
for (int i = 0; i < FIRMWARE_LENGTH; i++) {
|
||||
c = (unsigned char)pgm_read_byte(adns9800_firmware_data + i);
|
||||
spi_write(c);
|
||||
for (uint16_t i = 0; i < FIRMWARE_LENGTH; i++) {
|
||||
spi_write(pgm_read_byte(firmware_data + i));
|
||||
wait_us(15);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue