chiptools.parsers.options module
Options parser package for the build/verification framework application.
The Options class contained within provides convenient access to system configuration settings with error checking and file-modification checking.
The path to the system configuration file is hard-coded into options_path.
- class chiptools.parsers.options.Options[source]
Bases:
object
An Options instance provides convenient access to an INI based configuration file.
When an Options instance is created it will load the ‘.chiptoolsconfig’ file located in the root of the application and parse the settings contained within.
If no configuration file is preset a placeholder will be generated using the CONFIG_DEFAULTS as a base.
- CONFIG_DEFAULTS: Dict[str, Dict] = {'ghdl simulation libraries': {}, 'isim simulation libraries': {}, 'modelsim simulation libraries': {}, 'simulation executables': {}, 'synthesis executables': {}, 'vivado simulation libraries': {}}
- getSimulationTools()[source]
Return a dictionary of simulation tool name / path pairs.
If the configuration file was modified since the last access it will be reloaded and the new entries returned.
- getSynthesisTools()[source]
Return a dictionary of synthesis tool name / path pairs.
If the configuration file was modified since the last access it will be reloaded and the new entries returned.
- get_simulator_library_dependencies(toolname)[source]
Return the simulator library dependencies.
If the configuration file was modified since the last access it will be reloaded and the new entries returned.
- get_synthesis_tool_path(toolname)[source]
Return the executable path for the given simulator name ‘toolname’.
If no path is found for ‘toolname’ NoneType will be returned.
If the configuration file was modified since the last access it will be reloaded and the new entries returned.
- startup()[source]
Load the system configuration file and store the settings in local attributes.
The system configuration file MD5 sum is stored so that file changes can be detected at runtime.
This method will return an exception if the system configuration file is missing or contains invalid data.