Home AMX User Forum AMX General Discussion

BIAMP TC

I get module from amx site for this biamp tc. but error always pop up saying:

ERROR: D:\AvTelco File\Jerico Files\PMO Project\AMX Program\BOARDROOM 40\REv\REV1\PMO_BOARDROOM.tko(0): L20206: File [Biamp Audia Flex, Preset UI.tko] could not be found

i didn't change anything yet but still there is error.
I can program the audio and router, fader volume etc.

But dial-er is new to me. i only need to program dial-er and can't get to work.

Comments

  • ericmedleyericmedley Posts: 4,177
    The error is telling you that the compiler is expecting to find the file Preset UI.tko in the path mentioned before.

    So, you either need to put the file in that directory or an easier thing to do is (if the file is already added to the project in the Modules tree) delete the old reference and re-import it to your project. This will refresh the compiler's link to that file.

    If you didn't import the modle file into the project, that's your problem and you simply need to import it and you will be good to go.
  • JubalJubal Posts: 77
    ericmedley wrote: »
    The error is telling you that the compiler is expecting to find the file Preset UI.tko in the path mentioned before.

    So, you either need to put the file in that directory or an easier thing to do is (if the file is already added to the project in the Modules tree) delete the old reference and re-import it to your project. This will refresh the compiler's link to that file.

    If you didn't import the modle file into the project, that's your problem and you simply need to import it and you will be good to go.




    I get this module in AMX website. and it's in zip file. didint change anything but still error. anyway i create my onw code to do the dial-er but i have issue in # button. i can get feed back. all number (0-9) and * are working but cannot get # to work. this is my code for this.

    CODE:
    //DIAL-ER
    CHAR LAST_NUMBER_PRESSED[1000]
    CHAR NUMBER[1000]
    INTEGER ON_NUMBER
    INTEGER LAST_BUTTON_PRESSED


    INTEGER TP_BUTTONS[]=
    {
    62, //0
    52, //1
    53, //2
    54, //3
    55, //4
    56, //5
    57, //6
    58, //7
    59, //8
    60, //9
    61, //*
    63 //#
    }


    TEXT_READOUT = 1


    BUTTON_EVENT[dvtp,TP_BUTTONS]
    {
    PUSH:
    {
    LAST_BUTTON_PRESSED = GET_LAST(TP_BUTTONS)
    PULSE[BUTTON.INPUT] //FEEDBACK FOR TOUCHPANEL
    SWITCH (LAST_BUTTON_PRESSED)
    {
    CASE 1: //0
    CASE 2: //1
    CASE 3: //2
    CASE 4: //3
    CASE 5: //4
    CASE 6: //5
    CASE 7: //6
    CASE 8: //7
    CASE 9: //8
    CASE 10: //9
    CASE 11: //*
    CASE 12: //#
    {
    LAST_NUMBER_PRESSED = ITOA(LAST_BUTTON_PRESSED-1)
    IF(LAST_BUTTON_PRESSED = 11 )
    {
    LAST_NUMBER_PRESSED = '*'
    }
    IF(LAST_BUTTON_PRESSED = 12)
    {
    LAST_NUMBER_PRESSED = '#'
    }
    ELSE
    {
    NUMBER="NUMBER,LAST_NUMBER_PRESSED"
    SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
    }
    }
    }
    }
    }


    # didn't go to my feedback box. it always appear as 11 when i debug it.
    Next issue happend is when i put this number to dial in biamp but didn't work too



    BUTTON_EVENT [dvtp,79]

    {
    PUSH:
    {
    PULSE[dvtp,79]
    SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104',NUMBER,$0A"
    }
    }
  • It looks like you are trying to stack cases in a switch case statement. That will not work. Each case must be handled individually.
  • JubalJubal Posts: 77
    Bigsquatch wrote: »
    It looks like you are trying to stack cases in a switch case statement. That will not work. Each case must be handled individually.


    how can i do that?
  • Bigsquatch wrote: »
    It looks like you are trying to stack cases in a switch case statement. That will not work. Each case must be handled individually.

    This is NOT correct. You can stack cases as in the example, and I have done it successfully.

    As to the OP's problem, I'm willing to bet that if you select 'build active system' from the build menu instead of just hitting F7, you will get a successful compile. This is because the workspace that you are opening that comes in the Biamp module zip file has the .AXS files linked instead of the .tko's. Compiling the active system will compile ALL source files that are in the system, starting with any module source files, then hitting the main source code file after that.

    Hope that helps.
  • HedbergHedberg Posts: 671
    This is NOT correct. You can stack cases as in the example, and I have done it successfully.

    As to the OP's problem, I'm willing to bet that if you select 'build active system' from the build menu instead of just hitting F7, you will get a successful compile. This is because the workspace that you are opening that comes in the Biamp module zip file has the .AXS files linked instead of the .tko's. Compiling the active system will compile ALL source files that are in the system, starting with any module source files, then hitting the main source code file after that.

    Hope that helps.

    Ok, so you can do this, but I don't see why you would want to -- particularly in the example given.

    Looking a little closer at the example:
    SWITCH (LAST_BUTTON_PRESSED)
    {
      CASE 1: //0
      CASE 2: //1
      CASE 3: //2
      CASE 4: //3
      CASE 5: //4
      CASE 6: //5
      CASE 7: //6
      CASE 8: //7
      CASE 9: //8
      CASE 10: //9
      CASE 11: //*
      CASE 12: //#
      {
        LAST_NUMBER_PRESSED = ITOA(LAST_BUTTON_PRESSED-1)
        IF(LAST_BUTTON_PRESSED = 11 )
        {
           LAST_NUMBER_PRESSED = '*'
        }
        IF(LAST_BUTTON_PRESSED = 12)
        {
           LAST_NUMBER_PRESSED = '#'
        }
        ELSE
        {
           NUMBER="NUMBER,LAST_NUMBER_PRESSED"
           SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
        }
      }
    }
    

    wouldn't it be better to replace the switch-case with a single IF?

    Also, it appears to me that these lines:

    {
    NUMBER="NUMBER,LAST_NUMBER_PRESSED"
    SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
    }

    will be executed when * is pressed but not when # is pressed. I doubt that is the intent.

    That is, probably the second if needs to be replaced with "else if".

    Wonderful hijack
  • JubalJubal Posts: 77
    Hedberg wrote: »
    Ok, so you can do this, but I don't see why you would want to -- particularly in the example given.

    Looking a little closer at the example:
    SWITCH (LAST_BUTTON_PRESSED)
    {
      CASE 1: //0
      CASE 2: //1
      CASE 3: //2
      CASE 4: //3
      CASE 5: //4
      CASE 6: //5
      CASE 7: //6
      CASE 8: //7
      CASE 9: //8
      CASE 10: //9
      CASE 11: //*
      CASE 12: //#
      {
        LAST_NUMBER_PRESSED = ITOA(LAST_BUTTON_PRESSED-1)
        IF(LAST_BUTTON_PRESSED = 11 )
        {
           LAST_NUMBER_PRESSED = '*'
        }
        IF(LAST_BUTTON_PRESSED = 12)
        {
           LAST_NUMBER_PRESSED = '#'
        }
        ELSE
        {
           NUMBER="NUMBER,LAST_NUMBER_PRESSED"
           SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
        }
      }
    }
    

    wouldn't it be better to replace the switch-case with a single IF?

    Also, it appears to me that these lines:

    {
    NUMBER="NUMBER,LAST_NUMBER_PRESSED"
    SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
    }

    will be executed when * is pressed but not when # is pressed. I doubt that is the intent.

    That is, probably the second if needs to be replaced with "else if".

    Wonderful hijack



    so you mean i only need to put ELSE IF instead of IF only?

    {
    LAST_NUMBER_PRESSED = ITOA(LAST_BUTTON_PRESSED-1)
    IF(LAST_BUTTON_PRESSED = 11 )
    {
    LAST_NUMBER_PRESSED = '*'
    }
    ELSE IF(LAST_BUTTON_PRESSED = 12)
    {
    LAST_NUMBER_PRESSED = '#'
    }
    ELSE
    {
    NUMBER="NUMBER,LAST_NUMBER_PRESSED"
    SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
    }
    }


    IS THIS RIGHT?
  • HedbergHedberg Posts: 671
    Jubal wrote: »
    I get this module in AMX website. and it's in zip file. didint change anything but still error. anyway i create my onw code to do the dial-er but i have issue in # button. i can get feed back. all number (0-9) and * are working but cannot get # to work. this is my code for this.

    I believe I have already answered this one -- you need a "else if" instead of an if. Maybe you've mixed up the # and the *, but I'm not sure.


    about the following:
    BUTTON_EVENT [dvtp,79]
    
    {
        PUSH:
        {
    	PULSE[dvtp,79]
    	SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104',NUMBER,$0A"
        }
    }
    

    you need a space between the instance number (104) and the phone number. either of these should work:

    SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104',$20,NUMBER,$0A"
    SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104 ',NUMBER,$0A"

    Use diagnostics to enable device notifications and the error should be as obvious as Joe Biden's fake teeth. Assuming that you are controlling the biamp by rs232.

    Good luck with it -- biamps are pretty easy to control once you figure out the instance number and the type of biamp object you are controlling. I've been told that the Biamp programmer can assign aliases so that you can use a name instead of an instance number but I've never been successful when trying to actually get that done. Say, levee.
  • JubalJubal Posts: 77
    Hedberg wrote: »
    I believe I have already answered this one -- you need a "else if" instead of an if. Maybe you've mixed up the # and the *, but I'm not sure.


    about the following:
    BUTTON_EVENT [dvtp,79]
    
    {
        PUSH:
        {
    	PULSE[dvtp,79]
    	SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104',NUMBER,$0A"
        }
    }
    

    you need a space between the instance number (104) and the phone number. either of these should work:

    SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104',$20,NUMBER,$0A"
    SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104 ',NUMBER,$0A"

    Use diagnostics to enable device notifications and the error should be as obvious as Joe Biden's fake teeth. Assuming that you are controlling the biamp by rs232.

    Good luck with it -- biamps are pretty easy to control once you figure out the instance number and the type of biamp object you are controlling. I've been told that the Biamp programmer can assign aliases so that you can use a name instead of an instance number but I've never been successful when trying to actually get that done. Say, levee.

    thanks will try it on sat. when i go back on site. this is the first time that i use dialer in biamp
  • Jubal wrote: »
    so you mean i only need to put ELSE IF instead of IF only?

    {
    LAST_NUMBER_PRESSED = ITOA(LAST_BUTTON_PRESSED-1)
    IF(LAST_BUTTON_PRESSED = 11 )
    {
    LAST_NUMBER_PRESSED = '*'
    }
    ELSE IF(LAST_BUTTON_PRESSED = 12)
    {
    LAST_NUMBER_PRESSED = '#'
    }
    ELSE
    {
    NUMBER="NUMBER,LAST_NUMBER_PRESSED"
    SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
    }
    }


    IS THIS RIGHT?

    I would probably do something like the following in this case:
    switch(LAST_NUMBER_PRESSED){
         switch(last_button_pressed){
    	case 11:{
    		LAST_NUMBER_PRESSED = '*'
    	}
    	case 12:{
    		LAST_NUMBER_PRESSED = '#'
    	}
    	default:{
    		LAST_NUMBER_PRESSED = itoa(LAST_BUTTON_PRESSED -1)
    	}
    }
    

    Or, doing it the way Hedberg is talking about:
    if(last_button_pressed < 11){
    LAST_NUMBER_PRESSED = itoa(LAST_BUTTON_PRESSED - 1)
    }
    else if(last_button_pressed == 11){
    LAST_NUMBER_PRESSED = '*'
    }
    else if(last_button_pressed == 12){
    LAST_NUMBER_PRESSED = '#'
    }

    either of which results in more readable code and less typing. You do have to be careful with the first example, as anything that doesn't match one of the explicit cases will match the default case. I believe what Hedberg means is getting rid of the switch..case statement all together and using the if..else construct.
  • HedbergHedberg Posts: 671
    Ok, I think I was wrong about replacing the second if. I think what you need to do is remove the "else" and run those two lines of code whether the number pressed is a number or * or #. as it is, those two lines get run every time except when the last number comes out to be 12.

    Anyway, you're problem lies with the if, if, else code.

    Try this:
    IF(LAST_BUTTON_PRESSED = 11 )
    {
      LAST_NUMBER_PRESSED = '*'
    }
    IF(LAST_BUTTON_PRESSED = 12)
    {
      LAST_NUMBER_PRESSED = '#'
    }
    NUMBER="NUMBER,LAST_NUMBER_PRESSED"
    SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
    
    
  • JubalJubal Posts: 77
    Hedberg wrote: »
    Ok, I think I was wrong about replacing the second if. I think what you need to do is remove the "else" and run those two lines of code whether the number pressed is a number or * or #. as it is, those two lines get run every time except when the last number comes out to be 12.

    Anyway, you're problem lies with the if, if, else code.

    Try this:
    IF(LAST_BUTTON_PRESSED = 11 )
    {
      LAST_NUMBER_PRESSED = '*'
    }
    IF(LAST_BUTTON_PRESSED = 12)
    {
      LAST_NUMBER_PRESSED = '#'
    }
    NUMBER="NUMBER,LAST_NUMBER_PRESSED"
    SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
    
    

    but this is my code already, but # is not going to my feedback box.
  • HedbergHedberg Posts: 671
    I believe what Hedberg means is getting rid of the switch..case statement all together and using the if..else construct.


    either an abbreviated switch-case or a couple of ifs, just a matter of preference as either is easy to code and understand.

    Probably I'd do something like this:
    LAST_NUMBER_PRESSED = itoa(LAST_BUTTON_PRESSED - 1)
    if(last_button_pressed == 11)
    {
      LAST_NUMBER_PRESSED = '*'
    }
    if(last_button_pressed == 12)
    {
      LAST_NUMBER_PRESSED = '#'
    }
    
  • ericmedleyericmedley Posts: 4,177
    In this line
    LAST_NUMBER_PRESSED = ITOA(LAST_BUTTON_PRESSED-1) 
    

    Why are you converting to an ASCII then loading that back into the integer variable LAST_NUMBER_PRESSED?
  • HedbergHedberg Posts: 671
    ericmedley wrote: »
    In this line
    LAST_NUMBER_PRESSED = ITOA(LAST_BUTTON_PRESSED-1) 
    

    Why are you converting to an ASCII then loading that back into the integer variable LAST_NUMBER_PRESSED?

    Last_Button_Pressed is an integer.

    Last_Number_Pressed is either a character or string.
  • HedbergHedberg Posts: 671
    Jubal wrote: »
    but this is my code already, but # is not going to my feedback box.

    it's not the code that you posted. In your code, the last two lines are part of an "else". Cut the else.
  • mpullinmpullin Posts: 949
    Hedberg wrote: »
    Last_Button_Pressed is an integer.

    Last_Number_Pressed is either a character or string.
    The OP should look into Hungarian Notation.
  • viningvining Posts: 4,368
    I personnally like stacking cases and in a situation like this where you're using an array and get_last it allows you to see the array index position and the value it holds or represents on the TP as noted by the case and its comment which is helpful down the road when debugging.

    If taking the stacked case approach I would do something like:
    BUTTON_EVENT[dvtp,TP_BUTTONS]
         {
         PUSH:
    	  {
    	  LAST_BUTTON_PRESSED = GET_LAST(TP_BUTTONS) 
    	  PULSE[BUTTON.INPUT] //FEEDBACK FOR TOUCHPANEL
    
    	  SWITCH(LAST_BUTTON_PRESSED)
    	       {
    	       CASE 1: //0
    	       CASE 2: //1
    	       CASE 3: //2
    	       CASE 4: //3
    	       CASE 5: //4
    	       CASE 6: //5
    	       CASE 7: //6
    	       CASE 8: //7
    	       CASE 9: //8
    	       CASE 10:(*9*)  {LAST_NUMBER_PRESSED = ITOA(LAST_BUTTON_PRESSED-1)};
    	       CASE 11:(*'*'*){LAST_NUMBER_PRESSED = '*'};
    	       CASE 12:(*'#'*){LAST_NUMBER_PRESSED = '#'};
    	       DEFAULT:       {LAST_NUMBER_PRESSED = ''};
    	       }
    	  if(LAST_NUMBER_PRESSED)//indicates a valid button was pushed
    	       {
    	       NUMBER="NUMBER,LAST_NUMBER_PRESSED"
    	       SEND_COMMAND dvtp,"'@TXT',1,NUMBER"
    	       }
    	  }
         }
    
  • ericmedleyericmedley Posts: 4,177
    Hedberg wrote: »
    Last_Button_Pressed is an integer.

    Last_Number_Pressed is either a character or string.
    Ah, that's what I get for looking at the forum on my smart phone. :)
  • HedbergHedberg Posts: 671
    ericmedley wrote: »
    Ah, that's what I get for looking at the forum on my smart phone. :)


    As Matt Pullen noted, OP needs to do a better job naming variables.
  • JubalJubal Posts: 77
    Thanks all its now working. but again have one concern. how can i send the number to call

    SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104 ',NUMBER,$0A"

    I saw it in NExia that it is dialing but how to send it? how to start and end the call?
  • Do you have Biamp's Nexia software? If you look in the help file, it has all the valid commands for the Nexia. FYI, the same commands work for the Audia as well.
  • HedbergHedberg Posts: 671
    Jubal wrote: »
    Thanks all its now working. but again have one concern. how can i send the number to call

    SEND_STRING dvBiamp, "'DIAL 1 TIPHONENUM 104 ',NUMBER,$0A"

    I saw it in NExia that it is dialing but how to send it? how to start and end the call?

    That appears to be the proper command, assuming that the instance number is correct and that the number is correct.

    If you are properly connected to the nexia, you should get a helpful response telling you your error. Also, you should hear a dial tone.

    Your Nexia may not be properly programmed, you might not be connected to a proper analog telephone line. If you continue to have problems and can't hear a dial tone when you go off hook, talk to the installers or the person who programmed the biamp.
  • JubalJubal Posts: 77
    Actualy there is still no line in that site where i do the program. I only see the feedback when i connect the biamp to my laptop and open nexia software. I can see feedback when muting, level change routering etc. but in dialer i didnt get feedback. I only see in the line that the number i dial in my touch panel appear in nexia software. So thus it means that i get it right? What is the use of on hook and off hook? How about flash? How to end the call? Off hook??? Sorry for my stupid question, thanks for the help everyone.
Sign In or Register to comment.