Home AMX User Forum AMXForums Archive Threads AMX Hardware

extron switcher mps 112 problem

I m not able to control the extron switcher thru the amx touch panel.

The rs 232 is working because thru notifications i can send and recieve the messages

i have defined the device

dvExtron =5001:2:0
dvTpExtronMVP7500 =10001:2:1

and my extron code is


PROGRAM_NAME='IncExtron'

DEFINE_VARIABLE

INTEGER Index

char Sbuff[40]

INTEGER nExtronbutton[] =
{
1,2,3,4, // VGA

5,6,7,8, // S- video

9,10,11,12 //video


}


DEFINE_START

create_buffer dvExtron,Sbuff

DEFINE_EVENT

DATA_EVENT[dvExtron]
{
online:
{
// Set Baud for Projector
send_command dvExtron,"'SET BAUD 9600,N,8,1'"
}
}


BUTTON_EVENT[dvTpExtronMVP7500,nExtronbutton]
{
push:
{
Index = GET_LAST(nExtronbutton)
SWITCH(Index)
{
CASE 1:
{
// VGA
send_string dvExtron,"'1!'"
break
}
CASE 2:
{
// VGA
send_string dvExtron,"'2!'"
break
}
CASE 3:
{
// VGA
send_string dvExtron,"'3!'"
break
}
CASE 4:
{
// VGA
send_string dvExtron,"'4!'"
break
}
CASE 5:
{
// S-video
send_string dvExtron,"'5!'"
break
}
CASE 6:
{
// S-video
send_string dvExtron,"'6!'"
break
}
CASE 7:
{
// S-video
send_string dvExtron,"'7!'"
break
}
CASE 8:
{
// S-video
send_string dvExtron,"'8!'"
break
}
CASE 9:
{
// video
send_string dvExtron,"'9!'"
break
}
CASE 10:
{
// video
send_string dvExtron,"'10!'"
break
}
CASE 11:
{
// video
send_string dvExtron,"'11!'"
break
}
CASE 12:
{
// video
send_string dvExtron,"'12!'"
break
}
}
}
}

i think the code i m sending to the extron switcher is not recognized by it

can anyone help me in this ,this is my first program.

Comments

  • ericmedleyericmedley Posts: 4,177
    I think you need to put a CR and/or LF at the end of the string


    example
    CASE 1:
    { 
    // VGA
    send_string dvExtron," '1!',$0d,$0a "
    break
    }
    
  • Double check that your port actually went to 9600. Send a command to the port with control a device in diagnostics. The command is GET BAUD. Every once in a while, even when the processor says the port is online, It's not ready to receive a SEND_COMMAND. Extron commands don't need a CRLF.
  • jweatherjweather Posts: 320
    Make sure it's in single-switcher mode by sending 1*1# (or via front panel config). Then it should switch via the 1! commands.
  • DHawthorneDHawthorne Posts: 4,584
    It may also be necessary to put a CHARD command on that port. As I recall, the unit is really only looking for single bytes, and if they come in too fast it may not recognize the command.
  • the extron switcher was not in the single switcher mode ,so once i change it to single mode.the extron started recognizing the commands thru rs 232

    thanks to all for your help
  • Joe HebertJoe Hebert Posts: 2,159
    kbeattyAMX wrote:
    Every once in a while, even when the processor says the port is online, It's not ready to receive a SEND_COMMAND.
    Really? Is this a known documented bug? Has AMX confirmed this issue and are they working on a fix?

    Does this problem exist for SEND_COMMANDs to any device in its ONLINE: handler or is it strictly an RS-232 port problem?
  • I never reported this as a bug. It happens so sporadically I never thought to follow thru with it... Ajay just needs to confirm that the port actually changed to the proper settings.
Sign In or Register to comment.