Team2168 / 2017_Main_Robot

Code for the 2017 FRC Season - "Steamworks"
0 stars 1 forks source link

Develop code for the elevator #17

Closed jcorcoran closed 7 years ago

jcorcoran commented 7 years ago

This is a vertical roller system that takes balls from the conveyor and brings them up into the indexer, and ultimately the shooter wheel.

  1. Create a new subsystem
  2. Create two new commands, one for controlling the elevator with a constant speed, one for controlling it with the joystick.

Take a look at the indexer code (and its associated commands) for an example: https://github.com/Team2168/2017_Main_Robot/blob/develop/src/org/team2168/subsystems/ShooterIndexer.java

@davidm2556 post here when you have code committed for review or if you have any questions.

davidm2556 commented 7 years ago

Where is the Spark Motor Controller on the robotmap? Or where should I declare it?

jcorcoran commented 7 years ago

Add a new final variable in the PWM section. It will just be an integer value for the channel its plugged into. Then in the subsystem you will create an instance of a spark motor controller, and in the subsystem constructor you use the channel number defined in robot map.

Take a look at the ball intake subsystem in the develop branch for an example

davidm2556 commented 7 years ago

What buttons/sticks should be assigned to which commands?Also are they both on the operator controller? Also should there be elevator parameters?

jcorcoran commented 7 years ago

Not sure yet. It may very well end up being tied into a command group that drives a number of rollers all at once. So just pick something for now. We need to work out a controls layout still

davidm2556 commented 7 years ago

Committed :)

jcorcoran commented 7 years ago

@davidm2556 Doesn't look like you pushed your code up to the internet. Committing saves your changes out to a local copy of the repo on your computer. "Pushing" uploads those commits to the repo in the clouds github

After pushing, check here for your changes: https://github.com/Team2168/2017_Main_Robot/network If you don't see it it didn't work.

davidm2556 commented 7 years ago

Im getting an error when trying to commit and push, it reads,"error: GH006: Protected branch update failed for refs/heads/develop. error: You're not authorized to push to this branch. Visit https://help.github.com/articles/about-protected-branches/ for more information."

jcorcoran commented 7 years ago

You're trying to push to the remote branch called "develop".

You aren't allowed to push to that branch. You can push to a new branch. You just need to give it a name other than " develop" or "master"

If you are using egit in eclipse I think you can do this by right clicking the project in the package explorer. Team > advanced > rename branch. The select your local branch (probably called develop) and click the rename button. Then name it something that has to do with the work you did (name of subsystem). I don't use egit, so not sure if that will work or not.

The next time you start working on a new feature, you should always pull from the giyhub repo to get your local files up to date, then make a new local branch with a unique name. Then when you go to push everything will just work

davidm2556 commented 7 years ago

I think it should be all good now.

jcorcoran commented 7 years ago

closed by https://github.com/Team2168/2017_Main_Robot/commit/875fd323efd7f94a3bfb3da6f894bffeeee07236