Samsung TV control in Domoticz
Moderators: leecollings, remb0
-
- Posts: 4
- Joined: Saturday 18 March 2017 11:24
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
Hi,
i have try :
/usr/local/iSamsungTV/bin$ ./iSamsungTV C 192.168.1.10 -KEY KEY_MUTE
-sh: ./iSamsungTV: cannot execute binary file: Exec format error
and with root
/usr/local/iSamsungTV/bin$ ./iSamsungTV C 192.168.1.10 -KEY KEY_MUTE
-ash: /usr/local/iSamsungTV/bin$: No such file or directory
i have try :
/usr/local/iSamsungTV/bin$ ./iSamsungTV C 192.168.1.10 -KEY KEY_MUTE
-sh: ./iSamsungTV: cannot execute binary file: Exec format error
and with root
/usr/local/iSamsungTV/bin$ ./iSamsungTV C 192.168.1.10 -KEY KEY_MUTE
-ash: /usr/local/iSamsungTV/bin$: No such file or directory
- jumbotroll
- Posts: 793
- Joined: Tuesday 13 January 2015 14:36
- Target OS: NAS (Synology & others)
- Domoticz version: Beta
- Location: Oslo,Norway
- Contact:
Re: Samsung TV control in Domoticz
@ptijo
I am using this without any problem, on DS712+, but maybe my build not working on your NAS.
If my packages not work I'm going to delete them from my server.
Edit: packages deleted!
I am using this without any problem, on DS712+, but maybe my build not working on your NAS.
If my packages not work I'm going to delete them from my server.
Edit: packages deleted!
Last edited by jumbotroll on Sunday 19 March 2017 0:46, edited 1 time in total.
If you like the work I do for synology and domoticz, I appreciate a donation.
https://paypal.me/Jumbotroll
Regards
Jumbotroll
http://www.jadahl.com
https://paypal.me/Jumbotroll
Regards
Jumbotroll
http://www.jadahl.com
-
- Posts: 39
- Joined: Thursday 16 April 2015 10:18
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
Still the same error:tontze wrote:
Correct sudo usage :
Code: Select all
sudo /usr/local/iSamsungTV/bin/iSamsungTV E 192.168.1.36 -KEY KEY_POWEROFF
root@HA:~# sudo /usr/local/iSamsungTV/bin/iSamsungTV E 192.168.1.36 -KEY KEY_POWEROFF
/usr/local/iSamsungTV/bin/iSamsungTV: /usr/local/iSamsungTV/bin/iSamsungTV: cannot execute binary file
I tried:
Delete and reinstall package.
Install it on my 916 (running latest stable version)
Install it on my 916 running Domoticz V3.6749
Tried the C, D, F TV setting.
All give the same error
-
- Posts: 4
- Joined: Saturday 18 March 2017 11:24
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
I see that there are lot of issue with version of NASjumbotroll wrote:@ptijo
I am using this without any problem, on DS712+, but maybe my build not working on your NAS.
If my packages not work I'm going to delete them from my server.
Edit: packages deleted!
uname r :2.6.32.12
'm sorry, but I'm resigning myself.
thanks
Regards
-
- Posts: 317
- Joined: Thursday 12 January 2017 15:30
- Target OS: Linux
- Domoticz version: Beta Ch
- Location: Finland
- Contact:
Re: Samsung TV control in Domoticz
Not the same error, last time it didnt find sudo since wrong path was provided to it. go toRodio wrote:Still the same error:tontze wrote:
Correct sudo usage :
Code: Select all
sudo /usr/local/iSamsungTV/bin/iSamsungTV E 192.168.1.36 -KEY KEY_POWEROFF
root@HA:~# sudo /usr/local/iSamsungTV/bin/iSamsungTV E 192.168.1.36 -KEY KEY_POWEROFF
/usr/local/iSamsungTV/bin/iSamsungTV: /usr/local/iSamsungTV/bin/iSamsungTV: cannot execute binary file
I tried:
Delete and reinstall package.
Install it on my 916 (running latest stable version)
Install it on my 916 running Domoticz V3.6749
Tried the C, D, F TV setting.
All give the same error
Code: Select all
/usr/local/iSamsungTV/bin/
Code: Select all
./iSamsungTV
Code: Select all
sudo ./iSamsungTV
Code: Select all
chmod a+x /usr/local/iSamsungTV/bin/iSamsungTV
-----------------------------------------
Smartthings
zigbee2mqtt
RFLink 433mhz / Nrf 2.4Ghz
Mi Light
esp8266MiLight Hub
OpenHab/HomeAssistant/Domoticz
HP T610 & Debian 5.10.19-1 x86_64[/b]
Smartthings
zigbee2mqtt
RFLink 433mhz / Nrf 2.4Ghz
Mi Light
esp8266MiLight Hub
OpenHab/HomeAssistant/Domoticz
HP T610 & Debian 5.10.19-1 x86_64[/b]
-
- Posts: 39
- Joined: Thursday 16 April 2015 10:18
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
Hi Tontze,
Thx for the replies.
did the chmod a+x thing
root@HA:/usr/local/iSamsungTV/bin# iSamsungTV
-ash: /bin/iSamsungTV: cannot execute binary file: Exec format error
root@HA:/usr/local/iSamsungTV/bin# iSamsungTV E 192.168.1.36 -KEY KEY_POWERON
-ash: /bin/iSamsungTV: cannot execute binary file: Exec format error
root@HA:/usr/local/iSamsungTV/bin# sudo iSamsungTV
/bin/iSamsungTV: /bin/iSamsungTV: cannot execute binary file
root@HA:/usr/local/iSamsungTV/bin# sudo ./iSamsungTV
./iSamsungTV: ./iSamsungTV: cannot execute binary file
Regards
R
Thx for the replies.
did the chmod a+x thing
root@HA:/usr/local/iSamsungTV/bin# iSamsungTV
-ash: /bin/iSamsungTV: cannot execute binary file: Exec format error
root@HA:/usr/local/iSamsungTV/bin# iSamsungTV E 192.168.1.36 -KEY KEY_POWERON
-ash: /bin/iSamsungTV: cannot execute binary file: Exec format error
root@HA:/usr/local/iSamsungTV/bin# sudo iSamsungTV
/bin/iSamsungTV: /bin/iSamsungTV: cannot execute binary file
root@HA:/usr/local/iSamsungTV/bin# sudo ./iSamsungTV
./iSamsungTV: ./iSamsungTV: cannot execute binary file
Regards
R
-
- Posts: 317
- Joined: Thursday 12 January 2017 15:30
- Target OS: Linux
- Domoticz version: Beta Ch
- Location: Finland
- Contact:
Re: Samsung TV control in Domoticz
Check that your binary file matches with your systems architecture, is it ARM and your system is X86 or vice versa Or is it 32bit program and your system is 64bit, or vice versa.
-----------------------------------------
Smartthings
zigbee2mqtt
RFLink 433mhz / Nrf 2.4Ghz
Mi Light
esp8266MiLight Hub
OpenHab/HomeAssistant/Domoticz
HP T610 & Debian 5.10.19-1 x86_64[/b]
Smartthings
zigbee2mqtt
RFLink 433mhz / Nrf 2.4Ghz
Mi Light
esp8266MiLight Hub
OpenHab/HomeAssistant/Domoticz
HP T610 & Debian 5.10.19-1 x86_64[/b]
-
- Posts: 39
- Joined: Thursday 16 April 2015 10:18
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
Hi,
No idea how to check for which architecture the binary file is.
I've downloaded it form the site of Jumbotroll, but he's deleted them (they're not there anymore).
I'm gonna stop for now with this 'project'.
Thx for the help Tontze, really appreciate it
No idea how to check for which architecture the binary file is.
I've downloaded it form the site of Jumbotroll, but he's deleted them (they're not there anymore).
I'm gonna stop for now with this 'project'.
Thx for the help Tontze, really appreciate it
- bueno79
- Posts: 83
- Joined: Wednesday 08 March 2017 10:26
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.9700
- Location: France
- Contact:
Re: Samsung TV control in Domoticz
Hi,
your problem is : this file is NOT compile for your architecture. type :
file iSamsungTV
you will see the infos (you need file command of course). So I get the same issue and fix it with a 214play.
- I install a linux ubuntuu.
- I install the CORRECT tool chain from here on the ubuntuu (https://sourceforge.net/projects/dsgpl/ ... edomCookie)
- I set some variables to compile on th ubuntuu (lines below are not for 214play, just example)
- then compile the samsungTV code (I clone the project on the ubuntuu with git first) with the gcc (the path is in the variable CC you set before)
- move my new iSAmsungTV on my NAS
it woooorks !!!
you can find all info in french here : http://benjamin-balet.info/multimedia/s ... -synology/
you can fin d info on google with "cross compilation synology"
regards
Bueno
your problem is : this file is NOT compile for your architecture. type :
file iSamsungTV
you will see the infos (you need file command of course). So I get the same issue and fix it with a 214play.
- I install a linux ubuntuu.
- I install the CORRECT tool chain from here on the ubuntuu (https://sourceforge.net/projects/dsgpl/ ... edomCookie)
- I set some variables to compile on th ubuntuu (lines below are not for 214play, just example)
Code: Select all
export CFLAGS="-I/usr/local/arm-none-linux-gnueabi/include"
export LDFLAGS="-L/usr/local/arm-none-linux-gnueabi/lib"
export RANLIB=/usr/local/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-ranlib
export LD=/usr/local/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-ld
export CC=/usr/local/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-gcc
export LD_LIBRARY_PATH=/usr/local/arm-none-linux-gnueabi/lib
export ARCH=arm
- move my new iSAmsungTV on my NAS
it woooorks !!!
you can find all info in french here : http://benjamin-balet.info/multimedia/s ... -synology/
you can fin d info on google with "cross compilation synology"
regards
Bueno
-
- Posts: 3
- Joined: Friday 31 March 2017 18:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
As a proud owner of a Samsung Series K I really wanted to integrate remote control into Domoticz and i finally found a way!perwei wrote:Just a comment regarding newer Samsung TVs like model K. Seems iSamsungTV isn't working on those models.
On the other hand, Wake-on-LAN does work and brings the TV from sleeping and un-pingable to live and pingable.
Cheers,
Per
SamsungCTL makes it possible to control the Samsung Series K (and probably all the other series as well). At this moment i can control the TV via the command interface, so we are only a small step away from the full integration which will allow us to control the TV via Domoticz.
Installation
1. Install python3-pip:
Code: Select all
pi@domoticz:~ $ sudo apt-get install python3-pip
Code: Select all
pi@domoticz:~ $ sudo pip3 install samsungctl
Code: Select all
pi@domoticz:~ $ sudo pip3 install websocket-client
Code: Select all
pi@domoticz:~ $ samsungctl --host xxx.xxx.xxx.xxx --method websocket KEY_MUTE
6. Allow the external control with your TV Remote and voila! remote control should be working now and the volume of your TV should be muted.
Extra information:
1. To unmute your tv use
Code: Select all
pi@domoticz:~ $ samsungctl --host xxx.xxx.xxx.xxx --method websocket KEY_VOLUP
2. The extra option
Code: Select all
--method websocket
Links
SamsungCTL GitHub: https://github.com/Ape/samsungctl
Key Codes: https://github.com/Ape/samsungctl#key-codes
Good luck!
- mlamie
- Posts: 122
- Joined: Friday 25 October 2013 17:12
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 3.5877
- Location: The Netherlands
- Contact:
Re: Samsung TV control in Domoticz
I have seen there is a new Samsung TV page in the Domoticz wiki based on samsungctl. You can try that as well I expect.stavast wrote: Good luck!
https://www.domoticz.com/wiki/Plugins/SamsungTV.html
Raspberry Pi 3, RaZberry, RFXtrx433
Various Z-Wave devices, KlikAanKlikUit devices, ESP8266 NodeMCU, Sonoff POW and a Essent E-thermostaat
IP camera: Dahua 4MP IPC-HDBW4421R-AS, Vivotek FD8134V
Various Z-Wave devices, KlikAanKlikUit devices, ESP8266 NodeMCU, Sonoff POW and a Essent E-thermostaat
IP camera: Dahua 4MP IPC-HDBW4421R-AS, Vivotek FD8134V
- Westcott
- Posts: 423
- Joined: Tuesday 09 December 2014 17:04
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta
- Location: UK - Glos
- Contact:
Re: Samsung TV control in Domoticz
When I try it from the command line, I get -
File "/usr/local/bin/samsungctl", line 9, in <module>
load_entry_point('samsungctl==0.6.0', 'console_scripts', 'samsungctl')()
File "/usr/local/lib/python2.7/dist-packages/samsungctl/__main__.py", line 93, in main
config = _read_config()
File "/usr/local/lib/python2.7/dist-packages/samsungctl/__main__.py", line 37, in _read_config
except FileNotFoundError:
NameError: global name 'FileNotFoundError' is not defined
My guess is that the config file is missing...
File "/usr/local/bin/samsungctl", line 9, in <module>
load_entry_point('samsungctl==0.6.0', 'console_scripts', 'samsungctl')()
File "/usr/local/lib/python2.7/dist-packages/samsungctl/__main__.py", line 93, in main
config = _read_config()
File "/usr/local/lib/python2.7/dist-packages/samsungctl/__main__.py", line 37, in _read_config
except FileNotFoundError:
NameError: global name 'FileNotFoundError' is not defined
My guess is that the config file is missing...
Zwave - Sigma Z+ stick, Fibaro, Horstmann, Neo Coolcam, EUROtronic
RFlink - IR detectors and temperatures
Wifi - YeeLights, ESP32s, Anoop sockets
Zigbee - lots with zigbee2mqtt and ZbBridge
RFlink - IR detectors and temperatures
Wifi - YeeLights, ESP32s, Anoop sockets
Zigbee - lots with zigbee2mqtt and ZbBridge
-
- Posts: 3
- Joined: Friday 31 March 2017 18:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
O Wow, I have been searching for two weeks! what a coincidence and a luck. Thank god the plugin is from the 27th of March, I was very sure I search in every corner of the Domoticz forum and wiki. I felt a bit of a fool for missing such a big elephant Thanks for mentioning it mlamie!mlamie wrote:I have seen there is a new Samsung TV page in the Domoticz wiki based on samsungctl. You can try that as well I expect.stavast wrote: Good luck!
https://www.domoticz.com/wiki/Plugins/SamsungTV.html
-
- Posts: 3
- Joined: Friday 31 March 2017 18:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
You need to have Python Version 3 to be able to run samsungctl. based upon this "File "/usr/local/lib/python2.7/" i get the feeling you installed it under Python Version 2 with the use of pip instead of pip3Westcott wrote:When I try it from the command line, I get -
File "/usr/local/bin/samsungctl", line 9, in <module>
load_entry_point('samsungctl==0.6.0', 'console_scripts', 'samsungctl')()
File "/usr/local/lib/python2.7/dist-packages/samsungctl/__main__.py", line 93, in main
config = _read_config()
File "/usr/local/lib/python2.7/dist-packages/samsungctl/__main__.py", line 37, in _read_config
except FileNotFoundError:
NameError: global name 'FileNotFoundError' is not defined
My guess is that the config file is missing...
- Westcott
- Posts: 423
- Joined: Tuesday 09 December 2014 17:04
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta
- Location: UK - Glos
- Contact:
Re: Samsung TV control in Domoticz
Thanks, Stavast!
The Wiki needs to be updated with some 3's.
I REALLY don't like version-specific installs.
Now I'm getting the dreaded -
/usr/local/bin/python3.5: error while loading shared libraries: libpython3.5.so.1.0: cannot open shared object file: No such file or directory
Python3 runs OK -
Python3 -i
Python 3.5.2 (default, Dec 14 2016, 15:53:15)
echo $LD_LIBRARY_PATH
/usr/local/lib
And libpython3.5.so.1.0 is in /usr/local/lib
Haven't been able to Google a solution yet.
The Wiki needs to be updated with some 3's.
I REALLY don't like version-specific installs.
Now I'm getting the dreaded -
/usr/local/bin/python3.5: error while loading shared libraries: libpython3.5.so.1.0: cannot open shared object file: No such file or directory
Python3 runs OK -
Python3 -i
Python 3.5.2 (default, Dec 14 2016, 15:53:15)
echo $LD_LIBRARY_PATH
/usr/local/lib
And libpython3.5.so.1.0 is in /usr/local/lib
Haven't been able to Google a solution yet.
Zwave - Sigma Z+ stick, Fibaro, Horstmann, Neo Coolcam, EUROtronic
RFlink - IR detectors and temperatures
Wifi - YeeLights, ESP32s, Anoop sockets
Zigbee - lots with zigbee2mqtt and ZbBridge
RFlink - IR detectors and temperatures
Wifi - YeeLights, ESP32s, Anoop sockets
Zigbee - lots with zigbee2mqtt and ZbBridge
-
- Posts: 4
- Joined: Saturday 18 March 2017 11:24
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Samsung TV control in Domoticz
#bueno79
Could you give me the gcc command
i try but i have the same error (format exec error)
Could you give me the gcc command
i try but i have the same error (format exec error)
bueno79 wrote:Hi,
your problem is : this file is NOT compile for your architecture. type :
file iSamsungTV
you will see the infos (you need file command of course). So I get the same issue and fix it with a 214play.
- I install a linux ubuntuu.
- I install the CORRECT tool chain from here on the ubuntuu (https://sourceforge.net/projects/dsgpl/ ... edomCookie)
- I set some variables to compile on th ubuntuu (lines below are not for 214play, just example)
- then compile the samsungTV code (I clone the project on the ubuntuu with git first) with the gcc (the path is in the variable CC you set before)Code: Select all
export CFLAGS="-I/usr/local/arm-none-linux-gnueabi/include" export LDFLAGS="-L/usr/local/arm-none-linux-gnueabi/lib" export RANLIB=/usr/local/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-ranlib export LD=/usr/local/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-ld export CC=/usr/local/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-gcc export LD_LIBRARY_PATH=/usr/local/arm-none-linux-gnueabi/lib export ARCH=arm
- move my new iSAmsungTV on my NAS
it woooorks !!!
you can find all info in french here : http://benjamin-balet.info/multimedia/s ... -synology/
you can fin d info on google with "cross compilation synology"
regards
Bueno
- bueno79
- Posts: 83
- Joined: Wednesday 08 March 2017 10:26
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.9700
- Location: France
- Contact:
Re: Samsung TV control in Domoticz
@ptijo
just imagine your processor is an arm. you get the tool chain and your path is the default one. And you have the source from iSamnsungTV in your home. So you should type something like this :
/usr/local/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-gcc /home/bueno/iSamsungTV/iSamsungTV.c
just imagine your processor is an arm. you get the tool chain and your path is the default one. And you have the source from iSamnsungTV in your home. So you should type something like this :
/usr/local/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-gcc /home/bueno/iSamsungTV/iSamsungTV.c
Re: Samsung TV control in Domoticz
If you have a precompiled binary of iSamsungTV, other then osx or raspberry pi, post a link, I will add them to the github page...
-
- Posts: 317
- Joined: Thursday 12 January 2017 15:30
- Target OS: Linux
- Domoticz version: Beta Ch
- Location: Finland
- Contact:
Re: Samsung TV control in Domoticz
Finally made a button to control my TV in domoticz, but seems its not working well ..
This is what im getting to log in domoticz, from command line its working well .. ?
Code: Select all
2017-04-18 17:31:47.268 Error: Error executing script command (/usr/local/bin/iSamsungTV). returned: 512
-----------------------------------------
Smartthings
zigbee2mqtt
RFLink 433mhz / Nrf 2.4Ghz
Mi Light
esp8266MiLight Hub
OpenHab/HomeAssistant/Domoticz
HP T610 & Debian 5.10.19-1 x86_64[/b]
Smartthings
zigbee2mqtt
RFLink 433mhz / Nrf 2.4Ghz
Mi Light
esp8266MiLight Hub
OpenHab/HomeAssistant/Domoticz
HP T610 & Debian 5.10.19-1 x86_64[/b]
- bueno79
- Posts: 83
- Joined: Wednesday 08 March 2017 10:26
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.9700
- Location: France
- Contact:
Re: Samsung TV control in Domoticz
ok I will extract my version.woodtrix wrote:If you have a precompiled binary of iSamsungTV, other then osx or raspberry pi, post a link, I will add them to the github page...
Who is online
Users browsing this forum: No registered users and 0 guests