Add Verilog parsing and rendering support #26

Open
purpl3F0x wants to merge 5 commits from purpl3F0x/circuiteria:main into main
pull from: purpl3F0x/circuiteria:main
First-time contributor

Hi, the above changes add some support for parsing a Verilog file and autogenerating a circuit module. The lib also supports bundling AXI buses and indicating active low resets.

Testing is limited, happy to make changes if needed.

Example
{8CE34B23-70F4-4DFD-9883-ABAB63814DEF}.png

Hi, the above changes add some support for parsing a Verilog file and autogenerating a circuit module. The lib also supports bundling AXI buses and indicating active low resets. Testing is limited, happy to make changes if needed. Example <img width="353" alt="{8CE34B23-70F4-4DFD-9883-ABAB63814DEF}.png" src="attachments/23b8cbd9-9ef8-4a86-af11-3623cd547c2c">
purpl3F0x added 1 commit 2026-09-10 13:18:26 +02:00
- Introduced `verilog.typ` for parsing Verilog/SystemVerilog source code, supporting both ANSI and non-ANSI port styles.
- Implemented functions to analyze modules, infer AXI4, AXI4-Lite, and AXI4-Stream buses, as well as clock and reset signals.
- Added rendering capabilities for Verilog modules, allowing for visual representation of ports and buses.
- Created a new `gallery/verilog.typ` file to facilitate the drawing of Verilog blocks in diagrams.

Signed-off-by: Stavros Avramidis <stavros9899@gmail.com>
purpl3F0x force-pushed main from 55ea5cdef6 to 0c1272e35e 2026-09-10 13:18:26 +02:00 Compare
HEL added the enhancement label 2026-09-14 07:13:14 +02:00
Owner

This looks great, thank you for your contribution !
I'm not very familiar with Verilog but I will try to review this soon

This looks great, thank you for your contribution ! I'm not very familiar with Verilog but I will try to review this soon
purpl3F0x added 1 commit 2026-10-25 10:29:06 +01:00
purpl3F0x added 1 commit 2026-11-03 12:04:09 +01:00
Signed-off-by: Stavros Avramidis <stavros9899@gmail.com>
purpl3F0x added 1 commit 2026-11-03 12:18:47 +01:00
purpl3F0x added 1 commit 2026-11-03 12:31:08 +01:00
- Add `ports-align` ("center" by default, "top", "bottom", or "spread" for
  the previous evenly spread layout) and `ports-pitch` to `verilog.block`.
- Packed layouts use minimal margins, only reserving room for the module
  name and north/south ports, and size the block to the busiest side.
- The automatic height now also adapts to custom `ports-margins`.
- Regenerate the gallery image and the manual.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Stavros Avramidis <stavros9899@gmail.com>
You are not authorized to merge this pull request.
This pull request can be merged automatically.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u https://git.kb28.ch/purpl3F0x/circuiteria main:purpl3F0x-main
git checkout purpl3F0x-main
Sign in to join this conversation.