I'm trying to load some POPs from a hombrew without success. I keep getting 8002014E error...
This is the code which im using.
main.c:
Code: Select all
#include <stdio.h>
#include "systemctrl.h"
PSP_MODULE_INFO("usbpops", 0x1000, 1, 1);
int test_thread(SceSize args, void *argp)
{
char file[256];
strcpy(file, "ms0:/psp/game/sles01760/eboot.pbp");
struct SceKernelLoadExecVSHParam param;
memset(¶m, 0, sizeof(param));
param.key = "game";
param.size = sizeof(param);
param.args = strlen(file)+1;
param.argp = file;
sctrlKernelLoadExecVSHMs4(file, ¶m);
//sctrlKernelLoadExecVSHMs4(file, NULL);
sceKernelExitDeleteThread(0);
return 0;
}
int module_start(SceSize args, void *argp)
{
int thid = sceKernelCreateThread("loadExecVSHMs4Thread", test_thread, 14, 0x3000, 0, NULL);
if(thid >= 0) sceKernelStartThread(thid, args, argp);
sceKernelExitDeleteThread(0);
return 0;
}
Code: Select all
TARGET = usbpops
OBJS = main.o
# Define to build this as a prx (instead of a static elf)
#PRX_EXPORTS=exports.exp
BUILD_PRX=1
#PSP_FW_VERSION = 371
# Define the name of our custom exports (minus the .exp extension)
USE_KERNEL_LIBC=1
USE_KERNEL_LIBS=1
CFLAGS = -Os -G0 -Wall -fno-strict-aliasing -fno-builtin-printf
CXXFLAGS = $(CFLAGS) -fno-exceptions -fno-rtti
ASFLAGS = $(CFLAGS)
INCDIR = include
LIBDIR = lib
LDFLAGS = -mno-crt0 -nostartfiles
LIBS = -lpspsystemctrl_kernel
EXTRA_TARGETS = EBOOT.PBP
PSP_EBOOT_TITLE = usbpops
PSPSDK=$(shell psp-config --pspsdk-path)
include $(PSPSDK)/lib/build.mak
Using that code, if i call sctrlKernelLoadExecVSHMs2() to load a standard homebrew works fine, but not for a PSX EBOOT using sctrlKernelLoadExecVSHMs4().
Any hints?