Announcement

Collapse
No announcement yet.

Autonomous to Teleop

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Autonomous to Teleop

    Our robot this year was designed to be a "dumper". Two of our 3 autonomous routines were designed to use an encoder to measure distance, then once that distance had been met, to execute our "dump" routine. This worked fine if the robot didn't hit the fender. Unfortunately, the kids sometimes mis-aligned the robot and it would hit the fender and not reach the magic encoder value. When the field system transitioned from autonomous to teleop, our robot received a "No Robot Code" message, and our only solution at that point was to reboot the cRIO, which took about a minute of our teleop time. After having that happen 3-4 times on Friday, we modified our autonomous to a "do nothing" mode.

    My question centers around the switch from autonomous to teleop. Is our observation that autonomous wasn't fully completed when the switch to teleop occurred the reason behind our "No Robot Code" error? Our assumption was that the teleop.vi would take off regardless of the end state of autonomous, once the field system indicated the switch. I have attached our autonomous vi for your viewing pleasure.
    Attached Files

  • #2
    Re: Autonomous to Teleop

    In general the way you described the transition is the way it should work for LabVIEW, regardless of what you are doing in your Autonomous Independent VI when the field/DS state transitions, the Autonomous Independent VI should be terminated and execution should move to the Teleop VI.

    I won't have a chance to really take a look at your attached VI until at least after Championships, but were you using CAN by any chance?
    FIRST®
    FRC Robotics Engineer

    Comment


    • #3
      Re: Autonomous to Teleop

      Yes, we were using CAN.

      Comment


      • #4
        Re: Autonomous to Teleop

        The issue you ran into is specific to teams using CAN with LabVIEW at the end of the Autonomous period from the Autonomous Independent VI. See the last entry on the NI Know Issues list here. Your code would actually run a single call of the Teleop VI, but would lock up on the first call to the motor that was being accessed when autonomous ended.
        FIRST®
        FRC Robotics Engineer

        Comment


        • #5
          Re: Autonomous to Teleop

          Thank you for your response, the problem was driving me crazy!

          Comment

          Working...
          X