Skip to content

Code for controlling JAXA KIBO robot in the ISS (International Space Station)

Notifications You must be signed in to change notification settings

zero-abd/Astrobee-controller

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

7 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

JAXA Kibo Robot Programming Challenge - Astrobee Controller

๐ŸŽฅ Project Demo Video

Watch our Kibo-RPC Demo

Click the image above to watch our project demonstration in the International Space Station (ISS) starting at 22:44

๐Ÿ… Achievement

๐ŸŽ‰ 5th Crew Award Winner - Competing against 1,685 students from 421 teams around the globe in the Kibo Robot Programming Challenge Finals!


This repository contains the codebase for controlling NASA's Astrobee free-flying robot in the International Space Station (ISS), developed for participation in the Kibo Robot Programming Challenge (Kibo-RPC) Finals. The project demonstrates advanced robotics programming using Java, Gradle, TensorFlow, LiteRT, ZXing, and Docker.

๐Ÿš€ Project Overview

Team Paragon's Astrobee Controller features:

  • Astrobee Robot Movement: Programmed using Quaternions to navigate the Astrobee robot within the ISS via the KIBO API
  • AI-Powered Tool Detection: Trained a TensorFlow model with simulated data to detect 8 different tools
  • AR Code Recognition: Utilized ZXing Java library to detect AR codes for precise mission execution
  • Optimized Performance: Configured with OpenCV and TensorFlow Lite to run efficiently on Astrobee's limited processor

๐Ÿ›  Technologies Used

  • Java - Primary programming language
  • Gradle - Build automation and dependency management
  • TensorFlow/TensorFlow Lite - Machine learning model for tool detection
  • OpenCV - Computer vision processing
  • ZXing - QR/AR code detection
  • Docker - Containerization for development environment
  • Android SDK - APK development for Astrobee platform

๐ŸŒ Understanding Quaternions for Space Navigation

Quaternions are fundamental to our robot's movement system, providing mathematically robust 3D rotation without gimbal lock:

Quaternion Rotation Visualization

Quaternion rotation sequence showing smooth interpolation between orientations in 3D space

Why Quaternions for Space Robotics?

  • No Gimbal Lock: Unlike Euler angles, quaternions avoid mathematical singularities
  • Smooth Interpolation: Essential for precise movement in microgravity
  • Compact Representation: 4 values (w, x, y, z) represent any 3D rotation
  • Stable Computation: Numerically stable for continuous robot control

๐Ÿ”ง Hardware Specifications

The Astrobee robot operates on resource-constrained hardware in the ISS:

  • High-Level Processor (HLP): Intel Atom x5-E3940
  • Operating Environment: Microgravity, limited computational resources
  • Memory: Limited RAM requiring optimized algorithms
  • Power: Battery-powered operation requiring energy-efficient code

๐Ÿ“‹ Prerequisites

System Requirements

  • Operating System: Ubuntu 16.04 LTS 64-bit (recommended for Astrobee compatibility)
  • Memory: Minimum 4 GB RAM (8 GB recommended)
  • Java Development Kit (JDK): Version 8 or higher
  • Gradle: Version 6.0 or higher
  • Docker: Latest stable version
  • Python: Version 3.6+ (for TensorFlow model training)

Required Software

๐Ÿš€ Setup Instructions

1. Environment Setup

Install essential build tools:

sudo apt-get update
sudo apt-get install build-essential git openjdk-8-jdk

Verify Java installation:

java -version

2. Clone the Astrobee Flight Software

cd ~
git clone https://github.com/nasa/astrobee.git
cd astrobee
git clone https://github.com/nasa/astrobee_android.git android

3. Install Dependencies

cd ~/astrobee
./scripts/setup_host.sh

4. Configure Build Environment

./src/scripts/configure.sh -l -F -D
source ~/.bashrc

5. Build the Astrobee Software

catkin build
source devel/setup.bash

6. Clone This Repository

git clone <your-repository-url>
cd jaxa-kibo-controller

7. Build the APK

./gradlew build

๐ŸŽฏ Running the Simulator

Launch the Astrobee Simulator

  1. Start the simulation environment:
roslaunch astrobee sim.launch dds:=false robot:=sim_pub rviz:=true
  1. For visual representation (resource-intensive):
roslaunch astrobee sim.launch dds:=false robot:=sim_pub rviz:=true sviz:=true
  1. Deploy your APK to the simulated Astrobee robot through the Ground Data System (GDS)

๐Ÿค– Machine Learning Pipeline

Model Training

The TensorFlow model for tool detection is trained using our Kaggle notebook:

Training Notebook: 6th KRPC Training with Background

This notebook includes:

  • Synthetic data generation for 8 different tools
  • Data augmentation techniques
  • Model architecture optimization for embedded deployment

Model Conversion

Convert the trained model for deployment using our conversion notebook:

Conversion Notebook: Conversion Test

The conversion process:

  1. Exports the trained TensorFlow model
  2. Converts to TensorFlow Lite format
  3. Applies quantization for reduced model size
  4. Optimizes for Intel Atom x5-E3940 processor

Optimization for Astrobee's Processor

Given the Intel Atom x5-E3940 processor constraints:

  1. TensorFlow Lite Integration:

    • Model quantization reduces size by ~75%
    • INT8 quantization for faster inference
    • Optimized for x86 architecture
  2. OpenCV Optimization:

    • Hardware-accelerated functions
    • Memory-efficient image processing
    • Reduced computational complexity
  3. Performance Considerations:

    • Asynchronous processing for real-time performance
    • Memory pooling to prevent allocation overhead
    • Efficient quaternion calculations for movement

๐Ÿ“ Project Structure

jaxa-kibo-controller/
โ”œโ”€โ”€ app/
โ”‚   โ”œโ”€โ”€ src/main/
โ”‚   โ”‚   โ”œโ”€โ”€ java/jp/jaxa/iss/kibo/rpc/sampleapk/
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ MainActivity.java          # Main Android activity
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ YourService.java           # Core robot control logic
โ”‚   โ”‚   โ”œโ”€โ”€ res/
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ layout/                    # UI layouts
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ values/                    # App resources
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ xml/commands.xml           # Available robot commands
โ”‚   โ”‚   โ””โ”€โ”€ AndroidManifest.xml            # App configuration
โ”‚   โ””โ”€โ”€ build.gradle                       # App-level build configuration
โ”œโ”€โ”€ guest_science_library/                 # Astrobee guest science APIs
โ”œโ”€โ”€ kibo_rpc_api/                         # Kibo RPC API library
โ”œโ”€โ”€ build.gradle                          # Project-level build configuration
โ”œโ”€โ”€ settings.gradle                       # Gradle settings
โ””โ”€โ”€ README.md                            # This file

๐ŸŽฎ Mission Execution

The robot executes three main phases:

Phase 1: Navigation and Tool Detection

  • Navigate between predefined points using quaternion-based movement
  • Detect and photograph tools at each location
  • Use laser targeting for precise task completion

Phase 2: QR Code Recognition

  • Navigate to QR code location
  • Use ZXing library for code detection
  • Process QR message for mission completion

Phase 3: Mission Completion

  • Navigate to goal position
  • Report mission completion with appropriate message
  • Ensure safe docking procedure

๐Ÿ”ง Key Features

Intelligent Path Planning

  • Dynamic route optimization based on remaining time
  • Collision avoidance using Keep-Out Zones (KOZ)
  • Adaptive mission planning with multiple contingencies

Computer Vision Pipeline

  • Real-time tool detection using TensorFlow Lite
  • Robust QR code recognition with fallback mechanisms
  • Image preprocessing optimized for ISS lighting conditions

Precise Movement Control

  • Quaternion-based 6DOF movement
  • Sub-centimeter positioning accuracy
  • Momentum management in microgravity environment

๐Ÿ“Š Performance Metrics

  • Model Inference Time: <100ms per frame
  • Movement Precision: ยฑ2cm positioning accuracy
  • QR Detection Rate: >95% success rate
  • Mission Completion Time: Optimized for 7-hour ISS orbit window

๐Ÿ† Competition Preparation

For Kibo-RPC Finals:

  1. Test extensively in the simulator environment
  2. Validate all movement paths and timing calculations
  3. Optimize model performance for real ISS conditions
  4. Prepare contingency plans for various failure scenarios
  5. Document all code thoroughly for mission review

๐Ÿ‘ฅ Team Paragon

Team Paragon

Team Paragon - Dedicated to advancing space robotics through innovative programming solutions

๐Ÿ“š References and Resources

๐Ÿค Contributing

This project was developed for the Kibo Robot Programming Challenge. For questions or collaboration opportunities, please refer to the official competition guidelines.

๐Ÿ“„ License

This project is developed under the guidelines of the JAXA Kibo Robot Programming Challenge. Please refer to the official competition rules for usage restrictions.


Ready for the International Space Station! ๐Ÿš€

Developed by Team Paragon for the Kibo Robot Programming Challenge Finals

About

Code for controlling JAXA KIBO robot in the ISS (International Space Station)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages