Search found 45 matches

by LightStruk
Wed Oct 24, 2018 7:20 am
Forum: NES Hardware and Flash Equipment
Topic: MMC5 Hacking Adventures
Replies: 339
Views: 178062

Re: MMC5 Hacking Adventures

I don't need to stay with my current design -- I am open to ideas. I wish I had a 100 pin, 5 Volt microcontroller and skip these stupid IO expanders, they are so slow. It's not 100 pins, but the Arduino Mega 2560 rev 3 has 54 I/Os at 5V. (The ATmega2560 chip it uses has 86 I/Os, but the Arduino is ...
by LightStruk
Sun Sep 09, 2018 1:28 pm
Forum: General Stuff
Topic: C(++) and binary data annoyance
Replies: 15
Views: 7956

Re: C(++) and binary data annoyance

Why do you have to swap the bits with different endians? Shouldn't you only be swapping the bytes? I think the compiler developers could have decided to keep bit-order within bytes the same between little and big endian code, but they decided instead to make the bit-order behave like the byte-order...
by LightStruk
Sat Sep 08, 2018 6:57 pm
Forum: General Stuff
Topic: C(++) and binary data annoyance
Replies: 15
Views: 7956

Re: C(++) and binary data annoyance

I use bitfields all over the place in my emulator, in a way very similar to yours. I use them in the core CPU and PPU emulation, I use them in mapper registers, I use them in iNES and FDS header parsers. That advice about non-portable or compiler-specific behavior? Yeah, the standard might say that,...
by LightStruk
Fri Aug 17, 2018 1:29 pm
Forum: NESdev
Topic: Finding JSRs in PRG ROMs
Replies: 8
Views: 3761

Re: Finding JSRs in PRG ROMs

Thanks everyone for replying so quickly! If you find errors in the wiki please point them out and we'll fix them. Of course. I plan to submit fixes once I have completed my investigation. Perhaps my old FDS-Explorer might come in handy? Thank you for calling it to my attention. I will definitely che...
by LightStruk
Fri Aug 17, 2018 12:34 pm
Forum: NESdev
Topic: Finding JSRs in PRG ROMs
Replies: 8
Views: 3761

Finding JSRs in PRG ROMs

I'm trying to do some static analysis of FDS titles, identifying and counting which FDS BIOS APIs they call. Following the classic strategy of "do the simplest thing that could possibly work," my first attempt just scanned the ROM for byte sequences of $20 $xx [$Ex|$Fx], in other words, "JSR $Exxx" ...
by LightStruk
Thu Jul 26, 2018 9:21 am
Forum: NESemdev
Topic: Latest version of Nes_Snd_Emu code?
Replies: 0
Views: 9583

Latest version of Nes_Snd_Emu code?

The latest version of Nes_Snd_Emu available from blargg's website is 0.1.7, while his Game_Music_Emu library has Nes_Snd_Emu version 0.1.8 files in it. Are these the latest? Has blargg or another emulator author made any significant enhancements or fixes to Nes_Snd_Emu that are located somewhere els...
by LightStruk
Fri Feb 02, 2018 7:43 am
Forum: NESemdev
Topic: Question about nestopia MMC5 emulation
Replies: 17
Views: 11358

Re: Question about nestopia MMC5 emulation

MMC5 has mapper-controllable mirroring. Altering the mirroring bits in the iNES header won't affect emulation.
by LightStruk
Fri Dec 29, 2017 7:14 am
Forum: NESdev
Topic: Strategies for dealing with the four sprite palette limit?
Replies: 37
Views: 13547

Re: Strategies for dealing with the four sprite palette limi

So, I'm finding myself shocked and bamboozled by how darn few sprite palettes you can have at once. It's just four! It's not like I didn't know that beforehand, but now that I'm actually coding up my project I'm struck by how little four actually turns out to be. I'm making a co-op kinda thing, so ...
by LightStruk
Mon Aug 21, 2017 7:03 am
Forum: NESemdev
Topic: iNES header: size 255 == 256?
Replies: 14
Views: 7593

Re: iNES header: size 255 == 256?

Instead of re-interpreting bits that have already been defined, it would be easier to simply take advantage of the still-reserved bytes in the header. Bytes 14 and 15 are still undefined. If Byte 14's 8 bits were defined to be bits 13-20 of the PRG size field, then NES 2.0 would be able to specify 1...
by LightStruk
Tue May 02, 2017 7:38 pm
Forum: NESemdev
Topic: Sprite 0 hit, scroll splits, and fineX
Replies: 5
Views: 3576

Re: Sprite 0 hit, scroll splits, and fineX

Thanks for the help, everyone. It turns out that while I was testing the correct pixels, including the 1 line delay for the sprite position, I forgot to include that 1 line delay when I returned the hit location. Oops.

One more bug squished, countless more to go...
by LightStruk
Tue May 02, 2017 11:36 am
Forum: NESemdev
Topic: Sprite 0 hit, scroll splits, and fineX
Replies: 5
Views: 3576

Re: Sprite 0 hit, scroll splits, and fineX

Thank you for helping me work this out! If fine X is 7, and $2005 first write is written again with the same coarse X and fine X of 0, then the 7 most recently rendered background pixels will be rendered again. The scenario in SMB1 is the reverse - the fineX is 0 for the status bar, and then after t...
by LightStruk
Mon May 01, 2017 8:32 pm
Forum: NESemdev
Topic: Sprite 0 hit, scroll splits, and fineX
Replies: 5
Views: 3576

Sprite 0 hit, scroll splits, and fineX

Games like Super Mario Bros. and Zelda 2 put sprite 0 at the bottom-center of their status bars and then test for sprite 0 hit to know when to set a non-zero xScroll in $2005, right? In my emulator, the right half of that scanline is glitched, messing with the bottom pixels of the count counters and...
by LightStruk
Tue Aug 02, 2016 6:53 am
Forum: SNESdev
Topic: 65816 really 16 bit or just a 6502 with 16 bit registers
Replies: 126
Views: 37156

Re: 65816 really 16 bit or just a 6502 with 16 bit registers

The SNES, on the other hand, has only one true weakness - the inexcusably slow CPU. Once again, this statement complete and utter bullshit. Since this thread seems to be inspiring fanboi rage, let me start by saying that the SNES is my favorite console of the 16-bit generation, by a very long shot....
by LightStruk
Mon Aug 01, 2016 2:54 pm
Forum: SNESdev
Topic: 65816 really 16 bit or just a 6502 with 16 bit registers
Replies: 126
Views: 37156

Re: 65816 really 16 bit or just a 6502 with 16 bit registers

The Saturn is very complex, convoluted but at least it doesn't have real weakness as the SNES can have. This is from an old part of the conversation, but I really can't let it slide. The Saturn has multiple weaknesses that stem from atrocious design decisions. The SNES, on the other hand, has only ...
by LightStruk
Tue Mar 29, 2016 2:52 pm
Forum: NESdev
Topic: Reasonable implementation of PCM
Replies: 20
Views: 7070

Re: Reasonable implementation of PCM

Disadvantages: MMC5 is not cloned in a CPLD yet And the FME-7 is cloned? That's the mapper za909 is talking about using. Disadvantages: Mapper audio does not play back on unmodified 72-pin consoles On this forum, given how many folks are PowerPak users and FDS aficionados, I figured most everybody ...