Never miss a story from Analog/Custom Design. Subscribe for in-depth analysis and articles.
Cadence Spectre AMS Designer is a high-performance mixed-signal simulation system. The ability to use multiple engines and drive from a variety of platforms enables you to "rev up" your mixed-signal design verification and take the checkered flag in the race to the market. The Start Your Engines! blog series will provide you with tips and insights to help you tune your simulation performance and accelerate down the road to productivity.
In this post, I will explain how you can easily convert a logic signal to an electrical value using the Verilog-AMS standard language defined by Accellera.
First, let me draw the symbol for this model.
The model is named L2Econv, and it has:
The following table describes the model parameters:
vdd supply voltage
high level output value
low level output value
output series resistor
The L2Econv module can be considered equivalent to a level shifter. The only difference is that instead of an electrical input, it has a logic input. The output is electrical and operates with the supply value.
The disciplines.vams file is included in this model to provide the necessary Verilog-AMS discipline definitions (electrical) and the definition of the voltage and current access functions.
The idea behind this model is to:
The behavioral code is as follows:
It lets you perform a logic-to-electrical conversion. Inside the analog block, you generate the current branch to define a Norton generator, where rout is the value of the output resistor.
This model is very compact. With one initial, two always, and one analog block, this behavioral model is created.
Now, you just need to test the model.
The testbench is a stimuli digital generator source driving the logic L2Econv module input. It sends the logic values 1’b0, 1’b1, 1’bx, 1’bz sequentially.
With SimVision MS Debug, you can automatically create the schematic. It also annotates values in the schematic, as shown in the figure. The L2Econv module described in Verilog-AMS is a mixed-signal model, so the instance is highlighted in blue. The figure shows the stimuli digital generator driven by 1’b1. The L2Econv module then translates this value to 1 volt.
The plotted waveforms are as shown in the following figure:
In this figure:
The following waveform shows the transition operation:
In this waveform:
You can send an L2Econv instance to the Source Browser, perform a step-by-step operation investigation, or set a breakpoint at a specific line, as shown in the figure. The breakpoint causes the debugger to pause the simulation when it reaches the line execution. This allows us to examine the input and output, the internal register, and variable values. When you launch a batch simulation, you cannot execute inteactive debug and understand the model line by line and step by step operation, study the source code operation in detail. SimVision MS Debug provides you visibility on the code operation. The invisible value changes in the internal analog and digital variables become visible.
SimVision MS Debug lets you annotate internal variables and display their values at the current time. These values that are usually invisible during a batch simulation become visible.
In the figure shown below, we observe that the simulation is paused because a breakpoint is set up at line number 21.
I hope you are now excited to try this model and SimVision MS Debug features out for yourself! If you need more details, contact Cadence Customer Support team.
~ Andre Baguenier
Start Your Engines: An Innovative and Efficient Approach to Debug Interface Elements with SimVision MS
Start Your Engines: Win Le Mans with the SimVision Mixed-Signal Debug Option
Start Your Engines: Best Practices for Converting an Electrical Signal to a Logic Value with Mixed-Signal Modeling
Start Your Engines: Mixed-Signal Modeling Methods for Converting an Electrical Signal to a Real Number
Start Your Engines: Mixed-Signal Modeling Best Practices for Converting a Real Number Signal to Electrical
Spectre AMS Designer and Xcelium Mixed-Signal User Guide
Spectre AMS Designer
For more information on Cadence circuit design products and services, visit www.cadence.com.
The Start Your Engines series brings you blog posts from several analog/mixed-signal subject matter experts on a variety of topics, such as introduction to the new features in AMS Designer, tips for enhanced working with existing features, and much more. To receive notifications about new blogs in this series, click Subscribe and submit your email ID in the Subscriptions box.