Commit Graph

130 Commits

Author SHA1 Message Date
sanni
d1b1c88af0 Fix reading Bahamut Lagoon English Translation SRAM (thx to Cowboyjunkie)
https://github.com/sanni/cartreader/issues/917
2024-06-30 11:50:11 +02:00
sanni
f798336aaa Always disable SRAM when flashing any hirom repros 2024-06-30 11:04:40 +02:00
smesgr9000
4e7ef93cc6 declare "Revision: " and "Serial: " as common string and reuse string 2024-06-29 11:48:32 +02:00
sanni
ce4e26c686 Fix verifyFlash() 2024-06-27 10:55:54 +02:00
sanni
fd82faca2d SNES: Add 2x2MB flash to CFI (thx to MouseBiteLabs) 2024-06-26 09:24:12 +02:00
smesgr9000
e1bd042d82 replace duplicate error string "Can't open file" 2024-06-16 00:39:21 +02:00
sanni
27a213a3c1
Add CFI option to SNES repro menu
Only tested with 29LV640 on Chinese LoROM repro.
2024-06-13 16:43:20 +02:00
smesgr9000
5b43a162b8 reuse common strings, remove duplicate 2024-05-30 08:00:13 +02:00
smesgr9000
d039c590cc define more commonly used string in OSCR and reuse them 2024-05-28 21:11:48 +02:00
smesgr9000
cb111077f8 replace NES defines with rgbLed function calls 2024-05-26 22:43:41 +02:00
smesgr9000
363d18b542 add common function to open create folder, print message and open file. Remove duplicate code 2024-05-26 22:20:47 +02:00
smesgr9000
41182a7eb0 add option to clear display and remove duplicate code 2024-05-25 14:25:35 +02:00
smesgr9000
6abe29fcd9 remove duplicate code to print saving and increment of folder id 2024-05-25 14:07:08 +02:00
smesgr9000
9f0aa09197 remove duplicate code to create folder 2024-05-12 15:37:11 +02:00
smesgr9000
74352c6e31 define "File doesn't exist" in OSCR.cpp/h 2024-05-11 23:32:06 +02:00
sanni
ecc937bab3
Fix romType for Yuyu no Quiz de GO!GO!
https://github.com/sanni/cartreader/issues/922
2024-04-30 12:25:58 +02:00
Ancyker
e61ac414d8 Code optimization, cleanup, and stylization
* Reduced PROGMEM / DRAM usage slightly (Using defaults w/HW5: Before -> 214,668 bytes / 5,757 bytes; After -> 213,414 bytes / 5,751 bytes)
  * Optimized some menu options and calls
  * Added more string constants and implemented them where found.
* Fixed some stylization
  * Constants should always be uppercase.
  * Features should use the `ENABLE_<feature name>` format.
  * Options for features should use the `OPTION_<feature name>_<option name>` format.
  * Added ENUMs for more clarity and better type checking.
  * Moved some defines over to `constexpr` and `const` types. These are preferred over preprocessor constants when not intended for use with `#if` and other preprocessor language.
2024-03-02 11:26:35 -05:00
LuigiBlood
bbe37d9839 SNES: Add Game Processor RAM Cassette Read/Write support 2024-02-09 23:02:59 +01:00
PsyK0p4T
70d52636d7
Update SNES.ino
Add Sufami Turbo support
2023-11-25 00:32:51 +01:00
PsyK0p4T
a55aa7bbff
Update SNES.ino
Avoids a compilation warning
2023-11-20 21:46:44 +01:00
sanni
559010079c Add support for Atari 5200/7800, C64, Vectrex (thx to skaman) 2023-09-23 00:11:08 +02:00
But Thou Must
c88978f5ea SNES.ino: Fix dumping Sound Novel Tsukuru (Japan) with same fix as for Derby Stallion '96 (Japan) 2023-09-21 18:39:18 -04:00
sanni
34a1c6b336 Fix dumping Tactics Ogre 2023-07-04 19:58:45 +02:00
Ancyker
2cf7f5dbe7 Cleanup voltage requests
The `setVoltage()` function should be called even when `ENABLE_VSELECT` is disabled because `ENABLE_3V3FIX` also uses it. There is no resource cost to do this as when both options are disabled the compiler will optimize this function out. This just "future proofs" the code so if that function ever does more it doesn't need updated everywhere. This applies to `setup_FlashVoltage()` as well.

The changes to OSCR.cpp are just for code formatting and additional comments to clarify this.
2023-06-26 15:25:54 -04:00
sanni
3a2db439be Update SNES.ino 2023-06-26 12:27:45 +02:00
sanni
dee54dd30e Move automatic voltage selection from menu to setup functions 2023-06-26 12:04:00 +02:00
sanni
ff31141f7e
Fix Derby Stallion 96 2023-04-07 12:49:20 +02:00
Ancyker
010b7e7525 Firmware Updater support, 3.3V Fix, and more
Lots of changes/additions.

Added:
* Firmware Updater support: Supports the Firmware Updater app (release to follow soon). Enabled by default, can be disabled in the config.
* 3.3V Fix (3V3FIX): Enable if you have stability issues when using 3.3V, works best with VSELECT. Disabled by default, can be enabled in the config.
* `DynamicClockSerial`: Class that extends and modifies HardwareSerial to be compatible with a dynamically changing clock speed. Used through the `ClockedSerial` object/variable.
* `OSCR.cpp` & `OSCR.h`: New files for storing globals. Only contains these new additions for now. More code cleanup to come.

Changed:
* Moved configuration flags to `Config.h` and documented them better.
* Removed `vselect()` function. Now uses `setVoltage()` with the params `VOLTS_SET_3V3` and `VOLTS_SET_5V`.

Known Issues:
* Rarely the LCD backlight turns white when using 3V3FIX. Resetting fixes it. Doesn't affect functionality/usability; it's just weird.
2023-03-29 21:05:01 -04:00
sanni
d977b14cf4 Fix MD Zero Wing (E) (thx to jaffa225)
More info: https://github.com/sanni/cartreader/issues/664
2022-12-20 10:31:35 +01:00
splash5
eea4fb365f Do compareCRC when reading game in SFM.
Don't rename when calculate checksum, just use filename and folder.
2022-12-11 10:49:07 +08:00
splash5
ed1c1f0bea Fix SNES Daikaijuu Monogatari 2 2022-11-24 17:08:41 +08:00
Remy Starshade
aee632642d Add Voltage Selection Module 2022-11-12 14:13:22 -05:00
Vincent Pelletier
90303b45c0 SNES.ino: Restore code with side-effects
This code was removed as part of
  a555f21 ("All: Resolve all compiler and linker warnings")
because it was filling a 1kB buffer which was never read from.
While I expect reading values from PINC should be invisible from the
cartridge's perspective, writing to PORTL, PORTF and PORTK is definitely
visible.
I have currently no way of testing if this code is required, so in doubt
restore the parts which have effects visible from the cartridge.
2022-11-01 07:56:15 +00:00
Vincent Pelletier
c82815f0d5 SFM.ino, SNES.ino: Rework compiler warnings resolution
I am not sure why I changed some variables from 16 bit types to 8 bit types
when the warnings being resolved were only about signedness.
Fixes: a555f21 ("All: Resolve all compiler and linker warnings")
2022-11-01 07:53:35 +00:00
sanni
cc17c70e30 Fix reading/writing 4MB HiROM
HiROM starts at bank 192 and has 64 banks so byte variable currBank overflows.
2022-10-31 15:41:29 +01:00
Vincent Pelletier
f07f6f9025 All: Replace print_Error(*, boolean) calls with print_{,Fatal}Error(*)
Also, make print_FatalError(*) independent from print_Error(*).
Also, factorise common parts of print_Error(*).

Frees 2336 bytes of program space and 5 bytes of global ram space.
2022-10-31 08:52:33 +00:00
sanni
30d880bfa7 Fix SNES romName 2022-10-28 13:38:16 +02:00
Vincent Pelletier
67b54a690b All: Factorise title generation from cart.
Fix out-of-bound access when first byte is not an ascii printable
character.
Reduces program space use by 480 bytes.
2022-10-28 05:29:44 +00:00
Vincent Pelletier
3b05046ee9 All: Factorise CRC functions.
This saves 370 bytes of program space.
2022-10-28 05:29:41 +00:00
Vincent Pelletier
0a627e5bd4 All: Use f.seekCur(x) instead of f.seekSet(f.curPosition() + x)
Saves 450 bytes of program space.
2022-10-28 05:29:20 +00:00
Vincent Pelletier
a555f2117f All: Resolve all compiler and linker warnings
No functional change intended.
2022-10-28 05:29:20 +00:00
Vincent Pelletier
3fcd1a808d https://github.com/sanni/cartreader/issues/574#issuecomment-1286956251 2022-10-28 05:29:20 +00:00
sanni
5357dea659 Print checksum and header CRC32 when searching database 2022-10-27 23:43:46 +02:00
BacteriaMage
ab5f94af85 fix superfx sram size detection
The header offsets were wrong so the size wasn't correctly computed and generally ended up defaulting to 32KB. Stunt Race FX, at least, uses 64KB and so only half the save data was being read.
2022-10-25 19:54:40 -05:00
sanni
4badfff458 Move to Arduino IDE 2.0.0 (different auto formatting, no code changes) 2022-10-13 09:49:03 +02:00
sanni
21e7468dfd Fix flicker in Controller Test 2022-10-08 23:07:15 +02:00
sanni
1a8d127011 Increase romName array size from 17 to 22
Crashed with Lufia II(Estpolis II) before.
2022-10-06 10:20:02 +02:00
sanni
bef9d0f5f9 Don't log manual mapper selection to file for NES/GBA 2022-10-04 20:30:53 +02:00
Lesserkuma
6098700fdd Merge branch 'master' 2022-09-25 17:06:58 +02:00
Lesserkuma
140401161b UI improvements for GB, GBA, N64, SNES 2022-09-25 16:40:21 +02:00