]> pere.pagekite.me Git - homepage.git/blobdiff - blog/index.rss
Generated.
[homepage.git] / blog / index.rss
index 0581cf3d482ab8c7e39c677c5c73a37392121db7..0658da3ceb473559332fb9fcaea7c954796e640c 100644 (file)
@@ -6,6 +6,36 @@
                 <link>http://people.skolelinux.org/pere/blog/</link>
                 <atom:link href="http://people.skolelinux.org/pere/blog/index.rss" rel="self" type="application/rss+xml" />
        
+       <item>
+               <title>Using the Kodi API to play Youtube videos</title>
+               <link>http://people.skolelinux.org/pere/blog/Using_the_Kodi_API_to_play_Youtube_videos.html</link>
+               <guid isPermaLink="true">http://people.skolelinux.org/pere/blog/Using_the_Kodi_API_to_play_Youtube_videos.html</guid>
+                <pubDate>Sun, 2 Sep 2018 23:40:00 +0200</pubDate>
+               <description>&lt;p&gt;I continue to explore my Kodi installation, and today I wanted to
+tell it to play a youtube URL I received in a chat, without having to
+insert search terms using the on-screen keyboard.  After searching the
+web for API access to the Youtube plugin and testing a bit, I managed
+to find a recipe that worked.  If you got a kodi instance with its API
+available from http://kodihost/jsonrpc, you can try the following to
+have check out a nice cover band.&lt;/p&gt;
+
+&lt;p&gt;&lt;blockquote&gt;&lt;pre&gt;curl --silent --header &#39;Content-Type: application/json&#39; \
+  --data-binary &#39;{ &quot;id&quot;: 1, &quot;jsonrpc&quot;: &quot;2.0&quot;, &quot;method&quot;: &quot;Player.Open&quot;,
+  &quot;params&quot;: {&quot;item&quot;: { &quot;file&quot;:
+  &quot;plugin://plugin.video.youtube/play/?video_id=LuRGVM9O0qg&quot; } } }&#39; \
+  http://projector.local/jsonrpc&lt;/pre&gt;&lt;/blockquote&gt;&lt;/p&gt;
+
+&lt;p&gt;I&#39;ve extended kodi-stream program to take a video source as its
+first argument.  It can now handle direct video links, youtube links
+and &#39;desktop&#39; to stream my desktop to Kodi.  It is almost like a
+Chromecast. :)&lt;/p&gt;
+
+&lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
+activities, please send Bitcoin donations to my address
+&lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
+</description>
+       </item>
+       
        <item>
                <title>Software created using taxpayers’ money should be Free Software</title>
                <link>http://people.skolelinux.org/pere/blog/Software_created_using_taxpayers__money_should_be_Free_Software.html</link>
@@ -649,67 +679,6 @@ using, and selling the surplus electricity to the Norwegian power
 grid.  I find the concept truly amazing.  Is this the worlds only
 stone power plant?&lt;/p&gt;
 
-&lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
-activities, please send Bitcoin donations to my address
-&lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
-</description>
-       </item>
-       
-       <item>
-               <title>Add-on to control the projector from within Kodi</title>
-               <link>http://people.skolelinux.org/pere/blog/Add_on_to_control_the_projector_from_within_Kodi.html</link>
-               <guid isPermaLink="true">http://people.skolelinux.org/pere/blog/Add_on_to_control_the_projector_from_within_Kodi.html</guid>
-                <pubDate>Tue, 26 Jun 2018 23:55:00 +0200</pubDate>
-               <description>&lt;p&gt;My movie playing setup involve &lt;a href=&quot;https://kodi.tv/&quot;&gt;Kodi&lt;/a&gt;,
-&lt;a href=&quot;https://openelec.tv&quot;&gt;OpenELEC&lt;/a&gt; (probably soon to be
-replaced with &lt;a href=&quot;https://libreelec.tv/&quot;&gt;LibreELEC&lt;/a&gt;) and an
-Infocus IN76 video projector.  My projector can be controlled via both
-a infrared remote controller, and a RS-232 serial line.  The vendor of
-my projector, &lt;a href=&quot;https://www.infocus.com/&quot;&gt;InFocus&lt;/a&gt;, had been
-sensible enough to document the serial protocol in its user manual, so
-it is easily available, and I used it some years ago to write
-&lt;a href=&quot;https://github.com/petterreinholdtsen/infocus-projector-control&quot;&gt;a
-small script to control the projector&lt;/a&gt;.  For a while now, I longed
-for a setup where the projector was controlled by Kodi, for example in
-such a way that when the screen saver went on, the projector was
-turned off, and when the screen saver exited, the projector was turned
-on again.&lt;/p&gt;
-
-&lt;p&gt;A few days ago, with very good help from parts of my family, I
-managed to find a Kodi Add-on for controlling a Epson projector, and
-got in touch with its author to see if we could join forces and make a
-Add-on with support for several projectors.  To my pleasure, he was
-positive to the idea, and we set out to add InFocus support to his
-add-on, and make the add-on suitable for the official Kodi add-on
-repository.&lt;/p&gt;
-
-&lt;p&gt;The Add-on is now working (for me, at least), with a few minor
-adjustments.  The most important change I do relative to the master
-branch in the github repository is embedding the
-&lt;a href=&quot;https://github.com/pyserial/pyserial&quot;&gt;pyserial module&lt;/a&gt; in
-the add-on.  The long term solution is to make a &quot;script&quot; type
-pyserial module for Kodi, that can be pulled in as a dependency in
-Kodi.  But until that in place, I embed it.&lt;/p&gt;
-
-&lt;p&gt;The add-on can be configured to turn on the projector when Kodi
-starts, off when Kodi stops as well as turn the projector off when the
-screensaver start and on when the screesaver stops.  It can also be
-told to set the projector source when turning on the projector.
-
-&lt;p&gt;If this sound interesting to you, check out
-&lt;a href=&quot;https://github.com/fredrik-eriksson/kodi_projcontrol&quot;&gt;the
-project github repository&lt;/a&gt;.  Perhaps you can send patches to
-support your projector too?  As soon as we find time to wrap up the
-latest changes, it should be available for easy installation using any
-Kodi instance.&lt;/p&gt;
-
-&lt;p&gt;For future improvements, I would like to add projector model
-detection and the ability to adjust the brightness level of the
-projector from within Kodi.  We also need to figure out how to handle
-the cooling period of the projector.  My projector refuses to turn on
-for 60 seconds after it was turned off.  This is not handled well by
-the add-on at the moment.&lt;/p&gt;
-
 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
 activities, please send Bitcoin donations to my address
 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;