Sign in:

Tutorial #4: Blinky Remix

Instructions:

  1. In this tutorial you will be creating a new program for the Blinky robot you built in Tutorial #3. If you already have a working robot from Tutorial #3 proceed to the next step. Otherwise, follow the on-screen instructions to complete your robot.
  2. Click the button to download the cubelets_tutorial_4.cubelet lesson file.

  3. Power on your robot. Click the connection icon and complete the Bluetooth pairing process.
  4. To begin, you’ll need to load the “cubelets_tutorial_4.cubelet” file. Click the load icon in the toolbar. Then follow the system dialogue to select the proper file.

    Loading a .cubelet file.

  5. In this tutorial we are going to reprogram a flashlight so it blinks on at 50% brightness for 5.25 seconds and off for 3.5 seconds.
  6. Change the variables in the program so that your Flashlight Cubelet blinks at 50% brightness for 5.25 seconds and off for 3.5 seconds.
    • If you need help click here for a hint.

      HINT: If we want to set the value to 5.25 seconds then we need to convert seconds into milliseconds. To do this, multiply seconds by 1000. So multiply 5.25 seconds by 1000 for 5250 milliseconds. To set the Flashlight value to 50% select a number that is about halfway between 0 and 255. We suggest 127. To convert 3.5 milliseconds into seconds multiply by 1000. To turn the Flashlight off set the actuator value to 0.

  7. Let’s see if you built a program that works! Select your Flashlight Cubelet from the Block Map and click “Program Selected Cubelet.”
  8. After Cubelets Blockly has finished updating your Cubelet you should see a new blinking Flashlight. When you’re ready to move to the next tutorial, select your Flashlight from the block map and click “Restore Default Program.”