[API] SamyGO web API
Re: [API] SamyGO web API
I don't understand this step:
CMD_ON:/mnt/scripts/onPowerOn.sh CMD_OFF:/mnt/scripts/onPowerOff.sh
Where can I download those scripts?
CMD_ON:/mnt/scripts/onPowerOn.sh CMD_OFF:/mnt/scripts/onPowerOff.sh
Where can I download those scripts?
Samsung TV: UE46F6500
Re: [API] SamyGO web API
You should just create them, like this (minimum; you can run your own code in them as needed):The onPowerOn.sh/onPowerOff.sh scripts (among other functionality) should set a flag by creating a file called
Code: Select all
/dtv/tvIsSleeping
:
onPowerOn.sh: rm -f /dtv/tvIsSleeping
onPowerOff.sh: touch /dtv/tvIsSleeping
If you don't use libSoftPowerOff, the TV powers off and the web API is no longer accessible.
/mnt/scripts/onPowerOn.sh:
Code: Select all
#!/bin/sh
rm -f /dtv/tvIsSleeping
Code: Select all
#!/bin/sh
touch /dtv/tvIsSleeping
Code: Select all
chmod a+x /mnt/scripts/onPower*.sh
H6400, firmware 2602.2 downgraded to 2130
Re: [API] SamyGO web API
Would it be possible to provide support for "libAlert"?
Re: [API] SamyGO web API
Do you mean showing an alert on-screen injected via the API? Sure. Can you show me an example alert via the command line?
H6400, firmware 2602.2 downgraded to 2130
Re: [API] SamyGO web API
Yea exactly.
It's the App from here viewtopic.php?f=63&t=9099 .
And the command is something like:
There are some arguments you can check them in the Topic.
It's the App from here viewtopic.php?f=63&t=9099 .
And the command is something like:
Code: Select all
samyGOso -d -A -B -l /mnt/opt/privateer/usr/libso/libAlert.so BLINKS:3 DELAY:200 MSGBOX:"Blah!"
Re: [API] SamyGO web API
I've added support for libRunWidget (viewtopic.php?f=63&t=9306) and updated the first post with examples. Sadly, it crashes my H6400 when I try to run a widget (even via the command line), but give it a try on other systems:
I will add libAlert next.
Code: Select all
[root@tv rwcommon]# /mnt/opt/privateer/usr/bin/samyGOso -d -T -B -l /mnt/opt/privateer/usr/libso/libRunWidget.so ID:111299001922
samyGOso v1.2.5 (c) bugficks 2013-2014, sectroyer 2014-2015
Injecting '/mnt/opt/privateer/usr/libso/libRunWidget.so' resident: '0'
mprotect: 0x4227c020
dlopen: 0x424a0d80
dlclose: 0x424a0e14
dlsymaddr: 0x424a0e78
pc=42324eec lr=42324ed0 sp=be2a7de0 fp=302af40
r0=302af44 r1=80
r2=1 r3=0
stack: 0xbe288000-0xbe2a8000 length = 131072
executing injection code at 0xbe2a7c88
library injection completed!
Succeeded.
[root@tv rwcommon]#
H6400, firmware 2602.2 downgraded to 2130
Re: [API] SamyGO web API
You're right zoelechat, now it works without crashing. Thanks.
I also added libAlert support and updated the first post.
Enjoy!
I also added libAlert support and updated the first post.
Enjoy!
H6400, firmware 2602.2 downgraded to 2130
Re: [API] SamyGO web API
Thanks for that fast delivery of the feature request.
I am in developement for an FHEM Module for your API.
Who is interested in that can find it here:
https://forum.fhem.de/index.php/topic,88116.0.html
I got not all features at the moment cause it's still dev build.
Re: [API] SamyGO web API
Nice. Good luck with it!
Try not to have many simultaneous calls to the API because it will either fail, or risk crashing the TV. This is because to extract data I have to inject some libraries into a running process and if there are many injections it can fail. There is a locking mechanism inside the API, but I haven't tested it extensively.
Try not to have many simultaneous calls to the API because it will either fail, or risk crashing the TV. This is because to extract data I have to inject some libraries into a running process and if there are many injections it can fail. There is a locking mechanism inside the API, but I haven't tested it extensively.
H6400, firmware 2602.2 downgraded to 2130