Recently we decided to test the robot using the official competition template given by IFI. For some reason our neither our autonomous mode nor our operator control mode worked. When we switched on the controller, the robot just sat still.
That seems strange. It’s not commented out or something when you copied it? Maybe it needs to be in an infinite loop? Have you tried seeing if something simple like go forward works?
We are having similar issues. While debugging in RobotC and running with (autonomousTest) mode, it seems like the code gets stuck in this Loop.
while (!bIfiAutonomousPhase)
{
if (nVexRCReceiveState == 0) // the transmitter is powered off!!
allmotorsoff();
wait1Msec(25);
}
We are setting our mode by this format in (Vex_Competition_Includes.c)
#pragma competitionControl(autonomousTest)
competitionControl takes on four different values (OFF, Competition, autonomousTest, UserTest). When that pragma is set to Competition, it requires the field controller to execute the commands. If that pragma is set to autonomousTest, it will automatically run the autonomous routine without any field controllers.
However, our controller is still getting stuck in this loop with “bIfiAutonomousPhase” never getting changed and I don’t quite understand how “bIfiAutonomousPhase” gets set
I tested everything tonight with & without the Field Electronics and it works great.
Use the RobotC Template in Appendix D Programming guide and READ the pdf programming guide in RobotC .
Just make sure before you download any code you put the proper firmware.
Load Master Firmware
a. Select (Window->Menu Level->Check Expert Mode)
b. Select (Robot->Download IFI Master CPU Firmware)
c. select VEX_MASTER_V7.bin
Load User Firmware
a. Select (Robot->Download Firmware)
b. Select VEX_VM0752.hex (or higher)
Can you explain what you mean by Appendix D of the programming guide? I see a programming guide link on the Vex Robotics download page, but it is a one page PDF with no appendices. Also, you refer to the PDF programming guide in RobotC, but I see no such thing–neither on the installation disk nor within the application. Where is this? I’ve been pulling what little hair I have out trying to find documentation so we can do some coding.
I appreciate your help, but I’m still not on the same page. The only Appendix D I see for download anywhere is in the VEX 2008 Inventor’s Guide at http://www.vexrobotics.com/vex-robotics-downloads.shtml. It’s the “Control Configurations” section. This doesn’t appear to be what you are talking about, though, since “Autonomous Files->RobotC” sounds like some kind of pulldown menu within something, and that downloadable PDF file from the website above has no such menus that I can see. Nor do I see any mention of ROBOTC_140_VEX_Competition_Support.pdf in that document. I even did a Google search on “ROBOTC_140_VEX_Competition_Support.pdf,” and I just get this thread back as the only hit.
From where, exactly, are you downloading this Appendix D?
This appendix is your “one stop shop” for all the files and instructions you should need for programming an Elevation competition robot. We try to put all the resources in one place…