Go Back   Velocity Reviews > Newsgroups > VHDL
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

VHDL - Syntax help

 
Thread Tools Search this Thread
Old 11-15-2006, 01:08 PM   #1
Default Syntax help


What is the VHDL syntax to specify rise and fall time of the signal



atul.ee@gmail.com
  Reply With Quote
Old 11-15-2006, 02:30 PM   #2
Jonathan Bromley
 
Posts: n/a
Default Re: Syntax help

On 15 Nov 2006 05:08:35 -0800, wrote:

>What is the VHDL syntax to specify rise and fall time of the signal


There is none. Logic signals in VHDL have discrete values and
change instantaneously from one value to another. (Things are
a little more difficult for signals of type REAL, but let's skip
that issue for now.)

You can mimic some of the features of risetime by making
a signal go to 'X' for some time...

process
constant t_rise: time := 1 ns;
constant t_fall: time := 2 ns;
begin
sig <= '0';
wait for 10 ns;
sig <= 'X', '1' after t_rise;
wait for 10 ns;
sig <= 'X', '0' after t_fall;
...

But please NEVER do that with a clock signal!
--
Jonathan Bromley, Consultant

DOULOS - Developing Design Know-how
VHDL * Verilog * SystemC * e * Perl * Tcl/Tk * Project Services

Doulos Ltd., 22 Market Place, Ringwood, BH24 1AW, UK

http://www.MYCOMPANY.com

The contents of this message may contain personal views which
are not the views of Doulos Ltd., unless specifically stated.
  Reply With Quote
Old 11-16-2006, 04:21 AM   #3
atul.ee@gmail.com
 
Posts: n/a
Default Re: Syntax help


Jonathan Bromley wrote:
> On 15 Nov 2006 05:08:35 -0800, wrote:
>
> >What is the VHDL syntax to specify rise and fall time of the signal

>
> There is none. Logic signals in VHDL have discrete values and
> change instantaneously from one value to another. (Things are
> a little more difficult for signals of type REAL, but let's skip
> that issue for now.)
>
> You can mimic some of the features of risetime by making
> a signal go to 'X' for some time...
>
> process
> constant t_rise: time := 1 ns;
> constant t_fall: time := 2 ns;
> begin
> sig <= '0';
> wait for 10 ns;
> sig <= 'X', '1' after t_rise;
> wait for 10 ns;
> sig <= 'X', '0' after t_fall;
> ...
>
> But please NEVER do that with a clock signal!
> --
> Jonathan Bromley, Consultant
>
> DOULOS - Developing Design Know-how
> VHDL * Verilog * SystemC * e * Perl * Tcl/Tk * Project Services
>
> Doulos Ltd., 22 Market Place, Ringwood, BH24 1AW, UK
>
> http://www.MYCOMPANY.com
>
> The contents of this message may contain personal views which
> are not the views of Doulos Ltd., unless specifically stated.


Thanks, That was helpfull.
Atul

  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump