Trouble with changing resolution in KODI with JSON-RPC - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32) +--- Forum: Kodi Application (https://forum.kodi.tv/forumdisplay.php?fid=93) +---- Forum: JSON-RPC (https://forum.kodi.tv/forumdisplay.php?fid=174) +---- Thread: Trouble with changing resolution in KODI with JSON-RPC (/showthread.php?tid=273270) |
Trouble with changing resolution in KODI with JSON-RPC - Bandini7 - 2016-05-10 Hi guys and ladies! I'm trying to switch video screen resolution through KODI, with JSON-RPC, but some troubles are appear. I do that with this query: Code: {"jsonrpc":"2.0","method":"Settings.SetSettingValue", "params":{"setting":"videoscreen.resolution","value":41},"id":1} And system ( in this case Raspberry Pi) change resolution, wih dialog window for submiting that change. After that, I try to submit that change with JSON-RPC query for move left cursor and query for select, but that does not work. How to submit that change, with some JSON-RPC query ? RE: Trouble with changing resolution in KODI with JSON-RPC - shmizan - 2020-04-10 (2016-05-10, 09:48)Bandini7 Wrote: Hi guys and ladies! I have the same question but more general. is there a way to click/navigate dialog buttons from a python script? or through json-rpc? RE: Trouble with changing resolution in KODI with JSON-RPC - DaVu - 2020-04-13 (2016-05-10, 09:48)Bandini7 Wrote: How to submit that change, with some JSON-RPC query ? What exactly did not work. The move left or the submit? As I can easily submit to enable the "unknown sources" for addons by moving left and then submit/select what is highlighted with: curl -s -X POST http://127.0.0.1:8080/jsonrpc -H 'Content-Type: application/json' --data '{"jsonrpc": "2.0", "method": "Input.ExecuteAction","params":{"action":"select"},"id":1}'
RE: Trouble with changing resolution in KODI with JSON-RPC - DaVu - 2020-04-13 (2020-04-10, 18:07)shmizan Wrote: is there a way to click/navigate dialog buttons from a python script? or through json-rpc? Yes. As you can see in the posting above, you are able to send input actions via JSON. Depending on what is available on your system, you might also be possible to use "kodi-send" which makes use of Kodi built in python functions and also actions. Like: kodi-send -a "up" RE: Trouble with changing resolution in KODI with JSON-RPC - shmizan - 2020-04-14 (2020-04-13, 13:42)DaVu Wrote:thanks,(2020-04-10, 18:07)shmizan Wrote: is there a way to click/navigate dialog buttons from a python script? or through json-rpc? tried sending the json input actions, but they don't work for dialogs, they only work for regular navigation. does it work for you? RE: Trouble with changing resolution in KODI with JSON-RPC - DaVu - 2020-04-14 yes, I can naviaget to the shutdownmenu via: curl -s -X POST http://127.0.0.1:8080/jsonrpc -H 'Content-Type: application/json' --data '{"jsonrpc": "2.0", "method": "Input.ExecuteAction","params":{"action":"up"},"id":0}' or curl -s -X POST http://127.0.0.1:8080/jsonrpc -H 'Content-Type: application/json' --data '{"jsonrpc": "2.0", "method": "Input.ExecuteAction","params":{"action":"down"},"id":0}' and curl -s -X POST http://127.0.0.1:8080/jsonrpc -H 'Content-Type: application/json' --data '{"jsonrpc": "2.0", "method": "Input.ExecuteAction","params":{"action":"select"},"id":0}' and then also hit "Exit" with curl -s -X POST http://127.0.0.1:8080/jsonrpc -H 'Content-Type: application/json' --data '{"jsonrpc": "2.0", "method": "Input.ExecuteAction","params":{"action":"select"},"id":0}' Not sure why it doesn't work for you |