Skip to main content

Multitasking Snapshot

Create a coordinate system on the VIQC Virtual Skills Field with the initial position of the Hero Bot as the origin(0,0). Create an algorithm to use [Drive for] and [Turn to heading] blocks, the Arm Motor, the Intake Motor, and the Bumper Switch Sensor to drive the Hero Bot to specific positions to remove all the Discs from a blue Dispenser, pick up and launch three Discs to the 4-Point Goal Zone as fast as possible!

  • Select the VIQC Virtual Skills - Slapshot Playground.
  • Drive the Hero Bot to the position located at (60, 290), turn to the blue Dispenser, and remove all the Discs from it.
    • Use the and don’t wait feature of the spin ArmMotor block to enable the Hero Bot to drive to the next position while lowering the Arm after knocking the Dispenser.
  • Drive the Hero Bot to the position located at (1000, 175).
  • Code the Hero Bot to pick up and launch three Discs to the 4-Point Goal Zone.
    • Create an algorithm using the broadcast event to trigger the intake process to enable the Hero Bot to drive while spinning the Intake Motor until a Disc has been loaded.
    • Create an algorithm using a variable to coordinate the Drivetrain and the Intake Motor behaviors to avoid mutual interference between two Disc launch processes.
    • Drive the Hero Bot reverse to the position located at (800, 300), pick up a Disc, and launch it to the 4-Point Goal Zone.
    • Drive the Hero Bot reverse to the position located at (900, 500), pick up a Disc, and launch it to the 4-Point Goal Zone.
    • Drive the Hero Bot reverse to the position located at (800, 575), pick up a Disc, and launch it to the 4-Point Goal Zone.

Helpful Hints

  • The and don’t wait feature of the spin ArmMotor block will cause other blocks to continue running while the Arm Motor spins. To use this feature, select the arrow to expand and don't wait.
    Arm motor reverse 90 degrees and don't wait block
    • Matching Python command:
      Arm motor reverse 90 degrees and don't wait block
  • Use the broadcast block from the Events category to trigger the intake process.
    Broadcast check block
    • Matching Python command:
      Broadcast check Python command
  • Use the when I receive block from the Events category to run the attached stack of blocks when the triggered message is received.
    When I receive check block
    • Matching Python command:
      On event check Python command