Home AMX User Forum AMX Technical Discussion

biamp audia

i have this biamp audia and need to do a program. i have 8 input and 3 output.

i am done doing my program but i miss some important code but hard to create logic.

1st the volume level in biamp didnt match in the volume bar of my Touch panel.

2nd if i select input 1 going to output 1, then again select input 2 going to same output 1. i want to mute the crosspoint of the 1st selection i made so the sound will not coincide in the latest selection i made. this is the sample of my code


BUTTON_EVENT [dvTP,11] // DJ 1 Ground
{
PUSH:
{
[dvTP,11] = ![dvTP,11]
{
IF (![dvTP,11])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 7 1 0',$0A"
nSel_Ground = 11

}
IF ([dvTP,11])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 7 1 1',$0A"

}
}
}
}

BUTTON_EVENT [dvTP,12] // DJ 1 1st Flr
{
PUSH:
{
[dvTP,12] = ![dvTP,12]
{
IF (![dvTP,12])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 7 2 0',$0A"
nSel_1st = 12
}
IF ([dvTP,12])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 7 2 1',$0A"
}
}
}
}


BUTTON_EVENT [dvTP,13] // DJ 1 Outside.
{
PUSH:
{
[dvTP,13] = ![dvTP,13]
{
IF (![dvTP,13])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 7 3 0',$0A"
nSel_Outside = 13
}
IF ([dvTP,13])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 7 3 1',$0A"
}
}
}
}

// Volume UP & Down

BUTTON_EVENT [dvTP,14]
BUTTON_EVENT [dvTP,16]
{
PUSH:
{
SWITCH (BUTTON.INPUT.CHANNEL)
{
CASE 14:
{
IF (sVolLevel1<nVolMax1-nVolChange1)
{
SEND_STRING dvbiamp, "'INC 1 FDRLVL 18 7 1',$0A"
sVolLevel1 = sVolLevel1+nVolChange1
}
ELSE
sVolLevel1 = nVolMax1
}
CASE 16:
{
IF (sVolLevel1>nVolMin1+nVolChange1)
{
SEND_STRING dvbiamp, "'DEC 1 FDRLVL 18 7 1',$0A"
sVolLevel1 = sVolLevel1-nVolChange1
}
ELSE
sVolLevel1 = nVolMin1
}
}
}
HOLD [1,REPEAT]:
{
SWITCH (BUTTON.INPUT.CHANNEL)
{
CASE 14:
{
IF (sVolLevel1<nVolMax1-nVolChange1)
{
SEND_STRING dvbiamp, "'INC 1 FDRLVL 18 7 1',$0A"
sVolLevel1 = sVolLevel1+nVolChange1
}
ELSE
sVolLevel1 = nVolMax1
}
CASE 16:
{
IF (sVolLevel1>nVolMin1+nVolChange1)
{
SEND_STRING dvbiamp, "'DEC 1 FDRLVL 18 7 1',$0A"
sVolLevel1 = sVolLevel1-nVolChange1
}
ELSE
sVolLevel1 = nVolMin1
}
}
}
}

//Bar Level
LEVEL_EVENT[dvTP,1]
{
SEND_LEVEL dvTP,1,((sVolLevel1-nVolMin1) *255/(nVolMax1-nVolMin1))
}

//Mute
BUTTON_EVENT [dvTP,15]
{
PUSH:
{
[dvTP,15] = ![dvTP,15]
IF (![dvTP,15])
{
SEND_STRING dvbiamp, "'SET 1 FDRMUTE 18 7 0',$0A"
}
IF ([dvTP,15])
{
SEND_STRING dvbiamp, "'SET 1 FDRMUTE 18 7 1',$0A"
}
}
}





(**********************DJ 1st Flr.**************************************)

BUTTON_EVENT [dvTP,17] // DJ 2 Ground
{
PUSH:
{
[dvTP,17] = ![dvTP,17]
{
IF (![dvTP,17])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 8 1 0',$0A"
nSel_Ground = 17

}
IF ([dvTP,17])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 8 1 1',$0A"


}
}
}
}



BUTTON_EVENT [dvTP,18] // DJ 2 1st Flr.
{
PUSH:
{
[dvTP,18] = ![dvTP,18]
{
IF (![dvTP,18])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 8 2 0',$0A"
nSel_1st = 18
}
IF ([dvTP,18])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 8 2 1',$0A"
}
}
}
}


BUTTON_EVENT [dvTP,19] // DJ 2 Outside.
{
PUSH:
{
[dvTP,19] = ![dvTP,19]
{
IF (![dvTP,19])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 8 3 0',$0A"
nSel_Outside = 19
}
IF ([dvTP,19])
{
SEND_STRING dvbiamp, "'SET 1 MMMUTEXP 23 8 3 1',$0A"

}
}
}
}


// Volume UP & Down

BUTTON_EVENT [dvTP,20]
BUTTON_EVENT [dvTP,22]
{
PUSH:
{
SWITCH (BUTTON.INPUT.CHANNEL)
{
CASE 20:
{
IF (sVolLevel2<nVolMax2-nVolChange2)
{
SEND_STRING dvbiamp, "'INC 1 FDRLVL 18 8 1',$0A"
sVolLevel2 = sVolLevel2+nVolChange2
}
ELSE
sVolLevel2 = nVolMax2
}
CASE 22:
{
IF (sVolLevel2>nVolMin2+nVolChange2)
{
SEND_STRING dvbiamp, "'DEC 1 FDRLVL 18 8 1',$0A"
sVolLevel2 = sVolLevel2-nVolChange2
}
ELSE
sVolLevel2 = nVolMin2
}
}
}
HOLD [1,REPEAT]:
{
SWITCH (BUTTON.INPUT.CHANNEL)
{
CASE 20:
{
IF (sVolLevel2<nVolMax2-nVolChange2)
{
SEND_STRING dvbiamp, "'INC 1 FDRLVL 18 8 1',$0A"
sVolLevel2 = sVolLevel2+nVolChange2
}
ELSE
sVolLevel2 = nVolMax2
}
CASE 22:
{
IF (sVolLevel2>nVolMin2+nVolChange2)
{
SEND_STRING dvbiamp, "'DEC 1 FDRLVL 18 8 1',$0A"
sVolLevel2 = sVolLevel2-nVolChange2
}
ELSE
sVolLevel2 = nVolMin2
}
}
}
}

//Bar Level
LEVEL_EVENT[dvTP,2]
{
SEND_LEVEL dvTP,2,((sVolLevel2-nVolMin2) *255/(nVolMax2-nVolMin2))
}

//Mute
BUTTON_EVENT [dvTP,21]
{
PUSH:
{
[dvTP,21] = ![dvTP,21]
IF (![dvTP,21])
{
SEND_STRING dvbiamp, "'SET 1 FDRMUTE 18 8 0',$0A"
}
IF ([dvTP,21])
{
SEND_STRING dvbiamp, "'SET 1 FDRMUTE 18 8 1',$0A"
}
}
}

Comments

  • rfletcherrfletcher Posts: 217
    Jubal wrote: »
    i have this biamp audia and need to do a program. i have 8 input and 3 output.

    i am done doing my program but i miss some important code but hard to create logic.

    1st the volume level in biamp didnt match in the volume bar of my Touch panel.

    See comment below quoted code segment
    Jubal wrote: »
    2nd if i select input 1 going to output 1, then again select input 2 going to same output 1. i want to mute the crosspoint of the 1st selection i made so the sound will not coincide in the latest selection i made. this is the sample of my code

    Assuming you can edit the audia config file, you are better off putting a router block in front of the matrix mixer block and doing your source selection there, as router blocks only allow one source to be routed to each output at a time. It will do what you want automatically.
    Jubal wrote: »
    //Bar Level
    LEVEL_EVENT[dvTP,1]
    {
    SEND_LEVEL dvTP,1,((sVolLevel1-nVolMin1) *255/(nVolMax1-nVolMin1))
    }

    I see nothing in your code that will actually trigger this level event to occur. The line you have in this level event should probably be in the push and hold sections of your volume button events somewhere.

    Hope that was helpful
    -Ryan
  • AMXJeffAMXJeff Posts: 450
    I know this is obvious, but you could always use the Module? You just assign the "addresses" and object types to virtual devices using 'AUDIOPROCADD-' and the UI code is quite simple.
    DEFINE_DEVICE
    
    dvBiamp = 5001:1:0
    vdvBiamp = 41001:1:0;
    
    vdvBiampFader = 41001:2:0; // ADDRESS 1.18.8.0
    
    dvTP = 10001:1:0
    
    DEFINE_CONSTANT
    
    VOLUME_UP 	= 24;
    VOLUME_DN 	= 25;
    VOLUME_MT = 26;
    VOLUME_MT_FB  = 199;
    
    DEFINE_START
    
    // comm module
    DEFINE_MODULE 'Biamp_AudiaFlex_Comm_dr1_0_0' modBiampComm1(vdvBiamp,dvBiamp);
    
    DEFINE_EVENT
    
    DATA_EVENT[vdvBiamp]
    {
    	ONLINE:
    	{
    		SEND_COMMAND vdvBiamp,'PROPERTY-Baud_Rate,38400'
    		
    		// ASSIGNS FADER TO "vdvBiampFader"
    		SEND_COMMAND vdvBiamp,"'AUDIOPROCADD-',ITOA(vdvBiampFader.PORT),',LEVELFADERS.FADER.SET:1.18.8.0'";
    		
    		SEND_COMMAND vdvBiamp,'REINIT'
    	}
    }
    
    BUTTON_EVENT[dvTP,20] // FADER 1.18.8.0 RAISE
    {
    	PUSH:
    	{
    		TO[vdvBiampFader,VOLUME_UP]
    		TO[BUTTON.INPUT];
    	}
    }
    
    BUTTON_EVENT[dvTP,22] // FADER 1.18.8.0 LOWER
    {
    	PUSH:
    	{
    		TO[vdvBiampFader,VOLUME_DN]
    		TO[BUTTON.INPUT];
    	}
    }
    
    BUTTON_EVENT[dvTP,21] // FADER 1.18.8.0 MUTE
    {
    	PUSH:
    	{
    		TO[vdvBiampFader,VOLUME_MT];
    	}
    }
    
    // FADER LEVEL
    LEVEL_EVENT[vdvBiampFader, 1]
    {
    	SEND_LEVEL dvTP,2,LEVEL.VALUE
    }
    
    DEFINE_PROGRAM
    
    [dvTP,21] = [vdvBiampFader, VOLUME_MT_FB];
    
    
  • JubalJubal Posts: 77
    where can i see the module?? it's auto assign?
  • AMXJeffAMXJeff Posts: 450
    Jubal wrote: »
    where can i see the module?? it's auto assign?

    Physically? Download from AMX...

    In the code? see the "define_module" statement
  • JubalJubal Posts: 77
    AMXJeff wrote: »
    Physically? Download from AMX...

    In the code? see the "define_module" statement

    Its really frustrating now as i can't make it to work. any sample code that you can share for me?
  • jjamesjjames Posts: 2,908
    Look a few posts up, Jeff posted some code.

    Are you, or do you work for an AMX dealer? If so, this might be an excellent opportunity to take some more training.

    Also, may I make a public declaration that Pastebin (http://pastebin.com/) should be used from now on for large chunks of code?
  • rfletcherrfletcher Posts: 217
    jjames wrote: »
    Also, may I make a public declaration that Pastebin (http://pastebin.com/) should be used form now on for large chunks of code?

    Do pastebin posts expire and get deleted eventually? I couldn't find any answer to that in their faq.

    -Ryan
  • jjamesjjames Posts: 2,908
    Not entirely sure, but when pasting there is an selection for expiration, and by default it is 'Never'. I just assumed 'Never' meant never, but don't know for sure.

    Of course, this is as much a suggestion as are STOP signs, and budgets.
  • rfletcherrfletcher Posts: 217
    jjames wrote: »
    Of course, this is as much a suggestion as are STOP signs, and budgets.

    LOL, thanks I needed some humor today :D

    Given that it's just text, if they say never they probably mean it. So they should stay up till they go out of business or get bought out at least.
  • jjamesjjames Posts: 2,908
    That's kind of what I'm thinking too. I'm currently writing (err . . . attempting at least) a NetLinx GeSHi language file to submit to them. It'd be nice to have (most) syntax highlighting for the pastes. Variable highlighting will be a problem I think.
  • Without looking at the Audia file, it's hard to know if what you're sending is correct, but the format looks good.

    Are you monitoring responses from the Audia? If not, try creating a buffer (large as some strings get long) and watching what comes back. It will reply with '+OK' as an acknowledgement, or '-ERR' followed by some description of the error if it doesn't like a command.

    Also, are you controlling it via serial or IP? If I'm going to be sending alot of strings in a short time, I use a queue regardless of communication method, and wait for a reply before sending the next command.
  • Audia Control

    You have to match your levels on the Audia with the min. and max. of your bargraph on the touchpanel. Your values will vary depending on the levels on the Audia design. There is a table under Help menu of the Audia software that shows what values corresponds to what dB level.
    Hope this helps...
  • JubalJubal Posts: 77
    You have to match your levels on the Audia with the min. and max. of your bargraph on the touchpanel. Your values will vary depending on the levels on the Audia design. There is a table under Help menu of the Audia software that shows what values corresponds to what dB level.
    Hope this helps...

    So at this command where can i put the GETL command of biamp?

    BUTTON_EVENT [dvTP,20]
    BUTTON_EVENT [dvTP,22]
    {
    PUSH:
    {
    SWITCH (BUTTON.INPUT.CHANNEL)
    {
    CASE 20:
    {
    IF (sVolLevel2<nVolMax2-nVolChange2)
    {
    SEND_STRING dvbiamp, "'INC 1 FDRLVL 18 8 1',$0A"
    sVolLevel2 = sVolLevel2+nVolChange2
    }
    ELSE
    sVolLevel2 = nVolMax2
    }
    CASE 22:
    {
    IF (sVolLevel2>nVolMin2+nVolChange2)
    {
    SEND_STRING dvbiamp, "'DEC 1 FDRLVL 18 8 1',$0A"
    sVolLevel2 = sVolLevel2-nVolChange2
    }
    ELSE
    sVolLevel2 = nVolMin2
    }
    }
    }
    HOLD [1,REPEAT]:
    {
    SWITCH (BUTTON.INPUT.CHANNEL)
    {
    CASE 20:
    {
    IF (sVolLevel2<nVolMax2-nVolChange2)
    {
    SEND_STRING dvbiamp, "'INC 1 FDRLVL 18 8 1',$0A"
    sVolLevel2 = sVolLevel2+nVolChange2
    }
    ELSE
    sVolLevel2 = nVolMax2
    }
    CASE 22:
    {
    IF (sVolLevel2>nVolMin2+nVolChange2)
    {
    SEND_STRING dvbiamp, "'DEC 1 FDRLVL 18 8 1',$0A"
    sVolLevel2 = sVolLevel2-nVolChange2
    }
    ELSE
    sVolLevel2 = nVolMin2
    }
    }
    }
    }


    so the level bar of my touch panel sync. in my biamp volume? is my code correct?
Sign In or Register to comment.