forgectrl: promote to its own repo, recipe fetches the pinned git source

Sources live at github.com/ScottW514/forgectrl (history extracted, layout src/ + init/); the recipe pins SRCREV and installs the init script from the repo. Adds the build-forgectrl.sh bench cross-compile script.
This commit is contained in:
ScottW514
2026-08-03 14:06:25 -04:00
parent 421909a6a8
commit 8d798fa4b9
15 changed files with 48 additions and 2105 deletions
+1
View File
@@ -19,6 +19,7 @@ target board (dev image, python3 present) unless noted.
| `flow_recheck_char.py` | Characterizes short in-run re-checks and the differential metric; shows why over-temp cannot see a stopped pump and why passive warming trends are ambiguous. |
| `temp_calibrate.py` | Coolant temperature spot-check helper (`watch` / `point <measured_C>` / `fit`) — pairs a measured temperature with averaged raw ADC readings and fits a per-machine line to sanity-check the factory curve against a thermometer. |
| `build-glowforge.sh` | Cross-compiles **grblHAL-glowforge** (the canonical driver repo, `../../../grblHAL-glowforge`) in the forge-yocto WSL distro. Run: `wsl -d forge-yocto -- bash <path>/build-glowforge.sh` (from PowerShell; Git Bash mangles /mnt/c paths). This is the production controller build. |
| `build-forgectrl.sh` | Cross-compiles **forgectrl** (the canonical control-daemon repo, `../../../forgectrl`) the same way, borrowing the toolchain from the forgectrl recipe workdir (regenerate with `bitbake forgectrl` after a clean). |
| `build-feeder.sh` | Cross-compiles `feeder.c` the same way. |
| `puls_profile.py` | Decodes factory `.puls` streams (raw or GF1-headered) into velocity/accel profiles: peak speeds, ramp-slope fits, per-move segments, Z cadence. Runs anywhere (stdlib only). Source of the factory-true grblHAL defaults: 700/590 mm/s² accel, 200 mm/s max rate, 28160 Hz travel tick. |
| `bench_m2.py` | Motion-quality bench, runs against the board over TCP:23: bounded round-trip jogs (sanity, max-rate, diagonal) + feed-hold/resume mid-move, reporting peak feed, state transitions, and position drift. |
+22
View File
@@ -0,0 +1,22 @@
#!/bin/bash
# Cross-compiles forgectrl (the canonical repo, ../../../forgectrl -> synced
# to ~/dev/openglow-forgefirm/forgectrl) for the factory board, borrowing the
# Yocto cross toolchain + sysroot from the forgectrl recipe work directory
# (which carries ulfius and libjpeg). If that path ages out after a clean,
# regenerate it with: bitbake forgectrl. Run from PowerShell:
# wsl -d forge-yocto -- bash <path>/build-forgectrl.sh
set -e
TC=/home/builder/dev/openglow-forgefirm/forgefirm/build/tmp/work/cortexa9t2hf-neon-fslc-linux-gnueabi/forgectrl/0.1.0
export PATH="$TC/recipe-sysroot-native/usr/bin:$TC/recipe-sysroot-native/usr/bin/arm-fslc-linux-gnueabi:$PATH"
cd /home/builder/dev/openglow-forgefirm/forgectrl
rm -rf build-arm
cmake -B build-arm \
-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_SYSTEM_PROCESSOR=arm \
-DCMAKE_C_COMPILER=arm-fslc-linux-gnueabi-gcc \
-DCMAKE_BUILD_TYPE=None \
"-DCMAKE_C_FLAGS=--sysroot=$TC/recipe-sysroot -mthumb -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 -O2 -g" \
"-DCMAKE_EXE_LINKER_FLAGS=--sysroot=$TC/recipe-sysroot" \
> /tmp/cmake-fc.log 2>&1
cmake --build build-arm -j8 > /tmp/fcbuild.log 2>&1 || { tail -30 /tmp/fcbuild.log; exit 1; }
echo BUILD-OK
file build-arm/forgectrl 2>/dev/null || ls build-arm/