suborb / philips_android_tv

Tools to control Philips 2016 Android TVs
GNU General Public License v2.0
121 stars 61 forks source link

Change channel mutliple digit - API spec found #7

Open gpiccinni opened 6 years ago

gpiccinni commented 6 years ago

Hi, thanks for this useful repo, I'm using it for my own application and it works.

My goal it to be able to change channel by passing the channel number (single digit works via input_key but I'm not able to pass multiple digit eg. channel 52)

Via traffic capture from the philips application I found a way to change channel which I tested and it is working, see the API below

POST /6/activities/tv {"channelList":{"id":"allter"},"channel":{"ccid":338}}' This actually changes the TV channel, the only issue is that "ccid" does not correspond to TV channel preset, I'm trying to capture the call to get the channel list to be able to map "preset" (the channel number as saved on the TV) and ccid.

The API returning the list of channels is (eg. for DVBT) GET /6/channeldb/tv/channelLists/allter

allter has been retrieved from GET /6/channeldb/tv You can use other as cable or terrestrial Find attached another API request I was able to capture.

notifychange_api.txt