USB storage

From DD-WRT Wiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 12:00, 7 June 2006 (edit)
VeNoM (Talk | contribs)
m
← Previous diff
Revision as of 12:01, 7 June 2006 (edit) (undo)
VeNoM (Talk | contribs)
m
Next diff →
Line 8: Line 8:
The script below executes on every reboot all *.startup scripts located in /jffs/etc/config/ The script below executes on every reboot all *.startup scripts located in /jffs/etc/config/
<br /> <br />
 + console mode
> ~ # nvram set rc_startup=" > ~ # nvram set rc_startup="
> for I in `/bin/ls /jffs/etc/config/*.startup` > for I in `/bin/ls /jffs/etc/config/*.startup`
Line 14: Line 15:
> done > done
> " > "
- > ~ # nvram commit<br />+ > ~ # nvram commit
 + 
 + web interface mode
 + for I in `/bin/ls /jffs/etc/config/*.startup`
 + do
 + sh $I &
 + done
 + 
 +<br />
A startup script must be made to start usb drivers on every reboot. Create a file, usb.startup in /jffs/etc/config/ directory that contains this : A startup script must be made to start usb drivers on every reboot. Create a file, usb.startup in /jffs/etc/config/ directory that contains this :
<br /><br /> <br /><br />

Revision as of 12:01, 7 June 2006

First, install the folowing modules :

 ipkg install kmod-usb-uhci // this is for USB 1.1
 ipkg install kmod-usb-core
 ipkg install kmod-usb2
 ipkg install kmod-usb-storage



The script below executes on every reboot all *.startup scripts located in /jffs/etc/config/

 console mode
 > ~ # nvram set rc_startup="
 > for I in `/bin/ls /jffs/etc/config/*.startup`
 > do
 >    sh $I &
 > done
 > "
 > ~ # nvram commit
 web interface mode
 for I in `/bin/ls /jffs/etc/config/*.startup`
   do
     sh $I &
 done


A startup script must be made to start usb drivers on every reboot. Create a file, usb.startup in /jffs/etc/config/ directory that contains this :

#!/bin/sh
insmod /jffs/lib/modules/2.4.30/usbcore.o
insmod /jffs/lib/modules/2.4.30/ehci-hcd.o
insmod /jffs/lib/modules/2.4.30/scsi_mod.o
insmod /jffs/lib/modules/2.4.30/usb-storage.o
insmod /jffs/lib/modules/2.4.30/uhci.o



This is it. Here's my dmesg from Asus WL-500gP

dmesg

SCSI subsystem driver Revision: 1.00
Initializing USB Mass Storage driver...
usb.c: registered new driver usb-storage
USB Mass Storage support registered.
uhci.c: USB Universal Host Controller Interface driver v1.1
PCI: Enabling device 01:03.0 (0000 -> 0001)
uhci.c: USB UHCI at I/O 0x100, IRQ 2
usb.c: new USB bus registered, assigned bus number 2
hub.c: USB hub found
hub.c: 2 ports detected
PCI: Enabling device 01:03.1 (0000 -> 0001)
uhci.c: USB UHCI at I/O 0x120, IRQ 2
usb.c: new USB bus registered, assigned bus number 3
hub.c: USB hub found
hub.c: 2 ports detected