Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
indent_style = space
indent_size = 2
trim_trailing_whitespace = true

[*.py]
indent_size = 4

[Makefile]
indent_style = tab
10 changes: 10 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
* text=auto eol=lf
*.png binary
*.jpg binary
*.jpeg binary
*.gif binary
*.pdf binary
*.stl binary
*.step binary
*.stp binary
*.FCStd binary
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @bostromdev
3 changes: 3 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Contributing

The canonical contribution guide is [CONTRIBUTING.md](../CONTRIBUTING.md).
42 changes: 42 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Software bug
description: Report reproducible unexpected software behavior.
title: "[Bug]: "
labels: ["bug", "needs-triage"]
body:
- type: markdown
attributes:
value: "Do not include secrets or sensitive RF information."
- type: input
id: revision
attributes:
label: Version or commit
placeholder: "Commit SHA, tag, or branch"
validations:
required: true
- type: textarea
id: environment
attributes:
label: Environment
description: OS, Python version, installation method, and relevant devices.
validations:
required: true
- type: textarea
id: steps
attributes:
label: Reproduction steps
placeholder: "1. …"
validations:
required: true
- type: textarea
id: expected
attributes:
label: Expected behavior
validations:
required: true
- type: textarea
id: actual
attributes:
label: Actual behavior and logs
render: shell
validations:
required: true
5 changes: 5 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
blank_issues_enabled: false
contact_links:
- name: Security and safety-sensitive reports
url: https://github.com/bostromdev/Radiance3D/security
about: Report vulnerabilities privately; do not publish hazardous details.
36 changes: 36 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Feature proposal
description: Propose a scoped capability or design change.
title: "[Proposal]: "
labels: ["enhancement", "needs-design"]
body:
- type: textarea
id: problem
attributes:
label: Problem
description: What engineering or user need is not met?
validations:
required: true
- type: textarea
id: proposal
attributes:
label: Proposed approach
description: Include interfaces, units, and expected limitations.
validations:
required: true
- type: textarea
id: alternatives
attributes:
label: Alternatives considered
- type: dropdown
id: area
attributes:
label: Area
options:
- Architecture
- Firmware
- Software
- Hardware
- Data format
- Documentation
validations:
required: true
46 changes: 46 additions & 0 deletions .github/ISSUE_TEMPLATE/hardware_issue.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Hardware issue
description: Report a reproducible motion, electronics, power, or RF integration issue.
title: "[Hardware]: "
labels: ["hardware", "needs-triage"]
body:
- type: textarea
id: configuration
attributes:
label: Hardware configuration
description: Controller board, firmware version, driver, motors, and power supply.
validations:
required: true
- type: textarea
id: wiring
attributes:
label: Wiring description
description: Connections, cable lengths, grounding, and relevant photos or diagrams.
validations:
required: true
- type: textarea
id: steps
attributes:
label: Reproduction steps
placeholder: "1. Begin with power disconnected…"
validations:
required: true
- type: textarea
id: behavior
attributes:
label: Expected and actual behavior
validations:
required: true
- type: textarea
id: logs
attributes:
label: Logs and measurements
render: shell
- type: checkboxes
id: safety
attributes:
label: Safety confirmation
options:
- label: Power was disconnected before wiring changes.
required: true
- label: The report contains no unverified accuracy claim.
required: true
3 changes: 3 additions & 0 deletions .github/SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Security

The canonical security policy is [SECURITY.md](../SECURITY.md).
23 changes: 23 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
## Summary

<!-- What changed and why? -->

## Project status

- [ ] Implemented behavior is separated from planned or experimental work.
- [ ] Measured, simulated, imported, and processed data are labeled correctly.
- [ ] No unvalidated accuracy or compatibility claim is introduced.

## Validation

<!-- List commands and results. Explain anything not run. -->

## Hardware and safety impact

<!-- Note motion, power, RF, mechanical, or "None". -->

## Checklist

- [ ] The change is focused and documented.
- [ ] Tests or a clear validation method are included.
- [ ] Relevant architecture, protocol, schema, or changelog text is updated.
26 changes: 26 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Documentation

on:
pull_request:
paths:
- "**/*.md"
- ".github/workflows/docs.yml"
push:
branches: [main]
paths:
- "**/*.md"
- ".github/workflows/docs.yml"

permissions:
contents: read

jobs:
links:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check Markdown links
uses: lycheeverse/lychee-action@v2
with:
args: --no-progress --exclude-path CHANGELOG.md "./**/*.md"
fail: true
61 changes: 61 additions & 0 deletions .github/workflows/firmware.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Firmware

on:
pull_request:
paths:
- "firmware/**"
- "software/src/radiance3d/transport.py"
- "software/src/radiance3d/motion_client.py"
- "software/tests/test_firmware_simulator_protocol.py"
- "scripts/generate_hardware_profile_header.py"
- ".github/workflows/firmware.yml"
push:
branches: [main]
paths:
- "firmware/**"
- "software/src/radiance3d/transport.py"
- "software/src/radiance3d/motion_client.py"
- "software/tests/test_firmware_simulator_protocol.py"
- "scripts/generate_hardware_profile_header.py"
- ".github/workflows/firmware.yml"

permissions:
contents: read

jobs:
host-firmware:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Configure portable firmware build
working-directory: firmware/controller
run: cmake -S host -B build-host -DCMAKE_BUILD_TYPE=Release
- name: Build portable simulator and tests
working-directory: firmware/controller
run: cmake --build build-host --parallel 2
- name: Test portable motion and protocol behavior
working-directory: firmware/controller
run: ctest --test-dir build-host --output-on-failure
- name: Test Python host compatibility against the native simulator
working-directory: software
run: |
python -m pip install -e ".[dev]"
RADIANCE3D_SIMULATOR="$GITHUB_WORKSPACE/firmware/controller/build-host/radiance3d-simulator" pytest -q tests/test_firmware_simulator_protocol.py

esp-idf:
runs-on: ubuntu-latest
container: espressif/idf:v5.5.4
steps:
- uses: actions/checkout@v4
- name: Configure ESP32 target
working-directory: firmware/controller
run: idf.py set-target esp32
- name: Build native ESP-IDF firmware
working-directory: firmware/controller
run: idf.py build
- name: Report native firmware size
working-directory: firmware/controller
run: idf.py size
27 changes: 27 additions & 0 deletions .github/workflows/repository-checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Repository checks

on:
pull_request:
push:
branches: [main]

permissions:
contents: read

jobs:
structure-and-schema:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Check repository structure and internal links
run: python scripts/check_repository.py
- name: Install JSON Schema validator
run: python -m pip install "check-jsonschema>=0.31,<1"
- name: Validate scan example against schema
run: >-
check-jsonschema
--schemafile data/schemas/scan-v1.schema.json
data/examples/simulated/dipole-like-scan.json
39 changes: 39 additions & 0 deletions .github/workflows/software.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Software

on:
pull_request:
paths:
- "software/**"
- "data/**"
- ".github/workflows/software.yml"
push:
branches: [main]
paths:
- "software/**"
- "data/**"
- ".github/workflows/software.yml"

permissions:
contents: read

jobs:
quality:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
cache: pip
cache-dependency-path: software/pyproject.toml
- name: Install package and development tools
run: python -m pip install -e "./software[dev]"
- name: Lint
working-directory: software
run: ruff check .
- name: Type check
working-directory: software
run: mypy
- name: Test
working-directory: software
run: pytest
44 changes: 44 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Operating systems and editors
.DS_Store
Thumbs.db
.idea/
.vscode/
*.swp
*.swo

# Python
__pycache__/
*.py[cod]
*.egg-info/
.pytest_cache/
.ruff_cache/
.mypy_cache/
.coverage
htmlcov/
.venv/
venv/
dist/
build/

# Native ESP-IDF and host CMake build artifacts
.pio/
firmware/controller/build/
firmware/controller/build-host/
firmware/controller/sdkconfig
firmware/controller/sdkconfig.old
CMakeFiles/
CMakeCache.txt
Testing/

# Temporary and generated data
data/raw/
data/tmp/
*.tmp
*.log

# Mechanical CAD temporary and generated exports
*.autosave
*.bak
*.FCStd1
hardware/mechanical/exports/*
!hardware/mechanical/exports/README.md
Loading
Loading