Help with Error Code

A plugin that allows for end user development of multiple RS232 device control systems.
User avatar
DaveB
Simply Incredible
Simply Incredible
Posts: 3143
Joined: Sun May 30, 2004 10:57 pm
Location: Mays Landing, NJ
Contact:

Help with Error Code

Postby DaveB » Sat Jun 27, 2009 10:25 am

Hi All - I need a bit of an assist in figuring out what I am doing wrong to cause the errors below after every command sent to my Multi-Room amp.

THe device is an older Matrix Audio (prior to being bought out by AMX) MRC-8.4e. THe unit has a simple command set and works very well with my implementation. All commands work great, but I keep getting the error codes below. This does not effect operation, but I just want to clean it up a bit.

The Matrix is connected via a serial port on my GC-100.

Ideas will be appreciated.

Code: Select all

Sending command for MRC8 - Z51 via GC: 192.168.15.55:1
Processing Return String - OK
Error 9(Subscript out of range) @ Line 300 in procedure ProcessCommands of modSharedCode
Error 9(Subscript out of range) @ Line 380 in procedure ProcessCommands of modSharedCode
Error 5(Invalid procedure call or argument) @ Line 400 in procedure ProcessCommands of modSharedCode
Pass through command was processed
Processing - MRC8~Source_Select~5~1 from GIGA
CMD: MRC8~Source_Select~5~1 FROM: GIGA
Processing GC Command
Socket State - 7
Sending command for MRC8 - S51 via GC: 192.168.15.55:1
Buffer partially filled - Waiting for additional data
Processing Return String - OK
Error 9(Subscript out of range) @ Line 300 in procedure ProcessCommands of modSharedCode
Error 9(Subscript out of range) @ Line 380 in procedure ProcessCommands of modSharedCode
Error 5(Invalid procedure call or argument) @ Line 400 in procedure ProcessCommands of modSharedCode
Pass through command was processed
Processing - MRC8~Volume~5~13 from GIGA
CMD: MRC8~Volume~5~13 FROM: GIGA
Processing GC Command
Socket State - 7
Sending command for MRC8 - V513 via GC: 192.168.15.55:1
Processing Return String - OK
Error 9(Subscript out of range) @ Line 300 in procedure ProcessCommands of modSharedCode
Error 9(Subscript out of range) @ Line 380 in procedure ProcessCommands of modSharedCode
Error 5(Invalid procedure call or argument) @ Line 400 in procedure ProcessCommands of modSharedCode
Pass through command was processed
Processing - MRC8~Zone_pwr~6~1 from GIGA
CMD: MRC8~Zone_pwr~6~1 FROM: GIGA
Processing GC Command
Socket State - 7
Sending command for MRC8 - Z61 via GC: 192.168.15.55:1
Processing Return String - OK
Error 9(Subscript out of range) @ Line 300 in procedure ProcessCommands of modSharedCode
Error 9(Subscript out of range) @ Line 380 in procedure ProcessCommands of modSharedCode
Error 5(Invalid procedure call or argument) @ Line 400 in procedure ProcessCommands of modSharedCode
Pass through command was processed
Thanks!

Dave Bruner
:shock:

User avatar
DaveB
Simply Incredible
Simply Incredible
Posts: 3143
Joined: Sun May 30, 2004 10:57 pm
Location: Mays Landing, NJ
Contact:

Postby DaveB » Thu Jul 09, 2009 5:38 pm

Just bumping this one up - Anyone have any ideas?
Thanks!

Dave Bruner
:shock:

ricks
Is there life beyond Cinemar?
Is there life beyond Cinemar?
Posts: 1127
Joined: Wed Oct 27, 2004 7:01 pm
Location: Latham, Massachusetts
Contact:

Postby ricks » Thu Jul 09, 2009 7:04 pm

Hey Dave,

Shooting in the dark here but my guess is that MLGD is not understanding the response from the device when you send it a command. Is the device 2-way? Do you get status messages from the device once you've sent it a command or query? If so, do these responses also throw this error?

I think I would start by making sure you have the right command terminator set in the Device Setup tab. If you edit a command and hit "Test", what response do you see in the box? Does the error show up there as well? Or does it just say OK?

Anyway, that's my guess... incorrect command terminator for inbound messages from the device.

Sorry I couldn't be of more help.

Rick

User avatar
DaveB
Simply Incredible
Simply Incredible
Posts: 3143
Joined: Sun May 30, 2004 10:57 pm
Location: Mays Landing, NJ
Contact:

Re: Help with Error Code

Postby DaveB » Mon Aug 24, 2009 10:51 am

Rick;

Finally getting back to this. First, something along the way in the last year must have changed with the driver, as the equipment is the same and my script and command set worked previously. Everything works. I have control of the equipment and good feedback with the exception of volume level. The volume level issue is the fault of the device. When someone hits a keypad to adjust volume in a zone, then the unit seems to store that information in cache, which only gets flushed after the next command, so that is a mess with no good fix.

This issue is something different; every time I enter any command from the touchscreen, I get the errors above; same error every time.

The device is a Matrix Audio MRC-8e - 8 zone, 4 source distribution amp with keypads and distributed IR. Company was purchased by AMX four years ago and is gone.

Sample command for powering a zone; Z<<VAR1>><<VAR2>>, Where VAR1 = zone number 1 - 8 and VAR2 = Off/On (0,1), so the command actually sent is like this;

Z11; Commands must be in upper case, do not require CR/LF, and are confirmed with "OK" or "ERR" as a response. That is it - as simple as it gets.

The command will only work with a Command Terminator of 13;

Below is the response from a screen button to turn on zone 1;

OK
- (3) - Last Char => 13

and the errors generated;

Error 9(Subscript out of range) @ Line 300 in procedure ProcessCommands of modSharedCode
Error 9(Subscript out of range) @ Line 380 in procedure ProcessCommands of modSharedCode
Error 5(Invalid procedure call or argument) @ Line 400 in procedure ProcessCommands of modSharedCode

below is the response from a keypad button press to turn on then off zones 6 and 5 - Note that the response from a keypad press is far more descriptive than from a screen press;

ZZ61
- (5) - Last Char => 13
ZZ51
- (5) - Last Char => 13
ZZ60
- (5) - Last Char => 13
ZZ50
- (5) - Last Char => 13

So the problem is that a response from a screen press is just "OK" where from a keypad it is "ZZ##"

Either way, no matter what the command, i get the same errors above.
Thanks!

Dave Bruner
:shock:

ricks
Is there life beyond Cinemar?
Is there life beyond Cinemar?
Posts: 1127
Joined: Wed Oct 27, 2004 7:01 pm
Location: Latham, Massachusetts
Contact:

Re: Help with Error Code

Postby ricks » Mon Aug 24, 2009 8:41 pm

Hey Dave,

Another shot in the dark but I assume there has been no change in the baud rate. What happens if you skip the variables <<VARx>> and use actual command values like Z11 in MLGD?

I used to see similar errors with the Xantech if I placed 2 commands too close together... it didn't give the Xantech time to respond before the second command was sent. I had to build in MLPause's as low as .2 or .3 seconds. Doesn't seem to be the case here since you are only sending a single command.

Sorry I don't have anything else. :cry:

Rick

User avatar
DaveB
Simply Incredible
Simply Incredible
Posts: 3143
Joined: Sun May 30, 2004 10:57 pm
Location: Mays Landing, NJ
Contact:

Re: Help with Error Code

Postby DaveB » Tue Aug 25, 2009 7:23 pm

I am looking deeper into my scripting that is attached to the actions. There is a chance that a script is not correct. Many things happen with just one key press of the screen to turn physical things on or off and screen icons on or off. I am going to take one function like ZZ11 and disconnect everything from that function, then see what I get. Also, I have no response to catch the OK from valid key presses. I do not think that this is it due to the fact that I get the same response if I hit a keypad, which does not produce the OK return. I still think it is something to do with the "13", but the commands will not work without it. The documentation for the product says that it is not required, but they may be incorrect.

I am starting to look at other connected modules, as this thing was working great at one time. One of the updates from some module or MLS broke it partially. Once more, everything works, but the errors are annoying.
Thanks!

Dave Bruner
:shock:


Return to “MLGenericDevice”

Who is online

Users browsing this forum: No registered users and 1 guest