Skip to main content

XGO Blockly - 图形化和 AI 编程 Web 服务器

Project description

XGO Blockly 图形化编程服务器

简介

XGO Blockly 是专为陆吾 XGO 机器人系列设计的图形化编程和 AI 编程服务器。通过简单的安装和启动,您可以在电脑浏览器中进行图形化编程,AI 编程,控制您的陆吾 XGO机器人。

支持的机型

  • XGO-Lite:轻量级四足机器狗,680g超轻设计,适合教育入门

  • XGO-Mini:十二自由度AI机器狗,配备机械臂和500万像素摄像头,支持AI视觉和语音识别

  • XGO-Rider:双轮足开源开发平台,基于树莓派,560g桌面级设计,支持AI边缘计算、自稳控制和地形跨越

  • 未来的机型将陆续加入。

安装要求

该 pip 包需要安装在陆吾 XGO 机器人系列的树莓派机器上。

安装步骤

  1. 进入指定目录

    cd /home/pi/RaspberryPi-CM5/
    
  2. 创建或激活虚拟环境

    首先检查是否已存在 blocklyvenv 虚拟环境:

    ls blocklyvenv
    

    如果不存在,请创建虚拟环境(注意:使用 --system-site-packages 参数确保继承系统包,避免 Picamera2 和 libcamera 依赖问题):

    python3 -m venv --system-site-packages blocklyvenv
    

    激活虚拟环境:

    source blocklyvenv/bin/activate
    
  3. 安装 xgo-blockly 包

    pip install xgo-blockly -i https://pypi.tuna.tsinghua.edu.cn/simple
    

    升级 xgo-blockly 包(如果已安装):

    pip install --upgrade xgo-blockly -i https://pypi.tuna.tsinghua.edu.cn/simple
    pip install protobuf==4.25.8 -i https://pypi.tuna.tsinghua.edu.cn/simple
    
  4. 单独安装 AI 识别依赖包

    由于包冲突的原因,需要单独安装 MediaPipe 等几个包:

    pip install onnxruntime==1.20.0 -i https://pypi.tuna.tsinghua.edu.cn/simple
    pip install mediapipe -i https://pypi.tuna.tsinghua.edu.cn/simple
    如果安装 tensorflow 时,报错,请先清理缓存:pip cache purge
    pip install tensorflow==2.15.0 -i https://pypi.tuna.tsinghua.edu.cn/simple
    pip install ml_dtypes==0.5.0 -i https://pypi.tuna.tsinghua.edu.cn/simple
    

启动服务

安装成功后,运行以下命令启动图形化编程和AI编程服务器:

xgo-blockly

使用方法

服务器启动后,在电脑上打开浏览器,访问树莓派的IP地址和端口号(默认端口号为8000,直接输入IP即可)即可开始图形化编程和AI编程。

功能特性

  • 🎯 图形化编程:拖拽式编程界面,简单易用
  • 🤖 AI编程辅助:智能代码生成和优化建议
  • 🔗 实时控制:直接控制陆吾机器人硬件
  • 🌐 Web界面:跨平台浏览器访问
  • 📱 响应式设计:支持电脑、平板等设备

版本更新记录

v1.0.0.1

  1. 调整 A、B 按键映射
  2. 增加豆包大模型开通管理引导

技术支持

如有问题或需要技术支持,请联系陆吾机器人技术团队。

联系方式: hello@xgorobot.com


XGO Blockly Visual Programming Server

Introduction

XGO Blockly is a visual programming and AI programming server designed specifically for the Luwu XGO robot series. Through simple installation and startup, you can perform visual programming and AI programming in your computer browser to control your Luwu XGO robot.

Supported Models

  • XGO-Lite: Lightweight quadruped robot dog, ultra-light 680g design, suitable for educational introduction

  • XGO-Mini: Twelve degrees of freedom AI robot dog, equipped with robotic arm and 5-megapixel camera, supporting AI vision and voice recognition

  • XGO-Rider: Wheeled-legged open source development platform, based on Raspberry Pi, 560g desktop-level design, supporting AI edge computing, self-balancing control and terrain crossing

  • More models will be added in the future.

Installation Requirements

This pip package needs to be installed on the Raspberry Pi of the Luwu XGO robot series.

Installation Steps

  1. Navigate to the specified directory

    cd /home/pi/RaspberryPi-CM5/
    
  2. Create or activate virtual environment

    First check if the blocklyvenv virtual environment already exists:

    ls blocklyvenv
    

    If it doesn't exist, create the virtual environment (Note: Use the --system-site-packages parameter to ensure inheritance of system packages and avoid Picamera2 and libcamera dependency issues):

    python3 -m venv --system-site-packages blocklyvenv
    

    Activate the virtual environment:

    source blocklyvenv/bin/activate
    
  3. Install xgo-blockly package

    pip install xgo-blockly
    

    Upgrade xgo-blockly package (if already installed):

    pip install --upgrade xgo-blockly
    pip install protobuf==4.25.8
    
  4. Install AI recognition dependencies separately

    Due to package conflicts, MediaPipe and several other packages need to be installed separately:

    pip install onnxruntime==1.20.0
    pip install mediapipe
    # If there's an error when installing tensorflow, please clear the cache first: pip cache purge
    pip install tensorflow==2.15.0
    pip install ml_dtypes==0.5.0
    

Starting the Service

After successful installation, run the following command to start the visual programming and AI programming server:

xgo-blockly

Usage

After the server starts, open a browser on your computer and visit the Raspberry Pi's IP address and port number (default port is 8000) to begin visual programming and AI programming.

Features

  • 🎯 Visual Programming: Drag-and-drop programming interface, simple and easy to use
  • 🤖 AI Programming Assistant: Intelligent code generation and optimization suggestions
  • 🔗 Real-time Control: Direct control of Luwu robot hardware
  • 🌐 Web Interface: Cross-platform browser access
  • 📱 Responsive Design: Supports computers, tablets and other devices

Version History

v1.0.0.1

  1. Adjusted A and B button mapping
  2. Added Doubao AI model activation and management guide

Technical Support

If you have any questions or need technical support, please contact the Luwu Robotics technical team.

Contact: hello@xgorobot.com

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

xgo_blockly-1.0.4.1.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

xgo_blockly-1.0.4.1-py3-none-any.whl (1.2 MB view details)

Uploaded Python 3

File details

Details for the file xgo_blockly-1.0.4.1.tar.gz.

File metadata

  • Download URL: xgo_blockly-1.0.4.1.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for xgo_blockly-1.0.4.1.tar.gz
Algorithm Hash digest
SHA256 bc9cc0a6b86122a6cd4a2b2fb88f6a517db9d0ea195187183515dd2087aa60ff
MD5 63f9a4a7ad72d995171585160fa156f9
BLAKE2b-256 977b91f82788dca087ad2dfcd46d6c45a1badcd9a42b6c05239b9c11a9838189

See more details on using hashes here.

File details

Details for the file xgo_blockly-1.0.4.1-py3-none-any.whl.

File metadata

  • Download URL: xgo_blockly-1.0.4.1-py3-none-any.whl
  • Upload date:
  • Size: 1.2 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for xgo_blockly-1.0.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3533b70fe6fe7f80d460b0d0eb567a1a16002869799d11ca5ff463c38b6e124c
MD5 5d9d6edf0895e867e3b88a919ff35556
BLAKE2b-256 051c69e2096220d0863247d5d5692d23fb28daf2983a149244dcb6ec5b90ab76

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page