Skip to main content

No project description provided

Project description

Codroid Robot Python SDK

Codroid 机器人 Python 软件开发工具包。支持 TCP 指令控制、实时数据 (CRI) 监控以及运动路径规划。

PyPI - Version PyPI - Python Version


Table of Contents

🚀 快速开始

1. 前置条件

  • Python: 3.8 及以上版本。
  • Hatch: 本项目使用 Hatch 作为项目管理工具。

安装 Hatch:

pipx install hatch
# 或者使用 pip (如果系统允许)
pip install hatch

2. 获取代码与初始化

git clone <your-repo-url>
cd CodroidSDK/python

3. 运行示例程序

使用 Hatch 运行示例是最简单的方法,它会自动处理所有依赖和环境路径。

# 运行基础使用示例
hatch run python examples/01_basic_usage.py

Installation

pip install codroid-robot-sdk

Basic Usage

from codroid import CodroidControlInterface

# Initialize and connect automatically
with CodroidControlInterface(host="192.168.1.136") as robot:
    robot.to_remote()
    robot.switch_on()

🛠️ Hatch 开发工作流

本项目采用了现代 Python 的 src 布局,建议通过以下命令进行开发:

进入开发 Shell

如果你想在一个持久的虚拟环境中工作,可以进入 Hatch Shell:

hatch shell
# 进入 shell 后直接运行 python
python examples/01_basic_usage.py

构建项目

生成可分发的 .whl 和 .tar.gz 文件:

hatch build

文档预览

本项目配置了 mkdocs 文档环境:

# 启动本地文档服务器
hatch run docs:serve

📂 目录结构说明

  • src/codroid/: SDK 核心源码。
    • CodroidControlInterface.py: 主控制类。
    • cri.py: 实时数据流处理。
    • models.py: 数据模型与枚举定义。
  • examples/: 示例程序目录。
  • pyproject.toml: 项目配置文件 (Hatch 配置)。

License

codroid is distributed under the terms of the MIT license.

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

codroid_robot_sdk-1.2.0.tar.gz (26.2 kB view details)

Uploaded Source

Built Distribution

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

codroid_robot_sdk-1.2.0-py3-none-any.whl (23.4 kB view details)

Uploaded Python 3

File details

Details for the file codroid_robot_sdk-1.2.0.tar.gz.

File metadata

  • Download URL: codroid_robot_sdk-1.2.0.tar.gz
  • Upload date:
  • Size: 26.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Hatch/1.16.5 cpython/3.10.12 HTTPX/0.28.1

File hashes

Hashes for codroid_robot_sdk-1.2.0.tar.gz
Algorithm Hash digest
SHA256 303f6af6710b1f53946440954676d2fdab78a65dd939827ae3acc2c522c0a9b3
MD5 85ae99a9656df0c7f8784976871c8549
BLAKE2b-256 16e1e73935fa231c9caa7afca9f487a13f9e343122d54065edef13aeb7ea5666

See more details on using hashes here.

File details

Details for the file codroid_robot_sdk-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: codroid_robot_sdk-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 23.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Hatch/1.16.5 cpython/3.10.12 HTTPX/0.28.1

File hashes

Hashes for codroid_robot_sdk-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fdbdd588c6b6db96c08d470ed456304aac244e4206a836aac610fc37ca4aa288
MD5 968184b397354ddf3fe1d5a09b2e4484
BLAKE2b-256 cc62bd87b07c709c8d7a12f39ea9197ce0116b0c6cc3c8cae3dc75f995dbe52e

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