Some hackers have managed to convert an STM32 development into a Sega Master System emulator. This means Sonic the Hedgehog running on an ARM Cortex-M4.
This hack has a number of parts. First, [Alessandro Rocchegiani] showed off a video of his Sega Master System emulator running on the STM32F429 Discovery development board. This first version used the on board 2.4″ TFT LCD screen.
[Fabrice] was working with this STM32 Discovery board already. He had developed an expansion board that added a number of features to the development kit, including an R-2R DAC for video output. When [Fabrice] found out about the Sega Master System emulator, he worked with [Alessandro] and his son [Fabrizio] to get VGA output working. They also added support for the Wii controller using [Fabrice]’s Wii library. The result is a Sega Master System emulator with VGA output at 640 x 480, with 16 bit color and Wii controller support.
You can watch a video of both the LCD and VGA versions of the hack after the break.
Cool project, but nobody is THAT bad at Sonic…
I have to agree , I’m a bad player :)
And when i was doing the video i don’t really have take care on what happened on the screen , but if so , i will just survive some more seconds …
Cheers.
congratulations for your console. which emulator did you base yourself on ? was it done from scratch ?
I’ve made from scratch using as reference a lot of documentation found on smspower.org and using my old Z80 experience.
One of the best project.
Please add instruction to compile the lastest version.
I had error in KEIL with the directive #include “—-” Please help I;m new in STM32
Many Thanks
what no blast processing.
The Mega Drive, not the Master System, was the 16-bit console.
The 16 bit color reference seems to be referring to the video DAC on the expansion board.
The Master System only had a palette of 64 colors and would normally only display half of those at once, so it’s kind of wasted at the moment.
@mark g : read correctly…
great work !!!!
…and this is how you redefine “awesome”. Thanks, made my day.
It never ceases to amaze me what some people can cram into so few bytes. (c:
This board has 8Mbytes of RAM … (just in time for when I was about to publish a Gameboy emulator on the stm32f405 with 192k ram !)
For the Original version from Alessandro , only internal Flash and SRAM is used.
the SDRAM is the ‘standard’ frame buffer , then a very little part from the 8Mb is in use ;)
For my board it actually have 24Mb and the difference with Alessandro version is that
i don’t put the Game ROMs into the Flash but i read them from SD Card and put the whole into SDRAM buffer.
And here again , we are far away from the 8Mb we can use ;)
The LCD version this is in the first beta release. It need some clean up, so I think will fit in about 20K in the future version :)
All my released Open Source can be fit in less than 32K so everyone can try it.
How about doing something with the STM32F3 Discovery board?
The 32f3 don’t have the dma2d and ltdc like the st429.
It can probably done with one of the ‘normal’ DMA but then it will happens what i get
with my st407 board , allot of glitch on screen due to bus contention and another noise
in picture when the CPU is computing allot stuff together.
You can look how ugly it become here : at 2min23sec
https://www.youtube.com/watch?v=xs_Puw_lOWg
Now , for made emulator , VGA , etc … the best match at low cost was the st429 disco board.
Heh, I was going to say it’s the Genesis, not the SMS… But it turns out that they released a ‘low def’ 8-bit Sonic game for the Master system the same year as the original. (And then later ported it directly to the Game Gear.) I had no idea.
Hi,
I am programming the STM32F429 with Forth language.
As far as I can see in your very beautyfull port of Sage Master, I have one question:
I have turn and turned again STM documentation to find the memory mapped display adresses. Any idea from where I can fetch these informations. I only need text on screen for the moment.
Thanks for your help,
Guy from Paris
Would an STM32H7 have real-time performance?