How bbright99/hdl-studio-2 works
OMRANI HDL Studio is a browser-based HDL editing and digital-circuit simulation environment, with an Electron desktop shell offering native file access and external simulator support. The main workflow is to create or load a project, edit HDL, build it into diagnostics and modules, simulate it, then inspect the resulting waveform and console output. The excerpts establish several UI-to-library relationships, but omit parts of the main route and desktop bridge; uncertain links are left out or marked unverified.
Main entry points: index.tsx Studio workflow · project.ts Project and build · parser.ts Verilog parser · CodeEditor.tsx HDL editor
Components 22
Studio UI
- App shell
src/routes/__root.tsx - Studio workflow
src/routes/index.tsx - HDL editor
src/components/studio/CodeEditor.tsx - Project explorer
src/components/studio/ProjectExplorer.tsx - Diagnostics panel
src/components/studio/ProblemsPanel.tsx - Build console
src/components/studio/ConsolePanel.tsx - Waveform viewer
src/components/studio/WaveformViewer.tsx
Project and Build
- Project and build
src/lib/hdl/project.ts - Project templates
src/lib/hdl/templates.ts
HDL Runtime
- Verilog parser
src/lib/hdl/parser.ts - HDL lexer
src/lib/hdl/lexer.ts - HDL syntax model
src/lib/hdl/ast.ts - Built-in simulator
src/lib/hdl/sim.ts - External simulation
src/lib/hdl/icarus.ts - Waveform formatting
src/lib/hdl/format.ts - Syntax highlighting
src/lib/hdl/highlight.ts
Desktop Integration
- Electron shell
desktop/main.cjs - Desktop bridge
desktop/preload.cjs
Other components
- Engineer
- Browser storage
- Native file system
- Installed simulators
Connections 23
- Engineer → Studio workflow: uses
src/routes/index.tsx - App shell → Studio workflow: renders
- Studio workflow → HDL editor: renders
src/routes/index.tsx - Studio workflow → Project explorer: renders
src/routes/index.tsx - Studio workflow → Diagnostics panel: renders
src/routes/index.tsx - Studio workflow → Build console: renders
src/routes/index.tsx - Studio workflow → Waveform viewer: renders
src/routes/index.tsx - Studio workflow → Project and build: loads and saves
src/routes/index.tsx - Project and build → Browser storage: reads and writes
src/lib/hdl/project.ts - Project and build → Project templates: creates from
src/lib/hdl/project.ts - Project explorer → Project and build: uses project helpers
src/components/studio/ProjectExplorer.tsx - HDL editor → Syntax highlighting: uses
src/components/studio/CodeEditor.tsx - HDL editor → Verilog parser: uses
src/components/studio/CodeEditor.tsx - Project and build → Verilog parser: parses project files
src/lib/hdl/project.ts - Verilog parser → HDL lexer: tokenizes with
src/lib/hdl/parser.ts - Verilog parser → HDL syntax model: produces syntax model
src/lib/hdl/parser.ts - Studio workflow → Built-in simulator: simulates project
src/routes/index.tsx - Studio workflow → External simulation: runs selected simulator
src/routes/index.tsx - External simulation → Installed simulators: invokes installed tools
README.md - Waveform viewer → Waveform formatting: formats values
src/components/studio/WaveformViewer.tsx - Studio workflow → Electron shell: uses desktop bridge
README.md - Electron shell → Desktop bridge: exposes native features
README.md - Desktop bridge → Native file system: accesses files
README.md