Originally posted by: <email address deleted>
Hallo Zusammen,
ich versuche seit ein paar Tagen FHEM und CUL unter dem Readynas DUO
zum laufen zu bringen.
Perl und die Perl-Module liessen sich problemlos installieren. Leider
wird CUL nicht sauber "erkannt".
Aus dem Syslog:
----
Mar 18 21:52:52 NAS kernel: drivers/usb/serial/usb-serial.c: USB
Serial Driver core
Mar 18 21:52:58 NAS kernel: drivers/usb/serial/usb-serial.c: USB
Serial support registered for FTDI USB Serial Device
Mar 18 21:52:58 NAS kernel: usbcore: registered new driver ftdi_sio
Mar 18 21:52:58 NAS kernel: drivers/usb/serial/ftdi_sio.c: v1.4.3:USB
FTDI Serial Converters Driver
Mar 18 22:18:36 NAS kernel: usb 3-1: new full speed USB device using
uhci_hcd and address 2
Mar 18 22:18:37 NAS kernel: usb 3-1: configuration #1 chosen from 1
choice
Mar 18 22:18:37 NAS kernel: ftdi_sio 3-1:1.0: FTDI USB Serial Device
converter detected
Mar 18 22:18:37 NAS kernel: drivers/usb/serial/ftdi_sio.c: Detected
FT2232C
Mar 18 22:18:37 NAS kernel: usb 3-1: FTDI USB Serial Device converter
now attached to ttyUSB0
Mar 18 22:18:37 NAS kernel: ftdi_sio 3-1:1.1: FTDI USB Serial Device
converter detected
Mar 18 22:18:37 NAS kernel: drivers/usb/serial/ftdi_sio.c: Detected
FT2232C
Mar 18 22:18:37 NAS kernel: usb 3-1: FTDI USB Serial Device converter
now attached to ttyUSB1
Mar 18 22:18:46 NAS usb.agent: ... no modules for USB product 3eb/204b/
0
Mar 18 22:18:46 NAS usb.agent: ... no modules for USB product 3eb/204b/
0
Mar 18 22:19:47 NAS kernel: drivers/usb/serial/ftdi_sio.c:
ftdi_set_termios FAILED to set databits/stopbits/parity
Mar 18 22:19:47 NAS kernel: drivers/usb/serial/ftdi_sio.c:
ftdi_set_termios urb failed to set baudrate
Mar 18 22:19:47 NAS kernel: drivers/usb/serial/ftdi_sio.c: urb failed
to clear flow control
Mar 18 22:19:47 NAS kernel: drivers/usb/serial/ftdi_sio.c:
update_mctrl Error from MODEM_CTRL urb: DTR HIGH, RTS HIGH
Mar 18 22:19:47 NAS kernel: Unable to handle kernel NULL pointer
dereference
----
Wenn ich das hier so richtig interpretiere:
Mar 18 22:18:46 NAS usb.agent: ... no modules for USB product 3eb/204b/
0
Fehlen Kernel-Module oder Parameter.
usbserial.ko
sowie
ftdi_sio.ko
und die Module für Modem habe ich kompiliert und mit "insmod" geladen.
Da half der Synology Thread weiter. Leider stehe ich immer noch mit
der selben Message an.
Aus dem FHEM.log (je nach Konfiguration):
(Configuration with /ttyUSB0)
2011.03.18 00:39:15 2: FHEMWEB port 8083 opened
2011.03.18 00:39:15 3: CUL opening CUL device /dev/ttyUSB0
2011.03.18 00:39:15 3: Can't open /dev/ttyUSB0: No such device
(Configuration with /ttyACM0)
2011.03.18 00:50:15 2: FHEMWEB port 8083 opened
2011.03.18 00:50:15 3: CUL opening CUL device /dev/ttyACM0
2011.03.18 00:50:15 3: Can't open /dev/ttyACM0: No such device
Die Devices werden angelegt und z.B. ein USB Stick wird erkannt und
eingebunden.
Hier das Posting in Englisch aus dem READYNAS-Forum.
http://www.readynas.com/forum/viewtopic.php?f=36&t=51644
Hat irgend jemand eine Idee was ich testen/checken muss oder wo es im
Moment harkt? FHEM läuft, der Kernel macht zicken....
Gruss,
Axel
--
Sie haben diese Nachricht erhalten, da Sie der Google Groups-Gruppe FHEM users beigetreten sind.
Wenn Sie Nachrichten in dieser Gruppe posten möchten, senden Sie eine E-Mail an fhem-users@googlegroups.com.
Wenn Sie aus dieser Gruppe austreten möchten, senden Sie eine E-Mail an fhem-users+unsubscribe@googlegroups.com.
Besuchen Sie die Gruppe unter http://groups.google.com/group/fhem-users?hl=de, um weitere Optionen zu erhalten.
> usbserial.ko
> sowie
> ftdi_sio.ko
> und die Module für Modem habe ich kompiliert und mit "insmod" geladen.
Bitte http://fhem.de/commandref.html#CULdefine genau durchlesen.
1. cdc_acm.ko ist die erste Wahl
2. usbserial.ko ist Notloesung, muss mit Parameter geladen werden
3. ftdi_sio.ko ist fuer die ELV Produkte (FHZ/EM1010PC/etc) da, und ist fuer
CUL nutzlos.
--
Sie haben diese Nachricht erhalten, da Sie der Google Groups-Gruppe FHEM users beigetreten sind.
Wenn Sie Nachrichten in dieser Gruppe posten möchten, senden Sie eine E-Mail an fhem-users@googlegroups.com.
Wenn Sie aus dieser Gruppe austreten möchten, senden Sie eine E-Mail an fhem-users+unsubscribe@googlegroups.com.
Besuchen Sie die Gruppe unter http://groups.google.com/group/fhem-users?hl=de, um weitere Optionen zu erhalten.
Originally posted by: <email address deleted>
Merci - jetzt läuft es.
Hier das HOW-TO....
How to install FHEM 5.0 on a Netgear ReadyNAS Duo
Document created and compiled by A. Thobaben referencing various other
sources.
This "How-To" is provided "as it is" - read through it, understand it
and use it at your OWN RISK.
The Author is not responsible of the loss of time, date and nerves.
Considering donation to the red cross to help japan and step away from
nuklear power generation - consider alternatives.
1) Update to the latestet Firmware (4.1.7)
2) Get SSH access:
A. Download the EnableRootSSH extension. I've used the following
link:
http://www.readynas.com/download/addons/4.00/EnableRootSSH_1.0.bin
B. Go in the ReadyNAS FrontView with your browser and go to System -
> Update -> Local Update
C. Upload the EnableRootSSH binary file. The ReadyNAS verifies that
content and if it is correct it displays a description of the addon.
3) Get the so called development enviroment up and running
Follow the instructions under: http://www.readynas.com/?p=145
Create the missing system link between the gcc binary and cc
otherwise the make command with the GPL Sources will fail. Use the
following command:
cd /usr/bin
ln -sn cc gcc
4) Create a folder "GPL" under /c/ and download the GPL Sources
(~480MB)using the following commands:
cd /c
mkdir GPL
cd GPL
wget http://www.readynas.com/download/GPL/RNR4_RND4_RND2_4.1.7_WW_src.zip
>> Hint: check the following URL for your NAS: http://www.readynas.com/?page_id=2324
<<
unzip RNR4_RND4_RND2_4.1.7_WW_src.zip
5) Setup the configuration for padre. Therefore "cd" to the linux
kernel directory
cd /c/GPL/linux-2.6.17.14/
and run
cp arch/padre/defconfig .config
6) There is a hardcoded cross-compile setup in the kernel build, which
needs to be fixed. Edit arch/padre/Makefile, and replace the line that
starts with "CROSS_COMPILE" with one like this
CROSS_COMPILE ?=
7) Install the APT-Addon - follow the instructions under:
http://www.readynas.com/?p=4216
8) Install libncurses5-dev using the following command:
apt-get install libncurses5-dev
9) Configure the compilation of the missing USB Modules using the
following command:
make menuconfig
>> Hint: make menuconfig take quite a while on the little box. In
the end it gives you the installation screen to configure the kernel
modules.
With this tool you can end up easily in reinstalling everthing form
defaults. I did this myself... .
You have to configure the modem usb drivers (we are looking for the
cdc_acm module).
USE AT YOUR OWN RISK! <<
compile the modules:
make modules
>> Hint: Takes time as well... <<
and install the compiled modules using:
make modules_install
10) Reinstall Perl, it's tools and libraries
apt-get --reinstall install perl perl-base perl-modules perl-doc
11) update CPAN
apt-get install cpan
>> Hint: Endless session with a couple of questions in between. You
will sit longtime in fornt of the terminal but needed.... <<
12) install Device::Serial in a version greater than 1.x
cpan install Device::SerialPort
13) Install the screen tool
apt-get install screen
14) Install FHEM 5.0 from sources or from .deb file
15) Configure FHEM with you setting and devices (here my sample)
#
# pgm2 / autocreate configfile. Take a look at the other
examples for more.
#
attr global logfile /var/log/fhem/fhem-%Y-%m.log
attr global modpath /usr/share/fhem # where
our FHEM directory is
attr global port 7072 # our TCP/IP port
(localhost only)
attr global statefile /var/log/fhem/fhem.save # where to
save the state of the devices
attr global verbose 3 # "normal" verbosity
(min 1, max 5)
define CUL CUL /dev/ttyACM0 1234
#define FHEM FHEM /dev/USB0
define WEB FHEMWEB 8083 global
define WEBS FHEMWEB 8084 global
attr WEBS smallscreen
# Fake logfile, to access the global log
define Logfile FileLog /var/log/fhem/fhem-%Y-%m.log fakelog
define Arbeitszimmer FS20 1234 10
define Kinderzimmer FS20 1234 20
define Mobil_Lampe FS20 1234 30
# Comment out for initial testing....
#
# define autocreate autocreate
# attr autocreate autosave
# attr autocreate device_room %TYPE
# attr autocreate filelog /var/log/fhem/%NAME-%Y.log
# attr autocreate weblink
# attr autocreate weblink_room Plots
16) Flash CUL with the latest firmware (culfw 1.40) if needed
17) Reboot the whole thing
18) Load the module by running:
insmod cdc_acm.ko
19) Attach the CUL to the USB Slot (I used the front one)and check the
syslog:
tail --lines=100 /var/log/syslog
You should see something like this:
...
Mar 21 21:10:44 Talacker-NAS kernel: usb 3-1: new full speed USB
device using uhci_hcd and address 6
Mar 21 21:10:44 Talacker-NAS kernel: usb 3-1: configuration #1
chosen from 1 choice
Mar 21 21:10:44 Talacker-NAS kernel: cdc_acm 3-1:1.0: ttyACM0: USB
ACM device
Mar 21 21:10:54 Talacker-NAS usb.agent: ... no modules for USB
product 3eb/204b/0
....
Only the "no modules message" looks scary.
20) Check with the following:
lsusb
Gives you:
Bus 003 Device 006: ID 03eb:204b Atmel Corp. <<< This is your
CUL...
Bus 003 Device 001: ID 0000:0000
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 001: ID 0000:0000
21) test the usb device with
screen /dev/ttyACM0
press "V" (Shift-V) and you should see the Version String of the CUL
Firmware
unplug the CUL for some seconed to kill screen...
22) start FHEM
perl /usr/bin/fhem.pl /etc/fhem.cfg
23) Check fhem.log by using:
tail -lines=100 /var/log/fhem/YOURFHEM.LOG
You should not see any warning and the device must be read.
Might looks like this:
....
2011.03.21 23:35:14 3: CUL opening CUL device /dev/ttyACM0
2011.03.21 23:35:14 3: CUL device opened
2011.03.21 23:35:15 2: FHEMWEB port 8083 opened
2011.03.21 23:35:15 2: FHEMWEB port 8084 opened
2011.03.21 23:35:15 0: Server started (version 5.0 from 2010-08-15
($Id: fhem.pl,v 1.110 2010-08-14 10:35:12 rudolfkoenig Exp $), pid
12398)
2011.03.21 23:35:46 2: FS20 set Arbeitszimmer on
2011.03.21 23:35:56 2: FS20 set Arbeitszimmer off
....
24) Startup your webbrowser and navigate to the NAS URL
http://your-ReadyNAS:8083/fhem
You should see the settings under "unsorted" and you can switch on
the lights...
Works fine :-)
Regards,
Axel Thobaben
--
Sie haben diese Nachricht erhalten, da Sie der Google Groups-Gruppe FHEM users beigetreten sind.
Wenn Sie Nachrichten in dieser Gruppe posten möchten, senden Sie eine E-Mail an fhem-users@googlegroups.com.
Wenn Sie aus dieser Gruppe austreten möchten, senden Sie eine E-Mail an fhem-users+unsubscribe@googlegroups.com.
Besuchen Sie die Gruppe unter http://groups.google.com/group/fhem-users?hl=de, um weitere Optionen zu erhalten.
Originally posted by: <email address deleted>
How to install FHEM 5.0 on a Netgear ReadyNAS Duo
Document created and compiled by A. Thobaben referencing various other
sources.
This "How-To" is provided "as it is" - read through it, understand it
and use it at your OWN RISK.
The Author is not responsible of the loss of time, date and nerves.
Considering donation to the red cross to help japan and step away from
nuklear power generation - consider alternatives.
1) Update to the latestet Firmware (4.1.7)
2) Get SSH access:
A. Download the EnableRootSSH extension. I've used the following
link:
http://www.readynas.com/download/addons/4.00/EnableRootSSH_1.0.bin
B. Go in the ReadyNAS FrontView with your browser and go to System -
> Update -> Local Update
C. Upload the EnableRootSSH binary file. The ReadyNAS verifies that
content and if it is correct it displays a description of the addon.
3) Get the so called development enviroment up and running
Follow the instructions under: http://www.readynas.com/?p=145
Create the missing system link between the gcc binary and cc
otherwise the make command with the GPL Sources will fail. Use the
following command:
cd /usr/bin
ln -sn cc gcc
4) Create a folder "GPL" under /c/ and download the GPL Sources
(~480MB)using the following commands:
cd /c
mkdir GPL
cd GPL
wget http://www.readynas.com/download/GPL/RNR4_RND4_RND2_4.1.7_WW_src.zip
>> Hint: check the following URL for your NAS: http://www.readynas.com/?page_id=2324
<<
unzip RNR4_RND4_RND2_4.1.7_WW_src.zip
5) Setup the configuration for padre. Therefore "cd" to the linux
kernel directory
cd /c/GPL/linux-2.6.17.14/
and run
cp arch/padre/defconfig .config
6) There is a hardcoded cross-compile setup in the kernel build, which
needs to be fixed. Edit arch/padre/Makefile, and replace the line that
starts with "CROSS_COMPILE" with one like this
CROSS_COMPILE ?=
7) Install the APT-Addon - follow the instructions under:
http://www.readynas.com/?p=4216
8) Install libncurses5-dev using the following command:
apt-get install libncurses5-dev
9) Configure the compilation of the missing USB Modules using the
following command:
make menuconfig
>> Hint: make menuconfig take quite a while on the little box. In
the end it gives you the installation screen to configure the kernel
modules.
With this tool you can end up easily in reinstalling everthing form
defaults. I did this myself... .
You have to configure the modem usb drivers (we are looking for the
cdc_acm module).
USE AT YOUR OWN RISK! <<
compile the modules:
make modules
>> Hint: Takes time as well... <<
and install the compiled modules using:
make modules_install
10) Reinstall Perl, it's tools and libraries
apt-get --reinstall install perl perl-base perl-modules perl-doc
11) update CPAN
apt-get install cpan
>> Hint: Endless session with a couple of questions in between. You
will sit longtime in fornt of the terminal but needed.... <<
12) install Device::Serial in a version greater than 1.x
cpan install Device::SerialPort
13) Install the screen tool
apt-get install screen
14) Install FHEM 5.0 from sources or from .deb file
15) Configure FHEM with you setting and devices (here my sample)
#
# pgm2 / autocreate configfile. Take a look at the other
examples for more.
#
attr global logfile /var/log/fhem/fhem-%Y-%m.log
attr global modpath /usr/share/fhem # where
our FHEM directory is
attr global port 7072 # our TCP/IP port
(localhost only)
attr global statefile /var/log/fhem/fhem.save # where to
save the state of the devices
attr global verbose 3 # "normal" verbosity
(min 1, max 5)
define CUL CUL /dev/ttyACM0 1234
#define FHEM FHEM /dev/USB0
define WEB FHEMWEB 8083 global
define WEBS FHEMWEB 8084 global
attr WEBS smallscreen
# Fake logfile, to access the global log
define Logfile FileLog /var/log/fhem/fhem-%Y-%m.log fakelog
define Arbeitszimmer FS20 1234 10
define Kinderzimmer FS20 1234 20
define Mobil_Lampe FS20 1234 30
# Comment out for initial testing....
#
# define autocreate autocreate
# attr autocreate autosave
# attr autocreate device_room %TYPE
# attr autocreate filelog /var/log/fhem/%NAME-%Y.log
# attr autocreate weblink
# attr autocreate weblink_room Plots
16) Flash CUL with the latest firmware (culfw 1.40) if needed
17) Reboot the whole thing
18) Load the module by running:
insmod cdc_acm.ko
19) Attach the CUL to the USB Slot (I used the front one)and check the
syslog:
tail --lines=100 /var/log/syslog
You should see something like this:
...
Mar 21 21:10:44 Talacker-NAS kernel: usb 3-1: new full speed USB
device using uhci_hcd and address 6
Mar 21 21:10:44 Talacker-NAS kernel: usb 3-1: configuration #1
chosen from 1 choice
Mar 21 21:10:44 Talacker-NAS kernel: cdc_acm 3-1:1.0: ttyACM0: USB
ACM device
Mar 21 21:10:54 Talacker-NAS usb.agent: ... no modules for USB
product 3eb/204b/0
....
Only the "no modules message" looks scary.
20) Check with the following:
lsusb
Gives you:
Bus 003 Device 006: ID 03eb:204b Atmel Corp. <<< This is your
CUL...
Bus 003 Device 001: ID 0000:0000
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 001: ID 0000:0000
21) test the usb device with
screen /dev/ttyACM0
press "V" (Shift-V) and you should see the Version String of the CUL
Firmware
unplug the CUL for some seconed to kill screen...
22) start FHEM
perl /usr/bin/fhem.pl /etc/fhem.cfg
23) Check fhem.log by using:
tail -lines=100 /var/log/fhem/YOURFHEM.LOG
You should not see any warning and the device must be read.
Might looks like this:
....
2011.03.21 23:35:14 3: CUL opening CUL device /dev/ttyACM0
2011.03.21 23:35:14 3: CUL device opened
2011.03.21 23:35:15 2: FHEMWEB port 8083 opened
2011.03.21 23:35:15 2: FHEMWEB port 8084 opened
2011.03.21 23:35:15 0: Server started (version 5.0 from 2010-08-15
($Id: fhem.pl,v 1.110 2010-08-14 10:35:12 rudolfkoenig Exp $), pid
12398)
2011.03.21 23:35:46 2: FS20 set Arbeitszimmer on
2011.03.21 23:35:56 2: FS20 set Arbeitszimmer off
....
24) Startup your webbrowser and navigate to the NAS URL
http://your-ReadyNAS:8083/fhem
You should see the settings under "unsorted" and you can switch on
the lights...
Works fine :-)
Regards,
Axel Thobaben
--
Sie haben diese Nachricht erhalten, da Sie der Google Groups-Gruppe FHEM users beigetreten sind.
Wenn Sie Nachrichten in dieser Gruppe posten möchten, senden Sie eine E-Mail an fhem-users@googlegroups.com.
Wenn Sie aus dieser Gruppe austreten möchten, senden Sie eine E-Mail an fhem-users+unsubscribe@googlegroups.com.
Besuchen Sie die Gruppe unter http://groups.google.com/group/fhem-users?hl=de, um weitere Optionen zu erhalten.