Cadence Skill 论坛

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
12
返回列表 发新帖
楼主: sujuanyu888

[原创] 【求助】帮我看下附件的skill怎么用

[复制链接]
 楼主| 发表于 2016-5-3 22:12:41 | 显示全部楼层
只在原来的基础上面加一句的结果,如下图:  我用的是16.6,跟这个不知道有没有关系。以前是在16.3上用的。
无标题1.jpg
 楼主| 发表于 2016-5-3 22:13:17 | 显示全部楼层
谁能帮帮我啊,着急。不行只能一条一条的量,要崩溃的。
发表于 2016-5-4 22:51:30 | 显示全部楼层
sujuanyu888 发表于 2016-5-3 20:32
我这是手动加载的。自动加载到文件里,直接软件都打不开。手动加载我打的是:skill load ‘’length_report ...

不好意思!好像贴错了。
试试这个。
jdfw.gif


  1. /*
  2. *       Net Length Report For Allegro 14.2
  3. *                    
  4. *                          Allan Wu (2003/12/25)
  5. *
  6. *    1. Function Key F9 Define
  7. *    2. Set Select Filter CLINES
  8. */
  9. axlCmdRegister("Length_Report" 'Length_Report)
  10. procedure( Length_Report()
  11.         popup = axlUIPopupDefine(nil
  12.                 (list         (list "Done" `axlFinishEnterFun)
  13.                                 (list "Cancel" `axlcancelEnterFun)
  14.                 ))
  15.         axlUIPopupSet(popup)
  16.         (axlClearSelSet)
  17.         (axlSetFindFilter ?enabled  (list "noall" "clines" "nameform")
  18.                           ?onButtons  (list "noall" "clines"))
  19.         axlOpenFindFilter()
  20.         port = outfile("./lengthReport.txt")
  21.         ;port = axlDMOpenLog("lengthReport")
  22.         fprintf(port "        Net Length Report\n")
  23.         fprintf(port "                     Allan Wu (2003/12/25)\n")
  24.         fprintf(port "-----------------------------------------\n")
  25.         fprintf(port "-----------------------------------------\n")
  26.         axlDMClose(port)
  27.         logWindow = axlUIViewFileCreate("lengthReport.txt" "Net Length Report" nil)
  28.         (while (axlSelect)
  29.                 cpaths = axlGetSelSet()
  30.                 total = 0
  31.                 items = nil
  32.                 if((logWindow != nil) axlUIWClose(logWindow))
  33.                 logWindow = nil
  34.                 port = outfile("./lengthReport.txt")
  35.                 fprintf(port "        Net Length Report\n")
  36.                 fprintf(port "                     Allan Wu (2003/12/25)\n")
  37.                 fprintf(port "-----------------------------------------\n")
  38.                 foreach(path cpaths
  39.                         segments = path->segments
  40.                         pathlen = 0
  41.                         foreach(segment segments
  42.                                 box = segment->startEnd
  43.                                 lx = caar(box)
  44.                                 ly = cadar(box)
  45.                                 rx = caadr(box)
  46.                                 ry = cadadr(box)
  47.                                 pathlen = pathlen + sqrt( (lx-rx)**2+(ly-ry)**2 )
  48.                         )
  49.                         total = total + pathlen
  50.                         items = cons(list(path->net->name pathlen) items)
  51.                 )
  52.                 cpaths = sortcar(items nil)
  53.                 bknet = caar(cpaths)
  54.                 bklen = 0
  55.                 count = 1
  56.                 foreach( path cpaths
  57.                         if( (bknet==car(path))
  58.                                 then
  59.                                         bklen = bklen + cadr(path)
  60.                                 else
  61.                                         fprintf(port "%2d)\t%-15s\t%.3f\n" count bknet bklen)
  62.                                         count = count + 1
  63.                                         bknet = car(path)
  64.                                         bklen = cadr(path)
  65.                         )
  66.                 )
  67.                 fprintf(port "%2d)\t%-15s\t%.3f\n" count bknet bklen)
  68.                 fprintf(port "\nTotal length : %.3f\n" total)
  69.                 fprintf(port "-----------------------------------------\n")
  70.                 axlDMClose(port)
  71.                 if( (logWindow==nil)
  72.                         then
  73.                         logWindow = axlUIViewFileCreate("lengthReport.txt" "Net Length Report" nil)
  74.                         else
  75.                         (axlUIViewFileReuse logWindow "lengthReport.txt" "Net Length Report" nil)
  76.                 )
  77.         )
  78.         if((logWindow != nil) axlUIWClose(logWindow))
  79.         axlUIPopupSet(nil)        
  80. )
复制代码
发表于 2016-5-6 10:04:54 | 显示全部楼层
defir 所貼的 可以用了
发表于 2016-5-6 10:04:57 | 显示全部楼层
defir 所貼的 可以用了
 楼主| 发表于 2016-5-7 12:41:23 | 显示全部楼层
defir 发表于 2016-5-4 22:51
不好意思!好像贴错了。
试试这个。

可以用了,非常非常感谢
发表于 2018-12-10 10:14:48 | 显示全部楼层
本帖最后由 bingshuihuo 于 2018-12-12 09:56 编辑

我在菜单里面加载了  好像不能使用,奇怪
能帮忙看看为什么吗?

加载 load ("length_report.il" )  在allegro.ilinit 文件里面

命令菜单是  Length_Report

加载后还是提示  E- Command not found: Length_Report
last pick:  2385.3 4093.9

这个应该怎么解决
发表于 2018-12-10 10:20:19 | 显示全部楼层
本帖最后由 bingshuihuo 于 2018-12-11 08:22 编辑
vivianwu0317 发表于 2016-5-6 10:04
defir 所貼的 可以用了

这个你可以使用了吗  我这边还是使用不了  不知道哪里有问题  可以帮我看看吗
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|手机版|网站地图|Cadence Skill 论坛 ( 蜀ICP备13024417号 )

GMT+8, 2024-4-16 12:41 , Processed in 0.234825 second(s), 15 queries .

Powered by Discuz! X3.4

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表