RaspbmcCrystalbuntu

Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Disable chd for livetv
02-05-2014, 10:07 AM (This post was last modified: 02-05-2014 12:12 PM by iLLiac4.)
Post: #1
Disable chd for livetv
Do someone knows how can i disable chd card only when LiveTv is playing.
Because chd 90012 card is T.F.U for livetv.
I want to do this automatic way.

Is there something i can make?

Is it normal that 12 card decodes not as the 15?
Find all posts by this user
Quote this message in a reply
02-05-2014, 01:25 PM (This post was last modified: 02-05-2014 01:31 PM by kraqh3d.)
Post: #2
RE: Disable chd for livetv
This *may* be possible with a python script, though I think its only Gotham. Let me get back to you. If it does work, you'll need do something funky to make the script run when entering LiveTV. And then you'll need to run an alternate script when entering generic Videos to return the setting as the setting won't be able to be restored on exit.

And I have the '12. It totally barfs on 720p59.94 and 720p60 files which is seems to very common for recordings, so I'm guessing LiveTV is the same. Though for me it's totally fine for 720p24 and 720p30. I get very minor ocassional stutters with 1080p24, not enough for it to be annoying. I dont think I have any 1080p30 so I can't comment. And I wouldn't even think to try 1080p60.

Debug log instructions:
http://wiki.xbmc.org/index.php?title=Log_file/Easy
Find all posts by this user
Quote this message in a reply
02-05-2014, 02:14 PM (This post was last modified: 02-05-2014 02:28 PM by iLLiac4.)
Post: #3
RE: Disable chd for livetv
Well with 15 card there were no problems accept with HD but ok this is another thing.
Today i have tried to install on one users ATV with 12 chd card and sometimes the stream was started og and sometimes not; with just 16 fps.
I have made a log file where i was switching channels. Sometimes the stream was good sometimes it started with 17 fps and frames drop.
The last one CNN started good, then i have minimized it and back maximize it and the fps dropped from 58 to 16. It is very strange and annoying behavior.
I thought that there should be no real difference with 12 and 15 except some additional codec support.


Log:
http://pastebin.com/CuDUyWUA

And here is anther log where i have easily reproduced the frame drops on the same channels:
http://pastebin.com/G4yBjVYX
Find all posts by this user
Quote this message in a reply
02-05-2014, 02:34 PM
Post: #4
RE: Disable chd for livetv
I think your streaming method is the problem. The ffmpeg demuxer is having a hell of a time finding the elementary video stream in the transport stream. That's what all those ffmpeg lines are complaining about and then you get "ERROR: Get - failed to get stream" which clearly isn't good. I also see continual complaints from ffmpeg about the lack of RBSP data which is related. Very quick in laymans terms, the video stream gets encoded with special start byte sequences and padding to ensure that stream headers can be identified and are byte aligned. The demuxer, ffmpeg, uses this data to pull out the video stream data which is directed to the CHD card to be decoded. If it cant do that, then the CHD likely isn't getting a steady stream of data to decode. If you ever want this to go anywhere, open a trac case at xbmc.org.

Debug log instructions:
http://wiki.xbmc.org/index.php?title=Log_file/Easy
Find all posts by this user
Quote this message in a reply
02-05-2014, 02:40 PM (This post was last modified: 02-05-2014 02:45 PM by iLLiac4.)
Post: #5
RE: Disable chd for livetv
Do you think someone will care about this problem? I really doubt.

Update:
Ok i did opened trac or. better to say reopen it.
http://trac.xbmc.org/ticket/14548#comment:2
Find all posts by this user
Quote this message in a reply
02-05-2014, 03:04 PM (This post was last modified: 02-05-2014 03:05 PM by kraqh3d.)
Post: #6
RE: Disable chd for livetv
No, I don't but I can tell you that posting here will absolutely go no where as no one here has the interest or the even the ability to fix it.

Debug log instructions:
http://wiki.xbmc.org/index.php?title=Log_file/Easy
Find all posts by this user
Quote this message in a reply
02-05-2014, 04:06 PM (This post was last modified: 02-05-2014 04:09 PM by kraqh3d.)
Post: #7
RE: Disable chd for livetv
This is only available in Gotham but I'm not sure how far back JSON-RPC access to get and set settings was added. USE AT YOUR OWN RISK.

This will get the current state of the setting:
Code:
curl --header 'Content-Type: application/json' --data-binary \
'{"id":1,"jsonrpc":"2.0","method":"Settings.GetSettingValue","params":{"setting":"videoplayer.usechd"}}' \
http://localhost:8080/jsonrpc

## I get back this:
{"id":1,"jsonrpc":"2.0","result":{"value":true}}

This will change it. The fact that true above is not quoted shows you need to use unquoted booleans when changing it.
Code:
curl --header 'Content-Type: application/json' --data-binary \
'{"id":1,"jsonrpc":"2.0","method":"Settings.SetSettingValue","params":{"setting":"videoplayer.usechd","value":false}}' \
http://localhost:8080/jsonrpc

## I get this back:
{"id":1,"jsonrpc":"2.0","result":true}

Notice the return is different. It says "result":true and not "result":{"value":true} like before. This means the setting change action was executed successfully not that the setting is true. If you check it with the prior command and it'll respond "result":{"value":false}

Here comes the interesting part. How do you hook this into the GUI? That requires hacking the skin. You need to replace the <onclick> actions that say "ActivateWindow" with a python script as that's the only way to execute multiple actions via onclick. For instance:

<onclick>RunScript("/home/atv/usechd.py","PVR","false")</onclick>

And a crude script could be this. Use this as a starting point. You're on your own to correct the syntax. I doubt it'll work exactly as-is.

Code:
import sys
import xbmc

window=sys.argv[1]
usechd=sys.argv[2]

xbmc.executeJSONRPC('{"id":1,"jsonrpc":"2.0","method":"Settings.SetSettingValue","params":{"setting":"videoplayer.usechd","value":' + usechd + '}}')

xbmc.executebuiltin('ActivateWindow(' + window + ')')

Debug log instructions:
http://wiki.xbmc.org/index.php?title=Log_file/Easy
Find all posts by this user
Quote this message in a reply
02-05-2014, 06:18 PM
Post: #8
RE: Disable chd for livetv
OMG Smile i think i will abandon AppleTV, i am sick of it.
Find all posts by this user
Quote this message in a reply
02-05-2014, 08:08 PM (This post was last modified: 02-06-2014 12:51 AM by kraqh3d.)
Post: #9
RE: Disable chd for livetv
Give to me please Smile

You can also simply make two scripts that enable and disable the chd, and then call those scripts from favourites and they can even be mapped to buttons via keymap xml.

Debug log instructions:
http://wiki.xbmc.org/index.php?title=Log_file/Easy
Find all posts by this user
Quote this message in a reply
02-10-2014, 10:13 PM
Post: #10
RE: Disable chd for livetv
(02-05-2014 06:18 PM)iLLiac4 Wrote:  OMG Smile i think i will abandon AppleTV, i am sick of it.
LOL, well what do you expect when you're using hardware that's 7 years old now. and you want it to play HD live tv? Do you realize the hardware that's needed now days to playback live HD content? Send me your apple tv, i'll have it Wink

Are you using the latest Crystalbuntu?
How to post log files for Crystalbuntu 2.0 help
Check out my YouTube Channel
Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)

Sponsored Advertisement