aboutsummaryrefslogtreecommitdiffhomepage
path: root/Cart_Reader/N64.ino
AgeCommit message (Collapse)Author
2023-10-17N64: Add error message if eeprom does not return datasanni
Should prevent problem as described in discussion #857
2023-09-14N64.ino: Handle reused global from FLASH.inoAncyker
2023-09-13Remove unused variables in N64.inoAncyker
2023-09-12Update N64.inoRichard Weick
Update Xplorer64 functions in N64.ino to fix a potential issue for some hardware.
2023-09-10Update N64.inoRichard Weick
This adds full support for the Xplorer 64, including backup and writing of new firmware to the device. Firmware must be unscrambled (not dumped directly from the chips in a chip reader) in order to work with this program. Firmware dumped via the Sanni Cart Reader with this function work perfectly when written back.
2023-09-08Update N64.inoRichard Weick
This updates the N64 Gameshark function description, adds progress bars for the writing and verification functions, and updates the Chip ID function to report an unknown chip.
2023-09-07Update N64.inoRichard Weick
This completes the N64 Gameshark functions. It adds the command to enable CPLD address ranges of 0x1EEx_xxxx, 0x1EFx_xxxx, and 0x1ECx_xxxx which are necessary to program the SST 28LF040 eeprom. This also adds full support for the SST 28LF040 eeproms.
2023-08-18Fix Xplorer_N64 dumpPsyK0p4T
2023-08-18Add Xplorer 64 dump option to N64sanni
Thx to [RWeick](https://github.com/RWeick/FCD-0003.1S-Xplorer64) for finding the address the firmware is mapped to.
2023-06-26Cleanup voltage requestsAncyker
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-26Change default mode in N64 controller range testsanni
2023-06-26Move automatic voltage selection from menu to setup functionssanni
2023-05-10Update N64.inoPsyK0p4T
Allows to manually select a dump size up to 128 MB (used by some repros/aftermarket boards)
2023-03-29Firmware Updater support, 3.3V Fix, and moreAncyker
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-02-25typo fixnsx0r
2023-02-10Improve stability when dumping N64 with fastcrc optionsanni
2023-02-10Fix SRAM overflow in N64/MD, turn LED red if CRC not foundsanni
2022-11-12Add Voltage Selection ModuleRemy Starshade
2022-10-31Fix reading/writing 4MB HiROMsanni
HiROM starts at bank 192 and has 64 banks so byte variable currBank overflows.
2022-10-31All: Replace print_Error(*, boolean) calls with print_{,Fatal}Error(*)Vincent Pelletier
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-31N64.ino: Factorise JoyBus-related codeVincent Pelletier
IMPORTANT: with this change, the Adafruit clock generator becomes a hard requirement to read and write gamecart eeproms. This is a large patch, partly because JoyBus is used a lot: - controller - controller pak - gamecart eeprom and partly because of the further simplifications it allows. Also, implement low-level bit shift functions in assembly in order to get complete control of the timings: there can be just a few cycles of slack. Also, use the time waiting for the input line to go high to pack received bits into bytes on-the-fly, as there is now plenty of time. This saves about 2080 bytes of program space, and 369 bytes of global ram space.
2022-10-31N64.ino: Assorted low-hanging fruitsVincent Pelletier
More sizeof() use, avoiding high-level loops when a callee can do it without the call overhead on every iteration, a bit of source code factorisation, avoiding initializers for large variables.
2022-10-31N64.ino: Build eeprom path and file name with snprintf_PVincent Pelletier
So the format string is stored in flash rather than in ram. The gain from doing just one like this is not much, to be done in more places.
2022-10-31N64.ino: Optimise controller CRC functions for speedVincent Pelletier
Also, shave off 5 bytes from a local initializer. Saves 22 bytes of program space and of global ram space.
2022-10-28Auto formatsanni
2022-10-28All: Factorise title generation from cart.Vincent Pelletier
Fix out-of-bound access when first byte is not an ascii printable character. Reduces program space use by 480 bytes.
2022-10-28All: Factorise CRC functions.Vincent Pelletier
This saves 370 bytes of program space.
2022-10-28All: Use f.seekCur(x) instead of f.seekSet(f.curPosition() + x)Vincent Pelletier
Saves 450 bytes of program space.
2022-10-28All: Resolve all compiler and linker warningsVincent Pelletier
No functional change intended.
2022-10-28N64.ino: Remove unused functionVincent Pelletier
This does not save any space as the linker noticed it wasn't used. Also, point the (commented-out) only caller to the equivalent libc function.
2022-10-28All: Make flashid an integerVincent Pelletier
flashid (almost) always contains the hexadecimal representation of two bytes, which then means it gets compares with strcmp, which in turn need another string argument. Instead, make it an integer, removing the need to call strcmp. Add a separate string representation for printing purposes (maybe this can be avoided by having the print function format it when needed ?). The only apparent case where flashid is not an hexadecimal representation of a pair of bytes is when N64 clears it to "CONF". Set flashid to zero this case. This saves about 500 bytes of program space and 200 bytes of ram.
2022-10-28https://github.com/sanni/cartreader/issues/574#issuecomment-1286956251Vincent Pelletier
2022-10-13Move to Arduino IDE 2.0.0 (different auto formatting, no code changes)sanni
2022-10-08Fix flicker in Controller Testsanni
2022-10-08Remove crc file after successful Controller Pak readsanni
2022-10-08V10.1 Move HW1/2/3 to same display lib as HW4/5sanni
... bugs are to be expected :D
2022-09-28Fixed wordingLesserkuma
2022-09-28Find Game Serial for Game BoyLesserkuma
2022-09-25Merge branch 'master'Lesserkuma
2022-09-25UI improvements for GB, GBA, N64, SNESLesserkuma
2022-09-25Add support for Benesse Pocket Challenge W Module (thx to skaman)sanni
2022-09-24Update to displaying full ROM title on SNES, N64, GB, GBALesserkuma
2022-09-10Fix bug in N64 controller functionssanni
2022-09-10Update N64.inosanni
2022-09-10Verify MPK file after readingsanni
2022-09-09V9.7: Calculate block CRC during Controller Pak readsanni
2022-08-19Update N64.inosanni
2022-08-19Update N64.inosanni
2022-08-19Add header and ToC checksum calculation for N64 Controller Pak readsanni
2022-08-18Reset N64 Controller before accessing Controller Paksanni