1.2. Visualise Hierarchical Netlist (SVG/Interactive)ΒΆ

This example demonstrates how to visualize a netlist

  • SVG format, which uses Yosys and netlist SVG to render

  • Interactive viewer, which render hierarchical SVG using the d3-hwschematic project

../_images/basic_hierarchy.svg

Open schematic in separate window

The renderer is used from this project Nic30/d3-hwschematic

import spydrnet_physical as sdnphy
from spydrnet_physical.composers.html.composer import HTMLComposer
from spydrnet_physical.composers.svg.composer import SVGComposer

netlist = sdnphy.load_netlist_by_name("basic_hierarchy")

library = netlist.libraries[0]
library.create_top_wrapper("top_wrapper", inst_name="top_wrapper")

composer = HTMLComposer()
composer.run(netlist, file_out="_initial_design.html")

composer = SVGComposer()
composer.expand(modules=["top"])
composer.run(netlist, file_out="_initial_design.svg",
             netlistsvg="netlistsvg-hierarchy")

Total running time of the script: ( 0 minutes 0.000 seconds)

Gallery generated by Sphinx-Gallery