Skip to content

Add HDElkDiagramGen API documentation#292

Draft
Copilot wants to merge 3 commits intomasterfrom
copilot/add-api-description-hdelk-diagram-gen
Draft

Add HDElkDiagramGen API documentation#292
Copilot wants to merge 3 commits intomasterfrom
copilot/add-api-description-hdelk-diagram-gen

Conversation

Copy link

Copilot AI commented Feb 28, 2026

HDElkDiagramGen (introduced in SpinalHDL/SpinalHDL#1079) lacked any documentation. This adds a reference page covering its setup, usage, import path, and generated output.

The tool has since been moved to the separate SpinalSchemaGen library, so the documentation reflects the current state of the code.

Changes

  • New file: source/SpinalHDL/Libraries/EDA/tools/hdelkdiagramgen.rst
    • Setup section: SBT dependency ("com.github.spinalhdl" %% "spinalhdl-schema-gen" % "0.0.4") required to use the tool
    • Import path (spinal.schema.elk.HDElkDiagramGen) and minimal usage example for both SpinalVerilog and SpinalVHDL
    • Description of the generated <TopLevelName>.html output: ports, signals, inter-module connections, and per-clock-domain colour coding
    • Link to the SpinalSchemaGen repository
  • No index edits needed — the existing EDA/index.rst */* glob picks up the new file automatically

Usage

// build.sbt
libraryDependencies += "com.github.spinalhdl" %% "spinalhdl-schema-gen" % "0.0.4"
import spinal.schema.elk.HDElkDiagramGen

HDElkDiagramGen(SpinalVerilog(new MyToplevel))
// Produces MyToplevel.html — open in any modern browser
Original prompt

This section details on the original issue you should resolve

<issue_title>Add API description for HDElkDiagramGen</issue_title>
<issue_description>Do not merge until SpinalHDL/SpinalHDL#1079 has not been merged.
Due to SpinalHDL/SpinalHDL#1079 submission, a new application API method has been generated.

import spinal.lib.tools.HDElkDiagramGen
HDElkDiagramGen(SpinalVerilog(new _))

This function will generate a new file named _.html .Use your browser to open it.</issue_description>

Comments on the Issue (you are @copilot in this section)


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: Readon <3614708+Readon@users.noreply.github.com>
@Readon
Copy link
Collaborator

Readon commented Feb 28, 2026

Now, some part of the Schema Generator have been moved to SpinalHDL/SpinalSchemaGen , Check the code and rethink on it. @copilot

Copilot AI changed the title [WIP] Add API description for HDElkDiagramGen Add HDElkDiagramGen API documentation Feb 28, 2026
…ndency

Co-authored-by: Readon <3614708+Readon@users.noreply.github.com>
Copy link
Author

Copilot AI commented Feb 28, 2026

Now, some part of the Schema Generator have been moved to SpinalHDL/SpinalSchemaGen , Check the code and rethink on it. @copilot

Updated in d5f1950. The documentation now reflects the move to SpinalHDL/SpinalSchemaGen:

  • Import path corrected from spinal.lib.tools.HDElkDiagramGenspinal.schema.elk.HDElkDiagramGen
  • Added a Setup section with the required SBT dependency ("com.github.spinalhdl" %% "spinalhdl-schema-gen" % "0.0.4")
  • Added a link to the SpinalSchemaGen repository

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add API description for HDElkDiagramGen

2 participants