tag 标签: not

相关博文
  • 热度 24
    2014-3-10 11:17
    7851 次阅读|
    0 个评论
    在allegro环境下使用SKILL,必须要先载入后才能使用相关的命令,一种方式是直接在COMMAND窗口输入skill load("SKILL文件名")来载入,这种方法只针对当前开启的ALLEGRO才有效,另外一种方法是将载入语句写入PCBENV目录下的allegro.ilinit文件内来实现ALLEGRO启动时自动加载,这种是比较通用的方法,下面以此方法为例。 一,查看环境变量所在目录 1.通过查看电脑环境变量中的HOME变量值. 例如HOME变量为d:\ ,那实际的allegro.ilinit文件路径应该放在d:\pcbenv目录下 2.直接在ALLEGRO 命令行输入echo $localenv 也可以得到实际的环境变量目录。 在环境变量目录下如果没有allegro.ilinit文件,可以新建一个文本文件,然后修改文件名即可,allegro在启动时会在环境变量目录下查找allegro.ilinit文件,并执行其中的SKILL语句。可以把allegro.ilinit理解成一个ALLEGRO自动启动的SKILL文件。 二,allegro.ilinit文件的编写 大家经常见到的allegro.ilinit文件内容如下: 以下是代码片段: ;-------------------------------------------------------- setSkillPath(buildString(append1(getSkillPath() "D:/skill"))) load("xxx.il") ;--------------------------------------------------------   以上代码都是标准的SKILL语句,下面介绍所使用到的函数: getSkillPath() ;函数,作用是获取ALLEGRO的SKILL PATH列表,此列表所包含路径中的SKILL文件可直接使用相对路径调用。 append1 ;函数,在列表中添加内容,append1(getSkillPath() "D:/skill"))) 的作用就是将D:/SKILL这个目录添加进SKILL 路径里,这样只要123.il文件放在D:/skill目录下就可以直接使用load("123.il")来调用。 buildString ;将LIST类型组成字符串,此函数可以省略 setSkillPath ;函数,根据重新组成的路径设置SKILL PATH. load ;载入函数,如果SKILL带有密码,写法为load("xxx.il" "password");另外也可以使用loadi函数。 使用以上代码后,可以将SKILL文件放入指定文件夹以方便管理, 另外,因为PCBENV目录默认包括在SKILL PATH中,所以如果不使用上面语句,也可以将SKILL文件放入PCBENV目录下,使用相对路径调用 ,如load("test.il"); 如果在其它位置也可以使用绝对路径调用,例如load("d:/skill/test.il") 保存allegro.ilinit文件后, 在ALLEGRO命令行里执行skill load("allegro.ilinit") 所有加载的SKILL即可生效,当然也可以重开ALLEGRO. 三,在allegro.ilinit的中定义快捷键 使用axlSetAlias和axlSetFunckey函数 axlSetAlias("F2" "oops")
  • 热度 28
    2013-11-29 20:19
    1636 次阅读|
    0 个评论
    Hi! Long time no see! Life has been busy over the past few months... Students' lives are busy... should be busy... especially for engineering students... I got an out-of-order ethernet switch, the symptom is that the switch cannot be powered on - no LED lit up, no response at all...   Fig. The switch was Level-one's FSW-2421 From previous experiences of many LCD monitors, the capacitors in the power module are getting swollen easily after using for a few years. The capacitances of those capacitor will decrease significanly. Replacing the swollen capacitors may help the monitor to work again... But for this switch, the capacitors looked good. None of them was swollen. Anyway, I decided to test all the capacitors in the power module... to just have a try...   Fig. Inside the switch (Left: Power module, Right: Main module) The power module converts 100-240V a.c. to +3.3V @ 3A.   Fig. Using soldering iron to desolder the capacitors   Fig. The old capacitors looked good (from left: 25V470uF, 16V1000uF, 16V1000uF and 10V470uF)   Fig. The capacitances of the capacitors (from left: 25V470uF, 16V1000uF, 16V1000uF and 10V470uF) Aha! The 10V470uF capacitor had problem! (The capacitance had decreased greatly in percentage!) After replacing the capacitor, it was working again!! Fig. The switch could startup normall P.S. Intended for more durable (to have longer lifetime again), all the 4 capacitors were replaced. Actually there was one another 400V big capacitor, but was not considered...
  • 热度 21
    2013-4-27 12:29
    1432 次阅读|
    0 个评论
    Sometimes it is good to keep our development tools and utilities up-to-date, since updates may have the bugs fixed and have more functions. I just replaced my MDK4.6 with MDK4.7a (verson Mar 2013). Fig.1 MDK updated to 4.7a   Surprisingly, I was unable to download the firmware (to a STM32 MCU) with my ULINK2 anymore... The IDE went out of response during program download... Fig.2 A ULINK2 to download program   Fig.3 The IDE went out of response... download program failed On the other hand, the 'COM' LED keeped on... No further response for a long time... Fig.4 The COM LED seemed to be on forever To solve this problem, many people on the Internet could think of downloading older firmware versions to the ULINK2 through the UART port by opening the casing. Fig.5 Pins soldered for UART firmware download   I did not download the old firmware successfully, the LPC2000 flash utility was not working stably after trying for several times, using CP2102 as the USB to TTL interface. Probably the CP2102 had baud rate timing problems... I don't know...   At the end, I found that increasing the 'Max Clock' in the configuration would totally solve the problem!! The default "Max Clock" was 1MHz, if we plug the ULINK2 into the USB, then we can choose "10MHz" as the clock.   Fig.6 Choosing "Max Clock" to be 10MHz, after plugging in the ULINK2   Everything was working fine since then... however, old projects still have to be re-configured before downloading them again to MCUs...
相关资源