07-13-2010 10:27 AM
I am running LABView 8 and CANopen 1.1.1 with a PCI-CAN/2 card
I can run the example Analoginput.vi with no problem. I get the data I am looking for and the program exits (stops) with no errors and can run again with no problems.
But when I put the same code in my program I end up having issues. The 1st time it runs fine and stops ok. But the next time I run the program I get an error on the CANopen pdo create.vi. Then I either need to restart the computer or if I go to MAX and run a self check it will reset the card and it will work one more time.
Error: 1074388985
Attempted to set a configuration attribute while the object is running. Solutions: Configure attribute prior to opening the object; stop and restart communications as needed so you can update the configuration attribute.
So it looks like the port is not being shutdown properly when the code is in my program. But I have no idea why? The same code works fine by itself. I have tried putting in code to reset the card before my program runs, but that has not worked.
Any ideas to make sure the port closes properly?
07-13-2010 11:33 AM
Seconded.
I was just about to look for a solution to this also, though the error message I get is -1074384895. Presuming its the same, I got it while using CVI, and it asked me to send the attached file. The only time the error arises is when running my program a few times in quick succession, on the line when I nxStart. Normally my code seems to work fine though.
As such, I am also looking to find a way to guarantee that the connection actually closes.