NSLU2
| NSLU2 | |
|---|---|
| Spielereien mit der NSLU2 | |
| Status | Abgebrochen |
| OrganisatorIn | |
| InteressentInnen | Arkay3, Mischa |
| Bemerkungen | NSLU2 nicht mehr verfügbar. |
Inhaltsverzeichnis |
Was ist NSLU2?
Ein Fileserver von Linksys. Genaueres findet man hier.Beginn
Wir haben uns das WebFrontend der original Firmware angeguckt. Im grossen und ganzen unspannend. Ein USB-Stick wird sofort erkannt. Man kann auf die Daten zugreifen. Ausserdem die ueblichen Einstellungen (Passwoerter, Zugriff etc.).OpenWRT-Hack
Wir haben OpenWRT auf der NSLU2 installiert. Siehe dies fuer die Anleitung und UpSlug2 ist das Tool, die Firmware auf die NSLU2 zu bringen.
Es wird davon abgeraten die Installation ueber einen Router zu machen.
Am besten NSLU2 und einen Rechner in ein isoliertes Netzwerk (z.B. per Switch) stecken.
Anleitung von Openwrt. Damit wurde die NSLU2 auf DHCP gestellt, damit man nicht immer dumm nach der IP-Adresse suchen muss.
- Aber genau da gab es Probleme, weil sich im Prowenetz zwei dhcp-server sich um ihre Rollen streiten. Dieses Problem hat sich aus der ip-tables Konfiguration ergeben, seit wir wieder per Kabel im Nachbarnetz sind.
- Hoffe da kuemmert sich jemand drum.
- Ist erledigt.
- Hoffe da kuemmert sich jemand drum.
USB mit Openwrt
USB Storage
Done! http://nuwiki.openwrt.org/oldwiki/usbstoragehowto#modules.for.usb.2.0
USB BlueTooth
Die notwendigen Module:
bluez-hcidump - 1.42-1 - Bluetooth packet analyzer bluez-libs - 3.36-1 - Bluetooth library bluez-utils - 3.36-6 - Bluetooth utilities kmod-bluetooth - 2.6.26.6-ixp4xx-1 - Kernel support for Bluetooth devices
Starten:
root@OpenWrt:/etc/init.d/dbus enable root@OpenWrt:/etc/init.d/bluez-utils enable
Das device hochbringen:
root@OpenWrt:/etc/init.d# hciconfig hci0 down root@OpenWrt:/etc/init.d# hciconfig hci0 up
Wird erkannt:
root@OpenWrt:/etc/init.d# hciconfig hci0: Type: USB BD Address: 00:0C:55:FF:9D:A1 ACL MTU: 192:8 SCO MTU: 64:8 UP RUNNING RX bytes:696 acl:0 sco:0 events:22 errors:0 TX bytes:73 acl:0 sco:0 commands:21 errors:0
Scannt die Umgebung:
root@OpenWrt:/etc/init.d# hcitool scan Scanning ... 00:10:C6:26:92:A1 nichtschwimmer-laptop-0 00:1C:35:7A:37:3E Privatsphäre 00:1A:75:4E:BB:CD JP
root@OpenWrt:/etc/init.d# hcitool info 00:1C:35:7A:37:3E
Requesting information ...
BD Address: 00:1C:35:7A:37:3E
Device Name: Privatsphäre
LMP Version: 2.0 (0x3) LMP Subversion: 0x6cc
Manufacturer: Cambridge Silicon Radio (10)
Features: 0xbf 0xee 0x0f 0xc6 0x9a 0x39 0x00 0x00
<3-slot packets> <5-slot packets> <encryption> <slot offset>
<timing accuracy> <role switch> <sniff mode> <RSSI>
<channel quality> <SCO link> <HV3 packets> <u-law log>
<A-law log> <CVSD> <paging scheme> <power control>
<transparent SCO> <EDR ACL 2 Mbps> <EDR ACL 3 Mbps>
<inquiry with RSSI> <extended SCO> <EV5 packets>
<AFH cap. slave> <AFH class. slave> <3-slot EDR ACL>
<5-slot EDR ACL> <AFH cap. master> <AFH class. master>
<EDR eSCO 2 Mbps>
Pingen:
l2ping 00:19:63:11:7B:66
/etc/conf/bluetooth:
config hcid
option config /etc/bluetooth/hcid.conf
option enabled 1
config rfcomm
option config /etc/bluetooth/rfcomm.conf
option enabled 1
config dund
option listen true
option persist true
option msdun true
option interface dund
option unit 1
option pppdopts "ktune proxyarp 192.168.1.1:192.168.1.2 ms-dns 192.168.1.1"
option enabled 0
config pand
option listen true
option autozap true
option role "NAP"
option master true
option persist true
option enabled 0
/etc/bluetooth/hcid.conf:
#
# HCI daemon configuration file.
#
# HCId options
options {
# Automatically initialize new devices
autoinit yes;
# Security Manager mode
# none - Security manager disabled
# auto - Use local PIN for incoming connections
# user - Always ask user for a PIN
#
security auto;
# Pairing mode
# none - Pairing disabled
# multi - Allow pairing with already paired devices
# once - Pair once and deny successive attempts
pairing multi;
# Default PIN code for incoming connections
passkey "1111";
}
# Default settings for HCI devices
device {
# Local device name
# %d - device id
# %h - host name
name "%h";
# Local device class
class 0x000100;
# Default packet type
#pkt_type DH1,DM1,HV1;
# Inquiry and Page scan
iscan enable; pscan enable;
# Default link mode
# none - no specific policy
# accept - always accept incoming connections
# master - become master on incoming connections,
# deny role switch on outgoing connections
lm accept;
# Default link policy
# none - no specific policy
# rswitch - allow role switch
# hold - allow hold mode
# sniff - allow sniff mode
# park - allow park mode
lp rswitch,hold,sniff,park;
}
/etc/bluetooth/rfcomm.conf:
#
# RFCOMM configuration file.
#
#rfcomm0 {
# # Automatically bind the device at startup
# bind no;
#
# # Bluetooth address of the device
# device 11:22:33:44:55:66;
#
# # RFCOMM channel for the connection
# channel 1;
#
# # Description of the connection
# comment "Example Bluetooth device";
#}
Koppelung mit dem Handy:
echo "00:1C:35:7A:37:3E 1111" > /tmp/lib/bluetooth/01:FC:0E:FF:9D:A1/pincodes
Mac des Handys Pin Mac des Dongle
pand -n --connect 00:1C:35:7A:37:3E --role PANU
pand[2542]: Bluetooth PAN daemon version 3.36
pand[2542]: Connecting to 00:1C:35:7A:37:3E
pand[2542]: bnep0 connected
Links
http://nuwiki.openwrt.org/oldwiki/UsbAudioHowto2
http://linuxgazette.net/109/oregan3.html
http://www.novell.com/documentation/suse91/suselinux-adminguide/html/ch08s04.html
http://anyremote.sourceforge.net/
https://forum.openwrt.org/viewtopic.php?id=21211
http://www.crisos.org/dokuwiki/doku.php?id=documentation:wiki:bluez_play
http://www.bralug.de/wiki/Linux_und_Bluetooth
Debian-Hack
Ziel ist es Debian auf einer NSLU2 zu installieren. [DONE]
Das Vorgehen wie folgt:
Debian flashen
Mit Upslug2 wird zunaechst die fuer Debian geeignete Firmware aufgebracht. Das Verfahren ist wie bei OpenWRT. Damit ist nich nicht Debian installiert. Man hat nur einen Intaller auf der NSLU2, der automatisch laeuft, wenn man per SSH (Benutzername: Installer; Passwort: Install) auf die NSLU2 geht.
Debian auf externen Speicher installieren
Debian braucht mehr Speicher als der Installer. Daher benoetigt man einen externen Speicher (Stick, Festplatte), den man per USB an die NSLU2 bringen kann. Die Installation laeuft wie gewohnte Debianinstallationen - nur langsamer (Das vorliegende Geraet war auf dem Stand ab Werk, also noch nicht uebertaktet). U.U. ist es noetig, dem Installer klarzumachen, welche Pakete er fuer die Installation benoetigt. Da der Speicher auf der NSLU2 klein ist, muss das manuell geschehen.
An-/Ausschaltknopf konfigurieren
In der etc/inittab kann man die Zeile
ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
aendern:
ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -h now
Damit kann man das System durch Knopfdruck runterfahren. Sonst wird immer neu gestartet. Je nach Bedarf sollte man da entscheiden.
Weitere Konfiguration
Bitte folgende Debian-Hacks eintragen.
Projektideen
Terminal
http://chezphil.org/slugterm/ http://sokrates.mimuw.edu.pl/~sebek/openwrt/
Streams aufnehmen
https://lists.openwrt.org/pipermail/openwrt-devel/2007-October/001297.html
Scannerstation
http://blog.knecht-ruprecht.info/2008/01/nun-aber-wirklich-nslu2-sane-sanetwain_04.html
WLAN-Printserver
Die Schnecke soll Druckaufträge eines Rechners aus dem WLAN annehmen und an den Drucker weiterleiten.
BSD-Hacking (noch nicht getan)
Ich denke, dass diese Anleitung den einfachsten Weg beschreibt, NetBSD auf die NSLU2 zu bringen. Hier wird keine serielle Schnittstelle benoetigt, was leider bei dieser Anleitung vorausgesetzt wird.
Links
http://www.feyrer.de/NetBSD/bx/blosxom.cgi/index.front?-tags=nslu2
http://www.ende-der-vernunft.org/2007/04/07/umzug-auf-die-linksys-nslu2/