Re: support for multiple supplies

From: Jonathan David <j.david_at_.....>
Date: Thu Sep 07 2006 - 14:14:22 PDT
If that's not a simulator bug, its blows a big hole in the paper I'm presenting at BMAS next week. 
I was assuming that if there is no

connect logic_ss cmlogic resolveto logic_ss;

statement that the different disciplines would not be allowed to connect without error. 
Just because they are both discrete doesn't imply to me that they are compatible. 
I'll have to test this out my self.

But we need to add to 8.4.2 (in the 2.2 LRM)

It shall be an error to connect incompatible discrete disciplines together.


Jonathan

----- Original Message ----
From: Ken Kundert <ken@designers-guide.com>
To: Verilog-AMS LRM Reflector <verilog-ams@eda.org>
Sent: Thursday, September 7, 2006 1:57:12 PM
Subject: support for multiple supplies

All,
    I saw the article in the EE-Times insert "EDA Tech Forum" by Strahle
and Gossman from Infineon on using VHDL-AMS to find issues in designs
that stem from having multiple power supplies. Their approach seemed a
bit crude, so I thought I would try using the Verilog-AMS natures and
disciplines to try to provide a more elegant solution. What I wanted at
a minimum was to prevent from connecting gates that operate at one
supply voltage from being connected gates that use another supply
voltage. So I tried to define new disciplines as follows ...

discipline logic1p2
    domain discrete;
enddiscipline
discipline logic1p5
    domain discrete;
enddiscipline

module inv1p2 (out, in);
    output out;
    input in;
    logic1p2 out, in;

    assign out = !in;
endmodule

module inv1p5 (out, in);
    output out;
    input in;
    logic1p5 out, in;

    assign out = !in;
endmodule

module testbench;
    logic1p2 n1;
    logic1p5 n2;

    inv1p2 I1 (.out(n2), .in(n1));
    inv1p5 I2 (.out(n1), .in(n2));
endmodule

Verilog-AMS then allowed me to connect together ports with two different
disciplines because apparently they are compatible. So question number
one ...

Q1: Is there a way of explicitly declaring that two disciplines are
incompatible? Perhaps ...
    connectrules multisupply;
        connect logic1p2, logic1p5 resolveto error;
    endconnectrules
or
    connectrules multisupply;
        connect logic1p2, logic1p5 resolveto error("you must connect
1.2v logic to 1.5v logic");
    endconnectrules


So then I tried using connect modules, by adding the following to the
above example ...

connectmodule logic1p2to1p5 (out, in);
    output out;
    input in;
    logic1p5 out;
    logic1p2 in;

    initial $stobe("ERROR: %M: 1.2v logic driving 1.5v logic");
    assign out = 1'bx;
endmodule

connectmodule logic1p5to1p2 (out, in);
    output out;
    input in;
    logic1p2 out;
    logic1p5 in;

    initial $stobe("ERROR: %M: 1.5v logic driving 1.2v logic");
    assign out = 1'bx;
endmodule

connectrules multisupply;
    connect logic1p2to1p5;
    connect logic1p5to1p2;
endconnectrules

But this does not work because connect modules must have exactly one
discrete port and one continuous port. So question number 2 ...

Q2: Why have this restriction. Why can't we support connect modules that
have two discrete ports or two continuous ports?

Does anybody have any suggestions on how to prevent logic gates from
different supply domains from being connected together?

Thanks,
-Ken

begin:vcard
fn:Ken Kundert
n:Kundert;Ken
adr:;;101 First Street #150;Los Altos;CA;94022;USA
email;internet:ken@designers-guide.com
tel;work:+1-650-968-8291
x-mozilla-html:FALSE
url:http://www.designers-guide.com/home.html
version:2.1
end:vcard
Received on Thu Sep 7 14:14:25 2006

This archive was generated by hypermail 2.1.8 : Thu Sep 07 2006 - 14:14:28 PDT