I got an interesting question here
5 posts
• Page 1 of 1
I got an interesting question here
can you transform lets say RS click on xbox button to register as V key on keyboard press?
If so what would that look like.
Does my keyboard have to be connected to the titan two?
If so what would that look like.
Does my keyboard have to be connected to the titan two?
-
alencroat - Lieutenant
- Posts: 320
- Joined: Sun Oct 15, 2017 5:58 pm
Re: I got an interesting question here
Yes with key_set
Don't need a keyboard connected.
https://www.consoletuner.com/wiki/index ... t2:key_set
Don't need a keyboard connected.
https://www.consoletuner.com/wiki/index ... t2:key_set
ConsoleTuner Support Team || ConsoleTuner Discord || InputSense Discord
- Mad
- Major General
- Posts: 4536
- Joined: Wed May 22, 2019 5:39 am
Re: I got an interesting question here
hmm I tried to code what I think works but didn't work: Ill show what I got.
hmm i even tryed this didnt work
oh yea I forgot to say Im on pc using xbox controller trying to send a key function, by hitting button 6, which is RS click.
- Code: Select all
#include <keyboard.gph>
main {
//test
set_val(BUTTON_6, 0.0);
if(get_actual(BUTTON_6)) {
combo_run(test);
}
}
combo test{
static uint8 i;
const uint8 msg[] = {
KEY_A,
};
key_set(msg[i], TRUE);
wait(10);
key_set(msg[i], FALSE);
wait(100);
if(++i == sizeof(msg)) i = 0;
}
hmm i even tryed this didnt work
- Code: Select all
#include <keyboard.gph>
main {
if(event_active (BUTTON_6)) {
combo_run(HelloTitanTwo);}
}
combo HelloTitanTwo {
key_set(KEY_A, 100);
wait(500);
key_set(KEY_A, 0);
wait(500);
}
oh yea I forgot to say Im on pc using xbox controller trying to send a key function, by hitting button 6, which is RS click.
-
alencroat - Lieutenant
- Posts: 320
- Joined: Sun Oct 15, 2017 5:58 pm
Re: I got an interesting question here
I should have mentioned since it's outputting as a controller you'd need to switch the protocol to USB HID.
If timing is critical then this probably wont help. If timing doesn't matter it takes around one second to switch protocols.
https://www.consoletuner.com/wiki/index ... rt_connect
If timing is critical then this probably wont help. If timing doesn't matter it takes around one second to switch protocols.
https://www.consoletuner.com/wiki/index ... rt_connect
- Code: Select all
combo HelloTitanTwo {
port_connect(PORT_USB_C, PROTOCOL_HID);
wait(0);
wait(1000); // can adjust this based on how long it takes to connect
key_set(KEY_A, 100);
wait(500);
key_set(KEY_A, 0);
wait(500);
port_connect(PORT_USB_C, PROTOCOL_XB360);
}
ConsoleTuner Support Team || ConsoleTuner Discord || InputSense Discord
- Mad
- Major General
- Posts: 4536
- Joined: Wed May 22, 2019 5:39 am
Re: I got an interesting question here
ok ty sir I will try this
EDIT: yea works pretty good too bad it takes a bit to connect. Thank you
EDIT: yea works pretty good too bad it takes a bit to connect. Thank you
-
alencroat - Lieutenant
- Posts: 320
- Joined: Sun Oct 15, 2017 5:58 pm
5 posts
• Page 1 of 1
Return to GPC2 Script Programming
Who is online
Users browsing this forum: No registered users and 123 guests