Error when compiling "Listenindex überschreitet das maximu"

Antworten
DaveLEL
Beiträge: 10
Registriert: Dienstag 15. April 2014, 14:24

Error when compiling "Listenindex überschreitet das maximu"

Beitrag von DaveLEL » Montag 28. April 2014, 12:41

Have just installed Profilab Expert 4.0 and installed the latest updates.

Created a very simple test to turn in and off an output at 3Hz, it runs OK from within Profilab, but if I compile it a get a German error message of "Listenindex überschreitet das maximum"

What is generating this error, what its it trying to tell me?

Operating system is -
Windows 7 Professional, Service Pack 1 64-bit

Dave
Dateianhänge
test-1.prj
Saved program File
(19.15 KiB) 284-mal heruntergeladen

IKT
Beiträge: 549
Registriert: Mittwoch 4. November 2009, 18:32

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von IKT » Montag 28. April 2014, 16:54

Hi Dave,
DaveLEL hat geschrieben:German error message of "Listenindex überschreitet das maximum"
this means simply: "list index out of range" but I can't see where it comes from.
I'm pretty shure it has nothing to do with the LabJack U12, since I also use them and haven't ever seen such a message. Check your Phidget Device and its manual.

PS: Out of your project there isn't any indication of WHAT you really want to achieve?? Please explain!
++++++
Gruss/regards IKT

DaveLEL
Beiträge: 10
Registriert: Dienstag 15. April 2014, 14:24

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von DaveLEL » Montag 28. April 2014, 19:31

Hi,
thank you for our reply, the example program has no real function, just a quick test to change the outputs on the U12 and the Phiget Interface-kit ( 4 x 10A relays).

Have now created a program to start doing the testing I intended to do, but still cannot run it as a complied program.

1) 30 second delay.
2) Turns on power to the unit being tested -- Interface-Kit Output 0 turned on.
3) Delay of 5 seconds ( DLY1)
4) Send test command to unit under test (Calls external program M32 -C2 -B4800 Test-1.msg)
5) Test runs for 25 seconds.
6) Power turned off - Interface-kit Output 0 turned off.
7) Counter incremented.
8) Return to step 1

The U12 will be used to monitor the operation of the unit being tested, but until I can compile and run the program, I don't see the point in setting that up as well.

This program works if run from within the ProfiLab 4 environment with no problems.
I can compile the program, but as soon as it runs I get the "Listenindex überschreitet das maximu" error message.
Have tried running the program with the ProfiLab 4 environmet open and closed, both gives the same result.
As well as the "Front panel" error box saying "Listenindex überschreitet das maximu" there is also a blue progress bar that says Preparing... with the bar at 95%+ completion.

Dave
Dateianhänge
test-1.prj
Program file to Power cycle unit every 30 seconds and display test message
(2.42 KiB) 209-mal heruntergeladen

IKT
Beiträge: 549
Registriert: Mittwoch 4. November 2009, 18:32

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von IKT » Montag 28. April 2014, 20:17

Hi Dave,

this seems to me to be a problem at the base, rather than with the project as such.
So let's take it step by step PL first:
1) which sort of PL are you using? (DEMO or LICENSED, I assume you have PL-Expert?)
2) have you (after installation) updated to the latest version?
Hardware second:
3) installed the latest version of ALL the drivers (LJ-U12 and Phidgets)? You might have to deinstall older drivers first ...
third General:
4) compiled one or more of the Example Programs, without any errors?
After checking ALL the above 'successfully', try to compile the current project.
++++++
Gruss/regards IKT

DaveLEL
Beiträge: 10
Registriert: Dienstag 15. April 2014, 14:24

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von DaveLEL » Dienstag 29. April 2014, 11:32

Hi,
I have looked at the compiled program, and think I may have found an indication of what its going wrong.
When I run the compiled program, the first time it is run, the error is reported, but all subsequent times the program runs without error - but does not function. Only by re-compiling the program is the error again reported.

I compared the files of the program before and after the first time it is run, and indeed one of the files changed.

In the sub directory Settings is a file named HARDWARE.INI

Right after the program is compiled, but before the program has been run the file contents are.

Code: Alles auswählen

[1.IFK-1]
Name=Interface Kit
Device=15736
The Phidget Interface Kit has a serial number of 8862 = 0x15736 so this file looks to set up the address of the Phidget ( They are addressed by serial number ).

After the program has been run and the error "Listenindex überschreitet das maximu" is displayed, the HARDWARE.INI file is changed -- the contents is now

Code: Alles auswählen

[1.IFK-1]
Name=Interface Kit
Device=5736

When the program is run again the program does not function, I assume as its now addressing a Phidget of serial number 22326 rather than 87862.

Is it possible that when operating in the development environment, the serial number is taken as a 64 bit number, where when compiled it is taken to be only 32 bit, so truncating the stored number ?

Have tried changing the serial number from the Front panel and the dialog box will not take a serial number above 4 digits.

ProfiLab Expert 4.0 with latest updates -- New 28/4/2014 not yet registered it
Phigets driver DLL Downloaded and installed least version 25/4/2014

Dave

IKT
Beiträge: 549
Registriert: Mittwoch 4. November 2009, 18:32

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von IKT » Mittwoch 30. April 2014, 10:46

Hi,

you have just given the answer yourself:
The (Phidget) Device Serial Number is "out of range" ! (of PL-E supported ranges!)
You have to use the manufacturer supplied Setup-Tool to set up the HW to be within a range that:
- the HW manufacturer supports - and -
- PL-E also, is able to cope with
In order to do that, you will have to study the Phidget's Documentation. Since I don't have the HW, there is for me NO WAY to help you any further ...
++++++
Gruss/regards IKT

DaveLEL
Beiträge: 10
Registriert: Dienstag 15. April 2014, 14:24

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von DaveLEL » Mittwoch 30. April 2014, 11:06

Hi
The serial numbers of the Phidget devices are fixed and cannot be changed, so the error is in the ProfiLab Expert compiler.
The fact that the program works when running in the programming environment but fails when its compiled, looks like an error in the code used to link the elements using a 32 bit integer in place of a 64 bit integer.

Are the forums looked at by ABACOM ? or do I have to contact them another way to get this looked at, and hopefully resolved?

IKT
Beiträge: 549
Registriert: Mittwoch 4. November 2009, 18:32

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von IKT » Mittwoch 30. April 2014, 11:29

Hi,

PL-Expert is a Windows32 Application. How exactly the adressing internally works, I'm not aware of. The problem you are having could be related to what you are suspecting.

@Abacom:
Any suggestions and/or advice on this issue?
++++++
Gruss/regards IKT

abacom
Site Admin
Beiträge: 3372
Registriert: Dienstag 23. September 2008, 10:54
Kontaktdaten:

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von abacom » Mittwoch 30. April 2014, 12:57

I compiled and ran above project successfully. (Win7x64)
May be a issue of Driver/DLL versions.
Make sure to have latest installed...
http://www.phidgets.com/docs/Operating_System_Support
ABACOM support

DaveLEL
Beiträge: 10
Registriert: Dienstag 15. April 2014, 14:24

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von DaveLEL » Mittwoch 30. April 2014, 13:20

Hi
I have Phidget21 Version 2.1.8.185 installed From Phidget-x64_2.1.8.20140428.exe, which is the downloaded from the link you have posted. ( Updated 28th April 2014)

To check its the right version I have just uninstalled the Phidget drivers and re-installed them -- reports the same versions.

Again when I run the program I get the same error message - and again the serial number of the Phidget in the configuration file is changed for 15736 to 5736 after the program is first run.

Are you using Windows 7 64 Bit ?

I need to use 64 Bit Windows to use some 64Bit engineering applications -- but find with older 32 Bit applications there can be some incompatibility that give some odd errors at times.

I have an old PC with Windows XP on it, I may have a go at running the software on that PC and see if I still get the same problem.

Dave

P.S. What is the serial number of the Phodget you are using ? is it > 65535 ?
Zuletzt geändert von DaveLEL am Mittwoch 30. April 2014, 13:45, insgesamt 1-mal geändert.

IKT
Beiträge: 549
Registriert: Mittwoch 4. November 2009, 18:32

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von IKT » Mittwoch 30. April 2014, 13:36

hi,
DaveLEL hat geschrieben:Phidget-x64_2.1.8.20140428.exe
there we have it: you are installing the x64 drivers (wrong), get and install the 32bit Version. (after de-installing everything you have now!)

This should sort out all the hassles ...
++++++
Gruss/regards IKT

DaveLEL
Beiträge: 10
Registriert: Dienstag 15. April 2014, 14:24

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von DaveLEL » Mittwoch 30. April 2014, 14:04

The 64 Bit Installer installs both the 64 Bit and 32 Bit Libraries, the 32 Bit installer will not run on a 64 Bit system, telling you to install the 64 Bit version.

IKT
Beiträge: 549
Registriert: Mittwoch 4. November 2009, 18:32

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von IKT » Mittwoch 30. April 2014, 14:18

OK as of right now this is a Phidget only problem. It has nothing to do with PL.

We have had similar problems with compiling .DLL's for PLE, they too have to be 32bit to run properly. I think that, installing both versions, creates the problem of not beeing able to conrol which Driver/DLL is therafter used.

You should discuss this issue with Phidget's Support.
++++++
Gruss/regards IKT

IKT
Beiträge: 549
Registriert: Mittwoch 4. November 2009, 18:32

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von IKT » Mittwoch 30. April 2014, 18:21

Update:
After checking the Phidget's WebSite it becomes clear that:
1) You can't use their installers (deinstall everything according to their advice!)
2) You have to do a MANUAL install, as described clearly in 'black and white' there!
3) Get yourself the 32bit driver(s) without installer
4) Do the MANUAL install (copy the *.DLL-file to C:\Windows\System32\ )
5) Do not at this time install anything else!
6) Test with your freshly compiled project

This should do the trick ...
++++++
Gruss/regards IKT

DaveLEL
Beiträge: 10
Registriert: Dienstag 15. April 2014, 14:24

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von DaveLEL » Mittwoch 30. April 2014, 21:07

If there is a problem with the driver/DLL why does the program operate the Phidget with no problem when its run in the PLE environment ?
The PLE environment is a 32 bit application and works with the 32 Bit DLL installed by the Phidget installer.
So from this the DLL is working without a problem, I have had the program running within the PLE environment for a number of hours without a problem.

The compiled version of the program should use the DLL in just the same way as when its running from the PLE environment ?

When the program is compiled does it use the .h and .lib files or does it just link to the dll ? as the dll from Phidget has been updated so recently (28/4/14) the functions in the dll may have change -- but if that was the case the operation under the PLE environment would also be compromised ?

Will experiment with installing the older version of the dll's from Phidget

Have just checked with
Phidget 2.1.8.20130820 - 20th August 2013
Phidget 2.1.8.2012606 - 6th June 2012

Both sets of DLL's give the same result, operates without a problem when tested running from within PLE, but gives an error when the program is compiled and run as a stand alone program.

Dave

IKT
Beiträge: 549
Registriert: Mittwoch 4. November 2009, 18:32

Re: Error when compiling "Listenindex überschreitet das maximu"

Beitrag von IKT » Donnerstag 1. Mai 2014, 11:38

You seem to just want to have it 'your way'. So be it ... sort it out yourself ...

As of now I'm OUT of this thread!
++++++
Gruss/regards IKT

Antworten

Zurück zu „Thema: Compiler“