diff --git a/projects/Makefile b/projects/Makefile index f7ebfa4c..6145d749 100644 --- a/projects/Makefile +++ b/projects/Makefile @@ -182,6 +182,18 @@ RG35XXDIRS := . \ # ../sources/Adapters/RTMidi \ # Disabled for now # ../sources/Externals/RtMidi +RG35XXPLUSDIRS := . \ + ../sources/Adapters/DINGOO/Main \ + ../sources/Adapters/Unix/FileSystem \ + ../sources/System/Process \ + ../sources/Adapters/Unix/Process \ + ../sources/Adapters/DINGOO/System \ + ../sources/Adapters/Dummy/Midi \ + ../sources/Adapters/SDL/Audio \ + ../sources/Adapters/SDL/Process \ + ../sources/Adapters/SDL/GUI \ + ../sources/Adapters/SDL/Timer + PSPDIRS := . \ ../sources/Adapters/PSP/Main \ ../sources/Adapters/PSP/FileSystem \ @@ -334,6 +346,21 @@ RG35XXFILES := GPSDLMain.o \ # RTMidiOutDevice.o \ # RTMidiInDevice.o \ +RG35XXPLUSFILES := GPSDLMain.o \ + UnixFileSystem.o \ + SDLAudio.o \ + Process.o \ + UnixProcess.o \ + SDLAudioDriver.o \ + MIYOOSystem.o \ + DINGOOEventQueue.o \ + SDLProcess.o \ + SDLTimer.o \ + GUIFactory.o \ + SDLEventManager.o \ + DummyMidi.o \ + SDLGUIWindowImp.o + PSPFILES := PSPmain.o \ PSPFileSystem.o \ Process.o \ diff --git a/projects/Makefile.RG35XXPLUS b/projects/Makefile.RG35XXPLUS new file mode 100644 index 00000000..e31fbad7 --- /dev/null +++ b/projects/Makefile.RG35XXPLUS @@ -0,0 +1,36 @@ +-include $(PWD)/rules_base +STRIP = $(CROSS_COMPILE)strip + +%.elf: $(OFILES) + $(CXX) $(LDFLAGS) -o $@ $(OFILES) $(LIBS) + @$(STRIP) $@ + +# compiled using the https://github.com/shauninman/union-rg35xxplus-toolchain +# Docker image + +DEVKIT = /opt/rg35xxplus-toolchain/usr/ +CROSS_COMPILE=$(DEVKIT)bin/arm-buildroot-linux-gnueabihf- + +CC = $(CROSS_COMPILE)gcc +CXX = $(CROSS_COMPILE)g++ +SYSROOT := $(shell $(CROSS_COMPILE)gcc --print-sysroot) +SDL_CFLAGS := $(shell $(SYSROOT)/usr/bin/sdl-config --cflags) +SDL_LIBS := $(shell $(SYSROOT)/usr/bin/sdl-config --libs) + +DEFINES = -DHAVE_STDINT_H -D_NDEBUG -D_NO_JACK_ -I$(PWD)/../sources -DCPP_MEMORY $(SDL_CFLAGS) $(SDL_LIBS) -DBUFFERED +INCLUDES = -Iinclude $(SDL_CFLAGS) +OPT_FLAGS = -O3 -Ofast -fdata-sections -fdata-sections -fno-common -fno-PIC -flto -marm -mtune=cortex-a53 -mfpu=neon-vfpv4 -mfloat-abi=hard -march=armv8-a + +OUTPUT = ../lgpt-rg35xxplus + +TOOLPATH=$(DEVKIT)/usr/bin +PREFIX := arm-linux-gnueabihf- + +CFLAGS := $(DEFINES) $(INCLUDES) $(OPT_FLAGS) -Wall +CXXFLAGS:= $(CFLAGS) -std=gnu++03 + +EXTENSION:= elf + +LIBS := -lSDL -lpthread +LIBDIRS := $(DEKVIT)/usr/lib +LIBDIRS += $(DEKVIT)/usr/include diff --git a/projects/README.md b/projects/README.md index fc97122e..665ea83e 100644 --- a/projects/README.md +++ b/projects/README.md @@ -12,7 +12,7 @@ using nano ~/.bashrc, add export PSPDEV=~/pspdev export PATH=$PATH:$PSPDEV/bin - at the end, then + at the end, then source ~/.bashrc Build with: make PLATFORM=PSP @@ -70,3 +70,10 @@ apt install -y python3 python3-pillow make PLATFORM=RG35XX +##### RG35XXPLUS: Compile in shauninman toolchain docker + clone: + https://github.com/shauninman/union-rg35xxplus-toolchain + enter docker: + make shell + Build with: + make PLATFORM=RG35XXPLUS diff --git a/projects/resources/RG35XXPLUS/README.md b/projects/resources/RG35XXPLUS/README.md new file mode 100644 index 00000000..60ca4047 --- /dev/null +++ b/projects/resources/RG35XXPLUS/README.md @@ -0,0 +1,22 @@ +# Garlic OS + +## Installation + +1. Copy lgpt-rg35xxplus.elf, config.xml, samplelib, lgpt_BETA to /SdCard/Roms/APPS/lgpt/ +2. Copy LittleGPTracker.png to /SdCard/Roms/Imgs/ +3. Copy garlicos/LittleGPTracker.sh to /SdCard/Roms/ + +## Usage + +Open "Consoles -> Apps -> LittleGPTracker". + +# muOS + +## Installation + +1. Copy lgpt-rg35xxplus.elf, config.xml, samplelib, lgpt_BETA to /mnt/mmc/MUOS/application/.lgpt/ +3. Copy muos/LittleGPTracker.sh to /mnt/mmc/MUOS/application/ + +## Usage + +Open "Applications -> LittleGPTracker". diff --git a/projects/resources/RG35XXPLUS/config.json b/projects/resources/RG35XXPLUS/config.json new file mode 100644 index 00000000..b0a167b6 --- /dev/null +++ b/projects/resources/RG35XXPLUS/config.json @@ -0,0 +1,6 @@ +{ + "label": "LittleGPTracker", + "icon": "lgpt.png", + "launch": "launch.sh", + "description": "16bit sample-based tracker" +} diff --git a/projects/resources/RG35XXPLUS/config.xml b/projects/resources/RG35XXPLUS/config.xml new file mode 100644 index 00000000..21d43983 --- /dev/null +++ b/projects/resources/RG35XXPLUS/config.xml @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/projects/resources/RG35XXPLUS/garlicos/LittleGPTracker.sh b/projects/resources/RG35XXPLUS/garlicos/LittleGPTracker.sh new file mode 100755 index 00000000..f82c0450 --- /dev/null +++ b/projects/resources/RG35XXPLUS/garlicos/LittleGPTracker.sh @@ -0,0 +1,6 @@ +#!/bin/sh +progdir=$(dirname "$0")/lgpt +cd $progdir +HOME=$progdir +LD_LIBRARY_PATH=$PROGDIR:$LD_LIBRARY_PATH ./lgpt-rg35xxplus.elf > ./lgpt.log +sync diff --git a/projects/resources/RG35XXPLUS/lgpt.png b/projects/resources/RG35XXPLUS/lgpt.png new file mode 100644 index 00000000..3ee4d69a Binary files /dev/null and b/projects/resources/RG35XXPLUS/lgpt.png differ diff --git a/projects/resources/RG35XXPLUS/mapping.xml b/projects/resources/RG35XXPLUS/mapping.xml new file mode 100644 index 00000000..d1dea475 --- /dev/null +++ b/projects/resources/RG35XXPLUS/mapping.xml @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/projects/resources/RG35XXPLUS/muos/LittleGPTracker.sh b/projects/resources/RG35XXPLUS/muos/LittleGPTracker.sh new file mode 100644 index 00000000..85588804 --- /dev/null +++ b/projects/resources/RG35XXPLUS/muos/LittleGPTracker.sh @@ -0,0 +1,15 @@ +#!/bin/sh +echo app >/tmp/act_go + +. /opt/muos/script/var/device/storage.sh + +export LD_LIBRARY_PATH=/usr/lib32 + +PROGDIR="$DC_STO_ROM_MOUNT/MUOS/application/.lgpt" +cd $PROGDIR +HOME=$PROGDIR + +echo "lgpt" >/tmp/fg_proc + +LD_LIBRARY_PATH=$PROGDIR:$LD_LIBRARY_PATH ./lgpt-rg35xxplus.elf &> lgpt.log +sync