<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
    <title>SheevaPlug / 玄柴（KURO-SHEEVA)をハックしよう</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/" />
    <link rel="self" type="application/atom+xml" href="http://www.yamasita.jp/sheevaplug/atom.xml" />
    <id>tag:www.yamasita.jp,2009-09-15:/sheevaplug//12</id>
    <updated>2011-04-14T14:23:38Z</updated>
    
    <generator uri="http://www.sixapart.com/movabletype/">Movable Type Pro 5.02</generator>

<entry>
    <title>お出かけ用モバイルルータ</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/04/post-84.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2228</id>

    <published>2011-04-14T14:10:07Z</published>
    <updated>2011-04-14T14:23:38Z</updated>

    <summary> オープンソースカンファレンス 2011 Kansai @ Kobe 用に、お出...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="SheevaPlug" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[<a href="http://www.ospn.jp/osc2011-kobe/">
オープンソースカンファレンス 2011 Kansai @ Kobe</a>
用に、お出かけ用モバイルルータを組み立てた。
<p>
<a href="/sheevaplug/2011/04/110414_1l.jpg" target="_blank">
<img src="/sheevaplug/2011/04/110414_1s.jpg"></a>
<p>
OSC では、出展者用に無線LANが提供されるのだが、
IT系イベントにはPocketWiFiなどモバイルルータがたくさん持ち込まれ
数少ない無線LANのチャンネルが一杯になってしまい、
まともに使えないことを何度も経験している。
<p>
そのようなトラブルを避けるために、
ブースの各機器を有線LAN経由でインターネットに接続できるようにするため。
<p>
これまでは、
<a href="http://www.yamasita.jp/sheevaplug/2010/10/-kof2010-gadget1.html">
ハンガーネットに括り付けて壁に架けていた</a>のだが、
今回の OSC では壁がないので、かつ気楽に持って歩けるよう
105円ショップで買ったハンドル付きのケースに納めた。
<p>
ケースのふたを開けると、、、
<p>
<a href="/sheevaplug/2011/04/110414_2l.jpg" target="_blank">
<img src="/sheevaplug/2011/04/110414_2s.jpg"></a>
何か写真が変
<p>
中に入っているのは、、、
<p>
<a href="/sheevaplug/2011/04/110414_3l.jpg" target="_blank">
<img src="/sheevaplug/2011/04/110414_3s.jpg"></a>
やっぱりデジカメ変
<p>
一番左の白いのが SheevaPlug<br>
上の基板むき出しのが Lafonera の中身。そのままではハンドルつきのケース
に収まらなかったので、中身だけを入れることにした。
<p>
中央の白い四角いのが今回のヒット。
<p>
<a href="/sheevaplug/2011/04/110414_4l.jpg" target="_blank">
<img src="/sheevaplug/2011/04/110414_4s.jpg"></a>
<p>
Logtec の LAN-SW05N/PSW。<br>
<a href="http://a.r10.to/hBnwRY">楽天市場</a> 
<a href="http://www.amazon.co.jp/gp/product/B004QQ1L52/ref=as_li_tf_tl?ie=UTF8&tag=hack0c-22&linkCode=as2&camp=247&creative=1211&creativeASIN=B004QQ1L52">Amazon</a><img src="http://www.assoc-amazon.jp/e/ir?t=hack0c-22&l=as2&o=9&a=B004QQ1L52" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" />
<p>
4cm × 3cm ほどの USB 給電専用 5ポート SW-HUB である。<br>
見たことがないぐらい小さく、AC アダプタも付いていないので、
安価でもある。
<p>
<a href="/sheevaplug/2011/04/110414_5l.jpg" target="_blank">
<img src="/sheevaplug/2011/04/110414_5s.jpg"></a>
<p>
その他、USB コネクタが長くて、SheevaPlug に直接刺すと
ハンドル付きケースに収まらなかったので、
105円ショップで買った方向転換アダプタで直角に曲げるとか、、<br>
<p>
<a href="/sheevaplug/2011/04/110414_6l.jpg" target="_blank">
<img src="/sheevaplug/2011/04/110414_6s.jpg"></a>
<p>
10cm の LAN ケーブルとか、、、
<p>
いろいろワザが詰まっている
<p>
<a href="http://www.ospn.jp/osc2011-kobe/">
オープンソースカンファレンス 2011 Kansai @ Kobe</a>
に持っていきますので、
実物をご覧になりたい方はブースまでおこしください。<br>
出展テーマは「LinkStation をハックしよう」で、
メインの展示物は LinkStation ですが、、、
]]>
        
    </content>
</entry>

<entry>
    <title>レンガからの脱出</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/post-83.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2218</id>

    <published>2011-02-12T12:00:00Z</published>
    <updated>2011-02-07T14:30:43Z</updated>

    <summary>flash に書いたカーネルから起動しなくなったので、 次は tftp boot...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[flash に書いたカーネルから起動しなくなったので、
次は tftp boot。もう後がなひ

<h2>uImage の準備</h2>
tftp サーバの LS-GL で uImage を準備する
<pre>
yasunari@ude:~$ cd /srv/tftp/
yasunari@ude:/srv/tftp$ unzip /mnt/SheevaPlug/cd_1.2b/SheevaPlug_USB-Recovery1.2.zip
Archive:  /mnt/SheevaPlug/cd_1.2b/SheevaPlug_USB-Recovery1.2.zip
  inflating: USB_Recovery/flashware.img
  inflating: USB_Recovery/u-boot-rd88f6281Sheevaplug_400db_nand.bin
  inflating: USB_Recovery/uImage.sheeva.040309
yasunari@ude:/srv/tftp$ mkdir SheevaPlug_1.2
yasunari@ude:/srv/tftp$ mv USB_Recovery/uImage.sheeva.040309 !$
mv USB_Recovery/uImage.sheeva.040309 SheevaPlug_1.2
yasunari@ude:/srv/tftp$ rm -fr USB_Recovery
yasunari@ude:/srv/tftp$ ln SheevaPlug_1.2/uImage.sheeva.040309 .
yasunari@ude:/srv/tftp$
</pre>

<h2>tftp boot の設定</h2>
SheevaPlug Development Kit - Writing Jaunty Filesystem on the NAND flash-Rev1.2.pdf
を参考に、環境変数を設定する。
mtdparts の設定は、
SheevaPlug Development Kit - Writing Jaunty Filesystem on the NAND flash-Rev1.2.pdf
とは異なる。
<pre>
Marvell>> set ipaddr 192.168.2.89
Marvell>> set serverip 192.168.2.38
Marvell>> set rootpath '/home/rootfsv1.0'
Marvell>> set image_name uImage.sheeva.040309
Marvell>> set console 'console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs)'
Marvell>> set bootargs_root 'root=/dev/nfs rw'
Marvell>> set bootcmd 'tftpboot 0x2000000 $(image_name);setenv bootargs $(console) $(bootargs_root) nfsroot=$(serverip):$(rootpath) ip=$(ipaddr):$(serverip)$(bootargs_end); bootm 0x2000000'
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>> 
</pre>

<h2>再起動</h2>
<pre>
Marvell>> reset
	:
USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0
Using egiga0 device
TFTP from server 192.168.2.38; our IP address is 192.168.2.89
Filename 'uImage.sheeva.040309'.
Load address: 0x2000000
Loading: #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         ###############
done
Bytes transferred = 2070316 (1f972c hex)
## Booting image at 02000000 ...
   Image Name:   Linux-2.6.22.18
   Created:      2009-04-04   1:49:44 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2070252 Bytes =  2 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux.................................................................................................................................. done, booting the kernel.

</pre>
やっぱりここで止った。
uImage.sheeva.040309 ではだめなのか？？

<h2>2.6.37 の uImage</h2>
2.6.37 の uImage でも試してみる
<p>
tftp サーバの LS-GL で uImage をダウンロード
<pre>
yasunari@ude:/srv/tftp$ rm uImage.sheeva.040309
yasunari@ude:/srv/tftp$ cd SheevaPlug_1.2/
yasunari@ude:/srv/tftp/SheevaPlug_1.2$ wget http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-uImage
--2011-02-06 21:29:34--  http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-uImage
Resolving sheeva.with-linux.com... 216.146.103.100, 2001:470:b:3e:250:43ff:fe01:c1bd
Connecting to sheeva.with-linux.com|216.146.103.100|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2773928 (2.6M) [application/octet-stream]
Saving to: `sheeva-2.6.37-uImage'

100%[======================================>] 2,773,928   50.8K/s   in 66s

2011-02-06 21:30:44 (40.8 KB/s) - `sheeva-2.6.37-uImage' saved [2773928/2773928]

yasunari@ude:/srv/tftp/SheevaPlug_1.2$
</pre>
玄柴側ではそれを指定してブート
<pre>
Marvell>> set image_name sheeva-2.6.37-uImage
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>> reset

         __  __                      _ _
        |  \/  | __ _ _ ____   _____| | |
        | |\/| |/ _` | '__\ \ / / _ \ | |
        | |  | | (_| | |   \ V /  __/ | |
        |_|  |_|\__,_|_|    \_/ \___|_|_|
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_
| | | |___|  _ \ / _ \ / _ \| __|
| |_| |___| |_) | (_) | (_) | |_
 \___/    |____/ \___/ \___/ \__|
 ** MARVELL BOARD: SHEEVA PLUG LE

U-Boot 1.1.4 (Sep  7 2009 - 20:21:09) Marvell version: 3.4.16

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 006CEE60

Soc: 88F6281 A0 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 256MB
DRAM CS[1] base 0x10000000   size 256MB
DRAM Total size 512MB  16bit width
Flash:  0 kB
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:512 MB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0
Using egiga0 device
TFTP from server 192.168.2.38; our IP address is 192.168.2.89
Filename 'sheeva-2.6.37-uImage'.
Load address: 0x2000000
Loading: #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         ######################
done
Bytes transferred = 2773928 (2a53a8 hex)
## Booting image at 02000000 ...
   Image Name:   Linux-2.6.37
   Created:      2011-01-23   5:39:39 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2773864 Bytes =  2.6 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
Linux version 2.6.37 (kelly@speedy) (gcc version 4.5.2 (PlugComputer G++ 20110117) ) #3 PREEMPT Sat Jan 22 22:39:36 MST 2011
CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=00053177
CPU: VIVT data cache, VIVT instruction cache
Machine: Marvell eSATA SheevaPlug Reference Board
Memory policy: ECC disabled, Data cache writeback
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 130048
Kernel command line: console=ttyS0,115200 mtdparts=nand_mtd:0x100000@0(uboot)ro,0x0@0x100000(uImage),0x1ff00000@0x100000(rootfs)rw root=/dev/nfs rw nfsroot=192.168.2.38:/home/rootfsv1.0 ip=192.168.2.89:192.168.2.38:::DB88FXX81:eth0:none
PID hash table entries: 2048 (order: 1, 8192 bytes)
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
Memory: 512MB = 512MB total
Memory: 513288k/513288k available, 11000k reserved, 0K highmem
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
    DMA     : 0xffc00000 - 0xffe00000   (   2 MB)
    vmalloc : 0xe0800000 - 0xfe800000   ( 480 MB)
    lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)
    modules : 0xbf000000 - 0xc0000000   (  16 MB)
      .init : 0xc0008000 - 0xc0030000   ( 160 kB)
      .text : 0xc0030000 - 0xc0550620   (5250 kB)
      .data : 0xc0552000 - 0xc0584080   ( 201 kB)
SLUB: Genslabs=13, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Preemptable hierarchical RCU implementation.
        RCU-based detection of stalled CPUs is disabled.
        Verbose stalled-CPUs detection is disabled.
NR_IRQS:114
Console: colour dummy device 80x30
Calibrating delay loop... 1192.75 BogoMIPS (lpj=5963776)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
NET: Registered protocol family 16
Kirkwood: MV88F6281-A0, TCLK=200000000.
Feroceon L2: Enabling L2
Feroceon L2: Cache support initialised.
bio: create slab <bio-0> at 0
vgaarb: loaded
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
Switching to clocksource orion_clocksource
FS-Cache: Loaded
NET: Registered protocol family 2
IP route cache hash table entries: 4096 (order: 2, 16384 bytes)
TCP established hash table entries: 16384 (order: 5, 131072 bytes)
TCP bind hash table entries: 16384 (order: 4, 65536 bytes)
TCP: Hash tables configured (established 16384 bind 16384)
TCP reno registered
UDP hash table entries: 256 (order: 0, 4096 bytes)
UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
NET: Registered protocol family 1
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
FS-Cache: Netfs 'nfs' registered for caching
JFFS2 version 2.2. (NAND) 息 2001-2006 Red Hat, Inc.
JFS: nTxBlock = 4010, nTxLock = 32080
msgmni has been set to 1002
io scheduler noop registered
io scheduler deadline registered
io scheduler cfq registered (default)
Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A
console [ttyS0] enabled
brd: module loaded
loop: module loaded
NAND device: Manufacturer ID: 0xec, Chip ID: 0xdc (Samsung )
Scanning device for bad blocks
mtd: partition size too small (0)
Creating 3 MTD partitions on "orion_nand":
0x000000000000-0x000000100000 : "u-boot"
0x000000100000-0x000000500000 : "uImage"
0x000000500000-0x000020000000 : "root"
MV-643xx 10/100/1000 ethernet driver version 1.4
mv643xx_eth smi: probed
net eth0: port 0 with MAC address 00:50:43:01:44:96
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
orion-ehci orion-ehci.0: Marvell Orion EHCI
orion-ehci orion-ehci.0: new USB bus registered, assigned bus number 1
orion-ehci orion-ehci.0: irq 19, io mem 0xf1050000
orion-ehci orion-ehci.0: USB 2.0 started, EHCI 1.00
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
usbcore: registered new interface driver ums-datafab
usbcore: registered new interface driver ums-freecom
usbcore: registered new interface driver ums-jumpshot
usbcore: registered new interface driver ums-sddr09
usbcore: registered new interface driver ums-sddr55
mice: PS/2 mouse device common for all mice
rtc-mv rtc-mv: rtc core: registered rtc-mv as rtc0
i2c /dev entries driver
cpuidle: using governor ladder
cpuidle: using governor menu
mv_xor_shared mv_xor_shared.0: Marvell shared XOR driver
mv_xor_shared mv_xor_shared.1: Marvell shared XOR driver
mv_xor mv_xor.0: Marvell XOR: ( xor cpy )
mv_xor mv_xor.1: Marvell XOR: ( xor fill cpy )
mv_xor mv_xor.2: Marvell XOR: ( xor cpy )
mv_xor mv_xor.3: Marvell XOR: ( xor fill cpy )
sdhci: Secure Digital Host Controller Interface driver
sdhci: Copyright(c) Pierre Ossman
mmc0: mvsdio driver initialized, using GPIO 47 for card detection
usbcore: registered new interface driver usbhid
usbhid: USB HID core driver
oprofile: hardware counters not available
oprofile: using timer interrupt.
TCP cubic registered
NET: Registered protocol family 17
lib80211: common routines for IEEE802.11 drivers
Registering the dns_resolver key type
registered taskstats version 1
rtc-mv rtc-mv: setting system clock to 2011-02-06 21:34:51 UTC (1297028091)
IP-Config: Guessing netmask 255.255.255.0
IP-Config: Complete:
     device=eth0, addr=192.168.2.89, mask=255.255.255.0, gw=255.255.255.255,
     host=DB88FXX81, domain=, nis-domain=(none),
     bootserver=192.168.2.38, rootserver=192.168.2.38, rootpath=
eth0: link up, 1000 Mb/s, full duplex, flow control disabled
VFS: Unable to mount root fs via NFS, trying floppy.
VFS: Cannot open root device "nfs" or unknown-block(2,0)
Please append a correct "root=" boot option; here are the available partitions:
1f00            1024 mtdblock0  (driver?)
1f01            4096 mtdblock1  (driver?)
1f02          519168 mtdblock2  (driver?)
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
[<c00355d0>] (unwind_backtrace+0x0/0xe0) from [<c0408298>] (panic+0x58/0x17c)
[<c0408298>] (panic+0x58/0x17c) from [<c0008d98>] (mount_block_root+0x1bc/0x1fc)
[<c0008d98>] (mount_block_root+0x1bc/0x1fc) from [<c0008f70>] (mount_root+0xa0/0xc0)
[<c0008f70>] (mount_root+0xa0/0xc0) from [<c00090f4>] (prepare_namespace+0x164/0x1b8)
[<c00090f4>] (prepare_namespace+0x164/0x1b8) from [<c00089f0>] (kernel_init+0x10c/0x14c)
[<c00089f0>] (kernel_init+0x10c/0x14c) from [<c0031494>] (kernel_thread_exit+0x0/0x8)
</pre>
こっちは、tftp boot するけど、NFS root で panic する

<h2>別の uImage</h2>
1.0 の uImage でも試す
<p>
tftp サーバの LS-GL で。
<pre>
ude:/srv/tftp# unzip /mnt/SheevaPlug/cd/SheevaPlug_LSP.zip
Archive:  /mnt/SheevaPlug/cd/SheevaPlug_LSP.zip
   creating: Image/
  inflating: Image/uImage.sheeva.20090319
   creating: Sources/
  inflating: Sources/linux-2.6.22.18.tar.bz2
ude:/srv/tftp# mv Image/uImage.sheeva.20090319 SheevaPlu
ude:/srv/tftp# rm -fr Sources/
ude:/srv/tftp# mv Image/ SheevaPlug_1.0
ude:/srv/tftp#
</pre>

玄柴でそれを指定
<pre>
Marvell>> set image_name uImage.sheeva.20090319
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>> reset
	:
	:
Starting kernel ...

Uncompressing Linux.................................................................................................................................... done, booting the kernel.

</pre>
やっぱりここで止る。

<h2>とりあえずレンガからの脱出</h2>
カーネルは sheeva-2.6.37-uImage を tftp boot<br>
ファイルシステムは flash で起動する。

<pre>
Marvell>> set image_name sheeva-2.6.37-uImage
Marvell>> set bootcmd 'tftpboot 0x2000000 $(image_name); setenv bootargs rootfstype=jffs2 console=ttyS0,115200 mtdparts=orion_nand:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 ip=$(ipaddr):$(serverip)$(bootargs_end); bootm 0x2000000'
Marvell>> savenv
Unknown command 'savenv' - try 'help'
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>> reset
	:
	:
Ubuntu jaunty (development branch) debian ttyS0

debian login: root
Password:
Last login: Sun Feb  6 20:26:12 UTC 2011 on ttyS0
Linux debian 2.6.37 #3 PREEMPT Sat Jan 22 22:39:36 MST 2011 armv5tel

The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.

To access official Ubuntu documentation, please visit:
http://help.ubuntu.com/
root@debian:~#
</pre>
起動した。<br>
Flash のカーネルを更新する。
<pre>
root@debian:~# bash -x README-2.6.37 --nandkernel
+ set -e
	:
	:
Writing data to block 220000
Writing data to block 240000
Writing data to block 260000
Writing data to block 280000
Writing data to block 2a0000
root@debian:~# head -20 README-2.6.37
#! /bin/bash
#
# Sheeva kernel install
# This README can be used to flash the new kernel
# Watch out for erase/flash errors
# If errors are encountered you should redo the flash
#
# This is a mainline Linux Kernel and you must set
# the mainlineLinux and arcNumber env variables in U-Boot
# and change the bootargs for a successful boot.
#
# setenv mainlineLinux yes
# Do one of the following three
# setenv arcNumber 2097 # for standard sheevaplugs
# setenv arcNumber 2678 # for e-sata sheevaplugs
# setenv arcNumber 2659 # for guruplugs
####### change bootargs, replace nand_mtd with orion_nand and add rootfstype=jffs2
# setenv bootargs rootfstype=jffs2 console=ttyS0,115200 mtdparts=orion_nand:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=192.168.1.9:192.168.1.4:192.168.1.4:255.255.255.0:DB88FXX81:eth0:none
# saveenv

root@debian:~# reboot
	:
	:
USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0
Marvell>> setenv mainlineLinux yes
Marvell>> setenv arcNumber 2678
Marvell>> setenv bootargs rootfstype=jffs2 console=ttyS0,115200 mtdparts=orion_nand:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=192.168.1.9:192.168.1.4:192.168.1.4:255.255.255.0:DB88FXX81:eth0:none
Marvell>> set bootcmd 'nand read.e 0x800000 0x100000 0x400000; bootm 0x800000'
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>> printenv
baudrate=115200
loads_echo=0
netmask=255.255.0.0
CASset=min
MALLOC_len=1
ethprime=egiga0
ethmtu=1500
usb0Mode=host
nandEcc=1bit
ethact=egiga0
cesvcid=ULULULULULULPPULULULULULDA
bootargs_end=:::DB88FXX81:eth0:none
standalone=fsload 0x2000000 $(image_name);setenv bootargs $(console) root=/dev/mtdblock0 rw ip=$(ipaddr):$(serverip)$(bootargs_end) $(mvPhoneConfig); bootm 0x2000000;
mvPhoneConfig=mv_phone_config=dev0:fxs,dev1:fxs
mvNetConfig=mv_net_config=(00:11:88:0f:62:81,0:1:2:3),mtu=1500
yuk_ethaddr=00:00:00:EE:51:81
netretry=no
rcvrip=169.254.100.100
loadaddr=0x02000000
autoload=no
run_diag=no
ethaddr=00:50:43:01:44:96
ipaddr=192.168.2.89
serverip=192.168.2.38
rootpath=/home/rootfsv1.0
bootargs_root=root=/dev/nfs rw
image_name=sheeva-2.6.37-uImage
arcNumber=2678
stdin=serial
stdout=serial
stderr=serial
console=console=ttyS0,115200 mtdparts=nand_mtd:0x100000@0(uboot)ro,0x0@0x100000(uImage),0x1ff00000@0x100000(rootfs)rw
mainlineLinux=yes
enaMonExt=no
enaCpuStream=no
enaWrAllo=no
pexMode=RC
disL2Cache=no
setL2CacheWT=yes
disL2Prefetch=yes
enaICPref=yes
enaDCPref=yes
sata_dma_mode=yes
netbsd_en=no
vxworks_en=no
bootdelay=3
disaMvPnp=no
enaAutoRecovery=yes
bootargs=rootfstype=jffs2 console=ttyS0,115200 mtdparts=orion_nand:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 ip=192.168.2.89:192.168.2.38:::DB88FXX81:eth0:none
bootcmd=nand read.e 0x800000 0x100000 0x400000; bootm 0x800000

Environment size: 1427/131068 bytes
Marvell>> reset
	:
	:

Ubuntu jaunty (development branch) debian ttyS0

debian login: root
Password:
Last login: Mon Feb  7 23:06:18 UTC 2011 on ttyS0
Linux debian 2.6.37 #3 PREEMPT Sat Jan 22 22:39:36 MST 2011 armv5tel

The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.

To access official Ubuntu documentation, please visit:
http://help.ubuntu.com/
root@debian:~#
</pre>
ふー。とりあえずレンガからは脱出
]]>
        
    </content>
</entry>

<entry>
    <title>カーネルを戻す</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/post-82.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2217</id>

    <published>2011-02-11T12:00:00Z</published>
    <updated>2011-02-06T12:06:26Z</updated>

    <summary>NFS root でブートしようとしたら、ブートしてこなかった。 カーネルを戻す...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[NFS root でブートしようとしたら、ブートしてこなかった。<br>
カーネルを戻す

<h3>uImage の入手</h3>
ftp で宅内のファイルサーバから SheevaPlug_USB-Recovery1.2.zip を
入手する
<pre>
root@debian:~# ftp ude.yamasita.jp
-bash: ftp: command not found
root@debian:~# apt-get install ftp
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libx11-data libxcb1 libxau6 libxdmcp6 libxcb-xlib0 libx11-6
Use 'apt-get autoremove' to remove them.
The following NEW packages will be installed:
  ftp
0 upgraded, 1 newly installed, 0 to remove and 103 not upgraded.
Need to get 56.3kB of archives.
After this operation, 168kB of additional disk space will be used.
Get:1 http://ports.ubuntu.com jaunty/main ftp 0.17-18 [56.3kB]
Fetched 56.3kB in 1s (33.8kB/s)
Selecting previously deselected package ftp.
(Reading database ... 10329 files and directories currently installed.)
Unpacking ftp (from .../archives/ftp_0.17-18_armel.deb) ...
Setting up ftp (0.17-18) ...

root@debian:~# ftp ude.yamasita.jp
ftp: ude.yamasita.jp: Host name lookup failure
ftp> bye
root@debian:~# ftp 192.168.2.38
Connected to 192.168.2.38.
220 ude FTP server (GNU inetutils 1.5) ready.
Name (192.168.2.38:root): yasunari
331 Password required for yasunari.
Password:
230- Linux ude 2.6.16.16-arm1 #37 Tue May 20 10:01:57 JST 2008 armv5tejl
230-
230- The programs included with the Debian GNU/Linux system are free software;
230- the exact distribution terms for each program are described in the
230- individual files in /usr/share/doc/*/copyright.
230-
230- Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
230- permitted by applicable law.
230 User yasunari logged in.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> cd /mnt/SheevaPlug/cd_1.2b/
250 CWD command successful.
ftp> bin
200 Type set to I.
ftp> hash
Hash mark printing on (1024 bytes/hash mark).
ftp> get SheevaPlug_USB-Recovery1.2.zip
local: SheevaPlug_USB-Recovery1.2.zip remote: SheevaPlug_USB-Recovery1.2.zip
200 PORT command sucessful.
150 Opening BINARY mode data connection for 'SheevaPlug_USB-Recovery1.2.zip' (72864326 bytes).
################################################################################
	:
	:
####################################
226 Transfer complete.
72864326 bytes received in 88.16 secs (807.1 kB/s)
ftp> bye
221 Goodbye.
root@debian:~# unzip SheevaPlug_USB-Recovery1.2.zip
Archive:  SheevaPlug_USB-Recovery1.2.zip
  inflating: USB_Recovery/flashware.img
  inflating: USB_Recovery/u-boot-rd88f6281Sheevaplug_400db_nand.bin
  inflating: USB_Recovery/uImage.sheeva.040309
root@debian:~#
</pre>

<h3>uImage を flash に焼く</h3>
失敗すると再起不能に、、、
<pre>
root@debian:~# flash_eraseall -j /dev/mtd0
Erasing 128 Kibyte @ 3e0000 -- 96 % complete. Cleanmarker written at 3e0000.
root@debian:~# nandwrite -pm /dev/mtd0 USB_Recovery/uImage.sheeva.040309
Writing data to block 0
Writing data to block 20000
Writing data to block 40000
Writing data to block 60000
Writing data to block 80000
Writing data to block a0000
Writing data to block c0000
Writing data to block e0000
Writing data to block 100000
Writing data to block 120000
Writing data to block 140000
Writing data to block 160000
Writing data to block 180000
Writing data to block 1a0000
Writing data to block 1c0000
Writing data to block 1e0000
root@debian:~#
</pre>

<h3>再起動</h3>
<pre>
root@debian:~# reboot
root@debian:~#
Broadcast message from root@debian
        (/dev/ttyS0) at 20:43 ...
	:
	:
USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0
Marvell>>
</pre>

<h3>戻したカーネルで起動</h3>

<pre>
Marvell>> set bootargs console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=$(ipaddr):$(serverip):$(serverip):255.255.255.0:DB88FXX81:eth0:none
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>> reset
	:
	:
Starting kernel ...

Uncompressing Linux.................................................................................................................................. done, booting the kernel.
</pre>
ここで止った。
どんどん深みには待っているような気がする。

<h3>環境変数を戻す</h3>
再度 U-Boot のプロンプトに入り
<pre>
Marvell>> setenv arcNumber
Marvell>> setenv mainlineLinux no
Marvell>> printenv
baudrate=115200
loads_echo=0
rootpath=/mnt/ARM_FS/
netmask=255.255.0.0
CASset=min
MALLOC_len=1
ethprime=egiga0
bootargs_root=root=/dev/mtdblock2 ro
ethmtu=1500
usb0Mode=host
nandEcc=1bit
ethact=egiga0
cesvcid=ULULULULULULPPULULULULULDA
bootargs_end=:::DB88FXX81:eth0:none
image_name=uImage
standalone=fsload 0x2000000 $(image_name);setenv bootargs $(console) root=/dev/mtdblock0 rw ip=$(ipaddr):$(serverip)$(bootargs_end) $(mvPhoneConfig); bootm 0x2000000;
mvPhoneConfig=mv_phone_config=dev0:fxs,dev1:fxs
mvNetConfig=mv_net_config=(00:11:88:0f:62:81,0:1:2:3),mtu=1500
yuk_ethaddr=00:00:00:EE:51:81
netretry=no
rcvrip=169.254.100.100
loadaddr=0x02000000
autoload=no
run_diag=no
bootcmd=nand read.e 0x800000 0x100000 0x400000; bootm 0x800000
ethaddr=00:50:43:01:44:96
serverip=192.168.2.38
ipaddr=192.168.2.89
bootargs=console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=192.168.2.89:192.168.2.38:192.168.2.38:255.255.255.0:DB88FXX81:eth0:none
stdin=serial
stdout=serial
stderr=serial
console=console=ttyS0,115200 mtdparts=nand_mtd:0x100000@0(uboot)ro,0x0@0x100000(uImage),0x1ff00000@0x100000(rootfs)rw
enaMonExt=no
enaCpuStream=no
enaWrAllo=no
pexMode=RC
disL2Cache=no
setL2CacheWT=yes
disL2Prefetch=yes
enaICPref=yes
enaDCPref=yes
sata_dma_mode=yes
netbsd_en=no
vxworks_en=no
bootdelay=3
disaMvPnp=no
enaAutoRecovery=yes
mainlineLinux=no

Environment size: 1408/131068 bytes
Marvell>>
</pre>
これでもう一回再起動

<pre>
Marvell>> reset
	:
	:
Uncompressing Linux.................................................................................................................................. done, booting the kernel.
</pre>
とまった。
<p>
どんどん深みにハマっていく。楽し！]]>
        
    </content>
</entry>

<entry>
    <title>Squeeze のインストール（３）root fs の入れ換え</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/squeeze-root-fs.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2216</id>

    <published>2011-02-10T12:00:00Z</published>
    <updated>2011-02-06T05:04:09Z</updated>

    <summary>Debian GNU/Linux 6.0 (Squeeze) が正式リリースされ...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[Debian GNU/Linux 6.0 (Squeeze) が正式リリースされたので、
<a href="http://www.debian.org/releases/stable/armel/apds03.html.ja">
D.3. Unix/Linux システムからの Debian GNU/Linux のインストール</a>
にしたがって、
玄柴に Squeeze をインストールする。
<p>
D.3.2. debootstrap のインストール<br>
D.3.3. debootstrap の実行<br>
D.3.4. 基本システムの設定<br>
までが終わったので、いよいよ /mnt/debinst を / に移す。
<p>
と言っても動いているシステムに cp するわけにも行かず、
NFS ブートして移す。

<h2>NFS root でブート</h2>
先日の通り
<pre>
Marvell>> set bootargs console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/nfs rw nfsroot=$(serverip):/srv/nfs/rootfsv1.0 ip=$(ipaddr):$(serverip)$(bootargs_end)
Marvell>> printenv
baudrate=115200
loads_echo=0
rootpath=/mnt/ARM_FS/
netmask=255.255.0.0
CASset=min
MALLOC_len=1
ethprime=egiga0
bootargs_root=root=/dev/mtdblock2 ro
ethmtu=1500
usb0Mode=host
nandEcc=1bit
ethact=egiga0
cesvcid=ULULULULULULPPULULULULULDA
bootargs_end=:::DB88FXX81:eth0:none
image_name=uImage
standalone=fsload 0x2000000 $(image_name);setenv bootargs $(console) root=/dev/mtdblock0 rw ip=$(ipaddr):$(serverip)$(bootargs_end) $(mvPhoneConfig); bootm 0x2000000;
mvPhoneConfig=mv_phone_config=dev0:fxs,dev1:fxs
mvNetConfig=mv_net_config=(00:11:88:0f:62:81,0:1:2:3),mtu=1500
yuk_ethaddr=00:00:00:EE:51:81
netretry=no
rcvrip=169.254.100.100
loadaddr=0x02000000
autoload=no
run_diag=no
bootcmd=nand read.e 0x800000 0x100000 0x400000; bootm 0x800000
ethaddr=00:50:43:01:44:96
serverip=192.168.2.38
ipaddr=192.168.2.89
arcNumber=2678
stdin=serial
stdout=serial
stderr=serial
console=console=ttyS0,115200 mtdparts=nand_mtd:0x100000@0(uboot)ro,0x0@0x100000(uImage),0x1ff00000@0x100000(rootfs)rw
mainlineLinux=yes
enaMonExt=no
enaCpuStream=no
enaWrAllo=no
pexMode=RC
disL2Cache=no
setL2CacheWT=yes
disL2Prefetch=yes
enaICPref=yes
enaDCPref=yes
sata_dma_mode=yes
netbsd_en=no
vxworks_en=no
bootdelay=3
disaMvPnp=no
enaAutoRecovery=yes
bootargs=console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/nfs rw nfsroot=192.168.2.38:/srv/nfs/rootfsv1.0 ip=192.168.2.89:192.168.2.38:::DB88FXX81:eth0:none

Environment size: 1434/131068 bytes
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>> reset
	:
TCP cubic registered
NET: Registered protocol family 17
lib80211: common routines for IEEE802.11 drivers
Registering the dns_resolver key type
registered taskstats version 1
rtc-mv rtc-mv: setting system clock to 2011-02-06 13:57:56 UTC (1297000676)
IP-Config: Guessing netmask 255.255.255.0
IP-Config: Complete:
     device=eth0, addr=192.168.2.89, mask=255.255.255.0, gw=255.255.255.255,
     host=DB88FXX81, domain=, nis-domain=(none),
     bootserver=192.168.2.38, rootserver=192.168.2.38, rootpath=
eth0: link up, 1000 Mb/s, full duplex, flow control disabled
VFS: Unable to mount root fs via NFS, trying floppy.
VFS: Cannot open root device "nfs" or unknown-block(2,0)
Please append a correct "root=" boot option; here are the available partitions:
1f00            4096 mtdblock0  (driver?)
1f01          519168 mtdblock1  (driver?)
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
[<c00355d0>] (unwind_backtrace+0x0/0xe0) from [<c0408298>] (panic+0x58/0x17c)
[<c0408298>] (panic+0x58/0x17c) from [<c0008d98>] (mount_block_root+0x1bc/0x1fc)
[<c0008d98>] (mount_block_root+0x1bc/0x1fc) from [<c0008f70>] (mount_root+0xa0/0xc0)
[<c0008f70>] (mount_root+0xa0/0xc0) from [<c00090f4>] (prepare_namespace+0x164/0x1b8)
[<c00090f4>] (prepare_namespace+0x164/0x1b8) from [<c00089f0>] (kernel_init+0x10c/0x14c)
[<c00089f0>] (kernel_init+0x10c/0x14c) from [<c0031494>] (kernel_thread_exit+0x0/0x8)

</pre>
ぐぉー。<br>
カーネル入れ換えたからか（泣
]]>
        
    </content>
</entry>

<entry>
    <title>Squeeze のインストール（２）基本システムの設定</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/squeeze.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2215</id>

    <published>2011-02-09T12:00:00Z</published>
    <updated>2011-02-06T04:42:37Z</updated>

    <summary>Debian GNU/Linux 6.0 (Squeeze) が正式リリースされ...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[Debian GNU/Linux 6.0 (Squeeze) が正式リリースされたので、
<a href="http://www.debian.org/releases/stable/armel/apds03.html.ja">
D.3. Unix/Linux システムからの Debian GNU/Linux のインストール</a>
にしたがって、
玄柴に Squeeze をインストールする。
<p>
D.3.2. debootstrap のインストール<br>
D.3.3. debootstrap の実行<br>
迄が終わったので、次は、<br>


<h2>D.3.4. 基本システムの設定</h2>

<h3>chroot</h3>
<pre>
root@debian:/# LANG=C chroot /mnt/debinst /bin/bash
root@debian:/# ls
bin   dev  home  media  opt   root  selinux  sys  usr
boot  etc  lib   mnt    proc  sbin  srv      tmp  var
root@debian:/# cat etc/debian_version
6.0
root@debian:/#
</pre>
出たり入ったりするのでしょうけど、、、

<h3>D.3.4.1. デバイスファイルの作成</h3>
これも良くわかってない。<br>
パス。

<h3>D.3.4.2. パーティションのマウント</h3>
早速ジェイルを抜けて
標準ファームの Ubuntu の fstab を参考にする。
<pre>
root@debian:/# exit
exit
root@debian:/# cat /mnt/debinst/etc/fstab
# UNCONFIGURED FSTAB FOR BASE SYSTEM
root@debian:/# cat /etc/fstab
# UNCONFIGURED FSTAB FOR BASE SYSTEM
tmpfs /lib/init/rw tmpfs rw,nosuid,mode=0755 0 0
/proc /proc proc rw,noexec,nosuid,nodev 0 0
sysfs /sys sysfs rw,noexec,nosuid,nodev 0 0
varrun /var/run tmpfs rw,nosuid,mode=0755 0 0
varlock /var/lock tmpfs rw,noexec,nosuid,nodev,mode=1777 0 0
udev /dev tmpfs rw,mode=0755 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev 0 0
devpts /dev/pts devpts rw,noexec,nosuid,gid=5,mode=620 0 0
rootfs / rootfs rw 0 0
tmpfs   /var/cache/apt  tmpfs   defaults,noatime
root@debian:/#
</pre>
コピーしてしまう。
<pre>
root@debian:/# ls -l /mnt/debinst/etc/fstab
-rw-r--r-- 1 root root 37 Feb  6 12:00 /mnt/debinst/etc/fstab
root@debian:/# cp /etc/fstab /mnt/debinst/etc/fstab
root@debian:/# !ls
ls -l /mnt/debinst/etc/fstab
-rw-r--r-- 1 root root 488 Feb  6 13:00 /mnt/debinst/etc/fstab
root@debian:/# 
</pre>
若干修正
<pre>
root@debian:/# vi !$
	:
	:
root@debian:/# cat /mnt/debinst/etc/fstab
# UNCONFIGURED FSTAB FOR BASE SYSTEM
/proc /proc proc rw,noexec,nosuid,nodev 0 0
sysfs /sys sysfs rw,noexec,nosuid,nodev 0 0
udev /dev tmpfs rw,mode=0755 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev 0 0
devpts /dev/pts devpts rw,noexec,nosuid,gid=5,mode=620 0 0
rootfs / rootfs rw 0 0
root@debian:/#
</pre>

<h3>D.3.4.3. タイムゾーンの設定</h3>
<pre>
root@debian:/# !LANG
LANG=C chroot /mnt/debinst /bin/bash
root@debian:/# cat /etc/default/rcS
#
# /etc/default/rcS
#
# Default settings for the scripts in /etc/rcS.d/
#
# For information about these variables see the rcS(5) manual page.
#
# This file belongs to the "initscripts" package.

TMPTIME=0
SULOGIN=no
DELAYLOGIN=no
UTC=yes
VERBOSE=no
FSCKFIX=no
RAMRUN=no
RAMLOCK=no
root@debian:/#
</pre>
UTC=no に変える。
<pre>
root@debian:/# vi /etc/default/rcS
	:
	:
</pre>

続いて、tzdata の reconfigure
<pre>
root@debian:/# dpkg-reconfigure tzdata

Package configuration
  敖陳陳陳陳陳陳陳陳陳陳陳陳 潅onfiguring tzdata 団陳陳陳陳陳陳陳陳陳陳陳陳朕
   覚lease select the geographic area in which you live. Subsequent
  崖 configuration questions will narrow this down by presenting a list of
  崖 cities, representing the time zones in which they are located.
  崖
  崖 Geographic area:
  崖
  崖                              Arctic
  崖                             Asia                                       嘘
                                 Atlantic                                  嘘
                                 Europe                                    嘘
                                 Indian        霸                          嘘
                                 Pacific       霸                          嘘
                                 柮ystemV                                  嘘
                                 US                                        朿
                                 嬰tc
  崖
  崖
  崖                   &lt;Ok&gt;                       &lt;Cancel&gt;
  崖
  垣陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳潰

</pre>
Asia を選んで、
<pre>

Package configuration
     敖陳陳陳陳陳陳陳陳陳陳陳 潅onfiguring tzdata 団陳陳陳陳陳陳陳陳陳陳陳
     審 Please select the city or region corresponding to your time zone.
     崖
     崖 Time zone:
     崖
     崖                         Seoul
                               較hanghai                                 嘘
                               較ingapore                                嘘
                               郭aipei                                   嘘
                               郭ashkent                                 嘘
                               郭bilisi                                  嘘
                               郭ehran                                   嘘
                               郭el_Aviv                                 嘘
                               郭himphu                                  朿
                                Tokyo                                    嘘
                                Ujung_Pandang
     崖
     崖
     崖                 &lt;Ok&gt;                     &lt;Cancel&gt;
     崖
     垣陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳

</pre>
Tokyo を選ぶ
<pre>

Current default time zone: 'Asia/Tokyo'
Local time is now:      Sun Feb  6 22:04:23 JST 2011.
Universal Time is now:  Sun Feb  6 13:04:23 UTC 2011.

root@debian:/#
</pre>

<h3>D.3.4.4. ネットワークの設定</h3>
<h4>/etc/network/interfaces</h4>
<pre>
root@debian:/# vi /etc/network/interfaces
root@debian:/# cat !$
cat /etc/network/interfaces
######################################################################
# /etc/network/interfaces -- configuration file for ifup(8), ifdown(8)
# See the interfaces(5) manpage for information on what options are
# available.
######################################################################

# We always want the loopback interface.
#
auto lo
iface lo inet loopback

# To use dhcp:
#
# auto eth0
# iface eth0 inet dhcp

# An example static IP setup: (broadcast and gateway are optional)
#
auto eth0
iface eth0 inet static
        address 192.168.2.89
        network 192.168.2.0
        netmask 255.255.255.0
        broadcast 192.168.2.255
        gateway 192.168.2.1
root@debian:/#
</pre>

<h4>/etc/resolv.conf</h4>
<pre>
root@debian:/# vi /etc/resolv.conf
	:
	:
root@debian:/# cat !$
cat /etc/resolv.conf
domain yamasita.jp
search yamasita.jp
nameserver 192.168.2.39
root@debian:/#
</pre>

<h4>/etc/hostname</h4>
<pre>
root@debian:/# cat /etc/hostname
debian
root@debian:/# echo ks2 > !$
echo ks2 > /etc/hostname
root@debian:/# !cat
cat /etc/hostname
ks2
root@debian:/#
</pre>

<h4>/etc/hosts</h4>
<pre>
root@debian:/# cat /etc/hosts
127.0.0.1       localhost
::1             localhost ip6-localhost ip6-loopback
fe00::0         ip6-localnet
ff00::0         ip6-mcastprefix
ff02::1         ip6-allnodes
ff02::2         ip6-allrouters

root@debian:/# echo "192.168.2.98       ks2" >> /etc/hosts
root@debian:/# !cat
cat /etc/hosts
127.0.0.1       localhost
::1             localhost ip6-localhost ip6-loopback
fe00::0         ip6-localnet
ff00::0         ip6-mcastprefix
ff02::1         ip6-allnodes
ff02::2         ip6-allrouters

192.168.2.98    ks2
root@debian:/#
</pre>

<h3>D.3.4.5. apt の設定</h3>
<pre>
root@debian:/# cat /etc/apt/sources.list
deb http://ftp.us.debian.org/debian squeeze main
root@debian:/# vi !$
	:
	:
root@debian:/# cat !$
cat /etc/apt/sources.list
deb http://ftp.us.debian.org/debian squeeze main

deb http://security.debian.org/ squeeze/updates main
deb-src http://security.debian.org/ squeeze/updates main
root@debian:/# apt-get update
Get:1 http://ftp.us.debian.org squeeze Release.gpg [1671 B]
Ign http://ftp.us.debian.org/debian/ squeeze/main Translation-en
Hit http://ftp.us.debian.org squeeze Release
Hit http://ftp.us.debian.org squeeze/main armel Packages
Get:2 http://security.debian.org squeeze/updates Release.gpg [835 B]
Ign http://security.debian.org/ squeeze/updates/main Translation-en
Get:3 http://security.debian.org squeeze/updates Release [38.4 kB]
Get:4 http://security.debian.org squeeze/updates/main Sources [8026 B]
Get:5 http://security.debian.org squeeze/updates/main armel Packages [40.8 kB]
Fetched 89.7 kB in 3s (23.3 kB/s)
Reading package lists... Done
root@debian:/#
</pre>

<h3>D.3.4.6. ロケールとキーボードの設定</h3>
<h4>locales のインストール</h4>
<pre>
root@debian:/# apt-get install locales
Reading package lists... Done
Building dependency tree... Done
The following NEW packages will be installed:
  locales
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 4757 kB of archives.
After this operation, 13.1 MB of additional disk space will be used.
Get:1 http://ftp.us.debian.org/debian/ squeeze/main locales all 2.11.2-10 [4757 kB]
Fetched 4757 kB in 6s (745 kB/s)
Preconfiguring packages ...
Can not write log, openpty() failed (/dev/pts not mounted?)
Selecting previously deselected package locales.
(Reading database ... 8459 files and directories currently installed.)
Unpacking locales (from .../locales_2.11.2-10_all.deb) ...
Processing triggers for man-db ...
Can not write log, openpty() failed (/dev/pts not mounted?)
Setting up locales (2.11.2-10) ...
Generating locales (this might take a while)...
Generation complete.
root@debian:/#

</pre>

<h4>locales の reconfigure</h4>
日本語のロケールをインストールして、
デフォルトを None にする（漢
<pre>
root@debian:/# dpkg-reconfigure locales

Package configuration
 敖陳陳陳陳陳陳陳陳陳陳陳陳調 Configuring locales 団陳陳陳陳陳陳陳陳陳陳陳陳朕
  殻ocales are a framework to switch between multiple languages and allow
 崖 users to use their language, country, characters, collation order, etc.
 崖
 崖 Please choose which locales to generate. UTF-8 locales should be chosen
 崖 by default, particularly for new installations. Other character sets may
 崖 be useful for backwards compatibility with older systems and software.
 崖
 崖 Locales to be generated:
 崖
 崖      ]iw_IL ISO-8859-8
     額 ] iw_IL.UTF-8 UTF-8                                                 嘘
     額*] ja_JP.EUC-JP EUC-JP                                               朿
     額*] ja_JP.UTF-8 UTF-8                                                 嘘
     額 ] ka_GE GEORGIAN-PS                                                 嘘
     額 ] ka_GE.UTF-8 UTF-8
 崖
 崖
 崖                    &lt;Ok&gt;                        &lt;Cancel&gt;
 崖
 垣陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳潰

Package configuration

 敖陳陳陳陳陳陳陳陳陳陳陳陳調 Configuring locales 団陳陳陳陳陳陳陳陳陳陳陳陳朕
  獲any packages in Debian use locales to display text in the correct
 崖 language for the user. You can choose a default locale for the system
 崖 from the generated locales.
 崖
 崖 This will select the default language for the entire system. If this
 崖 system is a multi-user system where not all users are able to speak the
 崖 default language, they will experience difficulties.
 崖
 崖 Default locale for the system environment:
 崖
 崖                               None
 崖                               ja_JP.EUC-JP
 崖                               ja_JP.UTF-8
 崖
 崖
 崖                    &lt;Ok&gt;                        &lt;Cancel&gt;
 崖
 垣陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳陳潰


Generating locales (this might take a while)...
  ja_JP.EUC-JP...cannot map archive header: Invalid argument
 done
  ja_JP.UTF-8...cannot map archive header: Invalid argument
 done
Generation complete.
root@debian:/#
</pre>

<h3>D.3.5. カーネルのインストール</h3>
これはドキュメント通りではなく、
Ubuntu 側からコピーする。
<pre>
root@debian:/# exit
exit
root@debian:/# cd /
root@debian:/# tar cf - boot/sheeva-2.6.37-System.map |(cd /mnt/debinst/; tar xv
f -)
boot/sheeva-2.6.37-System.map
root@debian:/# tar cf - lib/modules/2.6.37 |(cd /mnt/debinst/; tar xvf -)
lib/modules/2.6.37/
lib/modules/2.6.37/build
lib/modules/2.6.37/modules.isapnpmap
	:
	:
lib/modules/2.6.37/modules.symbols.bin
lib/modules/2.6.37/modules.dep
lib/modules/2.6.37/modules.seriomap
root@debian:/#

</pre>

<h3>D.3.6. ブートローダのセットアップ</h3>
これも要らない

<h3>その他</h3>
<h4>inittab</h4>
<pre>
root@debian:/# tty
/dev/ttyS0
root@debian:/# grep ttyS0 /mnt/debinst/etc/inittab
#T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100
root@debian:/#
</pre>
/dev/ttyS0 で getty が動いていない他、/etc/inittab を修正する。
<pre>
root@debian:/# vi /mnt/debinst/etc/inittab
	:
	:
root@debian:/# cat /mnt/debinst/etc/inittab
# /etc/inittab: init(8) configuration.
# $Id: inittab,v 1.91 2002/01/25 13:35:21 miquels Exp $

# The default runlevel.
id:2:initdefault:

# Boot-time system configuration/initialization script.
# This is run first except when booting in emergency (-b) mode.
si::sysinit:/etc/init.d/rcS

# What to do in single-user mode.
~~:S:wait:/sbin/sulogin

# /etc/init.d executes the S and K scripts upon change
# of runlevel.
#
# Runlevel 0 is halt.
# Runlevel 1 is single-user.
# Runlevels 2-5 are multi-user.
# Runlevel 6 is reboot.

l0:0:wait:/etc/init.d/rc 0
l1:1:wait:/etc/init.d/rc 1
l2:2:wait:/etc/init.d/rc 2
l3:3:wait:/etc/init.d/rc 3
l4:4:wait:/etc/init.d/rc 4
l5:5:wait:/etc/init.d/rc 5
l6:6:wait:/etc/init.d/rc 6
# Normally not reached, but fallthrough in case of emergency.
z6:6:respawn:/sbin/sulogin

# What to do when CTRL-ALT-DEL is pressed.
ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now

# Action on special keypress (ALT-UpArrow).
#kb::kbrequest:/bin/echo "Keyboard Request--edit /etc/inittab to let this work."

# What to do when the power fails/returns.
pf::powerwait:/etc/init.d/powerfail start
pn::powerfailnow:/etc/init.d/powerfail now
po::powerokwait:/etc/init.d/powerfail stop

# /sbin/getty invocations for the runlevels.
#
# The "id" field MUST be the same as the last
# characters of the device (after "tty").
#
# Format:
#  <id>:<runlevels>:<action>:<process>
#
# Note that on most Debian systems tty7 is used by the X Window System,
# so if you want to add more getty's go ahead but skip tty7 if you run X.
#
#1:2345:respawn:/sbin/getty 38400 tty1
#2:23:respawn:/sbin/getty 38400 tty2
#3:23:respawn:/sbin/getty 38400 tty3
#4:23:respawn:/sbin/getty 38400 tty4
#5:23:respawn:/sbin/getty 38400 tty5
#6:23:respawn:/sbin/getty 38400 tty6

# Example how to put a getty on a serial line (for a terminal)
#
#T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100
#T1:23:respawn:/sbin/getty -L ttyS1 9600 vt100
T0:2345:respawn:/sbin/getty -L ttyS0 115200 vt100

# Example how to put a getty on a modem line.
#
#T3:23:respawn:/sbin/mgetty -x0 -s 57600 ttyS3

root@debian:/#
</pre>

<h4>root にパスワードをつける</h4>
<pre>
root@debian:/# grep root /etc/shadow
root:*:15011:0:99999:7:::
root@debian:/# passwd root
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
root@debian:/#
</pre>

<h4>掃除</h4>
<pre>
root@debian:/# apt-get clean
root@debian:/#
</pre>

こんなところか、、、
]]>
        
    </content>
</entry>

<entry>
    <title>Squeeze のインストール（１）debootstrap</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/squeeze-debootstrap.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2214</id>

    <published>2011-02-08T12:00:00Z</published>
    <updated>2011-02-06T03:53:21Z</updated>

    <summary>下準備をしている間に Debian GNU/Linux 6.0 (Squeeze...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[下準備をしている間に
Debian GNU/Linux 6.0 (Squeeze) が正式リリースされたので、
<a href="http://www.debian.org/releases/stable/armel/apds03.html.ja">
D.3. Unix/Linux システムからの Debian GNU/Linux のインストール</a>
にしたがって、
玄柴に Squeeze をインストールする。
<p>
まずは、debootstrap でディレクトリツリーを作るところから。

<h2>D.3.2. debootstrap のインストール</h2>
<h3>wget と ar の確認</h3>
<pre>
root@debian:~# which wget
/usr/bin/wget
root@debian:~# which ar
root@debian:~#
</pre>
ar がないので、binutils をインストールする。
<pre>
root@debian:~# apt-get install binutils
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libx11-data libxcb1 libxau6 libxdmcp6 libxcb-xlib0 libx11-6
Use 'apt-get autoremove' to remove them.
Suggested packages:
  binutils-doc
The following NEW packages will be installed:
  binutils
0 upgraded, 1 newly installed, 0 to remove and 103 not upgraded.
Need to get 1410kB of archives.
After this operation, 7864kB of additional disk space will be used.
Get:1 http://ports.ubuntu.com jaunty/main binutils 2.19.1-0ubuntu3 [1410kB]
Fetched 1410kB in 3s (385kB/s)
Selecting previously deselected package binutils.
(Reading database ... 10244 files and directories currently installed.)
Unpacking binutils (from .../binutils_2.19.1-0ubuntu3_armel.deb) ...
Setting up binutils (2.19.1-0ubuntu3) ...

Processing triggers for libc6 ...
ldconfig deferred processing now taking place
root@debian:~# which ar
/usr/bin/ar
root@debian:~#
</pre>

<h3>debootstrap の入手</h3>
<pre>
root@debian:~# mkdir work
root@debian:~# cd work
root@debian:~/work# wget http://ftp.debian.org/debian/pool/main/d/debootstrap/debootstrap_1.0.26_all.deb
--2011-02-06 11:45:57--  http://ftp.debian.org/debian/pool/main/d/debootstrap/debootstrap_1.0.26_all.deb
Resolving ftp.debian.org... failed: Name or service not known.
wget: unable to resolve host address `ftp.debian.org'
root@debian:~/work# cat /etc/resolv.conf
domain yamasita.jp
search yamasita.jp
nameserver 127.0.0.1
root@debian:~/work# echo nameserver 192.168.2.39 >> !$
echo nameserver 192.168.2.39 >> /etc/resolv.conf
root@debian:~/work# !wget
wget http://ftp.debian.org/debian/pool/main/d/debootstrap/debootstrap_1.0.26_all.deb
--2011-02-06 11:46:24--  http://ftp.debian.org/debian/pool/main/d/debootstrap/debootstrap_1.0.26_all.deb
Resolving ftp.debian.org... 130.89.149.226, 2001:610:1908:a000::149:226
Connecting to ftp.debian.org|130.89.149.226|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 58232 (57K) [application/x-debian-package]
Saving to: `debootstrap_1.0.26_all.deb'

100%[======================================>] 58,232      51.3K/s   in 1.1s

2011-02-06 11:46:26 (51.3 KB/s) - `debootstrap_1.0.26_all.deb' saved [58232/58232]

root@debian:~/work#
</pre>

<h3>debootstrap の展開</h3>
<pre>
root@debian:~/work# ar -x debootstrap_1.0.26_all.deb
root@debian:~/work# ls
control.tar.gz  data.tar.gz  debian-binary  debootstrap_1.0.26_all.deb
root@debian:~/work# cd /
root@debian:/# tar zxvf /root/work/data.tar.gz
./
./usr/
./usr/sbin/
./usr/sbin/debootstrap
./usr/share/
./usr/share/man/
./usr/share/man/man8/
	:
	:
./usr/share/debootstrap/scripts/testing
./usr/share/debootstrap/scripts/maverick
./usr/share/debootstrap/scripts/unstable
./usr/share/debootstrap/scripts/hardy
root@debian:/#
</pre>

<h2>D.3.3. debootstrap の実行</h2>
<pre>
root@debian:/# date ; /usr/sbin/debootstrap --arch armel squeeze  /mnt/debinst http://ftp.us.debian.org/debian ; date
Sun Feb  6 11:50:37 UTC 2011
I: Retrieving Release
I: Retrieving Packages
	:
	:
I: Configuring libept1...
I: Configuring apt-utils...
I: Configuring aptitude...
I: Configuring tasksel-data...
I: Configuring tasksel...
I: Base system installed successfully.
Sun Feb  6 12:03:29 UTC 2011
root@debian:/#
</pre>
13分ほど。速い
]]>
        
    </content>
</entry>

<entry>
    <title>カーネルのアップデート</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/post-81.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2213</id>

    <published>2011-02-07T12:00:00Z</published>
    <updated>2011-02-06T02:26:54Z</updated>

    <summary>次はカーネルのアップデート。 インストーラの入手 http://sheeva.w...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[次はカーネルのアップデート。

<h2>インストーラの入手</h2>

<a href="http://sheeva.with-linux.com/sheeva/">
http://sheeva.with-linux.com/sheeva/</a>から
<a href="http://sheeva.with-linux.com/sheeva/README-2.6.37">
README-2.6.37</a>をいただいてくる。
<pre>
root@debian:~# wget http://sheeva.with-linux.com/sheeva/README-2.6.37
-bash: wget: command not found
root@debian:~#
</pre>
wget がない。インストールする。

<pre>
root@debian:~# apt-get install wget
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libx11-data libxcb1 libxau6 libxdmcp6 libxcb-xlib0 libx11-6
Use 'apt-get autoremove' to remove them.
The following NEW packages will be installed:
  wget
0 upgraded, 1 newly installed, 0 to remove and 13 not upgraded.
Need to get 244kB of archives.
After this operation, 1970kB of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
  wget
Install these packages without verification [y/N]? y
Get:1 http://ports.ubuntu.com jaunty/main wget 1.11.4-2ubuntu1 [244kB]
Fetched 244kB in 2s (96.2kB/s)
Selecting previously deselected package wget.
(Reading database ... 10231 files and directories currently installed.)
Unpacking wget (from .../wget_1.11.4-2ubuntu1_armel.deb) ...
Setting up wget (1.11.4-2ubuntu1) ...

root@debian:~#
</pre>
もう一回、
<a href="http://sheeva.with-linux.com/sheeva/README-2.6.37">
README-2.6.37</a>をいただいてくる。
<pre>
root@debian:~# !wget
wget http://sheeva.with-linux.com/sheeva/README-2.6.37
--2011-02-06 11:01:35--  http://sheeva.with-linux.com/sheeva/README-2.6.37
Resolving sheeva.with-linux.com... failed: Name or service not known.
wget: unable to resolve host address `sheeva.with-linux.com'
root@debian:~#
</pre>
ぐは。全然設定できていないし。
<p>
/etc/resolv.conf を設定する
<pre>
root@debian:~# cat /etc/resolv.conf
domain yamasita.jp
search yamasita.jp
nameserver 127.0.0.1
root@debian:~#
</pre>
何で、DHCP で nameserver がとれてない？<br>
手動で追加する。
<pre>
root@debian:~# echo nameserver 192.168.2.39 >> !$
echo nameserver 192.168.2.39 >> /etc/resolv.conf
root@debian:~# cat !$
cat /etc/resolv.conf
domain yamasita.jp
search yamasita.jp
nameserver 127.0.0.1
nameserver 192.168.2.39
root@debian:~#
</pre>
もう一回 wget
<pre>
root@debian:~# !wget
wget http://sheeva.with-linux.com/sheeva/README-2.6.37
--2011-02-06 11:03:36--  http://sheeva.with-linux.com/sheeva/README-2.6.37
Resolving sheeva.with-linux.com... 216.146.103.100, 2001:470:b:3e:250:43ff:fe01:c1bd
Connecting to sheeva.with-linux.com|216.146.103.100|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 3965 (3.9K) [text/plain]
Saving to: `README-2.6.37'

100%[======================================>] 3,965       --.-K/s   in 0.05s

2011-02-06 11:03:37 (78.1 KB/s) - `README-2.6.37' saved [3965/3965]

root@debian:~#
</pre>
ようやく、できた。

<h2>インストーラの実行</h2>
README-2.6.37 を実行！する
<pre>
root@debian:~# sh -x README-2.6.37 --nandkernel
+ set -e
+ set -u
+ KVer=2.6.37
README-2.6.37: 32: Syntax error: "(" unexpected
root@debian:~# ls -l /bin/sh
lrwxrwxrwx 1 1010 1011 4 Mar 18  2009 /bin/sh -> dash
root@debian:~#
</pre>
おっと、bash じゃないといけないんだった。
<pre>
root@debian:~# bash -x README-2.6.37 --nandkernel
+ set -e
+ set -u
+ KVer=2.6.37
+ [[ 1 &lt; 1 ]]
+ [[ --nandkernel == \-\-\n\a\n\d\k\e\r\n\e\l ]]
+ Download
+ echo 'Downloading files'
Downloading files
+ local f=
+ for f in Modules.tar.gz Modules.tar.gz.md5 uImage uImage.md5 System.map
+ [[ ! -f sheeva-2.6.37-Modules.tar.gz ]]
++ which wget
+ [[ -z /usr/bin/wget ]]
+ local 'sites=http://dev.plugapps.com/with-linux http://sheeva.with-linux.com/sheeva'
+ local s=
+ for s in '$sites'
+ wget -c http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-Modules.tar.gz
--2011-02-06 11:06:53--  http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-Modules.tar.gz
Resolving dev.plugapps.com... 216.24.193.251
Connecting to dev.plugapps.com|216.24.193.251|:80... failed: Connection refused.
+ for s in '$sites'
+ wget -c http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-Modules.tar.gz
--2011-02-06 11:06:54--  http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-Modules.tar.gz
Resolving sheeva.with-linux.com... 216.146.103.100, 2001:470:b:3e:250:43ff:fe01:c1bd
Connecting to sheeva.with-linux.com|216.146.103.100|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 5652312 (5.4M) [application/x-tar]
Saving to: `sheeva-2.6.37-Modules.tar.gz'

100%[======================================>] 5,652,312   46.9K/s   in 2m 17s

2011-02-06 11:09:13 (40.2 KB/s) - `sheeva-2.6.37-Modules.tar.gz' saved [5652312/5652312]

+ break
+ [[ ! -f sheeva-2.6.37-Modules.tar.gz ]]
+ for f in Modules.tar.gz Modules.tar.gz.md5 uImage uImage.md5 System.map
+ [[ ! -f sheeva-2.6.37-Modules.tar.gz.md5 ]]
++ which wget
+ [[ -z /usr/bin/wget ]]
+ local 'sites=http://dev.plugapps.com/with-linux http://sheeva.with-linux.com/sheeva'
+ local s=
+ for s in '$sites'
+ wget -c http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-Modules.tar.gz.md5
--2011-02-06 11:09:13--  http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-Modules.tar.gz.md5
Resolving dev.plugapps.com... 216.24.193.251
Connecting to dev.plugapps.com|216.24.193.251|:80... failed: Connection refused.
+ for s in '$sites'
+ wget -c http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-Modules.tar.gz.md5
--2011-02-06 11:09:13--  http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-Modules.tar.gz.md5
Resolving sheeva.with-linux.com... 216.146.103.100, 2001:470:b:3e:250:43ff:fe01:c1bd
Connecting to sheeva.with-linux.com|216.146.103.100|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 63 [text/plain]
Saving to: `sheeva-2.6.37-Modules.tar.gz.md5'

100%[======================================>] 63          --.-K/s   in 0s

2011-02-06 11:09:13 (1.85 MB/s) - `sheeva-2.6.37-Modules.tar.gz.md5' saved [63/63]

+ break
+ [[ ! -f sheeva-2.6.37-Modules.tar.gz.md5 ]]
+ for f in Modules.tar.gz Modules.tar.gz.md5 uImage uImage.md5 System.map
+ [[ ! -f sheeva-2.6.37-uImage ]]
++ which wget
+ [[ -z /usr/bin/wget ]]
+ local 'sites=http://dev.plugapps.com/with-linux http://sheeva.with-linux.com/sheeva'
+ local s=
+ for s in '$sites'
+ wget -c http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-uImage
--2011-02-06 11:09:13--  http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-uImage
Resolving dev.plugapps.com... 216.24.193.251
Connecting to dev.plugapps.com|216.24.193.251|:80... failed: Connection refused.
+ for s in '$sites'
+ wget -c http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-uImage
--2011-02-06 11:09:13--  http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-uImage
Resolving sheeva.with-linux.com... 216.146.103.100, 2001:470:b:3e:250:43ff:fe01:c1bd
Connecting to sheeva.with-linux.com|216.146.103.100|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2773928 (2.6M) [application/octet-stream]
Saving to: `sheeva-2.6.37-uImage'

100%[======================================>] 2,773,928   52.7K/s   in 59s

2011-02-06 11:10:13 (46.2 KB/s) - `sheeva-2.6.37-uImage' saved [2773928/2773928]

+ break
+ [[ ! -f sheeva-2.6.37-uImage ]]
+ for f in Modules.tar.gz Modules.tar.gz.md5 uImage uImage.md5 System.map
+ [[ ! -f sheeva-2.6.37-uImage.md5 ]]
++ which wget
+ [[ -z /usr/bin/wget ]]
+ local 'sites=http://dev.plugapps.com/with-linux http://sheeva.with-linux.com/sheeva'
+ local s=
+ for s in '$sites'
+ wget -c http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-uImage.md5
--2011-02-06 11:10:13--  http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-uImage.md5
Resolving dev.plugapps.com... 216.24.193.251
Connecting to dev.plugapps.com|216.24.193.251|:80... failed: Connection refused.
+ for s in '$sites'
+ wget -c http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-uImage.md5
--2011-02-06 11:10:13--  http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-uImage.md5
Resolving sheeva.with-linux.com... 216.146.103.100, 2001:470:b:3e:250:43ff:fe01:c1bd
Connecting to sheeva.with-linux.com|216.146.103.100|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 55 [text/plain]
Saving to: `sheeva-2.6.37-uImage.md5'

100%[======================================>] 55          --.-K/s   in 0s

2011-02-06 11:10:13 (1.60 MB/s) - `sheeva-2.6.37-uImage.md5' saved [55/55]

+ break
+ [[ ! -f sheeva-2.6.37-uImage.md5 ]]
+ for f in Modules.tar.gz Modules.tar.gz.md5 uImage uImage.md5 System.map
+ [[ ! -f sheeva-2.6.37-System.map ]]
++ which wget
+ [[ -z /usr/bin/wget ]]
+ local 'sites=http://dev.plugapps.com/with-linux http://sheeva.with-linux.com/sheeva'
+ local s=
+ for s in '$sites'
+ wget -c http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-System.map
--2011-02-06 11:10:13--  http://dev.plugapps.com/with-linux/2.6.37/sheeva-2.6.37-System.map
Resolving dev.plugapps.com... 216.24.193.251
Connecting to dev.plugapps.com|216.24.193.251|:80... failed: Connection refused.
+ for s in '$sites'
+ wget -c http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-System.map
--2011-02-06 11:10:13--  http://sheeva.with-linux.com/sheeva/2.6.37/sheeva-2.6.37-System.map
Resolving sheeva.with-linux.com... 216.146.103.100, 2001:470:b:3e:250:43ff:fe01:c1bd
Connecting to sheeva.with-linux.com|216.146.103.100|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1177276 (1.1M) [text/plain]
Saving to: `sheeva-2.6.37-System.map'

100%[======================================>] 1,177,276   53.1K/s   in 22s

2011-02-06 11:10:36 (52.5 KB/s) - `sheeva-2.6.37-System.map' saved [1177276/1177276]

+ break
+ [[ ! -f sheeva-2.6.37-System.map ]]
+ Md5Compare sheeva-2.6.37-Modules.tar.gz sheeva-2.6.37-Modules.tar.gz.md5
++ cat sheeva-2.6.37-Modules.tar.gz.md5
++ cut '-d ' -f1
++ md5sum sheeva-2.6.37-Modules.tar.gz
++ cut '-d ' -f1
+ [[ 01e79db639119f1b2f188bc7104d5bad != 01e79db639119f1b2f188bc7104d5bad ]]
+ Md5Compare sheeva-2.6.37-uImage sheeva-2.6.37-uImage.md5
++ cat sheeva-2.6.37-uImage.md5
++ cut '-d ' -f1
++ md5sum sheeva-2.6.37-uImage
++ cut '-d ' -f1
+ [[ 01da406b84c680f479c9cf00a78474cc != 01da406b84c680f479c9cf00a78474cc ]]
+ CheckSize
+ local uImageFile=sheeva-2.6.37-uImage
++ grep uImage /proc/mtd
++ sed s#:##
++ cut '-d ' -f1
+ local mtd=mtd0
++ grep uImage /proc/mtd
++ cut '-d ' -f2
+ local mtdHexSize=00400000
+ local mtdSize=
+ let mtdSize=0x00400000
++ stat -c%s sheeva-2.6.37-uImage
+ local uImageSize=2773928
+ ((  uImageSize > mtdSize  ))
+ ExtractModules
+ echo 'Extracting modules'
Extracting modules
+ tar x -C / --overwrite -zf sheeva-2.6.37-Modules.tar.gz
+ [[ -d /boot ]]
+ cp sheeva-2.6.37-System.map /boot/
+ depmod -eF /boot/sheeva-2.6.37-System.map 2.6.37
+ NandKernel
+ echo 'Flashing kernel to NAND'
Flashing kernel to NAND
++ grep uImage /proc/mtd
++ cut '-d ' -f1
++ sed s#:##
+ local Mtd=mtd0
+ flash_eraseall -j /dev/mtd0
Erasing 128 Kibyte @ 3e0000 -- 96 % complete. Cleanmarker written at 3e0000.
+ nandwrite -pm /dev/mtd0 sheeva-2.6.37-uImage
Writing data to block 0
Writing data to block 20000
Writing data to block 40000
Writing data to block 60000
Writing data to block 80000
Writing data to block a0000
Writing data to block c0000
Writing data to block e0000
Writing data to block 100000
Writing data to block 120000
Writing data to block 140000
Writing data to block 160000
Writing data to block 180000
Writing data to block 1a0000
Writing data to block 1c0000
Writing data to block 1e0000
Writing data to block 200000
Writing data to block 220000
Writing data to block 240000
Writing data to block 260000
Writing data to block 280000
Writing data to block 2a0000
root@debian:~#
</pre>

<h2>U-Boot のコマンドプロンプトへ</h2>
再起動し、U-Boot のプロンプトにはいる
<pre>
root@debian:~# reboot

Broadcast message from root@debian
        (/dev/ttyS0) at 11:12 ...
	:
	:
USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0
Marvell>>
</pre>

<h2>環境変数の設定</h2>
README-2.6.37 のコメントにしたがって U-Boot の環境変数を設定する
<pre>
Marvell>> setenv mainlineLinux yes
Marvell>> setenv arcNumber 2678
Marvell>>
</pre>
玄柴は e-sata sheevaplugs 相当だと思うので、
arcNumber には 2678 をセットする
<pre>
Marvell>> setenv bootargs rootfstype=jffs2 console=ttyS0,115200 mtdparts=orion_nand:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=192.168.2.89:192.168.2.1:192.168.2.39:255.255.255.0:DB88FXX81:eth0:none
Marvell>>
</pre>
IP アドレスは、私のサイトに合わせた。
<p>
保存する。
<pre>
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>>
</pre>

<h2>再起動して確認</h2>
<pre>
Marvell>> reset

         __  __                      _ _
        |  \/  | __ _ _ ____   _____| | |
        | |\/| |/ _` | '__\ \ / / _ \ | |
        | |  | | (_| | |   \ V /  __/ | |
        |_|  |_|\__,_|_|    \_/ \___|_|_|
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_
| | | |___|  _ \ / _ \ / _ \| __|
| |_| |___| |_) | (_) | (_) | |_
 \___/    |____/ \___/ \___/ \__|
 ** MARVELL BOARD: SHEEVA PLUG LE

U-Boot 1.1.4 (Sep  7 2009 - 20:21:09) Marvell version: 3.4.16

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 006CEE60

Soc: 88F6281 A0 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 256MB
DRAM CS[1] base 0x10000000   size 256MB
DRAM Total size 512MB  16bit width
Flash:  0 kB
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:512 MB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0

NAND read: device 0 offset 0x100000, size 0x400000

Reading data from 0x4ff800 -- 100% complete.
 4194304 bytes read: OK
## Booting image at 00800000 ...
   Image Name:   Linux-2.6.37
   Created:      2011-01-23   5:39:39 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2773864 Bytes =  2.6 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
Linux version 2.6.37 (kelly@speedy) (gcc version 4.5.2 (PlugComputer G++ 20110117) ) #3 PREEMPT Sat Jan 22 22:39:36 MST 2011
CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=00053177
CPU: VIVT data cache, VIVT instruction cache
Machine: Marvell eSATA SheevaPlug Reference Board
Memory policy: ECC disabled, Data cache writeback
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 130048
Kernel command line: rootfstype=jffs2 console=ttyS0,115200 mtdparts=orion_nand:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=192.168.2.89:192.168.2.1:192.168.2.39:255.255.255.0:DB88FXX81:eth0:none
PID hash table entries: 2048 (order: 1, 8192 bytes)
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
Memory: 512MB = 512MB total
Memory: 513288k/513288k available, 11000k reserved, 0K highmem
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
    DMA     : 0xffc00000 - 0xffe00000   (   2 MB)
    vmalloc : 0xe0800000 - 0xfe800000   ( 480 MB)
    lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)
    modules : 0xbf000000 - 0xc0000000   (  16 MB)
      .init : 0xc0008000 - 0xc0030000   ( 160 kB)
      .text : 0xc0030000 - 0xc0550620   (5250 kB)
      .data : 0xc0552000 - 0xc0584080   ( 201 kB)
SLUB: Genslabs=13, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Preemptable hierarchical RCU implementation.
        RCU-based detection of stalled CPUs is disabled.
        Verbose stalled-CPUs detection is disabled.
NR_IRQS:114
Console: colour dummy device 80x30
Calibrating delay loop... 1192.75 BogoMIPS (lpj=5963776)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
NET: Registered protocol family 16
Kirkwood: MV88F6281-A0, TCLK=200000000.
Feroceon L2: Enabling L2
Feroceon L2: Cache support initialised.
bio: create slab &lt;bio-0> at 0
vgaarb: loaded
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
Switching to clocksource orion_clocksource
FS-Cache: Loaded
NET: Registered protocol family 2
IP route cache hash table entries: 4096 (order: 2, 16384 bytes)
TCP established hash table entries: 16384 (order: 5, 131072 bytes)
TCP bind hash table entries: 16384 (order: 4, 65536 bytes)
TCP: Hash tables configured (established 16384 bind 16384)
TCP reno registered
UDP hash table entries: 256 (order: 0, 4096 bytes)
UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
NET: Registered protocol family 1
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
FS-Cache: Netfs 'nfs' registered for caching
JFFS2 version 2.2. (NAND) 息 2001-2006 Red Hat, Inc.
JFS: nTxBlock = 4010, nTxLock = 32080
msgmni has been set to 1002
io scheduler noop registered
io scheduler deadline registered
io scheduler cfq registered (default)
Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A
console [ttyS0] enabled
brd: module loaded
loop: module loaded
NAND device: Manufacturer ID: 0xec, Chip ID: 0xdc (Samsung )
Scanning device for bad blocks
2 cmdlinepart partitions found on MTD device orion_nand
Creating 2 MTD partitions on "orion_nand":
0x000000100000-0x000000500000 : "uImage"
0x000000500000-0x000020000000 : "rootfs"
MV-643xx 10/100/1000 ethernet driver version 1.4
mv643xx_eth smi: probed
net eth0: port 0 with MAC address 00:50:43:01:44:96
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
orion-ehci orion-ehci.0: Marvell Orion EHCI
orion-ehci orion-ehci.0: new USB bus registered, assigned bus number 1
orion-ehci orion-ehci.0: irq 19, io mem 0xf1050000
orion-ehci orion-ehci.0: USB 2.0 started, EHCI 1.00
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
usbcore: registered new interface driver ums-datafab
usbcore: registered new interface driver ums-freecom
usbcore: registered new interface driver ums-jumpshot
usbcore: registered new interface driver ums-sddr09
usbcore: registered new interface driver ums-sddr55
mice: PS/2 mouse device common for all mice
rtc-mv rtc-mv: rtc core: registered rtc-mv as rtc0
i2c /dev entries driver
cpuidle: using governor ladder
cpuidle: using governor menu
mv_xor_shared mv_xor_shared.0: Marvell shared XOR driver
mv_xor_shared mv_xor_shared.1: Marvell shared XOR driver
mv_xor mv_xor.0: Marvell XOR: ( xor cpy )
mv_xor mv_xor.1: Marvell XOR: ( xor fill cpy )
mv_xor mv_xor.2: Marvell XOR: ( xor cpy )
mv_xor mv_xor.3: Marvell XOR: ( xor fill cpy )
sdhci: Secure Digital Host Controller Interface driver
sdhci: Copyright(c) Pierre Ossman
mmc0: mvsdio driver initialized, using GPIO 47 for card detection
usbcore: registered new interface driver usbhid
usbhid: USB HID core driver
oprofile: hardware counters not available
oprofile: using timer interrupt.
TCP cubic registered
NET: Registered protocol family 17
lib80211: common routines for IEEE802.11 drivers
Registering the dns_resolver key type
registered taskstats version 1
rtc-mv rtc-mv: setting system clock to 2011-02-06 11:19:45 UTC (1296991185)
IP-Config: Complete:
     device=eth0, addr=192.168.2.89, mask=255.255.255.0, gw=192.168.2.39,
     host=DB88FXX81, domain=, nis-domain=(none),
     bootserver=192.168.2.1, rootserver=192.168.2.1, rootpath=
eth0: link up, 1000 Mb/s, full duplex, flow control disabled
VFS: Mounted root (jffs2 filesystem) on device 31:1.
Freeing init memory: 160K
 * Setting preliminary keymap...                                         [ OK ]
 * Setting the system clock
Cannot access the Hardware Clock via any known method.
Use the --debug option to see the details of our search for an access method.
 * Unable to set System Clock to: Sun Feb  6 11:20:23 UTC 2011
 * Starting basic networking...                                          [ OK ]
 * Starting kernel event manager...                                             udevd (675): /proc/675/oom_adj is deprecated, please use /proc/675/oom_score_adj instead.
                                                                         [ OK ]
 * Loading hardware drivers...                                                  sata_mv sata_mv.0: version 1.28
sata_mv sata_mv.0: slots 32 ports 2
scsi0 : sata_mv
scsi1 : sata_mv
ata1: SATA max UDMA/133 irq 21
ata2: SATA max UDMA/133 irq 21
ata1: SATA link down (SStatus 0 SControl F300)
ata2: SATA link down (SStatus 0 SControl F300)
                                                                         [ OK ]
 * Setting the system clock
 * Loading kernel modules...                                                     * Loading manual drivers...                                             [ OK ]
 * Setting kernel variables (/etc/sysctl.conf)...                        [ OK ]
 * Setting kernel variables (/etc/sysctl.d/10-console-messages.conf)...  [ OK ]
 * Setting kernel variables (/etc/sysctl.d/10-network-security.conf)...  [ OK ]
 * Setting kernel variables (/etc/sysctl.d/10-process-security.conf)...  [ OK ]
 * Setting kernel variables (/etc/sysctl.d/10-tcp-timestamps-workaround.conf)...                                                                         [ OK ]
 * Activating swap...                                                    [ OK ]
 * Starting early crypto disks...                                        [ OK ]
 * Starting remaining crypto disks...                                    [ OK ]
 * Checking file systems...                                                     fsck 1.41.3 (12-Oct-2008)
                                                                         [ OK ]
 * Mounting local filesystems...                                         [ OK ]
 * Activating swapfile swap...                                           [ OK ]
 * Configuring network interfaces...                                     [ OK ]
 * Setting up console font and keymap...                                 [ OK ]
 * Starting system log daemon...
Ubuntu jaunty (development branch) debian ttyS0

debian login:
                                                                                * Starting kernel log daemon...                                                 Killed
                                                                         [fail]
                                                                                * Starting OpenBSD Secure Shell server sshd                              [ OK ]
                                                                                * Starting periodic command scheduler crond                              [ OK ]

</pre>
kernel log daemon が fail と言っているが、、、
]]>
        
    </content>
</entry>

<entry>
    <title>/etc/rc.local の修正</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/etcrclocal.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2212</id>

    <published>2011-02-06T12:00:00Z</published>
    <updated>2011-02-06T01:49:25Z</updated>

    <summary>ほとんど新品状態の玄柴なので、 /etc/rc.local を修正するところから...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[ほとんど新品状態の玄柴なので、
/etc/rc.local を修正するところから。

<pre>
root@debian:~# cd /etc
root@debian:/etc# mv rc.local{,.orig}
root@debian:/etc# cp rc.local{.orig,}
root@debian:/etc# vi rc.local
	:
	:
root@debian:/etc# diff -c rc.local{.orig,}
*** rc.local.orig       Mon Jan 26 18:00:10 2009
--- rc.local    Mon Jan 29 20:30:14 2001
***************
*** 10,22 ****
  # bits.
  #
  # By default this script does nothing.
! insmod /boot/fat.ko
! insmod /boot/vfat.ko
  mkdir -p /var/cache/apt/archives/partial
! /root/discoverd
! cd /
  #./demo.sh
! date 012618002009
! hwclock -w

  exit 0
--- 10,22 ----
  # bits.
  #
  # By default this script does nothing.
! #insmod /boot/fat.ko
! #insmod /boot/vfat.ko
  mkdir -p /var/cache/apt/archives/partial
! #/root/discoverd
! #cd /
  #./demo.sh
! #date 012618002009
! #hwclock -w

  exit 0
root@debian:/etc#
</pre>
時計も合わせておく。
<pre>
root@debian:/etc# date 020610402011
Sun Feb  6 10:40:00 UTC 2011
root@debian:/etc#
</pre>
ぐへぇ。UTC だ。まぁいいか（謎
]]>
        
    </content>
</entry>

<entry>
    <title>NFS root でバックアップ</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/nfs-root.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2211</id>

    <published>2011-02-05T12:00:00Z</published>
    <updated>2011-02-05T08:01:52Z</updated>

    <summary>NFS root でブートできたので、 次は Flash root のバックアッ...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[NFS root でブートできたので、
次は Flash root のバックアップ

<h2>起動</h2>
<pre>
512 MB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0
Marvell>>
</pre>

<h2>bootargs の変更</h2>
<pre>
Marvell>> set bootargs console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/nfs rw nfsroot=$(serverip):/srv/nfs/rootfsv1.0 ip=$(ipaddr):$(serverip)$(bootargs_end)
Marvell>> printenv
baudrate=115200
loads_echo=0
rootpath=/mnt/ARM_FS/
netmask=255.255.0.0
CASset=min
MALLOC_len=1
ethprime=egiga0
bootargs_root=root=/dev/mtdblock2 ro
ethmtu=1500
usb0Mode=host
nandEcc=1bit
ethact=egiga0
cesvcid=ULULULULULULPPULULULULULDA
bootargs_end=:::DB88FXX81:eth0:none
image_name=uImage
standalone=fsload 0x2000000 $(image_name);setenv bootargs $(console) root=/dev/mtdblock0 rw ip=$(ipaddr):$(serverip)$(bootargs_end) $(mvPhoneConfig); bootm 0x2000000;
mvPhoneConfig=mv_phone_config=dev0:fxs,dev1:fxs
mvNetConfig=mv_net_config=(00:11:88:0f:62:81,0:1:2:3),mtu=1500
yuk_ethaddr=00:00:00:EE:51:81
netretry=no
rcvrip=169.254.100.100
loadaddr=0x02000000
autoload=no
run_diag=no
bootcmd=nand read.e 0x800000 0x100000 0x400000; bootm 0x800000
ethaddr=00:50:43:01:44:96
serverip=192.168.2.38
ipaddr=192.168.2.89
stdin=serial
stdout=serial
stderr=serial
console=console=ttyS0,115200 mtdparts=nand_mtd:0x100000@0(uboot)ro,0x0@0x100000(uImage),0x1ff00000@0x100000(rootfs)rw
mainlineLinux=no
enaMonExt=no
enaCpuStream=no
enaWrAllo=no
pexMode=RC
disL2Cache=no
setL2CacheWT=yes
disL2Prefetch=yes
enaICPref=yes
enaDCPref=yes
sata_dma_mode=yes
netbsd_en=no
vxworks_en=no
bootdelay=3
disaMvPnp=no
enaAutoRecovery=yes
bootargs=console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/nfs rw nfsroot=192.168.2.38:/srv/nfs/rootfsv1.0 ip=192.168.2.89:192.168.2.38:::DB88FXX81:eth0:none

Environment size: 1418/131068 bytes
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>>
</pre>

<h2>reboot</h2>
<pre>
Marvell>> reset

         __  __                      _ _
        |  \/  | __ _ _ ____   _____| | |
        | |\/| |/ _` | '__\ \ / / _ \ | |
        | |  | | (_| | |   \ V /  __/ | |
        |_|  |_|\__,_|_|    \_/ \___|_|_|
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_
| | | |___|  _ \ / _ \ / _ \| __|
| |_| |___| |_) | (_) | (_) | |_
 \___/    |____/ \___/ \___/ \__|
 ** MARVELL BOARD: SHEEVA PLUG LE

U-Boot 1.1.4 (Sep  7 2009 - 20:21:09) Marvell version: 3.4.16

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 006CEE60

Soc: 88F6281 A0 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 256MB
DRAM CS[1] base 0x10000000   size 256MB
DRAM Total size 512MB  16bit width
Flash:  0 kB
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:512 MB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0

NAND read: device 0 offset 0x100000, size 0x400000

Reading data from 0x4ff800 -- 100% complete.
 4194304 bytes read: OK
## Booting image at 00800000 ...
   Image Name:   Linux-2.6.22.18
   Created:      2009-03-19   9:18:16 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2106696 Bytes =  2 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux.................................................................................................................................... done, booting the kernel.
Linux version 2.6.22.18 (dhaval@devbox) (gcc version 4.2.1) #1 Thu Mar 19 14:46:22 IST 2009
CPU: ARM926EJ-S [56251311] revision 1 (ARMv5TE), cr=00053177
Machine: Feroceon-KW
Using UBoot passing parameters structure
Memory policy: ECC disabled, Data cache writeback
CPU0: D VIVT write-back cache
CPU0: I cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets
CPU0: D cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets
Built 1 zonelists.  Total pages: 130048
Kernel command line: console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/nfs rw nfsroot=192.168.2.38:/srv/nfs/rootfsv1.0 ip=192.168.2.89:192.168.2.38:::DB88FXX81:eth0:none
PID hash table entries: 2048 (order: 11, 8192 bytes)
Console: colour dummy device 80x30
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
Memory: 256MB 256MB 0MB 0MB = 512MB total
Memory: 515456KB available (3864K code, 257K data, 104K init)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
NET: Registered protocol family 16

CPU Interface
-------------
SDRAM_CS0 ....base 00000000, size 256MB
SDRAM_CS1 ....base 10000000, size 256MB
SDRAM_CS2 ....disable
SDRAM_CS3 ....disable
PEX0_MEM ....base e8000000, size 128MB
PEX0_IO ....base f2000000, size   1MB
INTER_REGS ....base f1000000, size   1MB
NFLASH_CS ....base fa000000, size   2MB
SPI_CS ....base f4000000, size  16MB
BOOT_ROM_CS ....no such
DEV_BOOTCS ....no such
CRYPT_ENG ....base f0000000, size   2MB

  Marvell Development Board (LSP Version KW_LSP_4.2.7_patch2)-- SHEEVA PLUG  Soc: 88F6281 A0 LE

 Detected Tclk 200000000 and SysClk 400000000
MV Buttons Device Load
Marvell USB EHCI Host controller #0: c08b8600
PEX0 interface detected no Link.
PCI: bus0: Fast back to back transfers enabled
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
NET: Registered protocol family 2
Time: kw_clocksource clocksource has been installed.
IP route cache hash table entries: 16384 (order: 4, 65536 bytes)
TCP established hash table entries: 65536 (order: 7, 524288 bytes)
TCP bind hash table entries: 65536 (order: 6, 262144 bytes)
TCP: Hash tables configured (established 65536 bind 65536)
TCP reno registered
RTC registered
Use the XOR engines (acceleration) for enhancing the following functions:
  o RAID 5 Xor calculation
  o kernel memcpy
  o kenrel memzero
Number of XOR engines to use: 4
cesadev_init(c000c894)
mvCesaInit: sessions=640, queue=64, pSram=f0000000
Warning: TS unit is powered off.
MV Buttons Driver Load
NTFS driver 2.1.28 [Flags: R/O].
JFFS2 version 2.2. (NAND) 誕 ・001-2006 Red Hat, Inc.
io scheduler noop registered
io scheduler anticipatory registered (default)
Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A
serial8250.0: ttyS1 at MMIO 0xf1012100 (irq = 34) is a 16550A
Loading Marvell Ethernet Driver:
  o Cached descriptors in DRAM
  o DRAM SW cache-coherency
  o Single RX Queue support - ETH_DEF_RXQ=0
  o Single TX Queue support - ETH_DEF_TXQ=0
  o TCP segmentation offload enabled
  o Receive checksum offload enabled
  o Transmit checksum offload enabled
  o Network Fast Processing (Routing) supported
  o Driver ERROR statistics enabled
  o Driver INFO statistics enabled
  o Proc tool API enabled
  o Rx descripors: q0=128
  o Tx descripors: q0=532
  o Loading network interface(s):
    o eth0, ifindex = 1, GbE port = 0
    o eth1, ifindex = 2, GbE port = 1

mvFpRuleDb (dfd00000): 16384 entries, 65536 bytes
Intel(R) PRO/1000 Network Driver - version 7.3.20-k2-NAPI
Copyright (c) 1999-2006 Intel Corporation.
e100: Intel(R) PRO/100 Network Driver, 3.5.17-k4-NAPI
e100: Copyright(c) 1999-2006 Intel Corporation
Integrated Sata device found
scsi0 : Marvell SCSI to SATA adapter
scsi1 : Marvell SCSI to SATA adapter
NFTL driver: nftlcore.c $Revision: 1.98 $, nftlmount.c $Revision: 1.41 $
NAND device: Manufacturer ID: 0xec, Chip ID: 0xdc (Samsung NAND 512MiB 3,3V 8-bit)
Scanning device for bad blocks
2 cmdlinepart partitions found on MTD device nand_mtd
Using command line partition definition
Creating 2 MTD partitions on "nand_mtd":
0x00100000-0x00500000 : "uImage"
0x00500000-0x20000000 : "rootfs"
ehci_marvell ehci_marvell.70059: Marvell Orion EHCI
ehci_marvell ehci_marvell.70059: new USB bus registered, assigned bus number 1
ehci_marvell ehci_marvell.70059: irq 19, io base 0xf1050100
ehci_marvell ehci_marvell.70059: USB 2.0 started, EHCI 1.00, driver 10 Dec 2004
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
USB Universal Host Controller Interface driver v3.0
usbcore: registered new interface driver usblp
drivers/usb/class/usblp.c: v0.13: USB Printer Device Class driver
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
mice: PS/2 mouse device common for all mice
i2c /dev entries driver
Linux telephony interface: v1.00
Marvell Telephony Driver:
mvBoardVoiceAssembleModeGet: TDM not supported(boardId=0x9)
assembly=-1,irq=-1
mp_check_config: Error, invalid voice assembley mode
md: linear personality registered for level -1
md: raid0 personality registered for level 0
md: raid1 personality registered for level 1
raid6: int32x1     97 MB/s
raid6: int32x2    114 MB/s
raid6: int32x4    122 MB/s
raid6: int32x8    110 MB/s
raid6: using algorithm int32x4 (122 MB/s)
md: raid6 personality registered for level 6
md: raid5 personality registered for level 5
md: raid4 personality registered for level 4
raid5: measuring checksumming speed
   arm4regs  :  1083.600 MB/sec
   8regs     :   754.800 MB/sec
   32regs    :   899.600 MB/sec
raid5: using function: arm4regs (1083.600 MB/sec)
device-mapper: ioctl: 4.11.0-ioctl (2006-10-12) initialised: dm-devel@redhat.com
dm_crypt using the OCF package.
sdhci: Secure Digital Host Controller Interface driver
sdhci: Copyright(c) Pierre Ossman
mvsdmmc: irq =28 start f1090000
mvsdmmc: no IRQ detect
usbcore: registered new interface driver usbhid
drivers/hid/usbhid/hid-core.c: v2.6:USB HID core driver
Advanced Linux Sound Architecture Driver Version 1.0.14 (Thu May 31 09:03:25 2007 UTC).
mvCLAudioCodecRegGet: Error while reading register!
mvCLAudioCodecInit: Error - Invalid Cirrus Logic chip/rev ID!
Error - Cannot initialize audio decoder.at address =0xff&lt;6>ALSA device list:
  #0: Marvell mv88fx_snd ALSA driver
TCP cubic registered
NET: Registered protocol family 1
NET: Registered protocol family 17
eth0: link down
eth0: started
IP-Config: Guessing netmask 255.255.255.0
IP-Config: Complete:
      device=eth0, addr=192.168.2.89, mask=255.255.255.0, gw=255.255.255.255,
     host=DB88FXX81, domain=, nis-domain=(none),
     bootserver=192.168.2.38, rootserver=192.168.2.38, rootpath=
md: Autodetecting RAID arrays.
md: autorun ...
md: ... autorun DONE.
Looking up port of RPC 100003/2 on 192.168.2.38
eth0: link up, full duplex, speed 1 Gbps
Looking up port of RPC 100005/1 on 192.168.2.38
VFS: Mounted root (nfs filesystem).
Freeing init memory: 104K
init started: BusyBox v1.7.0 (2008-02-26 19:25:17 IST)
starting pid 260, tty '': '/etc/init.d/rcS'
starting pid 262, tty '': '/bin/sh'
-sh-3.2#
</pre>


<h2>flash のマウント</h2>
<pre>
-sh-3.2# mount -t jffs2 /dev/mtdblock1 /mnt
</pre>
しばらくして
<pre>
Empty flash at 0x0fcb49ac ends at 0x0fcb5000
-sh-3.2#
</pre>
この待ち時間は何だろう？？？

<h2>Flash root のバックアップ</h2>
<pre>
-sh-3.2# cd /mnt/
-sh-3.2# ls
bin      etc      media    proc     selinux  tmp
boot     home     mnt      root     srv      usr
dev      lib      opt      sbin     sys      var
-sh-3.2# tar zcvf /kuro-sheeva_root.tar.gz .
./
./bin/
./bin/dd
./bin/cp
./bin/df
./bin/ip
./bin/ln
./bin/ls
./bin/nc
./bin/mt
	:
	:
./root/.profile
./root/discoverd
./media/
./selinux/
-sh-3.2#
</pre>

<h2>ベリファイ</h2>
/ に kuro-sheeva_root.tar.gz を置いたので、
NFS サーバの LS-GL でも見えるはず。
<pre>
yasunari@ude:~$ cd /srv/nfs/rootfsv1.0/
yasunari@ude:/srv/nfs/rootfsv1.0$ ls
bin  etc                      lib      mnt   proc  usr
dev  kuro-sheeva_root.tar.gz  linuxrc  mnt1  sbin
yasunari@ude:/srv/nfs/rootfsv1.0$
</pre>
kuro-sheeva_root.tar.gz ができている。
<p>
ベリファイする。
<pre>
yasunari@ude:/srv/nfs/rootfsv1.0$ tar ztvf kuro-sheeva_root.tar.gz
drwxr-xr-x root/root         0 1970-01-01 09:00 ./
drwxr-xr-x root/root         0 2008-11-15 08:41 ./bin/
	:
	:
-rw------- root/root        47 2000-02-15 15:35 ./root/.lesshst
-rw------- root/root      5617 2001-01-29 11:17 ./root/.bash_history
-rw-r--r-- root/root       140 2007-11-20 02:57 ./root/.profile
-rwxr-xr-x root/root      4928 2009-01-20 14:06 ./root/discoverd
drwxr-xr-x root/root         0 2009-01-20 02:06 ./media/
drwxr-xr-x root/root         0 2008-11-14 01:15 ./selinux/
yasunari@ude:/srv/nfs/rootfsv1.0$
</pre>
OK

<h2>bootargs を戻す</h2>
<pre>
-sh-3.2# reboot
	:
	:
Marvell>> set bootargs console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=$(ipaddr):$(serverip):$(serverip):255.255.255.0:DB88FXX81:eth0:none
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>> reset
</pre>
]]>
        
    </content>
</entry>

<entry>
    <title>NFS root でブート</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2011/02/-nfs-root.html" />
    <id>tag:www.yamasita.jp,2011:/sheevaplug//12.2210</id>

    <published>2011-02-04T14:36:54Z</published>
    <updated>2011-02-08T00:40:22Z</updated>

    <summary>以前 SheevaPlug で実施した NFS root で bootを玄柴でも...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[以前 SheevaPlug で実施した
<a href="http://www.yamasita.jp/sheevaplug/2009/10/root-fs-1.html">
NFS root で boot</a>を玄柴でも試してみる。

<h2>起動</h2>
<pre>

         __  __                      _ _
        |  \/  | __ _ _ ____   _____| | |
        | |\/| |/ _` | '__\ \ / / _ \ | |
        | |  | | (_| | |   \ V /  __/ | |
        |_|  |_|\__,_|_|    \_/ \___|_|_|
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_
| | | |___|  _ \ / _ \ / _ \| __|
| |_| |___| |_) | (_) | (_) | |_
 \___/    |____/ \___/ \___/ \__|
 ** MARVELL BOARD: SHEEVA PLUG LE

U-Boot 1.1.4 (Sep  7 2009 - 20:21:09) Marvell version: 3.4.16

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 006CEE60

Soc: 88F6281 A0 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 256MB
DRAM CS[1] base 0x10000000   size 256MB
DRAM Total size 512MB  16bit width
Flash:  0 kB
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:512 MB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0
Marvell>>
</pre>
カウントダウンが終わる前にキーを押して、U-Boot のプロンプトに入る。
<br>
Hit any key と言われているので、押すのはもちろん ANY キー（笑
<p>
<img src="/sheevaplug/2011/02/IMAGE_190.jpg">
<p>

<h2>環境変数の確認</h2>
<pre>
Marvell>> printenv
baudrate=115200
loads_echo=0
rootpath=/mnt/ARM_FS/
netmask=255.255.0.0
CASset=min
MALLOC_len=1
ethprime=egiga0
bootargs_root=root=/dev/mtdblock2 ro
ethmtu=1500
usb0Mode=host
nandEcc=1bit
ethact=egiga0
serverip=10.10.0.2
ipaddr=10.10.0.1
cesvcid=ULULULULULULPPULULULULULDA
bootargs_end=:::DB88FXX81:eth0:none
image_name=uImage
standalone=fsload 0x2000000 $(image_name);setenv bootargs $(console) root=/dev/mtdblock0 rw ip=$(ipaddr):$(serverip)$(bootargs_end) $(mvPhoneConfig); bootm 0x2000000;
mvPhoneConfig=mv_phone_config=dev0:fxs,dev1:fxs
mvNetConfig=mv_net_config=(00:11:88:0f:62:81,0:1:2:3),mtu=1500
yuk_ethaddr=00:00:00:EE:51:81
netretry=no
rcvrip=169.254.100.100
loadaddr=0x02000000
autoload=no
run_diag=no
bootargs=console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=10.4.50.4:10.4.50.5:10.4.50.5:255.255.255.0:DB88FXX81:eth0:none
bootcmd=nand read.e 0x800000 0x100000 0x400000; bootm 0x800000
ethaddr=00:50:43:01:44:96
stdin=serial
stdout=serial
stderr=serial
console=console=ttyS0,115200 mtdparts=nand_mtd:0x100000@0(uboot)ro,0x0@0x100000(uImage),0x1ff00000@0x100000(rootfs)rw
mainlineLinux=no
enaMonExt=no
enaCpuStream=no
enaWrAllo=no
pexMode=RC
disL2Cache=no
setL2CacheWT=yes
disL2Prefetch=yes
enaICPref=yes
enaDCPref=yes
sata_dma_mode=yes
netbsd_en=no
vxworks_en=no
bootdelay=3
disaMvPnp=no
enaAutoRecovery=yes

Environment size: 1393/131068 bytes
Marvell>>
</pre>

<h2>bootargs の変更</h2>
<pre>
Marvell>> set serverip 192.168.2.38
Marvell>> set ipaddr 192.168.2.89
Marvell>> set bootargs console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/nfs rw nfsroot=$(serverip):/srv/nfs/rootfsv1.0 ip=$(ipaddr):$(serverip)$(bootargs_end)
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>>
</pre>

<h2>reboot</h2>
<pre>
Marvell>> reset

         __  __                      _ _
        |  \/  | __ _ _ ____   _____| | |
        | |\/| |/ _` | '__\ \ / / _ \ | |
        | |  | | (_| | |   \ V /  __/ | |
        |_|  |_|\__,_|_|    \_/ \___|_|_|
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_
| | | |___|  _ \ / _ \ / _ \| __|
| |_| |___| |_) | (_) | (_) | |_
 \___/    |____/ \___/ \___/ \__|
 ** MARVELL BOARD: SHEEVA PLUG LE

U-Boot 1.1.4 (Sep  7 2009 - 20:21:09) Marvell version: 3.4.16

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 006CEE60

Soc: 88F6281 A0 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 256MB
DRAM CS[1] base 0x10000000   size 256MB
DRAM Total size 512MB  16bit width
Flash:  0 kB
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:512 MB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0

NAND read: device 0 offset 0x100000, size 0x400000

Reading data from 0x4ff800 -- 100% complete.
 4194304 bytes read: OK
## Booting image at 00800000 ...
   Image Name:   Linux-2.6.22.18
   Created:      2009-03-19   9:18:16 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2106696 Bytes =  2 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux.................................................................................................................................... done, booting the kernel.
Linux version 2.6.22.18 (dhaval@devbox) (gcc version 4.2.1) #1 Thu Mar 19 14:46:22 IST 2009
CPU: ARM926EJ-S [56251311] revision 1 (ARMv5TE), cr=00053177
Machine: Feroceon-KW
Using UBoot passing parameters structure
Memory policy: ECC disabled, Data cache writeback
CPU0: D VIVT write-back cache
CPU0: I cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets
CPU0: D cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets
Built 1 zonelists.  Total pages: 130048
Kernel command line: console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/nfs rw nfsroot=192.168.2.38:/srv/nfs/rootfsv1.0 ip=192.168.2.89:192.168.2.38:::DB88FXX81:eth0:none
PID hash table entries: 2048 (order: 11, 8192 bytes)
Console: colour dummy device 80x30
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
Memory: 256MB 256MB 0MB 0MB = 512MB total
Memory: 515456KB available (3864K code, 257K data, 104K init)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
NET: Registered protocol family 16

CPU Interface
-------------
SDRAM_CS0 ....base 00000000, size 256MB
SDRAM_CS1 ....base 10000000, size 256MB
SDRAM_CS2 ....disable
SDRAM_CS3 ....disable
PEX0_MEM ....base e8000000, size 128MB
PEX0_IO ....base f2000000, size   1MB
INTER_REGS ....base f1000000, size   1MB
NFLASH_CS ....base fa000000, size   2MB
SPI_CS ....base f4000000, size  16MB
BOOT_ROM_CS ....no such
DEV_BOOTCS ....no such
CRYPT_ENG ....base f0000000, size   2MB

  Marvell Development Board (LSP Version KW_LSP_4.2.7_patch2)-- SHEEVA PLUG  Soc: 88F6281 A0 LE

 Detected Tclk 200000000 and SysClk 400000000
MV Buttons Device Load
Marvell USB EHCI Host controller #0: c08b8600
PEX0 interface detected no Link.
PCI: bus0: Fast back to back transfers enabled
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
NET: Registered protocol family 2
Time: kw_clocksource clocksource has been installed.
IP route cache hash table entries: 16384 (order: 4, 65536 bytes)
TCP established hash table entries: 65536 (order: 7, 524288 bytes)
TCP bind hash table entries: 65536 (order: 6, 262144 bytes)
TCP: Hash tables configured (established 65536 bind 65536)
TCP reno registered
RTC registered
Use the XOR engines (acceleration) for enhancing the following functions:
  o RAID 5 Xor calculation
  o kernel memcpy
  o kenrel memzero
Number of XOR engines to use: 4
cesadev_init(c000c894)
mvCesaInit: sessions=640, queue=64, pSram=f0000000
Warning: TS unit is powered off.
MV Buttons Driver Load
NTFS driver 2.1.28 [Flags: R/O].
JFFS2 version 2.2. (NAND) 誕 ・001-2006 Red Hat, Inc.
io scheduler noop registered
io scheduler anticipatory registered (default)
Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A
serial8250.0: ttyS1 at MMIO 0xf1012100 (irq = 34) is a 16550A
Loading Marvell Ethernet Driver:
  o Cached descriptors in DRAM
  o DRAM SW cache-coherency
  o Single RX Queue support - ETH_DEF_RXQ=0
  o Single TX Queue support - ETH_DEF_TXQ=0
  o TCP segmentation offload enabled
  o Receive checksum offload enabled
  o Transmit checksum offload enabled
  o Network Fast Processing (Routing) supported
  o Driver ERROR statistics enabled
  o Driver INFO statistics enabled
  o Proc tool API enabled
  o Rx descripors: q0=128
  o Tx descripors: q0=532
  o Loading network interface(s):
    o eth0, ifindex = 1, GbE port = 0
    o eth1, ifindex = 2, GbE port = 1

mvFpRuleDb (dfd00000): 16384 entries, 65536 bytes
Intel(R) PRO/1000 Network Driver - version 7.3.20-k2-NAPI
Copyright (c) 1999-2006 Intel Corporation.
e100: Intel(R) PRO/100 Network Driver, 3.5.17-k4-NAPI
e100: Copyright(c) 1999-2006 Intel Corporation
Integrated Sata device found
scsi0 : Marvell SCSI to SATA adapter
scsi1 : Marvell SCSI to SATA adapter
NFTL driver: nftlcore.c $Revision: 1.98 $, nftlmount.c $Revision: 1.41 $
NAND device: Manufacturer ID: 0xec, Chip ID: 0xdc (Samsung NAND 512MiB 3,3V 8-bit)
Scanning device for bad blocks
2 cmdlinepart partitions found on MTD device nand_mtd
Using command line partition definition
Creating 2 MTD partitions on "nand_mtd":
0x00100000-0x00500000 : "uImage"
0x00500000-0x20000000 : "rootfs"
ehci_marvell ehci_marvell.70059: Marvell Orion EHCI
ehci_marvell ehci_marvell.70059: new USB bus registered, assigned bus number 1
ehci_marvell ehci_marvell.70059: irq 19, io base 0xf1050100
ehci_marvell ehci_marvell.70059: USB 2.0 started, EHCI 1.00, driver 10 Dec 2004
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
USB Universal Host Controller Interface driver v3.0
usbcore: registered new interface driver usblp
drivers/usb/class/usblp.c: v0.13: USB Printer Device Class driver
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
mice: PS/2 mouse device common for all mice
i2c /dev entries driver
Linux telephony interface: v1.00
Marvell Telephony Driver:
mvBoardVoiceAssembleModeGet: TDM not supported(boardId=0x9)
assembly=-1,irq=-1
mp_check_config: Error, invalid voice assembley mode
md: linear personality registered for level -1
md: raid0 personality registered for level 0
md: raid1 personality registered for level 1
raid6: int32x1     97 MB/s
raid6: int32x2    114 MB/s
raid6: int32x4    122 MB/s
raid6: int32x8    110 MB/s
raid6: using algorithm int32x4 (122 MB/s)
md: raid6 personality registered for level 6
md: raid5 personality registered for level 5
md: raid4 personality registered for level 4
raid5: measuring checksumming speed
   arm4regs  :  1084.000 MB/sec
   8regs     :   754.800 MB/sec
   32regs    :   899.600 MB/sec
raid5: using function: arm4regs (1084.000 MB/sec)
device-mapper: ioctl: 4.11.0-ioctl (2006-10-12) initialised: dm-devel@redhat.com
dm_crypt using the OCF package.
sdhci: Secure Digital Host Controller Interface driver
sdhci: Copyright(c) Pierre Ossman
mvsdmmc: irq =28 start f1090000
mvsdmmc: no IRQ detect
usbcore: registered new interface driver usbhid
drivers/hid/usbhid/hid-core.c: v2.6:USB HID core driver
Advanced Linux Sound Architecture Driver Version 1.0.14 (Thu May 31 09:03:25 2007 UTC).
mvCLAudioCodecRegGet: Error while reading register!
mvCLAudioCodecInit: Error - Invalid Cirrus Logic chip/rev ID!
Error - Cannot initialize audio decoder.at address =0xff&lt;6>ALSA device list:
  #0: Marvell mv88fx_snd ALSA driver
TCP cubic registered
NET: Registered protocol family 1
NET: Registered protocol family 17
eth0: link down
eth0: started
IP-Config: Guessing netmask 255.255.255.0
IP-Config: Complete:
      device=eth0, addr=192.168.2.89, mask=255.255.255.0, gw=255.255.255.255,
     host=DB88FXX81, domain=, nis-domain=(none),
     bootserver=192.168.2.38, rootserver=192.168.2.38, rootpath=
md: Autodetecting RAID arrays.
md: autorun ...
md: ... autorun DONE.
Looking up port of RPC 100003/2 on 192.168.2.38
eth0: link up, full duplex, speed 1 Gbps
Looking up port of RPC 100005/1 on 192.168.2.38
VFS: Mounted root (nfs filesystem).
Freeing init memory: 104K
init started: BusyBox v1.7.0 (2008-02-26 19:25:17 IST)
starting pid 260, tty '': '/etc/init.d/rcS'
starting pid 262, tty '': '/bin/sh'
-sh-3.2#
</pre>
できた。

<h2>flash のマウント</h2>
実はやりたかったのはこれ
<pre>
-sh-3.2# ls /
bin      etc      linuxrc  mnt1     sbin
dev      lib      mnt      proc     usr
-sh-3.2# ls /mnt
-sh-3.2# mount -t jffs2 /dev/mtdblock1 /mnt

</pre>
しばらくして
<pre>
Empty flash at 0x0fcb49ac ends at 0x0fcb5000
-sh-3.2# df
Filesystem           1k-blocks      Used Available Use% Mounted on
/dev/mtdblock1          519168    152360    366808  29% /mnt
-sh-3.2# ls /mnt
bin      etc      media    proc     selinux  tmp
boot     home     mnt      root     srv      usr
dev      lib      opt      sbin     sys      var
-sh-3.2#
</pre>

書けることも確認する。
<pre>
-sh-3.2# echo a > /mnt/tmp/a
-sh-3.2# cat /mnt/tmp/a
a
-sh-3.2#
</pre>
と言うことで、玄柴も NFS root でブート可能。
まぁ、あたりまえ。

<h2>bootargs を戻す</h2>
<pre>
-sh-3.2# reboot
The system is going down NOW!
Sending SIGTERM to all processes
Requesting system reboot
md: stopping all md devices.
Restarting system.
Reseting !!

         __  __                      _ _
        |  \/  | __ _ _ ____   _____| | |
        | |\/| |/ _` | '__\ \ / / _ \ | |
        | |  | | (_| | |   \ V /  __/ | |
        |_|  |_|\__,_|_|    \_/ \___|_|_|
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_
| | | |___|  _ \ / _ \ / _ \| __|
| |_| |___| |_) | (_) | (_) | |_
 \___/    |____/ \___/ \___/ \__|
 ** MARVELL BOARD: SHEEVA PLUG LE

U-Boot 1.1.4 (Sep  7 2009 - 20:21:09) Marvell version: 3.4.16

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 006CEE60

Soc: 88F6281 A0 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 256MB
DRAM CS[1] base 0x10000000   size 256MB
DRAM Total size 512MB  16bit width
Flash:  0 kB
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:512 MB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0
Marvell>> set bootargs console=ttyS0,115200 mtdparts=nand_mtd:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs) rw root=/dev/mtdblock1 rw ip=10.4.50.4:10.4.50.5:10.4.50.5:255.255.255.0:DB88FXX81:eth0:none
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
Marvell>>
</pre>
]]>
        
    </content>
</entry>

<entry>
    <title>Ubuntu オフラインミーティング Kansai 10.10 で「SheevaPlug/玄柴をハックしよう」 #ubuntujp</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2010/11/ubuntu-kansai-1010-sheevaplug-ubuntujp.html" />
    <id>tag:www.yamasita.jp,2010:/sheevaplug//12.2165</id>

    <published>2010-11-30T11:00:00Z</published>
    <updated>2010-11-29T14:24:21Z</updated>

    <summary>報告するのをすっかり忘れてましたが、 Ubuntu オフラインミーティング Ka...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="KURO-RS" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="SheevaPlug" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[報告するのをすっかり忘れてましたが、<br>
Ubuntu オフラインミーティング Kansai 10.10 でムチャ振りされ、<br>
仕方なく「SheevaPlug/玄柴をハックしよう」と題してしゃべってきました。
<p>
普段、顔出ししないのですが、
YouTube に上げられてしまったので（笑、仕方なく紹介しておきます。<br>
<a href="http://www.youtube.com/watch?v=JA4AbxV28Rg">
前半</a> 
<a href="http://www.youtube.com/watch?v=i3kk2wpGADE">
後半</a><br>
初めて私を見る方もいらっしゃるのでは？こんなオジサンです。
<p>
見直すと、かなりいい加減ですね。<br>
「ボチボチ出てくる」と言っていながら出てこなかったり、<br>
スライドをおくったら今しゃべった内容が出てきたりと、、（藁
<p>
まぁ、カラアゲ食べながら、ビール片手にちょこちょこっと
OQO の小さい画面ででっち上げたプレゼンなので、勘弁してください。
]]>
        
    </content>
</entry>

<entry>
    <title>ブース完成 #kof2010 #gadget1</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2010/11/-kof2010-gadget1-1.html" />
    <id>tag:www.yamasita.jp,2010:/sheevaplug//12.2143</id>

    <published>2010-11-05T03:22:45Z</published>
    <updated>2010-11-05T03:27:43Z</updated>

    <summary> 関西オープンソース2010 / 関西コミュニティ大決戦／ Gadget1 R3...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="KURO-RS" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="SheevaPlug" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[<a href="http://k-of.jp/2010/index.html">
関西オープンソース2010 / 関西コミュニティ大決戦</a>／
<a href="http://gadget1.jus.or.jp/r3/">
Gadget1 R3 Chitoseame</a>
のブース完成。
<p>
<a href="/sheevaplug/2010/11/IMAGE_246.jpg" target="_blank">
<img src="/sheevaplug/2010/11/IMAGE_246.jpg" width=256 height=192></a>
<p>
みなさん、遊びに来てやってください。
<p>
ロボアクター、チョロQはこの机の向こうの「床」に。<p>
机上、右端はとしさんの自作GPSロガー]]>
        
    </content>
</entry>

<entry>
    <title>壁掛けコンピュータキット（？）のアップグレード #kof2010 #gadget1</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2010/10/-kof2010-gadget1.html" />
    <id>tag:www.yamasita.jp,2010:/sheevaplug//12.2142</id>

    <published>2010-10-31T11:29:32Z</published>
    <updated>2010-10-31T11:40:09Z</updated>

    <summary>Sheeva Plug/玄柴や周辺機器を ハンガーネットにタイラップで縛り付け、...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="KURO-RS" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="SheevaPlug" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[Sheeva Plug/玄柴や周辺機器を
ハンガーネットにタイラップで縛り付け、
壁にかけられるようにした
俗称「壁掛けコンピュータキット」（ (c) @ktamura777 ）を<br>
11/5,6 に大阪南港ATC ITM棟 6Fで開催される
<a href="http://k-of.jp/2010/index.html">
関西オープンソース2010 / 関西コミュニティ大決戦</a>／
<a href="http://gadget1.jus.or.jp/r3/">
Gadget1 R3 Chitoseame</a>
に持込む予定。
<p>
ところが、今回はローカルなネットワーク内に無線LANのアクセスポイントを
提供いただけないので
自前でアクセスポイントを用意しなければならなくなった。
<p>
仕方がないので、La fonera とそれを玄柴に接続するために、
5ポートの Fast Ethernet HUB とを追加した。
<p>
<a href="/sheevaplug/2010/10/101031_1l.jpg" target="_blank">
<img src="/sheevaplug/2010/10/101031_1s.jpg"></a>
<p>
これで、この１枚で<br>
・Linux マシン（Web サーバ、DHCP サーバ、ダイアルアップサーバ等）<br>
・無線 LAN アクセスポイント<br>
・Fast Ethernet HUB<br>
・赤外線学習リモコン<br>
・Web カメラ<br>
と、オールインワンの持ち運びサーバ環境ができた。
<p>
まぁ、これの話題だけでも十分皆さんとお話できますが、
<a href="http://k-of.jp/2010/index.html">
関西オープンソース2010 / 関西コミュニティ大決戦</a>／
<a href="http://gadget1.jus.or.jp/r3/">
Gadget1 R3 Chitoseame</a>
には、これを使ったもっとスゲーの、持込みます。<br>
ご期待下さい。
]]>
        
    </content>
</entry>

<entry>
    <title>チョロＱ制御ライブラリの作成</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2010/10/post-79.html" />
    <id>tag:www.yamasita.jp,2010:/sheevaplug//12.2140</id>

    <published>2010-10-23T12:19:53Z</published>
    <updated>2010-10-23T12:25:47Z</updated>

    <summary> ロボアクターと同様、チョロＱ制御ライブラリを作る ライブラリの作成 root@...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
        <category term="KURO-RS" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="玄柴(KURO-SHEEVA)" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[<a href="http://www.yamasita.jp/sheevaplug/2010/08/post-76.html">
ロボアクター</a>と同様、チョロＱ制御ライブラリを作る

<h2>ライブラリの作成</h2>
<pre>
root@debian:~# cd /usr/local/lib/kuro-rs/choro-q_a/
root@debian:/usr/local/lib/kuro-rs/choro-q_a# vi libchoro-q_a.sh
	:
	:
root@debian:/usr/local/lib/kuro-rs/choro-q_a# cat !$
cat libchoro-q_a.sh
RS_SEND=${RS_SEND:-/usr/local/bin/rs_send}
CHOROQADIR=${CHOROQADIR:-/usr/local/lib/kuro-rs/choro-q_a}
CHOROQACHANNEL=${CHOROQACHANNEL:-1}
CHOROQAPORT=${CHOROQAPORT:-/dev/ttyUSB0}

choroqa_forward() {
        $RS_SEND $CHOROQADIR/BUTTON_F $CHOROQACHANNEL $CHOROQAPORT
}

choroqa_forwardleft() {
        $RS_SEND $CHOROQADIR/BUTTON_FL $CHOROQACHANNEL $CHOROQAPORT
}

choroqa_forwardright() {
        $RS_SEND $CHOROQADIR/BUTTON_FR $CHOROQACHANNEL $CHOROQAPORT
}

choroqa_forwarddash() {
        $RS_SEND $CHOROQADIR/BUTTON_FD $CHOROQACHANNEL $CHOROQAPORT
}

choroqa_back() {
        $RS_SEND $CHOROQADIR/BUTTON_B $CHOROQACHANNEL $CHOROQAPORT
}

choroqa_backleft() {
        $RS_SEND $CHOROQADIR/BUTTON_BL $CHOROQACHANNEL $CHOROQAPORT
}

choroqa_backright() {
        $RS_SEND $CHOROQADIR/BUTTON_BR $CHOROQACHANNEL $CHOROQAPORT
}

choroqa_backdash() {
        $RS_SEND $CHOROQADIR/BUTTON_BD $CHOROQACHANNEL $CHOROQAPORT
}

root@debian:/usr/local/lib/kuro-rs/choro-q_a#

</pre>


<h2>テストプログラムの作成</h2>

<pre>
root@debian:/usr/local/lib/kuro-rs/choro-q_a# cd
root@debian:~# mkdir choro-q_a
root@debian:~# cd !$
cd choro-q_a
root@debian:~/choro-q_a# vi test.sh
	:
	:
	:
root@debian:~/choro-q_a# cat test.sh
#!/bin/sh

. /usr/local/lib/kuro-rs/choro-q_a/libchoro-q_a.sh

CHOROQAPORT=/dev/ttyUSB0



choroqa_forward
choroqa_forwardleft
choroqa_forwardright
choroqa_forwarddash
choroqa_back
choroqa_backleft
choroqa_backright
choroqa_backdash
root@debian:~/choro-q_a#
</pre>

<h2>テスト</h2>
<pre>
root@debian:~/choro-q_a# sh -x test.sh
+ . /usr/local/lib/kuro-rs/choro-q_a/libchoro-q_a.sh
+ RS_SEND=/usr/local/bin/rs_send
+ CHOROQADIR=/usr/local/lib/kuro-rs/choro-q_a
+ CHOROQACHANNEL=1
+ CHOROQAPORT=/dev/ttyUSB0
+ CHOROQAPORT=/dev/ttyUSB0
+ choroqa_forward
+ /usr/local/bin/rs_send /usr/local/lib/kuro-rs/choro-q_a/BUTTON_F 1 /dev/ttyUSB0
/usr/local/lib/kuro-rs/choro-q_a/BUTTON_F - 1 - /dev/ttyUSB0
Send File : [/usr/local/lib/kuro-rs/choro-q_a/BUTTON_F]
+ choroqa_forwardleft
test.sh: 1: choroqa_forwardleft: not found
+ choroqa_forwardright
+ /usr/local/bin/rs_send /usr/local/lib/kuro-rs/choro-q_a/BUTTON_FR 1 /dev/ttyUSB0
/usr/local/lib/kuro-rs/choro-q_a/BUTTON_FR - 1 - /dev/ttyUSB0
Send File : [/usr/local/lib/kuro-rs/choro-q_a/BUTTON_FR]
+ choroqa_forwarddash
+ /usr/local/bin/rs_send /usr/local/lib/kuro-rs/choro-q_a/BUTTON_FD 1 /dev/ttyUSB0
/usr/local/lib/kuro-rs/choro-q_a/BUTTON_FD - 1 - /dev/ttyUSB0
Send File : [/usr/local/lib/kuro-rs/choro-q_a/BUTTON_FD]
+ choroqa_back
+ /usr/local/bin/rs_send /usr/local/lib/kuro-rs/choro-q_a/BUTTON_B 1 /dev/ttyUSB0
/usr/local/lib/kuro-rs/choro-q_a/BUTTON_B - 1 - /dev/ttyUSB0
Send File : [/usr/local/lib/kuro-rs/choro-q_a/BUTTON_B]
+ choroqa_backleft
+ /usr/local/bin/rs_send /usr/local/lib/kuro-rs/choro-q_a/BUTTON_BL 1 /dev/ttyUSB0
/usr/local/lib/kuro-rs/choro-q_a/BUTTON_BL - 1 - /dev/ttyUSB0
Send File : [/usr/local/lib/kuro-rs/choro-q_a/BUTTON_BL]
+ choroqa_backright
+ /usr/local/bin/rs_send /usr/local/lib/kuro-rs/choro-q_a/BUTTON_BR 1 /dev/ttyUSB0
/usr/local/lib/kuro-rs/choro-q_a/BUTTON_BR - 1 - /dev/ttyUSB0
Send File : [/usr/local/lib/kuro-rs/choro-q_a/BUTTON_BR]
+ choroqa_backdash
+ /usr/local/bin/rs_send /usr/local/lib/kuro-rs/choro-q_a/BUTTON_BD 1 /dev/ttyUSB0
/usr/local/lib/kuro-rs/choro-q_a/BUTTON_BD - 1 - /dev/ttyUSB0
Send File : [/usr/local/lib/kuro-rs/choro-q_a/BUTTON_BD]
root@debian:~/choro-q_a#
</pre>
動くことは動くけど、
チョロＱが KURO-RS の赤外線の届く範囲外に
出てしまってイマイチ制御できない。<br>
CAUL と同じと言えば同じだが、、、
]]>
        
    </content>
</entry>

<entry>
    <title>関西オープンソース2010 / 関西コミュニティ大決戦 / Gadget1 R3 Chitoseame 参画 #kof2010 #gadget1</title>
    <link rel="alternate" type="text/html" href="http://www.yamasita.jp/sheevaplug/2010/10/2010-gadget1-r3-chitoseame-kof2010-gadget1.html" />
    <id>tag:www.yamasita.jp,2010:/sheevaplug//12.2139</id>

    <published>2010-10-18T14:24:46Z</published>
    <updated>2010-10-18T14:29:40Z</updated>

    <summary>11/5,6 に大阪南港ATC ITM棟 6Fで開催される 関西オープンソース2...</summary>
    <author>
        <name>yasunari</name>
        <uri>http://www.yamasita.jp</uri>
    </author>
    
    
    <content type="html" xml:lang="ja" xml:base="http://www.yamasita.jp/sheevaplug/">
        <![CDATA[11/5,6 に大阪南港ATC ITM棟 6Fで開催される
<a href="http://k-of.jp/2010/index.html">
関西オープンソース2010 / 関西コミュニティ大決戦</a> に
<a href="http://gadget1.jus.or.jp/r3/">
Gadget1 R3 Chitoseame</a>
から今年も参画します。
<p>
例年は「LinkStation / 玄箱をハックしよう」というテーマで
参画していますが、今年は「ハックしよう」というテーマで。<br>
<a href="http://k-of.jp/2010/list_booth.html#Gadget1">
ブース</a>は、マーレ広場のステージに向かって右側、<br>
<a href="http://k-of.jp/2010/list_seminar.html#23">
セッション</a>は 11/6(土) 13:00-13:25 ITM棟 6F M3 にて。
<p>
今年は Gadget1 枠なので、ぶっ飛ばします（意味不明）<br>
皆さん、是非おこし下さい！]]>
        
    </content>
</entry>

</feed>
