![]() |
Why is my autonomous code still not working?
1 Attachment(s)
I posted about this code already.
I fixed it, yet our robot doesn't do anything when we enable autonomous. Teleop is working fine. Is there still something wrong with the program? :eek: Thanks! |
Re: Why is my autonomous code still not working?
The robot doesn't do anything? It doesn't even "twitch" the motors slightly when you enable Autonomous, or ten seconds later?
Are there any messages showing on the Driver Station diagnostic display that might point to a cause? |
Re: Why is my autonomous code still not working?
Maybe you enabled a Motor Safety in Begin.vi for each of these and you shouldn't have?
|
Re: Why is my autonomous code still not working?
2 Attachment(s)
When I enable autonomous, the motors do not flash. They stay a solid orange.
I noticed that it says "autonomous disabled" under the Robot Global Data VI. Does that make a difference? P.S I attached the errors that are shown on the Driver Station. Thanks! |
Re: Why is my autonomous code still not working?
A solid orange status on the motor controller would mean that the code successfully opened the device.
The code error listed on your Driver Station probably means the name you are using for your Get in Autonomous Independent.vi does not match EXACTLY the name you Opened in Begin.vi. I suggest that you
Quote:
In the future, instead of taking a snapshot of the Driver Station Diagnostic window, it would be more complete if you highlighted all the errors in the Diagnostic window and cut/paste them into WordPad. The screen shot only got the top of the error and the scroll bar shows that there are a lot more messages that you haven't looked at. |
Re: Why is my autonomous code still not working?
Here's two other issues you should resolve before your regional:
Your Driver Station Software is out of date, see R90. You can download the update here: http://joule.ni.com/nidu/cds/view/p/id/2263 The battery voltage needs to be displayed on the Driver Station. See R71 for how to set up the hardware to do that. |
Re: Why is my autonomous code still not working?
The main reason is because those are "wait" functions, so instead of running the code for 10 seconds, its running it once, then moving on. What you want to do is remove the sequence structure, and put each "command" in its own for loop. Set a time delay for about 1ms, and set it to iterate 10000 times. You also want to check that that the refnums are the same as they are in the Begin.vi, down to captitalized/uncapitalized, and spacing. I don't know what to tell you about the autonomous disabled part, I know for a fact its supposed to default to disable in the Begin.vi, but if the framework got messed up somewhere else I couldn't be quite sure what to tell you.
|
Re: Why is my autonomous code still not working?
Quote:
|
Re: Why is my autonomous code still not working?
Thanks :)
I checked the name that I used in the begin.vi and I noticed that I wrote "SWING" and in the autonomous independent.vi I wrote "swing" I have yet to deploy the code, so I was wondering if the capitalization made the difference? |
Re: Why is my autonomous code still not working?
Quote:
|
Re: Why is my autonomous code still not working?
That was the problem all along!
The name I was using for my Get in Autonomous Independent.vi did not match the name I Opened in Begin.vi. Thank you all very much! :D |
| All times are GMT -5. The time now is 12:07. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi