# ac6embedded/vscode-zephyr-workbench architecture

> Architecture diagram of the GitHub repository ac6embedded/vscode-zephyr-workbench, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-18). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ac6embedded/vscode-zephyr-workbench
- Repository: https://github.com/ac6embedded/vscode-zephyr-workbench

## Overview

Workbench for Zephyr is a VS Code extension for managing Zephyr development. The main workflow starts with host tools and toolchain setup, then workspace and application creation, build configuration and build/flash, followed by debugging. The graph also preserves the documented Kconfig, devicetree, memory-analysis, static-analysis, SBOM and dashboard capabilities. Some subsystem paths are directories because their implementation spans several files; README-documented links are cited there, while source-based links are limited to relationships visible in the supplied excerpts or index.

Main entry points: [`src/models/ZephyrApplication.ts`](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/ZephyrApplication.ts) (Zephyr Application), [`src/panels/DebugManagerPanel.ts`](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/DebugManagerPanel.ts) (Debug Manager), [`src/models/ToolchainInstallations.ts`](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/ToolchainInstallations.ts) (Toolchain Registry), [`src/models/WestWorkspace.ts`](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/WestWorkspace.ts) (West Workspace)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_setup["Setup and Workspaces"]
  node_host_tools["Host Tools<br/>[HostToolsPanel.ts]"]
  node_toolchains["Toolchain Registry"]
  node_global_sdk["Global SDK Discovery"]
  node_west_workspace["West Workspace<br/>[WestWorkspace.ts]"]
  node_west_commands["West Management<br/>[WestCommands.ts]"]
end

subgraph group_build["Applications and Build"]
  node_application["Zephyr Application"]
  node_build_config["Build Configuration"]
  node_tasks["Build and Flash Tasks"]
end

subgraph group_debug["Debug and Flash"]
  node_debug_manager["Debug Manager"]
  node_debug_config["Debug Configuration<br/>[debugUtils.ts]"]
  node_debug_backends["Debug Backends"]
  node_debug_runners["Debug Runners"]
end

subgraph group_analysis["Configuration and Analysis"]
  node_kconfig["Kconfig Manager"]
  node_devicetree["Devicetree Editing"]
  node_memory_reports["Memory Analysis"]
  node_dashboard["Build Dashboard"]
  node_eclair["ECLAIR Analysis"]
  node_sbom["SBOM Services"]
  node_sbom_client["SBOM Total Client<br/>[sbomTotalClient.ts]"]
end

subgraph group_runtime["Extension Runtime"]
  node_extension["Workbench Extension<br/>[extension.ts]"]
  node_execution["Command Execution<br/>[execUtils.ts]"]
  node_env["Build Environment<br/>[zephyrEnvUtils.ts]"]
end

node_developer(("Developer"))

node_developer -->|"uses"| node_extension
node_extension -->|"registers commands"| node_west_commands
node_developer -->|"installs tools"| node_host_tools
node_developer -->|"adds toolchain"| node_toolchains
node_toolchains -->|"discovers SDKs"| node_global_sdk
node_developer -->|"creates workspace"| node_west_workspace
node_west_commands -->|"manages"| node_west_workspace
node_developer -->|"creates application"| node_application
node_application -->|"resolves workspace"| node_west_workspace
node_application -->|"selects toolchain"| node_toolchains
node_application -->|"resolves SDK"| node_global_sdk
node_application -->|"defines configurations"| node_build_config
node_developer -->|"builds and flashes"| node_tasks
node_tasks -->|"runs commands"| node_execution
node_build_config -->|"loads environment"| node_env
node_developer -->|"configures debugging"| node_debug_manager
node_debug_manager -->|"generates launch config"| node_debug_config
node_debug_manager -->|"selects backend"| node_debug_backends
node_debug_manager -->|"selects runner"| node_debug_runners
node_developer -->|"configures application"| node_kconfig
node_developer -->|"edits devicetree"| node_devicetree
node_developer -->|"analyzes memory"| node_memory_reports
node_developer -->|"inspects build"| node_dashboard
node_developer -->|"runs static analysis"| node_eclair
node_eclair -->|"runs analysis"| node_execution
node_developer -->|"generates and verifies"| node_sbom
node_sbom -->|"calls service"| node_sbom_client

click node_extension "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/extension.ts"
click node_host_tools "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/HostToolsPanel.ts"
click node_toolchains "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/ToolchainInstallations.ts"
click node_global_sdk "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/zephyr/globalSdkService.ts"
click node_west_workspace "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/WestWorkspace.ts"
click node_west_commands "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/commands/WestCommands.ts"
click node_application "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/ZephyrApplication.ts"
click node_build_config "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/ZephyrBuildConfig.ts"
click node_tasks "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/providers/ZephyrTaskProvider.ts"
click node_execution "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/execUtils.ts"
click node_env "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/env/zephyrEnvUtils.ts"
click node_debug_manager "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/DebugManagerPanel.ts"
click node_debug_config "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/debugTools/debugUtils.ts"
click node_debug_backends "https://github.com/ac6embedded/vscode-zephyr-workbench/tree/main/src/debug/backends"
click node_debug_runners "https://github.com/ac6embedded/vscode-zephyr-workbench/tree/main/src/debug/runners"
click node_kconfig "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/KconfigManagerPanel.ts"
click node_memory_reports "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/zephyr/memoryReportParser.ts"
click node_dashboard "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/ZephyrDashboardViewProvider.ts"
click node_eclair "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/EclairManagerPanel.ts"
click node_sbom "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/sbomtotal/sbomVerifyService.ts"
click node_sbom_client "https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/sbomtotal/sbomTotalClient.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_host_tools,node_toolchains,node_global_sdk,node_west_workspace,node_west_commands toneBlue
class node_application,node_build_config,node_tasks toneAmber
class node_debug_manager,node_debug_config,node_debug_backends,node_debug_runners toneMint
class node_kconfig,node_devicetree,node_memory_reports,node_dashboard,node_eclair,node_sbom,node_sbom_client toneRose
class node_extension,node_execution,node_env,node_developer toneIndigo
```

## Components

### Setup and Workspaces

- [Host Tools](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/HostToolsPanel.ts): `src/panels/HostToolsPanel.ts`
- [Toolchain Registry](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/ToolchainInstallations.ts): `src/models/ToolchainInstallations.ts`
- [Global SDK Discovery](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/zephyr/globalSdkService.ts): `src/utils/zephyr/globalSdkService.ts`
- [West Workspace](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/WestWorkspace.ts): `src/models/WestWorkspace.ts`
- [West Management](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/commands/WestCommands.ts): `src/commands/WestCommands.ts`

### Applications and Build

- [Zephyr Application](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/ZephyrApplication.ts): `src/models/ZephyrApplication.ts`
- [Build Configuration](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/models/ZephyrBuildConfig.ts): `src/models/ZephyrBuildConfig.ts`
- [Build and Flash Tasks](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/providers/ZephyrTaskProvider.ts): `src/providers/ZephyrTaskProvider.ts`

### Debug and Flash

- [Debug Manager](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/DebugManagerPanel.ts): `src/panels/DebugManagerPanel.ts`
- [Debug Configuration](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/debugTools/debugUtils.ts): `src/utils/debugTools/debugUtils.ts`
- [Debug Backends](https://github.com/ac6embedded/vscode-zephyr-workbench/tree/main/src/debug/backends): `src/debug/backends`
- [Debug Runners](https://github.com/ac6embedded/vscode-zephyr-workbench/tree/main/src/debug/runners): `src/debug/runners`

### Configuration and Analysis

- [Kconfig Manager](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/KconfigManagerPanel.ts): `src/panels/KconfigManagerPanel.ts`
- **Devicetree Editing**
- [Memory Analysis](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/zephyr/memoryReportParser.ts): `src/utils/zephyr/memoryReportParser.ts`
- [Build Dashboard](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/ZephyrDashboardViewProvider.ts): `src/panels/ZephyrDashboardViewProvider.ts`
- [ECLAIR Analysis](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/panels/EclairManagerPanel.ts): `src/panels/EclairManagerPanel.ts`
- [SBOM Services](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/sbomtotal/sbomVerifyService.ts): `src/sbomtotal/sbomVerifyService.ts`
- [SBOM Total Client](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/sbomtotal/sbomTotalClient.ts): `src/sbomtotal/sbomTotalClient.ts`

### Extension Runtime

- [Workbench Extension](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/extension.ts): `src/extension.ts`
- [Command Execution](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/execUtils.ts): `src/utils/execUtils.ts`
- [Build Environment](https://github.com/ac6embedded/vscode-zephyr-workbench/blob/main/src/utils/env/zephyrEnvUtils.ts): `src/utils/env/zephyrEnvUtils.ts`

### Other components

- **Developer**

## Connections

- Developer → Workbench Extension: uses (evidence: `README.md`)
- Workbench Extension → West Management: registers commands (evidence: `src/extension.ts`)
- Developer → Host Tools: installs tools (evidence: `README.md`)
- Developer → Toolchain Registry: adds toolchain (evidence: `README.md`)
- Toolchain Registry → Global SDK Discovery: discovers SDKs (evidence: `src/utils/zephyr/globalSdkService.ts`)
- Developer → West Workspace: creates workspace (evidence: `README.md`)
- West Management → West Workspace: manages (evidence: `src/commands/WestCommands.ts`)
- Developer → Zephyr Application: creates application (evidence: `README.md`)
- Zephyr Application → West Workspace: resolves workspace (evidence: `src/models/ZephyrApplication.ts`)
- Zephyr Application → Toolchain Registry: selects toolchain (evidence: `src/models/ZephyrApplication.ts`)
- Zephyr Application → Global SDK Discovery: resolves SDK (evidence: `src/models/ZephyrApplication.ts`)
- Zephyr Application → Build Configuration: defines configurations (evidence: `src/models/ZephyrApplication.ts`)
- Developer → Build and Flash Tasks: builds and flashes (evidence: `README.md`)
- Build and Flash Tasks → Command Execution: runs commands (evidence: `src/providers/ZephyrTaskProvider.ts`)
- Build Configuration → Build Environment: loads environment (evidence: `src/models/ZephyrBuildConfig.ts`)
- Developer → Debug Manager: configures debugging (evidence: `README.md`)
- Debug Manager → Debug Configuration: generates launch config (evidence: `src/panels/DebugManagerPanel.ts`)
- Debug Manager → Debug Backends: selects backend (evidence: `src/panels/DebugManagerPanel.ts`)
- Debug Manager → Debug Runners: selects runner (evidence: `src/panels/DebugManagerPanel.ts`)
- Developer → Kconfig Manager: configures application (evidence: `README.md`)
- Developer → Devicetree Editing: edits devicetree (evidence: `README.md`)
- Developer → Memory Analysis: analyzes memory (evidence: `README.md`)
- Developer → Build Dashboard: inspects build (evidence: `README.md`)
- Developer → ECLAIR Analysis: runs static analysis (evidence: `README.md`)
- ECLAIR Analysis → Command Execution: runs analysis (evidence: `src/panels/EclairManagerPanel.ts`)
- Developer → SBOM Services: generates and verifies (evidence: `README.md`)
- SBOM Services → SBOM Total Client: calls service (evidence: `src/sbomtotal/sbomVerifyService.ts`)
