mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-09-05 07:17:45 -04:00
partially revived platform support for PSP (unfinished), part 3
changes to libpicofe, fixed path handling
This commit is contained in:
parent
df6d9f93fe
commit
80bc22540a
6 changed files with 21 additions and 9 deletions
2
.gitmodules
vendored
2
.gitmodules
vendored
|
@ -1,6 +1,6 @@
|
||||||
[submodule "platform/libpicofe"]
|
[submodule "platform/libpicofe"]
|
||||||
path = platform/libpicofe
|
path = platform/libpicofe
|
||||||
url = https://github.com/notaz/libpicofe.git
|
url = https://github.com/irixxxx/libpicofe.git
|
||||||
[submodule "cpu/cyclone"]
|
[submodule "cpu/cyclone"]
|
||||||
path = cpu/cyclone
|
path = cpu/cyclone
|
||||||
url = https://github.com/notaz/cyclone68000.git
|
url = https://github.com/notaz/cyclone68000.git
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit e0bf794693c1c2384ef704e687df448168cd5170
|
Subproject commit 26632f960f881fa64f3f6805f588c729dc3d651d
|
|
@ -609,6 +609,7 @@ void plat_init(void)
|
||||||
in_psp_init(in_psp_defbinds);
|
in_psp_init(in_psp_defbinds);
|
||||||
in_probe();
|
in_probe();
|
||||||
sound_init();
|
sound_init();
|
||||||
|
plat_get_data_dir(rom_fname_loaded, sizeof(rom_fname_loaded));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* platform dependend emulator deinitialization */
|
/* platform dependend emulator deinitialization */
|
||||||
|
|
|
@ -36,7 +36,7 @@ static int mh_scale(int id, int keys)
|
||||||
}
|
}
|
||||||
if (keys & PBTN_LEFT) *val += -0.01;
|
if (keys & PBTN_LEFT) *val += -0.01;
|
||||||
if (keys & PBTN_RIGHT) *val += +0.01;
|
if (keys & PBTN_RIGHT) *val += +0.01;
|
||||||
if (*val <= 0) *val = +0.01;
|
if (*val < 0.01) *val = +0.01;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -110,17 +110,28 @@ void plat_early_init(void)
|
||||||
/* base directory for configuration and save files */
|
/* base directory for configuration and save files */
|
||||||
int plat_get_root_dir(char *dst, int len)
|
int plat_get_root_dir(char *dst, int len)
|
||||||
{
|
{
|
||||||
*dst = 0;
|
if (len > 0) *dst = 0;
|
||||||
if (len > 4)
|
|
||||||
strcpy(dst, "ms0:/");
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* base directory for emulator resources */
|
/* base directory for emulator resources */
|
||||||
int plat_get_skin_dir(char *dst, int len)
|
int plat_get_skin_dir(char *dst, int len)
|
||||||
{
|
{
|
||||||
if (len > 0) *dst = 0;
|
if (len > 4)
|
||||||
return 0;
|
strcpy(dst, "skin/");
|
||||||
|
else if (len > 0)
|
||||||
|
*dst = 0;
|
||||||
|
return strlen(dst);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* top directory for rom images */
|
||||||
|
int plat_get_data_dir(char *dst, int len)
|
||||||
|
{
|
||||||
|
if (len > 4)
|
||||||
|
strcpy(dst, "ms0:/");
|
||||||
|
else if (len > 0)
|
||||||
|
*dst = 0;
|
||||||
|
return strlen(dst);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* check if path is a directory */
|
/* check if path is a directory */
|
||||||
|
|
|
@ -135,7 +135,7 @@ void psp_init(void)
|
||||||
lprintf("\n%s\n", "PicoDrive v" VERSION " " __DATE__ " " __TIME__);
|
lprintf("\n%s\n", "PicoDrive v" VERSION " " __DATE__ " " __TIME__);
|
||||||
lprintf("running on %08x kernel\n", sceKernelDevkitVersion()),
|
lprintf("running on %08x kernel\n", sceKernelDevkitVersion()),
|
||||||
lprintf("entered psp_init, threadId %08x, priority %i\n", main_thread_id,
|
lprintf("entered psp_init, threadId %08x, priority %i\n", main_thread_id,
|
||||||
sceKernelGetThreadCurrentPriority());
|
sceKernelGetThreadCurrentPriority());
|
||||||
|
|
||||||
thid = sceKernelCreateThread("update_thread", callback_thread, 0x11, 0xFA0, 0, NULL);
|
thid = sceKernelCreateThread("update_thread", callback_thread, 0x11, 0xFA0, 0, NULL);
|
||||||
if (thid >= 0)
|
if (thid >= 0)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue