心情低落中

March 24, 2008

經過了322的總統大選後,長昌配落選,心情稍稍受了點影響。

還有再加上最近工作很不順,又有很多與工作不相干的事重疊在一起,感覺好累。

或許也跟最近感冒生病有點關係吧!!

反正就是有點憂鬱就是了。

不知道何時才能走出這段不快樂~~~ 

編譯spca5xx的Webcam Driver

September 20, 2006

The command to install these packages is:
Become root:

$ sudo -s

# apt-get install linux-headers-`uname -r` linux-restricted-modules-`uname -r` build-essential gcc-3.4


The linux stuff is installed under /usr/src. So I suggest, you go there:

# cd /usr/src


and move the spca5xx source from your home directory to this location:

# mv ~/spca5xx-20051212.tar.gz .


Unpack it

# tar xfvz spca5xx-20051212.tar.gz


Enter the spca5xx directory

# cd spca5xx-20051212


Workaround to make the Makefile use gcc-3.4
The Makefile which controls the compiling process for this driver has to be told to use gcc-3.4 instead of the default version 4.0:

CC=gcc-3.4
export CC


This sets the environment variable CC, which is used in the spac5xx Makefile to select the compiler.
Setting a link back to the source code (headers)
Furthermore the spca5xx Makefile expect a pointer to the kernel source at a specific location. Let’s create it:

# ln -s /usr/src/linux-headers-`uname -r` /lib/modules/`uname -r`/build


(Note: If you compile a kernel, this link is usually there. But as we use a pre-compiled kernel, we have to cheat.)
Compiling the spca5xx source code

# make


There should be no errors.
Removing the old driver from memory

# modprobe -r spca5xx


Removing the old driver from the hard drive

# rm -rf /lib/modules/`uname -r`/kernel/drivers/usb/media/spca5xx*


Install the new driver

# make install


Load the new driver

# modprobe spca5xx


There should be no errors.

使用 ubuntu 播放 DVD

March 11, 2006

播放 DVD 需要 libdvdcss 套件,但是因為法律問題,Ubuntu/Debian 並
不直接包含該套件。相關資訊可以閱讀 /usr/share/doc/libdvdread3/README.Debian
安裝 libdvdcss 的方法不難,就如該檔案所敘述的,只要執行他提供的 script 就可以了:

$sudo /usr/share/doc/libdvdread3/examples/install-css.sh

就這樣。用 totem 播放就可以了。

this message is from:freesamael

 

裝了mySQL 4.1x之後,中文就會出問題嗎?看這篇教你如何解決!!

March 10, 2006

若你裝了新版的mySQL(for example:mySQL 4.1x),發生了兩種情形;
一個是:phpmyadmin或你的php網頁與mySQL建立連線時,會出現一段錯誤訊息,大致上是說php編譯器的驗證函數無法支援新版的mySQL。
解決方式有二:
1.升級你的php到第五版
2.解決新版 MySQL 4.1 + phpMyAdmin [root]無法登入的問題

另一個你會遇到的問題就是中文出現亂碼,不管是在你的phpmyadmin上的中文字、或是要出現在網頁上的資料庫內容,皆有可能出現亂碼,這是因為新版的mySQL已經支援多國語系了。因此,可以用來解決這個問題的方式有二(參考自mySQL的官網):
1.SET NAMES ‘charset_name’
2.SET CHARACTER SET charset_name

選擇其中一個即可。

There are two statements that affect the connection character sets:

SET NAMES ‘charset_name’
SET CHARACTER SET charset_name

舉個例子吧
mysql_query("SET NAMES ‘big5′");
or
mysql_query("SET NAMES ‘UTF8′");

而除此之外,你可能還得將你的網頁預設的編碼格式修改一下。方法如下:
<meta HTTP-EQUIV="content-type" CONTENT="text/html; charset=UTF-8">

沒錯,就跟你想的一下,只要改charset就行了,通常應該改為BIG5,但UTF-8應該會成為未來的主流,但要選擇那個,就看自己怎麼想囉!!個人還是比較偏好UTF-8,因為,比較有國際觀嘛。

Free Share Space

March 5, 2006

今天發現了一個免費提供網路空間的網站。box.net 這個網站提供使用者 1GigaBytes 的空間,可以用來分享檔案。 它的特色是完全沒有廣告,並且版面編排也相當的好,既美觀又好用。 據說是以AJAX的新網頁技術所打造出來的,我是沒去確認,但功能真的與一般的網頁差很 多。用到現在除了覺得它有點慢及單一檔案不可超過5MegaBytes以外,其他都只有棒能形 容。看到這篇文章的朋友,一定要去申請一個來用看看。

 

Hello world!

March 3, 2006

Welcome to spydogs at Blogsome. This is your first post. Edit or delete it, then start blogging!

An email has been sent to you giving you details how to login to the administration section. From there you can change the design by clicking on the tab MANAGE and then click on the tab THEMES. If you have any questions ask them in the forum. We are only too willing to help.
what time is it??