Skip to content

Handheld firmware optimized for the Anbernic RG351P/M/V/MP and RG552 devices.

License

Notifications You must be signed in to change notification settings

medeirosT/AmberELEC

 
 

Repository files navigation

GitHub-Mark-Dark GitHub-Mark-Light GitHub Release Downloads Latest Downloads Prerelease Discord

An open source firmware for the Anbernic RG351P/M/V/MP, RG552 and other compatible devices (see listing below).

AmberELEC (formerly know as 351ELEC) is a fork of EmuELEC which is based on CoreELEC, Lakka, and Batocera.

We have a Website with installation instructions and a lot of information on how to get started using AmberELEC.

Visit us on our Discord! https://discord.com/invite/R9Er7hkRMe

Supported Devices

SoC Manufacturer Device
RK3399 Anbernic RG552
RK3326 Anbernic RG351P
RG351M[1]
RG351V[2]
RG351MP[2]
PowKiddy RGB20S[3]
Magicx XU10[3]
Game Console
Game Station
R35S[3]
R36S[3]
SZDiiER D007 Plus[3]

Important

[1] use the RG351P image
[2] for RG351V and RG351MP devices with v2 display the use of the pre-release image is mandatory
[3] use the RG351MP pre-release image

Caution

Do not replace or rename any of the .dtb files after flashing a new image or updating from an older AmberELEC release. To simplify the process and reduce complexity, we're determining which display the device is using, so no manual interaction is necessary.

Installation

Please visit our Website Installation page for installation instructions.

Building from Source

Building AmberELEC from source is a fairly simple process. It is recommended to have a minimum of 4 cores, 16GB of RAM, and an SSD with 200GB of free space. The build environment used to develop these steps uses Ubuntu 20.04, your mileage may vary when building on other distributions.

Important

On Ubuntu 20.04 it's required to add the following apt-repository as golang 1.17 or higher is required for building AmberELEC:
sudo add-apt-repository ppa:longsleep/golang-backports

sudo apt update && sudo apt upgrade

sudo apt install gcc make git unzip wget xz-utils libsdl2-dev libsdl2-mixer-dev libfreeimage-dev libfreetype6-dev libcurl4-openssl-dev rapidjson-dev libasound2-dev libgl1-mesa-dev build-essential libboost-all-dev cmake fonts-droid-fallback libvlc-dev libvlccore-dev vlc-bin texinfo premake4 golang libssl-dev curl patchelf xmlstarlet patchutils gawk gperf xfonts-utils default-jre python xsltproc libjson-perl lzop libncurses5-dev device-tree-compiler u-boot-tools rsync p7zip unrar libparse-yapp-perl zip binutils-aarch64-linux-gnu dos2unix p7zip-full libvpx-dev meson

git clone https://github.com/AmberELEC/AmberELEC.git AmberELEC

cd AmberELEC

make clean

make world

The make world process will build and generate a image which will be located in AmberELEC/release. Follow the installation steps to write your image to a microSD. It will build for the RG351P/M, RG351V, RG351MP and for the RG552.

To create the image for the RG351P/M just make RG351P, and just for the RG351V make RG351V, and just for the RG351MP make RG351MP, and just for the RG552 make RG552.

Building from Source - Docker

Building with Docker simplifies the build process as any dependencies, with the exception of make, are contained within the docker image - all CPU/RAM/Disk/build time requirements remain similar.

NOTE: Make can be installed with sudo apt update && sudo apt install -y make on Ubuntu-based systems.

All make commands are available via docker, by prepending docker-. make RG351V becomes make docker-RG351V and make clean becomes make docker-clean.

New docker make commands:

  • make docker-image-build - Builds the docker image based on the Dockerfile. This is not required unless changes are needed locally.
  • make docker-image-pull - Pulls docker image from dockerhub. This will update to the latest image and replace any locally built changes to the docker file.
  • make docker-shell - (advanced) Launches a shell inside the docker build container. This allows running any development commands like ./scripts/build, etc, which aren't in the Makefile.
    • NOTE: Errors like groups: cannot find name for group ID 1002 and the user being listed as I have no name! are OK and a result of mapping the host user/group into the docker container where the host user/groups may not exist.

Example building with docker:

git clone https://github.com/AmberELEC/AmberELEC.git AmberELEC
cd AmberELEC
make docker-clean
make docker-world

Automated Dev Builds

Builds are automatically run on commits to main and for Pull Requests (PR's) from previous committers.

Development builds can be found looking for the green checkmarks next to commit history. Artifacts are generated for each build which can be used to update the RG351P/RG351V and are stored for 30 days by GitHub. Note that due to Github Action limitations, artifacts are zipped (.img.gz and .tar are inside the zip file).

All artifacts generated by builds should be considered 'unstable' and only used by developers or advanced users who want to test the latest code.

See: Build Overview for more information.

GitHub Actions and Forks

Builds use GitHub actions (.github/workflow) to execute. GitHub validates that changes to the .github/workflow folder require a special workflow permission.

When using Personal Access Token to push in upstream changes from AmberELEC into your fork, you may get an error similar to the following:

! [remote rejected] main -> main (refusing to allow a Personal Access Token to create or update workflow `.github/workflows/README.md` without `workflow` scope)
error: failed to push some refs to 'https://github.com/my-AmberELEC-fork/AmberELEC.git'

To fix, edit the Personal Access Token to add workflow permissions (or create a new token with workflow permission).

Alternatively, ssh-key authentication can be used.

About

Handheld firmware optimized for the Anbernic RG351P/M/V/MP and RG552 devices.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Makefile 35.3%
  • Shell 27.7%
  • GLSL 26.2%
  • Python 8.4%
  • C 1.6%
  • CMake 0.5%
  • Other 0.3%