Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
db42177
Add full sensor pipeline including DB tables, SensorClient interface,…
CarlosVasquez04 Dec 2, 2025
4708e03
Added pyserial to dependencies
CarlosVasquez04 Dec 2, 2025
e8fbca1
Spectraval Sim implementation, writes to a mock .cap file and yields …
tylerlv3 Jan 27, 2026
849d007
Backend:
tylerlv3 Feb 1, 2026
9179ca4
Merge remote-tracking branch 'origin/main' into feat/sensor-integration
tylerlv3 Feb 1, 2026
6e3e0c8
Initial implementation of code routine builder. Went with JS instead …
tylerlv3 Feb 12, 2026
f6bd8a2
feat/fix: Migrate routine builder to backend, add documentation, and …
tylerlv3 Feb 22, 2026
04b8227
very small syntax tweak
tylerlv3 Feb 23, 2026
8ed97b7
seperate groups and routines into seperate buttons rather than manage…
tylerlv3 Mar 2, 2026
1d0941a
Update .gitignore
CarlosVasquez04 Mar 3, 2026
968b888
Merge branch 'main' into feat/sensor-integration
CarlosVasquez04 Mar 3, 2026
f511c55
Add sensor logs API and real-sensor support
CarlosVasquez04 Mar 4, 2026
8393670
feat: improve routine editor, audit logs, and HMI consistency
tylerlv3 Mar 5, 2026
7c4e0d4
fix: resolve room grid compact vertical overflow while maintaining 3 …
tylerlv3 Mar 5, 2026
18ad9e6
Grid rezising to fit when side panel is open. Rename app to remove pr…
tylerlv3 Mar 5, 2026
9a64eb9
docs: add detailed sensor API metrics to Routine Builder documentation
tylerlv3 Mar 5, 2026
548b708
feat: Add docker configuration
tylerlv3 Mar 9, 2026
691d43d
Merge branch 'main' into feat/sensor-integration-2
tylerlv3 Mar 31, 2026
48ef398
Fix real sensor integration and update on-site setup docs
CarlosVasquez04 Apr 13, 2026
57d9dfe
Update sensor docs
CarlosVasquez04 Apr 14, 2026
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
20 changes: 15 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -224,13 +224,23 @@ docs/TintSpecificAPIPages.pdf
web/node_modules/
web/dist/

# Service runtime/state data
svc/data/audit.json
svc/data/audit.db
svc/data/*.db-journal
svc/data/*.db-wal
svc/data/*.db-shm
svc/data/panels.json
svc/data/panels_state.json
svc/data/panels_config.json
#svc/svc/data/window_mapping.json
# Note: panels_config.json is tracked (structural data)
# panels_state.json is ignored (runtime state)
svc/data/routines/

svc/data/audit.db
# audit.db is a SQLite database for the audit log, changes on run time, so ignore it for now
# JETI simulator output (configured as either file or directory)
svc/data/jeti_sim_output
svc/data/jeti_sim_output/

# Vendor manuals, extracted text, and ad hoc sensor docs used for local AI context
/docs/SensorDocs/

# Local temporary research repo / scratch workspace
/.tmp_luox/
2 changes: 1 addition & 1 deletion DEV-SETUP.md
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ You should see the control interface
# Use the app

1. The header shows service status
2. Pick a group set a level press `Set group`
2. Pick a group set a level press `Tint Group`
3. Move a slider on any panel and press `Apply`
4. Press `Refresh` in the header to reload state

Expand Down
2 changes: 1 addition & 1 deletion OVERVIEW.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ React + Vite front-end with an HMI-style control screen.
- Stays a fixed max size in the middle of the screen
- Tabs styled to match the Manage side panel tabs:
- **Audit log** – table of command history
- **Sensor log** – placeholder for future sensor telemetry
- **Sensor log** – live sensor telemetry with filtering and CSV export
- Props:
- `isOpen` / `onClose`
- `auditLogs`, `loading`, `error`
Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ Secondary: email to partner or instructor
## Getting Started
An overview of the file structure:
- `docs/` for design notes and meeting minutes
- `sim/` for an API simulator used off site
- `docs/real_sensor_setup.md` and `docs/on_site_sensor_checklist.md` for real sensor deployment
- `facilities/` for site-specific facility notes
- `web/` for the researcher UI (Contains a README specific to the web interface)
- `svc/` for the control service and queue (Contains a README specific to the backend service)

Expand Down
33 changes: 33 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
version: '3.8'

services:
svc:
build:
context: ./svc
dockerfile: Dockerfile
container_name: glazing-svc
ports:
- "8000:8000"
volumes:
- ./svc/data:/app/data
environment:
- SVC_HOST=0.0.0.0
- SVC_PORT=8000
- UVICORN_RELOAD=false
restart: unless-stopped

web:
build:
context: ./web
dockerfile: Dockerfile
args:
# Ok since we are only running locally, we can just use localhost
- VITE_API_BASE=http://localhost:8000
container_name: glazing-web
ports:
- "80:80"
depends_on:
- svc
restart: unless-stopped


83 changes: 83 additions & 0 deletions docs/on_site_sensor_checklist.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# On-Site Sensor Checklist

Use this at the trailer/lab PC after the hardware is physically installed.

## Connection Order

1. Connect each `T-10A` head chain to its T-10A body.
2. If a T-10A body has multiple heads, connect external power to that setup.
3. Connect each `T-10A` body to the PC by USB.
4. Connect each JETI device to the PC by USB.
5. If the JETI path will use file mode, confirm the PC software is configured to write a live `.cap` file or folder.
6. If the JETI path will use direct serial mode, confirm the JETI USB driver is installed and a COM port appears in Windows.
7. Connect the EKO `MS-90` and optional `MS-80S` to the `C-BOX`.
8. Connect `C-BOX` output power and RS-485 wiring.
9. Connect the USB-to-RS485 adapter from the `C-BOX` output side to the PC.

## Windows Checks

1. Open Device Manager.
2. Record the COM port for each `T-10A` body.
3. Record the COM port for each JETI device that will use direct serial mode.
4. Record the COM port for the USB-RS485 adapter used by the `C-BOX`.
5. If a JETI device is missing, install the JETI USB driver and reconnect it.

## Update `svc/data/sensors_config.json`

1. Set `t10a[].port` to the actual T-10A COM port.
2. Set `t10a[].heads[].head_no` to the actual physical T-10A adaptor/head ID.
3. Set `jeti_spectraval[].transport` to either `file` or `serial_scpi`.
4. If JETI uses file mode, set `jeti_spectraval[].output_path` to the actual live `.cap` file or folder.
5. If JETI uses serial mode, set `jeti_spectraval[].port` to the JETI COM port.
6. If JETI uses serial mode, set `jeti_spectraval[].baudrate`:
- `921600` for `spectraval 1511`
- `115200` for `specbos 1211-2`
7. Set `eko_ms90_plus[].port` to the COM port of the USB-RS485 adapter.

## Start The Backend

```powershell
cd svc
$env:SVC_MODE = "real"
uv run python main.py
```

Use `SENSORS_CONFIG_FILE` only if you are not using the default `svc/data/sensors_config.json`.

## Acceptance Checks

```powershell
Invoke-RestMethod http://127.0.0.1:8000/sensors
Invoke-RestMethod http://127.0.0.1:8000/metrics/latest
```

Verify:

- T-10A sensors report `lux`
- JETI sensors report `lux` plus color/spectral metrics
- EKO reports `ghi_w_m2`, `dni_w_m2`, `dhi_w_m2`, and sun position data

Then open the HMI and confirm:

- live sensor cards are populated
- live graphs update
- `Logs -> Sensor log` is filling with new rows
- sensor CSV export works

For the full step-by-step connection instructions for each sensor and each supported method, use [`docs/real_sensor_setup.md`](./real_sensor_setup.md).

## If Something Fails

- No T-10A data:
- re-check USB COM port
- verify head IDs
- verify straight CAT5 and external power for multi-point mode
- No JETI data:
- re-check driver install
- confirm the PC measurement software is writing to the configured `output_path`, or
- confirm COM port and baudrate for serial mode
- No EKO data:
- swap RS-485 `A/B`
- verify `12 VDC` power and fuse
- verify `slave_address`
- try a different `float_byte_order` if values are present but incorrect
Loading
Loading