physicalai-stararm-plugin 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- physicalai_stararm_plugin-0.1.0/.gitignore +219 -0
- physicalai_stararm_plugin-0.1.0/PKG-INFO +81 -0
- physicalai_stararm_plugin-0.1.0/README.md +62 -0
- physicalai_stararm_plugin-0.1.0/pyproject.toml +54 -0
- physicalai_stararm_plugin-0.1.0/src/physicalai_stararm_plugin/__init__.py +58 -0
- physicalai_stararm_plugin-0.1.0/src/physicalai_stararm_plugin/_urdf.py +31 -0
- physicalai_stararm_plugin-0.1.0/src/physicalai_stararm_plugin/constants.py +35 -0
- physicalai_stararm_plugin-0.1.0/src/physicalai_stararm_plugin/motion.py +171 -0
- physicalai_stararm_plugin-0.1.0/src/physicalai_stararm_plugin/stararm102fl.py +225 -0
- physicalai_stararm_plugin-0.1.0/src/physicalai_stararm_plugin/stararm102hd.py +308 -0
- physicalai_stararm_plugin-0.1.0/src/physicalai_stararm_plugin/stararm102ld.py +37 -0
- physicalai_stararm_plugin-0.1.0/src/physicalai_stararm_plugin/studio_catalog.py +400 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/base_link.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/link1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/link2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/link3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/link4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/link5.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/link6.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/link7_left.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/link7_right.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link1__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link1__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link1__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link1__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link1__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link2__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link2__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link2__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link2__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link2__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link3__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link3__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link3__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link3__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link3__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link5__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link5__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link5__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link5__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link5__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link5__5.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link5__6.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link5__7.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link6__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link6__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link6__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link6__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/fl/shells/link6__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/base_link.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/link1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/link2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/link3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/link4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/link5.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/link6.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/link7_left.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/link7_right.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/base_link__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/base_link__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link1__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link1__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link1__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link1__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link1__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link2__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link2__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link2__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link2__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link2__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link3__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link3__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link3__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link3__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link3__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link5__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link5__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link5__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link5__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link5__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link5__5.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link5__6.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link5__7.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link6__0.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link6__1.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link6__2.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link6__3.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/meshes/ld/shells/link6__4.STL +0 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/urdf/stararm102_fl_description.urdf +412 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/urdf/stararm102_hd_description.urdf +413 -0
- physicalai_stararm_plugin-0.1.0/urdf/stararm102/urdf/stararm102_ld_description.urdf +413 -0
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[codz]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
share/python-wheels/
|
|
24
|
+
*.egg-info/
|
|
25
|
+
.installed.cfg
|
|
26
|
+
*.egg
|
|
27
|
+
MANIFEST
|
|
28
|
+
|
|
29
|
+
# PyInstaller
|
|
30
|
+
# Usually these files are written by a python script from a template
|
|
31
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
32
|
+
*.manifest
|
|
33
|
+
*.spec
|
|
34
|
+
|
|
35
|
+
# Installer logs
|
|
36
|
+
pip-log.txt
|
|
37
|
+
pip-delete-this-directory.txt
|
|
38
|
+
|
|
39
|
+
# Unit test / coverage reports
|
|
40
|
+
htmlcov/
|
|
41
|
+
.tox/
|
|
42
|
+
.nox/
|
|
43
|
+
.coverage
|
|
44
|
+
.coverage.*
|
|
45
|
+
.cache
|
|
46
|
+
nosetests.xml
|
|
47
|
+
coverage.xml
|
|
48
|
+
*.cover
|
|
49
|
+
*.py.cover
|
|
50
|
+
.hypothesis/
|
|
51
|
+
.pytest_cache/
|
|
52
|
+
cover/
|
|
53
|
+
|
|
54
|
+
# Translations
|
|
55
|
+
*.mo
|
|
56
|
+
*.pot
|
|
57
|
+
|
|
58
|
+
# Django stuff:
|
|
59
|
+
*.log
|
|
60
|
+
local_settings.py
|
|
61
|
+
db.sqlite3
|
|
62
|
+
db.sqlite3-journal
|
|
63
|
+
|
|
64
|
+
# Flask stuff:
|
|
65
|
+
instance/
|
|
66
|
+
.webassets-cache
|
|
67
|
+
|
|
68
|
+
# Scrapy stuff:
|
|
69
|
+
.scrapy
|
|
70
|
+
|
|
71
|
+
# Sphinx documentation
|
|
72
|
+
docs/_build/
|
|
73
|
+
|
|
74
|
+
# PyBuilder
|
|
75
|
+
.pybuilder/
|
|
76
|
+
target/
|
|
77
|
+
|
|
78
|
+
# Jupyter Notebook
|
|
79
|
+
.ipynb_checkpoints
|
|
80
|
+
|
|
81
|
+
# IPython
|
|
82
|
+
profile_default/
|
|
83
|
+
ipython_config.py
|
|
84
|
+
|
|
85
|
+
# pyenv
|
|
86
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
+
# .python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
+
# install all needed dependencies.
|
|
95
|
+
# Pipfile.lock
|
|
96
|
+
|
|
97
|
+
# UV
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
uv.lock
|
|
102
|
+
|
|
103
|
+
# poetry
|
|
104
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
105
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
106
|
+
# commonly ignored for libraries.
|
|
107
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
108
|
+
# poetry.lock
|
|
109
|
+
# poetry.toml
|
|
110
|
+
|
|
111
|
+
# pdm
|
|
112
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
113
|
+
# pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
|
|
114
|
+
# https://pdm-project.org/en/latest/usage/project/#working-with-version-control
|
|
115
|
+
# pdm.lock
|
|
116
|
+
# pdm.toml
|
|
117
|
+
.pdm-python
|
|
118
|
+
.pdm-build/
|
|
119
|
+
|
|
120
|
+
# pixi
|
|
121
|
+
# Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
|
|
122
|
+
# pixi.lock
|
|
123
|
+
# Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
|
|
124
|
+
# in the .venv directory. It is recommended not to include this directory in version control.
|
|
125
|
+
.pixi
|
|
126
|
+
|
|
127
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
128
|
+
__pypackages__/
|
|
129
|
+
|
|
130
|
+
# Celery stuff
|
|
131
|
+
celerybeat-schedule
|
|
132
|
+
celerybeat.pid
|
|
133
|
+
|
|
134
|
+
# Redis
|
|
135
|
+
*.rdb
|
|
136
|
+
*.aof
|
|
137
|
+
*.pid
|
|
138
|
+
|
|
139
|
+
# RabbitMQ
|
|
140
|
+
mnesia/
|
|
141
|
+
rabbitmq/
|
|
142
|
+
rabbitmq-data/
|
|
143
|
+
|
|
144
|
+
# ActiveMQ
|
|
145
|
+
activemq-data/
|
|
146
|
+
|
|
147
|
+
# SageMath parsed files
|
|
148
|
+
*.sage.py
|
|
149
|
+
|
|
150
|
+
# Environments
|
|
151
|
+
.env
|
|
152
|
+
.envrc
|
|
153
|
+
.venv
|
|
154
|
+
env/
|
|
155
|
+
venv/
|
|
156
|
+
ENV/
|
|
157
|
+
env.bak/
|
|
158
|
+
venv.bak/
|
|
159
|
+
|
|
160
|
+
|
|
161
|
+
# mkdocs documentation
|
|
162
|
+
/site
|
|
163
|
+
|
|
164
|
+
# mypy
|
|
165
|
+
.mypy_cache/
|
|
166
|
+
.dmypy.json
|
|
167
|
+
dmypy.json
|
|
168
|
+
|
|
169
|
+
# Pyre type checker
|
|
170
|
+
.pyre/
|
|
171
|
+
|
|
172
|
+
# pytype static type analyzer
|
|
173
|
+
.pytype/
|
|
174
|
+
|
|
175
|
+
# Cython debug symbols
|
|
176
|
+
cython_debug/
|
|
177
|
+
|
|
178
|
+
# PyCharm
|
|
179
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
180
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
181
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
182
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
183
|
+
.idea/
|
|
184
|
+
|
|
185
|
+
# Abstra
|
|
186
|
+
# Abstra is an AI-powered process automation framework.
|
|
187
|
+
# Ignore directories containing user credentials, local state, and settings.
|
|
188
|
+
# Learn more at https://abstra.io/docs
|
|
189
|
+
.abstra/
|
|
190
|
+
|
|
191
|
+
# Visual Studio Code
|
|
192
|
+
# Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
|
|
193
|
+
# that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
|
|
194
|
+
# and can be added to the global gitignore or merged into this file. However, if you prefer,
|
|
195
|
+
# you could uncomment the following to ignore the entire vscode folder
|
|
196
|
+
.vscode/
|
|
197
|
+
|
|
198
|
+
# Ruff stuff:
|
|
199
|
+
.ruff_cache/
|
|
200
|
+
|
|
201
|
+
# PyPI configuration file
|
|
202
|
+
.pypirc
|
|
203
|
+
|
|
204
|
+
# Marimo
|
|
205
|
+
marimo/_static/
|
|
206
|
+
marimo/_lsp/
|
|
207
|
+
__marimo__/
|
|
208
|
+
|
|
209
|
+
# Streamlit
|
|
210
|
+
.streamlit/secrets.toml
|
|
211
|
+
|
|
212
|
+
# Misc
|
|
213
|
+
.DS_Store
|
|
214
|
+
|
|
215
|
+
# MuJoCo runtime logs
|
|
216
|
+
MUJOCO_LOG.TXT
|
|
217
|
+
|
|
218
|
+
|
|
219
|
+
tmp/
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: physicalai-stararm-plugin
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Fashion Star Arm 102 plugin (LD/HD leaders + FL follower) for PhysicalAI
|
|
5
|
+
Project-URL: Homepage, https://github.com/MarkRedeman/physicalai-plugins
|
|
6
|
+
Project-URL: Repository, https://github.com/MarkRedeman/physicalai-plugins
|
|
7
|
+
Project-URL: Issues, https://github.com/MarkRedeman/physicalai-plugins/issues
|
|
8
|
+
License-Expression: Apache-2.0
|
|
9
|
+
Requires-Python: >=3.12
|
|
10
|
+
Requires-Dist: loguru>=0.7
|
|
11
|
+
Requires-Dist: motorbridge-smart-servo>=0.0.4
|
|
12
|
+
Requires-Dist: numpy>=1.24
|
|
13
|
+
Requires-Dist: physicalai-studio-plugin
|
|
14
|
+
Requires-Dist: physicalai>=0.1.1
|
|
15
|
+
Requires-Dist: pydantic>=2.0
|
|
16
|
+
Provides-Extra: tests
|
|
17
|
+
Requires-Dist: pytest; extra == 'tests'
|
|
18
|
+
Description-Content-Type: text/markdown
|
|
19
|
+
|
|
20
|
+
# PhysicalAI Star Arm Plugin
|
|
21
|
+
|
|
22
|
+
Fashion Star Star Arm 102 plugin for [PhysicalAI](https://github.com/openvinotoolkit/physicalai). This package provides Star Arm 102-LD/102-HD leaders and a Star Arm 102-FL follower, and registers all variants with [Physical AI Studio](https://github.com/open-edge-platform/physical-ai-studio).
|
|
23
|
+
|
|
24
|
+
[](https://pypi.org/project/physicalai-stararm-plugin/)
|
|
25
|
+
[](https://pypi.org/project/physicalai-stararm-plugin/)
|
|
26
|
+
|
|
27
|
+
## Features
|
|
28
|
+
|
|
29
|
+
- Star Arm 102-LD leader driver (`StarArm102LDLeader`) for read-only teleoperation input
|
|
30
|
+
- Star Arm 102-HD leader driver (`StarArm102HDLeader`) with passive mode (default) and optional assist mode for hold/action commands
|
|
31
|
+
- Star Arm 102-FL follower driver (`StarArm102FLFollower`) for position control
|
|
32
|
+
- Studio catalog plugin entries for LD leader, HD leader, and FL follower
|
|
33
|
+
- Bundled `stararm102` URDF package
|
|
34
|
+
|
|
35
|
+
## Installation
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
uv add physicalai-stararm-plugin
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Quick start
|
|
42
|
+
|
|
43
|
+
```python
|
|
44
|
+
from physicalai.robot import connect
|
|
45
|
+
from physicalai_stararm_plugin import StarArm102FLFollower
|
|
46
|
+
|
|
47
|
+
robot = StarArm102FLFollower(port="/dev/ttyUSB1", baudrate=1_000_000)
|
|
48
|
+
|
|
49
|
+
with connect(robot) as arm:
|
|
50
|
+
obs = arm.get_observation()
|
|
51
|
+
arm.send_action(obs.joint_positions)
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
## Run with the PhysicalAI CLI
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/teleop-hd-to-fl.yaml
|
|
58
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/teleop-ld-to-fl.yaml
|
|
59
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/read-joints-hd.yaml
|
|
60
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/read-joints-ld.yaml
|
|
61
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/read-joints-fl.yaml
|
|
62
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/move-joints-fl.yaml
|
|
63
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/hold-hd.yaml
|
|
64
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/policy-follow-hd.yaml
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
## URDF
|
|
68
|
+
|
|
69
|
+
```python
|
|
70
|
+
from physicalai_stararm_plugin import get_urdf_path
|
|
71
|
+
|
|
72
|
+
urdf_dir = get_urdf_path()
|
|
73
|
+
star_urdf = urdf_dir / "stararm102" / "urdf" / "stararm102_description.urdf"
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
## Development
|
|
77
|
+
|
|
78
|
+
```bash
|
|
79
|
+
uv sync
|
|
80
|
+
uv run pytest packages/physicalai-stararm-plugin/tests/
|
|
81
|
+
```
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# PhysicalAI Star Arm Plugin
|
|
2
|
+
|
|
3
|
+
Fashion Star Star Arm 102 plugin for [PhysicalAI](https://github.com/openvinotoolkit/physicalai). This package provides Star Arm 102-LD/102-HD leaders and a Star Arm 102-FL follower, and registers all variants with [Physical AI Studio](https://github.com/open-edge-platform/physical-ai-studio).
|
|
4
|
+
|
|
5
|
+
[](https://pypi.org/project/physicalai-stararm-plugin/)
|
|
6
|
+
[](https://pypi.org/project/physicalai-stararm-plugin/)
|
|
7
|
+
|
|
8
|
+
## Features
|
|
9
|
+
|
|
10
|
+
- Star Arm 102-LD leader driver (`StarArm102LDLeader`) for read-only teleoperation input
|
|
11
|
+
- Star Arm 102-HD leader driver (`StarArm102HDLeader`) with passive mode (default) and optional assist mode for hold/action commands
|
|
12
|
+
- Star Arm 102-FL follower driver (`StarArm102FLFollower`) for position control
|
|
13
|
+
- Studio catalog plugin entries for LD leader, HD leader, and FL follower
|
|
14
|
+
- Bundled `stararm102` URDF package
|
|
15
|
+
|
|
16
|
+
## Installation
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
uv add physicalai-stararm-plugin
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
## Quick start
|
|
23
|
+
|
|
24
|
+
```python
|
|
25
|
+
from physicalai.robot import connect
|
|
26
|
+
from physicalai_stararm_plugin import StarArm102FLFollower
|
|
27
|
+
|
|
28
|
+
robot = StarArm102FLFollower(port="/dev/ttyUSB1", baudrate=1_000_000)
|
|
29
|
+
|
|
30
|
+
with connect(robot) as arm:
|
|
31
|
+
obs = arm.get_observation()
|
|
32
|
+
arm.send_action(obs.joint_positions)
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## Run with the PhysicalAI CLI
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/teleop-hd-to-fl.yaml
|
|
39
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/teleop-ld-to-fl.yaml
|
|
40
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/read-joints-hd.yaml
|
|
41
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/read-joints-ld.yaml
|
|
42
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/read-joints-fl.yaml
|
|
43
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/move-joints-fl.yaml
|
|
44
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/hold-hd.yaml
|
|
45
|
+
uv run physicalai run --config packages/physicalai-stararm-plugin/examples/runtime/policy-follow-hd.yaml
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
## URDF
|
|
49
|
+
|
|
50
|
+
```python
|
|
51
|
+
from physicalai_stararm_plugin import get_urdf_path
|
|
52
|
+
|
|
53
|
+
urdf_dir = get_urdf_path()
|
|
54
|
+
star_urdf = urdf_dir / "stararm102" / "urdf" / "stararm102_description.urdf"
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Development
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
uv sync
|
|
61
|
+
uv run pytest packages/physicalai-stararm-plugin/tests/
|
|
62
|
+
```
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling<1.30", "hatch-vcs"] # cap <1.30: hatchling>=1.30 emits Metadata 2.5, rejected by PyPI/twine (pypi/warehouse#19083)
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "physicalai-stararm-plugin"
|
|
7
|
+
#dynamic = ["0.1.0"]
|
|
8
|
+
version = "0.1.0"
|
|
9
|
+
description = "Fashion Star Arm 102 plugin (LD/HD leaders + FL follower) for PhysicalAI"
|
|
10
|
+
readme = "README.md"
|
|
11
|
+
requires-python = ">=3.12"
|
|
12
|
+
license = "Apache-2.0"
|
|
13
|
+
dependencies = [
|
|
14
|
+
"physicalai>=0.1.1",
|
|
15
|
+
"physicalai-studio-plugin",
|
|
16
|
+
"numpy>=1.24",
|
|
17
|
+
"loguru>=0.7",
|
|
18
|
+
"motorbridge-smart-servo>=0.0.4",
|
|
19
|
+
"pydantic>=2.0",
|
|
20
|
+
]
|
|
21
|
+
|
|
22
|
+
[project.optional-dependencies]
|
|
23
|
+
tests = ["pytest"]
|
|
24
|
+
|
|
25
|
+
[project.urls]
|
|
26
|
+
Homepage = "https://github.com/MarkRedeman/physicalai-plugins"
|
|
27
|
+
Repository = "https://github.com/MarkRedeman/physicalai-plugins"
|
|
28
|
+
Issues = "https://github.com/MarkRedeman/physicalai-plugins/issues"
|
|
29
|
+
|
|
30
|
+
[project.entry-points."physicalai.studio.catalog_plugins"]
|
|
31
|
+
stararm-102 = "physicalai_stararm_plugin.studio_catalog:register_physicalai_studio_plugin"
|
|
32
|
+
|
|
33
|
+
[tool.hatch.version]
|
|
34
|
+
source = "vcs"
|
|
35
|
+
tag-pattern = '^physicalai-stararm-plugin-v(?P<version>\d+(?:\.\d+)*)$'
|
|
36
|
+
raw-options = { search_parent_directories = true, git_describe_command = "git describe --dirty --tags --long --match physicalai-stararm-plugin-v*" }
|
|
37
|
+
|
|
38
|
+
[tool.hatch.build.targets.wheel]
|
|
39
|
+
packages = ["src/physicalai_stararm_plugin"]
|
|
40
|
+
|
|
41
|
+
[tool.hatch.build.targets.wheel.force-include]
|
|
42
|
+
"urdf" = "urdf"
|
|
43
|
+
|
|
44
|
+
[tool.hatch.build.targets.sdist]
|
|
45
|
+
include = [
|
|
46
|
+
"src/physicalai_stararm_plugin/**",
|
|
47
|
+
"urdf/**",
|
|
48
|
+
"README.md",
|
|
49
|
+
"pyproject.toml",
|
|
50
|
+
"LICENSE",
|
|
51
|
+
]
|
|
52
|
+
exclude = [
|
|
53
|
+
"examples/**",
|
|
54
|
+
]
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# ruff: noqa: PLC0415
|
|
2
|
+
|
|
3
|
+
"""Star Arm 102 plugin for PhysicalAI.
|
|
4
|
+
|
|
5
|
+
Provides Star Arm 102-LD/102-HD leader drivers and a Star Arm 102-FL follower
|
|
6
|
+
driver compatible with the ``physicalai.robot.Robot`` protocol.
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
from __future__ import annotations
|
|
10
|
+
|
|
11
|
+
from typing import TYPE_CHECKING
|
|
12
|
+
|
|
13
|
+
from physicalai_stararm_plugin._urdf import get_urdf_path as get_urdf_path
|
|
14
|
+
|
|
15
|
+
if TYPE_CHECKING:
|
|
16
|
+
from physicalai_stararm_plugin.stararm102fl import StarArm102FLFollower as StarArm102FLFollower
|
|
17
|
+
from physicalai_stararm_plugin.stararm102fl import (
|
|
18
|
+
StarArm102FLFollowerObservation as StarArm102FLFollowerObservation,
|
|
19
|
+
)
|
|
20
|
+
from physicalai_stararm_plugin.stararm102hd import StarArm102HDLeader as StarArm102HDLeader
|
|
21
|
+
from physicalai_stararm_plugin.stararm102hd import (
|
|
22
|
+
StarArm102HDLeaderObservation as StarArm102HDLeaderObservation,
|
|
23
|
+
)
|
|
24
|
+
from physicalai_stararm_plugin.stararm102ld import StarArm102LDLeader as StarArm102LDLeader
|
|
25
|
+
|
|
26
|
+
__all__ = [
|
|
27
|
+
"StarArm102FLFollower",
|
|
28
|
+
"StarArm102FLFollowerObservation",
|
|
29
|
+
"StarArm102HDLeader",
|
|
30
|
+
"StarArm102HDLeaderObservation",
|
|
31
|
+
"StarArm102LDLeader",
|
|
32
|
+
"get_urdf_path",
|
|
33
|
+
]
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
def __getattr__(name: str) -> object:
|
|
37
|
+
if name == "StarArm102HDLeader":
|
|
38
|
+
from physicalai_stararm_plugin.stararm102hd import StarArm102HDLeader
|
|
39
|
+
|
|
40
|
+
return StarArm102HDLeader
|
|
41
|
+
if name == "StarArm102HDLeaderObservation":
|
|
42
|
+
from physicalai_stararm_plugin.stararm102hd import StarArm102HDLeaderObservation
|
|
43
|
+
|
|
44
|
+
return StarArm102HDLeaderObservation
|
|
45
|
+
if name == "StarArm102LDLeader":
|
|
46
|
+
from physicalai_stararm_plugin.stararm102ld import StarArm102LDLeader
|
|
47
|
+
|
|
48
|
+
return StarArm102LDLeader
|
|
49
|
+
if name == "StarArm102FLFollower":
|
|
50
|
+
from physicalai_stararm_plugin.stararm102fl import StarArm102FLFollower
|
|
51
|
+
|
|
52
|
+
return StarArm102FLFollower
|
|
53
|
+
if name == "StarArm102FLFollowerObservation":
|
|
54
|
+
from physicalai_stararm_plugin.stararm102fl import StarArm102FLFollowerObservation
|
|
55
|
+
|
|
56
|
+
return StarArm102FLFollowerObservation
|
|
57
|
+
msg = f"module {__name__!r} has no attribute {name!r}"
|
|
58
|
+
raise AttributeError(msg)
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"""URDF path utility for bundled robot description packages."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
# importlib.resources is safe here because this package requires Python >=3.11.
|
|
6
|
+
import importlib.resources as ir # nosemgrep: python.lang.compatibility.python37.python37-compatibility-importlib2
|
|
7
|
+
from typing import TYPE_CHECKING
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from pathlib import Path
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
def get_urdf_path() -> Path:
|
|
14
|
+
"""Return the path to the bundled URDF directory.
|
|
15
|
+
|
|
16
|
+
The URDF files are installed alongside the Python package. This function
|
|
17
|
+
locates them regardless of whether the package is installed in development
|
|
18
|
+
mode (editable) or from a wheel.
|
|
19
|
+
|
|
20
|
+
Returns:
|
|
21
|
+
Path to the ``urdf/`` directory containing robot description packages.
|
|
22
|
+
|
|
23
|
+
Example:
|
|
24
|
+
>>> from physicalai_stararm_plugin import get_urdf_path
|
|
25
|
+
>>> urdf_dir = get_urdf_path()
|
|
26
|
+
>>> star_urdf = urdf_dir / "stararm102" / "urdf" / "stararm102_description.urdf"
|
|
27
|
+
|
|
28
|
+
"""
|
|
29
|
+
traversal = ir.files("physicalai_stararm_plugin")
|
|
30
|
+
with ir.as_file(traversal) as p:
|
|
31
|
+
return p.parent.parent.joinpath("urdf")
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"""Motor and joint constants for Star Arm 102 variants."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Final
|
|
6
|
+
|
|
7
|
+
STAR_ARM_102_JOINT_ORDER: Final = (
|
|
8
|
+
"shoulder_pan",
|
|
9
|
+
"shoulder_lift",
|
|
10
|
+
"elbow_flex",
|
|
11
|
+
"wrist_flex",
|
|
12
|
+
"wrist_yaw",
|
|
13
|
+
"wrist_roll",
|
|
14
|
+
"gripper",
|
|
15
|
+
)
|
|
16
|
+
|
|
17
|
+
STAR_ARM_102_JOINT_IDS: Final = {
|
|
18
|
+
"shoulder_pan": 0,
|
|
19
|
+
"shoulder_lift": 1,
|
|
20
|
+
"elbow_flex": 2,
|
|
21
|
+
"wrist_flex": 3,
|
|
22
|
+
"wrist_yaw": 4,
|
|
23
|
+
"wrist_roll": 5,
|
|
24
|
+
"gripper": 6,
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
STAR_ARM_102_JOINT_RANGES_DEG: Final = {
|
|
28
|
+
"shoulder_pan": (-150.0, 150.0),
|
|
29
|
+
"shoulder_lift": (-1.0, 170.0),
|
|
30
|
+
"elbow_flex": (-200.0, 1.0),
|
|
31
|
+
"wrist_flex": (-80.0, 90.0),
|
|
32
|
+
"wrist_yaw": (-90.0, 90.0),
|
|
33
|
+
"wrist_roll": (-90.0, 90.0),
|
|
34
|
+
"gripper": (-0.0, 270.0),
|
|
35
|
+
}
|