Skip to content

Commit dfeb6d5

Browse files
authored
feat(public): latest release downloads, vendor-neutral README and verified Win/Linux installation tooling
* feat(distribution): latest release onboarding, Linux AppImage CI, Windows verified installer and WinGet manifest tooling * fix(ci): separate Linux release upload into permissions-scoped gated job * fix(linux): use supported Qt 6.10 linux_gcc_64 kit and matching AppImage icon * ci(winget): dispatchable verified manifest generation and review artifact
1 parent 43b3440 commit dfeb6d5

10 files changed

Lines changed: 535 additions & 38 deletions
Lines changed: 176 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,176 @@
1+
name: ARStack Studio Linux AppImage
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- 'apps/arstack_studio/**'
7+
- '.github/workflows/arstack-studio-linux-appimage.yml'
8+
- 'scripts/install-linux.sh'
9+
workflow_dispatch:
10+
inputs:
11+
release_tag:
12+
description: 'Existing GitHub release tag to build, test and attach Linux AppImage; blank = build artifact only'
13+
required: false
14+
type: string
15+
16+
permissions:
17+
contents: read
18+
19+
jobs:
20+
appimage:
21+
name: Build and test Linux x86_64 package
22+
runs-on: ubuntu-22.04
23+
timeout-minutes: 55
24+
permissions:
25+
contents: read
26+
steps:
27+
- uses: actions/checkout@v4
28+
with:
29+
ref: ${{ github.event_name == 'workflow_dispatch' && inputs.release_tag != '' && inputs.release_tag || github.sha }}
30+
fetch-depth: 0
31+
32+
- name: Confirm release identity before packaging
33+
if: ${{ inputs.release_tag != '' }}
34+
env:
35+
GH_TOKEN: ${{ github.token }}
36+
TAG: ${{ inputs.release_tag }}
37+
run: |
38+
set -euo pipefail
39+
test "$(git rev-parse HEAD)" = "$(git rev-parse "$TAG^{commit}")"
40+
gh release view "$TAG" --json isDraft,isPrerelease -q 'select(.isDraft==false and .isPrerelease==false)' > release-check.json
41+
test -s release-check.json
42+
43+
- name: Install Linux native dependencies
44+
run: |
45+
sudo apt-get update
46+
sudo apt-get install -y --no-install-recommends cmake ninja-build build-essential \
47+
libgl1-mesa-dev libxkbcommon-x11-0 libxcb-cursor0 libxcb-xinerama0 \
48+
libxcb-xkb1 libxcb-randr0 libxcb-image0 libxcb-keysyms1 libxcb-render-util0 \
49+
libfuse2 unzip xvfb libdbus-1-3
50+
51+
- name: Install Qt 6
52+
uses: jurplel/install-qt-action@v4
53+
with:
54+
version: '6.10.3'
55+
arch: linux_gcc_64
56+
modules: 'qtserialport'
57+
cache: true
58+
59+
- name: Compile native Linux Studio and smoke test
60+
run: |
61+
set -euo pipefail
62+
cmake -S apps/arstack_studio -B build-studio-linux -G Ninja \
63+
-DCMAKE_BUILD_TYPE=Release -DARIEC61850_WARNINGS_AS_ERRORS=ON
64+
cmake --build build-studio-linux --target arstack_studio --parallel 2
65+
test -x build-studio-linux/arstack_studio
66+
QT_QPA_PLATFORM=offscreen xvfb-run -a build-studio-linux/arstack_studio --check-reference-template
67+
QT_QPA_PLATFORM=offscreen xvfb-run -a build-studio-linux/arstack_studio --check-p0-policy
68+
69+
- name: Stage Linux app and matched optional release firmware
70+
env:
71+
GH_TOKEN: ${{ github.token }}
72+
TAG: ${{ inputs.release_tag }}
73+
run: |
74+
set -euo pipefail
75+
mkdir -p AppDir/usr/bin AppDir/usr/share/icons/hicolor/512x512/apps
76+
cp build-studio-linux/arstack_studio AppDir/usr/bin/ARStackStudio
77+
cp assets/studio_icon/android-chrome-512x512.png AppDir/usr/share/icons/hicolor/512x512/apps/arstack-studio.png
78+
cat > arstack-studio.desktop <<'DESKTOP'
79+
[Desktop Entry]
80+
Type=Application
81+
Name=ARStack Studio
82+
Exec=ARStackStudio
83+
Icon=arstack-studio
84+
Categories=Education;Science;Electronics;
85+
Terminal=false
86+
DESKTOP
87+
cp LICENSE NOTICE COPYRIGHT.md THIRD_PARTY_NOTICES.md AppDir/usr/bin/
88+
if [ -n "$TAG" ]; then
89+
mkdir -p release-firmware AppDir/usr/bin/firmware AppDir/usr/bin/tools
90+
gh release download "$TAG" --dir release-firmware --pattern 'firmware-manifest.json' --pattern '*.bin'
91+
python3 - <<'PY'
92+
import hashlib,json,pathlib,shutil
93+
root=pathlib.Path('release-firmware')
94+
manifest=json.loads((root/'firmware-manifest.json').read_text())
95+
binfiles=list(root.glob('*.bin'))
96+
assert len(binfiles)==1 and manifest['chip']=='esp32p4', 'Release firmware ambiguity'
97+
src=binfiles[0]
98+
assert hashlib.sha256(src.read_bytes()).hexdigest()==manifest['sha256'], 'Firmware hash mismatch'
99+
output=pathlib.Path('AppDir/usr/bin/firmware')
100+
shutil.copy2(src,output/manifest['image'])
101+
shutil.copy2(root/'firmware-manifest.json',output/'firmware-manifest.json')
102+
(output/'SHA256SUMS.txt').write_text(f"{manifest['sha256']} {manifest['image']}\n")
103+
PY
104+
curl -fLsS https://github.com/esp-rs/espflash/releases/download/v4.5.0/espflash-x86_64-unknown-linux-gnu.zip -o espflash.zip
105+
echo 'dcd7fd822f247df18966935bbb10c7cb4b700c87172349633e9e323ee2542717 espflash.zip' | sha256sum -c -
106+
unzip -j espflash.zip 'espflash' -d AppDir/usr/bin/tools
107+
chmod +x AppDir/usr/bin/tools/espflash
108+
fi
109+
110+
- name: Bundle Qt and create single-file AppImage
111+
uses: miurahr/install-linuxdeploy-action@v1.8.0
112+
id: linuxdeploy
113+
with:
114+
plugins: qt appimage
115+
116+
- name: Generate AppImage and release checksum
117+
env:
118+
QML_SOURCES_PATHS: ${{ github.workspace }}/apps/arstack_studio/qml
119+
VERSION: ${{ inputs.release_tag || 'preview' }}
120+
run: |
121+
set -euo pipefail
122+
export QMAKE="$(command -v qmake6 || command -v qmake)"
123+
${{ steps.linuxdeploy.outputs.linuxdeploy }} \
124+
--appdir AppDir \
125+
--executable AppDir/usr/bin/ARStackStudio \
126+
--desktop-file arstack-studio.desktop \
127+
--icon-file AppDir/usr/share/icons/hicolor/512x512/apps/arstack-studio.png \
128+
--plugin qt --output appimage
129+
shopt -s nullglob
130+
images=( ./*.AppImage )
131+
test "${#images[@]}" -eq 1
132+
mv "${images[0]}" ARStack-Studio-linux-x86_64.AppImage
133+
chmod +x ARStack-Studio-linux-x86_64.AppImage
134+
APPIMAGE_EXTRACT_AND_RUN=1 QT_QPA_PLATFORM=offscreen \
135+
xvfb-run -a ./ARStack-Studio-linux-x86_64.AppImage --check-reference-template
136+
sha256sum ARStack-Studio-linux-x86_64.AppImage > ARStack-Studio-linux-x86_64.sha256
137+
138+
- name: Upload reviewed Linux artifacts
139+
uses: actions/upload-artifact@v4
140+
with:
141+
name: arstack-studio-linux-x86_64
142+
path: |
143+
ARStack-Studio-linux-x86_64.AppImage
144+
ARStack-Studio-linux-x86_64.sha256
145+
if-no-files-found: error
146+
retention-days: 14
147+
148+
attach-verified-release:
149+
name: Attach tested Linux package to exact release tag
150+
needs: appimage
151+
if: ${{ github.event_name == 'workflow_dispatch' && inputs.release_tag != '' }}
152+
runs-on: ubuntu-latest
153+
permissions:
154+
contents: write
155+
steps:
156+
- uses: actions/checkout@v4
157+
with:
158+
ref: ${{ inputs.release_tag }}
159+
fetch-depth: 0
160+
- name: Download Linux build that passed the AppImage checks
161+
uses: actions/download-artifact@v4
162+
with:
163+
name: arstack-studio-linux-x86_64
164+
- name: Verify tag and release before publishing
165+
env:
166+
GH_TOKEN: ${{ github.token }}
167+
TAG: ${{ inputs.release_tag }}
168+
run: |
169+
set -euo pipefail
170+
test "$(git rev-parse HEAD)" = "$(git rev-parse "$TAG^{commit}")"
171+
gh release view "$TAG" --json isDraft,isPrerelease -q 'select(.isDraft==false and .isPrerelease==false)' > release-check.json
172+
test -s release-check.json
173+
sha256sum -c ARStack-Studio-linux-x86_64.sha256
174+
gh release upload "$TAG" \
175+
ARStack-Studio-linux-x86_64.AppImage \
176+
ARStack-Studio-linux-x86_64.sha256
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
name: ARStack Studio WinGet Manifest
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- 'scripts/generate_winget_manifest.py'
7+
- 'docs/INSTALL.md'
8+
- '.github/workflows/arstack-winget-manifest.yml'
9+
workflow_dispatch:
10+
inputs:
11+
package_version:
12+
description: 'Unique WinGet package version, e.g. 0.2.0'
13+
required: true
14+
type: string
15+
release_tag:
16+
description: 'Published and verified GitHub stable release tag'
17+
required: true
18+
type: string
19+
installer_type:
20+
description: 'Match the actual installer technology for that release'
21+
required: true
22+
type: choice
23+
options:
24+
- inno
25+
- nullsoft
26+
27+
permissions:
28+
contents: read
29+
30+
jobs:
31+
validate-generator:
32+
name: Validate WinGet manifest generation tool
33+
runs-on: ubuntu-latest
34+
timeout-minutes: 5
35+
steps:
36+
- uses: actions/checkout@v4
37+
- name: Check Python generator
38+
run: |
39+
python3 -m py_compile scripts/generate_winget_manifest.py
40+
python3 scripts/generate_winget_manifest.py --help
41+
42+
prepare-manifest:
43+
name: Generate exact verified installer manifests
44+
needs: validate-generator
45+
if: ${{ github.event_name == 'workflow_dispatch' }}
46+
runs-on: ubuntu-latest
47+
timeout-minutes: 10
48+
steps:
49+
- uses: actions/checkout@v4
50+
- name: Generate manifest using published installer SHA-256
51+
env:
52+
PACKAGE_VERSION: ${{ inputs.package_version }}
53+
RELEASE_TAG: ${{ inputs.release_tag }}
54+
INSTALLER_TYPE: ${{ inputs.installer_type }}
55+
run: |
56+
set -euo pipefail
57+
python3 scripts/generate_winget_manifest.py \
58+
--version "$PACKAGE_VERSION" \
59+
--tag "$RELEASE_TAG" \
60+
--installer-type "$INSTALLER_TYPE"
61+
grep -R 'InstallerSha256: [0-9A-F]\{64\}' dist/winget
62+
63+
- uses: actions/upload-artifact@v4
64+
with:
65+
name: arstack-studio-winget-manifests
66+
path: dist/winget/
67+
if-no-files-found: error
68+
retention-days: 30

‎README.md‎

Lines changed: 32 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,46 @@
1-
# ARStack61850 — Real-Time IEC 61850 Instrumentation Stack
1+
# ARStack61850 — Open-source IEC 61850 Engineering Lab
22

3-
ARStack61850 is the real-time, hardware-aware evolution of ARIEC61850.
3+
Explore, simulate and test IEC 61850 in your own engineering lab. ARStack61850 combines a portable C++ protocol engine, desktop tools and real-time ESP32-P4 Sampled Values (SV) generation with PTP clock simulation.
44

5-
> **ARIEC61850 understands IEC 61850. ARStack61850 measures and executes IEC 61850 in real time.**
5+
**[Download the latest release](https://github.com/masarray/arstack61850/releases/latest)** · **[Open the product website](https://masarray.github.io/arstack61850/)** · **[Installation guide](docs/INSTALL.md)** · **[Source code](https://github.com/masarray/arstack61850)**
66

7-
The portable C++20 stack remains rooted in the ARIEC61850 behavioral model, but the project north star is now broader: build an open, deterministic IEC 61850 instrumentation platform for hardware-timestamped Sampled Values/GOOSE/PTP injection, analysis, commissioning and real-time closed-loop testing.
7+
### Get started
88

9-
## Public release — Process Bus Simulator M3.H (2026-10-24)
9+
1. Open **Latest release** and download the **Windows Setup** file; the portable package is also available.
10+
2. Install **ARStack Studio** and follow the built-in first-run flow.
11+
3. For real Ethernet SV/PTP experiments, connect a compatible ESP32-P4 Ethernet board and use the **firmware supplied with that same release**. You can explore the desktop interface before connecting hardware.
12+
4. Use a dedicated lab Ethernet connection for SV and PTP experiments.
1013

11-
**Current public laboratory edition: [M3.H Public Stable](https://github.com/masarray/arstack61850/releases/tag/processbus-sim-m3h-20261024).** This is an open-source engineering simulator, **not** a certified merging unit or UTC time reference. No GPS, Omicron, or protection relay is required for an isolated-lab experiment.
14+
**Windows command-line install** (downloads the current stable installer and verifies its SHA-256):
1215

13-
**[Download Setup EXE](https://github.com/masarray/arstack61850/releases/download/processbus-sim-m3h-20261024/ARStack-ProcessBus-M3H-win-x64-setup.exe)** · **[Portable ZIP](https://github.com/masarray/arstack61850/releases/download/processbus-sim-m3h-20261024/ARStack-ProcessBus-M3H-win-x64-portable.zip)** · **[ESP32-P4 firmware](https://github.com/masarray/arstack61850/releases/download/processbus-sim-m3h-20261024/ARStack-ESP32P4-ProcessBus-M3H-firmware.bin)** · [Release notes and engineer quick start](docs/releases/PROCESS_BUS_SIMULATOR_M3H_PUBLIC_20261024.md)
16+
```powershell
17+
$installer = Join-Path $env:TEMP 'arstack-install.ps1'
18+
Invoke-WebRequest 'https://raw.githubusercontent.com/masarray/arstack61850/main/scripts/install-windows.ps1' -OutFile $installer
19+
& $installer
20+
```
21+
22+
**Linux:** An AppImage packaging workflow is available; the [latest release](https://github.com/masarray/arstack61850/releases/latest) lists a Linux download once its build and checks pass. See [Linux install instructions](docs/INSTALL.md). Windows remains the verified desktop installer for the M3.H release.
23+
24+
### What you can explore
25+
26+
- **Sampled Values:** 4 currents + 4 voltages, simulated waveforms and real-time Ethernet output from supported ESP32-P4 hardware.
27+
- **PTP timing:** an internal simulated grandmaster, time-sync controls and on-wire timing evidence.
28+
- **Engineering tools:** SCL, COMTRADE, MMS, GOOSE and other IEC 61850 foundations in the source tree. Features depend on the chosen application and release.
29+
- **Reproducible experimentation:** open-source code, tests, example configurations and release notes.
30+
31+
No external GPS receiver or protection relay is needed to begin exploring the simulator. Network traffic generation is intended for a separate test bench, not an energized operational substation network.
32+
33+
### Verified M3.H milestone
1434

15-
* **ESP32-P4 Ethernet:** 4I+4V IEC 61850 SV publisher, one ASDU, 64-byte samples, 4,000 frames/s, continuous `smpCnt 0–3999` with explicit START/STOP.
16-
* **IEEE 1588 / IEC/IEEE 61850-9-3-style PTP emulation:** isolated-bench **internal simulated Global GM**, Layer-2 Announce/Sync/Follow_Up at approximately 1 Hz, ESP32-P4 EMAC hardware transmit timestamp, phase servo and MAC egress evidence. `smpSynch AUTO` supports `smpSynch=2` after local measured evidence; not an assertion of GPS/UTC traceability.
17-
* **ARStack Studio on Windows:** 4I+4V waveform/phasor controls, capture/reporting, SCL input within supported profile, supervised firmware flashing, verified COM identity and USB hotplug recovery.
18-
* **Actual independent M3.H capture:** **163,048 SV in 40.763 seconds**, 100% `smpSynch=2`, **zero missing, duplicate, counter-reset or malformed SV**, measured **3999.884 fps**, plus 44 PTP Announce and 43 each Sync/Follow_Up. A STOP truncated the requested 120-second capture; 120-second endurance and physical relay locking were **not** tested.
19-
* **Source pinned:** `a922e9bdba4e57a4e88406eb83344455dd8ff142`; **10/10 CI workflows PASS** for the shipped Studio/firmware pairing. The public tag includes only documentation/packaging deltas from that tested build.
20-
* **Release = main:** [PR #299](https://github.com/masarray/arstack61850/pull/299) merged the exact tested source and the public release-tag ancestry into `main` with **14/14 integration CI PASS**; no SV/PTP source drift, no binary re-upload, no loss of newer main docs. Original source Build ID remains `a922e9bdba4e57a4`. See [source-in-main audit](docs/integration/M3H_SOURCE_STACK_AUDIT_2026-10-24.md).
35+
The [24 October 2026 M3.H release](https://github.com/masarray/arstack61850/releases/tag/processbus-sim-m3h-20261024) recorded 163,048 consecutive SV packets over 40.76 seconds, at 3,999.884 frames/s, with `smpSynch=2` across the captured interval and no missing or malformed SV frames. That result is a measured laboratory milestone, not a claim about later builds or external device acceptance. See the [test record](docs/releases/PROCESS_BUS_SIMULATOR_M3H_PUBLIC_20261024.md).
2136

37+
**Release downloads always resolve through [GitHub's latest stable release](https://github.com/masarray/arstack61850/releases/latest)** rather than a hard-coded version. Release notes identify the firmware/software pairing and validated features for each build.
2238

23-
For electrical safety, transmit PTP and SV only on an isolated lab switch/VLAN: never introduce an unsolicited PTP grandmaster or SV publisher onto an operating substation LAN.
39+
---
2440

25-
### Earlier general-purpose Studio releases
41+
## Developer and technical documentation
2642

27-
[v0.1.1](https://github.com/masarray/arstack61850/releases/tag/v0.1.1) remains an earlier Studio release; [v0.1.0](https://github.com/masarray/arstack61850/releases/tag/v0.1.0) retains historical 4I+4V / 4000 fps **`smpSynch=0`** evidence, 10/10 START/STOP and a 3600-second retained run. These older results are not the M3.H measured PTP/SV evidence.
43+
The portable C++20 stack originated from the ARIEC61850 behavioral model. The engineering north star is deterministic IEC 61850 process-bus instrumentation with bounded runtime behavior, protocol evidence and platform-specific hardware timing.
2844

2945
## Start here
3046

‎apps/arstack_studio/README.md‎

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
# ARStack Studio — 4I + 4V SMV Injector / Generator
1+
# ARStack Studio — Desktop IEC 61850 Lab Tool
22

3-
ARStack Studio is the **canonical native desktop operator surface** for the first ARStack61850 public Sampled Values release. It is a Qt 6 / C++ / QML application; the ESP32-P4 remains the deterministic real-time publisher.
3+
ARStack Studio is the native desktop interface for IEC 61850 Sampled Values experiments and ESP32-P4 process-bus simulation.
44

5-
> **Newest public process-bus simulator:** [M3.H Lab Edition · 2026-10-24](https://github.com/masarray/arstack61850/releases/tag/processbus-sim-m3h-20261024) (Public Stable · engineering lab simulator). Earlier standalone Studio release: [v0.1.1](https://github.com/masarray/arstack61850/releases/tag/v0.1.1); historical P0 v0.1.0 is unchanged.
6-
>
7-
> **Source mainline:** Released M3.H firmware/Studio source and GitHub Release tag are both ancestors of `main` through [merged PR #299](https://github.com/masarray/arstack61850/pull/299), with 14/14 candidate CI SUCCESS and original `a922e9bdba4e57a4` hardware Build ID preserved in the published firmware.
8-
>
9-
> Install M3.H Setup **and flash its matched ESP32-P4 firmware** (build `a922e9bdba4e57a4`) to use the new PTP SOURCE continuity and simulated Global GM. The older firmware does not gain those features by updating Windows Studio alone.
10-
>
11-
> [Windows Setup EXE](https://github.com/masarray/arstack61850/releases/download/processbus-sim-m3h-20261024/ARStack-ProcessBus-M3H-win-x64-setup.exe) · [Portable](https://github.com/masarray/arstack61850/releases/download/processbus-sim-m3h-20261024/ARStack-ProcessBus-M3H-win-x64-portable.zip) · [firmware BIN](https://github.com/masarray/arstack61850/releases/download/processbus-sim-m3h-20261024/ARStack-ESP32P4-ProcessBus-M3H-firmware.bin)
5+
**[Get the latest release](https://github.com/masarray/arstack61850/releases/latest)** · **[How to install](../../docs/INSTALL.md)** · **[Product website](https://masarray.github.io/arstack61850/)**
6+
7+
On Windows, choose **Setup EXE** or **Portable ZIP** from the release page. For Linux, use an **AppImage** when it appears among the verified assets. For Ethernet output, connect the ESP32-P4 board and load its firmware from the **same release**.
8+
9+
Start with a 4I+4V example, choose the timing mode, adjust voltage/current signals, and press **Start**. This software is made for engineers, students and lab experimenters; a GPS reference or protection relay is not needed just to try it.
10+
11+
The M3.H release recorded verified 4 kHz SV and local simulated PTP traffic. These measurements belong to that specific release; newer builds have their own release notes and evidence.
1212

1313
## M3.H laboratory SV + PTP mode
1414

0 commit comments

Comments
 (0)