Launching an homebrew within another homebrew

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
Phantom8
Posts: 30
Joined: Fri Jun 17, 2005 10:17 am

Launching an homebrew within another homebrew

Post by Phantom8 »

I'm working on a screen shot tool which allows you to take screen shots from other UMD games/homebrew. I know there are a couple available, but I want to make my own.

I have not much problem in getting screenshots for UMD games, but I can't seem to get any homebrew to load properly within my screen shot program. I used sceKernelLoadModule, but it always returns with memory block allocation failure when loading homebrew. I checked I still have 24MB of total free memory left before launching another homebrew. Anyone has any ideas? TIA!
User avatar
groepaz
Posts: 305
Joined: Thu Sep 01, 2005 7:44 am
Contact:

Post by groepaz »

you'll have to create a program that loads into kernel space - look how psplink does that by using a small bootstrap loader and a prx which contains the actual program.
Phantom8
Posts: 30
Joined: Fri Jun 17, 2005 10:17 am

Post by Phantom8 »

groepaz, thanks for the suggestion! Is creating a prx in kernel space the only way to solve the problem? Will it still work if the prx run under user space?
TyRaNiD
Posts: 907
Joined: Sun Jan 18, 2004 12:23 am

Post by TyRaNiD »

A possible alternative is to link your elf at a really low address (think 0x88004000 is the lowest you can go and still run), look at psp-packer's stub source for ideas how to relink an elf to a different address. However the kernel mode prx is the best solution as it moves your code completely out of user memory, although if you are making screenshots using png you will be tight for space as that lib is _big_ :)
Phantom8
Posts: 30
Joined: Fri Jun 17, 2005 10:17 am

Post by Phantom8 »

Thanks for the hint, TyRaNiD! I think I'll stick with the kernel prx approach if I can get it to work. lol.
Post Reply