Commit graph

80 commits

Author SHA1 Message Date
Giovanni Bajo
f70312008a Help users discover -is-viewer
IS Viewer emulation is currently gated by a command-line flag. All
other major emulators supporting ISViewer (Ares, dillonb, m64p) enable
it by default, and it does not seem to create any problem.

To help homebrew developers discover the feature without showing logs
by default, change the code to always emulate the ISViewer hardware
and add a warning if the ROM uses it but the command line flag was
not specified. This should point users towards correct usage, and
prevents possibly-verbose logs to be shown by default.
2022-03-26 00:12:14 +01:00
Giovanni Bajo
71903c63fa Add support for homebrew-specific special header flag
Nintendo 64 homebrew community is standardizing on a convention to
declare the save memory type as a header flag. This convention has been
first introduced by EverDrive 64 as a way to handle games not present
in their DB, but it's been since adopted by libdragon as well.

With this commit, cen64 will automatically configure the correct savetype
for homebrew ROMs using the special header flag.

I've also added support for a 1Mbit SRAM savetype. This was never used
in commercial games but it is available with EverDrive64 and is one of
the possible configuration options. It costs nothing to support it and
may help development of homebrew games that decide to use that savetype.
2022-03-25 23:30:54 +01:00
Giovanni Bajo
5431cd25b3 cen64: cleanup console/windowed support
Currently, the experience of cen64 binaries of Windows is not the
greatest, to be kind. If you get the binary and double-click on it,
you get nothing (no feedback whatsoever). If you run it from the
console, you get nothing (no command line help is shown). I am not sure
how Windows users ever manage to use it.

This happens because the binary is linked as a windowed application,
but when run with no command line applications, it exits after printing
the help with printf, which does nothing since no console is
attached to the windowed application.

This PR improves the usability on Windows. It compiles cen64 has a
console application (as was meant to be used), so that the help text
or any other stdout/stderr output is now visible on console. Moreover,
to provide a decent experience to users double-clicking on the
binary, it displays an error message explaining that it should be run
from the command line instead.
2022-03-19 22:59:20 +01:00
Christopher Bonhage
6b7c2af8d4 Add support for 768Kbit SRAM save type
Fixes a Segfault when loading Dezaemon 3D.

  * Unfortunately, Dezaemon 3D does not actually work yet. It appears to
    fail the SRAM test, which still needs further investigation.

Adds an option alias for sram256k to disambiguate with new sram768k option.
2021-12-17 21:18:48 +01:00
Simon Eriksson
89e47d2968 Add Dinosaur Planet to cart DB 2021-02-20 18:39:05 +01:00
James Lambert
2865d107e4 Implement debugging hooks into vr4300 2021-01-10 17:07:21 -07:00
Lauri Kasanen
81bf10960f Teach the profiler about L1D misses 2020-12-21 19:05:07 +02:00
Simon Eriksson
a109ac02de Cart DB updates 2020-05-31 20:55:02 +02:00
Larkin Nickle
909db0eaf2 device/sha1.c: Remove sys/cdefs.h include 2019-07-27 01:52:11 -04:00
Pavel I. Kryukov
9ddfa25c77 Extract all VR4300 interfaces to interface.h 2019-05-27 22:31:19 +03:00
Lauri Kasanen
9812f78917 Add profiling support 2018-12-16 20:04:09 +02:00
tgsm
c3387fca49 cart_db: fix Ocarina of Time's (NTSC) save type
Ocarina of Time NTSC uses SRAM, not 4k EEPROM.
2018-11-30 06:25:06 -05:00
peterlemon
5ce3772646 fix master 2018-09-10 23:15:30 +01:00
PeterLemon
f08ffadc04
Revert "Remove wrong 'const' qualifier for is_viewer pointer" 2018-09-10 20:58:18 +01:00
Pavel I. Kryukov
8b2f77ed6c Remove wrong 'const' qualifier for is_viewer pointer 2018-09-10 11:36:21 +03:00
Thomas Lercher
8dfae37edb Fix thread_setname handling for macOS and older Windows APIs 2018-05-05 23:01:35 +02:00
Thomas Lercher
c16a317b3d Add thread names 2018-05-05 17:43:36 +02:00
Mike Ryan
8d0e7bb627 pi: add support for IS Viewer 64
When -is-viewer is passed on the command line, create an IS Viewer
object that intercepts writes at 0x13FF0000. This is used by Ocarina of
Time Master Quest Debug to log debug messages.

The messages are encoded in EUC-JP, so we bring in iconv to convert that
to UTF-8 so the messages can be printed to modern consoles.

Props to jrra (@jkbenaim) and spinout for reverse engineering the
interface and documenting it: http://wiki.spinout182.com/w/IS64
2017-02-28 19:55:55 -08:00
Jason
1c518539c2 Add note about debugger not existing 2016-08-31 21:45:04 -04:00
Jason
6cd0777286 Fix -debug argument parsing 2016-08-31 21:44:58 -04:00
Mike Ryan
36a4a6fdfa dd: identify IPL and add support for all known dumped IPLs
This also fixes a regression introduced in 3900be4 that prevented the DD
IPL from booting.
2016-08-31 18:33:15 -07:00
Tyler J. Stachecki
ed08c028e5 sha1: MSVC is braindead, so help it out a little. 2016-06-26 17:20:25 -04:00
Tyler J. Stachecki
3288229a50 Start fixing MSVC builds.
Conflicts:
	rdp/n64video.c
2016-06-26 17:19:17 -04:00
Mike Ryan
406b080fd1 multithread: stop all threads from running when window is closed
Add a "running" boolean to the master device struct, and set it to false
when the main window is closed. All the tight inner while (1) loops now
become while (running).

Closes #24
2016-06-19 09:56:24 -07:00
Tyler Stachecki
154343bdea Commit latest fork of angrylion/MAME RDP.
Conflicts:
	device/device.c
2016-06-17 05:06:34 -04:00
Mike Ryan
73f4420a4c fix all build warnings, does not affect functionality 2016-06-16 20:40:51 -07:00
Simon Eriksson
802556002e Added region field in cart DB.
This field is required in order to distinguish between regional
versions where the game ID is the same but the save type differ,
such as the Castlevania games.

Also added more Japanese-specific game IDs and edited some descriptions.
2016-04-03 11:12:31 -04:00
exhalatio
852f6cea24 Add Save list entry in the cart DB. 2016-03-16 12:04:32 +09:00
Simon Eriksson
8d17792969 Minor fix to description in cart DB.
Majora's Mask has the same ID in all regions.
2016-03-12 16:20:56 -05:00
Simon Eriksson
1b33cffa9c Add description field in the cart DB.
This description is printed along with the ID when a cart is detected.
Also includes a fix to a bug in the cart DB verification function.
2016-03-06 13:56:19 -05:00
Tyler J. Stachecki
d2d9dd6371 simer's cart db patch.
simer suggested (and implemented) the use of ROM IDs instead
of titles: "I've also found that the header name in some cases
are too inprecise, for example "TOP GEAR RALLY" has EEPROM 4K
for the Japanese and European versions, but not for the American.
2016-02-27 15:39:26 -05:00
Tyler J. Stachecki
08f1667432 Expand the cart list.
Thanks: Snowstorm64 and krom.
2016-02-21 21:02:36 -05:00
Mike Ryan
3235ee74eb options: document controller and save options 2016-02-05 21:44:53 -05:00
Tyler J. Stachecki
3c7765b136 (More) fixes for SHA1 compilation errors on Windows. 2016-01-30 15:42:42 -05:00
Tyler J. Stachecki
36b2aabc2b Fixes for SHA1 compilation errors on Windows. 2016-01-30 15:42:35 -05:00
Tyler J. Stachecki
9e33765f2e Standardized type names! Who would use such things?! 2016-01-30 15:04:14 -05:00
Tyler J. Stachecki
63b2709dc0 Bad implementation of PI delay. 2016-01-30 14:58:31 -05:00
Tyler Stachecki
80cd82e571 Merge pull request #29 from mikeryan/sha1-validate
validate SHA1 of important files
2016-01-28 00:36:30 -05:00
Mike Ryan
1146c33755 sha1: validate NTSC-J pifrom
Thanks @vgturtle127 !
2016-01-27 19:40:43 -08:00
Mike Ryan
eaf3cee002 sha1: validate DD IPL 2016-01-27 13:28:32 -08:00
Mike Ryan
bc9f14c7f9 sha1: detect and validate PAL PIFROM 2016-01-27 09:38:42 -08:00
Tyler J. Stachecki
24350e2440 device: Tighter sync on AI/VR4300 with -multithread. 2016-01-27 03:14:05 -05:00
Mike Ryan
2803a304bc validate SHA1 of important files
Currently only validating pifdata.bin. Probably also worth validating DD
IPL and other known binaries.
2016-01-26 22:15:38 -08:00
Tyler J. Stachecki
0a06f8850f Restore audio in Windows builds with -multithread.
Fixed the bug that was causing this a little bit ago.
2016-01-27 00:44:38 -05:00
Mike Ryan
782b8cb826 flashram: take command line option and pass into PI 2016-01-25 20:09:46 -08:00
Tyler J. Stachecki
c548e9b7e2 Prevent audio problems with -multithread. 2016-01-25 03:55:16 -05:00
Tyler J. Stachecki
b0082df3ca Add experimental multithreading support. 2016-01-25 01:10:10 -05:00
Tyler J. Stachecki
376dcc2f86 Add more options for running without audio/video.
This commit does the following:
  * Renames the -nointerface argument to -headless
  * Adds -noaudio and -novideo arguments
2016-01-24 23:29:46 -05:00
Mike Ryan
799b2af628 transfer pak: parse command line and load tpak ROM/saves 2016-01-24 17:46:44 -08:00
Tyler J. Stachecki
cdd3c44aea Add a subsystem for detecting carts. 2016-01-24 19:01:51 -05:00