Skip to content

Add Renesas RZ/G3E EVK robotic-arm demo - #56

Open
mlamp99 wants to merge 1 commit into
mainfrom
rz3ge
Open

mlamp99 wants to merge 1 commit into
mainfrom
rz3ge

Conversation

@mlamp99

@mlamp99 mlamp99 commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Renesas RZ/G3E EVK robotic-arm demo (xArm control, teach/scan positions, web view, device template and install scripts).

Continues #17 — that PR was closed automatically when its branch was renamed add-rzg3e-robotic-arm-demorz3ge during branch cleanup; the commit is unchanged.

Port of the TRIA Vision AI Kit 6490 robotic-arm demo to the Renesas
RZ/G3E EVK. Controls a Hiwonder XArm 1S over USB and streams telemetry
to /IOTCONNECT.

Adapted to RZ/G3E constraints:
- Browser-based MJPEG calibration + live demo view (the board has no
  display server and we install opencv-python-headless).
- Stdlib-only systemdata.py — the Yocto Python image strips `resource`,
  `multiprocessing`, and `statistics`, so psutil and py-cpuinfo are
  unusable. Reads /proc and /sys directly while keeping the same
  dataclass shape so main.py is unchanged.
- deps-download.sh / deps-install.sh follow the base RZ/G3E SDK install
  pattern (host-side wheel fetch → scp → on-board offline unzip into
  site-packages). Defaults to cp312 wheels (matches the shipped image's
  Python 3.12.9). torch/torchvision/mediapipe stay best-effort, so the
  asl mode is documented as best-effort accordingly.
- Defaults: --mode ball, --camera 0, start.sh drops stdbuf (busybox
  doesn't ship it).
try:
from point_net import PointNet
except ImportError:
print("Warning: point_net module not found. Please ensure model/point_net.py exists and that the project root is on PYTHONPATH.")
"""

import argparse
import io
import threading
import time
from http.server import BaseHTTPRequestHandler, ThreadingHTTPServer
from urllib.parse import urlparse, parse_qs
import time
from collections import deque
from dataclasses import asdict
from datetime import datetime
from modes import make_mode

try:
from avnet.iotconnect.sdk.lite import Client, DeviceConfig, Callbacks, DeviceConfigError

try:
from avnet.iotconnect.sdk.lite import Client, DeviceConfig, Callbacks, DeviceConfigError
from avnet.iotconnect.sdk.sdklib.mqtt import C2dCommand, C2dAck
print(f" Product: {usb.util.get_string(device, device.iProduct)}")
print(f" Serial: {usb.util.get_string(device, device.iSerialNumber)}")
print()
except:
except Exception as e:
print('getBattery error', e)
traceback.print_exc()
except BaseException as e:
try:
arm.servoOff()
print('servos off')
except:
self.wfile.write(b"\r\n")
last = buf
time.sleep(0.05)
except (BrokenPipeError, ConnectionResetError):
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant