mirror of
https://github.com/mariusgreuel/avrdude.git
synced 2025-09-27 22:45:27 +00:00
Provide self-documenting API for disabling trailing-0xff removal
This commit is contained in:
@@ -131,6 +131,5 @@ void arduino_initpgm(PROGRAMMER * pgm)
|
||||
pgm->open = arduino_open;
|
||||
pgm->close = arduino_close;
|
||||
|
||||
/* disable trailing-0xff removal when reading input files and avr flash */
|
||||
avr_mem_hiaddr(NULL);
|
||||
disable_trailing_ff_removal(); /* so that arduino bootloader can ignore chip erase */
|
||||
}
|
||||
|
@@ -787,6 +787,7 @@ int avr_get_cycle_count(PROGRAMMER * pgm, AVRPART * p, int * cycles);
|
||||
|
||||
int avr_put_cycle_count(PROGRAMMER * pgm, AVRPART * p, int cycles);
|
||||
|
||||
#define disable_trailing_ff_removal() avr_mem_hiaddr(NULL)
|
||||
int avr_mem_hiaddr(AVRMEM * mem);
|
||||
|
||||
int avr_chip_erase(PROGRAMMER * pgm, AVRPART * p);
|
||||
|
@@ -528,7 +528,7 @@ int main(int argc, char * argv [])
|
||||
|
||||
case 'D': /* disable auto erase */
|
||||
uflags &= ~UF_AUTO_ERASE;
|
||||
avr_mem_hiaddr(NULL); /* disable trailing 0xff optimisation */
|
||||
disable_trailing_ff_removal();
|
||||
break;
|
||||
|
||||
case 'e': /* perform a chip erase */
|
||||
|
Reference in New Issue
Block a user