peakrdl-python 1.0.1__tar.gz → 1.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/.github/workflows/action.yaml +1 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/PKG-INFO +1 -1
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/__about__.py +1 -1
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/exporter.py +11 -1
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_simulation_tb.py.jinja +3 -3
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_tb.py.jinja +6 -6
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/baseclass_simulation_tb.py.jinja +9 -9
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/baseclass_tb.py.jinja +7 -7
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python.egg-info/PKG-INFO +1 -1
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python.egg-info/SOURCES.txt +1 -0
- peakrdl_python-1.1.0/tests/testcases/parametrised_top.rdl +13 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/.gitignore +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/.readthedocs.yaml +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/LICENSE +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/MANIFEST.in +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/README.md +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/api.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/api_components.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/command_line.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/conf.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/customisation.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/design_decisions.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/design_tools.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/generated_package.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/genindex.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/index.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/installation.rst +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/docs/requirements.txt +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/array_access/array_access.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/array_access/demo_array_access.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/enumerated_fields/demo_enumerated_fields.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/enumerated_fields/enumerated_fields.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/optimised_access/demo_optimised_access.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/optimised_access/demo_optimised_array_access.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/optimised_access/optimised_access.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/optimised_access/optimised_array_access.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/overridden_names/demo_over_ridden_names.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/overridden_names/overridden_names.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/simulating_callbacks/chip_with_a_GPIO.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/simulating_callbacks/flashing_the_LED.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/tranversing_address_map/chip_with_registers.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/tranversing_address_map/dumping_register_state_to_json_file.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/tranversing_address_map/reg_dump.json +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/tranversing_address_map/reseting_registers.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/tranversing_address_map/writing_register_state_from_json_file.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/user_defined_properties/demo_user_defined_properties.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/user_defined_properties/user_defined_properties.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/why_ral/__init__.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/why_ral/gpio.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/why_ral/with_hal.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/why_ral/with_ral.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/why_ral/without_ral.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/generate_and_test.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/generate_testcases.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/pyproject.toml +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/setup.cfg +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/.coveragerc +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/__init__.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/__peakrdl__.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/_node_walkers.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/compiler_udp.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/__init__.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/async_memory.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/async_register_and_field.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/base.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/base_field.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/base_register.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/callbacks.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/memory.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/py.typed +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/register_and_field.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/utility_functions.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/py.typed +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/safe_name_utility.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/__init__.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/_callbacks.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/base.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/dummy_callbacks.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/field.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/memory.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/py.typed +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/register.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/sim_lib/simulator.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/systemrdl_node_utility_functions.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/__init__.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_field.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_memory.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_register.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_simulation.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_udp_property.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/example.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/header.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/header_tb.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/reg_definitions.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/sim_addrmap.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python.egg-info/dependency_links.txt +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python.egg-info/entry_points.txt +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python.egg-info/requires.txt +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python.egg-info/top_level.txt +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates/header.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates/header_tb.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_dynamic/header.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_dynamic/header_tb.py.jinja +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_dynamic_toml/header_check.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_dynamic_toml/peakrdl.toml +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_toml/header_check.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_toml/peakrdl.toml +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/RDLFormatCode_example.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/addr_map.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/all_register_access_types.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/basic.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/block_a.xml +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/block_b.xml +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/different_array_types.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/enum_example.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/example_issue_106.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/extended_memories.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/extended_sizes_registers_array.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/field_scope.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/field_with_overridden_reset.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/fields_with_HW_write.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/fields_with_reset_values.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/hidden_property.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/memories.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/memories_with_registers.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/msb0_and_lsb0.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/multi_block.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/multifile.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/name_clash.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/overridden_python_name.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/parametrised_readonly_and_readwrite.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/regfile_and_arrays.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/reserved_elements.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/same_but_different_enum.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/signals_definitions_at_various_levels.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/simple.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/simple.xml +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/simulator_test.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/sizes_registers.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/sizes_registers_array.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/user_defined_properties.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/write_only_enum_with_undefined_reset.rdl +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/unit_tests/__init__.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/unit_tests/simple_components.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/unit_tests/test_array_indexing.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/unit_tests/test_export.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/unit_tests/test_optimised_reg_array.py +0 -0
- {peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/unit_tests/test_reg.py +0 -0
|
@@ -175,6 +175,7 @@ jobs:
|
|
|
175
175
|
peakrdl python tests/testcases/extended_memories.rdl -o peakrdl_out/raw/
|
|
176
176
|
peakrdl python tests/testcases/user_defined_properties.rdl -o peakrdl_out/raw/ --udp bool_property_to_include
|
|
177
177
|
peakrdl python tests/testcases/reserved_elements.rdl -o peakrdl_out/raw/ --hide_regex "(?:[\w_\[\]]+\.)+RSVD"
|
|
178
|
+
peakrdl python tests/testcases/parametrised_top.rdl -o peakrdl_out/raw/ -P MY_PARAM=3
|
|
178
179
|
python -m unittest discover -s peakrdl_out/raw
|
|
179
180
|
|
|
180
181
|
peakrdl python tests/testcases/basic.rdl -o peakrdl_out/raw_async/ --async
|
|
@@ -735,8 +735,18 @@ class PythonExporter:
|
|
|
735
735
|
# de-duplicate the values
|
|
736
736
|
raise RuntimeError("node is already in the lookup dictionary")
|
|
737
737
|
|
|
738
|
-
|
|
738
|
+
if child_node == node:
|
|
739
|
+
# in the case of the top node the type name should match the instance name
|
|
740
|
+
cand_type_name = child_node.inst_name
|
|
741
|
+
else:
|
|
742
|
+
cand_type_name = get_fully_qualified_type_name(child_node)
|
|
739
743
|
if cand_type_name in self.node_type_name.values():
|
|
744
|
+
if child_node == node:
|
|
745
|
+
raise RuntimeError(
|
|
746
|
+
f'Top Node name {cand_type_name} already used by instance ' \
|
|
747
|
+
+ str(list(self.node_type_name.keys())
|
|
748
|
+
[list(self.node_type_name.values()).index(cand_type_name)])
|
|
749
|
+
)
|
|
740
750
|
self.node_type_name[child_inst] = cand_type_name + '_0x' + hex(hash(child_inst))
|
|
741
751
|
else:
|
|
742
752
|
self.node_type_name[child_inst] = cand_type_name
|
|
@@ -35,10 +35,10 @@ from enum import IntEnum
|
|
|
35
35
|
from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}sim_lib.register import Register,MemoryRegister
|
|
36
36
|
from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}sim_lib.field import Field
|
|
37
37
|
|
|
38
|
-
from ._{{top_node.inst_name}}_sim_test_base import {{top_node.
|
|
38
|
+
from ._{{top_node.inst_name}}_sim_test_base import {{top_node.inst_name}}_SimTestCase, {{top_node.inst_name}}_SimTestCase_BlockAccess
|
|
39
39
|
from ._{{top_node.inst_name}}_sim_test_base import __name__ as base_name
|
|
40
40
|
|
|
41
|
-
class {{fq_block_name}}_single_access({{top_node.
|
|
41
|
+
class {{fq_block_name}}_single_access({{top_node.inst_name}}_SimTestCase): # type: ignore[valid-type,misc]
|
|
42
42
|
|
|
43
43
|
{% if asyncoutput %}async {% endif %}def test_register_read_and_write(self) -> None:
|
|
44
44
|
"""
|
|
@@ -335,7 +335,7 @@ class {{fq_block_name}}_single_access({{top_node.type_name}}_SimTestCase): # typ
|
|
|
335
335
|
|
|
336
336
|
|
|
337
337
|
|
|
338
|
-
class {{fq_block_name}}_block_access({{top_node.
|
|
338
|
+
class {{fq_block_name}}_block_access({{top_node.inst_name}}_SimTestCase_BlockAccess): # type: ignore[valid-type,misc]
|
|
339
339
|
"""
|
|
340
340
|
tests for all the block access methods
|
|
341
341
|
"""
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_tb.py.jinja
RENAMED
|
@@ -35,9 +35,9 @@ from enum import IntEnum
|
|
|
35
35
|
|
|
36
36
|
from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}lib import RegisterWriteVerifyError, UnsupportedWidthError
|
|
37
37
|
|
|
38
|
-
from ..reg_model.{{top_node.
|
|
38
|
+
from ..reg_model.{{top_node.inst_name}} import {{top_node.inst_name}}_cls
|
|
39
39
|
{% for property_enum in dependent_property_enum %}
|
|
40
|
-
from ..reg_model.{{top_node.
|
|
40
|
+
from ..reg_model.{{top_node.inst_name}} import {{property_enum.type_name}}_property_enumcls
|
|
41
41
|
{% endfor %}
|
|
42
42
|
|
|
43
43
|
|
|
@@ -67,12 +67,12 @@ from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}lib import
|
|
|
67
67
|
from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}lib import Field
|
|
68
68
|
from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}lib import Reg
|
|
69
69
|
|
|
70
|
-
from ._{{top_node.inst_name}}_test_base import {{top_node.
|
|
70
|
+
from ._{{top_node.inst_name}}_test_base import {{top_node.inst_name}}_TestCase, {{top_node.inst_name}}_TestCase_BlockAccess, {{top_node.inst_name}}_TestCase_AltBlockAccess
|
|
71
71
|
from ._{{top_node.inst_name}}_test_base import __name__ as base_name
|
|
72
72
|
|
|
73
73
|
{% from 'addrmap_udp_property.py.jinja' import udp_property_dict_entry with context %}
|
|
74
74
|
|
|
75
|
-
class {{fq_block_name}}_single_access({{top_node.
|
|
75
|
+
class {{fq_block_name}}_single_access({{top_node.inst_name}}_TestCase): # type: ignore[valid-type,misc]
|
|
76
76
|
|
|
77
77
|
def test_inst_name(self) -> None:
|
|
78
78
|
"""
|
|
@@ -1329,7 +1329,7 @@ class {{fq_block_name}}_single_access({{top_node.type_name}}_TestCase): # type:
|
|
|
1329
1329
|
|
|
1330
1330
|
|
|
1331
1331
|
|
|
1332
|
-
class {{fq_block_name}}_block_access({{top_node.
|
|
1332
|
+
class {{fq_block_name}}_block_access({{top_node.inst_name}}_TestCase_BlockAccess): # type: ignore[valid-type,misc]
|
|
1333
1333
|
"""
|
|
1334
1334
|
tests for all the block access methods
|
|
1335
1335
|
"""
|
|
@@ -1488,7 +1488,7 @@ class {{fq_block_name}}_block_access({{top_node.type_name}}_TestCase_BlockAccess
|
|
|
1488
1488
|
|
|
1489
1489
|
{%- endfor %}
|
|
1490
1490
|
|
|
1491
|
-
class {{fq_block_name}}_alt_block_access({{top_node.
|
|
1491
|
+
class {{fq_block_name}}_alt_block_access({{top_node.inst_name}}_TestCase_AltBlockAccess): # type: ignore[valid-type,misc]
|
|
1492
1492
|
"""
|
|
1493
1493
|
tests for all the block access methods with the alternative callbacks, this is a simpler
|
|
1494
1494
|
version of the tests above
|
|
@@ -37,23 +37,23 @@ from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}lib import
|
|
|
37
37
|
from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}lib import NormalCallbackSet{% if legacy_block_access %}Legacy{% endif %}
|
|
38
38
|
{% endif %}
|
|
39
39
|
|
|
40
|
-
from ._{{top_node.inst_name}}_test_base import {{top_node.
|
|
40
|
+
from ._{{top_node.inst_name}}_test_base import {{top_node.inst_name}}_TestCase, {{top_node.inst_name}}_TestCase_BlockAccess
|
|
41
41
|
|
|
42
|
-
from ..reg_model.{{top_node.
|
|
43
|
-
from ..sim.{{top_node.
|
|
42
|
+
from ..reg_model.{{top_node.inst_name}} import {{top_node.inst_name}}_cls
|
|
43
|
+
from ..sim.{{top_node.inst_name}} import {{top_node.inst_name}}_simulator_cls
|
|
44
44
|
|
|
45
|
-
class {{top_node.
|
|
45
|
+
class {{top_node.inst_name}}_SimTestCase({{top_node.inst_name}}_TestCase): # type: ignore[valid-type,misc]
|
|
46
46
|
|
|
47
47
|
def setUp(self) -> None:
|
|
48
|
-
self.sim = {{top_node.
|
|
49
|
-
self.dut = {{top_node.
|
|
48
|
+
self.sim = {{top_node.inst_name}}_simulator_cls(address=0)
|
|
49
|
+
self.dut = {{top_node.inst_name}}_cls(callbacks={% if asyncoutput %}AsyncCallbackSet{% else %}NormalCallbackSet{% endif %}{% if legacy_block_access %}Legacy{% endif %}(read_callback=self.sim.read,
|
|
50
50
|
write_callback=self.sim.write))
|
|
51
51
|
|
|
52
|
-
class {{top_node.
|
|
52
|
+
class {{top_node.inst_name}}_SimTestCase_BlockAccess({{top_node.inst_name}}_TestCase_BlockAccess): # type: ignore[valid-type,misc]
|
|
53
53
|
|
|
54
54
|
def setUp(self) -> None:
|
|
55
|
-
self.sim = {{top_node.
|
|
56
|
-
self.dut = {{top_node.
|
|
55
|
+
self.sim = {{top_node.inst_name}}_simulator_cls(address=0)
|
|
56
|
+
self.dut = {{top_node.inst_name}}_cls(callbacks={% if asyncoutput %}AsyncCallbackSet{% else %}NormalCallbackSet{% endif %}{% if legacy_block_access %}Legacy{% endif %}(read_callback=self.sim.read,
|
|
57
57
|
write_callback=self.sim.write,
|
|
58
58
|
read_block_callback=self.sim.read_block,
|
|
59
59
|
write_block_callback=self.sim.write_block))
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/baseclass_tb.py.jinja
RENAMED
|
@@ -38,7 +38,7 @@ from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}lib import
|
|
|
38
38
|
{% endif %}
|
|
39
39
|
|
|
40
40
|
|
|
41
|
-
from ..reg_model.{{top_node.
|
|
41
|
+
from ..reg_model.{{top_node.inst_name}} import {{top_node.inst_name}}_cls
|
|
42
42
|
{% if asyncoutput %}
|
|
43
43
|
from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}sim_lib.dummy_callbacks import async_dummy_read as read_addr_space
|
|
44
44
|
from {% if skip_lib_copy %}src.peakrdl_python.{% else %}..{% endif %}sim_lib.dummy_callbacks import async_dummy_write as write_addr_space
|
|
@@ -83,10 +83,10 @@ else:
|
|
|
83
83
|
TestCaseBase = unittest.TestCase
|
|
84
84
|
{% endif %}
|
|
85
85
|
|
|
86
|
-
class {{top_node.
|
|
86
|
+
class {{top_node.inst_name}}_TestCase(TestCaseBase): # type: ignore[valid-type,misc]
|
|
87
87
|
|
|
88
88
|
def setUp(self) -> None:
|
|
89
|
-
self.dut = {{top_node.
|
|
89
|
+
self.dut = {{top_node.inst_name}}_cls(callbacks={% if asyncoutput %}AsyncCallbackSet{% else %}NormalCallbackSet{% endif %}{% if legacy_block_access %}Legacy{% endif %}(read_callback=read_callback,
|
|
90
90
|
write_callback=write_callback))
|
|
91
91
|
|
|
92
92
|
@staticmethod
|
|
@@ -106,22 +106,22 @@ class {{top_node.type_name}}_TestCase(TestCaseBase): # type: ignore[valid-type,m
|
|
|
106
106
|
result |= 1 << (number_bits - 1 - i)
|
|
107
107
|
return result
|
|
108
108
|
|
|
109
|
-
class {{top_node.
|
|
109
|
+
class {{top_node.inst_name}}_TestCase_BlockAccess(TestCaseBase): # type: ignore[valid-type,misc]
|
|
110
110
|
|
|
111
111
|
def setUp(self) -> None:
|
|
112
|
-
self.dut = {{top_node.
|
|
112
|
+
self.dut = {{top_node.inst_name}}_cls(callbacks={% if asyncoutput %}AsyncCallbackSet{% else %}NormalCallbackSet{% endif %}{% if legacy_block_access %}Legacy{% endif %}(read_callback=read_callback,
|
|
113
113
|
write_callback=write_callback,
|
|
114
114
|
read_block_callback=read_block_callback,
|
|
115
115
|
write_block_callback=write_block_callback))
|
|
116
116
|
|
|
117
|
-
class {{top_node.
|
|
117
|
+
class {{top_node.inst_name}}_TestCase_AltBlockAccess(TestCaseBase): # type: ignore[valid-type,misc]
|
|
118
118
|
"""
|
|
119
119
|
Based test to use with the alternative call backs, this allow the legacy output API to be tested
|
|
120
120
|
with the new callbacks and visa versa.
|
|
121
121
|
"""
|
|
122
122
|
|
|
123
123
|
def setUp(self) -> None:
|
|
124
|
-
self.dut = {{top_node.
|
|
124
|
+
self.dut = {{top_node.inst_name}}_cls(callbacks={% if asyncoutput %}AsyncCallbackSet{% else %}NormalCallbackSet{% endif %}{% if not legacy_block_access %}Legacy{% endif %}(
|
|
125
125
|
read_callback=read_callback,
|
|
126
126
|
write_callback=write_callback,
|
|
127
127
|
read_block_callback=read_block_callback_alt,
|
|
@@ -127,6 +127,7 @@ tests/testcases/multifile.rdl
|
|
|
127
127
|
tests/testcases/name_clash.rdl
|
|
128
128
|
tests/testcases/overridden_python_name.rdl
|
|
129
129
|
tests/testcases/parametrised_readonly_and_readwrite.rdl
|
|
130
|
+
tests/testcases/parametrised_top.rdl
|
|
130
131
|
tests/testcases/regfile_and_arrays.rdl
|
|
131
132
|
tests/testcases/reserved_elements.rdl
|
|
132
133
|
tests/testcases/same_but_different_enum.rdl
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/enumerated_fields/demo_enumerated_fields.py
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/enumerated_fields/enumerated_fields.rdl
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/optimised_access/demo_optimised_access.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/optimised_access/optimised_array_access.rdl
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/overridden_names/demo_over_ridden_names.py
RENAMED
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/simulating_callbacks/chip_with_a_GPIO.rdl
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/simulating_callbacks/flashing_the_LED.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/example/tranversing_address_map/reseting_registers.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/lib/async_register_and_field.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/systemrdl_node_utility_functions.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_field.py.jinja
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_memory.py.jinja
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/addrmap_register.py.jinja
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/header_tb.py.jinja
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/reg_definitions.py.jinja
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python/templates/sim_addrmap.py.jinja
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/src/peakrdl_python.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates/header_tb.py.jinja
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_dynamic/header.py.jinja
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_dynamic/header_tb.py.jinja
RENAMED
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_dynamic_toml/peakrdl.toml
RENAMED
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/alternative_templates_toml/header_check.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/extended_sizes_registers_array.rdl
RENAMED
|
File without changes
|
|
File without changes
|
{peakrdl_python-1.0.1 → peakrdl_python-1.1.0}/tests/testcases/field_with_overridden_reset.rdl
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|