Welcome to KittenBot documentation!

Welcome to the Coding & STEM Sharing of KittenBot, here you will find all the knowledge and information related to KittenBot’s products, including product details, specifications, use case sharing and coding tutorials.

Meowbit

Information about Meowbit and related tutorials.

Meowbit Introductions

_images/1.jpeg

Most teenagers nowadays like playing video games, in order to make them more intereseted in coding, Kittenbot has developed Meowbit, a handheld game console designed for MakeCode Arcade. Students can use MakeCode Arcade to create their own games and then play them on the Meowbit, allowing everyone to experience game design, truly realizing the concept of STEAM education.

In addition, Meowbit can also act as a control board for robots as it has the same edge connectors as the Micro:bit, making it compatible with Kittenbot’s expansion boards. Thus, the flexibility and possibilities with Meowbit can be further increased with expansion boards!

Target Audiences

  • Schools and Institutes

  • Users interested in Game Design

Special Features

  • Supports Graphical Programming, suitable for beginners.

  • Combing Coding with Art, realizing concept of STEAM.

  • High flexibility, can be used as a game console or as a robot controller.

  • Multiple sensors have been built-in, allowing for more possibilities in coding.

  • Supports multiple coding platform, including MakeCode Arcade and Kittenblock.

  • Nostalgic and adorable graphics.

  • Highly portable, allows you to play you games anywhere.

  • Supports Chinese Unicode, allowing you to display Chinese characters.

Specifications

  • Dimensions: 52x76x12mm

  • Weight: 42g

  • CPU: STM32F401RET6,32-bit ARM Cortex M4

  • Power Inpit: 5V USB, 3.7~4.2V Battery Box

  • Screen: TFT Full-Color

  • Resolution: 160x128

  • Screen Size: 1.8 inches

  • IO Pins: 20PIN(Same as Microbit)

Onboard Devices:

  • Programmable Buttons x6

  • Buzzer x1

  • Programmable LEDs x2

  • Light Intensity Sensor x1

  • Temperature Sensor x1

  • Accelerometer x1

  • SD Card Slotx1

  • JacDac Connectorx1

Breakdown Diagram

_images/2.png

1: Power Indicator

2: Light Sensor

3: Power Switch

4: Programmable LEDs x2

5: Reset Button

6: DFU/Menu Button

7: TFT Screen

8: Temperature Sensor

9: Programmable D-Pad

10: Programmable Buzzer

11: Programmable A and B Buttons

12: Edge Connectors

_images/3.png

13:USB Port

14:SD Card Slot

15:JacDac Connector

16: 6-Axis Accelerometer

17:3.7V Battery JST Connector

18: Main Chip

19: Unicode Chipset

20: Name Plate

Supported Programming Platforms:

  • Microsoft MakeCode Arcade

  • Kittenblock

Detailed Pinouts:

_images/41.png

Videos:

Meowbit Introduction:

_images/6.png

Sharing by Overseas User:

_images/5.png

Meowbit Usage Sharing:

_images/7.png

MeowBit System Operations

This page will explain how to use the system operations on the MeowBit, including entering uploading mode, opening options or firmware updates.

Entering Upload Mode

Only in Upload Mode can the games be uploaded to MeowBit.

Method 1

Connect the MeowBit to a computer using an USB Cable.

Hold the A button on the MeowBit and switch the power on.

The Meowbit is in Upload Mode when this screen is shown.

_images/f4_1.gif

Method 2

Connect the MeowBit to a computer using an USB Cable.

Switch the power on.

Hold the A button and press the reset button.

The Meowbit is in Upload Mode when this screen is shown.

_images/f4_2.gif

Opening Options Menu

We can open up the settings menu to change settings such as screen brightness or volume.

Method 1

Press the Options button.

Use the D-Pad to select different settings and use button A to confirm.

_images/menu1.gif

Updating the Firmware

Firmware v2.8.0 Download

Enter Upload Mode first.

_images/fw1.jpeg

Put the files onto the device called Arcade-F4. After updating, press the reset button to finish the update.

_images/fw2.jpeg

Meowbit MakeCode Coding QuickStart

MakeCode Arcade is a programming platform for making games developed by Microsoft, it is also the main programming platform for Meowbit.

Meowbit has been officially approved by Microsoft for MakeCode Arcade.

MakeCode Arcade Coding

_images/acbanner1.png

Connect your Meowbit to the computer.
Enter Upload Mode
  • Hold A and power on.

_images/kb1.jpg

A device called Arcade-F4 would appear on your computer.

_images/kb2.png

Open Makecode Arcade
Create a Project

_images/arcade2_1.png

Coding Interface

_images/arcade3_1.png

Select Meowbit from Hardware Menu

_images/arcade4_1.png

_images/arcade5_1.png

Code your game
This program is for demonstration only.

_images/arcade7_1.png

Download the game onto your Meowbit.

_images/arcade8_1.png

_images/arcade6.png

MeowBit HourOfCode Tutorials

We are delighted to have the permission of Mr. Kwok from Tin Ka Ping Secondary School to show his tutorials of making games on MakeCode Arcade.

In this 2-session tutorial, you will learn to create your own game from scratch.

MakeCode Arcade

_images/acbanner1.png

Your First Meowbit Game (Video is in Chinese)

Please start watching from the 118 minutes mark, the session lasts approximately 1 hour.

_images/hoc1.png

Your Second Meowbit Game (Video is in Chinese)

The session lasts approximately 1 hour.

_images/hoc2.png

Credits

Mr. Kwok’s Classroom:

https://www.facebook.com/kwoksirclassroom/

Hong Kong InnoSpace HourOfCode:

https://www.facebook.com/watch/107807216571940/728249611306184

Meowbit Kittenblock Coding Quickstart

Kittenblock is a programming platform designed for teenagers, it is another major programming platform for Meowbit.

mainBoard/functional_module/PWmodules/images/kbbanner.png

Connect Meowbit to Kittenblock

Establishing a connection between Meowbit and Kittenblock is required to program Meowbit from Kittenblock.

1. Connect Meowbit to computer and enter upload mode.
  • Hold button A and turn on the power.

_images/kb1.jpg

A device called Arcade-F4 would appear.

_images/kb2.png

2. Open Kittenblock and select Meowbit from the Hardware Menu.

_images/kb3_1.png

3. Flash the firmware.

_images/kb4_1.png

_images/kb5_1.png

A device called PYBFLASH would appear.

_images/kb6.png

If the device is called USB Drive, hold down B and press reset.
4. Click the Exclamation Mark Icon and click Connect.

_images/kb7_1.png

_images/kb8_1.png

A string will be displayed on Meowbit to notify it is connected to Kittenblock.

Kittenblock Coding Tutorial

Scripts

_images/kb9_1.png

Inputs and Sensors

_images/kb10_1.png _images/kb10_2.png

Display

_images/kb11_1.png _images/kb11_2.png

Buzzer

_images/kb12_1.png

IO Pins

_images/kb13_1.png

Robotbit

_images/kb15_1.png

Neopixel

_images/kb17_1.png

Turtle

_images/kb16_1.png _images/kb16_2.png

Serial Communication

_images/kb14_1.png

MeowBit’s Light Sensor

Meowbit has a built-in light intensity sensor, allowing it to detect environment brightness.

MakeCode Arcade Coding Tutorial

_images/acbanner1.png

Load Controller Extension
Blocks for Controller Extension

_images/light2_1.png

Detecting Brightness

_images/light3_1.png

Sample Code Link

Detecting Light Intensity

_images/light4_1.png

The light intensity has a range from 0 to 255.

Sample Code Link

Kittenblock Coding Tutorial

mainBoard/functional_module/PWmodules/images/kbbanner.png

Blocks for onboard sensors

_images/kb10_1.png

Detecting Light Intensity

_images/light5_1.png

Meowbit’s Accelerometer

Meowbit has a built-in accelerometer for measuring rotation and acceleration of the device, as well as detecting different gestures.

_images/accel6.png

MakeCode Arcade Coding Tutorial

_images/acbanner1.png

Load Controller Extension
Blocks for Controller Extension

_images/light2_1.png

Detecting rotation

_images/accel1_1.png

The rotation value ranges from 0 to 1023.

Sample Code Link

Detecting gestures

_images/accel2_1.png

Sample Code Link

Kittenblock Coding Tutorial

mainBoard/functional_module/PWmodules/images/kbbanner.png

Blocks for onboard sensors

_images/kb10_1.png

Getting the acceleration

_images/accel3_1.png

Getting the rotational acceleration

_images/accel4_1.png

Getting the tilting degree

_images/accel5_1.png

_images/accel7.png _images/accel8.png

Detecting gestures

The gestures can be detected in 2 ways.

_images/accel9_1.png

_images/accel10_1.png

Meowbit’s Temperature Sensor

Meowbit has a built-in Temperature Sensor that allows it to detect the ambient temperature.

MakeCode Arcade Coding Tutorial

_images/acbanner1.png

Load Controller Extension
Blocks for Controller Extension

_images/light2_1.png

Detecting the temperature

_images/temp1_1.png

Sample Code Link

Kittenblock Coding Tutorial

mainBoard/functional_module/PWmodules/images/kbbanner.png

Blocks for onboard sensors

_images/kb10_1.png

Detecting the temperature

_images/temp2_1.png

Meowbit’s IO Pins

Meowbit has the same 20 IO Pins as the Micro:bit, you can connect different modules to use on the Meowbit.

MakeCode Arcade Coding Tutorial

_images/acbanner1.png

Load IO Pin Extension
Blocks for IO Pins
Loading the extension for Robotbit would automatically load the extension for IO pins.

_images/led2_1.png

Using the IO Pins
Reading values

_images/robotbit8_1.png

Sample Code Link

Writing Values

_images/robotbit9_1.png

Sample Code Link

Kittenblock Coding Tutorial

mainBoard/functional_module/PWmodules/images/kbbanner.png

Blocks for IO Pins

_images/kb13_1.png

Reading values

_images/pin1_1.png

Writing Values

_images/pin2_1.png

MeowBit Wireless SD Module

With the Wireless SD Module, we can use Meowbit to communicate with other devices such as Micro:bit.

_images/sd1.png

_images/sd2.png

Specifications

  • Chipset: nRF51822 ARM Cortex-M0

  • Frequency: 16Mhz

  • Dimensions: 24x21X3mm

  • Weight: 14g

  • Max distance: 10m

  • Working Voltage: 3.3V

  • Protocols: Wireless 2.4GHz, Bluetooth 2.4G

  • Wireless Mode Indicator (Green for 2.4GHz, Blue for Bluetooth)

  • Mode Toggle Switch

  • Compatible with SD Card slot

Installation Method

Installation: Insert the module into the SD Card Slot of Meowbit with the golden connectors facing towards you.

_images/sd3.gif

Removal: Slowly and carefully pull out the module from the slot.

_images/sd4.gif

Mode Toggle

The button on the top of the module is for switching between modes.

_images/sd12.gif

MakeCode Arcade Coding Tutorial

_images/acbanner1.png

Load the extension for the wireless module

Wireless Extension: https://github.com/KittenBot/pxt-sdwireless

Blocks for the wireless module

_images/sd7_1.png

MakeCode Arcade Error Message
This error message may appear in MakeCode Arcade when using the wireless module, this is simply because the emulator cannot emulate the wireless module.
Please ignore and continue.

_images/sd13.png

Sending data

Data can be sent from Meowbit to the Micro:bit using the 2.4GHz radio.

Meowbit Coding

_images/sd8_1.png

Sample Code Link

Microbit Coding

_images/sd9_1.png

Sample Code Link

Pressing A or B on the Meowbit causes Micro:bit to display different icons.
Receiving data

Meowbit can also receive data from a Micro:bit using the 2.4GHz radio.

Meowbit Coding

_images/sd11_1.png

Sample Code Link

Microbit Coding

_images/sd10_1.png

Sample Code Link

Pressing A or B on the Micro:bit causes Meowbit to display different text.

Meowbit & Robotbit

Meowbit can be used in conjunction with a Robotbit to achieve even more possibilities.

Robotbit Precautions:

1: The battery must be installed in the right way.
2: The screen of the Meowbit must be facing outwards.

_images/robotbit24.png

MakeCode Arcade Coding Tutorial

_images/acbanner1.png

Using Robotbit

Load Robotbit Extension
Robotbit Extension: https://github.com/KittenBot/meow-robotbit
Loading Extensions
Loading the extension for Robotbit would automatically load the extension for IO pins.

_images/sd5_1.png

_images/robotbit1_1.png

Blocks for controlling Robotbit

_images/robotbit2_1.png

Using Meowbit and Robotbit
1. Controlling Motors

Connect DC motors to the motor ports M1A and B of the Robotbit.

mainBoard/Microbit_eboard/RBimage/motor_wire.png

_images/robotbit5_1.png

Sample Code Link

2. Controlling Servos

Connect a servo to the servo port S1 of the Robotbit.

mainBoard/Microbit_eboard/RBimage/servo_wire.png

_images/robotbit6_1.png

Sample Code Link

3. Controlling Stepper Motors

Connect stepper motors to the motor ports M1 and M2 of the Robotbit, with the red wire connecting to VM.

mainBoard/Microbit_eboard/RBimage/stepper_wire.png

_images/robotbit7_1.png

Sample Code Link

Kittenblock Coding Tutorial

mainBoard/functional_module/PWmodules/images/kbbanner.png

Blocks for controlling Robotbit

_images/kb15_1.png

1. Controlling Motors

Connect DC motors to the motor ports M1A and B of the Robotbit.

mainBoard/Microbit_eboard/RBimage/motor_wire.png

_images/robotbit16_1.png

2. Controlling Servos

Connect a servo to the servo port S1 of the Robotbit.

mainBoard/Microbit_eboard/RBimage/servo_wire.png

_images/robotbit17_1.png

3. Controlling Stepper Motors

Connect stepper motors to the motor ports M1 and M2 of the Robotbit, with the red wire connecting to VM.

mainBoard/Microbit_eboard/RBimage/stepper_wire.png

_images/robotbit18_1.png

Troubleshooting

Q: How to solve the problem of “Robotbit is not defined” error on Meowbit after uploading the program from Kittenblock?

_images/robotbit23.jpg

A: Robotbit could not be initialized because Meowbit is not connected to Robotbit, connect Meowbit to Robotbit and reset to run the program as normal.

Meowbit & Neopixel

Meowbit can also be programmed to control Neopixel LED strips, such as the one on Robotbit.

MakeCode Arcade Coding Tutorial

_images/acbanner1.png

Controlling LED strip

Load Light Extension
Blocks for controlling LED strips

_images/robotbit4_1.png

Programming LED strip of the Robotbit
The LED strip on the Robotbit is connected to P16.

_images/robotbit15_1.png

Lighting up all 4 LEDs

_images/robotbit10_1.png

Sample Code Link

RGB color

_images/robotbit11_1.png

Sample Code Link

HSL color

_images/robotbit12_1.png

Sample Code Link

Controlling individual lights
The index of the LED lights starts from 0.

_images/robotbit13_1.png

Sample Code Link

Photon effect

_images/robotbit14_1.png

Sample Code Link

Kittenblock Coding Tutorial

mainBoard/functional_module/PWmodules/images/kbbanner.png

Blocks for controlling the LED strip

_images/kb17_1.png

Programming the LED strip of the Robotbit
The LED strip of the Robotbit is connected to P16.

_images/robotbit19.png

Lighting up all LEDs
All effects will only be shown after using Color Update block.

_images/robotbit20.png

RGB color

_images/robotbit21.png

Controlling Individual Lights
The index of the LED lights starts from 0.

_images/robotbit22.png

Meowbit & IOBit

Meowbit can be used in conjunction with an IOBit to achieve even more possibilities.

MakeCode Arcade Coding Tutorial

_images/acbanner1.png

Using IOBit and IO Pins

Load IOBit Extension

IOBit Extension: https://github.com/KittenBot/meow-iobit

Blocks for controlling IOBit

_images/iobit2_1.png

1. Reading and Writing Values
1.1 Read digital values

_images/iobit3_1.png

Sample Code Link

1.2 Write digital values

_images/iobit4_1.png

Sample Code Link

1.3 Reading analog values

_images/iobit5_1.png

Sample Code Link

1.4 Writing analog values

_images/iobit6_1.png

Sample Code Link

2. Controlling servos

_images/iobit7_1.png

Sample Code Link

Meowbit & Turtle(Kittenblock)

Turtle Academy is a programming tool designed for children, Turtle is also available on Meowbit in Kittenblock.

Kittenblock Coding Tutorial

mainBoard/functional_module/PWmodules/images/kbbanner.png

Blocks for controlling Turtle

_images/kb16_1.png _images/kb16_2.png

Turtle Movements and Filling

_images/turtle1.png

Press up to begin filling, press A to go forwards, use Left and Right to turn and press down to complete the filling.

Setting Coordinates and Drawing Circles

_images/turtle2.png

Setting the coordinates and drawing a circle with a radius of 20 pixels.

Drawing dots and clearing the screen.
Clearing the screen also clears the background.

_images/turtle3.png

Pen Up and Pen Down
Any movement of the turtle would draw a line if the pen is down. We can use pen up to avoid this.

_images/turtle4.png

Using Pen Up and Pen Down, it can draw 2 serperate lines.

Meowbit’s Display(Kittenblock)

Meowbit’s screen can be programmed to display various text or shapes.

Kittenblock Coding Tutorial

mainBoard/functional_module/PWmodules/images/kbbanner.png

Blocks for controlling the screen

_images/kb11_1.png _images/kb11_2.png

Filling a color and clear screen

_images/tft1.png

Drawing dots and lines
Lines must be given two coordinates for them to be drawn.

_images/tft2.png

Drawing Rectangles and Circles
The coordinates of a rectangle represents its top-left corner, with width and height as w and h.
The coordinates of a circle represents its origin, with radius as r.

_images/tft3.png

Drawing Triangles and Polygons
Give 3 coordinates as vertices to create a triangle.
The coordinates of a polygon represents its origin.

_images/tft4.png

Displaying text
The coordinates are at the top-left corner of the string.
Traditional Chinese Characters are not supported yet.

_images/tft5.png

RobotBit

Information related to Robotbit.

Robotbit

Robotbit (Version 2.2)

Suitable for school-based STEM education/ Training Institutes/ Enthusiasts

Must be used with Micro:bit

Purchasing Options

Online Shop———-→Robotbit v2.2

Package Contents

  • RobotbitV2.2 X 1

  • Robotbit Base X 1

  • 18650 Li-ion Battery X 1 (Optional)

    _images/Robotbit_18650.png

Special Features

  • Able to power a lot of actuators, DC motor x 4 or Stepper motor x 2 and Servo Motor x 8.

    Power Demostration

  • Extends the IO pins of the Micro:bit into Dupont connectors, supporting most electronic modules found on the market

  • Simplifies the power delivery system

    • Has a 18650 Li-ion battery compartment to provide a convenient and stable power source;

    • Can connect to external power that accepts up to 6V power, increasing the driving power even more.

  • Robotbit Base: Provides protection as well as pin holes compatible with Lego Technic pins

    _images/with_base2.png

    Installing the Base

  • Built-in buzzer allows the Micro:bit to make sounds

  • 4 programmable RGB LEDs, adds lighting effects to your projects

Robotbit Demo Video:

_images/video1.png

Dimensions and Weight:

  • Dimensions: 78mm x 57mm x 23mm

  • PCB Thickness: 1.5mm

  • Hole Diameter(Small): 3.0mm

  • Hole Diameter(Big): 4.8mm

  • Weight: 37.5g

_images/robotbitSize.png

Specifications:

  • 18650 Voltage: 3.7V

  • USB Input Voltage: 5V

  • External Input Voltage:5V (Supports up to 6V, 3A)

  • VM Maximum Output: 1A(Under 18650 Battery)

Programming Platform

Hardware Support: Micro:bit, Meowbit

Programming Platform: Kittenblock(Based on Scratch 3.0) / Microsoft Makecode / Python(Mu editor)

Microsoft MakeCode

functional_module/PWmodules/images/mcbanner.png

_images/04_1.png
Search for “Robotbit” in the extensions page

_images/38_01.png

_images/39_1.png

The Robotbit extension is added

_images/success.png

KittenBlock

functional_module/PWmodules/images/kbbanner.png

1. Open Kittenblock and connect the Micro:bit with a USB cable

_images/40_01.png

2. Connect KittenBlock with Micro:bit

_images/41_01.png

3. The extension for Robotbit will be loaded automatically

_images/43_1.png

Python

Robotbit can be programmed with Python.

Switch to “Coding Mode” to view and edit MicroPython code.

_images/44_1.png

_images/45_1.png

Breakdown Diagram

_images/02_1.png

  1. External Power Input

  2. Power Switch

  3. Power Indicator

  4. Battery Level Indicator

  5. MicroUSB Charging Port

  6. 2 Motor Ports for a total of 4 DC Motors or 2 28BYJ Stepper Motors

  7. Buzzer Toggle Jumper

  8. 8 IO Pins(Corresponds to P0-P2, P8, P12-P15)

  9. 5V Output Pins

  10. Buzzer

  11. Servo Ports for 8 servos

  12. I2C Port

  13. 18650 Li-ion Battery Holder

  14. Battery Indicator

  15. Micro:bit slot

  16. Programmable RGB LED x 4

_images/03_1.png

  1. Servo Driver

  2. Motor Driver

  3. Mounting Holes

  4. Lego Technic Pin Holes

Robotbit Details

_images/48.png

18650 Battery Holder
_images/09_1.png

Please be careful with the polarity! Install battery according to the label on the holder.

For safety, the battery is not activated when it is installed for the first time. Press the Battery Activate Button or connect a USB power supply to activate the battery.

(This procedure should be done after each battery install)

18650 Power Switch

_images/112.png

Push the switch to ON position(Towards the green connector) to power the board. (18650 Battery is needed)

Micro USB Charging Port

_images/102.png

The Charging Port can charge the 18650 battery with any 5V USB power supply, any USB port on computers or phone chargers will work. It takes about 2.5 hours to fully charge a battery with a 5V1A supply, the Charging Indicator will light up green when it is fully charged.It is recommended to disconnect the power after fully charging. Please read the battery usage guidelines included in the box.

Attention: This port is for charging only! Not for downloading programs!
Power Indicators

_images/122.png

Led(3) is a Power Indicator, it lights up when Robotbit is powered on.Led(1) is a Charging Indicator, it lights up when the battery is being charged. Led(2) is a Battery Level Indicator, it lights up when the battery is fully charged.

Micro:bit Slot

_images/132.png

Used to install Micro:bit.

Correct orientation: The A and B buttons of the Micro:bit should face outwards.

_images/001_01.png

If installed incorrectly, just reinstall it in the correct way. Micro:bit / Robotbit won’t be damaged.

Programmable RGB LEDs

![](../RBimage/14.png

The 4 programmable RGB LEDs are connected to Pin 16 of the Micro:bit.

Servo Ports

_images/19.png

  • Robotbit is equipped with a servo driver with support of up to 8 servos.

    Attention: The servo pins will not work as IO pins, they are solely for servos. 
    
  • When using a 18650 battery, a total of 8 servos with a total current of less than 2A can be supported. Do not use high current servos such as MG995 to avoid damaging the Robotbit.

  • When using the external power input(5V 3A or more), 8 servos with a total current of less than 3A is supported.

    shield/RBimage/robotbit_extpower.png

Motor Ports

_images/171.png

A total of 4 DC motors can be used, alternatively 2 stepper motors can be used, the total current must be less than 2A. Do not use high current motors to avoid damaging the Robotbit.

A mix of motors can also be used.(2 DC Motors with 1 Stepper Motor)

Buzzer and Jumper

_images/21_1.png

  • By default,the buzzer jumper is connected to enable the buzzer by connecting it to Pin 0.

  • Removing the buzzer allows usage of Pin 0.

  • The buzzer can be programmed using the Music coding blocks on MakeCode.

Micro:bit IO Pins

_images/181.png

The IO pins of the Micro:bit(P0-P2, P8, P12-15) have been adapted into standard Dupont connectors compatible with most Arduino modules.P0-P2 supports both Analogue and Digital modules. P8, P12-P15 are only for Digital input and outputs.The pins have a voltage of 3.3V, for modules that need a 5V power, use the 5V pins next to the servo ports.

I2C Port

_images/19.png

Supports I2C modules, has a voltage of 3.3V.

2PIN External Power Port

_images/20.png

  • Pay attention to the polarity when connecting.

  • DC 5V power is supported by this port, it is recommended to use 5v power with more than 2A when using high torque motors and servos.

  • Under battery power, the VM port outputs 3.7V; Under external power, the VM port outputs 5V.

Robotbit Quick Start Guide

Install the Battery
_images/z1.gif
Insert the Micro:bit
_images/z4.gif
Activate the Battery
_images/z2.gif
Turn on the Power
_images/z3.gif

Robotbit & MakeCode

Robotbit improves the functions of Micro:bit on multiple aspects, Kittenbot has developed an extension for Robotbit so that users can easily make use of these functions.

Please refer to the following document for details:

Robotbit & MakeCode

Commonly Asked Questions

Robotbit does not turn on after installing battery and switching on the power.

Please check if the battery has been activated via the activator button.Please check if the battery has been installed correctly.Please check if the battery is charged.


What is the function of the battery activator?

The battery activator serves as a protection mechanism. In case of accidents such as over current or short circuit, the protection circuit will be activated to cut off the power to prevent damage. Pressing the activator will reset the circuit to its working state.


I can’t find my Micro:bit or Robotbit when connecting it to my computer.

The USB port on the Robotbit is only for charging the battery, not for communicating with a computer.


Will I destroy the Robotbit if I install the battery in the wrong way?

No, Robotbit was designed to prevent damage in this case. However please still be careful when installing the battery.


Will I destroy the Robotbit by inserting the Micro:bit in the wrong way?

No because Micro:bit will not be powered in this case.


How do I use Pin 0?

Pin 0 is used by the buzzer by default, remove the buzzer jumper to use Pin 0 as normal.


Micro:bit has more than 8 IO pins, where are the other ones on the Micro:bit?

Although Micro:bit has close to 20 IO pins, a lot of them are used by the Micro:bit’s built-in devices such as the LED matrix.

Although these occupied pins can in fact be used, it may be confusing and difficult for beginners. The 8 remaining free pins accessible with the Robotbit is more than enough for most projects.

If more IO pins are required, consider using IOBit, another expansion board made by Kittenbot.


Can the Servo Ports be used as IO Ports?

No, because the 8 servo ports are controlled by a servo driver, they are not IO pins.


What is the use of VM port on the Motor ports?

The VM port is only used by stepper motors, DC motors only need to use A+A- or B+B-者B+B-.


Can the board be placed on a metal or wet surface?

No, doing so will cause a short circuit and damage the board. Please install a Base to prevent short circuit.

Base Installation


What kind of current is supported by the external power input?

The external input supports a maximum current of 6V3A.


I can’t reproduce the results from the tutorials.

There may be slight mistakes in your wiring or your program, check each carefully.

The Robotbit seems to be broken, is there a warranty?

Each Robotbit has been tested to be in working order before they are packaged. Please check if the problem is caused by your program or your wiring, if you are certain that the Robotbit is damaged, please contact the supplier.

If the board is evaluated to be damaged by not man-made damage, the supplier will offer a replacement for boards that are within 1 year of their purchase according to the receipt.


Robotbit Version Changelog

Due to popular requests, Robotbit has experienced two updates since it was launched in 2017.

From V1.2 in 2017, it was updated to V1.3 and then updated again to V2.0 in 2018.

Changes to the Robotbit V2.0:

1. Increasing the number of IO pins

V1.3 only had 3 IO pins. V2.0 increased the number of IO pins to 8.

2. Improving the battery discharge mechanism

Now, charging will not cause the battery to heat up yet charging performance is not affected.

3. Improving the power switch

The new switch can completely cut off power to the board, thus solving the problem where the battery discharges while power is switched on.

4. Adding an external power input

Under the external power, high current motors or servos like MG995 can be used. With a 5V3A power, 4 MG995 servos can be used.

5. Improving the VM port

Increasing the output of VM port to 3A.

6. Upgrading to an independent battery protector chip.

Upgrading the battery protector chip with a high cost version to improve safety in discharging.

7. Adding a battery activator switch.

The battery activator serves as a protection mechanism. In case of accidents such as over current or short circuit, the protection circuit will be activated to cut off the power to prevent damage. Pressing the activator will reset the circuit to its working state.

8. Upgrading the buzzer.

The buzzer’s position and volume has been adjusted.

9. Upgrading the Micro:bit slot.

Reduces the wear on the edge connector of the Micro:bit, also making it easier to insert and pull out the Micro:bit.

10. Adding a 5V output

Adding a 5V output to make Robotbit compatible with even more electronic modules.

11. Improving the power indicators

Robotbit Base

Each Robotbit comes with a base, not only does using this base protect the bottom of the Robotbit from short circuiting, it also provides mounting holes for Lego Technic pins or screws, allowing more choices for building your robots.

_images/base3.png

Installing the Robotbit Base:

_images/base7.png

Robotbit Base Explaination

_images/base1.jpg

Pay attention to the orientation of the base!!
The indents must align with the charging ports and the power switch of the Robotbit!!

_images/base8.png

Robotbit Coding with MakeCode

Robotbit can be programmed using Microsoft MakeCode.

Makecode Coding

functional_module/PWmodules/images/mcbanner.png

Loading the extension for Robotbit
1. In the extensions page, search for “Robotbit”.

Robotbit and its extension has been officially approved by Microsoft.

_images/38_01.png

_images/39_1.png

2. In Offline MakeCode by Kittenbot, the Robotbit extension can even be loaded without access to the internet.)
The blocks for Robotbit is added

_images/success2.png

1. Programming Motors

_images/robotbit_motor.png

For information about DC motors by Kittenbot, please visit: Kittenbot Actuators

Sample Program:

Connect 2 DC motors to the M1A and M1B port of the Robotbit.

_images/motor_wire.png

The speed of motor ranges from -255 to 255.

_images/robotbit_code1.png

2. Programming Servos

For information about servos by Kittenbot, please visit: Kittenbot Actuators

Sample Program:

Connect a servo to the S1 port of Robotbit.

Connect the orange wire from the servo to the yellow wire of the Robotbit.

_images/servo_wire.png

Typical servos have a rotation range of 0-180.

_images/robotbit_code2.png

3. Programming Stepper Motors

For information about DC motors by Kittenbot, please visit: Kittenbot Actuators

The programming blocks were designed for Kittenbot's 28BY-48-5V stepper motor, using other motors may result in reduced accuracy.
Sample Program:

Connect Stepper Motors to the M1 and M2 port of the Robotbit, with the red wire connecting to the VM port.

_images/stepper_wire.png

Stepper Motors have a rotation range of -360 to 360.

_images/robotbit_code12.png

4. Programming the buzzer

Do not remove the buzzer jumper when using the buzzer.

_images/robotbit_code4.png

5. Programming the built-in LED strip

The programming blocks for the LED strip are found in the Neopixel tab.

_images/robotbit_neopixel1.png

Remember to add a "Show" block to display the effect.(Except show color.)
5.1 Lighting up all lights

_images/robotbit_code5.png

5.2 Customizing color with RGB
RGB value has a range of 0-255.

_images/robotbit_code6.png

5.3 Customizing color with HSL.
HSL consists of a hue value with the range 0-360, a sturation and brightness value with the range 0-100.

_images/robotbit_code7.png

5.4 Lighting up individual lights
The lights are labelled 0-3. (As labelled on the Robotbit)

_images/robotbit_neopixel2.png

_images/robotbit_code8.png

5.5 Adjusting the brightness.
The brightness level has a range of 0-255.

_images/robotbit_code9.png

6. Programming the IO Pins

The blocks for the IO pins are found in the Pins tab.

Pin 0-2 can be used as analog pins while P8, P12~P15 can only be used as digital pins.
Analog values have a range of 0 to 1023, digital values have a range of 0 to 1.

_images/robotbit_pin1.png

6.1 Reading values from pins
Pin 0 is occupied by the buzzer by default, the jumper should be removed when using this pin.

_images/robotbit_code10.png

6.2 Writing values to pins
Pin 0 is occupied by the buzzer by default, the jumper should be removed when using this pin.

_images/robotbit_code11.png

Robotbit Coding with KittenBlock

Robotbit can be programmed with KittenBlock.

Refer to this page for introduction with Kittenblock: Kittenblock Introduction

Kittenblock Coding

functional_module/PWmodules/images/kbbanner.png

Connect the Micro:bit to your computer with a USB cable.

Click select hardware and choose MicroBit Python from the menu.

_images/add.png

Press this exclamation mark(!).

functional_module/PWmodules/kbimages/kbmbcon.png

Click this button to connect the Micro:bit.

functional_module/PWmodules/kbimages/kbmbcon1.png

functional_module/PWmodules/kbimages/kbmbcon2.png

Micro:bit will display a heart icon after connecting to Kittenblock.

If the Micro:bit does not show a heart icon,

functional_module/PWmodules/kbimages/upload.png

The blocks for Robotbit will be added

_images/success1.png

1. Programming Motors

For information about DC motors by Kittenbot, please visit: Kittenbot Actuators

Sample Program:

Connect 2 DC motors to the M1A and M1B port of the Robotbit.

_images/motor_wire.png

The speed of motor ranges from -255 to 255.

_images/kb_code1.png

2. Programming Servos

For information about servos by Kittenbot, please visit: Kittenbot Actuators

Sample Program:

Connect a servo to the S1 port of Robotbit.

Connect the orange wire from the servo to the yellow wire of the Robotbit.

_images/servo_wire.png

Typical servos have a rotation range of 0-180.

_images/kb_code2.png

3. Programming Stepper Motors

For information about DC motors by Kittenbot, please visit: Kittenbot Actuators

Sample Program:

Connect Stepper Motors to the M1 and M2 port of the Robotbit, with the red wire connecting to the VM port.

_images/stepper_wire.png

Stepper Motors have a rotation range of -360 to 360.

_images/kb_code3.png

4. Programming the buzzer

Do not remove the buzzer jumper when using the buzzer.

_images/kb_code4.png

5. Programming the built-in LED strip
Remember to add a "Show" block to display the effect.
5.1 Lighting up all lights

_images/kb_code5.png

5.2 Customizing color with RGB
RGB value has a range of 0-255.

_images/kb_code6.png

5.3 Lighting up individual lights
The lights are labelled 0-3. (As labelled on the Robotbit)

_images/robotbit_neopixel2.png

_images/kb_code7.png

6. Programming the IO Pins

The blocks for the IO pins are found in the menu for Micro:bit.

_images/robobit_pinKB.png

Pin 0-2 can be used as analog pins while P8, P12~P15 can only be used as digital pins.
Analog values have a range of 0 to 1023, digital values have a range of 0 to 1.

_images/robotbit_pin1.png

6.1 Reading values from pins
Pin 0 is occupied by the buzzer by default, the jumper should be removed when using this pin.

_images/robobit_pinKB2.png

6.2 Writing values to pins
Pin 0 is occupied by the buzzer by default, the jumper should be removed when using this pin.

_images/robobit_pinKB3.png

Robotbit Shield

The Robotbit Shield is designed to facilitate the use of modules with a PH2.0 connector by adapting the Dupont connectors into 3PIN and 4Pin PH2.0 connectors, removing the need to use a conversion cable.

_images/shield4.jpg

Installing the Robotbot Shield

_images/shield3.jpg

_images/shield5.gif

Robotbit Shield Breakdown Diagram

_images/shield1.jpg

1: PH2.0 4PIN I2C Port

2~9: PH2.0 3PIN Ports

10: PH2.0 4PIN Port, identical to Port 2 of Armourbit

11: Dupont 4PIN I2C Port

12: Voltage Selector, switches the voltage at pin 0-2 to be 3.3V or 5V

13: Dupont 3PIN Port, VCC voltage can be switched by the selector

14: Power Indicator

_images/shield2.jpg

15: 8PIN Female Connector, connects to the IO pins on the Robotbit

16: 2x2 5V Female Connector, connects to the 5V pins on the Robotbit

17: 4PIN Female Connector, connects to the I2C pins on the Robotbit

Attention: All PH2.0 ports have a voltage of 3.3V

IOBit

_images/22.jpg

IOBit is a basic expansion board designed for Micro:bit, as the name suggests, IOBit makes the all IO pins of the Micro:bit accessible.

Product Details

IOBit is a low cost expansion board for Micro:bit, it extends all the IO pins of the Micro:bit into Dupont connectors for easy access. IOBit is equipped with a buzzer and a 3.5mm audio jack for making sounds with Micro:bit. It also has a power port to supply 3V or 5V power to your hardware. The edge connectors of the Micro:bit is preserved for users familiar with using crcodile clips.

Special Features

  1. Converts the edge connectors pins of the Micro:bit to the standard 3 pin format. The singal, vcc and gnd pins can be distinguished by their colors.

  2. Equipped with short circuit protection and a resettable fuse, avoiding dangers such as short circuiting because of incorrect connection.

  3. Preserves the 3 pin edge connector of the Micro:bit, allowing users who are used to this system to use the board.

  4. 2 pin holes compatible with standard Lego Technic pins allow easy integration of the expansion board to your robotic projects.

Specifications

  • Dimensions: 56.8x44x12 mm

  • Power Input: USB 5V/Micro:bit Battery Box 3V

  • Power Output: 3.3V~5V, maximum 1A

_images/11.jpg

Built-in devices

  • 3 Pin IO Edge Connector

  • Buzzer and toggle switch

  • 3.5mm audio jack

  • 5V USB Port

  • Power switch

5V Input

_images/3.jpg

  1. Plug in a USB power supply

  2. Press the power switch

  3. The power indicator will light up

  4. The 5V pins can now be used.

P0 Buzzer Toggle

_images/4.jpg

Pin 0 is occupied by the buzzer, use this switch to togglebuzzer on or off

Demo Video

_images/video.png

Precautions:

  1. Do not use high current devices, large servos or motors with this board, as this may result it damaging the Micro:bit.

  2. The 5V power supply is able to run multiple small servos as long as the total current is less than 1A.

  3. Using Pin 0 requires the buzzer to be switched off or the buzzer may buzz erratically.

  4. Since Pin 3 to Pin 11 are used by Micro:bit’s LED Matrix, the matrix needs to be turned off or it may light up erratically.

  5. Do not connect to a USB power with current exceeding 1A.

KOI AI Camera

AI Camera KOI

All information about AI Camera KOI is documented here, including hardware information, coding tutorials and firmware updates.

AI Camera KOI

AI Camera KOI (HKBC8006A)

Online Shop

Available to purchase at KidsLab. → AI Camera KOI

Package Content

· AI Camera KOI x1

· MicroUSB Cable x1

· PH2.0 to Dupont Cable x1

· 128MB MicroSD Card x1

_images/KOI-packing.png

Product Introduction

· What is KOI?

AI Camera KOI is an offline Artificial Intelligence Module developed by Kittenbot. It is aimed to provide an easy to use platform for students and enthusiasts.KOI is an integrated module combining AI chip, camera, microphone, speaker, IPS display and Wifi chip into 1 convenient module.

AI Camera KOI has a lot of abilities, including Visual Recognition, Face Detection and Recognition, Object Classification, Speech Recognition and Text to Speech. With its built in Wifi chipset, you can even connect your KOI to the cloud for IoT AI Projects!

KOI’s functions can let you experience and learn Artificial Intelligence in a systematic way!

· Intended Audience:

STEM Education in Primary or Secondary Schools / STEM Enthusiasts / Advanced MakeCode or Kittenblock users

Features

· Combing AI and IoT functions, authentic offline AIoT projects can be realized

· Comprehensive peripherals are built in, a standalone module can realize AI functions including vision and speech

· Supports both graphical programming and code based programming, suitable for beginners and makers alike

· A customized classifier model can be trained, external models can also be imported from from SD Card

Intro Video

_images/video01-1.png

Youtube

List of functions

_images/function.bmp

_images/Demo.png

Object Classification Demo

_images/video03-1.png

Youtube

Specifications

· CPU: K210

· Supported Micro Controllers: Microbit, Arduino series or any micro controller with serial support

· Display Resolution: 1.3 inch 240x240 IPS

· Camera Resolution: 640x480 RGB

· Audio Input/Output: Outputs in 48khz mono, inputs in 8khz

· SD Card Slot: Supported MicroSD Card, used to store classifier models, images and sounds, and Python code

· WiFi Chipset: ESP8285

· Data Output Channels: UART / WIFI /USB

· Image Output Channels: USB / Wifi

· Input Buttons: 2 Programmable Buttons

· SD Card Support: 16 G

· Voltage: 3.3~5v

· Supported Programming Platforms:

  1. Kittenblock

  2. Makecode

  3. Micropython

  4. Arduino (PlatformIO)

KOI Close Up

Let’s take a closer look at the AI Camera KOI.

Correct Orientation

This is the default orientation of KOI.

_images/01-12.png

Camera Rotation

The camera can be rotated from 0° to 180°. Be careful of the cable when rotating the camera.

Front Camera Mode

When both the camera and the display are facing towards you, the KOI is set up in Front Camera mode.

This is usually used in face detection or visual recognition.

_images/02-16.png

Back Camera Mode

Wehn the camera and the display are facing the opposite the direction, the KOI is set up in Back Camera mode.

This is usually used in object classification, qr code/barcode recognition or line tracing.

_images/03-15.png

Display and Coordinates

KOI uses an IPS display with a resolution of 240x240.

The origin of the coordinates is at the top left corner with (x,y)=(0,0).

Real time camera feed and system notifications will be displayed on the monitor.

_images/04-15.png

A & B and Reset Buttons

2 programmable buttons are found on both sides of the KOI, they function like the A and B buttons found on the Micro:bit.

A reset button is also found on the lower left hand side of the KOI, this is seldomly used.

_images/13-11.png

Microphone

At the bottom left of the module, a microphone can be found. This microphone picks up sound in a range of approximately 50cm.

_images/05-1.png

Micro USB Port

This MicroUSB port is used to power the KOI or connect to a computer.

_images/06-1.png

PH2.0 4PIN Connector

This connector handles the serial communication between KOI and other micro controllers.

Pin out:

_images/14-1.png

Beginners are advised to use an Armourbit to prevent incorrect connection.

Armourbit

_images/15-1.png

Micro SD Card Slot

The SD card slot has an ejector mechanism, it supports cards up to 16GB. Images, sounds and classifier models will be saved to here.

_images/08-1.png

Speaker

The mono speaker is on the back of KOI.

_images/09-1.png

LEGO Pin Connectors

Round slots on the back of KOI are compatible with LEGO Technic pins.

Pin Connector Spacing:

Length: 4 spaces between pins

Width: 3 spaces between pins

_images/10-1.png

MakeCode Quickstart Guide

Connecting to Micro:bit

1. Connecting to Armourbit

It is easier to connect to an Armourbit because they both use PH2.0 connectors.

When using KOI with an Armourbit, KOI needs an extra 5V power source.

Using the USB port on the battery box, 5V power can be supplied to KOI. (See figure below)

_images/armourbit_connection1-1.png

_images/armourbit_connection2-3.png

2. Connecting to Robotbit

As Robotbit can supply 5V power, there is no need to power KOI with an USB cable.

Please pay attention in connecting the power wires to the Robotbit.

DO NOT connect it in the wrong way.

Or KOI may not function correctly, it may even suffer damage.

Using the cable included with KOI, connect KOI to Robotbit using Dupont wires.

The Dupont wires are arranged as: Black, Red, Blue, Green

These wires correspond to: GND, 5V, P1(TX), P12(RX)

The (Blue)TX wire must be connected to an analog pin(Pin0-Pin2).
Remember to remove the buzzer jumper when Pin0 is used.

_images/robotbit_connection1.png

Do not connect Red to Ground and Black to 5V!!!

Ensure the connection is correct and switch the power on.

_images/robotbit_connection2.png

_images/robotbit_connection3-1.png

MakeCode Coding Tutorial

modules/functional_module/PWmodules/images/mcbanner.png

https://makecode.microbit.org

_images/01-13.png

Loading Extensions

_images/16-1.png

Copy and paste the following link to the search bar.

https://github.com/KittenBot/pxt-koi

_images/023.png

New block labelled KOI will be added.​

_images/03-16.png

Blocks Explained

This section briefly explains the functions of blocks.

Please refer to tutorials for detailed tutorial and sample codes.

KOI Initialization

_images/042.png

1st Block —— is used for Robotbit.

2nd Block —— is used for Armourbit.

Classifier

It is easier to understand Classifier blocks if you are already familiar with ML5 extension on Kittenblock.

Classifier is used to train and run a customized model for object/scene classification.

_images/051.png

Screenshots and Display

Micro SD card is required for this function to work.

The Screenshot block creates a png file and saves it onto the SD card. The name must not contain spaces.

The Display block finds the file on the SD Card then displays it on the screen for 1 second. The name must not contain spaces.

_images/061.png

Show Text

The print block shows a string at the specific coordinates. It shows the text for 1 second by default, this duration can be changed via delay.

_images/071.png

Display Orientation

Since KOI cannot detect the direction of the camera, the display orientation has to be set manually so that the image corresponds to camera direction.

There are 3 modes, Front, Back and Land. (Refer to figure below.)

_images/082.png

Circle Tracking

A threshold can be adjusted, a higher value can filter out more noise and interferences, but tracking difficulty increases as well.

Tracking circle returns 3 values, the coordinates of the circle as well as the radius.

_images/091.png

Rectangle Tracking

Similar to Circle Tracking, the threshold can be adjusted.

Rectangle Tracking returns the coordinates of the rectangle and its width and height.

_images/10.png

Line Tracing and Color Blob Tracing

Calibration is required before tracing lines or color blobs.

Line Tracing returns the starting and ending coordinates of the line.

Color Blob Tracing returns the coordinates of the blob and its width and height.

_images/111.png

Barcode/QRCode Recognition

Scans and returns the contents of the Barcode/QRCode.

The Barcode/QRCode should not be smaller than 3.5cm in width or the resoulution is too small to be recognized.

_images/121.png

Apriltag Recognition

Apriltags are seldomly used in Hong Kong, this tag is usually used in robots.

Apriltags Recognition returns an id and its geometric attributes.

_images/141.png

Face Detection
  1. Load the face model before detecting faces.

  2. Runs the model once to detect faces.

  3. Returns the coordinates of the face.

_images/151.png

Recording and Playing wav files

Micro SD card is required for this function to work.

This function records and plays a wav file from the SD card.

_images/17.png

Using the built-in Buttons

When the button is pressed, it returns 1, otherwise 0 is returned.

_images/02-1.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

KOI Firmware Update

Kittenbot’s development team releases new firmware for KOI periodically to improve KOI’s functions.

Users can follow these instructions to update your KOI to the latest firmware.

KOI Update History

The latest and legacy firmware files can be downloaded here.

Latest Firmware(Version: v1.12.0)

Firmware Version: v1.12.0

Release date: 23/11/2020

Firmware Download

Update Notes:

  1. Improve Text-to-Speech stability

  2. Face Recognition Improvements

  3. Speech Recognition Improvements

  4. UI Improvements

Greeting Screen:

_images/25081.jpg

Version:

_images/1_12_0.jpg

Version: v1.9.5

Version: v1.9.5

Release date: 16/09/2020

Download Link

Update Notes:

  1. IOT Update

  2. Voice Recognition Update

  3. Increasing tag size from 20 to 40

Greeting Screen:

_images/25081.jpg

Version:

_images/195_1.jpg

Version: 0.43

Version: 0.43

Relase Date: Before 16/09/2020

Download Link

Update Notes:

  1. Factory Firmware

Version

_images/043.jpg

Checking the firmware version

Version is shown when booting up.

Connect to KOI on Kittenblock will cause a pop up showing the firmware version.

_images/kb8.png

Updating KOI Firmware

Kittenbot’s development team releases new firmware for KOI periodically to improve KOI’s functions.

Users can follow these instructions to update your KOI to the latest firmware.

Update Method

Connect KOI to a computer using a USB cable.

_images/usb.jpg

You will need firmware flashing tool and a firmware file to update firmware. Download them using the provided link.

Flashing tool

Firmware Download

1. Download the version appropiate to your operating system.

_images/16.png

2. Unzip the file.

_images/24.png

3. Find and open kflash_gui.exe

_images/34.png

4. Please allow the program to run if this message appeared.

_images/45.png

5. Select the firmware file.

_images/52.png

6. From Board, select Sipeed Maixduino。

_images/61.png

7. Select the port that KOI is connected to.

_images/72.png

8. Leave other settings as default and Download.

_images/82.png

9. Wait for the update to complete.

_images/92.png

10. Flashing done.

_images/101.png

11. Reset KOI to check if update is successful.

_images/reset.jpg

KOI Wifi Firmware Update

Kittenbot may release Wifi firmware updates periodically to improve stability and performance.

Users can follow this guide to update their KOI Wifi firmware.

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension:
https://github.com/KittenBot/pxt-koi
Checking firmware version:

Build the following program.

Extension Version: 0.6.4 or above

_images/updateCode1.png

Sample Link Download

Extension Version: 0.5.7 or below

_images/updateCode2.png

Sample Code Download

Upload the program to Micro:bit and wait for KOI to connect to the internet.

Press A to show the IP address of KOI, write the address down.

If you have administrator rights to your network, you can go to your router's homepage and see the IP address directly.

Use a web browser and type in the IP address, then press Enter.

_images/update4.gif

The firmware version is shown on the homepage.

_images/update2.png

Updating KOI’s Wifi Firmware

Download the latest firmware: v2.95

Enter KOI’s homepage using the above method.

Select Upgrade Firmware from the menu.

_images/update5.png

Select the right file according to the instructions.

_images/update6.png

The instruction tells us to upload user2.bin, so that file is selected.

_images/update8.png

The update will be done automatically.

_images/update7.png

KOI Coding with MakeCode

Interchanging between Armourbit and Robotbit

KOI supports both Robotbit and Armourbit, the only difference is in the initialization.

KOI Initialization

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Initialization Blocks:

_images/15.png

For Armourbit users, choose “init powerbirck port”.

_images/23.png

For Robobit users, choose “init Tx Rx”

_images/33.png

There are no difference between the 2 coding wise.

_images/44.png

In the following tutorials, Robotbit will be used. Armourbit users can modify the code based on this guide.

A and B Buttons

KOI has 2 built in programmable buttons called A and B.

_images/13-1.png

Using A and B Buttons

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for buttons:

_images/02-1.png

btnA and btnB refer to Button A and B respectively.

When the button is being pressed, it returns a value of 1. When it is not being pressed, it returns a value of 0.

Sample Program:

_images/03-2.png

Program Flow

Download the program to Micro:bit.

Pressing button A on the KOI causes Micro:bit to show a smiley face, pressing button B on the KOI causes Micro:bit to show a surprised face.

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the KOI.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

Displaying Text

English strings can be displayed on the KOI screen.

Displaying Text

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for displaying text:

_images/07.png

We can add a delay to specify the duration shown.

The coordinates refer to the top left corner of the text. See figure below for explaination of coordinates.

_images/04-1.png

Sample Program:

_images/03-1.png

Program

Download the program to Micro:bit.

Pressing button A on the Micro:bit to display “Kittenbot” on the screen. Pressing button B to display “KOI” for 2 seconds.

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: Why does the text disappear after a short while?

· A: Since the dislay of the KOI keeps refreshing, the text cannot persist on the screen for a long time. For displaying persisting text, considering connecting an I2C OLED screen.

LCD Orientation

One advantage of the KOI is that camera is able to rotate from 0°~180°, however the image may be reversed on the LCD when the camera is rotated, thus we may need to change the LED orientation based on our use case.

Changing LCD Orientation

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Block for Changing LCD Orientation:

_images/01.png

From the drop down menu, there are 3 types of orientation to choose from.

_images/02.png

_images/08.png

Sample Program:

_images/03.png

Program Flow

Download the program to Micro:bit.

1: When button A is pressed, the LCD is set to Front mode. The image looks correct when the camera is facing towards you.

2: When button B is pressed, the LCD is set to Back mode. The image looks correct when the camera is facing away from you.

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

Taking and Displaying Pictures

KOI can take pictures and display them like a digital camera.

Install an SD Card

_images/02-11.png

The pictures are stored onto an SD card, without an SD card, these operations would fail.
Taking and Displaying Pictures

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for taking pictures and displaying:

_images/06.png

Sample Program:

_images/031.png

Program Flow

Download the program to MicroL:bit.

  1. Press button A on the Micro:bit to take a picture.

  2. Press button B on the Micro:bit to display the picture.

Advanced Program

The above program can only save 1 picture because the file is overwritten when a picture is saved. By making use of numbers, we can create a camera program that stores many photos and show them all.

_images/05.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: The picture appears noisy and there are black bars when I view the pictures on my computer.

· A: This is because KOI’s camera is not a phone camera, the quality and resolution is not as good. The black bars are caused by the difference in aspect ratio, since our computer monitors are typically 16:9 and KOI is 1:1, black bars would appear.

Recording and Playback

With the built-in microphone and speaker, simple recording and playback is possible.

KOI can record a 3 second audio clip and saves the file as a wav format.

Install an SD Card

_images/02-12.png

The pictures are stored onto an SD card, without an SD card, these operations would fail.
Recording and playback

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for recording and playback:

_images/04.png

Sample Program:

_images/03-11.png

Program Flow

Download the program to Micro:bit.

  1. Press button A on the Micro:bit, KOI will record what you say.

  2. Press button B on the Micro:bit, KOI will playback the audio file.

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: Can I change the recording duration?

· A: No, because recording duration is limited by the amount of RAM that KOI has.

4: Can I play mp3 files on the KOI?

· A: No, KOI can only play wav files, and file size cannot exceed 512KB.

5: Can I create my own wav files to play on KOI?

· A: Yes but make sure the duration is less than 3.75 seconds with a bitrate of less than 512kbps. The file size has to be within 512KB.

Scanning Barcodes and QR Codes

· Barcode is wide adopted in our daily lives, they are found on various products.

· QR Codes are used for data exchange or cashless shopping.

Scanning Barcodes and QR Codes

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for reading codes:

_images/011.png

Sample Program

_images/02-13.png

Program Flow

Download the program to the Micro:bit.

  1. Point the KOI at a Barcode and press A on the Microbit, the content of the Barcode will be shown on KOI’s screen.

  2. Point the KOI at a QRCode and press B on the Microbit, the content of the QRCode will be shown on KOI’s screen.

Advanced Program

There may not be enough time to read the contents if we show it on KOI, to improve readability, we can connect an OLED screen.

Connecting an OLED

Connect an OLED panel to the I2C port of your Robotbit/Armourbit.

_images/03-12.png

Sample Program
Load the extension for OLED: https://github.com/KittenBot/pxt-oled

_images/04-11.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: KOI fails to recognize my Barcodes/QR Codes.

· A: Make sure the width of the code is at least 3.5cm and the code is entirely within the camera’s view.

Circle Tracing

KOI is able to find and track circles in a scene.

Circle Tracing

modules/functional_module/PWmodules/images/mcbanner.png

Load the KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for circle tracing:

_images/01-1.png

Sample Program

_images/02-14.png

Threshold

_images/04-12.png

Threshold affects the detection rate, testing and fine tuning the value is needed for achieving the best results.

A higher threshold value decreases interference and noise, but detection difficulty increases at the same time, please trial and fine tune for different scenarios.

Program Flow

Download the program to Micro:bit, then press A on the Micro:bit.

The radius of the circle is shown on the Micro:bit while its coordinates are shown on the KOI.

Advanced Program

The information becomes more easily readable if we add an OLED screen.

Connecting an OLED

Connect an OLED panel to the I2C port of your Robotbit/Armourbit.

_images/03-12.png

Sample Program
Load the extension for OLED: https://github.com/KittenBot/pxt-oled

_images/03-13.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: How do I improve detection rate?

· Adjust the threshold value.

· Keep a clean background.

· Make sure the circle has a sharp outline.

Rectangle Tracing

KOI is able to find and track rectangles in a scene.

Rectangle Tracing

modules/functional_module/PWmodules/images/mcbanner.png

Load the KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for rectangle tracing:

_images/01-11.png

Sample Program

_images/02-15.png

Threshold

_images/04-13.png

Threshold affects the detection rate, testing and fine tuning the value is needed for achieving the best results.

A higher threshold value decreases interference and noise, but detection difficulty increases at the same time, please trial and fine tune for different scenarios.

Program Flow

Download the program to Micro:bit, then press A on the Micro:bit.

The coordinates and dimenions of the rectangle are shown on the KOI.

Advanced Program

The information becomes more easily readable if we add an OLED screen.

Connecting an OLED

Connect an OLED panel to the I2C port of your Robotbit/Armourbit.

_images/03-12.png

Sample Program
Load the extension for OLED: https://github.com/KittenBot/pxt-oled

_images/03-14.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: How do I improve detection rate?

· Adjust the threshold value.

· Keep a clean background.

· Make sure the rectangle has a sharp outline.

Line Tracing

Line Tracing is usually used in line tracing robots, we will learn how to obtain the coordinates of the line (x1,y1) & (x2,y2 )in this tutorial.

Getting coordinates

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for Line Tracing:

_images/image4154.png

Sample Program

_images/code.png

Color Calibration

Line Tracing and Blob Tracing both require calibration before using.

_images/calibrate.png

During calibration, a small green square will appear on the screen. Aim the square at the color you intend to track. The calibration will be done automatically.

It is recommended to have a distinct difference between the color you intend to track and the background.

_images/041.png

Program Flow

Download the program to the Micro:bit.

Put a thin object in front of the camera and press A to calibrate color.

After calibration, the coordinates of the line will be shown on the screen.

Advanced Program

The information becomes more easily readable if we add an OLED screen.

Connecting an OLED

Connect an OLED panel to the I2C port of your Robotbit/Armourbit.

_images/03-12.png

Sample Program

_images/codeoled.png

The program works the same way as the normal program, but now the coordinates are displayed on the oled.

_images/013.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: How to improve line tracing accuracy?

· A: Keep a clean background and use a color that is significantly different from the background.

Face Detection

Face detection has a wide range of application, we will learn how to do face detection in this tutorial.

_images/081.png

Detecting Faces

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for face detection:

_images/09.png

Sample Program:

_images/012.png

Program Flow

Download the program to the Micro:bit, the pixel on the Micro:bit 把程式下載到Microbit上,可以看到Microbit的點陣隨著人臉的移動而移動。

_images/04-14.png

Mapping coordinates

We can use the map function to map a value to a new range.

_images/022.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

Classifier Model Training

Machine Learning may seem like a farfetched concept. AI Camera is already capable of Machine Learning features in the form of object classification. KOI can be trained to recognize objects.

In this section, we will learn how to use the Machine Learning feature to easily train a object classification model.

Install an SD Card

The trained model will be stored on an SD card, without an SD card we won’t be able to save this model.

_images/021.png

Training a Model

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for machine learning:

_images/8.png

Sample Program

_images/trainercode.png

The model can be saved in a .bin or .json file.
e.g. aaa.json or aaa.bin
Program Flow

1: Download the program to the Micro:bit.

2: Put the first object in front of the camera and press B, slightly change angle and repeat about 3 times.

3: Press A to start training the next object.

4: Repeat the process until all objects have been analyzed.

The sample program has set the maximum number of object to 4, this can be changed to your liking.
A maximum of 40 images and 40 objects is supported by KOI.

5: Press A and B simultaneously to save the model.

The file name cannot include spaces, and it must be a bin or json file.
Demo video

_images/image6365.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: KOI gives a warning message when I try to train a classifier.

· A: The classifier hasn’t been reset.

· Solution: Run the block for classifier reset, KOI will display a success message.

Classifier Model Predicting

In the previous section, we have trained a classifier model. In this section, we will use this model to classify objects.

Install an SD Card

The trained model will be stored on an SD card, without an SD card we won’t be able to save this model.

_images/021.png

Running a Model

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for machine learning:

_images/8.png

Sample Program:

_images/run2.png

The model can be saved in a .bin or .json file.
e.g. aaa.json or aaa.bin
Program Flow

1: Download the program to the Micro:bit.

2: Press button A to load the classifier model.

3: Put the object in front of the camera. Press button B to run the classifier.

4: The tag of the object will be displayed on the Micro:bit.

Demo video:

_images/9.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: KOI gives a warning message when I try to train a classifier.

· A: The classifier hasn’t been reset.

· Solution: Run the block for classifier reset, KOI will display a success message.

Voice Recognition (Firmware v1.9.5 or above)

KOI is able to recognize our commands after training.

Recognizing Voice Commands

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for voice recognition:

_images/11.png

Sample Program

_images/21.png

Program Flow

1: Download the program to the Micro:bit.

2: Press A and record the first command. A green color will be shown if the command has been successfully added. Otherwise red will be shown.

3: Press B to continue, you can now repeak step 2 and record the next command.

4: Repeat step 2-3 to record all your commands.

    AI Camera KOI has the capacity for 10 voice samples.

5: Press A and B at the same time to recognize a command. A green color will be shown if KOI successfully recognizes your command, else it will show a red color. The command ID will be shown on Micro:bit.

Voice Recognition Demo Video

_images/31.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: KOI displays red everytime I try to record my command.

· A: The noise level hasn’t been calibrated, it is essential to run the block before voice recognition.

Voice Recognition Train Model(KOI v1.12.0)

From KOI v1.12.0 onwards, saving and loading a voice recognition model is supported.

Install an SD Card

The trained model will be stored on an SD card, without an SD card we won’t be able to save this model.

_images/021.png

Training a Voice Recognition Model

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for Voice Recognition:

_images/0.6.4.png

Sample Program:

_images/42.png

Program Flow

1: Download the program to the Micro:bit.

2: Press A to record the first command. KOI’s screen will display green upon a successful record.

3: Press B to record the first command. KOI’s screen will display green upon a successful record.

AI Camera has the capacity for 10 voice samples.

4: Press A and B at the same time to save the model.

The saved model must be in a .json format, or else it will not work.
Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: KOI displays red everytime I try to record my command.

· A: The noise level hasn’t been calibrated, it is essential to run the block before voice recognition.

Voice Recognition Load Model(KOI v1.12.0)

From KOI v1.12.0 onwards, saving and loading a voice recognition model is supported.

Install an SD Card

The trained model will be stored on an SD card, without an SD card we won’t be able to save this model.

_images/021.png

Using a Trained Model

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for Voice Recognition:

_images/0.6.4.png

Sample Program

_images/51.png

Program Flow

1: Download the program to the Micro:bit.

2: Press A to load the trained model.

3: Press B to recognize a voice command. KOI will display green upon a successful recognition.

4: Micro:bit will display the tag of the recognized command.

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: KOI displays red everytime I try to record my command.

· A: The noise level hasn’t been calibrated, it is essential to run the block before voice recognition.

Internet of Things (KOI v1.9.5)

The Wifi capabilities of KOI allows it to access IoT platforms.

Connecting to IoT Platforms

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for IoT:

_images/12.png

Sample Code
This tutorial just serves as a general example for communicating with MQTT servers, different MQTT servers may require different credentials.
ThingSpeak

Refer to this page for ThingSpeak tutorials: ThingSpeak Tutorial

MakerCloud

MakerCloud

For MakerCloud Users, please refer to: MakerCloud Tutorial

_images/91.png

Program Flow

1: Download the program to the Micro:bit.

2: Press A and B at the same time and wait for KOI to connect to the Wifi network.

KOI can store the Wifi and MQTT credentials, there is no need to run these blocks everytime we use these functions.

3: Press A to upload a random number to the MQTT.

4: Press B to read the data from the MQTT.

5: KOI will display the number on its screen.

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

Internet Time (KOI v1.12.0)

After connecting to the Wifi, KOI is able to tell the current time to function as a clock.

Getting internet time

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for IoT:

_images/71.png

Sample Program

_images/81.png

Internet time returns an array-like object that has the format of: [year, month, day, hour, minute, second]
In the sample program, the current hour and the minute is obtained by index 3 and 4.
Program Flow

1: Download the program to the Micro:bit.

2: Press A to show the current time. (Timezone: GMT+8)

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

Face Recognition (KOI v1.9.5)

Face Recognition is the technology of recognizing individuals from an image. This function can be realized on KOI.

Face Recognition

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for Face Recognition:

_images/13.png

Sample Program:
Wifi connection is required for Face Recognition.

Face Recognition is a free feature, therefore you must choose a unique name for your class.
For example, common names like testing, test1, class01 are already made by others.
A maximum of 20 images can be stored in each class.

_images/32.png

Program Flow

1: Download the program to Micro:bit.

2: Press A to store a face to the class.

3: After a shortwhile, KOI will display the gender and the age of the face detected.

You can change the name and reupload the program to store another face.

6: Press B to recognize a face

7: KOI will display the name of this face and its confidence. If a new face is detected, KOI will display “stranger”.

Confidence level can range from 0 to 100.
Face Recognition Demo Video

_images/43.png

Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

3: KOI shows “Pic not has face” after taking a picture.

· A: This is normal because the focus may be off, try taking the picture again.

3: KOI shows “Get timeout” after taking a picture.

· A: This is because network conditions may not be good enough, or sometimes the server may be too busy.

Text-to-Speech (KOI v1.9.5)

By using BaiduAI, KOI can realize Text-to-Speech.

Using Text to Speech

modules/functional_module/PWmodules/images/mcbanner.png

Load KOI Extension: https://github.com/KittenBot/pxt-koi
Loading Extensions

Blocks for Text to Speech:

_images/14.png

Sample Program:
Wifi connection is required to use text to speech function.

_images/22.png

Program Flow

1: Download the program to the Micro:bit.

2: Press A and KOI will say “Hello” in English.

3: Press B and KOI will say “Good Morning” and “I am happy” in English.

The text to speech function only supports short phrases(2-3 words) and there must be no spaces between the words.

4: Press A and B and KOI will say “123” in Putonghua.

MakeCode does not support Chinese chracters but BaiduAI does, so BaiduAI will treat numbers as Chinese.
Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

Makecode Extension Update

FAQ
1: There is no reaction after pressing the buttons on the Micro:bit.

· A: This is because KOI has a longer boot time than Micro:bit. When the power is turned on, Micro:bit has already ran the code for KOI initialization before KOI is ready.

· Solution: Reset your Micro:bit after KOI has been turned on. (The trick is to let KOI power on completely before initialization.)

2: Does KOI work with 3V input?

· A: No, KOI only works with 5V.

Meowbit發明家套件

Meowbit發明家套件是為Meowbit而開發的套件。這部分會詳細地介紹Meowbit發明家套件與其內容。

Meowbit發明家套件介紹

Meowbit發明家套件()

_images/4.png

Meowbit發明家套件是一套針對Meowbit而開發的教育套件,為Meowbit提供多款電子硬件擴展Meowbit的功能性。發明家套件正正發揮了Meowbit上搭載了引腳這個優勢,配合各款感應器和積木,Meowbit的玩法就變得更加多,可以創作更多獨特的遊戲!

Meowbit發明家套件內容

  • Robotbit擴展板x1

  • 滑動電位器x1

  • 紅外線避障/巡線感應器x1

  • 聲音感應器x1

  • 全彩LED燈x1

  • 貓耳超聲波x1

  • GeekServo 9G電機x1

  • GeekServo 9G舵機x1

  • 公對公杜邦線x20

  • 公對母杜邦線x20

  • 18650鋰電池x1

  • 導電銅片貼紙x1

  • USB數據線x1

  • 積木包x1

  • 造型紙板包x1

  • 雙面膠紙x1

  • Robotbit底座x1

產品特色

_images/2.jpg

  1. Meowbit的彩屏可以顯示動態的畫面和文字,令你的創作更美觀和更靈活

  2. 支援MakeCode Arcade與Kittenblock編程,編程門檻更低。

產品參數

  • 包裝尺寸:195x175x70mm

  • 淨重:650g

套件案例介紹

1. 計步裝置

_images/step.jpg

2. 拔河比賽

_images/tugofwar2.jpg

3. 硬幣收藏家

_images/coin4.jpg

4. 智能儲物箱

_images/coin2.jpg

5. 灌籃高手

_images/ball2.jpg

6. 鋼琴大師

_images/piano2.jpg

7. 聲控彩燈

_images/light1.jpg

8. 防噪窗

_images/window2.jpg

9. 巡邏智械

_images/trace2.jpg

10. 避障智貓

_images/avoid2.jpg

11. 智能停車系統

_images/parking.jpg

Meowbit發明家套件魔塊教學

Meowbit發明家套件魔塊教學

Meowbit發明家套件組裝資料

這裡合集了Meowbit發明家套件的模型組裝資料。

Meowbit發明家套件積木零件清單

Meowbit發明家套件的零件清單,請核實積木包沒有缺少零件。

零件清單

_images/1.jpg

_images/21.jpg

Meowbit發明家套件案例

Meowbit發明家套件案例說明書與教學

1. 計步裝置

_images/step.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

本案例毋須接線。

模型玩法

將計步器戴在手上,你的步數會顯示在Meowbit上。

2. 拔河比賽

_images/tugofwar1.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/tugofwar_wire.png

模型玩法

這是一個雙人遊戲,兩位玩家分別使用A鍵和左方向鍵控制,不停按下按鍵,直至對方越過白線落敗為止。

3. 硬幣收藏家

_images/coin3.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/coin_wire.png

模型玩法

這是一個錢箱,能夠幫助你儲錢。將硬幣放在錢箱的手上,它就會把硬幣吞下。直至錢箱裏儲夠20個硬幣才可以按A鍵打開錢箱將錢幣拿出來。

4. 智能儲物箱

_images/coin1.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/light_wire.png

模型玩法

對著模型拍手,燈泡會轉換顏色。

5. 灌籃高手

_images/ball1.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/ball_wire.png

模型玩法

打開電源後,屏幕會開始倒數,籃球架會左右移動。嘗試在限時之內入球數量創新高吧!

疑難排解
1: 為什麼我巡線感應器的靈敏度這麼低?
巡線感應器的檢測距離可以調較,靈敏度設定位於感應器上的藍色旋鈕,請使用螺絲批調節檢測距離(向左調高,向右調低)。
6. 鋼琴大師

_images/piano1.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/piano_wire.png

模型玩法

按下琴鍵發出音調,使用滑動電位器調整音調的高低。

7. 聲控彩燈

_images/light2.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/light_wire.png

模型玩法

對著模型拍手,燈泡會轉換顏色。

8. 防噪窗

_images/window1.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/window_wire.png

模型玩法

遇到環境的噪音過大的時候,窗口會自動關上。待環境噪音回復至平靜水平時才會自動打開。

9. 巡邏智械

_images/trace1.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/trace_wire1.png

_images/trace_wire2.png

模型玩法

車子會自動跟著地上的黑線路線行走。

疑難排解
1: 為什麼我巡線感應器的靈敏度這麼低?
巡線感應器的檢測距離可以調較,靈敏度設定位於感應器上的藍色旋鈕,請使用螺絲批調節檢測距離(向左調高,向右調低)。以巡線車來說,請調較感應器直至在白色區域上會亮紅燈,在黑色線段上會熄滅。
10. 避障智貓

_images/avoid1.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/avoid_wire.png

_images/trace_wire2.png

模型玩法

車子會在地上行走,遇到障礙物時會停下來,探測出路然後繼續行走。

11. 智能停車系統

_images/parking.jpg

教材資源包下載

包括說明書: 資源包下載地址

參考接線

_images/parking_wire.png

模型玩法

將車子駛到閘前,閘門打開之後可以駛到車位停泊。Meowbit上會顯示剩餘的車位。

疑難排解
1: 為什麼我巡線感應器的靈敏度這麼低?
巡線感應器的檢測距離可以調較,靈敏度設定位於感應器上的藍色旋鈕,請使用螺絲批調節檢測距離(向左調高,向右調低)。