reuse common string "ROM Size: "

This commit is contained in:
smesgr9000 2024-06-29 11:28:41 +02:00
parent acc069e103
commit 9e13964889
19 changed files with 26 additions and 23 deletions

View File

@ -332,7 +332,7 @@ void checkMapperSize_5200() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_5200(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(a5200[index]);
}
#endif

View File

@ -478,7 +478,7 @@ void println_Mapper7800(byte mapper) {
void printRomSize_7800(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(a7800[index]);
}
#endif

View File

@ -179,7 +179,7 @@ void readROM_ARC() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_ARC(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(ARC[index]);
}
#endif

View File

@ -629,7 +629,7 @@ void checkMapperSize_C64() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_C64(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(C64[index]);
}
#endif

View File

@ -204,7 +204,7 @@ void readROM_COL() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_COL(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(pgm_read_byte(&(COL[index])));
}
#endif

View File

@ -496,7 +496,7 @@ void read16K_FAIRCHILD() { // Read 16K Bytes
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_FAIRCHILD(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(FAIRCHILD[index]);
}
#endif

View File

@ -597,7 +597,7 @@ void showCartInfo_GB() {
print_Msg(F("M161"));
println_Msg(FS(FSTRING_EMPTY));
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
switch (romSize) {
case 0:
print_Msg(F("32 KB"));
@ -2486,7 +2486,8 @@ void readPelican_GB() {
if (flashid == 0xDA45 || flashid == 0xBF10) {
println_Msg(F("29EE020 / W29C020"));
println_Msg(F("Banks Used: 32/64"));
println_Msg(F("Rom Size: 256 KB"));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(F("256 KB"));
romBanks = 32;
display_Update();
} else {
@ -2514,7 +2515,8 @@ void readPelican_GB() {
if (flashid == 0xBF04) {
println_Msg(F("SST 28LF040"));
println_Msg(F("Banks Used: 64/64"));
println_Msg(F("Rom Size: 512 KB"));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(F("512 KB"));
romBanks = 64;
display_Update();
}
@ -3185,7 +3187,8 @@ void readGameshark_GB() {
if (flashid == 0xBFB5) {
display_Clear();
println_Msg(F("SST 39SF010"));
println_Msg(F("Rom Size: 128 KB"));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(F("128 KB"));
display_Update();
} else {
display_Clear();

View File

@ -258,7 +258,7 @@ void setup_GBA() {
println_Msg(cartID);
print_Msg(F("Revision: "));
println_Msg(romVersion);
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
if (cartSize == 0)
println_Msg(F("Unknown"));
else {
@ -683,7 +683,7 @@ void getCartInfo_GBA() {
println_Msg(gamename);
print_Msg(F("Serial: "));
println_Msg(tempStr);
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
print_Msg(cartSize);
println_Msg(F(" MB"));
print_Msg(F("Save Lib: "));

View File

@ -524,7 +524,7 @@ void checkMapperSize_INTV() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_INTV(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(pgm_read_byte(&(INTV[index])));
}
#endif

View File

@ -2888,7 +2888,7 @@ void readRealtec_MD() {
void printRomSize_MD(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
print_Msg(pgm_read_byte(&(MDSize[index])));
println_Msg(F(" Mbit"));
}

View File

@ -889,7 +889,7 @@ void checkMapperSize_MSX() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_MSX(uint8_t index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(MSX[index]);
}
#endif

View File

@ -1929,7 +1929,7 @@ void printCartInfo_N64() {
println_Msg(cartID);
print_Msg(F("Revision: "));
println_Msg(romVersion);
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
print_Msg(cartSize);
println_Msg(F(" MB"));
print_Msg(F("Save Type: "));

View File

@ -188,7 +188,7 @@ void printCartInfo_NGP() {
else
println_Msg(F("Unknown"));
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
if (cartSize == 0) {
println_Msg(F("Unknown"));
} else {

View File

@ -257,7 +257,7 @@ void readROM_ODY2() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_ODY2(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(ODY2[index]);
}
#endif

View File

@ -77,7 +77,7 @@ constexpr char PROGMEM FSTRING_MAPPER[] = "Mapper: ";
constexpr char PROGMEM FSTRING_SIZE[] = "Size: ";
constexpr char PROGMEM FSTRING_NAME[] = "Name: ";
constexpr char PROGMEM FSTRING_CHECKSUM[] = "Checksum: ";
constexpr char PROGMEM FSTRING_ROM_SIZE[] ="ROM SIZE: ";
constexpr char PROGMEM FSTRING_ROM_SIZE[] ="ROM Size: ";
/*==== /CONSTANTS =================================================*/

View File

@ -416,7 +416,7 @@ static void checkRomExist_Acan() {
if (cartSize == 0)
print_Error(F("Unable to find rom signature..."));
else {
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
print_Msg(romSize);
println_Msg(F(" Mb"));
}

View File

@ -238,7 +238,7 @@ void readROM_VECTREX() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_VECTREX(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(VECTREX[index]);
}
#endif

View File

@ -376,7 +376,7 @@ static void showCartInfo_WS() {
print_Msg(F("Game: "));
println_Msg(romName);
print_Msg(F("Rom Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
if (cartSize == 0x00)
println_Msg(romSize, HEX);
else {

View File

@ -222,7 +222,7 @@ void readROM_WSV() {
#if (defined(ENABLE_OLED) || defined(ENABLE_LCD))
void printRomSize_WSV(int index) {
display_Clear();
print_Msg(F("ROM Size: "));
print_Msg(FS(FSTRING_ROM_SIZE));
println_Msg(pgm_read_word(&(WSV[index])));
}
#endif