Home > Archives > 2010年02月17日

2010年02月17日

武市正人の Blog を発見

うちのボスの blog があった!

ということで,武市正人の Blog

きっと興味深い内容に違いない.

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でプレゼンできることを確認出来たので目的の大部分は達した.ページを頻繁に切り替えない限りストレスも無いし.あとはプロジェクタとの相性なのでなんとも.

Home > Archives > 2010年02月17日

Search
Feeds

Page Top