Homebrew blargSnes -- SNES emulator for the 3DS (WIP)

Status
Not open for further replies.

MajinCubyan

The Funky Super Saiyan
Member
Joined
Nov 24, 2014
Messages
783
Trophies
2
Age
35
Location
Orre
XP
2,124
Country
United States
A few findings;

-I got an error when I tried to start Doom on the SNES emulator, it said report to staplebutter. Don't have a screen of it right now but can try to get one if you need it.
-Trying to start Chrono trigger destroys everything, freezing up forcing to hard reset console.




God a PS1 emulator would make me drool, but right now I'd already be happy with a sped up GBA emulator. Very excited to see what will happen with the ninjhax update.

Doom has a special chip that isnt emulated yet.
 

shinyquagsire23

SALT/Sm4sh Leak Guy
Member
Joined
Nov 18, 2012
Messages
1,977
Trophies
2
Age
26
Location
Las Vegas
XP
3,765
Country
United States
Maybe some crazy mind will even attempt DS emulation, but that's a whole different thing. Oh well, we'll see :)


Merry Christmas guys :D



(the Chrono Trigger shiz is known too; it won't run on the last release because of unimplemented SPC700 instructions)

That would actually be interesting, although I'd imagine the hard part would be emulating the graphics/audio/other stuff more than the processor.
 

Celice

Well-Known Member
Member
Joined
Jan 1, 2008
Messages
1,920
Trophies
1
XP
628
Country
United States
Man, don't even mention DS emulation. I would KILL someone to get my DS Fire Emblems emulated on my 3DS. >.>
You may be able to. Nintendo of Japan released a DS game last year as a download title for the 3DS. I'm not sure if anyone in the scene has ever looked into the title to see if it can be broken down and swapped like other VC titles.
 

DiscostewSM

Well-Known Member
Member
Joined
Feb 10, 2009
Messages
5,484
Trophies
2
Location
Sacramento, California
Website
lazerlight.x10.mx
XP
5,509
Country
United States
I was looking into how noise could be incorporated into the emulator, but with all the ASM being used for mixing and processing audio, it's making it quite a challenge to understand it, and preventing a point of attack. I know some ASM, but not a whole lot. From what I understand, there is a single noise unit that (unless told otherwise) is consistently generating sample as white noise, having its own frequency, and is substituted in for any channels that have their noise flag set. It generates 15-bit samples (range -4000h ... +3FFFh), starting with -4000h upon reset (whether by power-on or set under the DSP register: FLG?), and then goes through this formula to generate the next sample.

sample = ((sample >> 1) & 0x3FFF) | (((sample ^ (sample >> 1)) & 0x1) << 14);

The frequency that noise runs at is set by the first 5 bits of the DSP register: FLG, which can range from a full stop (value of 0x00) to generating a 32kHz sample for each step (value of 0x1F), and generating samples after so many steps in between that range. I imagine that when not set at 0x1F, it just uses the previous sample generated until the number of steps it needs to make is complete. DSP Register: NON is what determines what channels use noise instead of the decompressed BRR samples. However, even with using noise, those BRR samples are still being decompressed because they determine the length of the noise (whether it will stop or loop).
 
  • Like
Reactions: VinsCool

DiscostewSM

Well-Known Member
Member
Joined
Feb 10, 2009
Messages
5,484
Trophies
2
Location
Sacramento, California
Website
lazerlight.x10.mx
XP
5,509
Country
United States
You may be able to. Nintendo of Japan released a DS game last year as a download title for the 3DS. I'm not sure if anyone in the scene has ever looked into the title to see if it can be broken down and swapped like other VC titles.


It may just be using the DS_FIRM, much like GBA Ambassador games use AGB_FIRM, to which it won't have any emulation features.
 

Kikirini

Zelda Fangirl
Member
Joined
May 18, 2011
Messages
1,142
Trophies
0
Age
34
Location
Vermont, USA
Website
kuroshouri.com
XP
1,214
Country
United States
You may be able to. Nintendo of Japan released a DS game last year as a download title for the 3DS. I'm not sure if anyone in the scene has ever looked into the title to see if it can be broken down and swapped like other VC titles.
Heck, I've downloaded DS titles off the shop. (Just Uno, but still...)
It would be nice, but I'm not holding my breath xD
 

Timburpton

Well-Known Member
Member
Joined
Nov 18, 2014
Messages
648
Trophies
0
Age
46
XP
580
Country
You may be able to. Nintendo of Japan released a DS game last year as a download title for the 3DS. I'm not sure if anyone in the scene has ever looked into the title to see if it can be broken down and swapped like other VC titles.

It is a DSi title. No work.
 

davhuit

Well-Known Member
Member
Joined
Nov 23, 2005
Messages
994
Trophies
0
XP
550
Country
France
Too bad no one is working on a sega genesis emulator. :O

Yeah, that would be nice but maybe one day! There is a pretty decent emulator on DS but the fact he have no scaling pretty much kill the interest to play it (though I understand NDS might not have enough cpu power do it a proper scaling)..

About DS emulation, don't think it has any interest as the 3DS is backward compatible so if people want to use roms, they can just get a DS flashcard compatible with 3DS (there are somes). 4.5 Gateway user can already use DS roms for example, with the blue card.

About GBA games, it seems gateway plan to fix them soon or later and maybe once it'll work, we'll be able to inject other roms like other VC games.
 
  • Like
Reactions: cvskid

Arisotura

rise of melonism
OP
Member
Joined
Dec 5, 2009
Messages
839
Trophies
1
Age
30
Location
center of the Sun
Website
kuribo64.net
XP
2,498
Country
France
I was looking into how noise could be incorporated into the emulator, but with all the ASM being used for mixing and processing audio, it's making it quite a challenge to understand it, and preventing a point of attack. I know some ASM, but not a whole lot. From what I understand, there is a single noise unit that (unless told otherwise) is consistently generating sample as white noise, having its own frequency, and is substituted in for any channels that have their noise flag set. It generates 15-bit samples (range -4000h ... +3FFFh), starting with -4000h upon reset (whether by power-on or set under the DSP register: FLG?), and then goes through this formula to generate the next sample.

sample = ((sample >> 1) & 0x3FFF) | (((sample ^ (sample >> 1)) & 0x1) << 14);

The frequency that noise runs at is set by the first 5 bits of the DSP register: FLG, which can range from a full stop (value of 0x00) to generating a 32kHz sample for each step (value of 0x1F), and generating samples after so many steps in between that range. I imagine that when not set at 0x1F, it just uses the previous sample generated until the number of steps it needs to make is complete. DSP Register: NON is what determines what channels use noise instead of the decompressed BRR samples. However, even with using noise, those BRR samples are still being decompressed because they determine the length of the noise (whether it will stop or loop).
Well yeah, that's the basic idea.

Part of me wants to just rewrite that DSP mixer in a more legible form, though. Might also be able to use some SIMD to speed it up.
 

Kazanye

Member
Newcomer
Joined
Nov 30, 2014
Messages
12
Trophies
0
Age
39
XP
55
Country
France
Maybe some of you have noticed that Smealum has released Ninjhax 1.1.
I was curious to check out the improvements so I uninstalled Ninjhax 1.0 and successfully installed 1.1 over wi-fi.

The problem now is that some homebrew seem to be partially broken. For example, blargSNES 1.2 crashes when you try to enter the settings menu, wether you click the settings icon in the rom list menu, or if you push start after pausing a game. It is also interesting to note that blarg now runs unscaled with a custom border on my 3DS, whereas it should be running scaled (it's set to 3 in the config file).

Maybe it should be corrected in the next release ?
 

Psi-hate

GBATemp's Official Psi-Hater
Member
Joined
Dec 14, 2014
Messages
1,750
Trophies
1
XP
3,439
Country
United States
Smealum says that the emulators will have to be modified towards the updated Ninjhax hardware. Once that's all sorted out, he says that a massive speed boost will come to the emus. ;)
 

davhuit

Well-Known Member
Member
Joined
Nov 23, 2005
Messages
994
Trophies
0
XP
550
Country
France
I don't think it's really useful because the number of people that will use Blargsnes with Ninjhax once Gateway will have released their 9.2 exploit will probably be really low, so even if it give a major speedboost, it's pretty useless if most people don't/can't use it.

And I don't really think it could help Snes emulation much, it's rather a good thing for GBA emulation.
 

davhuit

Well-Known Member
Member
Joined
Nov 23, 2005
Messages
994
Trophies
0
XP
550
Country
France
Never said it was garbage, but if you check twitter, you can see some of those who was using it updated to keep playing their games (Pokemon or Smash Bros) so it's just the reality to assume most of people who are on 9.2 will switch on using a gateway instead for homebrew, even more if it has emunand (which will won't block their future game updates). Not to mention "Cubic Ninja" now cost near as much as a gateway. Even the creator of Ninjhax don't really have plans to support it in higher firmwares as he said himself.

https://twitter.com/smealum/status/547607160289378304 (it's written "some", not "all").
https://twitter.com/smealum/status/547607245874155520 (gba and we can exepct , not "it will definitively give")

He even seemed to have gave up on it's project to make a region-free mod, now that the gateway exploit have been announced, refering to his lasts tweets about it.

I know a bit how much work you have to put in an emulator as I'm myself a romhacker/translator (you can find my lastest translation here : http://www.romhacking.net/translations/2301/ not the same nickname but I can be pmed there to check if I'm the same guy, gbatemp account have my brother nickname) and where you are, you often have to use debug functions/follow emulators developpement/etc... (though the PS2 translation was done without any debuggeur as there is no working debugger for PCSX2, the one we had was just crashing near all the time...) though, I don't understand your point. Never said my opinion was an absolute truth, it's just my opinion and StapleButter is free to do what he wants.

So if someone don't know anything about emulators, he shouldn't talk at all? That's the old debate of elite who say for example you can't make a movie critic if you are a movie director, which is a fucking retarded point (but well, what could I except more for someone who is an anti-GW and try to bash every people who refer to it? Not the first time, not the last time).

Anyway, I'm curious to see how it might give a big speedup for SNES emulation when most games already seems to run at the right speed.

If "useless = garbage" for you, then I understand your message but in my dictionnary, "useless =/ garbare". A really good thing can become useless become something else appeared, without making the old thing "garbare".
 
Status
Not open for further replies.

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    SylverReZ @ SylverReZ: https://www.bleepingcomputer.com/news/security/hackers-phish-finance-orgs-using-trojanized-minesw...