karlandtanya
Posts: 6
Joined: Sun Sep 15, 2019 11:09 pm

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 1:29 pm

Rascas wrote:
Mon Sep 16, 2019 12:59 pm
How are you running Kodi? Through the Desktop, in a virtual terminal, at boot through systemd, etc ? Does it work if you start it through a virtual terminal ? If not what is the output ?
The log I posted is when I ran it from desktop.
I've also reproduced the behaviour running it from a terminal, as [ctrl][alt][f1], then type kodi at the prompt.
I will try messing with screen and see if I can ssh in and look at it after it goes dark. Problem is disconnecting from the screen session at the raspberry pi so I can connect to it from the ssh. Maybe if I just wait 30s and type ^a d it will disconnect...
Maybe I will see the output? I will follow up either way.

When I originally set it up, I had a black screen on my HDMI TV after installing raspian; I guess this is a common issue?
I tried the suggested /boot/config.txt changes, first hdmi_force_hotplug=1 (that's apparently automatically added by NOOBS), which didn't help. Next, config_hdmi_boost=4; didn't help. Finally hdmi_safe=1.
At that point had video at 1024x768, and then used the config tools from the desktop to change it to either 1280x720 or 1280x768 (both work). Afterward HDMI seems to work well.

So, now I'm GUESSING kodi might be using a resolution my TV doesn't like? There (should) be a way to tell kodi what resolution to use...
Some folks in the kodi forums try to specify resolution in advancedsettings.xml, but they report those directives are ignored.
I will look for a solution in that direction and report back if I have any luck.
Meantime if you see something stupid I'm doing, please give a shout.

Thanks!

LTolledo
Posts: 1951
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 2:55 pm

Hi there!

Finally able to install to my RPi4B-4G desktop
followed the procedure as stated in the first post of this topic
started well, did follow the udev settings as stated
HDMI and Analog seems to be working fine.... :)

unfortunately DAC audio is "not supported", meaning no audio is outputted from the DAC even when selected.
did several reboots and checking of the configuration files.... to no avail.... :(
anyway to enable audio output to DAC?

thanks!
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 3:29 pm

LTolledo wrote:
Mon Sep 16, 2019 2:55 pm
Hi there!

Finally able to install to my RPi4B-4G desktop
followed the procedure as stated in the first post of this topic
started well, did follow the udev settings as stated
HDMI and Analog seems to be working fine.... :)

unfortunately DAC audio is "not supported", meaning no audio is outputted from the DAC even when selected.
did several reboots and checking of the configuration files.... to no avail.... :(
anyway to enable audio output to DAC?

thanks!
WHich DAC model ? Can you post a Kodi debug log, after playing something with the DAC selected in audio settings? Also, does it work on a RPi 3 or below ?

psollich
Posts: 1
Joined: Mon Sep 16, 2019 5:20 pm

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 5:29 pm

Hi,

[PHAT DAC not working from within Kodi?]

Many thanks for making all this work - I just got my new Raspberry Pi 4b a few days and it will mainly be used for Kodi so the timing was perfect!

I have a question regarding audio. I have PHAT DAC from Pimoroni on my Pi. It works fine with non-Kodi sound sources, and output of "aplay -l" looks normal. Within Kodi I can _see_ the PHAT DAC listed as an output option (in fact it's the default; as an aside it's listed as "hifiberry", which appears to be normal, see https://learn.pimoroni.com/tutorial/pha ... ac-install). But when I choose it I don't get any sound output. (Sound output via HDMI works fine.)

Is there something obvious I might be doing wrong? I've asked on the Pimoroni forum but the guys there thought it would be a Kodi-specific issue.

If there are logs that would be helpful I'd be happy to post them - it'll take a bit though as I first have to re-install the system (I also have Pimoroni's fan shim and it turns out the software install for that breaks the PHAT DAC because of a GPIO pin conflict, so I'll need to start from scratch to make that PHAT DAC work again at all...).

LTolledo
Posts: 1951
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 9:53 pm

My DAC is Suptronics X400 v3.0 using dtoverlay=iqaudio-dacplus in config.txt
DAC audio works outside of Kodi (Chromium, VLC, omxplayer)

Here's the Kodi log
https://paste.kodi.tv/nuluyekaga.kodi

usually there is an "audio greeting" beeps when Kodi starts and audio is active, but not on this one
the audio greeting is present when HDMI or Analog is selected.

have not tried this installation on the RPi3B+ or lower. But will try this weekend on a fresh Raspbian Buster install on the RPiB (c.2012) autoboot Kodi Media Player that I have (image posted several times in the forum), as it too has a DAC, using dtoverlay=hifiberry-dacplus in the config.txt.
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

luiz_saluti
Posts: 3
Joined: Sat Sep 14, 2019 12:39 am

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 10:05 pm

I had a similar problem regarding audio. I selected bluetooth device through gui, ran emulationstation and web browser youtube video and audio comes out just fine through BT speaker. But when I run kodi, no audio is heard. Selected both alsa devices in the options, and nothing. Here follows a log after running with --debug flag
Attachments
kodi.log.7z
(27.1 KiB) Downloaded 7 times

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 10:16 pm

LTolledo wrote:
Mon Sep 16, 2019 9:53 pm
My DAC is Suptronics X400 v3.0 using dtoverlay=iqaudio-dacplus in config.txt
DAC audio works outside of Kodi (Chromium, VLC, omxplayer)

Here's the Kodi log
https://paste.kodi.tv/nuluyekaga.kodi

usually there is an "audio greeting" beeps when Kodi starts and audio is active, but not on this one
the audio greeting is present when HDMI or Analog is selected.

have not tried this installation on the RPi3B+ or lower. But will try this weekend on a fresh Raspbian Buster install on the RPiB (c.2012) autoboot Kodi Media Player that I have (image posted several times in the forum), as it too has a DAC, using dtoverlay=hifiberry-dacplus in the config.txt.
That is not a debug log but a normal log. A debug log is needed, see first post.
To compare, I would need a test in a RPi lower than version 4, using Raspbian Buster and this Kodi packages. It should work in RPi < 4 with hifiberry DACs, but I didn't had the chance yet to test any DAC in a RPi 4 with this packages.

PS: Just remembered, did you disabled the onboard audio by commenting/removing dtparam=audio=on from /boot/config.txt ? I believe that is needed for the DAC to work.
Last edited by Rascas on Tue Sep 17, 2019 1:30 am, edited 1 time in total.

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 10:28 pm

luiz_saluti wrote:
Mon Sep 16, 2019 10:05 pm
I had a similar problem regarding audio. I selected bluetooth device through gui, ran emulationstation and web browser youtube video and audio comes out just fine through BT speaker. But when I run kodi, no audio is heard. Selected both alsa devices in the options, and nothing. Here follows a log after running with --debug flag
Well Bluetooth audio never was straightforward in Kodi + Raspbian. I explained that several ocasions in the thread [GUIDE] Kodi on Raspbian Stretch which was accidentaly deleted.
Anyway, you can try to make it work following this thread:
https://www.raspberrypi.org/forums/view ... 8&t=206898
Let me know if and what worked for you after.

PS: In OSs like LibreELEC and OSMC it works without any extra work because they ship a modified PulseAudio and ALSA packages respectively. If someone has any ideas on how to make this easier please let me know, I will gladly try to workaround it.
Last edited by Rascas on Mon Sep 16, 2019 10:35 pm, edited 1 time in total.

karlandtanya
Posts: 6
Joined: Sun Sep 15, 2019 11:09 pm

Re: [Guide] Kodi on Raspbian Buster

Mon Sep 16, 2019 10:35 pm

karlandtanya wrote:
Mon Sep 16, 2019 1:29 pm
So, now I'm GUESSING kodi might be using a resolution my TV doesn't like? There (should) be a way to tell kodi what resolution to use...
Some folks in the kodi forums try to specify resolution in advancedsettings.xml, but they report those directives are ignored.
Explicitly setting the gui resolution in guisettings.xml to 1280x720 fixed it, so I *guess* the issue was kodi wanted a resolution that my TV didn't like:

I configured videoscreen.resolution and videoscreen.screenmode in guisettings.xml (middle line included for context only)

Code: Select all

<setting id="videoscreen.resolution">26</setting>
<setting id="videoscreen.screenmode">0128000720059.97403pstd</setting>
Thank you so much for your work in producing this package!

luiz_saluti
Posts: 3
Joined: Sat Sep 14, 2019 12:39 am

Re: [Guide] Kodi on Raspbian Buster

Tue Sep 17, 2019 10:54 am

Rascas wrote:
Mon Sep 16, 2019 10:28 pm
luiz_saluti wrote:
Mon Sep 16, 2019 10:05 pm
I had a similar problem regarding audio. I selected bluetooth device through gui, ran emulationstation and web browser youtube video and audio comes out just fine through BT speaker. But when I run kodi, no audio is heard. Selected both alsa devices in the options, and nothing. Here follows a log after running with --debug flag
Well Bluetooth audio never was straightforward in Kodi + Raspbian. I explained that several ocasions in the thread [GUIDE] Kodi on Raspbian Stretch which was accidentaly deleted.
Anyway, you can try to make it work following this thread:
https://www.raspberrypi.org/forums/view ... 8&t=206898
Let me know if and what worked for you after.

PS: In OSs like LibreELEC and OSMC it works without any extra work because they ship a modified PulseAudio and ALSA packages respectively. If someone has any ideas on how to make this easier please let me know, I will gladly try to workaround it.
Thank you, based on that post I could get kodi to work with my bluetooth speakers. But I resorted to scripting to make me able to switch from HDMI to Bluetooth, something I think not every user will be fond of.

LTolledo
Posts: 1951
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: [Guide] Kodi on Raspbian Buster

Tue Sep 17, 2019 11:55 am

Rascas wrote: PS: Just remembered, did you disabled the onboard audio by commenting/removing dtparam=audio=on from /boot/config.txt ? I believe that is needed for the DAC to work.
Im so sorry @rascas but you've made me a very happy person again! :D
DAC-Amp now working on my Raspbian Buster Kodi....
Thanks!

Now I can port all my Raspbian Stretch Desktop to Buster (a working Kodi is a No. 1 requirement for me!) ;)
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Tue Sep 17, 2019 1:37 pm

@LTolledo
@luiz_saluti
@karlandtanya

Wow, nice work. I am glad that it ended up working for you guys!

shrd
Posts: 4
Joined: Fri Jul 12, 2019 1:20 pm

Re: [Guide] Kodi on Raspbian Buster

Wed Sep 18, 2019 7:58 am

it is working quite well but the GUI interface seems slow, 20 to 40 fps is displayed when logging is enabled (why not 60 fps for the interface?)

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Wed Sep 18, 2019 6:13 pm

shrd wrote:
Wed Sep 18, 2019 7:58 am
it is working quite well but the GUI interface seems slow, 20 to 40 fps is displayed when logging is enabled (why not 60 fps for the interface?)
It doesn't look slow for me, what you may be seeing is some tearing. Kodi in Raspberry Pi 4 uses GBM as the window rendering and does not support VSync on the user interface yet, so tearing may occur. Videos play fine though. Raspberry Pi =< 3 support Vsync in the interface.
About the FPS when you activate the logging feature, that is not very accurate, but anyway, you get more or less the same thing in the previous versions of the Raspberry Pi, so that isn't something new.

graphicw
Posts: 77
Joined: Mon Sep 09, 2019 5:04 pm

Re: [Guide] Kodi on Raspbian Buster

Thu Sep 19, 2019 6:20 am

Performs splendidly on my RPI 4 without any tearing whatsoever. This gives me an excuse to order three more Pi's for all TVs.

andrum99
Posts: 815
Joined: Fri Jul 20, 2012 2:41 pm

Re: [Guide] Kodi on Raspbian Buster

Thu Sep 19, 2019 4:18 pm

Please add to your instructions that gpu_mem should not be set higher than 512MB, since this is untested by the folks at Raspberry Pi and may break things.

andrum99
Posts: 815
Joined: Fri Jul 20, 2012 2:41 pm

Re: [Guide] Kodi on Raspbian Buster

Thu Sep 19, 2019 8:48 pm

For anyone trying to get this working on Raspbian Buster Lite - you need two additional packages:

Code: Select all

sudo apt update && sudo apt install libegl1 libgles2
Probably kodi-bin needs these added as additional dependencies.

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Thu Sep 19, 2019 11:27 pm

andrum99 wrote:
Thu Sep 19, 2019 8:48 pm
For anyone trying to get this working on Raspbian Buster Lite - you need two additional packages:

Code: Select all

sudo apt update && sudo apt install libegl1 libgles2
Probably kodi-bin needs these added as additional dependencies.
Thanks, added, should be good in the next build.

andrum99
Posts: 815
Joined: Fri Jul 20, 2012 2:41 pm

Re: [Guide] Kodi on Raspbian Buster

Fri Sep 20, 2019 4:19 am

I'm running your build of Kodi 18.4 on my Pi 4 on Raspbian Buster Lite and everything looks good so far. :D Thanks for the systemd service def as well - I was missing that from my previous install on Pi 3B+ running Stretch.

weebsnore
Posts: 1
Joined: Fri Sep 20, 2019 2:50 pm

Re: [Guide] Kodi on Raspbian Buster

Fri Sep 20, 2019 3:00 pm

Works fantastically on my RPi 4 after applying the udev fix - thank you very much!

A couple of questions for everyone -

1. This setting doesn't seem to work:
Player -> Videos -> Adjust display refresh rate -> Always

Is this fixable?

2. Is it possible to make Alt+Tab between Kodi and the Rasbian desktop work?

And thanks again!

I feel I'm now very close to the web browser + Kodi RPi box I want. The improvement from a couple of months ago is night and day.

BenRandomNameHere
Posts: 3
Joined: Fri Sep 20, 2019 2:59 pm

Re: [Guide] Kodi on Raspbian Buster

Fri Sep 20, 2019 4:34 pm

Ok, I'm a n00b.

I had Kodi installed previously, and attempted to follow this guide.

I immediately get errors.

My actual question:
If I follow these directions in reverse, will that remove it? And then, if I follow the steps in revers to remove my existing Kodi... would I be able to avoid starting all over again making an SD card? Is it more likely to be a waste of time to try to remove the files versus just making a new SD?

EDIT:
So I believe I properly removed all the files from before this guide, and then I followed this guide. Now I see there are still repos from the prior install... could those cause issues?

Also: ALT-TAB seems broken. Is this expected?
Last edited by BenRandomNameHere on Fri Sep 20, 2019 6:17 pm, edited 1 time in total.

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Fri Sep 20, 2019 5:27 pm

Packages updated to 18.4-4.

Changes:

-Added libegl1 and libgles2 dependencies
-Support for "OpenGL desktop driver with fake KMS" on the Raspberry Pi 3. This uses Kodi with GBM (like the Pi 4) but looses H265/HEVC support. The recommended is still using the "Legacy Original non-GL desktop driver" aka Broadcom drivers on the Pi 3, for a more stable/optimized solution. This was a request from the RetroPie folks, more info here: https://retropie.org.uk/forum/topic/193 ... tropie/137

Just update and upgrade the packages has you normally do.
Last edited by Rascas on Fri Sep 20, 2019 10:03 pm, edited 1 time in total.

bat0nas
Posts: 18
Joined: Wed Jul 17, 2019 8:28 am

Re: [Guide] Kodi on Raspbian Buster

Fri Sep 20, 2019 5:30 pm

Hi,

I did everything according the instructions. Did all the tweaks as suggested in OP (GPU memory increase, udev rule etc.).

All work great except little stutters every 3-5 seconds.

TOP shows that kodi loads only 15% of the CPU
Temperature stays constant at 72C. So I guess CPU is not thermal throttling.

I'm running it on Pi 4 4GB.

Playing 1080p mkv file. It happens with all mkv files in my collection.

Do you have 100% smooth playthrough?

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Fri Sep 20, 2019 7:36 pm

BenRandomNameHere wrote:
Fri Sep 20, 2019 4:34 pm
Ok, I'm a n00b.

I had Kodi installed previously, and attempted to follow this guide.

I immediately get errors.

My actual question:
If I follow these directions in reverse, will that remove it? And then, if I follow the steps in revers to remove my existing Kodi... would I be able to avoid starting all over again making an SD card? Is it more likely to be a waste of time to try to remove the files versus just making a new SD?

EDIT:
So I believe I properly removed all the files from before this guide, and then I followed this guide. Now I see there are still repos from the prior install... could those cause issues?

Also: ALT-TAB seems broken. Is this expected?
If you are using some other repo the best is to remove everything related with that.
Look at /etc/apt/sources.list and /etc/apt/sources.list.d/ to remove the repo, be carefull to not remove the usual ones.
Then remove all kodi related packages with:

Code: Select all

sudo apt-get purge kodi*
Note the asterisk at the end.

Then follow this guide again from the beginning.

ALT+TAB does not work in Kodi on the Raspberry Pi, that is expected. Kodi always stays fullscreen and on top.
Last edited by Rascas on Fri Sep 20, 2019 7:41 pm, edited 1 time in total.

Rascas
Posts: 531
Joined: Tue Mar 11, 2014 6:18 pm
Location: Porto, Portugal
Contact: Website

Re: [Guide] Kodi on Raspbian Buster

Fri Sep 20, 2019 7:40 pm

bat0nas wrote:
Fri Sep 20, 2019 5:30 pm
Hi,

I did everything according the instructions. Did all the tweaks as suggested in OP (GPU memory increase, udev rule etc.).

All work great except little stutters every 3-5 seconds.

TOP shows that kodi loads only 15% of the CPU
Temperature stays constant at 72C. So I guess CPU is not thermal throttling.

I'm running it on Pi 4 4GB.

Playing 1080p mkv file. It happens with all mkv files in my collection.

Do you have 100% smooth playthrough?
Works fine here, no stuttering playing videos. But that may depend on the video codec of your files. A Kodi debug log would be helpfull to see your problem with more detail. To get it follow this: http://kodi.wiki/view/Log_file Don't forget to play some of those videos before uploading the log.

Return to “Raspbian”