Very Simple SuperFX chip demo

Discussion of hardware and software development for Super NES and Super Famicom.

Moderator: Moderators

Forum rules
  • For making cartridges of your Super NES games, see Reproduction.
Post Reply
secondsun
Posts: 33
Joined: Tue Jul 31, 2018 9:37 am

Very Simple SuperFX chip demo

Post by secondsun » Sat Mar 13, 2021 5:24 pm

I've noticed that the SuperFX chip demo in the libSFX examples was great for booting the chip, but it does not include examples of drawing with the SFX chip or copying data from the chip to VRAM. I've created, I hope, an example of using the SuperFX in 4bpp 160 line mode that people can build from.

First, here's the source : https://github.com/secondsun/snes-sfx-demo

The source has a link to a youtube video. Be warned, I strobe colors and some people may find that unpleasant.

The demo does a few things that a SFX chip developer may be interested in. It demonstrates how to use the line interrupt to change your vblank interval, it stops and resumes the sfx chip mid frame, and it runs at 30 fps (more or less). I've only tested this on bsnes and Mesen-s but not on real hardware; if you try it on a flash cart let me know how it goes.

There are some improvements to be made. I would like to better align the letter box, and my interrupt is not right as it fires halfway across the screen.

User avatar
Nikku4211
Posts: 403
Joined: Sun Dec 15, 2019 1:28 pm
Location: Bronx, New York
Contact:

Re: Very Simple SuperFX chip demo

Post by Nikku4211 » Sun Mar 14, 2021 5:18 am

secondsun wrote:
Sat Mar 13, 2021 5:24 pm
The demo does a few things that a SFX chip developer may be interested in. It demonstrates how to use the line interrupt to change your vblank interval, it stops and resumes the sfx chip mid frame, and it runs at 30 fps (more or less). I've only tested this on bsnes and Mesen-s but not on real hardware; if you try it on a flash cart let me know how it goes.

There are some improvements to be made. I would like to better align the letter box, and my interrupt is not right as it fires halfway across the screen.
I can't wait to see you eventually do more with this in the future, and see what doors this code can open.

I'll get back to you when I test the demo on a real SD2SNES. I will say, however, that the SD2SNES still technically just uses an FPGA to emulate the Super FX chip, so the Super FX part there might not be quite as accurate as a real SuperFX cartridge.

EDIT: Just tested it on my SD2SNES. It works just fine on there. I did not notice any problems or differences whatsoever.
I have an ASD, so empathy is not natural for me. If I hurt you, I apologise.

secondsun
Posts: 33
Joined: Tue Jul 31, 2018 9:37 am

Re: Very Simple SuperFX chip demo

Post by secondsun » Sun Mar 14, 2021 1:45 pm

Thanks for testing it, that makes me feel a lot better.

Post Reply