Page 1 of 1

Updated feature for API 20141201: "forced" HD channels.

Posted: Thu Jul 16, 2015 10:55 am
by rkulagow
Developers, I need your input. In the JSON service, we have the capability to create custom channels.

The initial effort will be to create channels where a standard-def station is available in High Def, but our upstream either can't or won't create the channel.

Because we can't re-use stationIDs (and don't want a stationID collision in the future), I'd like to come up with something which is extensible and supportable.

The stationID is a string. I'm considering something like "{stationID}.HD" as the new stationID to indicate that we're taking an existing and forcing all of the programs to have the HD tag.

Is that going to break things in your application?

Re: Updated feature for API 20141201: "forced" HD channels.

Posted: Thu Jul 16, 2015 6:14 pm
by Slugger
This would break SageTV as it uses integers for stationids, unfortunately.

Re: Updated feature for API 20141201: "forced" HD channels.

Posted: Fri Jul 17, 2015 8:19 am
by rkulagow
Is there a max int I need to know about?

Re: Updated feature for API 20141201: "forced" HD channels.

Posted: Fri Jul 17, 2015 9:54 am
by rmeden
Why not let an application decide to force all channels to HD? Should it be part of SD-JSON?

Re: Updated feature for API 20141201: "forced" HD channels.

Posted: Mon Jul 20, 2015 1:23 pm
by rkulagow
Not all applications have the hooks to make a copy of a station and force all of the values to HD (or SD, if that's ever required), so I'm exploring the possibilities.

Re: Updated feature for API 20141201: "forced" HD channels.

Posted: Tue Jul 21, 2015 9:41 am
by Slugger
Integers are stored in 4 bytes in Java (32bits) and are signed so max integer value would be 2^32 / 2 - 1 = 2,147,483,647

Re: Updated feature for API 20141201: "forced" HD channels.

Posted: Tue Jul 21, 2015 10:28 am
by rkulagow
Thanks.

I've created a lineup called FIN-0004550-CUSTOM, available at Country:FIN, postal code 00100

The first custom channel is channel 021, stationID 1088272.

It should "just work", so if you'd like to try it in your code please give it a try and let me know if it doesn't.