2012年8月16日 星期四

install CentOS 6 from min installation to Desktop

1. boot from iso
2. minimal installization
3. yum groupinstall "Desktop"
4. yum groupinstall "X Window System"
5. yum groupinstall "Chinese Support"
6. vi /etc/inittab
    init 3 --> init 5
7. 

2012年8月5日 星期日

Laker: export layout with keeping the property of Mcells

In the main window

> File-> export -> stream
check 'Generate MCells to Prop No.' in the 'property' tab

> File -> import -> stream
check 'Generate MCell as Prop No.' in the 'property' tab


2012年7月29日 星期日

Win7 CD/DVD driver missing when installing

Mother Board: GA-X79-UD3
OS: Win7

Syndrome:
boot from DVD--> install program --> warning message "A required CD/DVD drive device driver is missing. If you..."

Valid solution for my case:
1. Boot from DVD
2. Don't install the system (BTW, you can't install your system in normal operation due to the mentioned warning message)
3. Choose 'repair your system' -> 'DOS mode' -> change drive to 'D' -> 'cd sources' --> execute the file 'setup.exe'
4. start installing in my case and everything goes well


2012年7月27日 星期五

Test HDD R/W speed in Linux

The most simple method to test HDD R/W speed in linux system

OS: Centos

> dd if=/dev/zero of=swapfile bs=1024 count=20480000
20480000+0 records in
20480000+0 records out
20971520000 bytes (21 GB) copied, 106.886 s, 196 MB/s

This hard disk should be with the spec of SATA II (3Gbps).

2012年7月21日 星期六

Linux: Pipe and xargs

I want to find certain files in a folder and its sub-folders, and then remove these files..

Here is the best solution I found.

find . | grep bak | xargs rm

or

find -iname "*.bak" | xargs rm

[Ref] http://blog.yam.com/ddy1280/article/13941218

2012年7月2日 星期一

Madedit crashed in Centos 6

After searching the internet, no one provides any solution for this issue.
Here is one solution.

OS: CentOS 6.3 x86_64

Syndrome:
installed by RPM
> madedit &
>> open new tab -> crashed and some message left in the terminal
'(core dumped) madedit'

Solution in 5 steps:
0. add additional lib for yum
> rpm -ivh ftp://ftp.cuhk.edu.hk/pub/linux/fedora-epel/6/x86_64/epel-release-6-8.noarch.rpm

1.
> yum install boost boost-devel   wxGTK wxGTK-devel gtk2-devel gcc-c++
(i686 version required)

2
>  cd   /usr/local/src/

> wget  http://downloads.sourceforge.net/project/madedit/MadEdit/MadEdit-0.2.9/madedit-0.2.9.tar.gz?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fmadedit%2Ffiles%2FMadEdit%2FMadEdit-0.2.9%2F&ts=1347185903&use_mirror=nchc


> tar -zxvf madedit-0.2.9.tar.gz

> cd   /usr/local/src/madedit-0.2.9/src/MadEdit
> vi MadEdit.cpp
//
Modify some content around line 9716
It may looks like the following text.
The red and underlined lines should be inserted.

-----------------------------------------------------------------------
//--- line 9716 ---///
void MadEdit::OnPaint(wxPaintEvent &evt)
{
    //--- add to avoid crash ---//
    if(m_ClientWidth==0 || m_ClientHeight==0) return;
    //--- end ---///


    wxPaintDC dc(this);
    wxMemoryDC memdc, markdc;

    wxWindow *focuswin=FindFocus();

    if(InPrinting())
-----------------------------------------------------------------------

3.
> cd  /usr/local/src/madedit-0.2.9
> ./configure
> make
> make install

4.
 Done

[Ref]  http://forum.ubuntu.org.cn/viewtopic.php?f=95&t=347254&start=15&sid=f4349b8a77616c9e3cda146aae2878e6&view=print
(you can also find the fixed deb package here. I didn't try this package yet.)



2012年6月10日 星期日

Probe in HSpice

1. plot the top level nodes

. option  POSTLVL= N
(N= 1--> top level, N=2--> only the second level)

or

.option POSTTOP

2.  the POSTTOP and POSTLVL options will be ignored if

.option PROBE

is also in the netlist.

[Ref]  http://www.designers-guide.org/Forum/YaBB.pl?num=1241031816