AdvancedHMI Software

General Category => Support Questions => Topic started by: WellsCPak on June 24, 2015, 11:18:06 AM

Title: IndexOutOfRange in Write function - CLX 398s
Post by: WellsCPak on June 24, 2015, 11:18:06 AM
I just picked up a Micro820 for a budget project based on the micro800 support in AHMI, thanks!
Using the EthernetIPforMicro800Com driver talking to a Micro820 controller, I'm getting a couple different exceptions thrown in the Write function. Any help would be greatly appreciated.
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: Archie on June 24, 2015, 06:52:45 PM
Are you writing via code or using PLCAddressKeypad on a control?
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: WellsCPak on June 25, 2015, 08:17:31 AM
I have two BasicButtons, with the PLCAddressClick and PLCAddressHighlight on each set to a test tag. OutputType set to Toggle. When the form loads, they both update and highlight accordingly, then I can toggle the bits with the buttons, but the highlight doesn't update until I restart the app. Also sometimes it throws that OutOfRange exception from the Write function.
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: Archie on June 25, 2015, 08:33:54 AM
Try the patch given for this problem:

http://advancedhmi.com/forum/index.php?topic=838.0

It sounds very similar. If you lose connection for more than a few seconds, it will give an Index Out of range when it tries to restart comms.
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: WellsCPak on June 25, 2015, 09:08:19 AM
It seems better with that patch, at least it isn't throwing the exception anymore.

Still having the issue where the button highlights don't update after form load. It seems like the first button press doesn't register either, whichever button I press first doesn't do anything, but any button presses after that toggle the bits properly.
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: Archie on June 25, 2015, 09:21:04 AM
If you have a lot of controls on the screen, you may be experiencing this bug, see the driver modification on the second to last post:

http://advancedhmi.com/forum/index.php?topic=836.0

Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: WellsCPak on June 25, 2015, 09:34:46 AM
It looks like I already made that change yesterday.
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: Archie on June 25, 2015, 09:38:06 AM
Would you be able to send me your project and the PLC program with the tags? I don't need the ladder logic, so it can be deleted. I only need tags to install in my PLC to test run the HMI.
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: WellsCPak on June 25, 2015, 10:24:46 AM
It's just a dummy program while I play with the 820 and get used to how it works.

http://s000.tinyupload.com/index.php?file_id=70124892009854730575
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: Archie on June 25, 2015, 10:59:19 AM
I have to download and install the latest version of software for the Micro820, so it may take me a few hours to get setup for testing, but I will let you know what I find out.
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: Archie on June 25, 2015, 11:57:55 AM
I found the problem and now I have to come up with a fix. Back in version 3.98j a new CIP function was implemented called the Multiple Service Request. This allows requests of multiple tag values with a single packet. Apparently the Micro800 series does not support this service. I will need to work on a driver modification that disables this.

In the mean time, you can try to use version 3.98f

https://sourceforge.net/projects/advancedhmi/files/advancedhmi/3.5/
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: WellsCPak on June 25, 2015, 01:43:14 PM
3.98f works awesome, thanks Archie! :)
Title: Re: IndexOutOfRange in Write function - CLX 398s
Post by: Archie on June 25, 2015, 03:01:28 PM
Within a week version 3.98t should be available that will have the fix for this.