• Set up your computer to teach your  Robot

    Bluetooth pairing your robot with your computer and connecting within SNAP

    broken image

    Install SNAP

    SNAP is a re-write of Scratch with extra capabilities

    SNAP is a drag and drop programming language very similar to Scratch written by people at UC Berkley http://snap.berkeley.edu/. SNAP allows you to create, import and export custom blocks. There is a special version of Scratch that works with Arduino called SNAP4Arduino (S4A). You can get S4A here http://s4a.cat/snap/.

    broken image

    Bluetooth Hardware

    Does your computer have Bluetooth?

    If your computer doesn't have Bluetooth built-in you will need an external Bluetooth dongle that is compatible with Bluetooth V2 (some V4 dongles are not backwards compatible).

     

    Dual mode Bluetooth dongles based on CSRv4 are cheap, compatible, and work OK.

     

    Often cheap CSR dongles come with identical MAC numbers: they will conflict is used at the same time. You can change the MAC numbers of the CSR dongles using a bootable Linux USB and these instructions: http://blog.petrilopia.net/linux/change-your-bluetooth-device-mac-address/

    broken image

    Is your robot listening?

    Get the right firmware

    S4A requires that your Arduino chip has been loaded with the Firmata program to listen for incoming commands. If your robot is doing the SOS blink when it first boots up, then it has the program MBTRv7 on it. You need to use the Arduino IDE to install Standard Firmata using the USB connection. Hopefully you were supplied with an Arduino chip with a hybrid version and don't have to worry about this.

    broken image

    Testing Firmata

    Check your robot is ready for S4A

    Turn your robot on and connect using Blueterm+ on an Android phone.  After connecting you should see the reply "Standard Firmata'.

     

    Note: you also need a Bluetooth chip that has been reprogrammed to talk to Firmata.  When you look for your robot in Bluetooth it should have a name like 'snapBot-9387'.

  • SNAP4Arduino with OSX

    Pairing and connecting to your robot

    Almost ready!

    This video shows you how to pair your computer with the robot and then from within S4A, connect to your robot.

  • SNAP4Arduino with Windows 7

    Paring and connecting to your robot

    broken image

    Get started

    Go to the 'Devices and printers'

    broken image

    Is Bluetooth on?

    If there is no Bluetooth icon in the corner, right click on your laptop and go to Bluetooth settings to turn on Bluetooth.

    broken image

    Add a Bluetooth device

    Click on the 'Add a device' button

    broken image

    Find your robot

    Your computer will scan for Bluetooth devices. If your robot is turned on and the Bluetooth LED is blinking fast,  your robot should appear in the box. It takes 5-10 seconds to pick up the name of your robot. Until then it just says 'other'.

    broken image

    Correct Bluetooth speed?

    When your computer gets the name of your robot it should be something-like 'snapbot-034'. If it says 'HC-05' then the Bluetooth connection speed will not work with S4A. Contact Mr. Elliott to fix this problem.

     

    Click once on the snapbot and then click next.

    broken image

    Pair with PIN

    Click on the button that says "Enter the device's pairing code' and then click next.

    broken image

    Enter the pin code

    The default pin code for our robots (and many Bluetooth devices) is 1234

    broken image

    Not quite there yet!

    Even though your computer has paired with the robot it still needs to install drivers. The little black clock circle means that the computer is still searching for drivers. This can take several minutes

    broken image

    Ready to Go!

    Now your robot is ready to control using S4A

    broken image

    Open S4A

    Right-click on the Snap4Arduino icon and choose open

    broken image

    Connect to robot

    Right-click on the sprite and choose connect to Arduino

    broken image

    Which one?

    Which one of the COM ports is my robot on? Look to the next two slides to find out.

    broken image

    Check properties

    Go back to 'Devices and printers', right-click on your robot, and choose properties.

    broken image

    Look for COM

    The standard Serial over Bluetooth will have the number of the COM port: something like COM32

     

    Now go back to S4A and choose COM32

    broken image

    Select a port

    Select the port number from the previous step

    broken image

    Almost there!

    S4A is searching for your robot over Bluetooth

    broken image

    You are ready!

    Your computer has connected to your robot and you are ready to write s4A programs.

  • Testing your set up

    Blink the LED on your Arduino

    broken image

    A simple program

    Make this simple program to test your setup. When you push the space bar (or click on the yellow block at the top of the stack). More details on programming your robot can be found at this URL: http://teachmybot.strikingly.com/

  • Contact Us!

    To get help building, programming or hosting a workshop:

  • About THE tKcBOT

    'Standing on the shoulders of giants.'

    Inspiration

    Starting from the UNSW CS4HS bot, many people have given this project a inspirational push, encouraging feedback, opened doors of opportunity, or sustained the project through their enthusiastic participation. Thanks to Susan, BW, Phillip, Adele, Ruth, Stuart and many others.

    Technology

    Thanks to the explosion of information available on the Internet it is possible to create a robot with amazing capabilities just by bringing together pieces of existing technology with very little original technology.  My role has been to marry the inspiration with the the technology available, and to use my experience as a teacher to construct the learning materials to help bring this amazing technology to children. Thanks also, to the helpful people (especially Leo) at Hobart Hackerspace, who have experience and expertise way beyond mine.