Hi… basically, our programmer had family issues and left, so heres the problem… he took the flashdrive. :\
Point is, we have absolutelly no one to program our robot, and no one that can knows even a tiny bit about programming in labview or anything. Our programmer told me to post here and gave me his account so here I am. I really help! So where can I find updated tutorails and stuff to program a rolling robot. Sucks that its pretty complicated this year.
Oh dear, that’s a shame. He can’t send the code he’s got to you or anyone else on the team?
If not, check out this website put out by Team 0358. While I didn’t learn of it till yesterday, it seems to be a good place to get started. Another alternative is to get someone from your team who has had past programming experience and let them sift through the default Robot Project code. It’s a pretty steep learning curve for basic things.
Other than that, just browse around the forums here. Lots of questions asked, with lots and lots of answers.
The team358 website is a great source for isolated pieces of code to do specific jobs. It has helped me many times.
Three years ago, our C programmer left the team and we started from scratch learning LabView. I relied heavily on http://www.frcmastery.com/. They have many tutorials on not just learning LabView, but they are specific to FRC. I just checked and they have not updated tutorials to this years game, but for learning labview in general, the 2010 and 2011 tutorials are still appropriate as the framework has not changed much.
You can also find general Labview tutorials at NI’s website. Some that I have used in the past are
I see your team is going to Alamo in week 1, so you don’t have a lot of time. Start by watching the FRCMastery tutorials. After that, I’d recommend you find a nearby team to come over and help (or who you could go visit for help). If that doesn’t work out, you can send me a Private Message (check the forum FAQ if you don’t know how) and I’ll set aside some time this weekend to work with you remotely.
As soon as you get to your regional next Thursday (after the inspector has come by and signed off on you getting the robot unbagged, and most of the teams have made it to their pits), go to the Pit Admin desk and ask the Pit Announcer to say “Team 3417 needs Labview help”. That should get you experienced people to help troubleshoot whatever you come up with between now and then, since you won’t be able to test it with the robot in the bag.
Don’t panic. Getting you rolling shouldn’t be all that bad. Vision may be a bit of a stretch, but getting you to some degree of functional is very possible.
I plan to be in San Antonio on Thursday, and I know a bit about LabVIEW.
Watch the videos and look at the sample code and examples. Ask questions on the LV forum, and I’ll be your tutor – if you need me.
In DC a few years ago, the Puerto Rico team had to build a replacement bot due to customs issues. Their programmer was a few thousand miles away as well. The team captain and I talked about what they wanted, then he programmed the robot as I pointed out where things are in the palettes. Twenty minutes later we had code that was waiting for the electrical to be finished. His English improved, my Spanish improved, and it was a very memorable experience.
Thanks for all the help so far guys! I’ve been using the basic tutorials on the Labview program so far and I pretty much copied and pasted the joystick refrence on Team358.org’s site twice so that I could have two different joysticks. (left and right) I put the parts from the three different VI’s in a picture so you could tell me if I set the up correctly:
Why are you programming the robot now? Are you the team captain and are taking charge of the role? Do you have someone else currently learning with you and helping? Do you have the time with homework, etc., to do this? I ask because we don’t want to make the situation worse by letting you to get burned out.
How much of your robot’s capabilities are you planning to program? Do you just want to get a rolling robot and some basic functions? What mechanisms does your robot have? I think we would all suggest to try not to program every advanced thing on your robot, which will be too hard with your time and experience. Only do what you really believe you can manage.
Looks like you’ve got a great start. Yes, team358’s website looks great, it’s the best one I’ve ever seen, they’ve compiled the links to the best resources.
Be aware that programming is another big area of the robot and can get tricky. Be prepared and willing to research and have some dedication to the task.
If what you want is for the speeds of each of the two motors to be controlled by the throttle on a different joystick, then this looks correct. If you’d like them to go the same speed, you could wire them both to a single joystick throttle instead, which might be easier for the driver(s) to deal with.
Yeah, the idea is that the two different sliders will control the speed of the two different motors to allow for variation of speed and control. I just programmed it so that the trigger on the right joystick. (number one) would fire a solonoid and upon release, cause the solonoid to come back. Did i do that correctly?
The Solenoid Set function’s value input expects an enumerated value of Off, On, Forward, or Reverse. Those are mapped to integers 0-3, respectively. If you provide a boolean input, a single solenoid is supposed treat a false as Off and a true as On. I don’t know if it would work right for a double solenoid. It’s likely that you’ll see the solenoid engaged as both forward and reverse at the same time, leading to an indeterminate state when the button is released.
The typical way to control a double solenoid from a button is to use a case block controlled by the button boolean value. In the true case, set the solenoid Forward, and in the false case set it Reverse. You can also use a Select (found in the Comparison subpalette) to choose between a Forward and a Reverse constant to feed to the Solenoid Set value.
First, disconnect the boolean from the solenoid set. Then hover over the port it was connected to. You will see that it is blue indicating either an integer or enum value is expected. Right click on this, and select create -> constant. This will make you an enum with the right values in it. Copy this so that you have two of them.
Now, use a Select from the comparisons palette (row three, icon 3 - looks like a big triangle with a ?, T, and F). Feed your button into the S port of that, wire one of the enums into each of the T and F ports, and set the value of the dropdowns to Forward and Reverse (in the appropriate places). Wire the output to the Solenoid Set.