3 button Pause Disable
-
Hi all i created my modified sega 3 button / GENESIS controller
it works great i even added a select button!Problem is every time press more than 3 buttons at same time it pauses , i have looked everywhere and i cant seeem to find anythign where i can edit this
thank you in advance
its driving me crazy :) -
@mrpromo need more info ob how you created this controller. And what emulator.
-
Created with Teensy LC works perfect apart from 3 button press simulates start
using all emulators this happens ,
the project
I added a micro switch to the back of the pad to use as select
Change pin numbers as needed
// player 1 bank
const int P1_A = 4;
const int P1_B = 5;
const int P1_C = 6;
const int P1_LEFT = 2;
const int P1_RIGHT = 1;
const int P1_DOWN = 9;
const int P1_UP = 8;
const int P1_SELECT = 10;
const int START_BUTTON = 7;
unsigned long lastTime = 0;
void setup()
{
pinMode(P1_A, INPUT_PULLUP);
pinMode(P1_B, INPUT_PULLUP);
pinMode(P1_C, INPUT_PULLUP);
pinMode(P1_LEFT, INPUT_PULLUP);
pinMode(P1_RIGHT, INPUT_PULLUP);
pinMode(P1_DOWN, INPUT_PULLUP);
pinMode(P1_UP, INPUT_PULLUP);
pinMode(START_BUTTON, INPUT_PULLUP);
pinMode(P1_SELECT, INPUT_PULLUP);lastTime = millis();
}
void loop()
{
unsigned long time = millis();
// run at 50 Hz
if(time - lastTime >= 20)
{
lastTime = time;
// read the data of all our buttons
// our buttons
Joystick.button(1, 1 - digitalRead(P1_A));
Joystick.button(2, 1 - digitalRead(P1_B));
Joystick.button(3, 1 - digitalRead(P1_C));
Joystick.button(4, 1 - digitalRead(START_BUTTON));
Joystick.button(9, 1 - digitalRead(P1_SELECT ));// also use buttons for the axes cuz unity is a derp Joystick.button(5, 1 - digitalRead(P1_UP)); Joystick.button(6, 1 - digitalRead(P1_RIGHT)); Joystick.button(7, 1 - digitalRead(P1_DOWN)); Joystick.button(8, 1 - digitalRead(P1_LEFT));
}
}
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.