wildgoat的个人空间 https://blog.eetop.cn/wildgoat [收藏] [复制] [分享] [RSS]

空间首页 动态 记录 日志 相册 主题 分享 留言板 个人资料

日志

[ZZ] Export Simulation Data using ocnPrint()

已有 2320 次阅读| 2011-7-11 21:48 |个人分类:Cadence

Simulation data generated by a simulator integrated with the Cadence Analog Design Environment, raw or post-processed, can be printed to text files using the print or printvs command. But if the data size is very large, Cadence will suggest the ocnPrint command which can be executed from the CIW.

This is an OCEAN (Open Command Environment for Analysis) command with the following syntax (OCEAN Reference, Ch. 8):

ocnPrint( [?output t_filename | p_port] [?precision x_precision] [?numberNotation s_numberNotation] [?numSpaces x_numSpaces] [?width x_width] [?from x_from] [?to x_to] [?step x_step] o_waveform1 [o_waveform2 ...] ) => t/nil

Example:

1. ocnPrint(clip((v("/Vo" ?result "tran")) 5.4e-06 6.2e-06) ?output "./x.txt" ?precision 16 ?numberNotation 'none)

An ASCII file x.txt appeared in the current directory, containing the transient voltage of node Vo from 5.4u to 6.2u and the corresponding time vector, with the maximum precision of 16-digit.

The data can then be further processed in other tools. For example, I imported the data to MATLAB, applied amplitude clipping to the voltage and did an FFT. Before the FFT, Vo is interpolated into a constant time-step vector of the length 2^N. N is of course an integer:
tr = linspace(x(1,1),x(end,1),2^N);
xr = spline(x(:,1),x(:,2),tr);
Might not be very smart but is surely a great option.

2. ocnPrint( ?output "./myOutputFile" v("net1") ?from 0 ?to 0.5n ?step 0.1n ?numberNotation ’engineering ?precision 10)

That will print the voltage at "net1" to "./myOutputFile" starting from 0 to 0.5ns with steps of 0.1n with a 10 decimal points and an engineering notation.

点赞

评论 (0 个评论)

facelist

您需要登录后才可以评论 登录 | 注册

  • 关注TA
  • 加好友
  • 联系TA
  • 0

    周排名
  • 0

    月排名
  • 0

    总排名
  • 0

    关注
  • 122

    粉丝
  • 42

    好友
  • 272

    获赞
  • 118

    评论
  • 22104

    访问数
关闭

站长推荐 上一条 /1 下一条

小黑屋| 关于我们| 联系我们| 在线咨询| 隐私声明| EETOP 创芯网
( 京ICP备:10050787号 京公网安备:11010502037710 )

GMT+8, 2024-4-25 18:07 , Processed in 0.013505 second(s), 7 queries , Gzip On, Redis On.

eetop公众号 创芯大讲堂 创芯人才网
返回顶部