setting autonomous mode

is it allowed to have something like a switch or jumpers on your OI to set your autonomous mode or does it have to be done on the robot? if not how do we choose the autonomous mode we want?

thanks in advance
allison

Somebody will have to correct me if I’m wrong, but the way the code is, I believe that you read the inputs from the OI once before you enter autonomous mode. However, I’m not sure if the OI will actually send anything to the robot.

The safe way is to have switches on the robot that you set to indicate which autonomous mode you want. Your program then reads these and figures out what you want it to do from them.

We’ve got a rotary switch on our OI that selects from the menu of autonomous options. The OI inputs do get passed to the robot during the disabled period *before * autonomous mode begins, so you can read the mode selection and store it somewhere to be used during
autonomous mode. The OI won’t be active while autonomous mode is underway – default values will be transmitted to the robot – so you’ll have to make sure not to accidentally try to read the mode selection after the match begins.

I read it when Default_Routine() is ran. Then I store it to a variable and use that in User_Autonomous_Code().

We have three binary switches on the robot to select one of the 8 auto modes. Its worked well so far, but it took a while to explain it to the drivers that set the robot before a round.

We do the same thing. What we do is make a sheet your coach (or drivers) can look at which has the program numbers in decimel, along with the names. Then next to the decemel number indicate which swithes need to be on or off to input that decimel number.

i was wondering if anyone had any sucess with reading switches off the OI after the match had started and before autonomus was enabled?

team update 13 said the OI values are read when the bot is diabled, so you should be able to send them from there

I dont think we have enough switches left free on the OI - we have 4 switches onthe bot tied to the rc_dig_inputs to tell it what to do in auton mode

the most important one you MUST have is a disable - sooner or later you are going to want to sit out auton mode.

well currently were only using 2 joystics… that leaves 8 switches open, thats like 64 programs or watever. so i could have done it that way. but there are two big red togle switches on the robot that are clearly labled “disable/enable autonomus” and “knock ball/dont knock ball”. it makes it pretty easy. we have 4 digital IOs on the rc left; with just 2 banner sensors. next year i hope they give us more inputs!

2^8 = 256 :slight_smile:

lol shush im writing a history paper and CDing at the same time. not thinking using the right part of my brain :stuck_out_tongue: