</p> <p><a href="https://love2d.org/">LÖVE</a> is a great gaming framework! I created PiLove to make it easier to play Löve games on the <a href="https://www.raspberrypi.org/">Raspberry PI</a> for everyone to share.</p> <h2 id="so-what-is-it">So what is it?</h2> <p>It's a Raspberry Pi bootable image. It is based on a Raspbian Jessie <a href="http://pipaos.mitako.eu/">derivative OS</a>.</p> <p>PiLove has the latest version of <em>Löve 0.10.0</em> in it, up and running. It has the minimal packages and no Xserver so it boots really fast.</p> <h2 id="how-is-it-built">How is it built?</h2> <p>The SDL2 library needs to be built with OpenGLES and RaspberryPI support. The <a href="http://blog.petrockblock.com/retropie/">RetroPie</a> team have come up with a <a href="https://github.com/RetroPie/SDL-mirror/tree/release-2.0.3">branch</a> that gets this done.</p> <p>For SDL 2.0.4 you need to add the option <em>--host=arm-raspberry-linux-gnueabihf</em>.</p> <p>Then build the official Löve Linux sources on top. There are discussions on the <a href="https://www.raspberrypi.org/forums/viewtopic.php?f=67&amp;t=90184&amp;p=883937">Raspberry PI</a> and <a href="https://love2d.org/forums/viewtopic.php?f=4&amp;t=81380">Love2d</a> forums.</p> <p>The source code to create the PiLove image <a href="https://github.com/skarbat/pilove">is available here</a>.</p> <h2 id="ok-lets-play">Ok, let's play!</h2> <p>Download <a href="downloads/pilove-0.3.img.gz">PiLove v0.3</a> image, burn it to an SDCard of 2GB size or larger, and boot it up.</p> <p>You should see Löve running on your display which looks like this.</p> <p><img src="pilove.png" width="450" height="500"/></p> <p>Pressing the Escape key should bring you to the console login prompt. Type <code>sysop</code> for the login name, and <code>posys</code> for the password.</p> <p>The Löve program is available here: <code>/usr/local/games/love-0.10.0/src/love</code>.</p> <h2 id="version-history">Version History</h2> <p>All versions are available in the <a href="downloads" class="uri">downloads</a> page. I also keep a more detailed <a href="https://github.com/skarbat/pilove/blob/master/changelog.txt">changelog</a>.</p> <ul> <li><strong>PiLove 0.3</strong> - February 20, 2016 - Lua <a href="https://luarocks.org/modules/luarocks/lua-periphery">Periphery</a> and <a href="https://github.com/Tieske/rpi-gpio/blob/master/lua/README.md">RPi.GPIO.Lua</a> to access the IO ports, i2c, spi, mmio, UART.</li> <li><strong>PiLove 0.2</strong> - January 17, 2016 - Comes with SDL version 2.0.4, Love2d 0.10.0</li> <li><strong>PiLove 0.1</strong> - January 9, 2016 - First version, SDL version 2.0.3, Love2d 0.10.0</li> </ul> <h2 id="sample-games">Sample games</h2> <p>There are no games installed at the moment.. Oooooohhh... !</p> <p>If you have the time to collect some, <a href="mailto:albert@mitako.eu">drop me an email</a> so we can add them on the next release!</p> <h2 id="faq">FAQ</h2> <ul> <li><strong>Can I install it on other distros?</strong></li> </ul> <p>It should be easy, but have not tested fully. SDL2 Debian packages and Löve binaries for Raspbian Jessie, are available at the <a href="downloads">downloads page</a>.</p> <p>Install the SDL2 package with <code>sudo dpkg</code>, followed by unzipping the Löve binaries tarball that match the SDL2 build.</p> <p>Please keep in mind that Löve has a special build method which hardcodes the paths during compilation.</p> <p>This means you need to extract the binaries under the <code>/usr/local/games</code> directory, as root, or <a href="https://github.com/skarbat/pilove/blob/master/build-love2d.sh">rebuild everything yourself</a> :-)</p> <ul> <li><strong>I get EGL / GLX Errors</strong></li> </ul> <p>This problem may appear when trying to run Love on top of an X server.</p> <p>Export this variable and run your game again: <code>export SDL_VIDEODRIVER=&quot;rpi&quot;</code>, or try to <code>unset DISPLAY</code>.</p> <p>See this document for more <a href="https://www.libsdl.org/release/SDL-1.2.15/docs/html/sdlenvvars.html">SDL options</a>.</p> <ul> <li><strong>How do I connect PiLove to a wireless network?</strong></li> </ul> <p>Edit the file <code>/etc/network/interfaces</code> to set your ESSID / Passphrase pair, then <code>sudo systemctl reboot</code>.</p> <ul> <li><strong>Does sound work?</strong></li> </ul> <p>Yes, it should go to the analog output. pulseaudio is automatically started during boot. If it stops working, try to start it with <code>pulseaudio --start</code>.</p> <p>To send audio to HDMI edit /boot/config.txt and uncomment the line <code>hdmi_drive=2</code>.</p> <ul> <li><strong>How do I start my preferred game on boot?</strong></li> </ul> <p>Edit the file <code>/etc/rc.local</code> to launch the game of your choosing.</p> <p>If you prefer to mute to boot log messages, edit <code>/boot/cmdline.txt</code> and add this flag <code>systemd.show_status=0</code>.</p> <ul> <li><strong>Does it work on the RaspberryPI touch screen?</strong></li> </ul> <p>Games will show perfectly fine but there is no touch event support just yet. If you find the way to add this feature <a href="https://love2d.org/forums/viewtopic.php?f=4&amp;t=81380">let us know</a>!</p> <h3 id="love2d-tutorials">Love2d Tutorials</h3> <p>Here is a list of some resources I found really useful:</p> <ul> <li>If you're a newbie start here: http://osmstudios.com/tutorials/your-first-love2d-game-in-200-lines-part-1-of-3</li> <li>Really good video tutorial to create a game from scratch: http://cupm.net/public/love2dtutorial/</li> <li>Love2D tutorials page: https://love2d.org/wiki/Category:Tutorials</li> <li>Great tutorials from Michael: http://nova-fusion.com/tags/love2d/</li> <li>Game tutorial from kikito: https://github.com/kikito/love-tile-tutorial/wiki</li> <li>Love2D for android: http://www.fysx.org/code/love-for-android/</li> <li>LoveFrames is a UI framework for Love2D: https://github.com/KennyShields/LoveFrames/wiki/Getting-Started</li> </ul> <h4 id="credits">Credits</h4> <p>Löve is released under the <a href="https://love2d.org/wiki/License">ZLIB license</a>.<br> The Raspberry PI is a trademark of the <a href="https://www.raspberrypi.org/">Raspberry PI foundation</a>.<br> PiLove is free and released under the <a href="https://opensource.org/licenses/MIT">MIT License</a>.<br></p> <p><em>Albert Casals - January 2016</em></p> <p>