I'm experiencing problems enabling the usb in a kernel 3.52 app.
First I had problem loading the usbstorms.prx (with the code from the sdk's sample) and I fixed it using pspSdkLoadStartModule.
Now is the last prx that fails to load (giving error 800213C) usbstorboot.prx
This way it fails also the sceUsbstorBootSetCapacity() call.
When I call sceUsbActivate() Windows detects the new hardware but I cannot see the new drive...
Here's my code:
Code: Select all
//Init USB:
int USBinit(){
u32 retVal;
//start necessary drivers
pspSdkLoadStartModule("flash0:/kd/semawm.prx", PSP_MEMORY_PARTITION_KERNEL);
pspSdkLoadStartModule("flash0:/kd/usbstor.prx", PSP_MEMORY_PARTITION_KERNEL);
pspSdkLoadStartModule("flash0:/kd/usbstormgr.prx", PSP_MEMORY_PARTITION_KERNEL);
pspSdkLoadStartModule("flash0:/kd/usbstorms.prx", PSP_MEMORY_PARTITION_KERNEL);
pspSdkLoadStartModule("flash0:/kd/usbstorboot.prx", PSP_MEMORY_PARTITION_KERNEL);
//setup USB drivers
retVal = sceUsbStart(PSP_USBBUS_DRIVERNAME, 0, 0);
if (retVal != 0) {
return -6;
}
retVal = sceUsbStart(PSP_USBSTOR_DRIVERNAME, 0, 0);
if (retVal != 0) {
return -7;
}
retVal = sceUsbstorBootSetCapacity(0x800000);
if (retVal != 0) {
return -8;
}
return 0;
}
P.S. If I copy the prx from my flash0 to my ms, then the module starts correctly...
Many thanks.
Ciaooo
Sakya