mirror of
https://github.com/sanni/cartreader.git
synced 2024-11-14 17:05:08 +01:00
Add a progressbar to Pokemon Mini
Add a progressbar to Pokemon Mini
This commit is contained in:
parent
8823603630
commit
74aaaa4d0e
@ -263,18 +263,24 @@ void readROM_POKE() {
|
|||||||
foldern++;
|
foldern++;
|
||||||
EEPROM_writeAnything(0, foldern);
|
EEPROM_writeAnything(0, foldern);
|
||||||
|
|
||||||
|
// read rom
|
||||||
|
uint32_t progress = 0;
|
||||||
|
draw_progressbar(0, 0x80000);
|
||||||
for (uint32_t addr = 0; addr < 0x80000; addr += 512) { // 512K
|
for (uint32_t addr = 0; addr < 0x80000; addr += 512) { // 512K
|
||||||
for (int w = 0; w < 512; w++) {
|
for (int w = 0; w < 512; w++) {
|
||||||
uint8_t temp = readData_POKE(addr + w);
|
uint8_t temp = readData_POKE(addr + w);
|
||||||
sdBuffer[w] = temp;
|
sdBuffer[w] = temp;
|
||||||
}
|
}
|
||||||
myFile.write(sdBuffer, 512);
|
myFile.write(sdBuffer, 512);
|
||||||
|
progress += 512;
|
||||||
|
draw_progressbar(progress, 0x80000);
|
||||||
}
|
}
|
||||||
myFile.close();
|
myFile.close();
|
||||||
|
|
||||||
|
// compare dump CRC with db values
|
||||||
compareCRC("pkmn.txt", 0, 1, 0);
|
compareCRC("pkmn.txt", 0, 1, 0);
|
||||||
|
|
||||||
println_Msg(F(""));
|
println_Msg(F(""));
|
||||||
|
|
||||||
// Prints string out of the common strings array either with or without newline
|
// Prints string out of the common strings array either with or without newline
|
||||||
print_STR(press_button_STR, 1);
|
print_STR(press_button_STR, 1);
|
||||||
display_Update();
|
display_Update();
|
||||||
|
Loading…
Reference in New Issue
Block a user