星期五, 12月 31, 2004

公出備忘

Chad說要將passport copy下來,還有有VISA那一頁也要copy。
到華航網頁有過境旅館資料。

明天中午警衛是拿機票。
後天出發前找怡君拿過境旅館資料。

要寫sja1000 reset code instruction 請alice改。

公出紀錄: day-3 + 1

班機又改了:


American Express Travel DATE : 31 DEC 2004
5F.,363 Fu-Hsing North Road. PAGE : 01
Tel:02-2659 0481 ABACUS REF: LFJDIO
Fax:02-2659 0482

ITINERARY PREPARED FOR:
1 CHANG/CHIHYUAN MR
FLIGHT STOP/EQP/
CITY/TERMINAL/ CLASS FLYING TIME/
DAY DATE STOPOVER CITY TIME STATUS SERVICES
--- ---- -------------- ---- ------ ------------
TUE 04JAN DEP TAIPEI 1345 CI 32 NON-STOP
TERMINAL 1 ECONOMY BOEING 747 400
ARR VANCOUVER BC 0755 CONFIRMED 10HR 10MIN
MAIN TERMINAL MEALS
TUE 04JAN DEP VANCOUVER BC 1100 AC 8 NON-STOP
MAIN TERMINAL ECONOMY AIRBUS A340-30
ARR TORONTO ON 1823 CONFIRMED 04HR 23MIN
TERMINAL 1 MEALS
THU 06JAN DEP TORONTO ON 1700 AC 115 NON-STOP
TERMINAL 1 ECONOMY AIRBUS A320
ARR VANCOUVER BC 1916 CONFIRMED 05HR 16MIN
MAIN TERMINAL MEALS
FRI 07JAN DEP VANCOUVER BC 1000 CI 31 NON-STOP
MAIN TERMINAL ECONOMY BOEING 747 400
08JAN ARR TAIPEI 1445 CONFIRMED 12HR 45MIN
TERMINAL 1 MEALS
* * * * * * * * *
PLEASE RECONFIRM YOUR FLIGHT 72 HOURS BEFORE DEPARTURE
* * *
THANK YOU FOR CHOOSING AMERICAN EXPRESS TRAVEL SERVICE
AIRLINE CODE
CI-CHINA AIRLINES REF:K27XE2 AC-AIR CANADA REF:MH3VQE

1.PLEASE CHECK BOOKING NAME & PASSPORT NAME ARE MATCHED
2.PLEASE MAKE SURE YOU HAVE VALID PASSPORT (MAX.6 MONTH)
* * * * * * * * * * * * * *
PLEASE HYPERLINK //WWW.VIRTUALLYTHERE.COM TO RETRIEVE YOUR
UPDATED TRIP RECORD WITH ABACUS REF. NO, YOUR LAST NAME,THEN
TYPE IN PASSPORT "AMEX" TO VIEW YOUR ITINERARY

==============================================================

DPR Contact Info:

Ed Pack
  Mobile 919-349-8004

Don Trentlage
  Mobile 919-616-8111

Lezley Kennison
  Office 919-767-3828

Jessica Stansell
  Office 919-767-3860

新相簿喔。100M

http://checko.pixnet.net/

星期四, 12月 30, 2004

公出備忘

名片
電話
code ?
spec ?

公出紀錄:day -4

終於被發現,所有聯絡都還沒做,資料也都還沒準備好。
現在開始吩咐準備資料,
開始說明是要討論規格,
開始請人安排住宿接機。

星期三, 12月 29, 2004

gedit 2.9.3 install

./configure
=====================================================
出現:
checking for XML::Parser... configure: error: XML::Parser perl module is required for intltool
到google 找mailinglist有說明,用以下指令install Perl的XML::Parser Module

su -
(need to be root)

perl -MCPAN -e shell
(would run CPAN module of Perl)

install XML::Parser
(would install XML::Parser and all of its dependencies)

then you can continue building Garnome

所以follow instruction,su install XML::Parser
進入Perl的shell,第一個問題是Perl的configure問題,因為不知道要怎麼設,所以回答No,讓他自動configure,之後Perl開始自動download source。
Perl先用lynx --source 來download source,但是很奇怪,很慢(或是根本不會動),所以用^-C中斷。
Perl會自動用ncftpd來download,這個就比較快。
Perl會download很多source,依樣,用^-C來中斷lynx,讓他用ncftp來download。
都download完後開始build,install,XML::Parser install OK。
===================================
繼續,回到gedit-2.9.3下作./configure
出現
*** The pkg-config script could not be found. Make sure it is
*** in your path, or set the PKG_CONFIG environment variable
*** to the full path to pkg-config.
*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config.
configure: error: Library requirements (glib-2.0 >= 2.6.0 gtk+-2.0 >= 2.6.0 gtksourceview-1.0 >= 1.1.1 libgnomeui-2.0 >= 2.6.0 libglade-2.0 >= 2.4.0 eel-2.0 >= 2.6.0 libgnomeprintui-2.2 >= 2.6.0) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.

所以去download pkg-condfig: pkgconfig-0.15.0
./configure
make
su
make install

OK,回去gedit config

pkg-config ok,但是還是說找不到glib2.0 ....... giveup

星期二, 12月 28, 2004

this post was createed by opera

中文OK?

Zaurus install Opera

安裝Opera 7.55
su 輸入

ln -s /opt/QtPalmtop/opera /usr/share/opera
chown -R zaurus /home/zaurus/.opera

星期一, 12月 27, 2004

Zaurus C700 SWAP ON, abcom ethernet card & Kmerlin

將Abcom的CF ethernet card: CEF100 插入。
編輯網路,ethernet,設定abcomoffice profile,固定ip,gateway,dns,勾自動。
和WLAN依樣,選netowrk icon,連線,OK。
ifconfig , ping ok,netfront ok

=====================================

follow czh in PIL's post and rakline's modification
插入SD card (256 PKI)

swapoff /mnt/card/swap //以防舊的設定swap有動作
umount /dev/mmcda1
mkfs.ext2 /dev/mmcda1
mount -t exte /dev/mmcda1 /mnt/card
dd if=/dev/zerp of=/mnt/card/swap bz=1k count=32768
mkswap /mnt/card/swap
swapon /mnt/card/swap

check一下/etc/cardcontrol:
開頭.
FATOPTS="-o noatime,quiet,umask=000,iocharset=utf8"
EXT2OPTS="-0 rw,noatime"

check insert要有swapon /mnt/card/swap
check ejext錢要有swapoff /mnt/card/swap

用free check OK

====================================

KMerlin

download openssl
download Kmerline

用新增/移除程式 安裝
openssl 安裝在本體
Kmerline安裝在SD

=====================================

SD的所有directory attr都是rwxr_xr_x,所以一班的application都不能access SD。
所以將所有目錄都chmod為777




修車

因為一早要去看Winter的daughter,所以開車,但是手煞的登一直亮著,
只好和爸換車。

到林叔叔那裡,登已經滅了。
也查不出什麼問題,只有找到找到煞車由太少,
所以

Install IBM HPA in another HD

Follow TP User Groupe的指示,將原廠HD的HPA backup下來(5 CD),
今天換一顆10 G的HD上去,試試能否安裝HPA。

換HD,裝入當初backup的第一片CD。

開機,F1進入BIOS,選boot from CD
C:\cd a:A:\FWRESTORE FILE=X:\HPAR40e (我當初backup的filename)
開始restore:一片約需15min。
一片copy完後,會提醒放入下一片。
5片都完後會自動停止。

因為舊的partirion table沒有修正(erase),所以partition是舊的。
(應該現在就用A:\的fdisk刪除)

第二天

開機,按下AccessIBM,已經會進入IBM的tool menu。
將HPA由normal改為secure。

放入RescueCD,開機用fdisk /dev/hda將所有partition刪除。creater一個Win95 FAT32,bootable partition。

restart,按下AccessIBM。
選restore to factory

prompt 版權與說明hd上data都會被erase,press Y。
prompt hd的partition table有問題,詢問要不要修正。press Y。

OK,開始copy HPA的system data到boot partition,約需1 Hr。
重新開機。
開始解開data,進入XP boot screen。
開始安裝custom package。
重新啟動。
安裝ibm的軟體。
啟動。
轉換FAT32到NTFS。
-----以上都是自動。

開始設定,keyboard layout,time zone,machine name,network,username。

開啟IE,download firefox。

OK
===========================
HPA 1 hr
resotr and setup 2 hr



星期五, 12月 24, 2004

Code Review

Review的Code要加說明(comment)
  1. 設計時要以功能為歸類。Code將完成同一功能的function放在一起,針對這些function要完成的功能寫comment。不一定美一個function都要寫comment。
  2. 一個C file的檔頭要描述這個source code file中implement的功能。
  3. 使用隱含的資料方法或Magic Number要說明原因。
  4. 複雜的資料結構,要說明結構的內容。


Go Seeing Winter's Daughter

金山南路跟信義路
不要從信義路轉喔...那裡在做捷運
康合
車可以停金山南路or愛國東路
Stanley 0982-123-536
11:00
帶照片,達文西密碼。

record some sites..

cnxp
註冊了,用o註冊,yahoo

星期三, 12月 22, 2004

Realone: install and uninstall

因為裝錯了檢體版的RealOnePlayer,導致無法開啟,也無法uninstall。
重裝一次英文版的也無效。

所以只好用regedit將所有realone刪除。
將folder刪除。
重裝一次英文版。

可以正常開啟了。
===============================
有些檔不能開的原因:
結果是缺了RealOneWithAAC

Gmail的invitation又來了

又有4個,上一次有2個沒用,總共有6個。
一個給姊
一個給WanWe
一個給Chris
===================
剛給完又有6個,這下不知道要給誰。

慘了,這下一定要去了。

Invitation letter也給了。
這下真的要去了。

星期二, 12月 21, 2004

ddd & m68k-elf-gdb

要執行ddd需要lesstif。
lesstif的安裝
./configure
make
su
make install

接著安裝ddd
./configure
make
su
make install

執行ddd時,要將lesstif的share library path加入
export LD_SHARED_LIB=$LD_SHARE_LIB:/usr/local/lib

窮人的習慣

我在小蘋果看到的,轉貼一下,以為警惕:
========================================
網友HiR所貼的,我轉過來是覺得內容含意很深啊!


有個故事,說的是一個窮人,很窮,一個富人見他可憐,就起了善心,
想幫他致富。富人送給他一頭牛,囑他好好開荒,等春天來了撒上種子
,秋天就可以遠離那個“窮”字了。

窮人滿懷希望開始奮鬥。可是沒過幾天,牛要吃草,人要吃飯,日子比
過去還難。窮人就想,不如把牛賣了,買幾只羊,先殺一只吃,剩下的
還可以生小羊,長大了拿去賣,可以賺更多的錢。

窮人的計劃如願以償,只是吃了一只羊之後,小羊遲遲沒有生下來,日
子又艱難了,忍不住又吃了一只。窮人想:這樣下去不得了,不如把羊
賣了,買成雞,雞生蛋的速度要快一些,雞蛋立刻可以賺錢,日子立刻
可以好轉。

窮人的計劃又如願以償了,但是日子並沒有改變,又艱難了,又忍不住
殺雞,終於殺到只剩一只雞時,窮人的理想徹底崩潰。他想:致富是無
望了,還不如把雞賣了,打一壺酒,三杯下肚,萬事不愁。

很快春天來了,發善心的富人興致勃勃送種子來,竟然發現窮人正就著
咸菜喝酒,牛早就沒有了,房子裡依然一貧如洗。

富人轉身走了。窮人仍然一直窮著。

很多窮人都有過夢想,甚至有過機遇,有過行動,但要堅持到底卻很難


據一個投資家說,他的成功秘訣就是:沒錢時,不管再困難,也不要動
用投資和積蓄,壓力會使你找到賺錢的新方法,幫你還清賬單。這是個
好習慣。

星期日, 12月 19, 2004

todos...

1.install j2se in ubutntu.
2.install ndiswrapper for wireless card.

這裡有一篇說明好像蠻簡單的,包含使用ndiswrapper + wlan 設定
1. Place the CD containing the Windows driver.
2. Navigate to the directory containing the INF file.
3. Issue the command ndiswrapper -i yourdriver.INF followed by ndiswrapper -m.
4. Edit /etc/network/interfaces using your favorite text editor and add the appropriate following lines:

For DHCP networks -

auto wlan0
iface wlan0 inet dhcp
wireless_essid yourrouterssid

(Replace the ssid above with your network setting)

For Static networks -

auto wlan0
iface wlan0 inet static
wireless_essid yourrouterssid
address 192.168.0.2
netmask 255.255.255.0
broadcast 192.168.0.255
gateway 192.168.0.1

(Replace the numbers and ssid above with your network settings)

7. Reboot/
Moto 這一篇則很清楚的說明,從download ndiswrapper 到install , configure ..

some meeting notes...

在整理包包時發現一張以前在開會時作的紀錄,不知道是甚麼時候寫的`,現在看起來還滿有趣的:
======================================================================
低廉的勞工價格--->低廉的生產品質
如果找的是日本的零件供應商?
如何在人員流動率高的產線維持一定的生產水準`?
如果由工程師擔任生產的工作?
程序問題(會議)
新技術,新零件所需時間較長
試產期間本來就會有錯,找出錯誤就是試產的目的
目前的schedule安排,進入QE測試階段,工程師就被安排到其他專案,結果導致工程師要同時解決前一個專案的問題和目前首上專的進度。
誰負責guildeline的內容?
checklist終於又出現了!
提出要文件的人總是說的多`動的少。都不是要產生文件的人。能力:經驗有累積?
========================================================

星期五, 12月 17, 2004

xlivecd - a free X server for Windows

這個很不錯,他是用Cygwin寫的X Server,所以可以用ssh執行X Client program。
而且很好新的把所有需要的程式合在一起,作成iso檔,燒成cd後autorun就可以執行。
ssh到linux上後就可以執行任何程式,包括X的程式。

如果想要有Destop managemer的話,像Redhat9.0以上,Debian,ubuntu都有nautilus,ssh後執行nautilus就可以。

很不錯。

星期三, 12月 15, 2004

muffie's law

真是莫非定律,三年前留下的bug,

星期二, 12月 14, 2004

飛驒山脈旅遊

9-13號參加雄獅的飛驒旅遊

星期三, 12月 08, 2004

chang totem-gstrem to totem-xine

Follow OSNEWA2的review,uninstall totem-gstream,install totem-xine。
then.. everything is fine.

立體的月曆

可以自己作喔

我的天哪,全世界的ThinkPad使用著都要降半旗..

悲慘的是ThinkPad的日本設計團隊沒有被併過去。
....將來有可能會出現ThinkPad中古機升值的情況。

pda手機新應用

Sina News:
====================
......................
因為有PDA手機內建無線網路,還可以插卡,把改裝的迷你雷射掃描器插上,就可以像那三名東歐人,在莊家放輪盤球時計算球速,把資料傳給同夥的電腦,即時估算機率,在輪盤停止前通知可能落點下注,
......................
=====================

星期二, 12月 07, 2004

ubuntu knows A40..

果然有人性多了,插上A40,就像在windows一樣樣跳出import dialog,問我要save的folder....

A Weird thing: Cannot browse www.uclinux.org with user:uclinux

So strange, when I was uclinux (username, I cannot connect to www.uclinux.org).
neither firefox nor lynx.
So weird, is the reason username ?
don't know, I should try adding another user with same (limited) privilege).

我在兩台電腦上試都依樣,只要login的username試uclinux,都不能連到www.uclinux.org。

這還真是奇怪,不過連到uclinux.com和其他siteaddress中有uclinux字樣的都OK。

我新create 一個user : uclinux1,就可以。

所以,
大概真的是username的原因。


這個如果是真的就好了

分子收穫Water's 氫 2004 年12月6 日 導致乾淨的+能的鑰匙發現一個non-polluting 方法從它的最豐富的來源提取純淨的氫-- 水。 研究員工作數十年開發使成為可能使用能量從陽光從水提取氫的催化劑。這些材料吸收能量從光子為了加速電子與氫結合在水分子裡分裂水成氫和氧氣的率。 這樣催化劑由半導體材料共同地被做被用於做電腦芯片。研究員工作發現可能從sunlight's 光譜的一個更加了不起的部份提取能量和使用能量更加高效率地移動電子的催化劑。 弗吉尼亞工藝學校和州立大學研究員開發了一個大分子, 或supramolecular 複合體, 結合亞單位吸收光以亞單位接受電子。 複合體能被使用生產氫為乾淨燃燒的燃燒引擎和燃料細胞。 它為人所知幾年來, 分子包含金屬釕吸收太陽光井, 能導致足夠的能量執行氫生產。絆腳石對生產這樣分子得到光引起二個或更多電子一次, 必需引起足夠的能量分裂水。 researchers' 分子有光吸收的釕亞單位在各個末端, 連接器亞單位在中部附近和一個易反應的銠亞單位在收集電子和搭載他們對水的中心。 圖在怎樣之外設計, 準備和使用supramolecular 複合體能使用光收集電子採取了更多比十年工作, 根據研究員。 研究員提出了研究在228th 美國化工社會全國會議上被召開在費城在2004 年8月22 日至26 日。

看到隱藏檔的mount方法: unhide option

這是在unofficial ubuntu installtion guide看到的。
不過應該屬於一般linux使用。
在man mount可也以找到,就是在mount時加unhide選項。

mount -t iso9660 -o unhide /dev/hdc /media/cdrom0

星期一, 12月 06, 2004

ubuntu multimedia : follow the instruction.

不 知道這個kernel的gcc vresion是多少。
google: ubuntu gcc 出現這個

因為會順便安裝developemnt tools,所以follow這個link。

automake1.8 : automake-dev
libtool : gcc, gcc 3.3
gcc-doc : gcc-doc 3.3
g++ : g++ -3.3, libstdc++ 5-3.3-dev
x-windows-system-dev : libdps-dev, libdps1-dbg, libice-dev,libice6-dbg,libsm-dev,libsm6-dbg,libx11-6-dbg, x......
libgtk1.2-dev: libglib1.2, libglib1.2-dev,libgtk1.2,libgtk1.2-common
libpng-dev : 沒有這一個,所以follow libpng,安裝libpng10-dev, libpng12-dev
其中一個copy skin到defult的command是錯的,應該是
cp -r Blue /usr/local/share/mplayer/Skin/default

command line run mplayer O但是可魯還不能play

follow接下來的instruction,加入
deb ftp://ftp.nerim.net/debian-marillat/ unstable main
Reload
intall libdvdcss2

但是建立symbolic link的動作沒作
ln -s /media/cdrom0 /dev/dvd
因為/media/cdrom0已經存在,而且link到/dev/cdrom

可魯不能撥的原因cdrom的關係,把dat檔co下來後就可以撥了。

Novell Linux Desktop Review

Review李有一些screenshot,
好像沒什麼特殊的,和ubuntu差不多,
因為都是用gnome2.8,Evolution。

Review也說沒什麼必要性。
因為ubuntu,Suse都有。
不知道友什麼特殊的地方。

Not bad Open source programmer's Editor (Win32) : Notepad++

好像艇不錯的,Ultra Editor功能好像都有。
可惜沒有XWindow的版本

試用了一下,應該紙適合單一檔案的編輯,沒有project的觀念。

Free Classic mp3 download

http://cocoa.itc.it:8080/cocoakaradar/SrvInit

這是從這裡看到的,有完整說明。

好像真的正能用IE

要註冊,login,選一個自己喜歡曲目。
加上title名稱,就可以下載。

聽說會問一個問題,不過google一下就可以。

這個還真誇張,最大入口'網站還這樣搞..

Sina.cn竟然在自己的網頁加上病毒。
讓進入的人中毒。

這個有趣:SAM,SKYPE的電話錄音機'

裝上這個軟體SKYPE就有電話流言功能。
可以把流言save成WAVE檔。

星期日, 12月 05, 2004

powerbook G3: wallstreet.. OS9

今天把wallstreet裝上OSX 10.1 因為OS9沒有酷音可以用。
一切都很順利,當初螢幕一睡不起的毛病也沒有發生`。
可是firefox竟然要從10.1.x開始支援起,也就是說10.1是孤兒。
比OS 9還慘。OS 9還有wacom版的OS 9 mozilla可以用。所以,只好再試試10.2版。

結果:一樣`,螢幕一睡不起的問題又再出現。
所以,只得灌回10.1,這下跟傳染病依樣,10.1的螢幕竟然也有問題`。

最後,一切就當沒發生過,裝回OS 9,wallstreet就單純當上網用`,不作編輯。

星期六, 12月 04, 2004

MSN也出blog了

http://spaces.msn.com/
這是從這裡看到的,
我也港快去註冊ok
這裡

星期五, 12月 03, 2004

行程

航班
團體名稱 04JPD09CIB 紅色識別證

集合時間 12/09 下午2:25 中正機場 第一航站 華航櫃台
機場電話 03-3982454

12/09 中華航空 CI150 中正機場 16:25 名古屋 12/09 19:55
12/13 中華航空 CI151 名古屋 09:30 中正機場 12/13 11:50

旅館
12/09 名古屋 名古屋榮東急INN/名古屋市中區榮3-1-8 TEL:002-81-52-2510109
12/10 高松 高山ASSOCIA RESORT/歧阜縣高山市越後町1134 TEL:0577-36-0001
12/11 山梨縣 YATSUGADAKE ROYAL HOTEL/山梨縣北杜市大泉町西井出8240-1039 TEL:0551-38-4455
12/12 名古屋 名古屋榮東急INN/名古屋市中區榮3-1-8 TEL:002-81-52-2510109

備註
台北機場送機人員 0921-809-206
緊急聯絡電話 0932-365-795

another x86 emulator: Xen

http://www.cl.cam.ac.uk/Research/SRG/netos/xen/index.html

讓lcd更清楚-- ubuntu

在字型,可以設定 描繪字型 選 次像素
這樣在lcd上的自會比較好看

Samba Printing OK!

選列表,新增印表機,
tpbu-npd-server
hp8000
(以上兩項到server去看)。

username 寫tw的login name
password也要寫tw的password

OK

星期四, 12月 02, 2004

終於可以輸入中文了

終於可以輸入中文了,
不知道是什麼原因`我follow moto討論區的說明, 設定好Xsession.d.
其實光是要follow就很困難,因為他寫錯,還寫錯兩個地方.
還有他改的檔案和"無痛起步"寫的不一樣.
---我最後follow moto討論區.

總算將內容弄正確後,還是不行.

最後只好到xcin的網站去看看

他有寫到XMODIFIERS="@im=xcin"其實要依據LANG的設定而有不同,
雖然我follow moto和無痛起步的內容,到處設定LANG變數。
奇怪的是
用locale看,總是不會是我設定的。

我設定 LANG="zh_TW.Big5"
結果是 LANG="zh_TW"

LANG一定會被改成zh_TW,而不是我要設的zh_TW.Big5。

剛好從xcin網站文件看到,當LANG=zh_TW時,
XMODIFIER="@im=xcin-zh_TW"

xcin網佔:

apt-get install xcin xfonts-intl-chinese

在目錄 /etc/X11/Xsession.d 建立 95xinput :

case "$LANG" in
zh_TW)
/usr/bin/xcin &
XMODIFIERS="@im=xcin-zh_TW"
;;
zh_TW.Big5)
/usr/bin/xcin &
XMODIFIERS="@im=xcin"
;;
zh_TW.*)
/usr/bin/xcin &
XMODIFIERS="@im=xcin-zh_TW"
;;
esac

export XMODIFIERS
Admin
67890

神準的星僑孔明神數

這一篇看到的,他說的很好笑。

莫歎事遲留,休言不到頭;長竿終人手,一釣上金釣。

ubuntu : Chinese Fonts

xfonts-intl-chinese 這個字型找不到,所以到ubutu的synaptic package manager的”設定”--”套件庫”,將CDROM後面三個location都enable (實際上會是uncomment掉/etc/apt/sourcelist的對應行),Reload,就找的到了。

ttf-arphic-bsmi00lp和ttf-arphic-bkai00mp 原來就已經安裝。

Ubuntu : 中文 顯示

follow 無痛起步,修改 /etc/locale.gen,加入
zh_TW BIG5
再 執行
# locale-gen
就看到zh_TW.BIG5... done

當初不行的原因是locale.gen加入的那一行沒加LFCR (Enter鍵)。


logout後重新login,下面的language就多了Chinese可以選。
進入後所有訊息就都是中文的了。

星期二, 11月 30, 2004

R40e ubuntu install ok

because ACPI may hang R40e, so boot with :
boot: linux no acpi.
then.... follow the installation.
Be attention on: the partition tool seems can see the HPA,
so use partition tools by yourself, don't use "erase all" button.

The eth card driver installed successfully.
The X start successfully.

....this post was created in R40e ubuntu.

星期一, 11月 29, 2004

ubutu install ..

安裝時選繁體中文,1stage安裝結束,reboot後,顯示的都是亂碼。
花2 hrs安裝後,還是出現亂碼。

重新來,改用english安裝。
又失敗,選的解析度太高,Virtual PC不支援。

重新來,改選800x600,640x480。
發現他沒有root帳號,要由一般user sudo轉為root。
還是一樣,出現解析度太高。
啟動進入recovery mode,找不到設解析度的地方。

重新來。

星期日, 11月 28, 2004

steps to install linux on R40e

有三種方法:
1.用Debian
2.用kannopix
3.用ubutu (?)

要注意:
broadcom的ethernet driver

先download image
try boot.

星期五, 11月 26, 2004

install linux on R40e

出乎意料的,R40e還蠻有名的(因為他的便宜)
所以安裝Linux的 資料也蠻多的(但是沒有一個是完全成功的)

還好沒有Sarge的範例。

星期四, 11月 25, 2004

linux上的新注音:酷音輸入法

http://chewing.good-man.org/

跟windows的新注音依樣,不用選字,
可惜中英切換友一點不方便,不一樣。
聽說好像跟自然輸入法比較接近。

不前已經知道輸入標點符號直接用shift。
但是不知道輸入大寫的英文要怎麼作.

星期日, 11月 21, 2004

IBM R40e

power on, press "Access IBM" choose Recover Factory"
wait for bootimng complete, press F3, get in prompt.

put any usb device in nb, the boot os (guess is 98) cannot see it.
the boot os cannot see ntfs partition,too.

use rescueCD, boot into linux, run qtparted.
thrink the ntfs partition, reserve 7G.

reboot system, get in system management, disk management.
add new logical disk. format as FAT32 (wait about 3 min for formating complete).

OK, now we got a new FAT partition, which can be see by XP and IBMBoot.

reboot, press AccessIBM, restore Factory Set, press F3, get in command mode.

Goto C:

Yes! can see the partition !!
md HPS, will put every backup here.

the IBM boot:

A: boot
C: my FAT
D: IBM HPA

the boot

星期四, 11月 18, 2004

IBM r40e typing test

嗯,這個試試,中文注音的話,雖然鍵盤是full size,也很有處感,但是注音是紅色,所以不太(應該是很)不清楚。
電力的話,8:00開始,加上無線望卡,中間修棉1 hr ? 還是half hour,
之後又去洗澡,修棉。
一開始放了15 min的DVD。
現在是10:30,還有28%,竟然說還有40 min?
應該是不可能。
10:36 ,還有24%,剩下36 min。
10:50, 還有15%,剩下20 min。
10:58,還有9%,剩下13 min。
今天收到南桃園的mail

星期六, 11月 13, 2004

Developementg Tools for Mac OS9

最近把不會動的wallstreet重灌OS9,竟然正常動作,開啟mozilla也不錯,反應也比OS X快的多,想想還是用OS9好了。

可惜application很少,想想,是不是有機會自己寫?

這個網站是Apple release的developement tools似乎是free的

星期五, 11月 12, 2004

try with os9

這一篇是用powerbook wallstreet OS9打的
看看可不可已用

Subvision

星期三, 11月 10, 2004

買蛋糕

家樂
後站,新中北路,近中原大學。

波士頓派
奶油
one size

+1

立委資訊

太率了,

koders : Source code search engine

http://www.koders.com/
source code的搜尋引擎。
輸入你要找的function 類型。

星期日, 11月 07, 2004

星期五, 11月 05, 2004

是機車 但還是不能停「機車位」喔!

這是從schee.info : http://blog.schee.info/archives/2004/11/04/e_aeeaeeaeaeaie.html" 看到的,原文(照co)如下,comment野蠻好笑的..

是機車 但還是不能停「機車位」喔!

半年前的一則真實趣聞。

北市和平西路和和羅斯福路口,泰一電器方向側,有兩塊退縮的機車停車位。北市交通局不知在什麼時候,在原本機車停車的號誌旁,加設了一個英文的標誌,上面寫著「Motorcycle Only」。我們可以合理的推論,這是要給老外看的,對不?

這下好了,那天我遇到一個老外,害我解釋的要死。他騎了一台 CB400 就準備停在那裡。所以下面就是我和他的對話(中譯版):

我(Schee):老兄,你車不可以停這裡喔!

老兄:喔?那個牌子不是寫 "Motorcycle Only" 嗎?那我可以停啊?

我:老兄,其實這位子是給速客達(scooter)和小排氣輛車子停的,你沒看到停在 "Motorcycle Only" 的車全部是 scooter 嗎(我竊笑著)?

老兄:那這個牌子寫 "motorcycle only" 是寫假的喔?台北市怎麼會這樣?你可以跟我說我可以停哪裡呢?

我:你可以去停一般的停車場,不過我還是陪你去好了,免得你被檔在外面。

老兄:為什麼?

我:Urhh... 台灣是一個奇怪的國家,你先別問這麼多。這是我的名片。過去一點就有位子,我帶你過去。

老兄:好吧。真搞不懂那個牌子是幹什麼的...

基本上負責(or been involved)在執行這個業務的人,是無知的。台灣交通政策有不少自打自嘴巴的地方,這是其中的一個。

機車停駐收費並不是不可以討論,而是單方想當然爾的直接「實施 (implementation)」,基本上就是偷懶、不健全,而且長期有害民主的決策過程。

後記:我每次看到那個 "Motorcycle Only" 就忍不住想笑又想哭

晚一點來討論一下,這張「Motorcycle Only」的牌子讓老外敬佩莫名的奧義玄機。:p

Comments

他可能原本想寫:「Motorcycle Orz」....

不好笑~

不過機車騎士在台灣真的沒啥基本權利,
沒專用道就算了. . 停車格更少. . .
可憐~ 希望哪天捷運能涵蓋全台北市. .
這樣我也不想騎機車了...

Posted by: brian at November 4, 2004 03:03 PM


星期五, 10月 29, 2004

TODOS - today (next MONDAY)

要作的事:
    How to implement : 放電曲線紀錄
    check if 5 weeks (modifying KPN) developement can be reduce . (Midas think it's too long).

Linux Signal List

Linux Signals are:
Signal Name Number Description
SIGHUP 1 Hangup (POSIX)
SIGINT 2 Terminal interrupt (ANSI)
SIGQUIT 3 Terminal quit (POSIX)
SIGILL 4 Illegal instruction (ANSI)
SIGTRAP 5 Trace trap (POSIX)
SIGIOT 6 IOT Trap (4.2 BSD)
SIGBUS 7 BUS error (4.2 BSD)
SIGFPE 8 Floating point exception (ANSI)
SIGKILL 9 Kill(can't be caught or ignored) (POSIX)
SIGUSR1 10 User defined signal 1 (POSIX)
SIGSEGV 11 Invalid memory segment access (ANSI)
SIGUSR2 12 User defined signal 2 (POSIX)
SIGPIPE 13 Write on a pipe with no reader, Broken pipe (POSIX)
SIGALRM 14 Alarm clock (POSIX)
SIGTERM 15 Termination (ANSI)
SIGSTKFLT 16 Stack fault
SIGCHLD 17 Child process has stopped or exited, changed (POSIX)
SIGCONT 18 Continue executing, if stopped (POSIX)
SIGSTOP 19 Stop executing(can't be caught or ignored) (POSIX)
SIGTSTP 20 Terminal stop signal (POSIX)
SIGTTIN 21 Background process trying to read, from TTY (POSIX)
SIGTTOU 22 Background process trying to write, to TTY (POSIX)
SIGURG 23 Urgent condition on socket (4.2 BSD)
SIGXCPU 24 CPU limit exceeded (4.2 BSD)
SIGXFSZ 25 File size limit exceeded (4.2 BSD)
SIGVTALRM 26 Virtual alarm clock (4.2 BSD)
SIGPROF 27 Profiling alarm clock (4.2 BSD)
SIGWINCH 28 Window size change (4.3 BSD, Sun)
SIGIO 29 I/O now possible (4.2 BSD)
SIGPWR 30 Power failure restart (System V)

星期三, 10月 27, 2004

Try Different Fonts

Try Different Fonts:
Times
Courier
Ariel
Book Antiqua
Fixedsys

MEMO .. todos these days..

  1. 11/7號前要買刮鬍刀
  2. 11/2前要付保險費
  3. 要去看餐廳,姊說約6桌

try nvu

#include <try.gt>

gfun()
{
    try sourcecode;
    if( a==0){
       dsds;
    }
}

好像不用加 <br>
每個return後都會自動加。

原來tab是&bsp

星期日, 10月 24, 2004

態度差的TESCO Giodano sales

今天到中壢TESCO,去Giodano,要改褲子。
結果小姐一臉臭臉,態度超差的,
大概是因為當初不是跟他買的吧。
他收了褲子後,臭著一張臉說:
大概要20幾分鐘吧,現在沒空幫你改。
(可是當時一個客人也沒有呀)

也沒關係,去逛了一個小時後,
他好像正在改。
就在他店裡逛的一下,
他一邊改,以為我們是新客人,
馬上起身,態度極好多招乎,
但是一看到是我們,馬上就變了臉,
把改好的褲子丟出來,馬上作回味子上,
正眼都沒看我們一眼。

真差,這應該是7年級生吧。

typhone..again


又來一個,不用上班喔。

星期五, 10月 22, 2004

TODOS - today

Tinylogin - still don't work - progress: utmp cannot create.
Hydroff - deadline : Monday
Plone - try , is it usable ?

Plone試用..

Install在win2k上。
安裝和第一次啟動很快。幾乎不用什麼大腦。馬上就可以運作。

實際使用後:

內容分成Document和File。
Document的格式有plain text,Structur Text,reStructure Text。
File : 就是除Document外的其他file,提供upload。
Send mail功能不能使用,也就是說。。Plone不含smtp agent.
內容不能存成local檔。print command都會印出到printer上。

blog tools

movable type : perl
wordpress : php
Plone : Zope(Python) ?

星期三, 10月 20, 2004

星期四, 10月 14, 2004

Password was cracked by Virus - mutation of Lovegate

所以從今天起,把password改為原password到過來拼。

星期三, 10月 13, 2004

Cannot make menuconfig on Debian.. lack of ncurses

在Debian stable上不能make menuconfig.
....缺ncurses,可是查installed package卻還有libncurses5.so

google:好像是要裝ncurses developement library,這個和ncurses library不一樣。
libncurses-dev
libncurses5-dev
之類的

Aptitude中屬於 Vitrual Package
(這是在Debian unstable 找的: /libncurses-dev)

Furl

紀錄下google到的東西。。。
...已經註冊

Floppy Linux with GRUB

1.安裝(grub)


一般Floppy Linux都使用syslinux(不支援ext2,只能用fat),經過測試grub只用了132KB,並不大。

# mke2fs /dev/fd0
# mount /dev/fd0 /mnt/floppy

將grub需要的設定檔copy到floppy

# mkdir /mnt/floppy/boot
# mkdir /mnt/floppy/boot/grub
# cp /boot/grub/stage1 /mnt/floppy/boot/grub
# cp /boot/grub/stage2 /mnt/floppy/boot/grub

先su -成root,執行grub

grub> root (fd0)
grub> setup (fd0)
grub> quit

grub安裝完成

2. 安裝Rootfs

Rootfs要包含:

/bin /etc /proc /tmp /var /dev /mnt

dev下要有:

/dev/console /dev/fd0 /dev/null /dev/ram0 /dev/tty /dev/tty0

etc下要有:

/etc/rc.d/inittab /etc/rc.d/rc.sysinit /etc/fstab

bin下要有一些基本工具:

如:sh,ls,cd,cat……

一般使用busybox

(1)修改 Makefile 中的 DOSTATIC,將false 改為 true,這樣執行時就不需要有glibc了。
(2)BusyBox 上的 init,和一般所使用的 init 不一樣,她會先執行 /etc/init.d/rcS 而不是 /etc/rc.d/rc.sysinit。
為了和Redhat的配置相同,所以修改了 BusyBox 中的 init.c。底下是修到的部分

#ifndef INIT_SCRIPT
#define INIT_SRCIPT "/etc/rc.d/rc.sysinit"
#endif

(3) 安裝
#make
#make install

(3)./_install 文件。

#cp ./_install /tmp/floppy-linux -r

(4)建立其它的文件或文件:


#cd /tmp/floppy-linux
# mkdir dev etc etc/rc.d proc mnt tmp var
# chmod 755 dev etc etc/rc.d bin mnt tmp var
# chmod 555 proc
# cd dev
# mknod tty c 5 0
# mknod console c 5 1
# chmod 666 tty console
# mknod tty0 c 4 0
# chmod 666 tty0
# mknod ram0 b 1 0
# chmod 600 ram0
# mknod fd0 b 2 0
# chmod 600 fd0
# mknod null c 1 3
# chmod 666 null

(5) 配置文件:(inittab,rc.sysinit,fstab)

initab:
::sysinit:/etc/rc.d/rc.sysinit
::askfirst:/bin/sh
rc.sysinit:
#!/bin/sh
mount -a
# chmod 755 rc.sysinit
fstab:
proc /proc proc defaults 0 0

(6) 作Ramdisk:


# dd if=/dev/zero of=/tmp/initrd bs=1k count=4096
# losetup /dev/loop0 /tmp/initrd
# mke2fs -m 0 /dev/loop0>
# mount -t ext2 /dev/loop0 /mnt
# cp -r /tmp/floppy-linux/* /mnt
# umount /mnt
# losetup -d /dev/loop0
# dd if=/tmp/initrd | gzip -9 > /tmp/initrd.gz
# rm -f /tmp/initrd
# sync

3.核:

主要是去掉了一些不需要的,?核是725920Byte。包含了必要的网卡。

4.整合

在所用到了的全部搞好了,下面就是整合一下:

全部文件(文件)如下:

/lost+found/
/boot/
/boot/grub/
/boot/grub/stage1 =========Grub用到的文件
/boot/grub/stage2
/boot/grub/menu.lst =========Grub的配置文件指向grub.conf
/boot/grub/grub.conf
/boot/kernel =============核
/initrd.gz ===============存

Copyright controlled CD..

Available audio cd protections:
Note: this list is not complete, more protections are available. Availability is mainly targeted at Europe.

How to recognize a protected audio cd:
  • use Clony XXl (German version, homepage might be down. English version can be found here.)
  • use Tccd Scout (German version. English version unavailable ?)
  • visual inspection
Note: Clony XXL/Tccd Scout will not always properly recognize the protection because audio protections are hardware dependant protections, dependant on your reader. Your reader might not properly report/read the content of the disc in which case Clony XXL can't determine the protection. Another factor: audio protections are still evolving and newer versions are silently released.

Cactus Data Shield 200 (Example: Natalie Imbruglia - White lillies island)

A CDS200 protected audio cd can be recognized by visual inspection as follows:
  • Copyright statement refering to Midbar Tech, Tel-Aviv, Israel somewhere on the front/back cover or inlay.
  • Availability of the Cactusplayer (= proprietary mp3-player) when cd is inserted in a cd-rom player.
  • Availability of the hidden textfile 'versions.txt' in the datatrack. In this file the used version of CDS200 is mentioned. Note: older versions of CDS200 may not have this file.

Key2Audio (Example: Shakira - Laundry service)

A Key2Audio protected audio cd can be recognized by visual inspection as follows:
  • Warning stating 'will not play on pc/mac' on the front/back cover and labelside of cd.
  • Textstring 'Sony Music' or 'Sony dadc' on the innerring on the data-side of the cd.

[update 2002-12-01]
Doc.Loc (Example: Hitzone 21 - various artists, released in the Netherlands)

A Doc.loc protected audio cd can be recognized by visual inspection as follows:
  • Textstring 'DocData' on the innerring on the data-side of the cd.
Note: DocData not only develops audio copy protections, it has also normal cd replication/manufacturing plants. It has been reported that non-protected cds also may have the textstring 'DocData' on the innerring on the data-side of the cd.

Logo's

The record industry nowadays uses special logo's so customers can recognize cds which contain copy protections. The following logo's are used:


This logo is a general logo stating the cd has a copy protection.


This logo states the cd can be played on most cd/dvd players but not on a personal computer.


This logo states the cd can be played on a personal computer but cannot be copied.

Note: A lot of modern dvd players are also able to play mp3 cds. In order to achieve this a cdrom is used. This means you can encounter the same problems as when trying to play this cd on your personal computer.

A user-contributed list of protected cds around the world can be found here. Note: be aware that wrong information might be displayed! For the Netherlands an official site with list can be found here.
[/update]

How to copy/rip a protected audio cd:

General considerations:

Audio protections are hardware dependant protections, based on your reader. This means that when you have the 'right' reader, audio protections will give (almost) no trouble copying/ripping. But it could also mean that when you have the 'wrong' reader you won't be able to copy/rip the cd at all... The writing part is not interesting because all available writers are able to write protected audio cds.

Tricks used by audio protections: illegal Table Of Content entries, multi-session tricks. A normal audio cd-player is a single-session device, it just reads the first session where the audio tracks are, it isn't bothered by the extra sessions because it can't read the extra sessions. Also, an audio cd-player expects only audio-tracks so can't be confused by illegal TOC entries which claim that the audio-tracks are data-tracks. A Cdrom-player (or dvd-player, cd-writer) is a multi-session device, it tries to read all sessions. But these (illegal) extra sessions are purposely added to the cd to fool the cdrom-player. Also, a cdrom-player can read audio as well as data, so it can be confused by illegal TOC entries which claim that audio-tracks are data-tracks.

Because the protection is hardware dependant we can classify 3 categories:
  1. reader is (almost) not affected by protection and just reads the cd.
  2. reader is affected by protection, but is still able to read the cd using tricks.
  3. reader is affected by protection and can't even read the cd using tricks.

1.) You are lucky, you can copy/rip the protected cd relatively easy with programs like CloneCD, Feurio or ExactAudioCopy or Isobuster. You might need to tweak the advanced settings of these programs.
2.) You are still able to copy/rip the protected cd with the marker-trick.
3.) You are not able to read the protected cd, whatever you try, you won't succeed. Only option: try another firmware which might make your reader able to read the protected cds. LiteOn is a good example for this, since november 2002 recent models can suddenly read most audio protections, while before they couldn't read almost any...

[update 2002-12-01]
Recommended hardware:
  • Yamaha CRW F1 (appears to read all copy protections and all versions of the copy protections, also the older and more harder versions)
  • Plextor - all models
  • LiteOn - starting from models 40sp and higher with the latest firmware
[/update]

General tips regarding the used software:

CloneCD v4 is the easiest way to backup your audio protected cd. Just use the audio-profile which reads only the first session so your backup is not protected anymore.
Feurio can be used to rip the tracks. Of course your backup, when writing the ripped tracks, isn't protected anymore. Feurio is able to detect illegal TOC entries and gives you the option to ignore the further sessions and illegal entries. If you succeed in reading the protected audio cd with CloneCD you should also be able to rip it with Feurio. You might need to tweak the advanced settings of Feurio first.
Exact Audio Copy can be used to rip the tracks. Of course the protection is gone after ripping. In some cases you might need the option 'manually detect TOC' in order to be able to rip the tracks. The advantage of EAC is its secure reading method (which has nothing to do with the protection).


Always try to let your application to close the cd-tray with the protected audio cd in it. Do not insert the protected audio cd earlier because Windows might interfere with it and 'activate' the protection. Programs like CloneCD lock the drive so Windows can't mess up things. Again: don't insert the disk to early!

In order to prevent Windows (or the firmware of your drive) to access the protected cd too early, you also need to make sure that you have disabled 'auto insert notification' and 'auto play'. These options can be disabled through the device manager or the registry, depending on your Windows version. CloneCD also has a special entry in its settings for disabling these settings.

How to copy/rip a protected audio cd if the above mentioned methods don't work:
  • make a digital copy using your audio cd-player and a soundcard.
  • make an analog copy using your audio cd-player and a soundcard.
If your audio cd-player has a digital-out and your soundcard has a digital-in, you could connect the two and use the 'record audio data'-option from Feurio. Total Recorder is also able to record from line-in.
If your audio cd-player has no digital-out or your soundcard has no digital-in, you could still connect the 2 the analog way. Just connect the line-out cinch-plug with the line-in minijack-plug of your soundcard. Again use Feurio or Total Recorder to record incoming audio data. The disadvantage of this method is you are copying in the analog domain, your digital data is converted twice which might degrade the resulting copy. In practice an analog copy can be very good, but we CDFreakers prefer the best, so we go for the digital copy!

中藥

星期二, 10月 12, 2004

中藥

大黃牡丹皮湯

[組成藥物]

大黃、牡丹皮、桃仁、芒硝、冬瓜子。
[主治效能] 下腹右側疼痛,盲腸炎,月經困難症,卵巢炎,濕疹,上項各症便秘者均可用之。
[運用經驗] 本方應用範圍至為廣泛,凡屬於實證有便秘傾向之下半身特在下腹部之諸炎症化膿症均可適用。其特徵為腫脹,疼痛,發熱,痛苦自覺較強,脈緊有力者,用法得當,功效難述。

蟬蛻
來 源 : 本 品 為 蟬 科 昆 蟲 黑 蟬 ( Cryptotympana atrata FABRICIUS ) 羽 化 後 蛻 殼 。
功 用 : 散 風 熱 , 退 目 翳 , 宣 肺 透 疹 。
主 治 : 外 感 風 熱 , 頭 風 眩 暈 , 中 風 失 音 , 咽 喉 腫 痛 , 目 翳 ; 小 兒 驚 風 , 夜 啼 , 麻 疹 透 發 不 暢 , 風 疹 , 皮 膚 瘡 瘍 癮 疹 。
貯 藏 : 置 乾 燥 處 、 防 壓 碎 。
鑑 別 : 以 色 黃 , 乾 燥 , 體 輕 , 完 整 無 缺 , 無 泥 砂 為 佳 。


遠志
[別名]

遠志筒,遠志通,遠志肉,小草,小雞棵,山茶葉。
[來源]

遠志科 (Polygalaceae)。遠志 Polygala tenuifolia Willd. 的與卵葉遠志 Polygala sibirica L. 根皮部。
[性味]

味苦、辛,性溫。
[功能]

安神,益智,祛痰,抗菌。
[主治]

心氣鬱結,心血虛,痰涎壅塞,煩熱,精神恍惚,驚悸,不眠,神經衰弱,寒痰喘咳,益精強志,健忘。
[用法用量]

10~20公克/日;科學中藥:0.52.0公克/日。可依病症與體質酌量增減使用量。

加味逍遙散

加味逍遙散

[組成藥物]

當歸芍藥柴胡白朮茯苓甘草牡丹皮梔子薄荷生薑
[主治效能] 治火旺,月經超前,大便閉濇,口燥咽乾,室女血虛陰弱,痰嗽潮熱。應用於婦人神經衰弱,月經不調,白帶,慢性子宮內膜炎,腰部覺冷,頭痛,目眩,肩凝,更年期障礙。
[運用經驗] 本方之主要藥效,在於養血清火,可用為婦科調經方。經驗上凡婦女平日有臟躁症者(包括更年期障礙,歇斯的里等症),用之多效。

Log on Integration

  1. .ad,dodiprc,usb_fun,qspi_client,usb_client 沒有Makefile
  2. 缺linear1-8 在/mnt,應該是執行rc的問題
  3. 嘗試整理file產生script和rc
  4. 將jffs image內容簡化成passwd 和cofig目錄,其他由sbin script和rc產生
  5. www的log因為一開始沒有,但是還是要有file,否則沒辦法有link。
  6. !!! Lcdui 應該不要顯示小數(DCV除外)

星期一, 10月 11, 2004

Fishing ..

今天第一次收到網路詐騙簡訊:

從1109100932 刷卡確認,您於18:40在新光百貨消費16800元,
簽單編號1598.如有疑問請速洽信用卡中心02-55995244

星期日, 10月 10, 2004

dwl -122 . take back.. but still not work..

拿回來了,查了一下是8/15去修的,竟然花了1.5 month。
測試了一下,雖然usb找的到,但是連不通呀!

是設定的問題嗎?

待會把AP reset試試。

真麻煩,所以便宜真不是沒道理。
============================
OK. 原來只是找得慢而已。
將AP的 broadcast ESSID打開後。
用pc (XP)測ok.用win2k,等了3 min才ok。

......訊號好像還比buffalo WLI-CB B11好。
畢竟是prism的,不是buffalo的realtek兩光晶片

星期五, 10月 08, 2004

some places ... maybe .. better.

  1. 一些用POW(2,number)的似乎可以用 0x01 <<>
  2. 用gcvt( )的是不是應該用sprintf( buf,"%4.2f",...) ?

http://www.bravenet.com/ : 提供webtool的地方

也就是說,可以知道是從哪裡來的,流言版`...之類

..已經註冊

Dream : Car is on fire

昨晚作了一個夢。

開車中覺得有亮光從第發出,後來身旁的駕駛告訴我我的車著火了,
不得了,這下我也好像聞到燒焦味,
趕緊下車,發現安全帶綁著,車門也鎖著,
我告訴自己,現在千萬不能慌張,越慌張越出不去(電影都是這樣演的),
所以我確實的把安全帶鬆開,
將車門鎖打開,
安全的開門出去。
這三個動作感覺上作了好久,速度變成慢動作的感覺。
走出車外發現是輪胎著火了,都燒得只剩下輪軸,
我趕緊去提水(用礦泉水瓶)滅火,
最後,火好像滅了。

但是車底隱隱好像還是有火光閃動....

星期四, 10月 07, 2004

Chad's call: from India

Chad晚上call
他看到的Err有:
A2 : Stuff Error , Id21-28, Reception
F3 : Other Types of Error, tormate dorminate bit, Reception
77 : Form error, error delimiter, Reception

不是一值出現,偶而才出現,一但出現就會連續出現,
AC斷掉不一定每次會發生。

=============================================

check the Err code then call Chad on 8:00. call chad's cellphone.

hotel no : +91 1245050757
91 is the contry code
002 91 1245050757.

2.1 -> 2.5 : make commerr confirm time from 6.5 sec to 10 sec.
2.5->2.6 : pdb watchdog function. (?)

LCD not work.. Solved.

以為一切都很好,
換上新的motherboard----LCD沒動作!
唉~~!

寫程式一pin一pin的動,check high-low是否正確,
signle step check delay time是否不同,
用示波器看是否有noise..
....都很正常。

Chris說:查一下contrast voltage好了。很多版子第一次作都要調這個。
OK。
查了一下舊版電路圖和新版的這個部分完全相同。

量電壓卻不一樣,
舊版是1.多,新版是4.多。

交給光X,發現所有舊版的電阻都交換過!

所以說版子換人作就是不行,當初一定是James自己debug改掉,但是sch是Chad負責,所以Chad不知道。

之後又交給光X。所以就照抄了。當初debug的動作就要再做一次。

~~浪費我半天的時間。

星期三, 10月 06, 2004

Debian: Search the contents of packages

Search the contents of packages
例如:
在Keyword輸入 xlib.h
結果是:

You have searched for xlib.h in stable, architecture i386.
Found 6 matching files/directories, displaying files/directories 1 to 6.

FILE                                                       PACKAGE 

usr/X11R6/include/X11/Xlib.h				    devel/xlibs-dev

usr/i486-linuxlibc1/include/X11/Xlib.h oldlibs/xlib6-altdev
usr/include/elk/extensions/xlib.h devel/elk
usr/include/ggi/display/xlib.h devel/libggi2-dev
usr/lib/TenDRA/lib/include/x5/lib.api/X11/Xlib.h devel/tendra
usr/lib/perl5/Tk/pTk/Xlib.h interpreters/perl-tk


所以知道要install xlibs-dev 就可以了

沒中!

093078大樂透:05,13,25,32,36,39
093079樂透 :03,14,18,23,29,40

SVN : a better CVS (?)

會比CVS好?

不過有中文說明。

usbehci.sys missing.. USB 2.0 XP driver

原來XP不內建USB 2.0的driver,
插上USB 2.0的device也是用1.1來通訊。

所以裝完XP,要先檢查hardware在USB Controller部分有沒有?號。

具microsoft的網站,SP1好像有update:Here

my poor knowlege : ++ and *

C中 ++的優先權大於*,
所以*cnt++會先將cnt+1後取值。

這又是一個簡單的rule,我又不知道。
我以為* > ++

my poor knowledge : printf

printf的第一個參數可以用string variable:
char format[]=" in hex %x\n";
printf(format,10);
其實想想也蠻正常的,應該算是我孤陋寡聞吧。

你有失眠體質嗎?

同樣的黑夜,有人呼呼大睡,有人卻睡不著,到底什麼樣的人容易失眠?中西醫一致認為,失眠與體質有關,西醫認為A型性格的人較易失眠,中醫則認為木型人屬於容易失眠的體質,如果你有這兩種體質,就應該特別注意失眠問題。

長 庚醫院精神科醫師許世杰表示,失眠與體質有關。經臨床上發現,失眠者的個性都是要求完美、容易緊張、急性子、自我要求較高的人,對事情較易採取否認與壓抑 的態度。例如在職場上,A型性格的人,如果身為部屬,對長官要求的事,一定努力去達成,要求自己必須完美演出。如果是中高階幹部,則常見個性很急,交代部 屬做的事,如果部屬還沒完成,他可能就急得親自跳下去做了。

知名中醫師李政育說,以中醫理論來看,失眠的高危險群是五行中的木型人,木型人的特質是行事內斂、易煩惱憂鬱、把事情往心裡面擱。平時喜歡動腦筋、愛思考、感情豐富。外型上,木型人臉色白中帶青色,身材多屬細瘦型,但也有身材高大的木型人。

不論是A型性格或木型人,許世杰指出,具有這樣特質的人,一旦碰到工作壓力突然增加、換工作、升遷、結婚、疾病等重大環境改變,就容易有睡眠障礙。如果每周有三天以上失眠,情況持續一個月以上,就屬於嚴重失眠,應該盡快就醫,以免變成慢性失眠或演變成憂鬱症或焦慮症。

本文轉載自今周刊第406期
已經FAX LJ的定購,1年,掛號,希望從這個月開始。

星期一, 10月 04, 2004

processor:
PIC,8051,80186,ARM7,Coldfire(m68k).
OS:
SALVO,RTX-51,RTXC,pSOS,uClinux.
Protocol:
SPI,I2C,CAN,MOBUS,SLIP,PPP,Ethernet.

星期六, 10月 02, 2004

星期五, 10月 01, 2004

XML special keyword

不能用">"
因為在xml中,所有以 <>刮起的都是tag。
又parsing是由>來決定結尾,所以"<"沒關係。
如果要用>,要寫& gt;


同理,"也是一樣。用& quot

stdarg.h uclibc lib/libc/include link..

使用ipc的message queue,include stdarg.h
stdarg.h include < machine/stdard.h >

include path是 uClinux-dist/lib/libc/

所以include path下要有machine 目錄。
這個目錄在make時才會產生。

make時會產生asm -> linux/include/asm
linux -> linux/include/linux
machine ->m68k
System V IPC on LX

imageshack - a place to store photos

http://imageshack.us/index3.php
另一個放照片的地方.
也已經註冊

Flickr : the place to store photos

http://flickr.com/
已經註冊了:)

星期四, 9月 30, 2004

記帳

長榮 3100

油錢 1000
比非多 20
土拖魚羹 95
lab聚餐 1000
ORO coffee 300

dinner 640

關子嶺溫泉旅館 2640
水火洞 lunch 270
筍乾 200
芭樂50
舒跑 20
芭樂 110
油錢 1010

集集 coffee 180
park 60
梅子 800+150+200
香腸 50
販賣機 17
香油錢 100

清水 150

過路費 560

星期二, 9月 28, 2004

唉,別多事了,
既然人家不喜歡,就做好自己的事就好,
做自己喜歡的事,其他人,也不關你的事,
算了吧!

星期五, 9月 24, 2004

二高

關廟出口,往歸仁.....

Sign..

要討論細節,又不准人家把程式寫好。。

那不就還是規格討論。

台灣網路危機處理暨協調中心

http://www.cert.org.tw/news/

Log\Auth.log

scanned from 218.58.67.47 with SSH-1.0-SSH_Version_Mapper. Don't panic.

星期四, 9月 23, 2004

LAB聚餐地點

餐廳:永上海鮮餐廳
地址:金華路四段45號 藥師廟對面,協進國小旁
電話:06-2206691

如何使用Emule同時保障自身安全

★ [教學] 如何使用Emule同時保障自身安全?
「哎!我被學校抓到,網路禁用一個月…」
「你這算什麼,我被學校記一隻大過耶!」
可怕嗎? 這是有辦法避免的!
作者:佚名

[適用版本]
官方版 eMule 0.27 以上版本
以官方版 eMule 0.27 以上版本修改的 eMule MODs
應該都有支援eDonkey、cDonkey、MLdonkey、xMule、
OverNet、Shareaza 我沒用過不確定
將 IpFilter.dat 內的資料加入防火牆亦可以達到同樣效果

[使用方法]
1. 舊版 eMule:放置於 eMule 安裝目錄下,或覆蓋檔案
 新版 eMule:覆蓋 config 目錄下原本的檔案
2. 設定 → 防護 → 勾選 [過濾伺服器] or [過濾壞的IP]
or [IP過濾器]←依版本不同,會有不同翻譯,請自行確認

[檔案連結] 請將檔名改為 IpFilter.dat
IpFilter

[簡介]
IPfilter是過濾不良ip
所謂的不良,就是對自己有害
所以像是國外的好萊X公司或其它電影、軟體等會抓人的
大公司的ip就可以擋掉。

強烈建議大家使用(尤其是學網的人)

疾風病毒

如何判斷已中毒:
1.網路變的很慢,或是沒有網路動作但網路卡卻不停閃爍。
2.電腦出現RPC錯誤訊息並警告將於 60 秒後自動關機。
3.執行 [工作管理員] 點選 [處理程序] 查看是否有下列程式正在執行
msblast.exe若有發現此檔名則是中了"疾風病毒"
4. Windows 2000作業系統
C:\> cd \winnt\system32\winsC:\> dir
dllhost.exe
svchost.exe (若出現此兩個檔案即已中了"疾風變種病毒")
5. Windows XP作業系統
C:\> cd \windows\system32\winsC:\> dir
dllhost.exe
svchost.exe (若出現此兩個檔案即已中了"疾風變種病毒")
請將dllhost.exe及svchost.exe2個檔案刪除

星期三, 9月 22, 2004

Notes : problems on Alice's .. (uclinux)

1.在副程式call vfork造成parent process hang.
2./usr內程式太多造成boot時core dump - single user mode

NB 無線往卡

apt-get install wireless-tools

設定網路組態,並重新啟動網路!
# vi /etc/network/interfaces
加入 "iface wlan0 inet dhcp"
(如果您的IP並非dhcp取得,請自行修改符合設定)
# /etc/init.d/networking restart
# ifconfig eth0 down
重新啟動網路!並讓無線網路裝置生效!


編譯並安裝驅動模組:

  為了要編譯驅動模組,我們必須安裝 kernel-package 及 debhelper 這兩個套件:

代碼:
apt-get install kernel-package debhelper

  然後,進入 Kernel Header 的目錄中,並進行編譯:
  (如果是 Kernel 2.4.x,則進入 Kernel-Source 目錄,並進行編譯。)
代碼:
cd /usr/src/kernel-headers-2.6.7-1-386/
make-kpkg modules_image


Intruder's log...

以下在 /var/log/auth.log..

Sep 21 20:07:55 debian sshd[909]: Illegal user test from 218.104.55.15
Sep 21 20:07:56 debian sshd[911]: Illegal user guest from 218.104.55.15
Sep 21 20:07:58 debian sshd[913]: Illegal user admin from 218.104.55.15
Sep 21 20:07:59 debian sshd[915]: Illegal user admin from 218.104.55.15
Sep 21 20:08:00 debian sshd[917]: Illegal user user from 218.104.55.15
Sep 21 20:08:05 debian sshd[925]: Illegal user test from 218.104.55.15


poor QNX

QNX真是可憐,
最初的時候,他做PC的OS,做得比DOS好太多了,
可惜,因為價錢(賣得太貴),所以IBM PC用DOS,
造成DOS成為標準的PC OS(其實這也要靠盜版的幫忙)。
沒關係,QNX就專攻embed市場(market就小得多了)。
可憐,最近embeded市場雖然變大,但是linux是free的,
雖然QNX的performance和方便都比linux好,
但是還是因為price,使用linux的人還是比較多。

現在,QNX要推出roylty free的version。
可憐,如果他當初就這樣,
QNX可能是現在的MS吧。
現在可能不會有Windows,因為QNX比DOS好很多(當初)。

TODOS - today

1.WuJian - hyperterminal 2.6_2
2.Notes : last night's meeting with Ed on Web.
3.Notes : Cxu modification flow.
4.Alice : vfork (do) hang.
5.請假 - SAT.

星期二, 9月 21, 2004

果然....

正如Jary所預測,SUNDAY的行程就是”鳥獸散”。
因為突然有3人有事要先走,先到。
所以....

目前考慮行程有
1.走馬賴
2.高雄
3.曾文水庫

usb cf reader on NB : OK

apt-get install hotplug

就這個command,然後

mount /dev/sd1 /mnt/usbcfreader <--是自己create的

就OK。

不知道為什麼Server卻不行(不過Server是Try eBay cf disk)。

星期一, 9月 20, 2004

debian cd image

TODOS - today

1.Modify HydrofanFail protocol.
2.NFS on win2k
3.Debian unstable.
4.Bill - Credit card. Loan.
5.uClinux driver - DIO : wrong initcode

6.Ask if Thu 7:30 could arriver at Threater -.. Movie Preview.

星期日, 9月 19, 2004

from greenfly : usb storage driver for linux

How to set up a removable USB Drive





Be sure the check out the 2004-04-22 update at the bottom of the page!

For my birthday this last year, I received a USB laptop drive enclosure. Once I upgraded my hard drive in my P2110, I had its 20Gb hard drive to use in it. I decided to set up a FAT32 partition on it, spanning the full 20Gb, and now have set up hotplug and autofs to automatically mount the usb drive when I insert and access it (and umount it when it's idle).


Getting information and setting hotplug up

So, first thing, is for hotplug to be installed. In Debian it was as simple as running apt-get install hotplug. Hotplug isn't necessarily easy to configure, but following some tips on the 'net, I was able to figure it all out. The first step, is to plug in the USB drive, and scan through the logs to make sure it works. Hotplug recognized that it was a usb hard drive, and made sure my usb-storage module was already loaded.


Jan 19 15:46:27 clover kernel: hub.c: new USB device 00:02.0-1, assigned address 4
Jan 19 15:46:27 clover kernel: WARNING: USB Mass Storage data integrity not assured
Jan 19 15:46:27 clover kernel: USB Mass Storage device found at 4
Jan 19 15:46:31 clover usb.agent[10819]: kernel driver usb-storage already loaded


USB drives work as regular scsi hard drives as far as we are concerned (and requires sd_mod to be loaded). And we could just mount the device that is created (/dev/sda1 for me) and be done with it. I wanted it to automatically mount when I plugged it in, and umount when I unplugged it. To do this, first we need some information from /proc:

/proc/bus/usb/devices will show information about the various usb devices on the system. For instance, here is a snip from the file when my usb drive is plugged in:



T: Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 4 Spd=12 MxCh= 0

D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1

P: Vendor=05e3 ProdID=0702 Rev= 0.02


S: Product=USB TO IDE

C:* #Ifs= 1 Cfg#= 1 Atr=c0 MxPwr= 96mA

I: If#= 0 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage

E: Ad=81(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms


Yeah, it's a lot of gibberish, but there's useful information in there for setting up hotplug. I have highlighted the parts that are of interest to us. You can configure hotplug to do certain things when certain devices are plugged in. It already has its own scripts set to run when it detects generic usb-storage devices, but I wanted something specific. To do this, you need to edit the /etc/hotplug/usb.usermap file:


# usb.usermap file
# This is autogenerated by update-usb.usermap program
# Note: you may use /etc/hotplug/usb/*.usermap
# usb module match_flags idVendor idProduct bcdDevice_lo bcdDevice_hi bDeviceClass bDeviceSubClass
#bDeviceProtocol bInterfaceClass bInterfaceSubClass bInterfaceProtocol driver_info
usb-storage 0x00f 0x05e3 0x0702 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00


In the line I added above, there are only 3 fields of interest, the match_flags, idVendor, and idProduct. I noticed from the usb.distmap file that the match_flags field for usb-storage was 0x00f. Now, the idVendor value I got from that /proc file I listed above. It says "Vendor=05e3" so I put in 0x05e3 in the second field. Likewise I took the "ProdID=0702" and put in 0x0702 in the idProduct field. The rest doesn't matter (the first three fields are enough to match this device) so I just put in 0x00 for those.

This line in usb.usermap tells hotplug to run the /etc/hotplug/usb/usb-storage script whenever it sees that this device is plugged in. That script can then load modules, or run other programs (including setting up programs to run when the drive is removed). I found some examples on the net and created my own that would automount the drive:



#!/bin/sh
case "$PRODUCT" in
5e3/702/2) # FireXpress usb hard drive
/bin/mount /mnt/usbdrive
# set up what to do when you remove the drive
echo -e '#!/bin/sh\n/bin/umount /mnt/usbdrive' > $REMOVER
chmod a+x $REMOVER
;;
esac


If you want to see what kind of enviroment variables are present when this script is run, you can insert a "set >> /tmp/settings" line above the case statement. Reading through that file, you can see what $PRODUCT is set to for your product. In my case it was set to "5e3/702/2". I then set up the case statement to mount this usbdrive when that device is actually plugged in (my fstab entry established the mounting of a /dev/sda1 vfat partition on /mnt/usbdrive). There is another environment variable, $REMOVER, that specifies the name of a script that is run after the device is removed. This script is empty by default, so I echoed in the umount command I wanted to use when I removed the drive.

I then ran chmod a+x /etc/hotplug/usb/usb-storage to make the script executable. Once I restarted the hotplug service with /etc/init.d/hotplug restart I then could plug in the drive and see that /mnt/usbdrive had been mounted by running df. When I unplugged the drive, the drive would then be umounted.

Not the best solution

Now, there are some problems for this. Namely, the drive isn't being umounted until it is already removed. This could result in filesystem corruption over time. The solution is to use autofs to mount the device on demand, and then umount when idle.

Autofs saves the day

First, I installed autofs with apt-get install autofs. Then I modified /etc/auto.master and added an entry for my removable drive:


# $Id: auto.master,v 1.2 1997/10/06 21:52:03 hpa Exp $
# Sample auto.master file
# Format of this file:
# mountpoint map options
# For details of the format look at autofs(5).
/var/autofs/misc /etc/auto.misc
/var/autofs/net /etc/auto.net
/var/autofs/removable /etc/auto.removable --timeout=2


That last line tells autofs to mount any of the removable devices I will specify in /etc/auto.removable under /var/autofs/removable, and to umount them after 2 seconds of idling. I then created the /etc/auto.removable file:


usbdrive -fstype=vfat,uid=1002,gid=1002,umask=002 :/dev/sda1


This file sets up a mount point which will end up being /var/autofs/removable/usbdrive, the mounting options to use, and which device to mount. Now, all of this happens outside of /etc/fstab, so I removed my entry for my usbdrive from /etc/fstab, and also removed the /mnt/usbdrive directory. I decided what I would do instead is have my hotplug script create a symlink to the autofs mountpoint when the drive is inserted, and remove the symlink when the drive is removed. That way, I will only deal with /mnt/usbdrive and not worry about any /var/autofs directories. The new and improved /etc/hotplug/usb/usb-storage is the following:


#!/bin/sh
case "$PRODUCT" in
5e3/702/2) # FireXpress usb hard drive
ln -s /var/autofs/removable/usbdrive /mnt/usbdrive
# set up what to do when you remove the drive
echo -e '#!/bin/sh\nrm /mnt/usbdrive' > $REMOVER
chmod a+x $REMOVER
;;
esac


Now, I can plug in my drive, and see that /mnt/usbdrive is created. After 2 seconds, autofs will umount the drive. You can monitor /var/log/syslog to watch this happening:


Jan 19 16:24:35 clover automount[14059]: mount(generic): calling mkdir_path /var/autofs/removable/usbdrive
Jan 19 16:24:35 clover automount[14059]: mount(generic): calling mount -t vfat -s -o uid=1002,gid=1002,umask=002
/dev/sda1 /var/autofs/removable/usbdrive
Jan 19 16:24:36 clover automount[14059]: mount(generic): mounted /dev/sda1 type vfat
on /var/autofs/removable/usbdrive
Jan 19 16:24:39 clover automount[14066]: running expiration on path
/var/autofs/removable/usbdrive
Jan 19 16:24:39 clover automount[14066]: expired /var/autofs/removable/usbdrive


As you can see, the drive unmounted seconds after the command finished, since it had been idling. It would now be safe to remove.

For the future, I am planning on setting up a similar system for my digital camera (which appears as a normal usb storage device as well) to not only automatically mount the camera, but also sync up any photos on it.

iPod-specific configuration

First of all, a caveat. I don't actually own an iPod (if you want to remedy that, email me) so all of this is based on a 3rd generation iPod configuration I helped a friend, whiprush, set up.

The configuration is really just about the same, with a few distinct changes. For one, the Product ID is different on the iPod, so /etc/hotplug/usb/usb-storage would look something like:



#!/bin/sh
set >> /tmp/settings
case "$PRODUCT" in
5ac/1201/0) # Apple iPod
sleep 5
ln -s /var/autofs/removable/ipod /mnt/ipod
# set up what to do when you remove the drive
echo -e '#!/bin/sh\nrm /mnt/ipod' > $REMOVER
chmod a+x $REMOVER
;;
esac


Make sure to make this script executable. As you can see, the main thing that changed from the previous usb-storage script is the value of $PRODUCT. Also added was a sleep 5, as the iPod seemed to take a bit longer to initialize than my regular usb drive. If this script doesn't work for your iPod, look through /tmp/settings and see what PRODUCT= is set to.

This script will create a symlink, /mnt/ipod, to the autofs directory that you will then set up. When you unplug the iPod, the symlink will be deleted.

Now to edit autofs settings. First add the following line to /etc/auto.master:


/var/autofs/removable /etc/auto.removable --timeout=2


Now edit /etc/auto.removable:


ipod -fstype=vfat,uid=1000,gid=1000 :/dev/sdc2


If your iPod partition sets itself up as something other than /dev/sdc2 (check /var/log/syslog or /var/log/messages if you don't know), then simply change the /dev/ entry to match it.


Now, restart autofs and a symlink, /mnt/ipod, should be created that then links to the autofs directory. When you access that directory, your iPod should become mounted. It will then umount after 2 seconds of idle time.

IEEE1394 Support

If you have a IEEE1394 card in your Linux system, you can add some extra configuration so that it will work the same as when you plug it in USB.

First you need to create an /etc/hotplug/ieee1394 directory. The iPod registers as an sdp2 device, and you will need to create a script at /etc/hotplug/ieee1394/sdp2 to handle the device:


#!/bin/sh
set >> /tmp/settings
case "$GUID" in
000a27000252a1ee) # Apple iPod
sleep 5
ln -s /var/autofs/removable/ipod /mnt/ipod
# set up what to do when you remove the drive
echo -e '#!/bin/sh\nrm /mnt/ipod' > $REMOVER
chmod a+x $REMOVER
;;
esac


Unlike the usb-storage script, the iPod as an ieee1394 device doesn't have a PRODUCT environment variable. Instead we use GUID to identify it. Now restart hotplug, and try plugging in your iPod to your IEEE1394 port. The /mnt/ipod symlink should be created, and accessing it should mount your iPod.

UPDATE 2004-04-22

I have modified this hotplug script rather heavily since I got started, and thought I might share some of the updates on this page.

I realize that hard-coding the scsi device doesn't work for anyone who might use multiple usb devices at once. The difficulty in generating the scsi device on the fly is that the kernel doesn't directly provide access to determine which scsi hard drive a certain GUID was assigned. Really the only way to do so required a hack that would read certain /proc entries along with /var/log/syslog. I call these pair of hacks usbguid2sd and sd2usbguid. As the names suggest, these scripts convert between a usb GUID and a scsi drive, and back again.


Using these scripts I can create a default autofs setup for sda1, sdb1, sdc1 and sdd1 and then map new usb-storage devices on the fly. The following hotplug script will use usbguid2sd and do special things for recognized usb drives, and otherwise create a /mnt/ symlink:


#!/bin/sh
DEVICE=`/usr/local/sbin/usbguid2sd $PRODUCT`
set > /tmp/settings
case "$PRODUCT" in
# FireXpress usb hard drive
5e3/702/2)
ln -s /var/autofs/usb/$DEVICE /mnt/firexpress
# set up what to do when you remove the drive
echo -e '#!/bin/sh\nrm /mnt/firexpress' > $REMOVER
chmod a+x $REMOVER
;;
# Olympus C750 camera
7b4/105/1)
ln -s /var/autofs/usb/$DEVICE/dcim/100olymp /mnt/camera
echo -e '#!/bin/sh\nrm /mnt/camera' > $REMOVER
chmod a+x $REMOVER
export DISPLAY=":0.0"
su greenfly -c /home/greenfly/bin/eterm_camera_sync
;;
# Attache usb key drive
ea0/6828/110)
ln -s /var/autofs/usb/$DEVICE /mnt/attache
ATTACHE=`diff /home/greenfly/.gnupg/secring.gpg /mnt/attache/.gnupg/secring.gpg`
if [ "$ATTACHE" = "" ]
then
killall xlock
echo -e '#!/bin/sh\nrm /mnt/attache\nsu greenfly -c "/usr/bin/X11/xlock -display :0.0 -mode blank"' > $REMOVER
else
echo -e '#!/bin/sh\nrm /mnt/attache' > $REMOVER
fi
# set up what to do when you remove the drive
chmod a+x $REMOVER
;;
# default
* )
ln -s /var/autofs/usb/$DEVICE /mnt/$DEVICE
# set up what to do when you remove the drive
echo -e "#!/bin/sh\nrm /mnt/$DEVICE" > $REMOVER
chmod a+x $REMOVER
;;
esac



You might notice I did something extra to the attache device. It is a usb keychain drive I carry around and I thought it might be slick if it killed xlock when I inserted it, and started xlock when I removed it. That section of the script compares the gpg secret keyring on the device with the one on the laptop (a crude form of authentication) and then if they match, it kills xlock. This way someone can't just plug in any attache drive and unlock my screen.



有關水火箭的飛遠比賽`...

全部都在推力和輕量化作文章,
我想”滑翔”的能力也是很重要的,
如果能夠加強滑翔力,要”滑”過100m應該是很容易的事,

適當配重,飛高,增加翼展,

usb disk

usb-storage
ide-core
hotplug

from Moto

花了一些時間追蹤 USB 裝置的 hotplug 流程, 將其記錄下來

以下是 USB Storage 的掛載流程:
1. kernel 偵測到新的 USB 裝置, 依據 /proc/sys/kernel/hotplug 內容呼叫 應用程式 /sbin/hotplug, 參數一為 usb, 參數二為 usb.agent 參數

2. hotplug 呼叫 /etc/hotplug/usb.agent

3. usb.agent 會依據 $MODULE_DIR/modules.usbmap 作 USB 裝置參數設定

然後 執行兩個 case

add)
載入驅動程式( /etc/hotplug/hotplug.functions, 其中 load_drivers()
最後呼叫 updfstab)

設定 storage device 的 symlinks( man devlabel, /etc/sysconfig/devlabel)

remove)
移除驅動程式
updfstab ( man updfstab, /etc/updfstab.conf )

5. updfstab 會依據 /etc/updfstab.conf 及系統偵測到的裝置, 自動設定

/etc/fstab

由以上流程可知, 若要讓一般使用者能夠 mount 隨身碟,需設定

/etc/updfstab.conf.default, 讓 updfstab 產生 /etc/fstab entry 時, 加上

必要參數, 並且動態產生 /mnt/memstick 掛載點, 目前 updfstab 並無法根據設定

檔設定 mount 參數, 而是寫死在程式碼中

- 預設 usb storage 的 mount 參數為 "noauto,owner,kudzu"

- kudzu 表示這個 entry 是 updfstab 產生

- owner 表示可以讓 console 登入的使用者 mount, unmount, 因為在 console

登入的時, 該 device 擁有者會變成該使用者

- 透過 /etc/security/console.perms

設定 =/mnt/memstick* 讓一般使用者可以直接存取 /mnt/memstick*
由以上流程:

Redhat 9 不需設定就可以偵測 USB 隨身碟, 並設定好 /etc/fstab

一般使用者只要 mount /mnt/memstick 就可以掛載, 並存取 /mnt/memstick

但是因為 updfstab 對於 USB Storage mount 參數是寫死在程式中, 因此對於

中文檔名需要加入 iocharset=cp950 無法藉由設定達成, 因此需修改 updfstab

updfstab 其所屬套件為 kudzu, 編譯 kudzu 需要安裝 newt-devel, dietlibc

加入以下 patch:
------------------------------------------------------------------------------
--- kudzu-0.99.99/updfstab.c.org 2003-02-21 00:48:31.000000000 +0800
+++ kudzu-0.99.99/updfstab.c 2003-09-29 22:13:06.000000000 +0800
@@ -740,7 +740,7 @@
!(strcmp(addition->device->type->name, "cdrom") &&
strcmp(addition->device->type->name, "cdwriter") &&
strcmp(addition->device->type->name, "cdrw")) ?
- "noauto,owner,kudzu,ro" : "noauto,owner,kudzu",
+ "noauto,owner,kudzu,ro" : "noauto,owner,kudzu,iocharset=cp950",
0, 0);
}

------------------------------------------------------------------------------

強制掛載參數 iocharset=cp950, 這個方法非常 dirty ....

reference:

1.http://www.spinics.net/lists/rh-devel/msg00811.html
2.http://connecteduser.com/forum/viewtopic.php?t=111

Linux Question Forume

註冊了....
# lspci -vvv
01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd.: Unknown device 8180 (rev 20)
Subsystem: Allied Telesyn International: Unknown device c106
Control: I/O Mem BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
Status: Cap 66Mhz- UDF- FastB2B ParErr- DEVSEL=medium TAbort- TAbort- MAbort- SERR- PERR-
Interrupt: pin A routed to IRQ 9
Region 0: I/O ports at 1000 [size=256]
Region 1: Memory at 10800000 (32-bit, non-prefetchable) [size=512]
Capabilities: [50] Power Management version 2
Flags: PMEClk- DSI- D1 D2 AuxCurrent=375mA PME(D0-,D1 ,D2 ,D3hot ,D3cold )
Status: D0 PME-Enable- DSel=0 DScale=0 PME-

# cardctl ident
Socket 0:
product info: "Realtek", "Rtl8139"
manfid: 0x0000, 0x024c
function: 6 (network)

wli cb b11

# lspci -vvv

01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd.: Unknown device 8180 (rev 20)
Subsystem: Allied Telesyn International: Unknown device c106
Control: I/O Mem BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
Status: Cap 66Mhz- UDF- FastB2B ParErr- DEVSEL=medium >TAbort- SERR- Interrupt: pin A routed to IRQ 9
Region 0: I/O ports at 1000 [size=256]
Region 1: Memory at 10800000 (32-bit, non-prefetchable) [size=512]
Capabilities: [50] Power Management version 2
Flags: PMEClk- DSI- D1 D2 AuxCurrent=375mA PME(D0-,D1 ,D2 ,D3hot ,D3cold )
Status: D0 PME-Enable- DSel=0 DScale=0 PME-

# cardctl ident
Socket 0:
product info: "Realtek", "Rtl8139"
manfid: 0x0000, 0x024c
function: 6 (network)


星期六, 9月 18, 2004

rl8180

  • Unpack the driver and edit the Makefile, make sure your INCLUDEPATH is correct. You will also need to edit line 59 in r8180_pci_init.c. Remember the vendor and device id you saved from watching the kernel log, the first value is the vendor, second is device, change them accordingly. It should look something like this:

    { 0x1186, 0x3300 /*0x8139*/, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 },

    Compile the driver, type make at the prompt. Now cross your fingers and do a insmod rtl8180_24x.o. This worked for me and I got the driver to load.

rtl8180 cardbus install

At the shell prompt, type make. The drivers will build themselves. If there are any problems making the drivers, open up the Makefile and check the kernel version settings on the first few lines.

Now open up the wlanup file.

Uncomment line 5 (remove the #) and change the SSID to the SSID of your network.

Uncomment line 8 and set the ssid2scan to your network's SSID. Uncomment line 9 and set the networktype to infra (unless you really are using adhoc). Save your changes.

Now eject the card

cardctl eject
and plug it in again.

From the directory where you unpacked the drivers, type

insmod -f rtl8180_24x.o

You will get a warning - ignore it.

Now run the wlanup script found in the driver package. Your card should now appear when you type ifconfig. You should configure your IP address at this point. If you use DHCP, just type "dhcpd wlan0". Try pinging google.com. You should get replies back. If so, your card is working!

Now copy rtl8180_24x.o to /lib/modules/YOURKERNELNAME, where YORUKERNELNAME is the name of the directory in /lib/modules.

Then copy the wlanup and wlandown scripts to /sbin.

星期五, 9月 17, 2004

1st software preview..

spam source map


這是postini的spam source統計,
看來台灣在這個領域算是名列前矛。

星期四, 9月 16, 2004

TODOS - today

  1. Release 2.7 : hyperterminal document
  2. Release 2.5 : all document
  3. Modify DO driver code, include all the do point.
光是補2.5, 2.7的document就花了一個早上...,

Problem - system hang - uclinux - so far

當機日,uclinux develop到現在,就剩下down機的部分了...
  1. Ad + Usb hang (file lock)
  2. qspi cs pin remove. (M)
  3. file copy hang - core dump (to ramdisk)
  4. web connection hang - core dump (temporary solved by reduce ramdisk to 512)
  5. snmp connection for a period of time, hang - core dump.
附計一些其他的
  1. Hydro No8 Init State
  2. include all DO point in do driver

1st Trial - Lispire (Lindows)

Follow PIL's post, download a trial version Lispire. install it on VPC.
Install process is smooth. just one click, no need to select any package.

Usage:

Similar to Windows, try to avoid using Console (Terminal). try to convince user to use GUI. .. maybe greate for novice, but for linuxers, it's a little bit......

Installation time is short (compare to most other distros), because it install the minimum packages only, only put an icon on the menubar.

It start download and install the package when user 1sttime executing the package.
The download and installtion process is smooth.. just wait, no need to choose anything.

.. So you know it's highly depend on internet access.

And.. this post is input in Lispir's browser.

New Search Engin : A9

新的搜尋引擎,Amazon,蠻有趣的。不過竟然要註冊。
...已經註冊了。

星期三, 9月 15, 2004

TODOS - today

1.Design Guidline for DcDcBreaker. (OK,append on problem.doc)
2. Changes from 2.1 to 2.6 - India want (OK, combined 3 doc)
3. 8 D report for DcDcBreaker
4.Reply Ok on OnGoRegisteration.
5.uClinux Hang on copy massive files.
6.Send hyperX.doc to chad. (OK, include cfg and tools)
7.ATM 3100 (ok:11:40)

星期二, 9月 14, 2004

different concept

兩種不同的觀念:
1.將一件事交給很多人檢查,所以每個人除了要作自己的事,還要做很多檢查其他事情的工作。
2.將事情區分清楚,每一個人負責做好自己的部分。

所以1的話,每個人的事都做不完,也因為事情多,所以檢查的事也就不認真在座,但是因為沒時間,所以自己的事也沒作好。

2的話,每個人都要專注的將自己的工作做好。所以focus的地方少,容易專精,自己工作得時間也多。

那要如何防止人為的意外,疏忽?

1的話就簡單,反正哪裡出問題,就列在表上,要求多一個人檢查,因為"總部可能每個人都錯馬"。

但是2就需要比較好的流程,加入"查核"單位,專注於查核的動作,或是以一關檢查上一關的方式達到檢查的目的。這就需要花腦筋了。

簡單的說1的話就是設計一個表格,找100個人來簽核,這樣不救有100個人做檢查工作?


Sign..

應該要說明原因才對,只有軍隊才是不問原因的(現在好像軍隊也要求合理化了)。
也就是說,要說"我為什麼要",而不是說"我就是要"。
所以當這一句話出現的時候,也就沒有什麼討論的餘地了。

所以基本的技術能力還是最重要的呀...

So different

設計表格的人通常是不需要填表格的人,所以表格的內容通常都很多。
如果他們自己要填,他可能就會一一斟酌每個item是否需要了

真是奇怪的公司

這一邊急著要,那一邊要等一下,另一邊還在懷疑是不是有問題。
她們自己內部沒有溝通的管道?

TODOS - today

1.Modify Modbus according CxT's request.
2.Rail - find TotalNumber and delete unused position.
3.Wujian - analysise SROM data send by Orgxn.Han
4.Write document - 2.1, 2.7, 2.8 difference for DxS India , to Chxd, request by Lxrry

RSS arggregator - blogline

原來用的Feedester在加入?的Feed後竟然無法動作(List all feeds)。
只好設法再找其他的。

原來Blogline比Feedster好,不會出現亂碼,subscribe的方式也容易的多,只要將他blogline提供的subcribe- link bookmark起來,以後看到想要subscribe的site,點選這個bookmark,就會自動取得資料,進入subscribe page。


星期一, 9月 13, 2004

INTERRUPT

早上的忘了,
下午
1:48 - Wu-Jixan, ask about hyperterminal cannot connect to 2.6.
1:55 - same question.
回KxN的mail - write SYSTOOLS document, modify James' parameter config file.
Phone call with CxT, Liao - so many things to modify.

Never Learn...

哪裡錯就改哪裡。

發生過這麼多事,還是一樣學不會。
總是想著 ”怎麼方便,怎麼改”。
這樣一天到晚都在做”補洞”的動作,

TODOS - today

1.HydrogxnFxnFail - Delay confirm (no modify on cxu) - Cancel.
2.CxT Modbus - Error on alarms
3.DxS India - ACSW Index Error
4.1800 - block out Empty Rail Noise message
5.KxN problem -mail
5.1: answer the question.
5.2: write document on SYSTOOLS
5.3: get the 7200 paramters setting.
6.Mail CxU board to CxT

音樂CD線上購物

已經用gmail註冊了

星期五, 9月 10, 2004

又住院了..

今天晚上去看中醫時,接到岳母的電話,岳父又肚子痛了。
我們把他接到忠孝急診,
一樣,是腸沾黏。
不過這次狀況沒上次嚴重。
還好。

今晚雨下得很大,所以急診的人很少,都是酒醉的。

紀錄一下

Max,
Tina
Mon, Tue - Microchip class.

Higher Grade CAN - FlexRay

大概是這樣

FlexRay - High
CAN
LIN - Low

設計上的混亂

因為detection board的功能不乾淨,
我們只做”綜合性”的版子,而不是偵測的資料區分。

所以會有很多detection board偵測相同的信號。
當版子拼在一起,就會發生...
  1. 要使用A的部分,B的部分不使用。
  2. 先用A的,數量多時再用B。
  3. A的這個部分不使用,用B的部分。
  4. A和B的這個部分都要使用。
這樣的問題。
而我們的系統,又很少只有接一個版子。

可以想見各種configuration的混亂狀況。

這就是沒做好系統分析的結果。
可是系統分析會有幫助嗎?
記得當初設計架構的依據是:作一快minimum (basic) requirement的board,所有的系統都要用他。如果有不足,再新增加其他的版子。

但是當不足時,新設計時會有以下情況:
  1. 為了配線,所以basic board的部分就不用了,改用增加的部分。
  2. 因為增加的部分很少,為此新增一塊並不划算(cost),所以新設計一塊,將新需求加進去。
  3. 因為增加的部分很多,所以basic的部分都不使用了,這樣還使用basic的部分,很不划算,所以新設計一大塊,將basic的部分加入。
這樣隨意拼裝的結果,就是所有的版子都不能共用,都不會是剛好match require。
同時造成software configuration的大混亂!

TODOS - today

1.Debug : 2.8_1, Breaker Rail index mass.
2.Pack and Send board to CxT.
3.Test time accuracy of system()
4.Find a useable toolkit for wxWidget (Minor)

Try Translate with the aid of automation...

Go Native

傑夫 和 Miguel 最近評論了 Java的效能 和 Net的輕便,都沒有提到關鍵的缺點在Java 的argument。

9 年前我第一次充滿幻想的執行Java 。現在,我天天,悲哀的工作就是建立Enterprise Java 程式。我想我應該夠資格與當局談談有關Java 的缺點。兩位原文件的作者提出要求' 解答' 。我認為, 所有軟體都是為End User而作, 並且為開發商提出解決方案。開發者迅速地創造可攜式程式的Toolkit是必要要考慮企業和用戶需要。但Kernel並不簡單, UI 不是可攜的, Programmer的工作是為End User撰寫程式。Developer要克制他們的自尊心和自我為客戶著想,做用戶想要的app 。

對 魚Performance的問題, 有哪些User了解轉換到其他VM的意義? 多少系統admins 知道調整kernel/OS 對Java VM會有一點影響? 我不喜歡告訴管理員和用戶, 他們必須設置記憶和Thread參數讓他們的VM 能使用我寫的app 。Windows3.0 為上百個App解決了記憶體管理問題,這應該就是他成功的原因。虛擬記憶體在Mac OS 8.0是固定的, 但是至少Mac 用戶可以有簡單的方法設置記憶體。調整VM 的記憶和螺紋不是僅有毛病的設計, 它的徵兆是障礙對寬收養。少量用戶將選擇正義工作以OS 代替一個要求熟練粗修得到它正確的app 。

Java 的可攜式的UI,Swing, 不是個解決方案。Java 由開發商迅速採取了, 並且這是選擇語言為企業發展。, 1995 年它被譽為桌面軟體的解決方案, 它仍然是在一些圈子(SUN), 但命名一桌面app 嗎? Limewire 是我曾經看了在一名正常用戶的桌面上的唯一的app, 並且那幾乎不是具有影響力的程式。問題是, 開發商應該做app 滿足終端用戶, 並且我認為用戶rejected Java UI 因為這是不好的時作。CHI 專家主張混合UI 規則嗎? 什麼是可能運行在任一個桌面上app 的真實的好處, 如果用戶必須經常停留考慮什麼他或她必須做做app 做某事? 肯定公司可能交換它的用戶從一個桌面到另一個, 並且app 跑同樣, 但那不是共同。生產力更將下跌因為用戶與電腦談判更多規則當工作。

一般的用戶不交換desktops/OSes 。用戶不需要運作得到處的接口。用戶需要運作與他們的桌面的接口。Mac 用戶是臭名遠揚的為這, 但窗口的用戶感覺同樣方式太-- Java 未成功在或者桌面上。用戶想要apps 表現像其它apps 和戲劇很好與桌面。我不意味神色& 不感覺。看起來像一個聯合桌面app 的Java apps 延遲用戶的失望當他們的老鼠、菜單, 或鍵盤行動不工作如同它做以其它apps 。

微軟和蘋果電腦公司 had/have 非常完全當地捆綁, 但平衡他們無法, 一部分, 因為太陽破壞不依照太陽的計劃的所有Java 實施。我有聽見太陽講話地精Java 為創造解答為它是基於地精的Java 桌面。我不批評太陽-- 搖擺接口對它是完善是當地環境, JavaOS 。我是請與單音VM 。它似乎表現很好以我的Linux OS, 但我肯定它將失敗如果定調選擇成為要求跑app 。至於GTK # 捆綁, hurray! 我GTK # apps 是難區分的從我的其它apps 。我不考慮怎樣他們被做了; 他們運作。

如此對單音開發商我說, 不迷路從您的道路, 因為終端用戶是在您的解答中心。對Java 開發商, 二個詞。去當地人。

星期四, 9月 09, 2004

gladw for win32

WIN2000, SP 4, update fail

VPC用online update,安裝SP4。
結果無法copy autochk.exe和xxx.exe。
選掠過,還是無法安裝,只好放棄。

重新開機後,再online update,又重新安裝SP4,但是他以為我已經裝過了,所以重開機後autochk.exe還是找不到,關機時會出線demodialog.exe無法結束的message。

真差。

sign...

別人要做的事,當然可以說些高調。
要是自己要負責,就不會這樣說了。

How much times will it take ?

要做到XXX,OOO,...
但是
要怎麼作,我也不知道,這是要討論的。
所以
先做,再來改。

...1 week pass...

喔,這個要有XXX。那個要加上OOO。還有要分,,
// 但是,這個有點不可行,因為sss...,而且當初你說....
我的意思是...,就像.....。OK?
// 只有回去翻修

... 1 week pass..

repeat above.

結果,做出來的東西也沒什麼用

Virus

今天(應該是昨天晚上開始)。
PcCilline的畫面又跳出來了。
Server和VPC都中毒了,LOVEGATE。
還好自己的pc沒有(why?)。

VPC的很誇張,重新開機後才scan到的,在share的folder被host scane到,
竟然出現一些rar檔,還很大,就是這些自動產生的rar當有讀。

filename是user.rar, Document.rar... etc。

沒辦法,只有山hd,拿以前的backup hd來run。

第一件事:Update。

Proof - not my fault

搞了這麼久,總以為是我的問題,
用另一個485接著monitor,發現是他的問題。
Monitor Log都正常,但是他卻掉字(1200),多字(19200)。
配合示波器更可以證明。
所以說,用VB的都不太可靠。
VB是快速上手,其他,不要太要求。

竟然是VB,為什麼Option不作多一點?
只是拉一些control到form上而已呀,為什麼寫成這樣?

星期二, 9月 07, 2004

作protocol實在是無聊的事

尤其定protocol的一方有點差的時候,
加上提供的測試軟體有點兩光的時候,
加上定的規格有點嚴的時候。

作protocol真是最無聊的事。

蠢呆了的debug方法

真是蠢呆了的debug方法:
眼睛注意著error number,一但增加就按下print screen鍵,
再用小畫家看內容。

天哪,這還是用VB寫的程式呢。

無法移除...

移除軟體之後,uninstall還是出現,而且無法刪除時

登錄編輯器
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
每一個項目都是「新增/移除」中顯示的軟體,
將無法刪除的item刪除,
就會發現到該項已經刪除了。

星期一, 9月 06, 2004

Conclusion - Testing Modbus

19200的問題似乎是在pc端,因為用另一個程式:Modicon測試沒有問題。
發現Protest又是用VB寫的,
VB的232部分又是問題最多的部分。

沒辦法,只好調整自己的程式來符合Protest。

星期日, 9月 05, 2004

Free Chinese Fontt

王漢宗老師的自由字型

headache ..

昨天早上開始,頭痛。
一直到晚上,開始痛得受不了,
頭靠近眼底,鼻子的地方會痛,
要是以前,衝個熱水澡大概會好,
可是現在是停水期,沒辦法,
只好用熱毛巾喜洗臉,比較好了一點,

大概是感冒了吧,前天晚上在中醫苑裡,冷氣很冷,吹了大概1hrs。
當初還好,可能後還就生病了吧,


所以人從感冒的”發病”大概要一個晚上的時間,
如果這時候吃些Vitamine C,大概就不會感冒了吧。

星期五, 9月 03, 2004

TODOS - today

1. Modify 2.8_1, change name to fullname (hydrogen) -OK
2.Test Modbus 19200
3. Attend meeting with India (New Request) PM 1:00.
(Need to measure each Cell Voltage, Define a property Protocol)
4.write instruction on calibration _7200 AC-detection board. (both ACB & CxU) to chad.

理想與現實的差距

當初都照規定寫了proposle請client確認。
現在做完了,
連”顯示名稱”都不同意:

”當初你們都同意了呀!”
”不然呢?你想到時後再重工嗎”

所以還是改了。

所以說,連最簡單的”顯示名稱”都會改,證明這個proposle根本就沒看。

這個”要客戶確認”這一點,應該是作心安的吧!

那我幹麻花時間寫這個無聊的proposle ?

Digest from Scicape.org
==============================================
哥倫比亞太空梭事故調查委員會年前公布了事故調查報告,美國工程界特別檢討了NASA這一年的所作所為,以及將來的走向。提醒大眾回顧調查報告,不要把教 訓束至腦後。從NASA這一年邁向太空梭復飛的蹣飧舋{上,我們見到一個龐大高科技單位如何誠實的處理工程問題;勇於進行組織文化改造;願意找個第三者進 行監督;不再配合時程一昧的趕工;進行組織內部的溝通(白話文就是願意聽聽低層工程師的意見,聽聽其他部門人員的聲音);當然我們也見到工程師的夢魘,預算永遠不足。在DISCOVERY 頻道的特別節目“歸鄉路:太空返航的挑戰”,NASA的高級工程師講了肺腑之言,大意是太空梭之前飛了百次的成孕羺A一連串的奇蹟蒙蔽了工程師的眼睛,所以沒有注意到潛在的危機。這是一種很令人震驚的反省,想想看不少計劃或不少人是經歷了幾次的失敗,不但沒有痛下針砭檢討改進,反而是期待下一次有奇蹟出現。讓我們期待奇蹟吧。
===================================================

Find the cause of 19200 error

預估原因:
自己的問題
1.TX的問題
1.1 送錯 (資料與送出不一致) => 使用485,在送出時copy content,啟動RX比較
1.2 Timing ? => ?
2.RX的問題
2.1 來不及收 => 在ISR中 Error時Errcount+1,在AI中送出
2.2 RX Error =>每個解開都加入Errot Count,在AI中送出

對方的問題
1. RX的問題
1.1 來不及收 => 加裝監聽port ? 改DMA為Queue?分段傳送

星期四, 9月 02, 2004

Zaurus : C7000, swap file on SD

Site http://home.opaopa.org/zaurus/
===============================
ここ を参考にSD上にスワップを作ります.FATだと不安定だそうなので,ext2 でファイルシステムを作っておきます.

# mkfs.ext2 /mnt/card

あとは,/mnt/card/swapfile を作って,それをスワップに使います.

# cd /mnt/card # dd if=/dev/zero of=swapfile count=32768 # mkswap /mnt/card/swapfile # swapon /mnt/card/swapfile

起動時に swap が有効になるように,/etc/fstab に登録して, /etc/rc.d/init.d/swapも作っておきます.

# vi /etc/fstab /mnt/card/swapfile swap swap defaults 0 0 # cd /etc/rc.d/init.d # vi swap # for i in rc3.d rc4.d rc5.d do cd $i ln -s ../init.d/swap S30swap cd .. done # for i in rc0.d rc6.d do cd $i ln -s ../init.d/swap K70swap cd .. done

ついでに,/dev/mmcda1 のマウントオプションに noatime を追加しました.気休めかもしれませんが….

抜く時は,

# swapoff /mnt/card/swapfile

とするか,

# /etc/rc.d/init.d/swap stop

としてくだしさい.
本当は,ツールバーの SD アイコンと対応させられるといいんですけどね.
===============================
http://www.zaurususergroup.com/
===============================
Can I use a CF or SD card as memory, instead of file storage space?

* Set up a 'swap' file on the card

It is not recommended for normal usage (since writing and rewriting to the same area of flash media will wear it out much more quickly than normal usage), or the faint of heart, but creating a 'swap' file (virtual memory) on a card is possible.

Set up a swap file, and more "memory" will be available for programs. (Just remember to remove the swap file before unmounting and removing the card.)

o Open the 'Terminal'
o Create an empty file for use as swap. For example:

dd if=/dev/zero of=/mnt/cf/SwapFile count=32768

("count" is the size of the file in 512-byte blocks, so 32768 is 16MB. "of" specifies the location of the swapfile. In this case, on the mounted CF card.)

o Turn the blank file into a swap file:

mkswap /mnt/cf/SwapFile

o Activate the swapfile:

swapon /mnt/cf/SwapFile

You can see the swap by checking the available memory. Run the command "free".

To turn off the swapfile (you won't be able to eject the card unless you do this first!!!), run the command:

swapoff /mnt/cf/SwapFile

See also: Increasing virtual memory on your 5000D

Source: Howard R. Abbey, Huge Eaves, Rick Spickelmier

Last updated: 2002.Apr.06

======================================================
http://hpcgi2.nifty.com/gary/wiki.cgi?Zaurus
======================================================
dd if=/dev/zero of=/mnt/card/.swap bs=512 count=65536 #32MのswapをSDに作成
mkswap /mnt/card/.swap
su
swapon /mnt/card/.swap # swap有効
swapoff /mnt/card/.swap # swap無効
======================================================
Site : unknown
=======================================================
Site:PIL
=======================================================
相信在幾位前輩的教導下, 大家的 C700 都已成功開好 swap 了. 但是預設的 swap 是使用 vfat 的檔案格式,因為 fat 較不安定,且讀取較頻繁,所以會減少 sd/cf 卡的壽命及使用時間. 在此建議大家改成 Linux 的原生檔案格式 ext2 會更好哦!!
方法如下:

Code:[Copy to clipboard]

# swapoff /mnt/card/swap
# umount /dev/mmcda1
# mkfs.ext2 /dev/mmcda1
# mount -t ext2 /dev/mmcda1 /mnt/card
# dd if=/dev/zero of=/mnt/card/swap count=20000
# mkswap /mnt/card/swap
# swapon /mnt/card/swap

記得還要將 /etc/sdcontrol 開頭的環境變數改一下:以後就都生效嘍!!

Code:[Copy to clipboard]

#FSTYPE="-t vfat"
FSTYPE="-t ext2"
#FATOPTS="-o noatimei,quiet,umask=000,iocharset=utf8"
FATOPTS="-o rw,noatime"

非常感謝心得分享
我的/etc/sdcontrol 是參考這裡的設定
http://club.h14m.org/kenji/diary/?200302a#200302024
FSTYPE="-t ext2" 這行更新後被拿掉了,系統會自動判斷
FATOPTS="-o noatimei,quiet,umask=000,iocharset=utf8" 這行可保留
FATOPTS="-o rw,noatime" 這行要改成EXT2OPTS="-o rw,noatime"
這些設定已經在1.3的升級中修正,如果已經升級的就無須修改
須注意記憶卡格式化成ext2後Win32平台或數位像機會不能存取
如果打算SD卡插上後不會拔了就可以這樣做

=================================================================
And Here
=================================================================
and

建議 sdcontrol 的檔案中加入一些錯誤檢查, 比較保險!!
並把 swapfile 改為 .swapfile (unix 中的隱藏檔) 可防止誤刪!!

改更如下:



Quote:

#!/bin/sh
#
# sdcontrol 1.0 2001/8/8 21:33:19 (Hideki Hayami)
#
# Initialize or shutdown a SD card device
#
# The first argument should be either 'insert' of 'eject'.
#

ACTION=$1
DEVICE=/dev/mmcda1
MOUNT_POINT=/mnt/card
SMB_MOUNT=/home/samba/SD_Card
INSTALL_DIR=Documents/Install_Files
#FSTYPE="-t vfat"
FATOPTS="-o noatimei,quiet,umask=000,iocharset=utf8"

###### for QPE ######
get_pid()
{
echo $1
}

wait_release()
{
count=1
while true
do
umount $MOUNT_POINT
if [ $? = 0 ]; then
#echo umount >> /tmp/sd
return
fi
echo count=$count >> /tmp/sd
if [ `expr $count \>= 500` = 1 ]; then
#echo time out >> /tmp/sd
return
fi
count=`expr $count + 1`
usleep 200000
done
}

kill_task()
{
ps_line=`ps ax | grep -w 'qpe$'`
qpe_pid=`get_pid $ps_line`
#echo qpe_pid = $qpe_pid >> /tmp/sd
target_pids=`fuser -m $DEVICE | cut -d : -f2`
#echo $target_pids >> /tmp/sd
if [ "$target_pids" = "" ]; then
return
fi
is_exist_qpe=`echo $target_pids | fgrep -w $qpe_pid`
if [ "$is_exist_qpe" = "" ]; then
kill -9 $target_pids
#echo kill -9 $target_pids >> /tmp/sd
else
#echo "found qpe!!!" >> /tmp/sd
target_pids=`echo $target_pids | sed -e "s/$qpe_pid//"`
if [ "$target_pids" != "" ]; then
kill -9 $target_pids
#echo kill -9 $target_pids >> /tmp/sd
fi
wait_release
exit 0
fi
}
###### for QPE ######

case "$ACTION" in
'insert')
mount $FSTYPE $FATOPTS $DEVICE $MOUNT_POINT
MOUNT_RES = `mount | grep $DEVICE`
if [ "$MOUNT_RES" = "" ]; then
mount $FSTYPE $DEVICE $MOUNT_POINT
fi
chkmntsh ${MOUNT_POINT}
if [ -d $SMB_MOUNT ] ; then
rm -rf $SMB_MOUNT
fi
ln -s $MOUNT_POINT $SMB_MOUNT
mkdir -p $MOUNT_POINT/$INSTALL_DIR
#echo mount $? >> /tmp/sd
# for card swap support
if [ -f /mnt/card/.swapfile ]; then
swapon /mnt/card/.swapfile
fi
;;
'eject')
# for card swap support
if [ -f /mnt/card/.swapfile ]; then
/sbin/swapoff /mnt/card/.swapfile
fi

fuser -s -m $DEVICE
if [ $? = 1 ]; then
umount $MOUNT_POINT
rm $SMB_MOUNT
else
exit 1
fi
;;
'compeject')
is_mount=`mount | fgrep $DEVICE`
if [ "$is_mount" = "" ]; then
exit 0
fi
kill_task # for QPE
#fuser -k -m $DEVICE > /dev/null
# for card swap support
if [ -f /mnt/card/.swapfile ]; then
/sbin/swapoff /mnt/card/.swapfile
fi
umount $MOUNT_POINT
if [ $? != 0 ]; then
usleep 500000
umount $MOUNT_POINT
#echo umount $? >> /tmp/sd
#else
# echo umount >> /tmp/sd
fi
rm $SMB_MOUNT
;;
'change')
$0 compeject
$0 insert
;;
'*')
exit 1
;;
esac

exit 0

網誌存檔