Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   NI LabVIEW (http://www.chiefdelphi.com/forums/forumdisplay.php?f=182)
-   -   Doesn't execute teleop execute case (http://www.chiefdelphi.com/forums/showthread.php?t=74008)

rjn 09-02-2009 16:07

Doesn't execute teleop execute case
 
1 Attachment(s)
We created a prototype traction-control code, however, we aren't sure if it is a problem with encoders in begin or if it is a problem with teleop, which is why after pain-staking hours of attempted debugging, and deciding it would be better than making ten million screen shots, here is our project.


The way the teleop works, although I added some comments, it might now have been enough/they may have been deleted, is the expected velocity value based on the joystick and compares it to the real value of velocity based on the accelerometer and corrects the values accordingly through a pid and gives it to the jag, it is also corrected for motor bias using encoders and ratios, which is that code node and the a and b wires. Please take a look, and I know I didn't do a very good job explaining, but that is because there is a lot, but I will be very actively checking the thread and answer every single question, our coders are quite confused. : s


dteleop is our traction control teleop, and some of the sub vis may be un apptly named.

Fred is where all the traction control occurs, vpid is the velocity pid and uh, yeah, have to run. Thanks for all the help.

Bryan Herbst 09-02-2009 21:29

Re: Doesn't execute teleop execute case
 
A little more explanation-

We have tried running the code from labview (not building/deploying), and it appears as though the code never sends anything out of begin.vi when we are looking at robot main. Begin.vi seems to take significantly longer running the enocder opens than anything else.

When looking at the data flowing through dteleop, it appears as if the code repeats the Teleop init case over and over again, and is never actually running the execute case.

We are unsure as to whether there is something in begin.vi, or dteleop.vi that is causing the problems. You may be able to determine our problem simply by looking at these two files as opposed to the whole project.

NumBeast 09-02-2009 23:50

Re: Doesn't execute teleop execute case
 
This might or might not be your problem, but in begin.vi your newly opened encoders aren't wired into your robot data structure. They're kinda just hanging there...

Greg McKaskle 10-02-2009 08:08

Re: Doesn't execute teleop execute case
 
As mentioned, your encoders aren't hooked up. Also, you have a start communications in the Vision VI.

I don't see anything that would make Begin run more than once. Put a breakpoint on something like an open node in it. Right click and set breakpoint. If you hit the breakpoint more than once, the stack crawl ring at the top of the window will show who is calling.

I think you'll find that there is only one call. Sorry I couldn't be more help.

Greg McKaskle


All times are GMT -5. The time now is 10:31.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi