Getting Started

Steps 1 2 3 4 5 6 7
Steps 1 2 3 4 5
Steps 1 2 3 4 5 6 7 8 9 10 11

Getting Started

Python is a great text-based language for beginning programmers because it is powerful but easy to learn and use. To use Python with the Hummingbird Bit on a Mac or Windows computer, you must connect to the Hummingbird Bit with the BlueBird Connector using Bluetooth or a USB cord. For Windows or older Macs without Bluetooth, you will need a Bluetooth dongle to use Hummingbird Bit via Bluetooth.

You can use any offline Python editor. If you don’t have a favorite, we suggest trying IDLE, which is an editor that is installed on your computer with Python.

Insert a micro:bit into your Hummingbird Bit Controller (you might need to push a little harder than you think!), and connect it to the computer with the USB cord. The Hummingbird also needs a source of power, so connect it to the battery pack or AC power adapter.

Download this file and drag it onto the micro:bit. Your device should start to flash three letters on its display.

Download Hex File

If you will be connnecting via Bluetooth, remove the USB cord. You won’t need it to use Snap! If necessary, insert the bluetooth dongle into a USB port.

If you will be connecting with the USB cord, just leave the Hummingbird Bit connected to your computer.

Open the BlueBird Connector. If you are connecting with the USB cord, it will connect automatically to your Hummingbird.

If you are using Bluetooth, you may see one robot or many, depending on how many are nearby. Click on the name of the robot that matches the initials on your device.

You will hear a sound as your device connects, and the initials will stop flashing on the device. The name of your robot should appear under Connected.

Now you are ready to start programming in Python! You can minimize the BlueBird Connector, but you should leave it open the entire time that you are using the Bit. If at any point you have trouble with your robot, you should come back to the BlueBird Connector to check your bluetooth connection. You can also check your battery level in the BlueBird Connector.

Programming

This section will show you how to start using Python with the Hummingbird Bit. Start by installing Python. You can use any offline Python editor with the Hummingbird on Mac/Windows. The screenshots here will show IDLE as an example; IDLE is an editor that is installed on your computer with Python.

 

Download the BirdBrain Python library. This folder contains the main library (BirdBrain.py) and a test file (HummingbirdTest.py).

To test that everything is working properly, connect a single-color LED to port 1 of the Hummingbird.

Then open HummingbirdTest.py in your IDE. To run the test program in IDLE, choose Run/Run Module. The single-color LED should blink 10 times.

Now you are ready to start writing your own Python programs with the Hummingbird! These lessons will help you to get started, and this reference summarizes the functions that are available in the Hummingbird Python library.

Make sure to store your programs in the BirdBrainPython folder so that they can find the BirdBrain library (BirdBrain.py). If you wish to store programs in a different folder, just make a copy of BirdBrain.py and move it to the desired folder.

Getting Started

Python is a great text-based language for beginning programmers because it is powerful but easy to learn and use. You can use Python in the Chrome browser using our BirdBrain Brython web app. Your Chromebook must have Bluetooth in order to connect to the Hummingbird Bit.

Insert a micro:bit into your Hummingbird Bit Controller (you might need to push a little harder than you think!), and connect it to the computer with the USB cord. The Hummingbird also needs a source of power, so connect it to the battery pack or AC power adapter.

Download this file and drag it onto the micro:bit. Your device should start to flash three letters on its display.

Download Hex File

You will use a browser-based web app to program the Finch with Brython, a browser-based version of Python. Go to brython.birdbraintechnologies.com.

Click Find Robots. You will see a list of devices that start with FN (Finch), BB (Hummingbird), or MB (micro:bit). You may see one robot or many, depending on how many are nearby. If you don’t know which robot is yours, write down the first device name on the list, i.e. BB5AE67. Then click that device. Once you know which Finch is connected, use masking tape to label it with the device name you wrote down. This will help you connect to the correct device in the future.

You will hear a sound as the Hummingbird connects, and the initials will stop flashing on the micro:bit. Once you have connected to a Hummingbird, the name of your robot will appear on the screen, along with a battery indicator. Brython will load automatically.

If you become disconnected while programming your Hummingbird, click the expand button to see the Find Robots button and reconnect.

You can use Brython online or offline. To use Brython offline with the Finch, install it on your Chromebook using the orange install button.

To test that everything is working properly, connect a single-color LED to port 1 of the Hummingbird.

Brython loads with a sample program. To run the program on your Finch, click the play button. There are also buttons to stop the program and upload or download Brython code.

Now you are ready to start writing your own Python programs with the Hummingbird! These lessons will help you to get started, and this reference summarizes the functions that are available in the Hummingbird Python library.