From 27a87ba239614ecfe3caa8dee9fa3316b3557191 Mon Sep 17 00:00:00 2001 From: mcc Date: Fri, 27 Nov 2020 17:01:08 -0500 Subject: [PATCH] Android instructions --- README.md | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 53bc568..f9f93d0 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,31 @@ -Lodr is a loader for [lovr](https://lovr.org/). +Lodr is a hot-loader for [lovr](https://lovr.org/). It restarts Lovr with updated code without Lovr itself having to quit and reopen. # How to use +## On Oculus Quest + +Go to the [releases page](https://github.com/mcclure/lodr/releases) for Lodr and download the newest `org.lovr.hotswap` APK. This has Lodr prebuilt in it. + +You will need your Quest in [developer mode](https://learn.adafruit.com/sideloading-on-oculus-quest/enable-developer-mode). You will also need the `adb` command line tool. For example, on Macintosh, you can get `adb` by installing [Homebrew](https://brew.sh/) and running `brew cask install android-platform-tools`; or, you can install [Android Studio](https://developer.android.com/studio), install "Android SDK Platform-Tools" during the first-run setup, and then run `export PATH="~/Library/Android/sdk/platform-tools:$PATH"` in your Terminal.app window before running the following commands. On Windows, to run adb, you can run [these instructions](https://www.howtogeek.com/125769/how-to-install-and-use-abd-the-android-debug-bridge-utility/) (but you will also need to install the special [Quest ADB driver for Windows](https://developer.oculus.com/downloads/package/oculus-adb-drivers/)). + +After downloading `org.lovr.hotswap.apk`, run: + + adb install -r build/lovr.apk + +You only have to do this once. + +Now, whenever you have new software to upload, `cd` to the directory containing your files and run: + + adb push --sync . /sdcard/Android/data/org.lovr.hotswap/files/.lodr + +You can run this while Lodr is running. + +If your program contains print statements, you can view them with: + + adb logcat | grep -i lovr + +## On a desktop computer + Clone or download this repo. Stick the lovr-lodr directory in your command line after the executable name. If `lovr.exe` is the LÖVR command line on your system and `your-game` is your project directory, run @@ -10,7 +34,7 @@ If `lovr.exe` is the LÖVR command line on your system and `your-game` is your p If files change in `your-game` while it is running, lodr will automatically relaunch it. -## Configuration options +# Configuration options Lodr checks for a "lodr" table in the configuration table from conf.lua. You can set options like: