|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Relay Set toggling between Indexes?
During testing we noticed we are getting error "-44040: invalid relay index"
Upon further investigation, we noticed that inside our compressor control loop (in periodic tasks) the WPI_RelaySet.vi is somehow toggling between relay 1, 2, and 3 by itself and also switching between forward, reverse and off relay modes. I probed the inputs to this subvi inside the compressor control vi, everything is perfect. RelaySet should be getting Relay 1 as the index and forward as the relay mode, but probing inside RelaySet, even the controls are toggling uncontrollably. We do use two other relays (solenoids) but they're on totally different controls. I checked and we don't have the same relay set anywhere else in the project. Anyone know what's going on? This is causing us headaches and lots of frustration .... |
|
#2
|
||||||
|
||||||
|
Re: Relay Set toggling between Indexes?
Quote:
Are you actually having a problem, or just trying to find out why that error message is printing? |
|
#3
|
|||
|
|||
|
Re: Relay Set toggling between Indexes?
The error string should contain an ASCII call stack. It list the lowest node or VI->calling VI->calling VI->etc.
If there are multiple calls to the same node or subVI, on that diagram, then you have to debug which one, but often it is unique. Does this help determine which refnum wasn't opened properly, or which didn't stay opened? Greg McKaskle |
|
#4
|
||||
|
||||
|
Re: Relay Set toggling between Indexes?
Quote:
Because Teleop runs/stops at the same rate as the change in relay index in this compressorloop, I'm led to believe this Relay vi is the problem. Quote:
The error meassage reads: "The relay index is invalid" The sporadic toggling of which relay index is the correct one begins in Relay set, starting with the controls; i mean sporadic in the most literal sense. Last edited by Invictus3593 : 18-01-2014 at 09:04. |
|
#5
|
|||||
|
|||||
|
Re: Relay Set toggling between Indexes?
Please show us the code where you're opening the compressor in Begin, and where you're calling its control loop in Periodic Tasks.
You can select the relevant section of the Begin.vi, then choose "Create VI Snippet from Selection" from the Edit menu. It'll create a .png file with the name and location you select, which you can then attach here. We'll be able to see the picture easily, and it will be live LabVIEW code that we can run if we want to check something for more detail. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|