Homebrew [WIP] ButtonSwap3DS - Remap buttons on your 3DS

Vieela

GBATemp's official thinker™
Member
Joined
Jan 18, 2017
Messages
562
Trophies
0
XP
936
Country
Brazil
That seems rather interesting and useful for a lot of stuff. Can be useful for a few games as well (remapping Kid Icarus camera button with no limitation) for example.
 

mcaboosec

Active Member
OP
Newcomer
Joined
Sep 15, 2009
Messages
34
Trophies
0
XP
408
Country
United States
I can get some of these later today or tomorrow, I've been super busy with school and work lately. I've also had an idea to make the system more friendly, but I haven't done much with it. I'll post any updates as I look into this.
 

danger229

Well-Known Member
Newcomer
Joined
Mar 1, 2017
Messages
56
Trophies
0
Age
26
XP
1,386
Country
United States
Slowly working on trying to make a working version with the new stuff but its kinda proving to be a pain as when i install the cia, inputs become wonky. most likely a be caused on my end, looking forward to a more user friendly version
 

Brongus

New Member
Newbie
Joined
Apr 27, 2017
Messages
3
Trophies
0
Age
23
XP
59
Country
United States
Any help? trying to compile but I get an error
"
injected.s
make[1]: bannertool: Command not found
make[1]: *** [banner.bnr] Error 127
make: *** [build] Error 2
"

Not really sure what I'm doing but I think I have something of a grasp of this.
 

mcaboosec

Active Member
OP
Newcomer
Joined
Sep 15, 2009
Messages
34
Trophies
0
XP
408
Country
United States
Any help? trying to compile but I get an error
"
injected.s
make[1]: bannertool: Command not found
make[1]: *** [banner.bnr] Error 127
make: *** [build] Error 2
"

Not really sure what I'm doing but I think I have something of a grasp of this.
Did you download the buildtools? They're needed to make the CIAs.

And what do you know, there was a bug in the c-pad code. There's a 0 missing at the end of the value at line 146 in injected.s. The repo has been updated. @Demnyx, I've tested and posted an updated version of what you had requested.

@Wishi, I've made your mapping. Let me know if it's backwards (I think I got it right).
The first file should match @neobahamut1989's build.
 

Attachments

  • ButtonSwap3DS_Up=>R_Down=>L.zip
    706.5 KB · Views: 1,038
  • ButtonSwap3DS_Wishi.zip
    706.5 KB · Views: 271
  • ButtonSwap3DS_Demnyx.zip
    707.5 KB · Views: 318
Last edited by mcaboosec,
  • Like
Reactions: Demnyx and Wishi

neobahamut1989

Member
Newcomer
Joined
Apr 24, 2017
Messages
13
Trophies
0
Age
35
XP
184
Country
Malaysia
Mind posting that for everyone? my L and R buttons are broken so I'd really appreciate it!

ah sorry forgot, but mcaboosec share already :)

currently try to learn more about button remapping cause i have no programming background.
this is the current setting for remap L to Down, and R to Up:
ldr r4, =0x40
ldr r5, =0x100
bl .button
ldr r4, =0x140
ldr r5, =0x40
bl .button

but when run the cia, input on 3ds become:
Up = R (when 'press' up button one time)
Up = Up (when 'hold' up button)
Down = L (when 'press' down button one time)
Down = Down (when 'hold' down button)

how can i change it into:
Up = Up (when 'press' up button one time)
Up = R (when 'hold' up button)
Down = Down (when 'press' down button one time)
Down = L (when 'hold' down button)


Then, this is another setting for remap L and R into Up and Down but using combo button Y (hold Y and Up for Up button and Y with down for down button).
ldr r4, =0x40
ldr r5, =0x100
bl .button
ldr r4, =0x440
ldr r5, =0x40
bl .button
ldr r4, =0x80
ldr r5, =0x200
bl .button
ldr r4, =0x480
ldr r5, =0x80
bl .button

but this setting work differently, such as i have to press Up button first then follow with Y button to become Up button. how can i change it into hold Y button first then Up button to become Up button. Sorry for my english.....i also confuse when reading what i have write :).
 

mcaboosec

Active Member
OP
Newcomer
Joined
Sep 15, 2009
Messages
34
Trophies
0
XP
408
Country
United States
Alright, let's see what's going on.
this is the current setting for remap L to Down, and R to Up:
ldr r4, =0x40
ldr r5, =0x100
bl .button
ldr r4, =0x140
ldr r5, =0x40
bl .button
Your first mapping is correct, but the second mapping is looking for Up+R to press up. It should be
Code:
ldr r4, =0x80
ldr r5, =0x200
but when run the cia, input on 3ds become:
I found a bug while troubleshooting some other mappings which resulted in the c-pad being moved down-left any time a button was held. Have you downloaded the new codebase from GitHub?
how can i change it into:
Up = Up (when 'press' up button one time)
Up = R (when 'hold' up button)
Down = Down (when 'press' down button one time)
Down = L (when 'hold' down button)
I've thought about adding this, but I just don't know how it would be possible. I would probably have to allocate some memory to keep track of button hold times, but I'm not sure if it could be done.
but this setting work differently, such as i have to press Up button first then follow with Y button to become Up button. how can i change it into hold Y button first then Up button to become Up button.
The order in which the buttons are pressed shouldn't matter, but looking at your mappings, it looks like you have it looking for X+Up and X+Down instead of Y+Up and Y+Down.
 

neobahamut1989

Member
Newcomer
Joined
Apr 24, 2017
Messages
13
Trophies
0
Age
35
XP
184
Country
Malaysia
Alright, let's see what's going on.

Your first mapping is correct, but the second mapping is looking for Up+R to press up. It should be
Code:
ldr r4, =0x80
ldr r5, =0x200

I found a bug while troubleshooting some other mappings which resulted in the c-pad being moved down-left any time a button was held. Have you downloaded the new codebase from GitHub?

I've thought about adding this, but I just don't know how it would be possible. I would probably have to allocate some memory to keep track of button hold times, but I'm not sure if it could be done.

The order in which the buttons are pressed shouldn't matter, but looking at your mappings, it looks like you have it looking for X+Up and X+Down instead of Y+Up and Y+Down.


ah yes, that explain why when i first try to remap button, every button i press always change to down-left movement. not yet download new code from github but i have deleted some code in injected.s and it start working. Sorry about first code...... :) doesnt realize i copy the wrong code.

again here the corrected code and how it behave:
Setting for remap R to Up and both Up and/or R to Up:

--------------------------
ldr r4, =0x40
ldr r5, =0x100
bl .button
ldr r4, =0x140
ldr r5, =0x40
bl .button
--------------------------

when run the cia, my 3ds input become:
Up become R when single press.
Up become Up when long press.

how can i change it into:
Up become Up when single press.
Up become R when long press.


#noted that no button is remap to R because my R button completely broken.
 

Wishi

Rareware Gamer
Member
Joined
Nov 24, 2015
Messages
219
Trophies
0
Age
27
XP
297
Country
Mexico
@Wishi, I've made your mapping. Let me know if it's backwards (I think I got it right). @mcaboosec
It works flawlessly many thanks to you , you're awesome (: , but after a while playing I think that it is a little better having "Y" in SELECT instead of "up dpad" so it would be like " R to Y button and Y button to Select" only if this doesn't cause you any trouble I would be Twice happy as I am now XD , so if you could please make this other one i would appreciate it a lot ! Thanks anyway you're awesome dude (:
 
Last edited by Wishi,

Demnyx

Well-Known Member
Newcomer
Joined
Jul 1, 2016
Messages
92
Trophies
0
Age
22
XP
330
Country
France
Did you download the buildtools? They're needed to make the CIAs.

And what do you know, there was a bug in the c-pad code. There's a 0 missing at the end of the value at line 146 in injected.s. The repo has been updated. @Demnyx, I've tested and posted an updated version of what you had requested.

@Wishi, I've made your mapping. Let me know if it's backwards (I think I got it right).
The first file should match @neobahamut1989's build.
Thanks you ! It works perfectly
 

lodart

Member
Newcomer
Joined
Jun 7, 2016
Messages
10
Trophies
0
Age
29
XP
105
Country
France
Hi ! I currently use l+b=r swap, but my r button suddenly keeps being pressed. Is there a way to keep this swap but ignore the R button (R = void) ?
Thanks !
 

gengardenne

Well-Known Member
Member
Joined
Nov 14, 2016
Messages
356
Trophies
0
Age
28
XP
384
Country
Italy
Which are the differences beetwen the standard mode and the 3 mode?More funcionality maybe?
The standard swap only A with B and the 3 mode?

And there is a way to swap the start/select with other buttons on preference?
 

mcaboosec

Active Member
OP
Newcomer
Joined
Sep 15, 2009
Messages
34
Trophies
0
XP
408
Country
United States
Sorry for no news on this for a while, I've been super busy with school and work.
Is the N3DS C-nub still unmappable? I would like to map the L and R buttons to the nub if possible.
With the release of Luma3DS v8.0, the new Rosalina module has the InputRedirection code built in, including C-nub. I'll be trying to see if I can get any sort of mapping to work between the two processes.
In addition to that, I would like to modify the Rosalina module to include input remapping, and in doing so allow for an easier way to customize the mappings. I will be trying to squeeze in some work on this when I can.
Which are the differences beetwen the standard mode and the 3 mode?More funcionality maybe?
The standard swap only A with B and the 3 mode?

And there is a way to swap the start/select with other buttons on preference?
Mode3 is used on O3DS systems for extended memory games like Smash Bros. There is no "extra" functionality other than what is necessary to get it to work in extended memory mode.
There is still no easy way to change button mappings without editing the code on your computer and making a new version.
 
  • Like
Reactions: BORTZ

gengardenne

Well-Known Member
Member
Joined
Nov 14, 2016
Messages
356
Trophies
0
Age
28
XP
384
Country
Italy
Sorry for no news on this for a while, I've been super busy with school and work.

With the release of Luma3DS v8.0, the new Rosalina module has the InputRedirection code built in, including C-nub. I'll be trying to see if I can get any sort of mapping to work between the two processes.
In addition to that, I would like to modify the Rosalina module to include input remapping, and in doing so allow for an easier way to customize the mappings. I will be trying to squeeze in some work on this when I can.

Mode3 is used on O3DS systems for extended memory games like Smash Bros. There is no "extra" functionality other than what is necessary to get it to work in extended memory mode.
There is still no easy way to change button mappings without editing the code on your computer and making a new version.
Thank you for the explanation
 

SonicvMario

Active Member
Newcomer
Joined
Jun 10, 2016
Messages
33
Trophies
0
Age
22
XP
1,104
Country
With the release of Luma3DS v8.0, the new Rosalina module has the InputRedirection code built in, including C-nub. I'll be trying to see if I can get any sort of mapping to work between the two processes.
In addition to that, I would like to modify the Rosalina module to include input remapping, and in doing so allow for an easier way to customize the mappings. I will be trying to squeeze in some work on this when I can.
Would zl and zr also be remappable or only the c nub?
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    AncientBoi @ AncientBoi: :OAnd it was from a Male Bear :ohnoes::ohnoes::ohnoes: Even I wouldn't want it :mellow: