Homebrew Homebrew Development

AlbertoSONIC

Pasta Team Member
Member
Joined
Jun 27, 2014
Messages
927
Trophies
0
Age
52
Website
www.albertosonic.com
XP
1,396
Country
Italy
Code:
// Check if user is in GW mode
    if (CSND_initialize(NULL)==0){
    CSND_shutdown();
    GW_MODE = false;
    }else{
    GW_MODE = true;
    }

This is how i check a GW/N3DS on lpp-3ds.

Wait can you explain this code? GW_MODE is set to true if it's in gateway mode? And if not, it shutdown CSND?

also, which bit resolution and sampling rate do i have to use for converting the wav file?
 

Rinnegatamante

Well-Known Member
Member
Joined
Nov 24, 2014
Messages
3,162
Trophies
2
Age
29
Location
Bologna
Website
rinnegatamante.it
XP
4,857
Country
Italy
CSND cannot be initialized with GW so you can check if your homebrew is started from ninjhax or from a GW/other flashcard by seeing what's the result of the CSND initialization (Note that also N3DS cannot initialize CSND).
 

Technicmaster0

Well-Known Member
Member
Joined
Oct 22, 2011
Messages
4,410
Trophies
2
Website
www.flashkarten.tk
XP
3,513
Country
Gambia, The
Someone knows how to use gyroscope?

I tried to use this:
Code:
hidScanInput();
    irrstScanInput();
HIDUSER_EnableGyroscope();
float value;
        HIDUSER_GetGyroscopeRawToDpsCoefficient(&value);

But ninjhax crashes when i try it.
You should try it with
Code:
hidScanInput();
irrstScanInput();
EnableGyroscope();
float value;
GetGyroscopeRawToDpsCoefficient(&value);
 

AlbertoSONIC

Pasta Team Member
Member
Joined
Jun 27, 2014
Messages
927
Trophies
0
Age
52
Website
www.albertosonic.com
XP
1,396
Country
Italy
CSND cannot be initialized with GW so you can check if your homebrew is started from ninjhax or from a GW/other flashcard by seeing what's the result of the CSND initialization (Note that also N3DS cannot initialize CSND).

Ok but why do you shutdown CSND if it has been correctly initialized?

also, which bit resolution and sampling rate do i have to use for converting the wav file?
 

Rinnegatamante

Well-Known Member
Member
Joined
Nov 24, 2014
Messages
3,162
Trophies
2
Age
29
Location
Bologna
Website
rinnegatamante.it
XP
4,857
Country
Italy
You should try it with
Code:
hidScanInput();
irrstScanInput();
EnableGyroscope();
float value;
GetGyroscopeRawToDpsCoefficient(&value);

Solved the problem few minutes ago but i still don't know how to properly get gyroscope status. It seems values are random like it's not calibrated.
When i try do do something like (z * value) where z is the Z result of hidGyroRead, i get variable values even if 3DS is not moving :/

Bitpersample and samplerate can be selected by your own, you have to take them with your WAV decoder by the header.
I shut CSND because lpp-3ds provides itself a function to initialize CSND (Sound.init).
 

Technicmaster0

Well-Known Member
Member
Joined
Oct 22, 2011
Messages
4,410
Trophies
2
Website
www.flashkarten.tk
XP
3,513
Country
Gambia, The
Solved the problem few minutes ago but i still don't know how to properly get gyroscope status. It seems values are random like it's not calibrated.
When i try do do something like (z * value) where z is the Z result of hidGyroRead, i get variable values even if 3DS is not moving :/
I think that you should use "hidGyroRead(angularRate* rate)".
 

AlbertoSONIC

Pasta Team Member
Member
Joined
Jun 27, 2014
Messages
927
Trophies
0
Age
52
Website
www.albertosonic.com
XP
1,396
Country
Italy
Solved the problem few minutes ago but i still don't know how to properly get gyroscope status. It seems values are random like it's not calibrated.
When i try do do something like (z * value) where z is the Z result of hidGyroRead, i get variable values even if 3DS is not moving :/

Bitpersample and samplerate can be selected by your own, you have to take them with your WAV decoder by the header.
I shut CSND because lpp-3ds provides itself a function to initialize CSND (Sound.init).

Alright, so i put your code just at the top of my code (without csnd shutdown) and then i use GW_MODE to check if i can use it or not to use it?
 

AlbertoSONIC

Pasta Team Member
Member
Joined
Jun 27, 2014
Messages
927
Trophies
0
Age
52
Website
www.albertosonic.com
XP
1,396
Country
Italy
I'm trying to convert it using audacity, but all i'm getting is a strange sound... Could someone convert this .wav file? https://www.dropbox.com/s/4oxxt9v7yko2cjr/POP.wav?dl=0

I also tried to cut the header using an hex editor, but it worked partially. The sound is similar to the one i'm trying to convert, but it has a loud and strange sound at the end..
 

Rinnegatamante

Well-Known Member
Member
Joined
Nov 24, 2014
Messages
3,162
Trophies
2
Age
29
Location
Bologna
Website
rinnegatamante.it
XP
4,857
Country
Italy
I'm trying to convert it using audacity, but all i'm getting is a strange sound... Could someone convert this .wav file? https://www.dropbox.com/s/4oxxt9v7yko2cjr/POP.wav?dl=0

I also tried to cut the header using an hex editor, but it worked partially. The sound is similar to the one i'm trying to convert, but it has a loud and strange sound at the end..

Probably you give an incorrect size to audiobuffer or incorrect samplerate.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • Sicklyboy @ Sicklyboy:
    I use AKG K7XX headphones for daily use, but Meze 99 Classics when I want to *enjoy* the music
    +1
  • Psionic Roshambo @ Psionic Roshambo:
    I mean built in sound on mobo's has gotten way better but still XP handled sound better and X-Fi was still better than onboard audio even to this day
  • Psionic Roshambo @ Psionic Roshambo:
    Hell not sure what was going on but for like a few weeks MP3's sounded muffled, some driver or Windows update fixed it. Thank god lol
  • Sicklyboy @ Sicklyboy:
    Oh boy Massdrop has $1100 IEMs. Want, but not at that price lmao. https://drop.com/buy/campfire-audio-andromeda-emerald-sea-iem
  • Sicklyboy @ Sicklyboy:
    I'd sooner buy the Meze 109 Pro if I was dropping that much on headphones. I don't even like buds/IEMs
  • Sicklyboy @ Sicklyboy:
    I got the Google Pixel Pro buds, they're good enough for when I need portable audio. And some really cheap IEMs that Dankpods recommends, I think the KZ ZSN Pro
    +1
  • K3Nv2 @ K3Nv2:
    I'd stick with cheapo Chinese $10 ones quality is actually becoming on pair with name brand since name Brand usually quads the price up anyway loose one bud that's another $200
  • Sicklyboy @ Sicklyboy:
    My Pixel Pro buds shit the bed a month or two ago. My wireless charger (which they do support Qi charging) absolutely COOKED them. Caused some problem that caused the case to heat up to 180F+
  • Sicklyboy @ Sicklyboy:
    They were like 9 months out of warranty but I hit up Google support anyway and told them how hot they were getting and they replaced them with new ones because they wanted these for failure analysis lol
  • Psionic Roshambo @ Psionic Roshambo:
    lol wireless charging
  • K3Nv2 @ K3Nv2:
    Yeah that's why I can't bring myself to even spend $100 on wireless earbuds
  • Psionic Roshambo @ Psionic Roshambo:
    I think it's a cool idea but damn
  • Sicklyboy @ Sicklyboy:
    Apparently the case has a problem with >15W wireless chargers. Google design fault, that one.
  • K3Nv2 @ K3Nv2:
    I could live with wireless charging if the damn standard case doesn't block connection
  • Xdqwerty @ Xdqwerty:
    how is wireless charging possible?
  • K3Nv2 @ K3Nv2:
    Dbz said everyone has raging energy senses
    +1
  • cearp @ cearp:
    you mean generally, how does the concept work?
    +1
  • K3Nv2 @ K3Nv2:
    Copper conducting electricity or something
  • Sicklyboy @ Sicklyboy:
    @Xdqwerty, power through a coil of wire causes an electromagnetic field to be generated. Another coil of wire can be set up to harness the power from that electromagnetic field and turn it into usable energy for charging a device
  • Sicklyboy @ Sicklyboy:
    Two good videos from ElectroBOOM that touch on the subject:

    https://www.youtube.com/watch?v=TQwGjhwPEik

    https://www.youtube.com/watch?v=M2YwkAWg0_g
    +1
  • K3Nv2 @ K3Nv2:
    Elements on earth are actually more powerful than we think
  • Sicklyboy @ Sicklyboy:
    Wow I can't believe I've been watching ElectroBOOM for that long. I remember when that first video came out lol
    Sicklyboy @ Sicklyboy: Wow I can't believe I've been watching ElectroBOOM for that long. I remember when that first...