Answer Key: Decisions, Decisions_Unit_Level

Answer Key: Unit Quiz

  1. The Switch-Loop allows the program to effectively check two sensors (one controlling the switch, the other controlling the loop) at the same time.  So both the obstacle detection with the ultrasonic sensor and the distance traveled with the rotation sensor and be checked simultaneously.
  2. The Loop exit control could be controlled by time (number of seconds, or forever) or any other sensor.
  3. The Switch block is controlled by the Color Sensor.  If the sensor sees "not Black" the tribot turns toward the line, and if the sensor sees “Black” the tribot turns off the line.
  4. The program runs one block at a time. By the time it checks to see if there is an obstacle in the path, it might have already run over the obstacle. It is not constantly checking for obstacles.
  5. Ziffle’s program will not detect obstacles constantly.  Since the Move block on the lower branch is set to move for a fixed number of rotations, the robot will move forward this set amount before it checks the Ultrasonic Sensor again.  For continuous obstacle detection, Ziffle needs to set the lower Move block to "On" for duration.
  6. The program only run for a few milliseconds, since the loop will only run 10 times and then stop, regardless of the light level.
  7. The True (Upper) Move Steering block Steering control needs to be set to steer the tribot slightly to the left and the False (Lower) Move Steering block Steering Control needs to be set to steer the tribot slightly to the right. Also, both Move Steering blocks need to be set to 'ON'.
  8. Running more than 1 program at the same time.
  9. Use Mutlitasking to run each of these smaller programs in parallel branches
  10. Ziffle needs to specify a different motor in one of his programs so the branches don't conflict. He uses motor B in both branches.
  11. The Loop Interrupt in the second program needs to specify the number/name of the program it wants to interrupt. Both values should be 01. The Loop Interrupt value is set to 02.
  12.  A custom block representing 1 or more regular blocks
  13. Any of the following:
     a) Allowing a sequence of blocks to be easily reused
     b) Saving space on-screen
     c) Combining multiple blocks into a single behavior


    Turquoise pallette


  15. Should look something like this:


                  Loop 10 X's

                   If light is less than threshold 50 then turn off motors

                   If light is greater than threshold 50 then run motors B&C

                 End Loop