Is there interest for Tellstick (Duo) support?
Moderator: leecollings
-
- Posts: 6
- Joined: Thursday 08 September 2016 10:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Is there interest for Tellstick (Duo) support?
It worked, as soon as i set the permissions to correctly. Thanks! (Check marked the Execute/Enter on the scripts).
But creating two scripts for each switch is pretty tedious.
Id rather use the script below. Anyone had any luck getting it to work?
But creating two scripts for each switch is pretty tedious.
Id rather use the script below. Anyone had any luck getting it to work?
Brighthead wrote:In the below script I've taken a slightly different path than in the scripts above: Instead of using the device id I use the device name. This means that the script does not need to be changed whenever I add or remove a device from Domoticz. Obviously tellstick.conf needs to be changed so that the devices have the exact same name in tellstick.conf and Domoticz.
I've also implemented basic DIM functionality in addition to just ON and OFF. This setup works perfectly for me. I'm running Domoticz and tdtool on a Raspberry B (256MB) with a USB-connected Tellstick (original).
Please let me know of any improvements you can see.
Note that the script requires BASH rather than SH as some builtin functionality is used.
Code: Select all
#!/bin/bash startup_path=$1 hardware_id=$2 device_id=$3 status=$4 status2=$5 devname=$6 LOGFILE=<filename of logfile or /dev/null> echo "startup_path=${startup_path}, hardware_id=${hardware_id}, device_id=${device_id}, status=${status}, status2=${status2}, devname=${devname}" >>$LOGFILE # This part of the script interfaces with a Tellstick device via tdtool # # Requirements: A working Tellstick installation with tdtool and configured tellstick.conf # All controlled devices needs to be defined with exactly the same name in tellstick.conf and Domoticz. # The device type in Domoticz can be anything. I use X10 as I am not using that for anything else. # To identify Tellstick devices a Dummy virtual device needs to be defined in Domoticz. I named it "Tellstick" and Domoticz # assigned it hardware_id "2" which is what the logic below uses to determine if it is a Tellstick device # Tellstick Hardware has hardware_id=2 if [ "${hardware_id}" = "2" ] ; then # tdtool commands are always lowercase whereas Domoticz uses mixed case for status. tdcmd is either "on" or "off" after this tdcmd=${status2,,} # if command is to dim device we need to find dimlevel and set that # Domoticz uses the status "Set Level: [n] %" where n is the dimlevel to use tmp="${tdcmd%:*}" if [ "$tmp" = "set level" ] ; then # Get percentage which is found between : and % tmp="${tdcmd#*:}" dimlevel="${tmp//%/}" # Tellstick dim level are 0-255 so we need to convert percentage dimlevel=$((dimlevel*255/100)) # Set tdtool command to use tdcmd="dim" fi # Execute Tellstick command # We need both command and devname set to execute tdtool if [ "${tdcmd}" != "" ] && [ "${tdcmd}" != "" ] ; then if [ "${tdcmd}" = "dim" ] ; then echo "Setting dim level for" $devname "to" $dimlevel >>$LOGFILE tdtool --dimlevel $dimlevel --dim "$devname" >>$LOGFILE else echo "Changing" "$devname" "to" $tdcmd >>$LOGFILE tdtool --$tdcmd "$devname" >>$LOGFILE fi fi fi # End of Tellstick section
-
- Posts: 279
- Joined: Sunday 03 January 2016 14:55
- Target OS: -
- Domoticz version:
- Location: Sweden
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Please tell me what you had to do with permission so I can add it to the Guide.Rivvern wrote:It worked, as soon as i set the permissions to correctly.
"sudo chmod 777 script.sh" ?
Please explainRivvern wrote:Check marked the Execute/Enter on the scripts.
-
- Posts: 6
- Joined: Thursday 08 September 2016 10:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Well. I didnt use putty to change the permission so i dont know the syntax.
I was browsing the file structure with WinSCP when i right clicked my scripts noticing the lack of permissions.
I was browsing the file structure with WinSCP when i right clicked my scripts noticing the lack of permissions.
-
- Posts: 279
- Joined: Sunday 03 January 2016 14:55
- Target OS: -
- Domoticz version:
- Location: Sweden
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Updated 1. with correct link
viewtopic.php?f=17&t=7807&p=95905#p95905
viewtopic.php?f=17&t=7807&p=95905#p95905
-
- Posts: 85
- Joined: Tuesday 06 September 2016 9:08
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Sorø, DK
- Contact:
Re: Is there interest for Tellstick (Duo) support?
I am trying to get Tellstick working in Domoticz. And I am unsure which path to follow.
Tellstick is working via command line, amd I have added the tellstick in Hardware - no devices will show up in Devices.
I try to manually add in the switch upper left corner, Manual Light/Switch. I am not able to have the test to switch on my Lamp/switch
I can se that my lamp is switched on, CMD is working
Tellstick is working via command line, amd I have added the tellstick in Hardware - no devices will show up in Devices.
I try to manually add in the switch upper left corner, Manual Light/Switch. I am not able to have the test to switch on my Lamp/switch
I can se that my lamp is switched on, CMD is working
-
- Posts: 85
- Joined: Tuesday 06 September 2016 9:08
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Sorø, DK
- Contact:
Re: Is there interest for Tellstick (Duo) support?
And then I will add this lamp manually in Domoticz - but I am not able to switch the lamp on?
IS this approach wrong? and I should go and use the "old" way with dummy switches hat are executing shell scripts? my system is RPI3
uname -a
Linux bjadomoticz 4.4.26-v7+ #915 SMP Thu Oct 20 17:08:44 BST 2016 armv7l GNU/Linux
Domoticz ver 3.5837 updated a few days ago with /domoticz/updaterelease script
(I have not tried Tellstick with older Domoticz variants)
IS this approach wrong? and I should go and use the "old" way with dummy switches hat are executing shell scripts? my system is RPI3
uname -a
Linux bjadomoticz 4.4.26-v7+ #915 SMP Thu Oct 20 17:08:44 BST 2016 armv7l GNU/Linux
Domoticz ver 3.5837 updated a few days ago with /domoticz/updaterelease script
(I have not tried Tellstick with older Domoticz variants)
-
- Posts: 279
- Joined: Sunday 03 January 2016 14:55
- Target OS: -
- Domoticz version:
- Location: Sweden
- Contact:
Re: Is there interest for Tellstick (Duo) support?
See my post above(number 36), my guide should be ok if not please tell me and I will change any faults.bjacobse wrote:And then I will add this lamp manually in Domoticz - but I am not able to switch the lamp on?
IS this approach wrong? and I should go and use the "old" way with dummy switches hat are executing shell scripts? my system is RPI3
uname -a
Linux bjadomoticz 4.4.26-v7+ #915 SMP Thu Oct 20 17:08:44 BST 2016 armv7l GNU/Linux
Domoticz ver 3.5837 updated a few days ago with /domoticz/updaterelease script
(I have not tried Tellstick with older Domoticz variants)
Yes, use old way with dummy and script
-
- Posts: 85
- Joined: Tuesday 06 September 2016 9:08
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Sorø, DK
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Ok,
Then I will make an update guide
Then I will make an update guide
-
- Posts: 85
- Joined: Tuesday 06 September 2016 9:08
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Sorø, DK
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Create a dummy device: Setup->Hardware
Click "Edit" and add your stuff like I did (My device id is 5 in etc/tellstick.conf) You shall use the device id that you have in your /etc/tellstick.conf
Create a dummy device: Click on "Create virtual Sensors" and add a device name that makes sense for you. Mine is a Kitchen Pouls Henningsen 43cm lamp
goto your "Switch" tab that contains all your switches, and search in the bottom at the pageClick "Edit" and add your stuff like I did (My device id is 5 in etc/tellstick.conf) You shall use the device id that you have in your /etc/tellstick.conf
-
- Posts: 85
- Joined: Tuesday 06 September 2016 9:08
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Sorø, DK
- Contact:
Re: Is there interest for Tellstick (Duo) support?
place this script here: /domoticz/scripts
to create and make it executeable
My script:
Code: Select all
touch tellstick_script
chmod a+x tellstick_script
to create and make it executeable
My script:
Code: Select all
#!/bin/bash
# Domoticz Script to execute tellstick commands via dummy device
# Created 2016,by Brian Jacobsen, [email protected]
# execute command like below, action is "on" or "off" device id is from etc/tellstick.conf
# tellstick_script action device id
# example:
# tellstick_script off 5
# tellstick_script on 2
tdtool --$1 $2
Last edited by bjacobse on Friday 04 November 2016 20:49, edited 1 time in total.
-
- Posts: 85
- Joined: Tuesday 06 September 2016 9:08
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Sorø, DK
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Then the script is used for all your Tellstick dummy devices, add a device switch for each device id that you have in your /etc/tellstick.conf (read: replace "5" with maybe "2" or "3" )
-
- Posts: 8
- Joined: Sunday 04 December 2016 22:07
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Where should the script be placed.
You have two scripts, one "to make it executeable"?
For me it is not working.
If i use Putty i can send command tdtool -n 1 or tdtool --on 1 and it is working.
But cant get it working in Domoticz.
You have two scripts, one "to make it executeable"?
For me it is not working.
If i use Putty i can send command tdtool -n 1 or tdtool --on 1 and it is working.
But cant get it working in Domoticz.
-
- Posts: 62
- Joined: Tuesday 22 November 2016 21:04
- Target OS: Linux
- Domoticz version: 2020.2
- Location: Gothenburg
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Can you add Telldus live support this way, or do I need to have a usb stick ?
Regards Magnus Svensson
Regards Magnus Svensson
-
- Posts: 85
- Joined: Tuesday 06 September 2016 9:08
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Sorø, DK
- Contact:
Re: Is there interest for Tellstick (Duo) support?
I have only 1 script and it's placed in your home folder/pi and then : /domoticz/scriptsLillios wrote:Where should the script be placed.
You have two scripts, one "to make it executeable"?
For me it is not working.
If i use Putty i can send command tdtool -n 1 or tdtool --on 1 and it is working.
But cant get it working in Domoticz.
-
- Posts: 85
- Joined: Tuesday 06 September 2016 9:08
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Sorø, DK
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Sorry I'm not able to support/add Telldus liveMelotron wrote:Can you add Telldus live support this way, or do I need to have a usb stick ?
Regards Magnus Svensson
-
- Posts: 2
- Joined: Monday 06 February 2017 21:00
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 3.6630
- Location: Gothenburg, SE
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Is the only way to get Tellstick DUO support to use this Dummy hardware and Virtual Devices?
I use an RPI2
I downloaded the latest version of Domoticz
Downloaded and compiled Telldus Core. Telldus core works and I can turn on and off lamps using tdtool
I can also receive my sensors
When I start Domoticz and select add HW I can see Tellstick as an option, but when added I can see no devices. Shouldn't this list be populated from tellsick.conf?
If I have to use virtual devices how do I recieve my sensor signals?
I've been running HA for a long time and is already automating alot, but this is my first attempt with Domoticz.
I'm planning on adding z-wave support on my RPI, but I wanted to make sure I can use my old Tellstick DUO as well since I have over 20 devices connected.
Thanks for all help I can get.
/Uffe
I use an RPI2
I downloaded the latest version of Domoticz
Downloaded and compiled Telldus Core. Telldus core works and I can turn on and off lamps using tdtool
I can also receive my sensors
When I start Domoticz and select add HW I can see Tellstick as an option, but when added I can see no devices. Shouldn't this list be populated from tellsick.conf?
If I have to use virtual devices how do I recieve my sensor signals?
I've been running HA for a long time and is already automating alot, but this is my first attempt with Domoticz.
I'm planning on adding z-wave support on my RPI, but I wanted to make sure I can use my old Tellstick DUO as well since I have over 20 devices connected.
Thanks for all help I can get.
/Uffe
- PeGe
- Posts: 25
- Joined: Tuesday 31 January 2017 14:21
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V3.6328
- Location: Sollentuna, Sweden
- Contact:
Re: Is there interest for Tellstick (Duo) support?
I don't know if it helps you at all, but I recently posted the following:
http://www.domoticz.com/forum/viewtopic ... 06#p118006
It might be somewhat useful, when/if you want to grab and replicate the sensor values from your Tellstick Duo.
/P-G
http://www.domoticz.com/forum/viewtopic ... 06#p118006
It might be somewhat useful, when/if you want to grab and replicate the sensor values from your Tellstick Duo.
/P-G
-
- Posts: 2
- Joined: Monday 06 February 2017 21:00
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 3.6630
- Location: Gothenburg, SE
- Contact:
Re: Is there interest for Tellstick (Duo) support?
Thanks, but not really what I was after. My main concern is if it's possible to use the Tellstick without using Dummy hardware and virtual devices
Who is online
Users browsing this forum: No registered users and 0 guests