I know this hasn’t been posted for awhile, but I’ve been keeping a close eye on how well the domain-server and assignment-client run on a humble Raspberry Pi. With the recent updates that have been going on, there are some things that work great and others not so much. The fact it even works at 90% functionality is pretty much a massive accomplishment in my book.
- Avatar positioning works fine
- Audio handling appears to work fine
- Domain-server control panel is 99% functional (see below)
- Assignment-clients run without any massive errors
What doesn’t work:
- Creating objects doesn’t sync with the server
- But letting entities be made from the marketplace seems to work fine
- This results in “EntityItem::deserializeActionsInternal – no _element”
- Setting up default viewpoints for paths seems to not fully work.
Changes that had to be done:
- AVX & AVX2 optimization had to be removed (not available for ARM processors)
- Had to include an additional header to AudioLimiter.h
- #include “stddef.h” just before #include “stdint.h”
Aside from being built on a Raspberry Pi and needing to change a few lines of code, High Fidelity’s server code runs very well and compiles just like any other Linux build, so much so that I used the same notes I have made for building the Pi version to build the version on one of my actual servers (except for changes to any code due to differences in architecture).
While I do plan to make a full from start to finish guide for building High Fidelity on a fresh Ubuntu installation (16.04 and 14.04), honestly the biggest hurdle is just getting QT 5.6.1 (And I just realized I have been fiddling around with 5.6.0. Woops).
Effectively, you just need to (and this is by no means a full guide):
- Flash a micro-SD card with Ubuntu 14.04 or 16.04 from here. (Do note that 14.04 is not available for the Raspberry Pi 3. I don’t have one yet so when I do go ahead and order one, I can provide any notable differences between 14.04’s setup and 16.04)
- Setup the OS as needed (enable SSH, setup accounts, expand storage space, etc).
- Get Qt 5.6.1 onto the Pi (Build it for 4 hours or find a pre-compiled package from someone else).
- Clone the stable build of Hifi from GIthub.
- Modify SetupHifiLibrary.cmake under cmake/macros and comment out the lines that add AVX/mavx and AVX2/mavx2/mfma optimizations (as of this writing, lines 22, 24, 32, and 34).
- Modify AudioLimiter.h under libraries/audio/src to include #include “stddef.h” just before #include “stdint.h”. (This is the only part of the build process that leaves me confused, since without the inclusion of stddef.h, it will fail due to some undefined error. This was resolved by including that header. I’ll report more on this once I rebuild it without this step to include the log of failure)
- Create the build folder and run cmake … (depending on how Qt was set up, you may run into instances of where Qt’s location was not added to paths and some errors will occur. How this is solved is dependent on how Qt was set up).
- Make the domain-server and assignment-client.
While I doubt the Pi can be used as a full server (10+ people), it is rather interesting that a ~10W computer can host an entire domain without too much of an issue (aside from the aforementioned issue with building). I’ll add a post with a full build guide after I get my new Raspberry Pi 3 (though this will also work fine with a Raspberry Pi 2). Meanwhile, my domain ‘soulis-net’ will be running the Pi version of the domain server. Bear in mind that it will a bit barren but does at least show it allows people to go in and out.