Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to simulate SPI interface in ADE?

Status
Not open for further replies.

walker5678

Full Member level 3
Joined
May 17, 2006
Messages
179
Helped
7
Reputation
14
Reaction score
3
Trophy points
1,298
Activity points
2,493
vpwl format

I am simulating a circuit with SPI interface in analog design environment.
There need DIN and DCLK singal input. I am using vpwl and vpulse to generate these signal, however if I want to simulate different clock frequency, i must remodify every parameters of the vpwl and vpulse source, which is very boring.
Anybody knows how to simulate such digital interface in ADE , or , is there any other better tools to simulate it?
Thanks a lot.
 

vpwl variable

walker5678 said:
... if I want to simulate different clock frequency, i must remodify every parameters of the vpwl and vpulse source, which is very boring.
Shouldn't it be possible to relate all parameters to a single parameter (clock frequency), then sweep this one?
 

vpwl support design variable

yes, i am also thinking that, but how to write the PWL file? What is the format of PWL file?
If I set a variable called frequency in the PWL file, i can use vpwlf source to generate the singal.
 

vpwlf variable

use the vpulse instead of the vpwlf and put your parameters in the delay, rise time, fall time pulse width and period boxes. For instance you can define:
dclk_freq=1e6, dclk_tp=1/dclk_freq, dclk_tr=1e-9, dclk_tf=1e-9, and dclk_tw=0.5*dclk_tp-dclk_tr.
Then you only need to change dclk_freq and your new clock is ready!
 

ade vpwlf format

However, for DCLK, between every 8 clocks there is a blanking time, which is also need to be adjust.

and DIN is not a pulse , but a constant logical level during one whole clock cycle.

Added after 1 hours 13 minutes:

anybody has an example pwl file , please kindly share. Thanks !
 

spi interface design

walker5678 said:
What is the format of PWL file?
walker5678 said:
anybody has an example pwl file , please kindly share. Thanks !
The format is: <time> <white space> <voltage>
i.e.:
<time0> <voltage0>
<time1> <voltage1>
............. ................

... however - at least in my setUp - variables in the vpwlf file are not supported. I used OS tools (Unix, Linux) to calculate the real values from the parameters.
Good luck! erikl
 

spi profile clock

If you use MMSIM 6.0 or higher version it is possible to set digital signals by means of digital vector file otherwise better to use ULTRASIM.
 

vpwl parameters

For the blanking time, you could use a second signal source and do a logical AND with DCLK.
 

walker5678 said:
hi, erikl:
thanks, it works.
BTW, you can use evalstring(desVar(\"vdd\")) to let pwl file support design variable. vdd is an example, it could be any variable name.
And thank you for your feedback, walker!
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top