Home > Archives > 2010年02月

2010年02月

EDIDがうまく作れない

displaylink-mod はディスプレイからの EDID が正しく得られないとコケる.例えば,ディスプレイにつながっていないUSB-VGAアダプタを挿すとコケてくれる.これは美味しくない.

ということで, 変な EDID が来たら,1024x768 が最大解像度して認識されるような EDID を使うようにしたかったのだけど… その EDID の作り方が良く分からない.1280x768のをベースに適当に弄ったら上手く動かなかった.こっちが悪いのかプロジェクタが悪いのかはしらんけど.

とりあえずどこかに落ちてた 800x600 の EDID をデフォルトとして使うようにしたら,あと付けで MPro120 でも上手く表示ができるようにはなった.まあ,プレゼンするにはこの解像度でもいいといえばいいのだけど…

どこかに最大解像度が1024x768のディスプレイがあればそこから EDID 抜き出せるんだけどなぁ.

Brother のプリンタをlinuxで使う

http://solutions.brother.co.jp/support/os/linux/cups_printer/install_04.html とか.ドライバが rpm/deb のパッケージで用意されている.x64だと強制インストールだけど…

ソースもあるっぽいので暇になったら眺めてみようかね.

Linux amd64用の Lightning を作る

Linux amd64用の Lightning のバイナリが見つからないので build する.作り方は Getting comm-central Source Code Using Mercurial とか参考にした.

とりあえず準備として必要なものを用意する.autoconf2.13であることが重要だったらしい.別バージョンのautoconfでやったら build に失敗した.

sudo apt-get build-dep sunbird
sudo apt-get build-dep firefox
sudo apt-get install mercurial libasound2-dev libcurl4-openssl-dev libnotify-dev libxt-dev libiw-dev mesa-common-dev autoconf2.13

次にソースを取ってくる.重たい.

mkdir mozilla
cd mozilla
hg clone http://hg.mozilla.org/releases/comm-1.9.1/ src
cd src
python client.py checkout

そして,Sunbird と Lightning をコンパイルするように設定して,コンパイルを走らせる.

echo 'ac_add_options --enable-application=calendar' > .mozconfig 
echo 'mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/objdir-sb-release' >> .mozconfig 
echo 'mk_add_options MOZ_MAKE_FLAGS="-j8"' >> .mozconfig 
echo 'ac_add_options --enable-calendar --disable-official-branding' >> .mozconfig 
make -f client.mk

以上で ./objdir-sb-release/mozilla/dist/xpi-stage/ に lightning.xpi (Lightning本体) と gdata-provider.xpi (Google calendar用) が出来上がるので,両者を Thunderbird 3.0 に読み込んで終了.

今のところ問題なく動いている.

そして外は雪が降っている.

Hardy で Thunderbird 3.0 を使おうかと

PPA for Ubuntu Mozilla Daily Build Team にある APTラインをソフトウェア・ソースに追加:

deb http://ppa.launchpad.net/ubuntu-mozilla-daily/ppa/ubuntu hardy main 
deb-src http://ppa.launchpad.net/ubuntu-mozilla-daily/ppa/ubuntu hardy main

そんで鍵を登録:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 247510BE

あとは適当にインストール:

sudo apt-get update
sudo apt-get install thunderbird-3.0

あとはランチャの起動プログラムを thunderbird から thunderbird-3.0 に変更して終了.

メニューが英語なのをどうにかするには… オフィシャルで日本語版を落とすのが早い気がしてきた.と思って試したけど libdbus あたりの shared library が見つからないとか起こられたので PPA で行くことにした.

Thunderbird で google calendar を

Thunderbird で google calendar を見れると便利かなぁということで,LightningProvider for Google Calendarを入れてみた.

新しいカレンダーの追加で google calendar のフィードを指定すると同期できる.Google calendar のフィードのアドレスは,Google calendar のカレンダーの設定画面で同期したいカレンダーに進み,そこのカレンダーのアドレスのXMLのURLをコピってくる.複数のカレンダーを作ってる場合には全部に対して同じ操作を繰り返す必要がある気がする.ちょいと面倒.

そして今のところ問題なく動いている模様.Thunderbird 3.0から入ったタブを初めて有効に使った気がする.

さて,Hardy に Thunderbird の 3.0 は入るのだろうか?

Netwalker に USBVGA アダプタ付けてみた

使ったUSBVGAアダプタはBUFFALOのGX-DVI/U2で,Displaylinkのチップが入っているのでここらへんのドライバとかが使える.

ということで以下手順メモ.

  1. カーネルモジュールとXのドライバを作る準備.
    sudo apt-get update
    sudo apt-get upgrade
    sudo apt-get install module-assistant
    sudo module-assistant prepare
    sudo apt-get install xorg-dev
    
  2. displaylink-mod作成.Netwalkerのカーネルは古めなのでコンパイルも問題なくできた.
    wget http://projects.unbit.it/downloads/displaylink-mod-0.3.tar.gz
    tar xfvz displaylink-mod-0.3.tar.gz
    cd displaylink
    make
    sudo make install
    sudo depmod -a 
    
    
  3. displaylink-modのテスト.USBVGAアダプタをディスプレイにつないでから,Netwalkerに繋ぐ.手元の環境だと /dev/fb2 が出来た.一面緑になっていればオッケーらしい.そして仮想コンソールを割り当ててみるとちゃんと表示されてくれる.
    sudo apt-get install fbset
    sudo con2fbmap 3 2     # virtual terminal 3 to framebuffer 2
    
    これでCTRL+ALT+F3とかやると仮想コンソールがでる.
  4. Xのドライバ作る.
    wget http://projects.unbit.it/downloads/udlfb-0.2.3_and_xf86-video-displaylink-0.3.tar.gz
    tar xfvz udlfb-0.2.3_and_xf86-video-displaylink-0.3.tar.gz 
    cd xf86-video-displaylink/
    ./configure
    make
    sudo make install
    
  5. /etc/X11/xorg.conf を書き換える.Using an external monitor with a Sharp Netwalker を参考に適当にファイルのパスとか解像度とか追加.書き換えたら再起動.失敗しても,/etec/X11/xorg.conf を空にすれば普通に起動できるので安心.
    #### xorg.conf for netwalker with dislaylink
    Section "Files"
     ModulePath "/usr/lib/xorg/modules"
     ModulePath "/usr/local/lib/xorg/modules"
    EndSection
     
    Section "Device"
     Identifier "Configured Video Device"
    EndSection
     
    Section "Monitor"
     Identifier "Configured Monitor"
    EndSection
     
    Section "Screen"
     Identifier "Default Screen"
     Monitor "Configured Monitor"
     Device "Configured Video Device"
    EndSection
     
    Section "ServerFlags"
     Option "DontZap" "False"
    EndSection
     
    ### for USB-VGA ###
     
    Section "Device"
     Identifier "Device[DLUSBVGA]"
     VendorName "Device Vendor"
     BoardName "Device Vendor"
     Driver "displaylink"
     Option "fbdev" "/dev/fb2"
    EndSection
     
    Section "Monitor"
     Identifier "Monitor[DLUSBVGA]"
     VendorName "Monitor Vendor"
     ModelName "Monitor Model"
     VertRefresh 50-76
     HorizSync 30-90
    EndSection
     
     
    Section "Screen"
     Identifier "Screen[DLUSBVGA]"
     Device "Device[DLUSBVGA]"
     Monitor "Monitor[DLUSBVGA]"
     DefaultDepth 16
     SubSection "Display"
      Depth 16
      Modes "1280x1024" "1024x768" "800x600" "640x480"
     EndSubSection
     SubSection "Display"
      Depth 8
      Modes "1280x1024" "1024x768" "800x600" "640x480"
     EndSubSection
     SubSection "Display"
      Depth 24
      Modes "1280x1024" "1024x768" "800x600" "640x480"
     EndSubSection
    EndSection
     
    Section "ServerLayout"
     Identifier "Default Layout"
     Screen 0 "Default Screen"
     Screen 1 "Screen[DLUSBVGA]" RightOf "Default Screen"
    EndSection
     
    #### end of xorg.conf
     
    
  6. 使う.アダプタ付けたらCTRL+ALT+BACKSPACEでX再起動してやると右に画面ができる.アダプタ外したらX再起動して画面なくす.今のところ1280x1024のディスプレイで接続成功した.でも3Mの超小型プロジェクタMPro120では上手くいかない… dmesg で見る限り最大画面サイズ(1280x768)の認識まで出来てるけど緑の画面が表示されず画面の一番下に白いラインが出た状態になるだけ.3Mのロゴがでてないので何らかの信号がプロジェクタに伝わっているようだけど謎.動的に解像度を変える仕組みでも入れていろいろ試さないと良く分からない.

そして別々のXサーバになってるので物事の移動が面倒.DMX(Distributed Multihead X)とかやりゃいいのかもしれないけど.xrandrって複数のXサーバをまとめるとかできるのかなぁ.とりあえずディスプレイ指定して物事を起動するスクリプトを用意してお茶を濁す.

#!/bin/bash
DISPLAY=:0.1 $*

とりあえず外部ディスプレイ上ではOOoでプレゼンできることを確認出来たので目的の大部分は達した.ページを頻繁に切り替えない限りストレスも無いし.あとはプロジェクタとの相性なのでなんとも.

コンパイルできないなぁ

Netwalker から画面出力したいなぁと思って DisplayLink のドライバ(displaylink-mod)をコンパイルしようとしたのだけど… drm_edid.h のエラーでコンパイルがこけた.付属の drm_edid.h 使えば良いらしいけどカーネルソースの drm_edid.h だとこける.なぜ?

Home > Archives > 2010年02月

Search
Feeds

Page Top