piel.integration.hdl21_gdsfactory.netlist
=========================================

.. py:module:: piel.integration.hdl21_gdsfactory.netlist

.. autoapi-nested-parse::

   This module provides functions to generate a raw netlist semi-compatible with gdsfactory from a hdl21 module object.



Attributes
----------

.. autoapisummary::

   piel.integration.hdl21_gdsfactory.netlist.ParsedProtoVLSIR


Functions
---------

.. autoapisummary::

   piel.integration.hdl21_gdsfactory.netlist._parse_module_to_proto_dict
   piel.integration.hdl21_gdsfactory.netlist._parse_connections
   piel.integration.hdl21_gdsfactory.netlist._find_target_instance_port
   piel.integration.hdl21_gdsfactory.netlist._generate_top_level_connections
   piel.integration.hdl21_gdsfactory.netlist._find_port_connection
   piel.integration.hdl21_gdsfactory.netlist._extract_instance_parameters
   piel.integration.hdl21_gdsfactory.netlist._extract_component_name
   piel.integration.hdl21_gdsfactory.netlist._extract_parameter_value
   piel.integration.hdl21_gdsfactory.netlist._generate_raw_netlist_dict_from_proto_dict
   piel.integration.hdl21_gdsfactory.netlist.generate_raw_netlist_dict_from_module
   piel.integration.hdl21_gdsfactory.netlist.generate_raw_yaml_from_module


Module Contents
---------------

.. py:data:: ParsedProtoVLSIR

.. py:function:: _parse_module_to_proto_dict(module: piel.types.AnalogueModule) -> ParsedProtoVLSIR

   Parse a hdl21 module object into a dictionary with the same structure as the proto VLSIR format.


.. py:function:: _parse_connections(proto_dict: ParsedProtoVLSIR) -> dict

   Extract the connections from the proto_dict and return a dictionary with the connections.


.. py:function:: _find_target_instance_port(proto_dict: ParsedProtoVLSIR, target_signal, current_instance_name)

   Find the target instance and port of the target signal in the proto_dict.


.. py:function:: _generate_top_level_connections(proto_dict: ParsedProtoVLSIR)

   Generate the top-level connections from the proto_dict.


.. py:function:: _find_port_connection(proto_dict: ParsedProtoVLSIR, port_signal)

   Find the connection of the port signal in the proto_dict.


.. py:function:: _extract_instance_parameters(proto_dict: ParsedProtoVLSIR)

   Extract the instance parameters from the proto_dict.


.. py:function:: _extract_component_name(instance)

   Extract the component name from the instance.


.. py:function:: _extract_parameter_value(value)

   Extract the parameter value from the value dictionary.


.. py:function:: _generate_raw_netlist_dict_from_proto_dict(proto_dict: ParsedProtoVLSIR)

   Generate a raw netlist dictionary from the proto_dict.


.. py:function:: generate_raw_netlist_dict_from_module(module: piel.types.AnalogueModule)

   Generate a raw netlist dictionary from a hdl21 module object.
   This just gives us a raw structure of the hdl21 modules, we cannot use this json equivalently to a gdsfactory netlist.


.. py:function:: generate_raw_yaml_from_module(module: piel.types.AnalogueModule)

   Generate a raw netlist yaml from a hdl21 module object which could be manually edited for specific instances
   related to the corresponding SPICE.


