3DS PDN: Difference between revisions

From GameBrew
m (Text replacement - "| licence" to "| license")
No edit summary
 
(11 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{Infobox 3DS Homebrews
{{Infobox 3DS Homebrews
| title = 3ds_pdn
|title=3ds_pdn
| type = Media players
|image=3ds.png
| version = 2021
|description=(POC) 3DS PDN module rewrite.
| lastupdated = 2021/06/14
|author=hax0kartik
| license = Mixed
|lastupdated=2021/06/14
| author = hax0kartik
|type=Media Players
| website = https://gbatemp.net/threads/poc-developer-only-background-3ds-mp3-player.589949
|version=2021
| download = https://dlhb.gamebrew.org/3dshomebrew/Background-mp3-player-3DS.rar
|license=Mixed
| source = https://github.com/hax0kartik/3ds_pdn/tree/music-player
|download=https://dlhb.gamebrew.org/3dshomebrews/3dspdn.7z
|website=https://gbatemp.net/threads/poc-developer-only-background-3ds-mp3-player.589949
|source=https://github.com/hax0kartik/3ds_pdn/tree/music-player
|donation=https://ko-fi.com/hax0kartik
}}
}}
3ds_pdn is an open source implementation of PDN sysmodule which plays a MP3 from the sd card. Up until now, it was unknown whether this was possible, but as it turns out it is possible to do this. As anyone who has developed for 3DS before, should know that 3DS has two ways of playing audios, one through CSND and one through DSP. Apparently, it is possible to use CSND with modules to play music.
3ds_pdn is an open source implementation of PDN sysmodule which plays a MP3 from the sd card. Up until now, it was unknown whether this was possible, but as it turns out it is possible to do this. As anyone who has developed for 3DS before, should know that 3DS has two ways of playing audios, one through CSND and one through DSP. Apparently, it is possible to use CSND with modules to play music.


This is a functional POC of the music player (3DS PDN module rewrite) for developers and is able to play a MP3 off the sd card.
This is a functional POC of the music player (3DS PDN module rewrite) intended for developers and is able to play a MP3 off the sd card.


==Building==
==Building==
Line 25: Line 27:
===Notes===
===Notes===
* Please remove patches for any other sysmodule before trying this as they can cause issues.
* Please remove patches for any other sysmodule before trying this as they can cause issues.
* It might be better if we do not use PDN for our purposes but create a entirely new sysmodule which will be launched by the homebrew audio player app.
* 3DS sleep mode will be broken by this, you'll need to restart your console.
* 3DS sleep mode will be broken by this, you'll need to restart your console.
* On a N3DS, enabling Clock+L2C seems to make the code run a bit more smoother.
* On a N3DS, enabling Clock+L2C seems to make the code run a bit more smoother.
* It might be better if we do not use PDN for our purposes, instead create a new sysmodule to be launched by the homebrew audio player app.


==Credits==
==Credits==
Line 36: Line 38:
* GBAtemp - https://gbatemp.net/threads/poc-developer-only-background-3ds-mp3-player.589949
* GBAtemp - https://gbatemp.net/threads/poc-developer-only-background-3ds-mp3-player.589949


[[Category:3DS homebrew applications]]
 
[[Category:Homebrew media players on 3DS]]
 
[[Category:Support the author]]

Latest revision as of 06:26, 6 May 2024

3ds_pdn
3ds.png
General
Authorhax0kartik
TypeMedia Players
Version2021
LicenseMixed
Last Updated2021/06/14
Links
Download
Website
Source
Support Author

3ds_pdn is an open source implementation of PDN sysmodule which plays a MP3 from the sd card. Up until now, it was unknown whether this was possible, but as it turns out it is possible to do this. As anyone who has developed for 3DS before, should know that 3DS has two ways of playing audios, one through CSND and one through DSP. Apparently, it is possible to use CSND with modules to play music.

This is a functional POC of the music player (3DS PDN module rewrite) intended for developers and is able to play a MP3 off the sd card.

Building

To build you need to have ctrtool in your path, after which do make.

User guide

To use you need to put a MP3 file named as sound.mp3 on the root of your sd card and then enable game patching. The PDN sysmodule will spawn a thread in appcore for MP3 decoding and playing.

The POC works (atleast on N3DS, for O3DS you might need to change appcore to syscore or change the prio) but not smoothly, every time the system/game spawns a new thread there is a small break in audio due to the audio thread freezing and there are constant pop sounds. One possible reason is that the audio decoding and playing code will need soft-tuning.

Notes

  • Please remove patches for any other sysmodule before trying this as they can cause issues.
  • 3DS sleep mode will be broken by this, you'll need to restart your console.
  • On a N3DS, enabling Clock+L2C seems to make the code run a bit more smoother.
  • It might be better if we do not use PDN for our purposes, instead create a new sysmodule to be launched by the homebrew audio player app.

Credits

@luigoalma - Help improving the code.

External links

Advertising: