# KOI 2 in MicroPython Quick Start Guide

## <mark style="color:orange;">**Wiring**</mark>

### **1. Use with Robotbit EDU**

Use the cable included to connect KOI to Robotbit.

Connect KOI 2 to the serial port of the Robotbit EDU as shown in the illustration.

As Robotbit EDU uses P2 and P12 for its serial port, you will need to select the appropiate pins in the MakeCode program.

{% hint style="info" %}
If you wish to power the KOI using USB power, please remove the black(GND) and red(5V) wires.
{% endhint %}

<figure><img src="https://686851495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7Bv9xBdKh3R9w6Vp7asd%2Fuploads%2FlSf5amP5cH73qyYeGQFg%2Fedu_wiring.png?alt=media&#x26;token=4bb63a7b-308e-4988-9b7b-52a91384bf1b" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
KOI 2 RX Port(Yellow) Connects to Robotbit TX Port(P2)

KOI 2 TX Port(Blue) Connects to Robotbit RX Port(P12)
{% endhint %}

### **2. Use with Robotbit 2.2**

Use the cable included to connect KOI to Robotbit.

Refers to the following illustration for correct wiring.

&#x20;           Black - GND

&#x20;           Red - 5V

&#x20;           Yellow - P2 (TX)

&#x20;           Blue - 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.
```

<figure><img src="https://kittenbothk.readthedocs.io/en/latest/_images/robotbit_connection1.png" alt=""><figcaption></figcaption></figure>

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

Ensure the connection is correct and switch the power on.

<figure><img src="https://kittenbothk.readthedocs.io/en/latest/_images/robotbit_connection2.png" alt=""><figcaption></figcaption></figure>

<figure><img src="https://kittenbothk.readthedocs.io/en/latest/_images/robotbit_connection3-1.png" alt=""><figcaption></figcaption></figure>

### Quick Start on MicroPython

Open KittenCode in browser.

{% embed url="<https://codebeta.kittenbot.net/home>" %}

Create a new project. (Futureboard or Futureboard Lite)

<figure><img src="https://686851495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7Bv9xBdKh3R9w6Vp7asd%2Fuploads%2FjuMzmvTbEtaUvm2fXXkb%2Fimage.png?alt=media&#x26;token=087fb641-6f79-4b01-bec7-9bd101894bf8" alt=""><figcaption></figcaption></figure>

Turn on REPL mode on the Futureboard by connecting it on KittenCode.

<div><figure><img src="https://686851495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7Bv9xBdKh3R9w6Vp7asd%2Fuploads%2Fh73ckaGfH9QqZzd2QkNE%2Fimage.png?alt=media&#x26;token=373a864c-9907-46be-9385-9e992bb796e5" alt=""><figcaption></figcaption></figure> <figure><img src="https://686851495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7Bv9xBdKh3R9w6Vp7asd%2Fuploads%2FvoRHKJKPsKlqWC87hf5f%2Fimage.png?alt=media&#x26;token=aeb4eabb-2f09-40ac-b2a6-bd222f9d91f7" alt=""><figcaption></figcaption></figure> <figure><img src="https://686851495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7Bv9xBdKh3R9w6Vp7asd%2Fuploads%2FjvEtQ3L5p6xxc8m4jdup%2Fimage.png?alt=media&#x26;token=4f6157d2-db1c-4edd-8ce8-7cffd06a9c85" alt=""><figcaption></figcaption></figure></div>

Click Run to run the program or Upload to store the program onto your Futureboard.

<figure><img src="https://686851495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7Bv9xBdKh3R9w6Vp7asd%2Fuploads%2FnHm7r8SgIGG5S1tuY6dh%2Fimage.png?alt=media&#x26;token=ee25b307-5a2d-4545-978c-8d77549d4318" alt=""><figcaption></figcaption></figure>
