Tellstick not found on Centos

Moderator: Telldus

danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Tellstick not found on Centos

Post by danardf »

Hi.

I had an old telldus version and i made an update from 2.0.4. to 2.1.1 just to include some new receivers.(with learn functions)
Works fine on windows.

But under linux with the last version, impossible to find the tellstick basic key.
I use CentOS Linux 5.2 under the kernel 2.6.18-92.1.22.el5 (not realy possible to making update on the server for any reasons)
telldusd daemon starting up
Trying to execute action, but no controller found. Rescanning USB ports
No contoller (TellStick) found after one retry. Giving up.
libftdi is already installed.
A symbolic link has been created : /dev/tellstick -> ttyUSB0
lsusb gives : Bus 005 Device 003: ID 1781:0c30 Multiple Vendors
modprobe ftdi_sio vendor=0x1781 product=0x0c30 has been launched.

I not understand anything with this device was detected with the old version and now it's impossible to detect it. :cry:

If you could help me please.

Regards

Franck
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

A small test has been realized, disconnecting the tellstick and reconnecting it,gives:
Dec 30 10:00:53 - kernel: usb 5-1: USB disconnect, address 3
Dec 30 10:00:53 - kernel: ftdi_sio ttyUSB0: FTDI USB Serial Device converter now disconnected from ttyUSB0
Dec 30 10:00:53 - kernel: ftdi_sio 5-1:1.0: device disconnected
Dec 30 10:00:59 - kernel: usb 5-1: new full speed USB device using uhci_hcd and address 4
Dec 30 10:00:59 - kernel: usb 5-1: configuration #1 chosen from 1 choice
Dec 30 10:00:59 - kernel: ftdi_sio 5-1:1.0: FTDI USB Serial Device converter detected
Dec 30 10:00:59 - kernel: drivers/usb/serial/ftdi_sio.c: Detected FT232BM
Dec 30 10:00:59 - kernel: usb 5-1: FTDI USB Serial Device converter now attached to ttyUSB0
So, the device is recognised well.
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

Hi and happy new year at all.

For informations, i did back under 2.0.4, all works fine and even my receiver.
micke.prag
Site Admin
Posts: 2243
Joined: Fri Mar 17, 2023 9:45 am
Location: Lund
Contact:

Re: Tellstick not found on Centos

Post by micke.prag »

Please unload ftdi_sio. It may not be used with >= 2.1.0
Micke Prag
Software
Telldus Technologies
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

Hi

Great information.

I'll try it and i'll let you know. :)
As soon as i have some free times. A little bit busy for moment.

thanks a lot

Franck
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

Hi.

Sorry for the late.

Just to making a little feedback.

I had any problem with another USB device (wview) which been broken all USB links and TellStick 2.0.4 was break down.
So, i tried to follow what you said.
So tried to unloading ftdi_sio, and reinstall Tellstick 2.1.0, and it works fine now. (Thanks) :)

However, something is missing.
telldusd should start automatically, but there's no telldsud into /etc/init.d/
There's a specific file to write into this folder?
gflygt
Posts: 46
Joined: Fri Mar 17, 2023 9:45 am

Tellstick not found on Centos

Post by gflygt »

In Debian there is a 'skeleton' file in /etc/init.d/ directory, to copy to telldusd or whatever, edit it to fit your needs, and then make it executable with 'chmod 755 /etc/init.d/telldusd' and then (this goes for debian) run 'update-rc.d telldusd defaults' to make symlinks in the startup directories.

As I said this goes for Debian, but I think you have something similar in Centos.

Here comes the skeleton file from debian installation. I think it is maybe a bit 'too much', but anyway. You can make it much simpler. But to get an idea, look at other script in the /etc/init.d directory.

Code: Select all

#! /bin/sh
### BEGIN INIT INFO
# Provides:          telldusd
# Required-Start:    $remote_fs $syslog
# Required-Stop:     $remote_fs $syslog
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: Tellstick service daemon
# Description:       Tellstick service daemon controlling remote switches.
### END INIT INFO

# Author: Foo Bar <foobar@baz.org>
#
# Please remove the "Author" lines above and replace them
# with your own name if you copy and modify this script.

# Do NOT "set -e"

# PATH should only include /usr/* if it runs after the mountnfs.sh script
PATH=/sbin:/usr/sbin:/bin:/usr/bin
DESC="Tellstick service daemon"
NAME=telldusd
DAEMON=/usr/sbin/$NAME
DAEMON_ARGS=""
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME

# Exit if the package is not installed
[ -x "$DAEMON" ] || exit 0

# Read configuration variable file if it is present
[ -r /etc/default/$NAME ] && . /etc/default/$NAME

# Load the VERBOSE setting and other rcS variables
. /lib/init/vars.sh

# Define LSB log_* functions.
# Depend on lsb-base (>= 3.2-14) to ensure that this file is present
# and status_of_proc is working.
. /lib/lsb/init-functions

#
# Function that starts the daemon/service
#
do_start()
{
	# Return
	#   0 if daemon has been started
	#   1 if daemon was already running
	#   2 if daemon could not be started
	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON --test > /dev/null \
		|| return 1
	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- \
		$DAEMON_ARGS \
		|| return 2
	# Add code here, if necessary, that waits for the process to be ready
	# to handle requests from services started subsequently which depend
	# on this one.  As a last resort, sleep for some time.
}

#
# Function that stops the daemon/service
#
do_stop()
{
	# Return
	#   0 if daemon has been stopped
	#   1 if daemon was already stopped
	#   2 if daemon could not be stopped
	#   other if a failure occurred
	start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE --name $NAME
	RETVAL="$?"
	[ "$RETVAL" = 2 ] && return 2
	# Wait for children to finish too if this is a daemon that forks
	# and if the daemon is only ever run from this initscript.
	# If the above conditions are not satisfied then add some other code
	# that waits for the process to drop all resources that could be
	# needed by services started subsequently.  A last resort is to
	# sleep for some time.
	start-stop-daemon --stop --quiet --oknodo --retry=0/30/KILL/5 --exec $DAEMON
	[ "$?" = 2 ] && return 2
	# Many daemons don't delete their pidfiles when they exit.
	rm -f $PIDFILE
	return "$RETVAL"
}

#
# Function that sends a SIGHUP to the daemon/service
#
do_reload() {
	#
	# If the daemon can reload its configuration without
	# restarting (for example, when it is sent a SIGHUP),
	# then implement that here.
	#
	start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE --name $NAME
	return 0
}

case "$1" in
  start)
	[ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME"
	do_start
	case "$?" in
		0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;;
		2) [ "$VERBOSE" != no ] && log_end_msg 1 ;;
	esac
	;;
  stop)
	[ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME"
	do_stop
	case "$?" in
		0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;;
		2) [ "$VERBOSE" != no ] && log_end_msg 1 ;;
	esac
	;;
  status)
	status_of_proc "$DAEMON" "$NAME" && exit 0 || exit $?
	;;
  #reload|force-reload)
	#
	# If do_reload() is not implemented then leave this commented out
	# and leave 'force-reload' as an alias for 'restart'.
	#
	#log_daemon_msg "Reloading $DESC" "$NAME"
	#do_reload
	#log_end_msg $?
	#;;
  restart|force-reload)
	#
	# If the "reload" option is implemented then remove the
	# 'force-reload' alias
	#
	log_daemon_msg "Restarting $DESC" "$NAME"
	do_stop
	case "$?" in
	  0|1)
		do_start
		case "$?" in
			0) log_end_msg 0 ;;
			1) log_end_msg 1 ;; # Old process is still running
			*) log_end_msg 1 ;; # Failed to start
		esac
		;;
	  *)
		# Failed to stop
		log_end_msg 1
		;;
	esac
	;;
  *)
	#echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2
	echo "Usage: $SCRIPTNAME {start|stop|status|restart|force-reload}" >&2
	exit 3
	;;
esac

:
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

pffff.... I rebooted my server before making modifications, just to be sure .... but unfortunatelly, impossible to detect the device.
I unloaded fdti_sio like this.

# modprobe -r ftdi_sio

I launched this cmd manually : # telldusd

lsusb result:

Code: Select all

# lsusb
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 001: ID 0000:0000
Bus 004 Device 001: ID 0000:0000
Bus 003 Device 001: ID 0000:0000
Bus 005 Device 003: ID 1781:0c30 Multiple Vendors
Bus 005 Device 001: ID 0000:0000
# tdtool -l gives:

Code: Select all

tdtool -l
Number of devices: 6
1       d211    OFF
2       d212    OFF
3       d213    OFF
4       d214    OFF
5       d215    OFF
6       d216    OFF
But tdtool --on 6 gives: Turning on device 6, d216 - TellStick not found

And message log gives:
Feb 14 06:16:11 -- telldusd: Trying to execute action, but no controller found. Rescanning USB ports
Feb 14 06:16:11 -- telldusd: No contoller (TellStick) found after one retry. Giving up.
I haven't any ttyUSB* into /dev folder.

into /etc/udev/rules.d/99-tellstick.rules, i have this:

Code: Select all

KERNEL=="ttyUSB*", BUS=="usb", SYSFS{idVendor}=="1781", SYSFS{idProduct}=="0c30", NAME="tellstick", GROUP="plugdev"
And more, when i try to connect on my server through putty, there's a long latency after the entered password and the prompt until telldusd is running.
Once telldusd stoped, no problem.

i understand anything

Something wrong side USB controller (Config).

Thanks for your help.
micke.prag
Site Admin
Posts: 2243
Joined: Fri Mar 17, 2023 9:45 am
Location: Lund
Contact:

Re: Tellstick not found on Centos

Post by micke.prag »

Try unloading ftdi_sio before starting telldusd.
Micke Prag
Software
Telldus Technologies
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

Sorry, but like i said, ftdi_sio is already unloaded with this cmd : # modprobe -r ftdi_sio
[root@ ~]# modprobe -r ftdi_sio
[root@ ~]# telldusd
[root@ ~]# tdtool --on 6
Turning on device 6, d216 - TellStick not found
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

micke.prag wrote:Try unloading ftdi_sio before starting telldusd.
modprobe -r is the good cmd line?
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

Hmmmm ... Really no idea? :?
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

Hi all.

It's a pity to have a Tellstick device and which cannot be use. :cry:
danardf
Posts: 41
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by danardf »

Hi..

Sorry, but your last version doesn't work. :cry:
Without help from anybody, i was forced to back under 2.0.4 and works fine.
Maybe something worng with the new version!?.
aduclert
Posts: 1
Joined: Fri Mar 17, 2023 9:45 am

Re: Tellstick not found on Centos

Post by aduclert »

Hi danardf,

Did you try again to have a version >= 2.1 working successfully on linux, without having the message "TellStick not found" ?

Thanks.

Aymeric
Post Reply