Skip to main content

4.1 Installation and Integration

This section explains how to install and integrate the Kikobot C2 on Ubuntu 22.04 with ROS 2 Humble: install kikobot-backend and Kikobot Studio, connect over USB, and optionally integrate without the vendor UI.

1. What you are installing​

The C2 control stack runs on an Ubuntu PC connected to the arm via USB/UART:

ComponentLocationRole
UART firmwareControl PC (kikobot_uart_with_gripper_loop.py)Servos, gripper, signal motor, ROS topic bridge
Kikobot backend/opt/kikobot from .debMotion planning, RViz, WebSocket 8080, optional camera 8081
Kikobot StudioAppImage (optional)Operator UI; same API as custom integrators

C1 and C2 share the same PC installers; start with kikobot-backend c2 or select C2 in Studio.


2. Hardware requirements​

2.1 Robot & electronics​

  • Kikobot C2 arm with USB servo controller
  • USB data cable to control PC
  • Power for arm and controller per your machine manual
  • Emergency stop verified before motion

2.2 Control PC​

ItemRequirement
OSUbuntu 22.04 (64-bit)
ROSROS 2 Humble (ros-humble-desktop recommended)
RAM8 GB+ (16 GB with RViz + camera)
USBPort for controller (often /dev/ttyUSB0)
CameraOptional USB/ROS camera for monitoring page

2.3 Optional​

  • Docker — [headless backend workflow](/docs/Kikobot C2/4.4 Headless Docker Workflow)
  • libfuse2 — run Kikobot Studio AppImage

3. Download packages​

Full list and checksums: [FAQ and Downloads](/docs/Kikobot C2/4.3 FAQ and Downloads).

FileDownload
Backendkikobot-backend_1.0.0_amd64.deb
Studiokikobot-studio_1.0.0_amd64.AppImage

C2 UART firmware is included in the backend package (no separate MCU flash step for the default C2 stack).


4. One-time PC setup (ROS 2 Humble)​

sudo apt update
sudo apt install -y ros-humble-desktop

Minimal ROS packages for backend-only:

sudo apt install -y ros-humble-xacro ros-humble-rviz2 ros-humble-robot-state-publisher \
ros-humble-joint-state-publisher ros-humble-joint-state-publisher-gui ros-humble-kdl-parser

Camera preview (recommended for C2 monitoring page):

sudo apt install -y ros-humble-web-video-server

Python dependency for WebSocket bridge (if missing):

pip3 install --break-system-packages 'websockets>=12'

5. Install Kikobot backend​

sudo apt install -y libfuse2 python3-pip
sudo dpkg -i kikobot-backend_1.0.0_amd64.deb
kikobot-verify-backend

Payload highlights:

  • ROS install: /opt/kikobot/ros/install/
  • C2 firmware script: /opt/kikobot/share/c2/kikobot_uart_with_gripper_loop.py
  • Docs: /opt/kikobot/share/doc/WEBSOCKET_INTEGRATION_GUIDE.pdf

Upgrade later:

sudo kikobot-install-backend /path/to/kikobot-backend_1.0.0_amd64.deb

6. USB / serial setup​

  1. Connect C2 controller USB to the PC.
  2. List devices:
ls -l /dev/serial/by-id/ 2>/dev/null
python3 /opt/kikobot/share/c2/kikobot_uart_with_gripper_loop.py --list-ports
  1. Common paths: /dev/ttyUSB0, /dev/ttyACM0.
  2. Add user to dialout if needed: sudo usermod -aG dialout "$USER" (re-login).

7. First run — Kikobot Studio​

chmod +x kikobot-studio_1.0.0_amd64.AppImage
./kikobot-studio_1.0.0_amd64.AppImage
  1. Allow backend startup (~10 s).
  2. Select C2.
  3. Connect ws://localhost:8080 (or robot PC IP).
  4. Start Firmware → choose serial port.
  5. Confirm joint_states and optional camera at http://<host>:8081/stream?topic=/camera/image_raw.

8. First run — backend & integrators​

kikobot-backend c2

Wait for: WebSocket bridge listening on port 8080.

ScenarioCommand
Headless / serverexport KIKOBOT_HEADLESS=1 && kikobot-backend c2
systemdsudo systemctl enable --now kikobot-backend@c2
Override firmware scriptexport KIKOBOT_C2_FIRMWARE_SCRIPT=/path/to/script.py

Typical integration flow​

1. sudo dpkg -i kikobot-backend_*.deb && kikobot-verify-backend
2. kikobot-backend c2
3. ws://<robot-pc>:8080 → firmware_status → start_firmware (/dev/ttyUSB0)
4. home / motion_plan / jog from your application

API detail: [Software, API and ROS](/docs/Kikobot C2/4.2 Software API and ROS).


9. Docker / headless deployment (overview)​

For factory cells or cloud-adjacent PCs without a display:

  1. Build or use an image with ROS Humble + kikobot-backend installed.
  2. Pass through USB: --device=/dev/ttyUSB0:/dev/ttyUSB0
  3. Publish port 8080 if clients run on the host: -p 8080:8080
  4. Set KIKOBOT_HEADLESS=1 and run kikobot-backend c2
  5. Keep ROS_DOMAIN_ID consistent (backend default domain 0)

Step-by-step: repository guide docs/HEADLESS_DOCKER_CLIENT_WORKFLOW.md (also referenced from CLIENT_INSTALL.txt).


10. Network & ports​

PortService
8080WebSocket JSON API
8081MJPEG camera (/stream?topic=/camera/image_raw)

Open 8080 (and 8081 if needed) on the robot PC firewall for LAN clients.


11. Physical integration checklist​

StepVerification
Mechanical mountingArm secured; cable dress clear of workspace
Power & E-stopE-stop stops motion; power cycle procedure documented
USBStable port; avoid unpowered hubs
Softwarekikobot-verify-backend OK
Firmwarefirmware_status → running
Homehome command reaches C2 home pose safely
Camera (if used)Browser or UI shows live stream on 8081

C2 home joints (deg): [92.53, 5.93, 102.73, 4.26, 90.07, 105.98]


12. Logs​

FilePurpose
/tmp/kikobot_c2_display.logRViz, planner, action servers
/tmp/kikobot_websocket.logWebSocket bridge
/tmp/kikobot_firmware.logUART firmware subprocess
/tmp/kikobot_web_video.logCamera node (if enabled)
/tmp/kikobot_image_handler.logImage handler (if enabled)

  • [Software, API and ROS](/docs/Kikobot C2/4.2 Software API and ROS)
  • [FAQ and Downloads](/docs/Kikobot C2/4.3 FAQ and Downloads)
  • [Kikobot C1 installation](/docs/Kikobot C1/3.4 Installation and Integration)