standanley / fixture

Library of templates for analog blocks and strategies to model them in a digital environment

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

fixture

Build Status

fixture is a tool to help circuit designers model mixed-signal systems. The goal is to automatically analyze analog blocks at the spice level and produce equivalent functional models in SystemVerilog. The models are pin-compatible and include the behavior of all pins, allowing the user to test complex digital-analog interaction in a fully digital simulator.

To accomplish this goal, fixture draws on a library of hand-written templates to analyze circuits and extract parameters. These parameters can then be used to create functional models using tools such as DaVE or msdsl.

If you are ready to start modeling, take a look at the wiki! https://github.com/standanley/fixture/wiki

Templates for analysis

Recently, development on fixture has been focused on circuit analysis. The goal is to create a library of flexible analysis scripts that can cover a wide variety of circuits. The existing templates can be found in fixture/templates. The main advantage of fixture is that each of these templates can cover many variations of the core circuit; for example, the differential amplifier template can analyze a basic differential amplifier as well as bias circuitry and calibration inputs, as well as CTLEs and TIAs.

The output of an analysis template is a list of extracted parameters. For a differential amplifier, these parameters might be the gain, the common-mode gain, and the pole and zero locations. These parameters can be used to verify circuit behavior, as the basis for a functional model, or to verify model behavior.

Templates for models

Once parameters have been extracted using an analysis template, they can be inserted into a functional model. Models are typically hand-written for a specific class of circuit, with annotations for the tool to fill in extracted information. Two examples, for use with the DaVE tool mGenero, can be found in tests/configs/amplifier.template.sv and tests/configs/phase_blender.sv. fixture no longer automatically generates the collateral needed to create these, but for linear models the conversion from fixture's output to mGenero's input is straightforward if you are familiar with mGenero. These two examples are written for use in a CPU-based simulation, although mGenero could also be used with models intended for FPGA emulation.

It is also possible to combine fixture with other tools for model generation. An example of integration with msdsl can be found here.

Installation

fixture is written in python3, so the first step is to set up a python3 environment. fixture uses fault for interacting with simulators. Temporarily, fixture has its own development branch of fault, found here. The recommended way of installing is to use git to download the source code from the development branch, and install with pip.

git clone https://github.com/standanley/fault/tree/fixture_additions
cd fault
pip install -e .
cd ..

Then, install fixture the same way.

git clone https://github.com/standanley/fixture
cd fixture
pip install -e .
cd ..

To run fixture, the user should first create a config file with the location of necessary files, simulator information, and information about the circuit to be analyzed. Many example config files can be found in tests/configs. A config file can be run with

python -m fixture.run path/to/config

Now that fixture is installed, head to the wiki to learn how to use it: https://github.com/standanley/fixture/wiki

About

Library of templates for analog blocks and strategies to model them in a digital environment

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:Python 74.5%Language:SourcePawn 15.3%Language:SystemVerilog 6.2%Language:JavaScript 2.8%Language:Shell 0.9%Language:HTML 0.1%Language:CSS 0.1%