Homebrew HzMod - old3DS screen streaming

  • Thread starter Sono
  • Start date
  • Views 248,722
  • Replies 573
  • Likes 102

What should be HorizonModule renamed to?

  • HzMod

    Votes: 11 50.0%
  • HzModule

    Votes: 8 36.4%
  • HzProc

    Votes: 2 9.1%
  • HzDbg

    Votes: 1 4.5%
  • HzDebug

    Votes: 0 0.0%

  • Total voters
    22
  • Poll closed .

Portentous

New Member
Newbie
Joined
May 1, 2021
Messages
2
Trophies
0
Age
21
XP
37
Country
United States
Enabled hotspot on your PC/Notebook and connect to it with your 3DS. it runs much better than when connected on wifi router
That's what I have to do in the first place since my router is 5MHz instead of 2.4 or whatever lol. I have to do that with my Wii's, so I assumed I'd have to do it with my 3DS too
 

Aheago

Well-Known Member
Member
Joined
Jan 4, 2021
Messages
505
Trophies
0
Age
33
XP
1,222
Country
United States
HzMod (or as more widely known "HorizonModule" or simply just "HorizonM") is a sysmodule for the 3DS which runs in the background. By looking at the reason why this project was started, this could be a "trying-to-be NTR clone".


Pros over NTR:
- runs natively (doesn't need to "eat" itself into random processes, though still needs a launcher (HzLoad) to launch)
- old3DS-compatible screen streaming
- *much* better game compatibility (in theory it's >99%, and it works with *hax (Rosalina and non-Rosalina) too!)

Cons over NTR:
- slightly worse screen streaming performance (NTR does some very hacky things to squeeze every last bit of performance out of the system as it can in a RAM-wasting fashion)
- game plugins are part of HzTool (but you can still poke memory from PC side using custom HzScreen)





Boring statistical data / facts:
  • old3DS hard (read as "total maximum", not *hardware*) limit is a bit above 21FPS, but at that point the game is awfully stuttering
  • new3DS softhard limit is 63FPS, but it would be possible to reach the 120FPS hardware limit via unstable and crashy hax on a pure white top screen (would require a complete rewrite (of the wifi sysmodule, also known as nwm))
  • on new3DS the performance boost comes from the L2 cache, hence disabling it makes the performance drop *below* old3DS speeds
  • on new2DS only HzMod gets a dedicated CPU core due to a dummy qtm sysmodule, hence it runs somewhat faster than any other new3DS (QTM is sure a resource-hungry beast)

Features:
- screen streaming from 3DS
(do you expect anything else from a purpose-built program on a purpose-built system?)

Usage:
  1. install HorizonM.cia or HzMod.cia (base module, does not show up in Home Menu)
  2. install HzLoad.cia (this shows up in Home Menu, but this does NOT contain HzMod, this is only the launcher)
  3. install HzLoad_HIMEM.cia on old3DS/2DS if you plan on using extended memory games (if the backlight turns off for more than a few seconds when launching the game then it is most likely an extended memory game)
  4. open the HzLoad of your choice
  5. open a console or PowerShell (SHIFT-RIGHTCLICK in an empty space in the directory where HorizonScreen is extracted)
  6. .\HorizonScreen-PC <ipaddress>
    • on my home network I run .\HorizonScreen-PC 192.168.1.65
    • in some old packages found on the internet it might be .\out\HorizonScreen-PC
  7. set JPEG quality to at least two digits with UP/DOWN keyboard buttons in HorizonScreen (if you can even see it change)
  8. press L on the keyboard to connect (or START if you have a PS2 controller plugged into the system)
If HzScreen doesn't connect then check the console:
  • 10060 - Windows can't find the 3DS on the network
  • 10061 - Windows can see the 3DS, but HzMod is not running on the 3DS, or it has crashed
    • look at the LED color, it must be bright blue
    • when you press a button, the LED must flash red and white very fast
  • if you see "data too long" then check if you have mistyped the IP address

All you had to do is read the damn README, CJ!

Downloads have been revoked. Thank you for your support.

Does this work with any NTR streamer program ? I want to stream to my TV using my Xbox one
 

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,827
Trophies
2
Location
home
XP
9,397
Country
Hungary
Does this work with any NTR streamer program ? I want to stream to my TV using my Xbox one

Nope.

HzMod has its own custom protocoll.

And that aside, NTR uses UDP, while HzMod uses TCP.
I can't use UDP in HzMod because the call overhead to the network send routine is so high that NTR had to copy itself into the WiFi driver to achieve the speeds it does.
 

FanNintendo

Well-Known Member
Member
Joined
Apr 16, 2018
Messages
1,591
Trophies
0
Age
51
XP
2,543
Country
United States
Nope.

HzMod has its own custom protocoll.

And that aside, NTR uses UDP, while HzMod uses TCP.
I can't use UDP in HzMod because the call overhead to the network send routine is so high that NTR had to copy itself into the WiFi driver to achieve the speeds it does.
what is TCP and can you explain HzMod like you explained for NTR?
 

jeffyTheHomebrewer

Neato Burrito!
Member
Joined
Aug 24, 2018
Messages
1,625
Trophies
1
Location
his house!
Website
catboybeebop.neocities.org
XP
3,508
Country
United States
It's bad.

It has a million problems, it's slower than it should be, and it still doesn't work properly with Mario Maker 3DS.
Don't get me started on bottom screen streaming...
Yeah.. Plus it also doesn't work with Xash3DS (3DS .cia port of Xash3D, an open source GoldSrc alternative, mostly so you can play HL1 on the go.) Will we ever see anything like HzMod but better? (and not NTR, that thing sucks + it's even more broken)
 

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,827
Trophies
2
Location
home
XP
9,397
Country
Hungary
what is TCP and can you explain HzMod like you explained for NTR?

I'll try to easy explain it.

UDP can only handle small data, and it's lossy, but you can send as many as the network driver can handle.
TCP is lossless, and the overhead for the lossless data transmission comes at a significant cost and RAM usage.

UDP is better for streaming data where losses are not cared about that much, as speed is preferred.
TCP is better for reliable data transmission, and supports sending a lot of data "at once" (basically limited by RAM).

Because networking in 3DS is bad, and the OS is also very slow, sending UDP packets is limited to around 10 per second on old3DS (regardless of size) if you do it the intended way.
NTR copies itself into the WiFi driver to bypass the slow OS and send data directly from the driver, so it can send a lot more than 10 per second.

HzMod works around this limitation by keeping all data in RAM, and letting the WiFi driver to slowly send data via TCP, as it only results in only a single call per frame, instead of multiple calls per frame.
The side effect of this is that there is less RAM available to games, and since TCP is lossless, it can decrease performance on bad WiFi conneciton.

Yeah.. Plus it also doesn't work with Xash3DS (3DS .cia port of Xash3D, an open source GoldSrc alternative, mostly so you can play HL1 on the go.) Will we ever see anything like HzMod but better? (and not NTR, that thing sucks + it's even more broken)

HzMod has never really worked on homebrew launcher from Homebrew Launcher.
It has once worked with old *hax, but Rosalina Homebrew Launcher just makes HzMod crash for some reason.
Did you try with a .cia version to see if it works at all?

Also, what does it mean "it doesn't work"? Crash? No graphics? No connection?

Yes, it's possible to optimize HzMod better (although on old3DS we're already peaking max FPS around 12 - 15).
For example, I could use a better JPEG encoder. Or I could optimize the code which fixes Smash and MK7 streaming.

And perhaps a Luma-exclusive mode where it doesn't need to double-copy RAM, and instead can work in-place, reducing both time spent on a frame, and also the RAM usage.

I can only assume that hzmod has been taken down until it gets fixed to the point where it can be reuploaded.

I took it down because I'm no longer developing homebrew, and can't deal with bugfixes anymore. I don't have the time and energy to do it.
 

FanNintendo

Well-Known Member
Member
Joined
Apr 16, 2018
Messages
1,591
Trophies
0
Age
51
XP
2,543
Country
United States
I'll try to easy explain it.

UDP can only handle small data, and it's lossy, but you can send as many as the network driver can handle.
TCP is lossless, and the overhead for the lossless data transmission comes at a significant cost and RAM usage.

UDP is better for streaming data where losses are not cared about that much, as speed is preferred.
TCP is better for reliable data transmission, and supports sending a lot of data "at once" (basically limited by RAM).

Because networking in 3DS is bad, and the OS is also very slow, sending UDP packets is limited to around 10 per second on old3DS (regardless of size) if you do it the intended way.
NTR copies itself into the WiFi driver to bypass the slow OS and send data directly from the driver, so it can send a lot more than 10 per second.

HzMod works around this limitation by keeping all data in RAM, and letting the WiFi driver to slowly send data via TCP, as it only results in only a single call per frame, instead of multiple calls per frame.
The side effect of this is that there is less RAM available to games, and since TCP is lossless, it can decrease performance on bad WiFi conneciton.



HzMod has never really worked on homebrew launcher from Homebrew Launcher.
It has once worked with old *hax, but Rosalina Homebrew Launcher just makes HzMod crash for some reason.
Did you try with a .cia version to see if it works at all?

Also, what does it mean "it doesn't work"? Crash? No graphics? No connection?

Yes, it's possible to optimize HzMod better (although on old3DS we're already peaking max FPS around 12 - 15).
For example, I could use a better JPEG encoder. Or I could optimize the code which fixes Smash and MK7 streaming.

And perhaps a Luma-exclusive mode where it doesn't need to double-copy RAM, and instead can work in-place, reducing both time spent on a frame, and also the RAM usage.



I took it down because I'm no longer developing homebrew, and can't deal with bugfixes anymore. I don't have the time and energy to do it.
Thank you for explaining each. I am trying to figure which is better to get best compability for streaming on pc. I have tried HzMod with kit kat before. Hope someone take over HzMod someday and redo. Maybe wii U moonlight will work with 3ds ?? Thank you again
 

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,827
Trophies
2
Location
home
XP
9,397
Country
Hungary
Thank you for explaining each. I am trying to figure which is better to get best compability for streaming on pc. I have tried HzMod with kit kat before. Hope someone take over HzMod someday and redo. Maybe wii U moonlight will work with 3ds ?? Thank you again

Don't know what moonlight is, and I don't think KitKat works with HzMod other than Snickersteam.

HzMod actually has better compatibility than NTR, and Virtual Console (like Gameboy games) actually has a correct color pattern, and not bad blue like NTR does.
 

jeffyTheHomebrewer

Neato Burrito!
Member
Joined
Aug 24, 2018
Messages
1,625
Trophies
1
Location
his house!
Website
catboybeebop.neocities.org
XP
3,508
Country
United States
HzMod has never really worked on homebrew launcher from Homebrew Launcher.
It has once worked with old *hax, but Rosalina Homebrew Launcher just makes HzMod crash for some reason.
Did you try with a .cia version to see if it works at all?

Also, what does it mean "it doesn't work"? Crash? No graphics? No connection?

Yes, it's possible to optimize HzMod better (although on old3DS we're already peaking max FPS around 12 - 15).
For example, I could use a better JPEG encoder. Or I could optimize the code which fixes Smash and MK7 streaming.

And perhaps a Luma-exclusive mode where it doesn't need to double-copy RAM, and instead can work in-place, reducing both time spent on a frame, and also the RAM usage.

Okay, so turns out the Xash3DS issue is with Snickerstream (the windows client I use for HzMod) since that doesn't support TARGA streams. Aside from that turns out there aren't any issues.. My bad. Also, where can we find the source code for HzMod? If you're not gonna make any bugfixes at least make it open source.
 
Last edited by jeffyTheHomebrewer,
  • Like
Reactions: livid_hen

Deleted member 446461

Well-Known Member
Member
Joined
Apr 16, 2018
Messages
265
Trophies
0
XP
485
Okay, so turns out the Xash3DS issue is with Snickerstream (the windows client I use for HzMod) since that doesn't support TARGA streams. Aside from that turns out there aren't any issues.. My bad. Also, where can we find the source code for HzMod? If you're not gonna make any bugfixes at least make it open source.
Sono doesn't publish source codes anymore -- people leave credits for him in the code, not on the program's output.
 
  • Like
Reactions: Sono

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,827
Trophies
2
Location
home
XP
9,397
Country
Hungary
Okay, so turns out the Xash3DS issue is with Snickerstream (the windows client I use for HzMod) since that doesn't support TARGA streams. Aside from that turns out there aren't any issues.. My bad. Also, where can we find the source code for HzMod? If you're not gonna make any bugfixes at least make it open source.

There is source archived online by others. Newer versions don't have the source released, but it's not like I changed too many things.

As for being locked to TARGA stream, that's an old version issue. I have a version where all pixel formats support JPEG, but I broke it somewhere, and it runs at half the FPS than it's supposed to be. I once got 60FPS in MK7 (on a new3DS, obviously), but after I broke it it's down to 31FPS. On old3DS it's unusable. Until I figure out what I broke, I can't release that version.
 
  • Like
Reactions: FanNintendo

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,827
Trophies
2
Location
home
XP
9,397
Country
Hungary
Yeah, there is a sad ending...

There are two extra unreleased versions of HzMod:
- one with a modified JPEG encoder which gets ~5-10FPS extra on new3DS
- one with FVENC which gets a lot more FPS on new3DS

Now then...

With the modified JPEG encoder, sadly there is zero performance increase (in fact, it seems to be slower???) on old3DS.
It's also not compatible with SnickerStream without modifications (the colors are messed up due to the modified colormath).

With FVENC, on old3DS I'm 64kilobytes short of RAM. While it's true that I had it working on old3DS (I got ~10FPS in ACNL), I had to reuse memory, which results in graphical glitches (which also decrease the performance, so it might be even better than 10FPS).

So basically old3DS runs "best" as is now. The hardware is really not meant for this, and it shows.
Funnily enough, the crippling factor is access to more RAM, and CPU cache.
While it's true that having more CPU power means more FPS, on a 3DS we're more often crippled by the memory speed than the CPU speed.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    Xdqwerty @ Xdqwerty: See ya see ya later later