|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools |
Rating:
|
Display Modes |
|
|
|
#1
|
|||
|
|||
|
Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fast
The basic result of our problem is that introducing the new compressor control loop vi to the begin.vi code prevents anything from running (mostly just the joystick controls, at this point in our code), but the compressor will only run if the control loop is introduced.
Begin.vi: ![]() teleop.vi: ![]() The error message we're currently receiving: ![]() This current error message isn't what I was originally intending to post about, so I get the feeling that this one is just due to some silly oversight. The main error we were trying to deal with (which I couldn't get a screenshot of because we started getting this new error) should be this one (but I can't be 100% sure that it was this exactly): ERROR <Code< -44061 occurred at "Robot Drive [see our teleop code]" in the VI path: Robot Main.vi FRC: The loop that contains RobotDrive is not running fast enough. This error can occur if the loop contains too much code, or if one or more other loops are starving the RobotDrive loop. I've seen this error code talked about in my google searches, but not in relation to the compressor control loop. We're brand new to labview would be greatly appreciated. |
|
#2
|
||||||
|
||||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
The compressor control loop should not be called in Begin. It should be called in periodic tasks, where it won't block anything. There is already an example of it in periodic tasks.
|
|
#3
|
|||||
|
|||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
To give a little more detail and explain why Joe is correct, the Compressor Control Loop vi never terminates. Putting it in Begin means that the Begin vi never terminates. Robot Main waits for Begin to be done before starting up pretty much everything else.
|
|
#4
|
||||
|
||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
Sure enuff, Alan's correct as we spent most of today finding this little tidbit of information.
|
|
#5
|
|||||
|
|||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
Quote:
We ran the the "Solenoid with Compressor Example.vi" and when we would enable the robot the compressor would turn on for less then half a second and then shut off. We could disable and the same behavior would repeat when we enabled. We verified that our all of our components where hooked up properly (we checked the spike, digital I/O port, compressor, etc). We got the following error message: ERROR <Code> -44040 occurred at WPI_RelayCache.vi>>WPI_RelaySet.vi>>WPI_Compressor ControlLoop.vi>>Solenoid With Compressor Example.vi <time>00:02:03 01/01/1970 FRC: The relay index is invalid. We used Digital Module 1, Relay 2, DIO 2. The example shows the correct wiring on the front panel and we followed it exactly. In past years we have an no problems with the compressor, so this was particularly confusing. So do we just need to add the new Compressor Control Loop vi? Last edited by rachelholladay : 11-02-2012 at 21:03. Reason: more details added. |
|
#6
|
|||||
|
|||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
It's the grayed out (Disabled) code in Periodic Tasks.vi
"The name" will have to be changed to whatever you're calling your compressor and it needs enabling. |
|
#7
|
|||||
|
|||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
So all we have to do is enable that within periodic tasks and specify the name?
We are still wondering why the "Solenoid with Compressor Example.vi" didn't work. The behavior is described in my previous post. |
|
#8
|
||||
|
||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
Ok I have read and read, here, NI site, labview help, everyone seems to know about the compressor s/w change. I have read the labview what's new for 2012 and they reference the compressor and camera changes, and say see examples and periodic tasks, that thank you now we see.
but since we can't make the solenoid with compressor example work, the compressor comes on for what seems like 1 execution cycle and stops, we are thinking there is still something here we don't understand. is there some place that is compressor s/w change is full documented? also i am assuming that when you enable the diagram for compressor_control, you still need a while loop for your compressor enable vi. is that still the way to code periodic tasks? |
|
#9
|
|||||
|
|||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
No compressor Enable is required.
No loops or addition code necessary. If your code looks like below, then you might have an electrical issue stopping your compressor so abruptly. ![]() |
|
#10
|
||||
|
||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
I'm curious to know how many teams have been able to get the compressor to work with the given code. I've been helping two teams, neither of which have gotten their compressor to work with the given control loop.
We ended up making our own compressor control loop, which works every time. I can share it, but I want to get some feedback on the given code first. Our problem has been registry get errors, or something like that. We use the same inputs and outputs in our own code and get zero errors, plus the compressor works every time. |
|
#11
|
||||
|
||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
I believe this is how it should be setup, right?
Begin.vi Periodic Tasks.vi Finish.vi This code should work assuming you're using DIO1 for the pressure switch and Relay 1 for the Compressor's Spike relay. Is this correct? Last edited by RyanN : 12-02-2012 at 15:42. |
|
#12
|
|||||
|
|||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
That looks correct, and it's worked for me when I've used it.
Your Driver Station reports the cRIO image version to be v43? No conflicts for DIO 1 or Relay 1? |
|
#13
|
||||
|
||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
Quote:
Quote:
Anyway, we're using this code right now, which works perfectly. Begin.vi Periodic Task.vi Finish.vi I'm assuming this is legal for use in competition as long as we can demonstrate that the compressor shuts off at ~120PSI, and we have the pressure relief valve installed. I'm not going to lie. I skimmed the rules when they first came out. Being a college mentor is hard. I dedicate what time I have to help out the teams I mentor. I don't remember any of the rules saying you have to use their compressor code, but I'm not 100% sure. Last edited by RyanN : 12-02-2012 at 16:55. |
|
#14
|
|||
|
|||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
Team 3711 has just run into the same message . Our code looks exactly like that shown above for all three vi's. And we're getting the invalid relay index message (and "invalid" indications in the control loop vi front panel)
Modules are set to the default of 1. Both the pressure switch and spike PWM are in the number 1 slots. We've replaced PWM cable and spikes. The spike gets a continuous orange(ish) light and receives no signal. If someone does have a workaround we'd love to see it since we're testing pneumatics on the robot using a manual switch at the moment. Thanks very much. |
|
#15
|
|||||
|
|||||
|
Re: Compressor Control Loop: Relay Index is Invalid; also, Robot Drive not Running fa
Team 1410 apparently fixed their "relay index is invalid" problem by using a good 37-pin cable between the cRIO digital module and the Digital Sidecar. I don't know why that would make a difference, unless the faulty cable was somehow keeping the module from working.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|