Commit Graph

928 Commits

Author SHA1 Message Date
adelikat 047ed975d1 NES - implement mapper 234 2012-07-29 03:42:05 +00:00
brandman211 b1db1b7a69 -Reversed the double byte data bytes. It now works properly.
-Set the D flag to clear one instruction after it's set; SDBD is a prefix instruction.
2012-07-29 00:02:06 +00:00
adelikat c555e1df40 NES - mapper 52 complete 2012-07-28 18:53:26 +00:00
adelikat 9e96eb9ddc NES - start mapper 52 2012-07-28 18:14:04 +00:00
brandman211 53c0dd5ee0 -Enabled the ops that merely set / clear flags...there's no way I could have messed those up.
-Tested and implemented the MVO op.
-Implemented the other direct ops.

I think my double byte data handling isn't working. Will diagnose.
2012-07-28 17:50:32 +00:00
brandman211 748efbcd20 -Fixed the overflow calculation for ADDR, SUBR, and CMPR.
-Implemented the remaining XXX@ ops.
2012-07-28 17:20:16 +00:00
brandman211 188e5662ca It seems that indirect writes decrement the stack pointer BEFORE reading memory. 2012-07-28 17:06:06 +00:00
adelikat 1fb7d9a8a6 NES - Mapper 45 - oops, add lock_regs flag to savestates 2012-07-28 15:42:57 +00:00
adelikat 678e60815e NES - Mapper 50 - hook up IRQ logic? 2012-07-28 13:19:12 +00:00
adelikat 8d45516811 NES - mapper 50 - fix mirroring 2012-07-28 12:35:51 +00:00
brandman211 0d10eee747 -Implemented branching and tested BNEQ. BEXT not implemented.
-Made it so that the indirect ops other than MVO@ decrement R6 when it's the mem address. Indirect write means writing to a register apparently, so maybe the documentation don't contradict itself.
2012-07-28 04:18:13 +00:00
adelikat 5d521a5132 NES - mapper 50 - some fixes, almost complete 2012-07-28 03:37:06 +00:00
adelikat 7805c460d0 NES - start mapper 50, but it doesn't work 2012-07-28 03:11:39 +00:00
adelikat 10c71da526 NES - implement mapper 45 2012-07-28 01:29:06 +00:00
adelikat 524bc29b43 NES - remove some console logging spam on mapper 49 2012-07-28 01:02:16 +00:00
brandman211 4864aaa291 -Enabled and tested DECR.
-Fixed my disassembly of branch; I wasn't thinking in hexadecimal. >_<
-Subtracted 1 from the negated offset when branching in reverse. The next op is "BNEQ $FFFC".
2012-07-27 04:46:44 +00:00
brandman211 4d1f0114c4 R4-R7 now auto-increment for all of the indirect opcodes. My documentation is inconsistent on whether R6 increments or decrements on right, but in any case, my output now matches my source until the DECR, which hasn't been implemented yet. 2012-07-27 04:07:06 +00:00
brandman211 3a56f65c3f Implemented the XXXR opcodes. As of now, I have Jump, MVO@, MVI@, and XORR enabled and tested. There might be an off by one error with MVO@. 2012-07-27 03:33:24 +00:00
adelikat 9ee133866d NES - complete mapper 205, slight fix to mapper 91 (still not working) 2012-07-27 02:14:18 +00:00
andres.delikat f72905f602 NES - start mapper 96 (prg mapping working) 2012-07-24 14:32:09 +00:00
brandman211 b96e014327 -Reverted disassembly printout as it'll now match up with my comparison.
-Fixed the branching disassembly; the direction just negates the offset and the second parameter only belongs to BEXT. All of my sources contradict each other, but this seems sensible.
2012-07-24 05:29:24 +00:00
brandman211 d469a4e568 -Put the disassembly in parenthesis and put the opcode to the left of it in the logs. This is uglier, but it's initially easier for comparison this way.
-RegisterSP now increments in MVO@ instead of decrements. I'm not sure how this allows the stack to function properly, but it seems to work.
2012-07-24 03:05:57 +00:00
adelikat d774e49cd8 NES - Mapper 245 - do chr-ram logic. The 3 games I found correctly labeled as 245 (Yin He Shi Dai, DQ7, Hyrule Fantasy) all fail to run properly in this implementation, and FCEUX. 2012-07-24 00:12:40 +00:00
andres.delikat b08c2861a4 NES - start mapper 245 prg mapping working (possibly) 2012-07-23 22:15:22 +00:00
adelikat ed16f40529 oops, forgot to add Mapper205.cs 2012-07-22 20:11:55 +00:00
adelikat f45238132e NES - start mapper 205 2012-07-22 18:41:54 +00:00
brandman211 743480e26f -Logging now uses a static StreamWriter instead of building the string and writing on destruction.
-Applied to the old Gameboy core. Why not? It at least fixes that annoying bug from before if we ever care to use it again.
-Both logs are now written to different files.
2012-07-22 18:40:28 +00:00
brandman211 9f2bcf3318 -Fixed logging.
--It now just builds a strings and writes on finalization.
-Fixed up format strings.
-As RegisterPC already increments upon reading the third decle, I now just store PC as the return address for jumping instead of PC + 1.
2012-07-22 18:08:10 +00:00
brandman211 60c5a1ce58 Added logging for the CP1610. Not working for some reason. 2012-07-22 17:18:11 +00:00
adelikat b089f2996c NES - decently support mappers 74 and 192 (games play fine other than missing characters in text boxes)) 2012-07-22 16:57:44 +00:00
adelikat 91be138920 NES - fixes to mapper 91, still fails 2012-07-22 15:35:19 +00:00
adelikat f85b6a017b NES - checkin start of mapper 91 2012-07-22 01:02:18 +00:00
adelikat 225079a843 NES - implement board MLT-ACTION52 (Mapper 228) for both Action-52 and Cheetahmen II 2012-07-21 20:40:10 +00:00
zeromus e66e936567 nes-fix mapper 061 2012-07-21 19:45:16 +00:00
adelikat b8a16f93fa Implement mapper 243 2012-07-21 19:23:05 +00:00
adelikat f16a44d4e6 Start Mapper 243 2012-07-21 18:54:12 +00:00
adelikat 8aeb313381 Fixes to mapper 164, Final Fantasy V has a broken title screen but otherwise playable. Implemented based on Disch's original notes and so not quite complete. 2012-07-21 18:31:41 +00:00
adelikat 544410b4d8 Fix mapper 154 (Devil Man) 2012-07-21 17:51:52 +00:00
adelikat 86e14410b7 NES - mapper 225 finished 2012-07-21 17:19:59 +00:00
brandman211 0a0763966c -Refactored of the executor / disassembler / Intellicart to use more descriptive variable names and types to clear up a lot of confusion.
-Added implementation for NOP (6 cycles of nothing).
-Made SWAP actually store the result (Still disabled).
-Added breaks to the swap / shift / rotate cases (Yikes).

Instruction disassembly:

JSRD R5, $1026
MVI@ R7, R6
JSR R5, $1A83
MVO@ R5, R6
MVO@ R0, R6
MVO@ R1, R6
MVI@ R7, R4
MVI@ R7, R0
JSR R5, $1738
MVO@ R5, R6
XORR R5, R5 <- Needs implementation.
2012-07-21 05:25:52 +00:00
brandman211 259ec356bd -Updated the disassembly based on a more accurate resource.
-Retrieved the double bit from the swap / shift / rotate instructions in a more proper way.

TODO: Use more specific variables; most of them suck, and with these docs, I have better names for them.
2012-07-20 23:06:59 +00:00
andres.delikat 5f4ad218a2 NES - start mapper 225 2012-07-20 21:48:16 +00:00
brandman211 610acf6ad6 -Made MVI@ and ADD@ follow the stack and immediate mode rules for incrementing / decrementing the SP / PC.
-Disabled Intellicart hook for ReadMemory, which seemed to be interfering.
-Implemented MVO@.
-Several instructions are now executed in succession until it hits the unimplemented "XORR R5, R5".

I should probably refactor Disassemble and Execute to label registers as source / destination to avoid further confusion at some point. My disassembly might have the source / destination registers flipped as well.
2012-07-20 07:22:41 +00:00
brandman211 b2323458ba Implemented / tested MVI@ and AND@.
-They both seem to work, but the operands for AND@ are both 0, so this seems fishy.
-I don't know for sure if AND@ executes cycles in the same way that MVI@ as the documentation isn't clear on this, but I assumed it did.

According to my disassembler, the first 5 instructions run on the Executive ROM are:

JSRD R5, $1026
MVI@ R7, R6
ADD@ R6, R1
JSR R5, $1A83
HLT

Considering that I hit a HLT, I figure something is going terribly wrong. Perhaps it has to do with my lack of an interrupt system?
2012-07-20 05:02:26 +00:00
adelikat 96e7d85122 NES - add mapper 61, chr mapping is off somehow 2012-07-20 03:52:14 +00:00
brandman211 ab8e98c41a -Finished the disassembler with the branches.
-Added bytesToAdvance assignments to the relevant opcodes I added yesterday.

TODO: Implement more stuff in Execute and use the Executive ROM as a test case.
2012-07-20 03:30:03 +00:00
zeromus dd504a4960 nes-fix mapper057 2012-07-20 03:19:19 +00:00
adelikat afbde96fe5 NES - fix some chr mapping logic in Mapper 57 2012-07-20 02:57:46 +00:00
andres.delikat 2e71b04de4 Start mapper 57 2012-07-19 18:30:39 +00:00
zeromus 3321c3e2c4 nes-fix mapper226 2012-07-19 18:20:32 +00:00
andres.delikat 77f4eeeac1 NES - implement mapper 58 2012-07-19 16:01:40 +00:00
andres.delikat a9323e0386 NES - Implement mapper 62 2012-07-19 15:51:41 +00:00
andres.delikat 8f95b611a5 BizHawk - implement mapper 201 2012-07-19 15:01:32 +00:00
andres.delikat c256e90a9d NES - add mapper 203, doesn't play the 35-1 properly, but it doesn't run in fceux as well, documentation may be off, or the ROM i used is bad (not a lot of info on good dumps for these types!) 2012-07-19 14:13:45 +00:00
brandman211 10274734f9 -My jumping seems to work, so I enabled it in Execute.
-Finished the disassembler except for branching.
-Merged the XXXI instructions with XXX@ for R7 as the address register as they are redundant.
2012-07-19 06:58:14 +00:00
adelikat 876007c502 NES - fixes to mapper 226 2012-07-19 02:56:43 +00:00
brandman211 e73c48219a -Loaded EROM / GROM.
-Fixed disassembly for JMP:
--Now it uses the parameter pc, not RegisterPC.
--I was loading both the second and third value from the second's address.
--Casting the calculated addresses to bytes when addresses are 16-bit was a bad idea.
--Removed a closing parenthesis I accidentally stuck in the formatting.

It seems that I've gotten far enough to use the Executive ROM as a test case! Now to go instruction by instruction and see if they work as planned and hope this will all eventually make something.
2012-07-19 00:05:08 +00:00
brandman211 198c60af88 -Refactored ReadMemory so that both the core and cart addresses are read.
--Afterwards, the data is reconciled, right now by chucking out the core value if the cart responded.
-WriteMemory now writes to both the core and the cart unconditionally.
--Each case now breaks out of the switch statement in case we want to do more complex things at the end of the function later on.
-All default paths in both functions now throw an exception.
2012-07-18 06:19:03 +00:00
brandman211 1ee1d03aea -Parsed / implemented fine addresses for the Intellicart.
-Implemented the final CRC check.

I didn't get around to implementing bank-switched ranges, but I don't think it's worth worrying about that right now considering that the Intellicart is not marked as readable at the initial PC, so something is either wrong or I need to implement more things before this will work. I think I'll put Intellicarts on hold and try to get a .int / .bin to run in the meantime.
2012-07-18 05:35:10 +00:00
adelikat 188716ab7b Start mapper 226 2012-07-18 04:22:41 +00:00
adelikat ecd3a2dd84 NES - add mapper 233 2012-07-18 04:08:37 +00:00
adelikat 803833d04a Fix Mapper 230 2012-07-18 03:00:52 +00:00
adelikat ea60a2c9f8 Mapper 60 - a more respectable bit logic implementation in ReadPRG 2012-07-17 23:58:53 +00:00
adelikat 2174e9938f Implement mapper 60 2012-07-17 23:52:55 +00:00
andres.delikat 8aea375f9f Mapper 230 - fix mirroring and some prg mapping 2012-07-17 23:05:58 +00:00
andres.delikat d939e66867 NES - Implement a SoftReset function into the board base, Mapper 230 - implement mode switching via soft reset, implement prg mode 0, game select screen now playable, games are not 2012-07-17 15:24:36 +00:00
andres.delikat fa449a5116 NES - add mapper 230, contra mode is working, still todo: implement mode toggling on soft reset 2012-07-17 14:02:56 +00:00
zeromus 5eaf27e510 nes-fix mapper 231 2012-07-17 06:24:36 +00:00
zeromus 309d6b4e64 nes-fix mapper 200 2012-07-17 06:19:03 +00:00
brandman211 0a3a392285 -Attempted to parse out memory attributes.
--In my test case, only a few segments were set to readable and nothing else was set. 0x1000, which is where the PC is initialized to, certainly isn't in a writable page.
--Although I've read that these memory attributes affect the Intellivision and not the Intellicart, I'm pretty sure this has to be implemented in the Intellicart so that my Read/WriteCart functions can choose to respond / not respond depending on these attributes. I very well could be wrong.
-Hooked Read/WriteCart into Read/WriteMemory.
-Implemented memory attributes into Read/WriteCart.
--TODO: Bank-switching.

TODO: Fine address table and memory attribute / fine address checksums.
2012-07-17 05:32:00 +00:00
brandman211 cd5458a5e4 Fixed CRC. Passes! 2012-07-17 04:16:11 +00:00
adelikat bbf5be7d74 NES - add mappers 200 & 231, PRG mapping isn't quite right on either but some games work 2012-07-17 04:06:48 +00:00
adelikat ee5db4cc06 Mapper 112 - Finish implementation of CHR mapping, and misc small cleanups 2012-07-17 02:01:53 +00:00
adelikat 69712a203d Remove compatibility.txt and replace with a link to the wiki page 2012-07-17 01:46:55 +00:00
adelikat 5df5def02d remove NES test status doc that is outdated and obsolete to this page: http://tasvideos.org/EmulatorResources/NESAccuracyTests.html 2012-07-17 01:06:38 +00:00
zeromus ecd58fc96e nes-protect from syncstates which dont call base.SyncState 2012-07-16 22:06:55 +00:00
zeromus 9c2a521c19 nes-fix m112 and some other unnecessary things 2012-07-16 22:01:10 +00:00
andres.delikat ad2e9267e3 NES - Mapper 112 - fix prg bank selection, however, game still fails to run 2012-07-16 21:12:01 +00:00
brandman211 21558eaf11 -Made ReadMemory and WriteMemory for the Intellicart Read/WriteCart and made them return nullable values instead of passing an out value.
-Started parsing data segments.
--CRC check fails. :(
-Added .bin and .rom to the Intellivision associated file extensions in the load ROM dialog.
2012-07-16 05:52:01 +00:00
zeromus cf5c972990 nes-try fixing m207 2012-07-16 03:04:44 +00:00
zeromus 06c44cf040 nes-add NES-JLROM for mr gimmick! (e) - but it doesnt work cos its pal 2012-07-16 02:59:54 +00:00
adelikat 2d89f5485f Implement Mapper 207, Fudou Myouou Den now playable but graphical issues. 2012-07-16 01:51:16 +00:00
adelikat 1751e615d7 Oops, update csproj file with new mapper files, update mapper compat list 2012-07-15 23:58:00 +00:00
adelikat c9128cc78e Start Mappers 154, 112 2012-07-15 23:12:52 +00:00
zeromus 3ae3a52f7a nes-do mapper088 differently 2012-07-15 22:30:25 +00:00
zeromus a33859fc1e nes-fix mapper 088 2012-07-15 22:22:57 +00:00
adelikat f62607dea9 Start mapper 88 2012-07-15 21:45:28 +00:00
brandman211 e82bae007a -Mapped .ROM to Intellivision.
--If a future system uses this extension, the condition:

Rom[0] == 0xA8 && Rom[1] == (0xFF ^ Rom[2])

...can verify if the file is in fact an IntelliCart, though I doubt this is a permanent solution to the more underlying problem.
2012-07-15 09:13:54 +00:00
brandman211 4f9539b73c -Made Executive ROM and Graphics ROM read-only. I still haven't made the memory map accessibility limited by the VBlank Period, but I'm assuming that should come way later.
-Initialized the memory devices with a tentative size that ignores the unofficial ranges.
-Masked addresses to match those sizes (That's my understanding of what the memory map needs to do based on other examples).
-Added the ICart interface.
-Started the Intellicart parser; got far enough to know that the files I'm working with are not Intellicarts. ^_^
2012-07-15 08:38:50 +00:00
beirich d24d3ae932 fix a dumb PAL bug. possibly for the second time. 2012-07-15 07:15:31 +00:00
zeromus a47c70d0ef nes-fix #12 "Strange "White noise" sound during 1943 (USA) intro" as well as a boatload of aesthetic improvements to make the sound output not so embarassing. no speedups whatsoever though. 2012-07-15 00:09:34 +00:00
zeromus 1f588c451f nes-add broken bisq apu. it probably wont be fixed. but its a lot of work, so there it is. also remove spam in SXROM 2012-07-14 18:43:37 +00:00
andres.delikat 0834c63a43 NES - sound config dialog for toggling sound channels 2012-07-12 23:13:22 +00:00
goyuken fd7a0b2fe7 change CoreOutputComm to use exact integers to specify VsyncRate. Helps for AV dumping with formats that require exact integer rates (AVI), and for emulators that aren't exactly 50hz/60hz (none yet). 2012-07-11 21:37:35 +00:00
brandman211 32baa013af -Made the memory map use ushort arrays because the Intellivision is 16-bit.
-Fixed JMP disassembly; I need to return on an invalid opcode because I was breaking out of the inner switch statement, not both that and the outer one.
2012-07-09 23:19:57 +00:00
brandman211 f3ce111c48 Checked in memory map...I need to stop programming and start sleeping. 2012-07-09 19:41:49 +00:00
brandman211 104511c5b7 -Intellivision.cs' constructor initializes the PC to 0x1000.
-Set up the "official" memory map - see http://wiki.intellivision.us/index.php?title=Memory_Map
--Things I didn't do:
---Accessibility.
---Additional Occupied Memory Ranges.
---Addresses Available to Cartridges
---Initialize any of the byte arrays.
--Not sure which of these I need to do, but clearly the byte arrays have to be initialized somewhere to something and there's a lot of gaps in this memory map.
2012-07-09 05:29:45 +00:00
brandman211 9b8a9d93f1 Opcodes up to 0x07F. 2012-07-09 03:27:27 +00:00
brandman211 bb532aa2d9 Opcodes up to 0x5F. 2012-07-08 21:49:09 +00:00
brandman211 61cada6190 -Made HLT throw an exception.
-Made all instructions in the executor, even implemented ones, throw exceptions. I will get rid of the exceptions as I test the instructions.
-Added instructions up to and including 0x57 to disassembly and executor.
2012-07-08 19:52:12 +00:00
brandman211 a4912e66c0 -Wasn't supposed to actually increment the PC in the disassembler.
-Cleaned up the 0x004 (Jump) disassembler.
-Implemented 0x004 in the executor.
2012-07-08 08:42:32 +00:00
brandman211 778274a12d -Set up the disassembly decoder just like the executor.
-Disassembled opcodes up to and including 0x7.
2012-07-08 08:17:07 +00:00
beirich 36ba018ae0 basic wire-up of Intellivision core 2012-07-08 04:20:53 +00:00
brandman211 8d254113c2 Finished the opcode decoder. Over a thousand lines in one day...now just to make them do stuff! 2012-07-08 03:53:12 +00:00
brandman211 1c480c98b4 -Created functions for calculating the flags.
-Implemented ADCR.
-Decoded all opcodes up to 0x23F.

TODO: Try vecna's idea of testing the instructions by running a game and implementing instructions as I need them...but first I'll need to implement loading of an Intellivision game.
2012-07-08 01:58:06 +00:00
brandman211 2457c68ed7 Starting IntelliHawk with the CP1610, using the other processors in BizHawk, BlissJ, and this (http://wiki.intellivision.us/index.php?title=CP1610) page as references.
-Definitions.
--Registers, Flags, TotalExecutedCycles, PendingCycles, ReadMemory, and WriteMemory.
-Execute.
--Implemented opcodes 0x001-0x027 with the exception of 0x004 and 0x005.
2012-07-08 00:36:16 +00:00
adelikat 60640acece NES - Implement Mapper 246 2012-07-06 03:44:34 +00:00
zeromus 1eda5f6d63 nes-express m193 differently, maybe more clearly 2012-07-06 03:12:20 +00:00
zeromus 157c145a46 nes-fix m193 2012-07-06 02:29:42 +00:00
adelikat 7a9d037fed NES - Progress on Mapper 193 2012-07-06 01:36:19 +00:00
zeromus 1d254c3705 nes-fiddle around with board irq signal tracking system. break every NES savestate. fix a desync bug in a bunch of mappers 2012-06-25 06:32:54 +00:00
beirich b599c69c18 Add VirtualWidth to IVideoProvider and the (numerous) implementations. This is just phase 1, client needs to be updated to utilize this information, and some cores (especially PCE) should be updated in a more involved way to provide better TV emulation. 2012-06-25 02:50:34 +00:00
zeromus 7e8752a5b9 nes-sort out some bus conflict flags for CNROM games to fix colorful dragon (unl) (sachen) 2012-06-24 17:39:12 +00:00
zeromus 5b356c5157 nes-support mapper 178 and fix a regression from yesterday that made most roms not loadable 2012-06-23 18:30:27 +00:00
adelikat dcdd98fc03 Fix mapper 116 code so that project compiles 2012-06-23 15:45:58 +00:00
zeromus 50d4564e0e nes-support mapper 116 2012-06-23 08:52:12 +00:00
zeromus 8bf9b92949 nes-support mapper 241 2012-06-20 22:24:56 +00:00
zeromus 6156188676 nes-support m015 2012-06-19 21:23:24 +00:00
adelikat a2a9bfde3c NES - implement mapper 92 2012-06-16 23:34:42 +00:00
zeromus ace86fa321 nes-clarificatoin to mapper 19 and 210 (theyre actually identical) 2012-06-16 16:59:02 +00:00
zeromus 540be07cf2 nes-support mapper 076 2012-06-15 19:55:29 +00:00
zeromus e1152799b4 nes-last commit was broken, fix tlsrom compile issue 2012-06-15 19:28:40 +00:00
zeromus 916066c3f0 nes-mmc3/namcot108 differences have become more clear in the past few months. refactor those mappers (split them apart, theyre not as similar as once thought) to reflect new understandings. no functional improvement from this other than maybe some new bugs, but it will help on some other mappers later 2012-06-15 19:24:06 +00:00
zeromus 931c9c9b23 get rid of some warnings 2012-06-15 19:21:46 +00:00
zeromus b240c675ce nes-mapper 72 fixed and misc bookkeeping 2012-06-11 07:59:30 +00:00
zeromus 6462d84ac9 nes-add some docs and clarification and cleanups of the sunsoft mappers 2012-06-11 06:55:34 +00:00
zeromus 3a336b9ef4 nes-mapper 67 2012-06-11 06:32:44 +00:00
zeromus cff7ba6d24 nes-fix lagrange point, including sound 2012-06-07 20:52:49 +00:00
beirich fe369e0455 pce: alter handling of reading $1FF402 irq status port, fixes Aldynes intro freeze 2012-06-03 20:09:09 +00:00
beirich 2dd91c4079 pce-cd: fix CD Set Audio End Position command Mode 2 bug - not ending audio playback! 2012-06-03 02:03:31 +00:00
brandman211 c3a4b12ca9 -Copied over the functions I need to implement for GB, leaving FrameAdvance and GetVideoBuffer unimplemented until I fully understand them. 2012-05-28 08:37:52 +00:00
zeromus 65060e47a7 nes-note that in compat list 2012-05-27 20:21:10 +00:00
zeromus 45cfc7b036 nes-add mapper 176 and fix savestate of mapper 164 2012-05-27 20:20:27 +00:00
zeromus 82e57988c6 nes-remove newly redundant wram masking from derived board classes (mmc3 and mmc1 affected); separate checkin done for this in case i goofed up 2012-05-27 07:44:29 +00:00
zeromus c5a2d0f8f0 nes-fix bug in base board class wram functionality (forgot to add masking to wram size configured in the Cart struct by the derived board Configure method) 2012-05-27 07:42:13 +00:00
brandman211 2553ac50bb -As I'm not going to know what I'm doing if I keep hacking away at zeromus' old core blindly, I'm writing a new one.
--It's going to be based heavily based on Imran Nazar's "GameBoy Emulation in Javascript" series. I figure it's better that I learn by emulation (Har har) instead of spending more time reading references than programming.
--Finished the memory management (Part 2).
--adelikat:
---Do I implement the required functions for IEmulator and IVideoProvider now, do it later, or is this something you or zeromus would do (Like for the API)?
---At what point should we have the emulator actually use this core instead of zeromus'? As terrible as he says his is, this one doesn't do anything yet. Still, I need some mechanism of testing it.
2012-05-27 04:06:48 +00:00
beirich df59686cbb Fix crash in PCE Coryoon when attempting to access disabled TurboCD ports 2012-05-26 20:21:00 +00:00
brandman211 aad9f05310 -Made it so that the log file only opens when you're actually logging. As a result, now can now at least switch games when you're not logging without getting errors. 2012-05-24 17:27:45 +00:00
brandman211 b29c9835ff -Separated the logging from the save state function.
-Made it so that the log only opens when logging is true and that the file closes upon destruction.
--Still, BizHawk says that it can't open the file again when I load a game again. This is because the emulator class gets recreated without deleting the original one every time you load a game.
---adelikat convinced me not to care about this.
-Fixed the initial state of the GB CPU:
--It was setting AF to 0x01, not A. This is effectively setting F to 0x01, which gets overwritten later anyway.
--Two BIOS flags were used in different places; merging them gets the PC to start in the right place.
-By fixing the initial state, most of the log now matches up.
--The only differences are the VBA has some repeated records (Where all of the registers, including PC, are the same as the previous record) whereas BizHawk doesn't.
--This very well might be an issue with how I'm logging it
--Alternatively, it could be some kind of lagging mechanism.
--I'm not sure which version is even correct...VBA is far from accruate.
--All in all, considering that the vast majority of the diff comes out as the same, I think I fixed the biggest CPU related bug. Will investigate more later.
2012-05-24 17:19:33 +00:00
beirich db1bfcfdfc very preliminary genesis savestate support 2012-05-22 02:25:41 +00:00
beirich 2aef2b8606 68000: savestate support (text) 2012-05-21 04:44:36 +00:00
zeromus 97933f2560 nes-support TENGEN-80004 (just bookkeeping; uses already existing mapper 068) 2012-05-20 21:10:22 +00:00
zeromus 638a99a1f7 nes-fix a potentially desyncable bug in mmc3 savestate 2012-05-20 21:04:06 +00:00
brandman211 9623f073eb Added a logging flag for GB using the SaveStateText function. 2012-05-20 06:43:41 +00:00
adelikat 147caec758 GameboyHawk - Skip BIOS menu option 2012-05-19 15:17:32 +00:00
adelikat abba87738f Fix input config for Gameboy, some small random work on ColecoHawk 2012-05-18 22:57:05 +00:00
brandman211 5f534518aa Colors were still wrong. I just used a switch statement to fix them. Not elegant, but I can't see a simple pattern. 2012-05-18 19:47:43 +00:00
brandman211 9f8144ec58 -Set the number of cycles per frame to 70224.
-Inverted the colors; according to http://imrannazar.com/GameBoy-Emulation-in-JavaScript:-Graphics, 0 is white, 1 is light gray, 2 is dark gray, and 3 is black, which is the opposite of the norm.
2012-05-18 19:11:14 +00:00
zeromus 42715fdca7 rehabilitate the GB core: fix videoprovider and input system 2012-05-18 18:28:12 +00:00
goyuken a313d3910d Add sound output to sound card while dumping is occurring. Uses a proxy ISoundProvider (DualSound.cs) to guarantee emulation sound core and dumping routine are unaffected, while sending "best effort" sound to system output. Doesn't sound great, but simple and functional. 2012-05-09 20:21:23 +00:00
adelikat 02bad39a88 Some Coleco docs 2012-05-06 23:16:50 +00:00
brandman211 cd0016343f Done trying to optimize the PPU's FrameAdvance. We may have saved some processing time, but it's not very consistent. 2012-05-06 06:04:00 +00:00
brandman211 05157997f1 -Added a very basic fix to the graphics scaling issue per adelikat's advice.
--Gets worse as the scale increases.
--For x3, the box doesn't increase size, but the box still changes position. I think there might be a difference between the TargetZoomFactor and the actual screen size, so perhaps we should tie this to something else.
-Working on very small optimizations to the NES PPU with CorruptedSyntax...this is more fun, so we'll do this first.
--Eliminated an entire loop.
--Branched to two loops instead of branching for every iteration in one loop.
--Got rid of some redundant instructions using temporary variables.
--This may be completely premature, but I seem to have gained a few FPS from doing this. For me, I get 38-39 FPS where I'd previously get 33-34.
2012-05-06 04:09:28 +00:00
adelikat 5fa0a681e1 Colecohawk - start VDP (ripped from the SMS core) 2012-05-06 02:48:39 +00:00
adelikat 3b7c23817a Coleco - some hacks and fixes to make a coleco rom open without crashing (draw a black screen instead) 2012-05-06 01:15:02 +00:00
adelikat 059aebec8e ColecoHawk - set up ROM loading (bind .col to Coleco), set up preliminary controller garbage in 85 places for coleco 2012-05-06 00:54:13 +00:00
adelikat 592b73ea5a Atari - implement mapper EF 2012-04-29 21:12:58 +00:00
adelikat e0a6ae5264 Atari - put descriptions at the top of each mapper file 2012-04-29 21:01:06 +00:00
beirich 700ac116dd ym2612: more ports processed, DAC now plays in stereo 2012-04-29 18:33:21 +00:00
beirich 239cb213f0 ym2612: some progress on operators 2012-04-29 17:41:39 +00:00
adelikat 02767a9fbb Genesis - hook up lag counter 2012-04-29 12:55:20 +00:00
beirich 59eb4b4abe ym2612: support TimerA and TimerB 2012-04-29 06:05:15 +00:00
adelikat 3d10431a2b Atari - implement console switches (as menu items) 2012-04-29 02:48:33 +00:00
beirich d322c3c00f Fix some bugs responsible for out-of-bounds array access crash on ym2612 2012-04-29 01:40:38 +00:00
beirich 7f1292d4f9 start on YM2612. DAC works. process port writes for FM channels. No FM channels output audio yet. 2012-04-29 01:09:06 +00:00
adelikat 4e04facdd9 Atari - make games marked F6SC load 2012-04-28 23:21:12 +00:00
adelikat 1adec35f93 Atari - implement player 2 button 2012-04-22 00:02:24 +00:00
beirich fad95b6bab Add 3-band equalizer. Not hooked up to client for time being though. Maybe later I'll expand it to more bands and create presets. Just wanted to check it in for now. 2012-04-21 20:22:13 +00:00
zeromus f2d1f1ff2f discohawk-fix bug that made some cue source files whose ffmpeg decode output is very verbose trigger a deadlock through stdout buffer filling up 2012-04-19 20:04:52 +00:00
zeromus b1d62ed574 6502-add some opcodes not handled by the instruction tests, but which are cursorily covered by the instr_timing test, which now passes 2012-04-18 08:04:06 +00:00
zeromus 97b66a907f 6502-implement undocumented opcodes. pass all instruction tests 2012-04-18 05:22:58 +00:00
zeromus 06239e1aa3 nes-fix mapper 64 and some minor details of ppu data bus management; fixes klax and chu chu rocket 2012-04-17 06:50:23 +00:00
zeromus e41eabcfc3 fix atarihawk video 2012-04-16 22:56:30 +00:00
zeromus 35fbe354c1 add threaded display manager to allow heavy OSD/compositing/filtering to happen on another thread. add a lua layer accessible via GDI+ which can be automatically composited and the simplest possible demo of it. add some filtering infrastructure and a hq2x filter set ported to c# but need to work on a minimal selector gui before its usable. separate OSD from RenderPanel so that gdi+ presentation mode now gets full OSD support. the OSD is now a little uglier because its drawn entirely differently and could use some finetuning 2012-04-16 08:18:41 +00:00
adelikat 836415455a NES - start an APU softreset function, and clear sequencer_irq, and 0x4015. Still a lot of work to be done for this, but passes nes apu reset tests: 4015_cleared, irq_flag_cleared 2012-04-14 13:51:26 +00:00
zeromus 7b86f66353 nes-oops. now, actually pass all mmc3 tests 2012-04-14 09:40:41 +00:00
zeromus 73fba31c34 nes-add mapper012 (mmc3 variant, for dragon ball z 5). add concept of mmc3 chip revision variants to mmc3 code and game database, and add proper emulation thereof. pass a bunch of mmc3 tests. simplify (to almost nothing) iNES board detection to correspond to new paradigms of virtual board types. your savestates for mmc3 games are invalidated. 2012-04-14 08:28:42 +00:00
zeromus eb1a6eb387 nes-clarify relationship between mapper 115 and mapper 248 (and support 248) 2012-04-09 20:09:58 +00:00
zeromus a561f8b7e7 nes-add mapper 227 2012-04-09 18:13:58 +00:00
zeromus a78a0fc5db nes-meant to check this in with last gamedb updates 2012-04-09 06:38:28 +00:00
adelikat eeec746010 NES Hawk - remove list of broken games from NES.cs and placed it on http://tasvideos.org/BizHawk/TODO.html instead 2012-04-08 18:07:46 +00:00
adelikat f495e7e068 Atari - slight fix to support the F4 mapper 2012-04-05 23:46:01 +00:00
zeromus a1cdd5dbfd nes-fix mapper 242 2012-04-05 18:55:34 +00:00
adelikat ea2bdac456 Fix an exception from commit 2161 (Prevent lua script restart when resetting a game). Fixed by making RecentFiles.GetRecentFileByPosition() more robust by not crashing when there is no recent file (returns "") instead 2012-04-04 02:23:47 +00:00
pjgat09 b5927b1212 Atari M6532: Turned the timer into an object, and now uses a prescaler, replacing the previous 32 bit int implementation.
Fixed a typo with the interrupt flag. 
These changes fix freezes with "Berzerk (1982) (Atari)" and "Omega Race (1983) (CBS Electronics)"
2012-04-04 01:18:41 +00:00
pjgat09 3591f7ca47 Atari: Changed the core to make the TIA the video and sound provider. 2012-04-02 20:55:29 +00:00
andres.delikat 31d65725bd Atari - start game compatibility spreadsheet 2012-04-02 19:13:24 +00:00
andres.delikat f0e4db8023 Atari - implement mapper CV (untested) 2012-04-02 17:13:38 +00:00
andres.delikat 5d28f8727a Atari - implement UA mapper (untested) 2012-04-02 16:58:04 +00:00
andres.delikat aed58c67e4 oops 2012-04-02 16:52:53 +00:00
andres.delikat 8ed2b8acbc Atari - F0 Mapper implemented (probably, needs testing) 2012-04-02 16:51:41 +00:00
andres.delikat c22c6ec4ce Atari - implmeent mapper E7, probably, hasn't been tested 2012-04-02 16:30:55 +00:00
zeromus 0e8b3605fa 2600-fix mapper FA? 2012-04-02 03:02:49 +00:00
adelikat 73b55dbf2e Atari mappers - Fix E0, add aux ram to FA but incorrectly most likely 2012-04-02 02:53:43 +00:00
adelikat a8de23fb79 Atari - mappers FA and E0 started 2012-04-02 01:54:51 +00:00
adelikat a22a2fa3dc Atari - implement mapper F4 2012-04-01 21:00:32 +00:00
zeromus eb13c505d6 nes-fix mapper 2 which broke a few revisions ago 2012-04-01 15:41:51 +00:00
adelikat 28effcba8c Atari - go ahead and hook up empty mappers for all 20 mappers 2012-03-31 20:53:14 +00:00
adelikat 7e30f2844f Atri - implement mapper F6 2012-03-31 20:32:40 +00:00
zeromus 79782defbe nes-dont crash when vrc mapper asks for unusual irq mode 2012-03-31 15:37:53 +00:00