Introduction: LittleBits Arduino MacBook Air Blink Sketch

Have you tried Littlebits Arduino? It is super simple and straight forward to use.

Step 1: Pull the Littlebits Modules Out of the Kit for the Blink Sketch

  1. Gather the components for the project
    1. 9V Battery + Cable
    2. Power
    3. Bargraph
    4. Arduino
    5. MacBook Air

Step 2: Connect the Littlebits

Place battery first ,then attach it to the middle of the LittileBit Aruduino piece. After, add the bargraph to the opposite side of the Arduino. Take the microUSB cable that came with the LittleBit Arduino and connect it to the LittleBit Arduino coonector like in the picture. Connect the full size USB connector to an open USB port on the MacBook Air.

Step 3: Turn on the Power to the Littlebits Arduino Setup

After the LittleBits Arduino setup is complete, be sure to turn on the power to the setup as illustrated in the picture.

Step 4: Look for the Arduino Program on Your Computer

Look for your program for aruduino on your desktop .Then, open it. The Arduino program and install instructions can be found here. Arduino Software

Step 5: Leonardo

First ,click ''Tools" to get your tool bar .To get the right arduino system click board .Then find Arduino Leonadro and click it .It tells the computer if it's littlebits or something else. According to the Littlebits documentation, the Arduino Littebit is compatible the Arduino Leonardo board.

Step 6: Serial Port

Go again to "Tools" and click "Serial Port". This is so the computer knows how to communicate to the Littlebits Arduino. Select the "/dev/tty.usbmodem411". It may be slightly different for your Mac.

Step 7: Select the Blink Sketch

The Blink Sketch is a basic program that makes the Littlebits Arduino turn the LEDs on the Bargraph blink ON and OFF. Click "File" then "Examples" there you'll find the "Basics" click in then click "Blink" for this Sketch.

Step 8: Set the LED Variable to 5

When you get the example MAKE SURE TO CHANGE LED VARIABLE TO 5 OR ELSE IT WON'T WORK!! The original Blink Sketch is set to 13. For the LittleBits Arduino, it should be changed to 5. NOTE: There is a swtich below the D5 writing on the Arduino labeled "analog" or "pwm". Be sure your switch is set to PWM. My Arduino was set to "analog" when I first took it out of the box and it took me 30 minutes to figure out it was the switch that was set to the wrong position.

Step 9: Compile and Download the Sketch

To download to Arduino click "Arrow" as shown in the picture to compile and download the Blink Sketch.You'll see a yellow lights blinking on the Littlebits Arduino for a few seconds - this means it's downloading the Blink Sketch.

Step 10: Program Behavior When Running

It will start blinking with all of the lights every second between no LEDs and all the LEDs on the Bargraph module being lit up. You can modify it to change speed of the blinking light .

Step 11: Modify the Duration of LED Blinking

To modify to a different Blinking rate - look at the example there you'll see two 1000's they each mean a ONE second .You can change it lower or higher and in a fraction of a second. For example I changed the values to 500. That will make the Bargraph blink every half a second when recompiled and downloaded to the Arduino.

Step 12: ENJOY!!

All I can say is "GOOD LUCK BLINKING!!":) Look for more LittleBits Arduino Instructables from me in the future as I get through my LittleBits Arduino kit!

Tech Contest

Participated in the
Tech Contest