2018-10-06, 22:53
(2018-09-17, 19:46)politby Wrote:I found another work-a-round because I am working on this problem now for weeks and I want to share it here for the users that try to solve this issue. Its not perfect (no simple json/http):(2018-07-30, 05:00)iorifly Wrote: Hello everyone!I am experiencing the exact same thing - although I'm sending the command from HomeSeer. I would expect current playback to continue while the preview is being displayed.
This addon is fantastic !!! Congratulations. It works great for my ubiquiti UVC camera
Now I have a doubt. When I call the preview through this code. It exits the movie screen and goes to the addon screen and displays the preview. It would be much better if only the preview is shown. How can I improve?
curl -i -X POST -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"Addons.ExecuteAddon","params":{"wait":false,"addonid":"plugin.video.surveillanceroom","params":{"action":"show_preview","camera_number":"1","id":"1"}},"id":2}' http://192.168.1.163:8080/jsonrpc
Suggestions?
TL;DR:
Use:
- xdotool
- a key that is defined in keymaps and triggers the preview
- SSH
You can use xdotool (needs to be installed on the target-system)
Quote:DISPLAY=':0.0' xdotool key [KEY]
and SSH to trigger a key on your kodi-system and via keymaps you can trigger
Quote:xbmc.executebuiltin('RunPlugin(plugin://plugin.video.surveillanceroom?action=show_preview&camera_number=1)')
You can trigger it by exchanged keys or -if security is not important- with sshpass (needs to be installed on the client-system)
Quote:sshpass -p [USERPASS] ssh -X [USERNAME]@[KODISYSTEMIP] DISPLAY=:0 xdotool key XF86SearchIn my case, I use the the search-key on my remote to activate the preview but i want to trigger it also with iobroker when someone press the doorbell
here you can find a list of keys you can send with xdotool:
http://wiki.linuxquestions.org/wiki/XF86...rd_symbols
You can also choose a key and start the keymap editor to bind it in kodi.
As I found this solution, i had to come here and share it for all unlucky users that have the same issue.