Home AMX User Forum NetLinx Studio

Biamp Room Combiner

i have a divisible 4 room layout (square layout). im trying to program the biamp DSP to combine and uncombine rooms using these command protocols that were given to me:

SET 1 RMCMBWALL 11 1 0 <LF> //combine 1&2

SET 1 RMCMBWALL 11 4 0 <LF> //combine 2&4

SET 1 RMCMBWALL 11 3 0 <LF> //combine 3&4

SET 1 RMCMBWALL 11 2 0 <LF> //combine 1&3

SET 1 RMCMBWALL 11 1 1 <LF> //separate 1&2

SET 1 RMCMBWALL 11 4 1 <LF> // separate 2&4

SET 1 RMCMBWALL 11 3 1 <LF> // separate 3&4

SET 1 RMCMBWALL 11 2 1 <LF> // separate 1&3

my client wants any way possible the rooms combined except diagonally. example: L shape rooms combined and side-by-side rooms combined.

i am making this simple by just using them in button_events.
//@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@__ROOM_COMBINE_MODES__@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
////////////////////////////////////ALL ROOMS SEPERATED//////////////////////////////////////
BUTTON_EVENT[dvTP_1189,29]
{
	PUSH:
	{
		SEND_STRING dvDSP,"'SET 1 RMCMBWALL 11 1 1',$0A"		//SEPARATE 1&2
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 1',$0A"		//SEPARATE 2&4
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 1',$0A"		//SEPARATE 3&4
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 1',$0A"		//SEPARATE 1&3
	}
}
////////////////////////////////////ALL ROOMS COMBINED//////////////////////////////////////
BUTTON_EVENT[dvTP_1189,30]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 1 0',$0A"		//COMBINE 1&2
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 0',$0A"		//COMBINE 2&4
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 0',$0A"		//COMBINE 3&4
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 0',$0A"		//COMBINE 1&3
	}
}
////////////////////////////////////////1189+1190///////////////////////////////////////////
BUTTON_EVENT[dvTP_1189,31]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 0',$0A"		//COMBINE 3&4
		SEND_STRING dvDSP,"'SET 1 RMCMBWALL 11 1 1',$0A"		//SEPARATE 1&2
	}
}
////////////////////////////////////////1187+1188///////////////////////////////////////////
BUTTON_EVENT[dvTP_1189,33]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 1 0',$0A"		//COMBINE 1&2
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 1',$0A"		//SEPARATE 3&4
	}
}
////////////////////////////////////////1187+1189///////////////////////////////////////////
BUTTON_EVENT[dvTP_1189,34]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 0',$0A"		//COMBINE 1&3
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 1',$0A"		//SEPARATE 2&4
	}
}
////////////////////////////////////////1188+1190///////////////////////////////////////////
BUTTON_EVENT[dvTP_1189,32]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 0',$0A"		//COMBINE 2&4
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 1',$0A"		//SEPARATE 1&3
	}
}
///////////////////////////////////1187+1189+1190///////////////////////////////////////////
BUTTON_EVENT[dvTP_1189,35]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 0',$0A"		//COMBINE 1&3
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 0',$0A"		//COMBINE 3&4
	}
}
///////////////////////////////////1187+1188+1189///////////////////////////////////////////
BUTTON_EVENT[dvTP_1189,36]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 1 0',$0A"		//COMBINE 1&2
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 0',$0A"		//COMBINE 1&3
	}
}
///////////////////////////////////1187+1188+1190///////////////////////////////////////////
BUTTON_EVENT[dvTP_1189,37]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 1 0',$0A"		//COMBINE 1&2
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 0',$0A"		//COMBINE 2&4
	}
}
///////////////////////////////////1188+1189+1190///////////////////////////////////////////
BUTTON_EVENT[dvTP_1189,38]
{
	PUSH:
	{
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 0',$0A"		//COMBINE 2&4
		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 0',$0A"		//COMBINE 3&4
	}
}

DATA_EVENT[dvDSP]
{
	ONLINE:
	{
		SEND_COMMAND data.device,"'SET BAUD 38400,N,8,1 485 disable'"
	}
	STRING:
	{
		WAIT 3 CLEAR_BUFFER cDSP_RESPONSE
	}
}


now i am only wondering if i typed in the command protocols correctly? the only buttons that worked are buttons 29 and 30.

Comments

  • kbeattyAMXkbeattyAMX Posts: 358
    I'm not too sure if the commands are correct but a way to limit problems like this is to reduce redundancy. Here's one way I tackled it.
    DEFINE_VARIABLE
    
    integer nChannelsused[] = {1,2,3,4}
    
    channel_event[dvDSP,nChannelsused]
    {
      on:
    	{
    	  send_string channel.device,"'SET 1 RMCMBWALL 11 ',itoa(channel.channel),' 1',$0A"
    	}
    	off:
    	{
    	  send_string channel.device,"'SET 1 RMCMBWALL 11 ',itoa(channel.channel),' 0',$0A"
    	}
    }
    
    

    In this way you greatly reduce the strings to the device. To operate it you just turn on [dvDSP,1] to uncombine rooms 1&2 and turn off [dvDSP,1] to combine 1&2. Now you just have 4 channels to deal with.
  • found out that i have to use all 4 commands if i wanted 2 rooms combined. ex:
    	PUSH:
    	{
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 1 0',$0A"		//COMBINE 1&2
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 1',$0A"		//SEPARATE 1&3
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 1',$0A"		//SEPARATE 3&4
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 1',$0A"		//SEPARATE 2&4
    	}
    
    

    or 3 rooms combined. ex:
    	PUSH:
    	{
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 1 0',$0A"		//COMBINE 1&2
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 0',$0A"		//COMBINE 1&3
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 1',$0A"		//SEPARATE 3&4
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 1',$0A"		//SEPARATE 2&4
    	}
    
    
  • kbeattyAMXkbeattyAMX Posts: 358
    playskool1 wrote: »
    found out that i have to use all 4 commands if i wanted 2 rooms combined. ex:
    	PUSH:
    	{
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 1 0',$0A"		//COMBINE 1&2
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 1',$0A"		//SEPARATE 1&3
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 1',$0A"		//SEPARATE 3&4
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 1',$0A"		//SEPARATE 2&4
    	}
    
    

    or 3 rooms combined. ex:
    	PUSH:
    	{
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 1 0',$0A"		//COMBINE 1&2
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 2 0',$0A"		//COMBINE 1&3
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 3 1',$0A"		//SEPARATE 3&4
    		SEND_STRING	dvDSP,"'SET 1 RMCMBWALL 11 4 1',$0A"		//SEPARATE 2&4
    	}
    
    


    Just do this....
    	PUSH:
    	{
    		OFF[dvDSP,1]
                    ON[dvDSP,2] //SEPARATE 1&3
                    ON[dvDSP,3] //SEPARATE 3&4
                    ON[dvDSP,4] //SEPARATE 2&4
    	}
    
    

    or 3 rooms combined. ex:
    	PUSH:
    	{
                    OFF[dvDSP,1] //COMBINE 1&2
                    OFF[dvDSP,2] //COMBINE 1&3
                    ON[dvDSP,3] //SEPARATE 3&4
                    ON[dvDSP,4] //SEPARATE 2&4
    	}
    
    

    In this way all of the strings to dvDSP are in the channel event. This makes it easier to modify if you need to make a change in the string.
  • kbeattyAMX - thank you for your help.
Sign In or Register to comment.