# 12V/Assembled

<mark style="color:yellow;">Your kit has been calibrated and teleoperated to make sure that it works well.</mark>

Upon receiving the assembled arm, follow these additional steps to complete the assembly.

Refer to the images and position the electronics and hardware appropriately.

<figure><img src="/files/Zq2H0SlYVLkNzEM2CCKQ" alt="" width="188"><figcaption></figcaption></figure>

You package consists of one leader + one follower arm + one mobile base.

<figure><img src="/files/HQHqk7vC5yMp573iJbab" alt="" width="188"><figcaption></figcaption></figure>

Place a 12V power supply and a servo board in the empty spots on your base plate as shown below.

<figure><img src="/files/uH3h7aEVUfb6PdsDbpMY" alt="" width="375"><figcaption></figcaption></figure>

Then,

1. Connect the wires from the 12V battery, DC plug connector, and power converter to the lever connector.
2. Attach the DC plug connector to the servo board to power the motor control board.
3. Connect the wires from the follower arm and mobile base to the motor control board.
4. You may find it easier to screw the follower arm to the top plate before connecting the top plate to the base plate.

<div><figure><img src="/files/KvRYfoxqOu4Ggi9Wdihj" alt="" width="188"><figcaption></figcaption></figure> <figure><img src="/files/D1peLbHgk2OkbDloUqO3" alt="" width="188"><figcaption></figcaption></figure></div>

<figure><img src="/files/GG7reJYkz1RK0GmKx58T" alt="" width="375"><figcaption></figcaption></figure>

Attach the Raspberry Pi to the top plate using M3 x 16 screws and nuts. Then, secure the top plate to the base plate with four more M3 x 16 screws

<figure><img src="/files/2h6Civ35h9KsSMLc9Flm" alt="" width="188"><figcaption></figcaption></figure>

Connect follower arm to top plate using 2 m3 x 30 screws. You are now ready for software!

Part II

1. For setting up the Raspberry Pi and its SD-card see: [Setup PI](https://www.raspberrypi.com/documentation/computers/getting-started.html). Here is explained how to download the [Imager](https://www.raspberrypi.com/software/) to install Raspberry Pi OS or Ubuntu.
2. Take the sd card and connect it to your laptop.
3. After setting up your Pi, you should enable and set up [SSH](https://www.raspberrypi.com/news/coding-on-raspberry-pi-remotely-with-visual-studio-code/) (Secure Shell Protocol) so you can log in to the Pi from your laptop without requiring a screen, keyboard, and mouse on the Pi. A great tutorial on how to do this can be found [here](https://www.raspberrypi.com/documentation/computers/remote-access.html#ssh). Logging into your Pi can be done in your Command Prompt (cmd) or, if you use VSCode you can use [this](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-ssh) extension. Here's a [video](https://www.youtube.com/watch?v=cOopQQIL8JU\&t=121s\&ab_channel=SusanB.) on how to do it.&#x20;
4. 1. Download source code on both pc as well as raspberry pi:

      ```
      git clone https://github.com/huggingface/lerobot.git
      cd lerobot
      ```

   2. Install miniconda (for raspberry pi)
      1. ```
         wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-aarch64.sh
         bash Miniconda3-latest-Linux-aarch64.sh
         ```
      2. ```
         source ~/.bashrc
         ```

   3. Install [miniconda](https://www.anaconda.com/docs/getting-started/miniconda/install#aws-graviton2%2Farm64) (for pc)

   4. Create a virtual environment with Python 3.10,

      ```
      conda create -y -n lerobot python=3.10
      ```

   5. Then activate your conda environment, you have to do this each time you open a shell to use lerobot:

      ```
      conda activate lerobot
      ```

   6. When using `miniconda`, install `ffmpeg` in your environment:

      ```
      conda install ffmpeg -c conda-forge
      ```

   7. Install 🤗 LeRobot:

      ```
      pip install -e .
      ```

      ####

   8. In addition to these instructions, you need to install the Feetech sdk on your Pi which you can skip on your laptop:

      Copied

      ```
      pip install -e ".[feetech]"
      ```

   9. Don't forget to Install LeRobot on laptop using the same steps as above \[step 4].
5. Make sure that one motor board is connected to you pc \[leader arm] and another to raspberry pi \[follower arm] and run on both:

```
python -m lerobot.find_port
```

Example output:

```
Finding all available ports for the MotorBus.
['/dev/tty.usbmodem575E0032081']
Remove the USB cable from your MotorsBus and press Enter when done.

[...Disconnect corresponding leader or follower arm and press Enter...]

The port of this MotorsBus is /dev/tty.usbmodem575E0032081
Reconnect the USB cable.
```

#### The port for the follower arm willl look like&#x20;

```python
Finding all available ports for the MotorBus.
['/dev/ttyACM0']
Remove the USB cable from your MotorsBus and press Enter when done.

[...Disconnect corresponding leader or follower arm and press Enter...]

The port of this MotorsBus is /dev/ttyACM0
Reconnect the USB cable.
```

#### 7. Calibration

Now we have to calibrate the leader arm and the follower arm. The wheel motors don’t have to be calibrated. The calibration process is very important because it allows a neural network trained on one robot to work on another.

#### 8. Calibrate follower arm (on mobile base)

Make sure the arm is connected to the Raspberry Pi and run this script or API example (on the Raspberry Pi via SSH) to launch calibration of the follower arm:

```
python -m lerobot.calibrate \
    --robot.type=lekiwi \
    --robot.id=my_awesome_kiwi # <- Give the robot a unique name
```

#### 9. Calibrate leader arm

Then, to calibrate the leader arm (which is attached to the laptop/pc). Run the following command of API example on your laptop:

```
python -m lerobot.calibrate \
    --teleop.type=so101_leader \
    --teleop.port=/dev/tty.usbmodem58760431551 \ # <- The port of your robot
    --teleop.id=my_awesome_leader_arm # <- Give the robot a unique name
```

10. Teleoperate LeKiwi

If you’re using a Mac, you might need to give Terminal permission to access your keyboard for teleoperation. Go to System Preferences > Security & Privacy > Input Monitoring and check the box for Terminal.

To teleoperate, SSH into your Raspberry Pi, and run `conda activate lerobot` and this command:

```
python -m lerobot.common.robots.lekiwi.lekiwi_host --robot.id=my_awesome_kiwi
```

Then on your laptop, also run `conda activate lerobot` and run the API example, make sure you set the correct `remote_ip` and `port` in `examples/lekiwi/teleoperate.py`.

```
python examples/lekiwi/teleoperate.py
```

Now you can move the leader arm and use the keyboard (w,a,s,d) to drive forward, left, backwards, right. And use (z,x) to turn left or turn right. You can use (r,f) to increase and decrease the speed of the mobile robot. Refer to the following table for more information on commands.

| W | Move forward   |
| - | -------------- |
| A | Move left      |
| S | Move backward  |
| D | Move right     |
| Z | Turn left      |
| X | Turn right     |
| R | Increase speed |
| F | Decrease speed |

10. Here's a concise guide to recording a dataset using [Hugging Face's documentation for more information](https://huggingface.co/docs/lerobot/lekiwi#record-a-dataset)

**Should you have any issue, reach out to <hello@partabot.com> !**


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://partabot-1.gitbook.io/partabot/lekiwi/12v-assembled-1.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
