GPC Library

TURBO - AUTO TURBO - HOLD - INACTIVE for ALL BUTTONS

Features:
1. "Turbo Toggle" which cycles between { TURBO | AUTO-TURBO | HOLD | INACTIVE }
Each individual button will always be in 1 of 4 states: Inactive (default), Turbo (rapid inputs when held),
Auto-Turbo (rapid inputs indefinitely), Hold (input remains held indefinitely).

2. "Adaptable turbo speed" + save feature
The ability to change the turbo speed. Each input had its own unique speed and you can save this speed to Eprom memory.
Version 1
Author Excalibur
Publish Date 2017-12-19 12:12:11
Update Date 2017-12-19 12:12:11
Downloads 434
RATE


2

0

Release Notes: new release
Code:Select all

/*******************************************************************
  TURBO - AUTO TURBO - HOLD - INACTIVE for ALL BUTTONS 

  Author   : Excalibur
  Console  : Multy ( will work on any console with any controller )
  
  Features:
  ***************************************************************************************************************************
	1. "Turbo Toggle" which cycles between { TURBO | AUTO-TURBO | HOLD | INACTIVE }
	Each individual button will always be in 1 of 4 states: Inactive (default), Turbo (rapid inputs when held), 
	Auto-Turbo (rapid inputs indefinitely), Hold (input remains held indefinitely).
	
	2. "Adaptable turbo speed" + save feature
	The ability to change the turbo speed. Each input had its own unique speed and you can save this speed to Eprom memory.
  ****************************************************************************************************************************
  
  INSTRUCTIONS :
  ----------------------------------
 I. ON/OFF turbo mode : hold PS4_SHARE ( XB1_VIEW ) + press button : will cycle between : TURBO / AUTO TURBO / HOLD / INACTIVE
  ----------------------------------
  
 II. TURBO mode change the speed
 ======================================================================================
	  hold PS4_SHARE( XB1_VIEW ) and press PS4_OPTIONS (XB1_MENU ) will turn menu ON / OFF
	  led color white
	  ----------------------------------
	  when you are in menu :
	  
	  Increase speed hold PS4_OPTIONS( XB1_MENU ) + button
	
	  Decrease speed hold PS4_SHARE (XB1_VIEW ) + button
	  ----------------------------------
	
	  III. SAVE speed to the EEPROM memory
	  ----------------------------------
	   when you are in menu :
	  
	   press PS4_PS ( XB1_XBOX )
   
 ====================================================================================== 
--------------------------------------
*********************************************************************/
//-------------------------------------
// BUTTON DEFINITION
//-------------------------------------
define btn3    =3;// R1
define btn4    =4;// R2
define btn5    =5;// R3
define btn6    =6;// L1
define btn7    =7;// L2
define btn8    =8;// L3
define btn17   =17;// TRIANGLE
define btn18   =18;// CIRCLE
define btn19   =19;// CROSS
define btn20   =20;// SQUARE
define btn13   =13;// Up
define btn14   =14;// Down
define btn15   =15;// Left
define btn16   =16;// Right
define btn27   =27;// TOUCH

int rest  = 20;
int btn[15];
int hold[15];
int state[15];
int index;
int menu_onoff; 
// INITIALIZATION
//-----------------------------------------
init { 
 
 	btn[0]   = 3;
 	btn[1]   = 4;
 	btn[2]   = 5;
 	btn[3]   = 6;
 	btn[4]   = 7;
 	btn[5]   = 8;
 	btn[6]   = 17;
 	btn[7]   = 18;
 	btn[8]   = 19;
 	btn[9]   = 20;
 	btn[10]  = 13;
 	btn[11]  = 14;
 	btn[12]  = 15;
 	btn[13]  = 16;
 	btn[14]  = 27;
 	//--------------
 	
	state[0] = 0;
	state[1] = 0;
	state[2] = 0;
	state[3] = 0;
	state[4] = 0;
	state[5] = 0;
	state[6] = 0;
	state[7] = 0;
	state[8] = 0;
	state[9] = 0;
	state[10]= 0;
	state[11]= 0;
	state[12]= 0;
	state[13]= 0;
	state[14]= 0;
	//--------------
	hold[0]  =  get_pvar(SPVAR_1, 0,600,40);//  R1
	hold[1]  =  get_pvar(SPVAR_2, 0,600,40);//  R2
	hold[2]  =  get_pvar(SPVAR_3, 0,600,40);//  R3
	hold[3]  =  get_pvar(SPVAR_4, 0,600,40);//  L1
	hold[4]  =  get_pvar(SPVAR_5, 0,600,40);//  L2
	hold[5]  =  get_pvar(SPVAR_6, 0,600,40);//  L3
	hold[6]  =  get_pvar(SPVAR_7, 0,600,40);//  TRIANGLE
	hold[7]  =  get_pvar(SPVAR_8, 0,600,40);//  CIRCLE
	hold[8]  =  get_pvar(SPVAR_9, 0,600,40);//  CROSS
	hold[9]  =  get_pvar(SPVAR_10,0,600,40);//  SQUARE
	hold[10] =  get_pvar(SPVAR_11,0,600,40);//  
	hold[11] =  get_pvar(SPVAR_12,0,600,40);//  
	hold[12] =  get_pvar(SPVAR_13,0,600,40);//  
	hold[13] =  get_pvar(SPVAR_14,0,600,40);// 
	
	hold[14] =  get_pvar(SPVAR_15,0,600,40);// TOUCH

}

// MAIN BLOCK
//-------------------------------------------
main {
  
  //------------------------------------------
  // MENU ON/OFF
  if(get_val(PS4_SHARE) && event_press(PS4_OPTIONS) ){
		menu_onoff  = !menu_onoff;  	
  }
 
  

///////////////////////////////////////
// TURBO mode change the speed
//////////////////////////////////////

  if(menu_onoff){
      set_led(LED_3,1);
	  /////////////////////////////////
	  // Increase speed D pad UP + button
	  //-------------------------------------------------
	   if(get_val(PS4_OPTIONS)){
	       index += 1;
	       if(index > 14) index = 0;
	       if(get_val(btn[index])) {
	          hold[index] -=  1;
	          if(hold[index]< rest) hold[index] = rest;    
	       }
	   }
	   //------------------------------------------------
	
	
	  /////////////////////////////////
	  // Decrease speed D pad DOWN + button
	  //-------------------------------------------------
	   if(get_val(PS4_SHARE)){
	      index += 1;
	      if(index > 14) index = 0;   
	      if(get_val(btn[index])) {
	         hold[index] += 1;
	      }
	   }
	   //------------------------------------------------
	   
	   
		//////////////////////////////////////////////
		//  SAVE speed to the EEPROM memory
		//////////////////////////////////////////////	
		if(event_press(PS4_PS)){
		     set_pvar(SPVAR_1, hold[0]);//  R1
	         set_pvar(SPVAR_2, hold[1]);//  R2
	         set_pvar(SPVAR_3, hold[2]);//  R3
	         set_pvar(SPVAR_4, hold[3]);//  L1
	         set_pvar(SPVAR_5, hold[4]);//  L2
	         set_pvar(SPVAR_6, hold[5]);//  L3
	         set_pvar(SPVAR_7, hold[6]);//  TRIANGLE
	         set_pvar(SPVAR_8, hold[7]);//  CIRCLE
	         set_pvar(SPVAR_9, hold[8]);//  CROSS
	         set_pvar(SPVAR_10,hold[9]);//  SQUARE
	         set_pvar(SPVAR_11,hold[10]);//
	         set_pvar(SPVAR_12,hold[11]);//
	         set_pvar(SPVAR_13,hold[12]);//
	         set_pvar(SPVAR_14,hold[13]);//
	         set_pvar(SPVAR_15,hold[14]);// TOUCH
         }
         
         set_val(PS4_PS,0);
         set_val(PS4_SHARE,0);
         set_val(PS4_OPTIONS,0);
	}else{
		set_led(LED_4,1);
		set_led(LED_3,0);
		// 0 INACTIVE | 1 TURBO |2 AUTO-TURBO |3 HOLD
		/////////////////////////////////
		// ON/OFF turbo mode  hold SELECT + press button to ON/OFF turbo
		//-------------------------------------------------
		if(get_val(PS4_SHARE)){
		  if(event_press(btn3)) set_state (0);// R1
		  if(event_press(btn4)) set_state (1);// R2
		  if(event_press(btn5)) set_state (2);// R3
		  if(event_press(btn6)) set_state (3);// L1
		  if(event_press(btn7)) set_state (4);// L2
		  if(event_press(btn8)) set_state (5);// L3
		
		
		  if(event_press(btn17)) set_state (6);// TRIANGLE
		  if(event_press(btn18)) set_state (7);// CIRCLE
		  if(event_press(btn19)) set_state (8);// CROSS
		  if(event_press(btn20)) set_state (9);// SQUARE
		  
		  if(event_press(btn13)) set_state (10);// Up
		  if(event_press(btn14)) set_state (11);// Down
		  if(event_press(btn15)) set_state (12);// Left
		  if(event_press(btn16)) set_state (13);// Right
		  
		  if(event_press(btn27)) set_state (14);// TOUCH
		}
		//------------------------------------------------
	}



   


//////////////////////////////////////////////

    //index=0;
///////////////////////////////////////
// TURBO MODE ON
///////////////////////////////////////

     //-------------------------------------------
     if(state[0]){// R1
     	 
         if( state[0] == 1) {
         	if(get_val(btn3)) combo_run(TURBO3);
         }else if( state[0] == 2){
         	combo_run(TURBO3);// R1
         }else if(state[0] == 3){
         	set_val(btn3,100);
         }
     }
     //-------------------------------------------
     if(state[1]){// R2
         
         if( state[1] == 1) {
         	if(get_val(btn4)) combo_run(TURBO4);
         }else if( state[1] == 2){
         	combo_run(TURBO4);// R2
         }else if(state[1] == 3){
         	set_val(btn4,100);
         }
     }
     //-------------------------------------------
     if(state[2]){// R3
         
         if( state[2] == 1) {
         	if(get_val(btn5)) combo_run(TURBO5);
         }else if( state[2] == 2){
         	combo_run(TURBO5);// R2
         }else if(state[2] == 3){
         	set_val(btn5,100);
         }
     }
     //-------------------------------------------
     if(state[3]){// L1
         
         if( state[3] == 1) {
         	if(get_val(btn6)) combo_run(TURBO6);
         }else if( state[3] == 2){
         	combo_run(TURBO6);// L1
         }else if(state[3] == 3){
         	set_val(btn6,100);
         }
     }
     //-------------------------------------------
     if(state[4]){// L2
         
         if( state[4] == 1) {
         	if(get_val(btn7)) combo_run(TURBO7);
         }else if( state[4] == 2){
         	combo_run(TURBO7);// L2
         }else if(state[4] == 3){
         	set_val(btn7,100);
         }
     }
     //-------------------------------------------
     if(state[5]){// L3
         
         if( state[5] == 1) {
         	if(get_val(btn8)) combo_run(TURBO8);
         }else if( state[5] == 2){
         	combo_run(TURBO8);// L3
         }else if(state[5] == 3){
         	set_val(btn8,100);
         }
     }
     //-------------------------------------------
     if(state[6]){// TRIANGLE
         
         if( state[6] == 1) {
         	if(get_val(btn17)) combo_run(TURBO17);
         }else if( state[6] == 2){
         	combo_run(TURBO17);// TRIANGLE
         }else if(state[6] == 3){
         	set_val(btn17,100);
         }
     }
     //-------------------------------------------
     if(state[7]){// CIRCLE
         
         if( state[7] == 1) {
         	if(get_val(btn18)) combo_run(TURBO18);
         }else if( state[7] == 2){
         	combo_run(TURBO18);// CIRCLE
         }else if(state[7] == 3){
         	set_val(btn18,100);
         }// 
     }
     //-------------------------------------------
     if(state[8]){// CROSS
         
         if( state[8] == 1) {
         	if(get_val(btn19)) combo_run(TURBO19);
         }else if( state[8] == 2){
         	combo_run(TURBO19);// CROSS
         }else if(state[8] == 3){
         	set_val(btn19,100);
         }// 
     }
	 //-------------------------------------------
     if(state[9]){// SQUARE
         if( state[9] == 1) {
         	if(get_val(btn20)) combo_run(TURBO20);
         }else if( state[9] == 2){
         	combo_run(TURBO20);// SQUARE
         }else if(state[9] == 3){
         	set_val(btn20,100);
         }// 
     }
     
     //-------------------------------------------
     if(state[10]){// Up
         if( state[10] == 1) {
         	if(get_val(btn13)) combo_run(TURBO13);
         }else if( state[10] == 2){
         	combo_run(TURBO13);// SQUARE
         }else if(state[10] == 3){
         	set_val(btn13,100);
         }// 
     }
     
     //-------------------------------------------
     if(state[11]){// Down
         if( state[11] == 1) {
         	if(get_val(btn14)) combo_run(TURBO14);
         }else if( state[11] == 2){
         	combo_run(TURBO14);// SQUARE
         }else if(state[11] == 3){
         	set_val(btn14,100);
         }// 
     }
     
     //-------------------------------------------
     if(state[12]){// Left
         if( state[12] == 1) {
         	if(get_val(btn15)) combo_run(TURBO15);
         }else if( state[12] == 2){
         	combo_run(TURBO15);// SQUARE
         }else if(state[12] == 3){
         	set_val(btn15,100);
         }// 
     }
     
     //-------------------------------------------
     if(state[13]){// Right
         if( state[13] == 1) {
         	if(get_val(btn16)) combo_run(TURBO16);
         }else if( state[13] == 2){
         	combo_run(TURBO16);// SQUARE
         }else if(state[13] == 3){
         	set_val(btn16,100);
         }// 
     }
     
     //-------------------------------------------
     if(state[14]){// TOUCH
         if( state[14] == 1) {
         	if(get_val(btn27)) combo_run(TURBO27);
         }else if( state[14] == 2){
         	combo_run(TURBO27);// SQUARE
         }else if(state[14] == 3){
         	set_val(btn27,100);
         }// 
     }


}

combo TURBO3  {//  R1
   set_val(btn3,100);
   wait(hold[0]);
   set_val(btn3,0);
   wait(hold[0] - rest);

}
combo TURBO4  {// R2
   set_val(btn4,100);
   wait(hold[1]);
   set_val(btn4,0);
   wait(hold[1] - rest);
}
combo TURBO5  {// R3
   set_val(btn5,100);
   wait(hold[2]);
   set_val(btn5,0);
   wait(hold[2] - rest);
}
combo TURBO6  {// L1
   set_val(btn6,100);
   wait(hold[3]);
   set_val(btn6,0);
   wait(hold[3] - rest);
}
combo TURBO7  {// L2
   set_val(btn7,100);
   wait(hold[4]);
   set_val(btn7,0);
   wait(hold[4] - rest);
}
combo TURBO8  {// L3
   set_val(btn8,100);
   wait(hold[5]);
   set_val(btn8,0);
   wait(hold[5] - rest);
}

combo TURBO17  {// TRIANGLE
   set_val(btn17,100);
   wait(hold[6]);
   set_val(btn17,0);
   wait(hold[6] - rest);
}
combo TURBO18  {// CIRCLE
   set_val(btn18,100);
   wait(hold[7]);
   set_val(btn18,0);
   wait(hold[7] - rest);
}
combo TURBO19  {// CROSS
   set_val(btn19,100);
   wait(hold[8]);
   set_val(btn19,0);
   wait(hold[8] - rest);
}
combo TURBO20  {// SQUARE
   set_val(btn20,100);
   wait(hold[9]);
   set_val(btn20,0);
   wait(hold[9] - rest);
}

combo TURBO13  {// Up
   set_val(btn13,100);
   wait(hold[10]);
   set_val(btn13,0);
   wait(hold[10] - rest);
}

combo TURBO14  {// Down
   
   set_val(btn14,100);
   wait(hold[11]);
   set_val(btn14,0);
   wait(hold[11] - rest);
}
combo TURBO15  {// Left
   set_val(btn15,100);
   wait(hold[12]);
   set_val(btn15,0);
   wait(hold[12] - rest);
}
combo TURBO16  {// Right
   set_val(btn16,100);
   wait(hold[13]);
   set_val(btn16,0);
   wait(hold[13] - rest);
}

combo TURBO27  {// TOUCH
   set_val(btn27,100);
   wait(hold[14]);
   set_val(btn27,0);
   wait(hold[14] - rest);
}


// 0 INACTIVE | 1 TURBO |2 AUTO-TURBO |3 HOLD
function set_state ( ind ) {

	if( state[ ind ] == 0) state[ind] = 1;// turbo
	else if( state[ ind ] == 1) state[ind] = 2;// auto turbo
	else if( state[ ind ] == 2) state[ind] = 3;// hold
	else if( state[ ind ] == 3) state[ind] = 0;// inactive
}


  • Rating

    10 / 10 here !

    If you own a ps3 and prefer an xbox controller, or even use a keyboard and mouse, this is a must to remap your keyboard to a controller. Go buy it now you won't be disappointed !

  • Rating

    Amazing device

    If you're like me and love your PS4 controller but want to use an Xbox One GET THIS you won't be sorry.

  • Rating

    Worth every penny

    The controller feels and performs as it does on the xbox right there on my ps3, awesome job guys, and worth every penny !!!

  • Rating

    Amazing Macro combos

    tested Super Street Fighter IV Arcade Edition. I was able to perform normal & FADC combos with some characters like Ryu and Ken with a single click. Amazing.

  • Rating

    As good as a XIM

    If you are a pc gamer, that needs a pc solution for console, get yourself a ControllerMAX you will not regret it.

  • Rating

    KB & Mouse RULES!

    All I can say playing 10 minutes with ControllerMAX properly configured it felt better then PC....YES I said it even better then PC, it's that smooth.

  • Rating

    Six-Axis 360!

    WOW! I can finally get that six-axis awesomeness on my Xbox 360. The best money I ever spent.

  • Rating

    Beats all rapidfire mods

    I've tried the Intensafire, Godfather even the new Wolf controller. The ControllerMAX beats them hands down and no wires or soldering too. 5 Stars!

  • Rating

    Just perfect!

    I can't believe how much this can do for the price tag - it blew me away. Best controller upgrade ever.

  • Rating

    Hugh Thanks!

    Without your help I couldn't be playing Xbox, thanks guys.

  • Rating

    Wow!

    I have to say after reading the forums for Destiny Mouse and Keyboard setup I was flying into getting it set up in 20 minutes. It works outstanding! I'm more then satisfied and its worth every penny!

  • Rating

    Achievement Unlocked!

    Idle boosting Complete 150 Multiplayer games, James Cameron's Avatar. My friend said it would be hard, I laughed then linked him.

  • Rating

    A++!

    Now this is a company you can count on and trust...keep up the great work guys!

  • Rating

    What Disability?

    I would like to thank you for making the CronusMax. I have this problem hitting L3 and R3, and today that problem was fixed. I love the remap feature on the Cronus max. You made my life easier.

  • Rating

    Awesome stuff guys!

    Playing Forza 5 with my original MS 360 wireless wheel makes the XB1 complete for me, thanks to the CronusMax. Thumbs up!