gwhs / FalconRecharged2021

First Robotics 2021 Infinite recharge source code for team 5507 Robotic Eagles, Washington High School, San Francisco CA
Other
1 stars 4 forks source link

time of flight isn’t working #8

Closed anton-levin closed 3 years ago

anton-levin commented 3 years ago

not sure if this is software but time of flight wasn’t working, it’d be nice to have a sanity check for software before having to dig through the wiring

alevin commented 3 years ago

Update: Before using the auto shoot, the automatic conveyor works and spaces balls out. However, after using the auto shoot, the the conveyor belt doesn't automatically space the balls out.

jhajel commented 3 years ago

I am looking at the code. There is a command that turns off the conveyor while Autoshoot is active. It is supposed to turn on after the autoshoot. I can't see why it doesn't work. May need some help debugging.

jhajel commented 3 years ago

We added a print statement. If we are disabling the sensor and not reenabling, it will print "Checking if conveyor works: true". Please test this like this.

  1. intake a PC and record what the log says.
  2. autoshoot (no need to have a PC to shoot)
  3. try to intake again and record what the log says.
anton-levin commented 3 years ago
  1. Reads False, then when PC hits the the TOF, it reads true, and goes back to false.
  2. auto shot with no PC
  3. Intaking read true again

1b. intake PC, reads true when PC hits TOF 2b, auto shoot with PC 3b. Intaking PC reads true when PC hits TOF

By the looks of it, issue seems to be resolved. As a precaution, we should check if the galactic search will have the same bug. We've only been testing one PC at a time so we don't know if it'll do the same thing with multiple.

jhajel commented 3 years ago

Seems like it is working. Closing.