mirror of
https://github.com/rvtr/TwlIPL.git
synced 2025-10-31 06:01:12 -04:00
テスト時にゴミが残らないようにnand:/tmp以下を利用するようにした。
テストのリザルトメッセージを心持ち親切にした。 git-svn-id: file:///Users/lillianskinner/Downloads/platinum/twl/TwlIPL/trunk@1857 b08762b0-b915-fc4b-9d8c-17b2551a87ff
This commit is contained in:
parent
60b6dedb8c
commit
38408468ba
@ -18,12 +18,13 @@
|
||||
#include <twl.h>
|
||||
#include <sysmenu/util_recoveryFile.h>
|
||||
|
||||
static char *s_strResult[4];
|
||||
|
||||
void VBlankIntr(void);
|
||||
|
||||
void TwlMain( void )
|
||||
{
|
||||
char path[] = "nand:/shared2/a/b/c/d/hogehoge.dat";
|
||||
char path[] = "nand:/tmp/a/b/c/d/hogehoge.dat";
|
||||
UTL_RecoveryStatus result;
|
||||
|
||||
OS_Init();
|
||||
@ -35,10 +36,11 @@ void TwlMain( void )
|
||||
GX_VBlankIntr(TRUE);
|
||||
|
||||
|
||||
// とりあえずファイルサイズに4KB指定
|
||||
result = UTL_RecoveryFile( path, 0x1000 );
|
||||
// とりあえずファイルサイズに16byte指定
|
||||
result = UTL_RecoveryFile( path, 0x0010 );
|
||||
|
||||
OS_TPrintf("recovery result: %d\n", result);
|
||||
OS_TPrintf("%s\n", s_strResult[result] );
|
||||
OS_TPrintf( "*** End of demo\n" );
|
||||
OS_Terminate();
|
||||
|
||||
@ -49,3 +51,10 @@ void VBlankIntr(void)
|
||||
{
|
||||
OS_SetIrqCheckFlag(OS_IE_V_BLANK);
|
||||
}
|
||||
|
||||
static char *s_strResult[] = {
|
||||
"Target file exists and file size matched.",
|
||||
"File size didn't match. Changing size succeeded.",
|
||||
"Target file didn't exist. Creating file and setting size succeeded.",
|
||||
"ERROR: File Recovery Failed."
|
||||
};
|
||||
Loading…
Reference in New Issue
Block a user