-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
How to open navit from kodi?
Hi there,
as I mentioned before in previous posts, I'm building a CarPI on Raspbian using Kodi and Navit;
as theme for kodi I use carpi, which has a navigation button to open navit from kodi, but what code do I need to insert to make it work and overlay kodi in the button it's settings?
It works fine but thats the last step!
Thanks
as I mentioned before in previous posts, I'm building a CarPI on Raspbian using Kodi and Navit;
as theme for kodi I use carpi, which has a navigation button to open navit from kodi, but what code do I need to insert to make it work and overlay kodi in the button it's settings?
It works fine but thats the last step!
Thanks
Re: How to open navit from kodi?
Where did you download that skin? If it has a button to open Navit, I think it is better to ask directly to the respective skin developer.
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
Still waiting for an answer?
Re: How to open navit from kodi?
I'm not even sure how to read this sentence correctly.. can you expand a bit about exactly what setting you are talking about and what you mean with "code"..but what code do I need to insert to make it work and overlay kodi in the button it's settings?
Refering us to another (unlinked) thread for background info is not that polite either..
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
I forgot to paste that url but I meant this post; viewtopic.php?f=73&t=217472&p=1346519#p1346519topguy wrote: ↑Fri Jul 27, 2018 2:06 pmI'm not even sure how to read this sentence correctly.. can you expand a bit about exactly what setting you are talking about and what you mean with "code"..but what code do I need to insert to make it work and overlay kodi in the button it's settings?
Refering us to another (unlinked) thread for background info is not that polite either..
here is some more info about the sentence you didn't quite get
What do I need to insert here (video) to make Navit run?!
https://easycompzeeland.nl/site/assets/ ... .53.49.mp4
Thanks!
Re: How to open navit from kodi?
Have you installed "navit" on the Pi ?
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
How would you start "navit" outside of Kodi ?
In a terminal if you write the command "which navit" you will probably get the response "/usr/bin/navit" or something similar which is the full path to the "navit" executable. You might try to enter that full path into the field in Kodi.
In a terminal if you write the command "which navit" you will probably get the response "/usr/bin/navit" or something similar which is the full path to the "navit" executable. You might try to enter that full path into the field in Kodi.
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
I already tried that method but it doesn't work...topguy wrote: ↑Tue Jul 31, 2018 1:48 pmHow would you start "navit" outside of Kodi ?
In a terminal if you write the command "which navit" you will probably get the response "/usr/bin/navit" or something similar which is the full path to the "navit" executable. You might try to enter that full path into the field in Kodi.
Re: How to open navit from kodi?
Like I said above, I am not familiar with that skin and navit but I am pretty sure that you cannot run any other graphical program on the RPi while Kodi is running. Well, you can start it, but you will only see it when you exit Kodi.EasyComp Zeeland wrote: ↑Thu Aug 02, 2018 2:49 pmI already tried that method but it doesn't work...topguy wrote: ↑Tue Jul 31, 2018 1:48 pmHow would you start "navit" outside of Kodi ?
In a terminal if you write the command "which navit" you will probably get the response "/usr/bin/navit" or something similar which is the full path to the "navit" executable. You might try to enter that full path into the field in Kodi.
So the script you are looking for must:
1- Exit Kodi
2- Start Navit
3- Start Kodi again when you exit Navit
If you contact the skin developer, he probably has or knows some script for that.
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
Now I've created;
#######
import os
import xbmc
#activate GPS USB Dongle
os.system("sudo systemctl stop gpsd.socket")
os.system("sudo systemctl disable gpsd.socket")
os.system("sudo gpsd /dev/ttyUSB0 -F /var/run/gpsd.sock")
#open navit
os.system("navit")
#########
It works although how to minimize kodi so navit can be on top of it?
#######
import os
import xbmc
#activate GPS USB Dongle
os.system("sudo systemctl stop gpsd.socket")
os.system("sudo systemctl disable gpsd.socket")
os.system("sudo gpsd /dev/ttyUSB0 -F /var/run/gpsd.sock")
#open navit
os.system("navit")
#########
It works although how to minimize kodi so navit can be on top of it?
Re: How to open navit from kodi?
Well, that's the problem as Rascas already identified.EasyComp Zeeland wrote: ↑Sat Aug 04, 2018 2:41 pmIt works although how to minimize kodi so navit can be on top of it?
Video output of Kodi on the Pi uses hardware acceleration and output is sent (more or less) directly to the hardware; it bypasses the framebuffer.
There's nothing to minimize. You would have to quit Kodi or maybe it's possible to 'switch off' Kodi output.
Re: How to open navit from kodi?
You can't minimize Kodi, it is rendered in an overlay on the framebuffer. You have to close it and open it again when you exit navit.EasyComp Zeeland wrote: ↑Sat Aug 04, 2018 2:41 pmNow I've created;
#######
import os
import xbmc
#activate GPS USB Dongle
os.system("sudo systemctl stop gpsd.socket")
os.system("sudo systemctl disable gpsd.socket")
os.system("sudo gpsd /dev/ttyUSB0 -F /var/run/gpsd.sock")
#open navit
os.system("navit")
#########
It works although how to minimize kodi so navit can be on top of it?
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
Rascas wrote: ↑Sat Aug 04, 2018 4:33 pmYou can't minimize Kodi, it is rendered in an overlay on the framebuffer. You have to close it and open it again when you exit navit.EasyComp Zeeland wrote: ↑Sat Aug 04, 2018 2:41 pmNow I've created;
#######
import os
import xbmc
#activate GPS USB Dongle
os.system("sudo systemctl stop gpsd.socket")
os.system("sudo systemctl disable gpsd.socket")
os.system("sudo gpsd /dev/ttyUSB0 -F /var/run/gpsd.sock")
#open navit
os.system("navit")
#########
It works although how to minimize kodi so navit can be on top of it?
Hmm, wondering if there is a workaround!
Re: How to open navit from kodi?
Try this:
-Create a bash script with the following:
-Change the last line of your python script by this:
Other solution would be to compile Kodi yourself with support for X server and OpenGL, but it will be much slower and without video decoding acceleration.
-Create a bash script with the following:
Code: Select all
#!/bin/bash
sudo killall -9 kodi.bin
navit
kodi &
Code: Select all
os.system("bash /path/to/the/script/scriptname")
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
I created this now it seems to do something at least, it doesn't kill kodi but It suddenly restarts kodi when I'll exit navit, I can control navit from vncRascas wrote: ↑Sun Aug 05, 2018 2:33 amTry this:
-Create a bash script with the following:-Change the last line of your python script by this:Code: Select all
#!/bin/bash sudo killall -9 kodi.bin navit kodi &
Other solution would be to compile Kodi yourself with support for X server and OpenGL, but it will be much slower and without video decoding acceleration.Code: Select all
os.system("bash /path/to/the/script/scriptname")

Code: Select all
#######
import os
import xbmc
#activate GPS dongle
os.system("bash /home/pi/.kodi/addons/skin.CarPc-Carbon/scripts/ActiveerGPS.sh")
#run navit
os.system("navit")
#kill kodi and comeback when navit gets killed
os.system("bash /home/pi/.kodi/addons/skin.CarPc-Carbon/scripts/minimizekodi.sh")
#########
Code: Select all
sudo systemctl stop gpsd.socket
sudo systemctl disable gpsd.socket
sudo gpsd /dev/ttyUSB0 -F /var/run/gpsd.sock
Code: Select all
#!/bin/bash
sudo killall -9 kodi.bin
navit
kodi &
Re: How to open navit from kodi?
If it is a RPi 2 or 3, it is:
Code: Select all
sudo killall kodi_v7.bin
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
it seems completely ignored, kodi doesn't get killed..Rascas wrote: ↑Sun Aug 05, 2018 7:53 pmIf it is a RPi 2 or 3, it is:Code: Select all
sudo killall kodi_v7.bin
Re: How to open navit from kodi?
Check the processes running with top or something. I can kill Kodi here just fine via ssh with that.EasyComp Zeeland wrote: ↑Mon Aug 06, 2018 9:52 amit seems completely ignored, kodi doesn't get killed..Rascas wrote: ↑Sun Aug 05, 2018 7:53 pmIf it is a RPi 2 or 3, it is:Code: Select all
sudo killall kodi_v7.bin
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
Well I can kill it with ssh as well but the script doesn't seem to work..Rascas wrote: ↑Mon Aug 06, 2018 10:06 amCheck the processes running with top or something. I can kill Kodi here just fine via ssh with that.EasyComp Zeeland wrote: ↑Mon Aug 06, 2018 9:52 amit seems completely ignored, kodi doesn't get killed..Rascas wrote: ↑Sun Aug 05, 2018 7:53 pmIf it is a RPi 2 or 3, it is:Code: Select all
sudo killall kodi_v7.bin
-
- Posts: 20
- Joined: Thu Jul 05, 2018 1:50 pm
- Contact: Website
Re: How to open navit from kodi?
Any Response please?EasyComp Zeeland wrote: ↑Mon Aug 06, 2018 11:25 amWell I can kill it with ssh as well but the script doesn't seem to work..Rascas wrote: ↑Mon Aug 06, 2018 10:06 amCheck the processes running with top or something. I can kill Kodi here just fine via ssh with that.EasyComp Zeeland wrote: ↑Mon Aug 06, 2018 9:52 am
it seems completely ignored, kodi doesn't get killed..
Re: How to open navit from kodi?
Try without -9, try to debug that by yourself, add some echos/printfs to a file, on both python and bash scripts, try to launch navit first and kill kodi after, I don't know... You already know what you have to do, try different approaches to do the same.
-
- Posts: 1
- Joined: Sat Oct 13, 2018 5:52 pm
Re: How to open navit from kodi?
Hi,EasyComp Zeeland wrote: ↑Sun Aug 05, 2018 6:50 pmI created this now it seems to do something at least, it doesn't kill kodi but It suddenly restarts kodi when I'll exit navit, I can control navit from vncRascas wrote: ↑Sun Aug 05, 2018 2:33 amTry this:
-Create a bash script with the following:-Change the last line of your python script by this:Code: Select all
#!/bin/bash sudo killall -9 kodi.bin navit kodi &
Other solution would be to compile Kodi yourself with support for X server and OpenGL, but it will be much slower and without video decoding acceleration.Code: Select all
os.system("bash /path/to/the/script/scriptname")
not from my 7" pi screen which got kodi on it.
Main .py scriptCode: Select all
####### import os import xbmc #activate GPS dongle os.system("bash /home/pi/.kodi/addons/skin.CarPc-Carbon/scripts/ActiveerGPS.sh") #run navit os.system("navit") #kill kodi and comeback when navit gets killed os.system("bash /home/pi/.kodi/addons/skin.CarPc-Carbon/scripts/minimizekodi.sh") #########
Code to activate GPS dongle - ActiveerGPS.shCode: Select all
sudo systemctl stop gpsd.socket sudo systemctl disable gpsd.socket sudo gpsd /dev/ttyUSB0 -F /var/run/gpsd.sock
Kill kodi and comeback script - Minimizekodi.shCode: Select all
#!/bin/bash sudo killall -9 kodi.bin navit kodi &
I am very new to Raspberry Pi and Kodi. I need your help in getting called Navit from Kodi. Can you please provide step by step procedure how to call Navit from Kodi? The python script works fine from RPi terminal but i dont understand how i should call Navit from Kodi.. Need your help plss..