Jump to content

Photo

it's fun to play on the F. P. G. A.

FPGA emulation vhdl verilog

126 replies to this topic

#26 phoenixdownita OFFLINE  

phoenixdownita

    River Patroller

  • 2,823 posts

Posted Thu Mar 2, 2017 8:47 PM

the problem is 32K of SRAM is nothing.  even 256K of SRAM is nothing.  the FPGA has plenty of blockrams on it in this size or better, and can run much faster- 150-200MHz or more.  The problem is bulk storage (i.e. neogeo carts) and sometimes raw speed (tg16).  Many tg16 games won't fit into 8 32K SRAMs.    The problem with SDRAM/DDR is latency.  These systems require random access to the storage medium to run the game, and SDRAM/DDR is designed for burst access.   i.e. you precharge, open the row, and burst out 2 or more words of data really fast.

 

With older videogame stuff that had asynchronous memory, they expect to present an address and read data X nanoseconds later.   Shoehorning this into SDRAM access means the SDRAM has to run through the entire access process for each byte/word the system expects.  i.e.  precharge, open the row, send address, read.   each of those things take a certain number of clocks to perform.   There's also refreshing to worry about.  The refreshing can be spaced out using "hidden refresh" but this also increases the latency as well. 

 

The tg16 wants data at 7.2MHz which is pretty damn fast when it comes to random access on the SDRAM, even when the SDRAM is running at 165MHz.  For PC style emulation this isn't such a huge problem- they can take advantage of bursting and caching to get around a lot of the problems with FPGA style low level hardware emulation.

Flahscart works today, surely you could do the same (the NeoSD is not super fast during first flashing but it works like 3m:30s to load KOF2003, Turbo EDv2 uses RAM and it's very very fast).

I thought the issue you were facing was the actual RAM the system had and not the storage for the ROM, an all RAM solution would be awesome if possible but if not then fall back to flash would be perfectly acceptable. The total size of a NeoGeo game is <= 128MB, the PCE has the biggest mapper game at 2MB (SF II) and as you are aware all games run today on NeoSD and on TurboED v2 (which has 4MB RAM onboard) ..... 

 

I'm not questioning how hard/easy just stating it's been done for PCE and flash would be an acceptable fallback for NeoGeo if 128MB of SRAM or Pseudo/1T SRAM is too expensive.

 

Just brainstorming here, not attempting to derail your line of thought/project

 

EDIT:

is this availble for cheap?

http://www.winbond.c...artNo=W968D6DAG

you'd need 8 of them for 128MB assuming you don't need to support weird splits.



#27 R.Cade OFFLINE  

R.Cade

    Stargunner

  • 1,074 posts
  • Location:Augusta, Georgia, USA

Posted Thu Mar 2, 2017 8:59 PM

Until something else comes along, the MiST is still the best deal. It has a lot of cores to play with and is not "break the bank" expensive. I haven't regretted it- especially in RGB connected to my Sony PVM. It's beautiful...


Edited by R.Cade, Thu Mar 2, 2017 9:00 PM.


#28 phoenixdownita OFFLINE  

phoenixdownita

    River Patroller

  • 2,823 posts

Posted Thu Mar 2, 2017 9:05 PM

Until something else comes along, the MiST is still the best deal. It has a lot of cores to play with and is not "break the bank" expensive. I haven't regretted it- especially in RGB connected to my Sony PVM. It's beautiful...

I don't want go back to CRT and VGA, I want the convenience of HDMI out.



#29 R.Cade OFFLINE  

R.Cade

    Stargunner

  • 1,074 posts
  • Location:Augusta, Georgia, USA

Posted Thu Mar 2, 2017 9:23 PM

To each his own... Playing old stuff on LCD doesn't feel right to me. Might as well use software emulation for that. ;)



#30 kevtris OFFLINE  

kevtris

    Dragonstomper

  • 513 posts
  • FPGA Whisperer
  • Location:Flyover, USA

Posted Thu Mar 2, 2017 9:27 PM

Flahscart works today, surely you could do the same (the NeoSD is not super fast during first flashing but it works like 3m:30s to load KOF2003, Turbo EDv2 uses RAM and it's very very fast).

I thought the issue you were facing was the actual RAM the system had and not the storage for the ROM, an all RAM solution would be awesome if possible but if not then fall back to flash would be perfectly acceptable. The total size of a NeoGeo game is <= 128MB, the PCE has the biggest mapper game at 2MB (SF II) and as you are aware all games run today on NeoSD and on TurboED v2 (which has 4MB RAM onboard) ..... 

 

I'm not questioning how hard/easy just stating it's been done for PCE and flash would be an acceptable fallback for NeoGeo if 128MB of SRAM or Pseudo/1T SRAM is too expensive.

 

Just brainstorming here, not attempting to derail your line of thought/project

 

EDIT:

is this availble for cheap?

http://www.winbond.c...artNo=W968D6DAG

you'd need 8 of them for 128MB assuming you don't need to support weird splits.

yeah I thought about putting a few megs (8 or 16) of mobile psram on the Z3K for the fast stuff but ultimately still undecided.



#31 Keatah ONLINE  

Keatah

    Quadrunner

  • 18,917 posts

Posted Thu Mar 2, 2017 9:32 PM

I've been playing through emulation for so long now that the faults and idiosyncrasies of real analog hardware is a real annoyance.

#32 phoenixdownita OFFLINE  

phoenixdownita

    River Patroller

  • 2,823 posts

Posted Thu Mar 2, 2017 9:47 PM

To each his own... Playing old stuff on LCD doesn't feel right to me. Might as well use software emulation for that. ;)

Well given they are not manufacturing CRTs anymore and that they do eventually break I guess I'm training to the inevitable.

Plus I actually play also on a plasma and saturation, blacks, colors are awesome. But they don't make many of those either.



#33 Newsdee OFFLINE  

Newsdee

    Stargunner

  • Topic Starter
  • 1,061 posts

Posted Fri Mar 3, 2017 1:31 AM

You do feel the difference when playing on LCD with real hw/FPGA vs. sofware emulation, if there is some lag (either input lag or video lag from the source).

That said I expect people who never used the originals to not really notice it. I only noticed after playing the same game on the real machine then later on an emu box.

Edited by Newsdee, Fri Mar 3, 2017 1:32 AM.


#34 Keatah ONLINE  

Keatah

    Quadrunner

  • 18,917 posts

Posted Fri Mar 3, 2017 2:29 AM

I had all the original consoles. Software Emulation isn't all that much different in terms of performance and lag.



#35 Newsdee OFFLINE  

Newsdee

    Stargunner

  • Topic Starter
  • 1,061 posts

Posted Fri Mar 3, 2017 6:29 AM

About the RAM, personally I got myself a ZxUno board so that I have all bases covered. They have 2-3 arcade cores and one XT (80186) core that the MiST doesn't support yet.

#36 Keatah ONLINE  

Keatah

    Quadrunner

  • 18,917 posts

Posted Fri Mar 3, 2017 11:50 AM

How will FPGA VCS repro consoles handle DPC+ games? The way I see it is you'll need to purchase a Harmony cart to go with it.



#37 phoenixdownita OFFLINE  

phoenixdownita

    River Patroller

  • 2,823 posts

Posted Fri Mar 3, 2017 11:57 AM

How will FPGA VCS repro consoles handle DPC+ games? The way I see it is you'll need to purchase a Harmony cart to go with it.

If it just limits itself to DPC (i.e.: Pitfall II) it's enough, DPC+ games are supposed to be modern homebrew so buy the 2600 adapter and the harmony cart and support the devs. In "20+Y" we can shove an ARM softcore in there and do DPC+.



#38 retro_fan OFFLINE  

retro_fan

    Star Raider

  • 83 posts

Posted Fri Mar 3, 2017 2:04 PM

Apart from these FPGA projects mentioned by Newsdee there are also quite a few interesting hobby/computer science experiments:

 

 

 

There are already a few NES implementations, for instance:

 

 

I have already mentioned this in the Z3K thread, DOS gaming on FPGA:

 

 

Some people want to improve old hardware using FPGAs, check out the MEGA65 project or the Vampire 2 Amiga accelerator.


Edited by retro_fan, Fri Mar 3, 2017 2:22 PM.


#39 Newsdee OFFLINE  

Newsdee

    Stargunner

  • Topic Starter
  • 1,061 posts

Posted Sat Mar 4, 2017 2:15 AM

That DOS FPGA is the Zet processor, which if I'm not mistaken is the base of the ZxUno DOS PC/XT core:
http://www.zxuno.com....php?f=56&t=815

The thing to bear in mind is that several of these cores are separate open source project/experiments. Once they run on an FPGA and are publicly available, they can usually be ported to another board if the hardware is similar or better.

Edited by Newsdee, Sat Mar 4, 2017 2:20 AM.


#40 Newsdee OFFLINE  

Newsdee

    Stargunner

  • Topic Starter
  • 1,061 posts

Posted Mon Mar 6, 2017 9:50 PM

Found an university project that attempted to replicate the PS1. Their report is an interesting read:
http://ece545.com/F1...rts/F13_PSX.pdf

Code seems to be here:
http://github.com/led02/psx_fpga

It looks like they got stuck though:

The core system (CPU/GTE, GPU, Memory, Controller) is largely complete (though not bug-free). However, the CDROM and MDEC are far from complete and the sound system was not even attempted. Unfortunately, time and HDMI makes fools of us all.

Still, it's a start in getting the system better documented.

Edited by Newsdee, Mon Mar 6, 2017 9:52 PM.


#41 Keatah ONLINE  

Keatah

    Quadrunner

  • 18,917 posts

Posted Mon Mar 6, 2017 10:51 PM

Love reading things like that, it's right at about my level of understanding.

 

Too bad the project was essentially given up and forgotten about, as is with many "for school" projects. Too bad they had to work under those time constraints. Too bad they didn't have enough documentation. And history has shown that the best emulators, either software on a general purpose cpu or hardware descriptions shoved into fpga, are best when slow cooked for many moons. You just don't up and up and spit something out, ala MK.



#42 zzip ONLINE  

zzip

    Stargunner

  • 1,654 posts

Posted Tue Mar 7, 2017 9:06 AM

What I find interesting is that many people bemoaned for years latency and incompatibility with CRTs for software emulation, and now that we have a technology where it isn't a problem, the complains become about lack of HDMI.

I'd imagine it's not the same set of people, but it does feel like there's some Negative Nancys around. :D

 

Probably not the same people complaining.   Lots of people dumped their old CRTs and only have flat panels now



#43 Kismet OFFLINE  

Kismet

    Chopper Commander

  • 190 posts

Posted Tue Mar 7, 2017 8:43 PM

 

Probably not the same people complaining.   Lots of people dumped their old CRTs and only have flat panels now

 

No more CRT's are being made.

https://boingboing.n...ned-crt-ar.html

 

 

 

The last manufacturer of arcade-sized cathode ray tubes is out of the business, with one supplier having only 30 or so in stock and no chance of ordering more.

 

That's it.

 

And yuck at the suggested replacement. Curved OLED's.



#44 enoofu ONLINE  

enoofu

    Dragonstomper

  • 944 posts

Posted Tue Mar 7, 2017 9:34 PM

 

 

"The last manufacturer of arcade-sized cathode ray tubes is out of the business"

 

Believe their is a few companies still running in China/Pakistan/India region for CRT's



#45 Newsdee OFFLINE  

Newsdee

    Stargunner

  • Topic Starter
  • 1,061 posts

Posted Mon Mar 13, 2017 5:21 PM

A nice write-up from the author of the Bombjack core:
http://papilio.cc/in...ground.BombJack

It has quite a bit of detail on the constraints for these kind of projects, without being too technical either. In particular Bombjack needs fast RAM access so it hasn't been ported to other boards yet.

This issue would have come up earlier had I bothered to go through a planning stage. In hindsight, it was probably serendipitous, as if I had figured this out early, I might not have started the project at all. Now that I had spent all this time and effort, I was invested. Even so, I had to put this project on ice for the rest of 2011 until through sheer luck, Jack Gasset donated a beta Papilio Plus board. The P+ uses a LX9 FPGA but the board also has a 512Kb of static RAM chip. This was perfect for this project and early this year I picked up the project again and attempted to progress it.



#46 retro_fan OFFLINE  

retro_fan

    Star Raider

  • 83 posts

Posted Thu Mar 16, 2017 1:39 PM

Five interesting links:

 

Apple2fpga: Reconstructing an Apple II+ on an FPGA

 

Emulation vs FPGA

 

ASIC, ASSP, SoC, FPGA – What's the Difference?

 

VeriSNES (FPGA-based SNES)

 

FPGA gaming on reddit


Edited by retro_fan, Thu Mar 16, 2017 2:37 PM.


#47 Thomas83Lin OFFLINE  

Thomas83Lin

    Space Invader

  • 17 posts

Posted Thu Mar 16, 2017 3:21 PM

Discussion of FPGA vs. pure software emulation excites the SHIT outta me :D

 

I have long dreamed for something like this to happen, however, it's still a new and expensive technology for casual gamers.

Besides, most people won't even get the most out of FPGA systems on their HDTVs, because every HDTV I've used has enough lag to discourage me.

As such, HDTVs don't exist to me. I'd only use these systems on computer monitors.

 

I have an AVS NES, and I'm waiting for the Z3K.

The Z3K is expected to output both HD and analogue. I'm really excited about the analogue part.

On the Nt mini I use a asus vg248qe with really good results, tried it on a 65in vizio with really bad results, almost unplayable with the lag that tv outputs. The monitor or tv really makes the difference when it comes to hdmi. 


Edited by Thomas83Lin, Thu Mar 16, 2017 3:48 PM.


#48 Newsdee OFFLINE  

Newsdee

    Stargunner

  • Topic Starter
  • 1,061 posts

Posted Thu Mar 16, 2017 6:55 PM

On the Nt mini I use a asus vg248qe with really good results, tried it on a 65in vizio with really bad results, almost unplayable with the lag that tv outputs. The monitor or tv really makes the difference when it comes to hdmi. 


Maybe you tried, but see if those TVs have any processing you can switch off. Sometimes it's called Game Mode (turn on to disable processing) but older TVs/other brands name it differently or may need switching off each effect.

#49 Newsdee OFFLINE  

Newsdee

    Stargunner

  • Topic Starter
  • 1,061 posts

Posted Thu Mar 16, 2017 6:56 PM

Five interesting links:
 
Apple2fpga: Reconstructing an Apple II+ on FPGA


If I'm not mistaken the MiST AppleII core is a port and enhancement of this one.

#50 Thomas83Lin OFFLINE  

Thomas83Lin

    Space Invader

  • 17 posts

Posted Thu Mar 16, 2017 7:19 PM

Maybe you tried, but see if those TVs have any processing you can switch off. Sometimes it's called Game Mode (turn on to disable processing) but older TVs/other brands name it differently or may need switching off each effect.

Nope you just reminded me, completely forgot about that







Also tagged with one or more of these keywords: FPGA, emulation, vhdl, verilog

0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users