piel.integration.hdl21_gdsfactory.netlist#

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

Attributes#

Functions#

_parse_module_to_proto_dict(→ ParsedProtoVLSIR)

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

_parse_connections(→ dict)

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

_find_target_instance_port(proto_dict, target_signal, ...)

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

_generate_top_level_connections(proto_dict)

Generate the top-level connections from the proto_dict.

_find_port_connection(proto_dict, port_signal)

Find the connection of the port signal in the proto_dict.

_extract_instance_parameters(proto_dict)

Extract the instance parameters from the proto_dict.

_extract_component_name(instance)

Extract the component name from the instance.

_extract_parameter_value(value)

Extract the parameter value from the value dictionary.

_generate_raw_netlist_dict_from_proto_dict(proto_dict)

Generate a raw netlist dictionary from the proto_dict.

generate_raw_netlist_dict_from_module(module)

Generate a raw netlist dictionary from a hdl21 module object.

generate_raw_yaml_from_module(module)

Generate a raw netlist yaml from a hdl21 module object which could be manually edited for specific instances

Module Contents#

ParsedProtoVLSIR#
_parse_module_to_proto_dict(module: piel.types.AnalogueModule) ParsedProtoVLSIR[source]#

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

_parse_connections(proto_dict: ParsedProtoVLSIR) dict[source]#

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

_find_target_instance_port(proto_dict: ParsedProtoVLSIR, target_signal, current_instance_name)[source]#

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

_generate_top_level_connections(proto_dict: ParsedProtoVLSIR)[source]#

Generate the top-level connections from the proto_dict.

_find_port_connection(proto_dict: ParsedProtoVLSIR, port_signal)[source]#

Find the connection of the port signal in the proto_dict.

_extract_instance_parameters(proto_dict: ParsedProtoVLSIR)[source]#

Extract the instance parameters from the proto_dict.

_extract_component_name(instance)[source]#

Extract the component name from the instance.

_extract_parameter_value(value)[source]#

Extract the parameter value from the value dictionary.

_generate_raw_netlist_dict_from_proto_dict(proto_dict: ParsedProtoVLSIR)[source]#

Generate a raw netlist dictionary from the proto_dict.

generate_raw_netlist_dict_from_module(module: piel.types.AnalogueModule)[source]#

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.

generate_raw_yaml_from_module(module: piel.types.AnalogueModule)[source]#

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