Editing ISO.BIN.EDAT

Jump to navigation Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 343: Line 343:
<!--// CELL_FS_  CELL_FS //-->
<!--// CELL_FS_  CELL_FS //-->
<pre>
<pre>
#define PSP_EMULATOR_KLIC {{0x2A, 0x6A, 0xFB, 0xCF, 0x43, 0xD1, 0x57, 0x9F, 0x7D, 0x73, 0x87, 0x41, 0xA1, 0x3B, 0xD4, 0x2E}}
#define PSP_EMULATOR_KLIC {0x2A,0x6A,0xFB,0xCF,0x43,0xD1,0x57,0x9F,0x7D,0x73,0x87,0x41,0xA1,0x3B,0xD4,0x2E}
#define BUF_SIZE      (16*1024)
#define BUF_SIZE      (16*1024)
#define NP_POOL_SIZE  (128*1024)
#define NP_POOL_SIZE  (128*1024)
Line 349: Line 349:
#include <np.h>
#include <np.h>
#include <np/drm.h>
#include <np/drm.h>
#include <stdio.h>
#include <cell/cell_fs.h>
#include <cell/sysmodule.h>


int main ()
{
uint8_t np_pool[NP_POOL_SIZE];
uint8_t np_pool[NP_POOL_SIZE];
uint8_t read_buf[BUF_SIZE];
uint8_t read_buf[BUF_SIZE];
Line 372: Line 367:
ret = sceNpDrmIsAvailable2(&k_licensee, edata_file);
ret = sceNpDrmIsAvailable2(&k_licensee, edata_file);
if (ret != CELL_OK) {
if (ret != CELL_OK) {
printf("EDAT not activated\n");
printf("EDAT not activated\n", ret);
return ret;
return ret;
}
}
Line 379: Line 374:
ret = cellFsOpen(edata_file, CELL_FS_O_RDONLY, &fd1, &arg, sizeof(arg));
ret = cellFsOpen(edata_file, CELL_FS_O_RDONLY, &fd1, &arg, sizeof(arg));
if (ret != CELL_FS_OK) {
if (ret != CELL_FS_OK) {
printf("Error opening for reading\n");
printf("Error opening for reading\n", ret);
return ret;
return ret;
}
}
Line 385: Line 380:
ret = cellFsOpen(raw_file, CELL_FS_O_RDWR|CELL_FS_O_CREAT, &fd2, NULL, 0);
ret = cellFsOpen(raw_file, CELL_FS_O_RDWR|CELL_FS_O_CREAT, &fd2, NULL, 0);
if (ret != CELL_FS_OK) {
if (ret != CELL_FS_OK) {
printf("Error opening file\n");
printf("Error opening file\n", ret);
cellFsClose(fd2);
cellFsClose(fd2);
return ret;
return ret;
Line 422: Line 417:
ret = cellSysmoduleUnloadModule(CELL_SYSMODULE_SYSUTIL_NP);
ret = cellSysmoduleUnloadModule(CELL_SYSMODULE_SYSUTIL_NP);
ret = cellSysmoduleUnloadModule(CELL_SYSMODULE_FS);
ret = cellSysmoduleUnloadModule(CELL_SYSMODULE_FS);
return ret;
}
</pre>
</pre>


Please note that all contributions to PS3 Developer wiki are considered to be released under the GNU Free Documentation License 1.2 (see PS3 Developer wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following hCaptcha:

Cancel Editing help (opens in new window)