mirror of
https://github.com/rvtr/ctr_Repair.git
synced 2025-10-31 13:51:08 -04:00
ネットワークアップデート完了後の再起動前にボタン操作を待つように
操作の前にカーソル音を鳴らすように git-svn-id: file:///Volumes/Transfer/gigaleak_20231201/2020-05-23%20-%20ctr.7z%20+%20svn_v1.068.zip/ctr/svn/ctr_Repair@42 385bec56-5757-e545-9c3a-d8741f4650f1
This commit is contained in:
parent
cf30075a41
commit
45fee26050
@ -45,6 +45,8 @@ typedef enum BackupState
|
|||||||
bool s_ExistAPSettingAnnotation = false;
|
bool s_ExistAPSettingAnnotation = false;
|
||||||
|
|
||||||
BackupState s_BackupState = STARTUP;
|
BackupState s_BackupState = STARTUP;
|
||||||
|
bool s_PlayedStartCursor = false;
|
||||||
|
bool s_PlayedSdPullOutCursor = false;
|
||||||
bool s_PlayedFinishedSound = false;
|
bool s_PlayedFinishedSound = false;
|
||||||
bool s_PlayedFailSound = false;
|
bool s_PlayedFailSound = false;
|
||||||
|
|
||||||
@ -130,13 +132,17 @@ void ControlState(::std::vector<std::string>& operationMessage, bool& nextStep,
|
|||||||
if(!error)
|
if(!error)
|
||||||
{
|
{
|
||||||
operationMessage.push_back(::std::string("Push A or START Button"));
|
operationMessage.push_back(::std::string("Push A or START Button"));
|
||||||
|
if(!s_PlayedStartCursor)
|
||||||
|
{
|
||||||
|
common::PlaySound(common::SOUND_CURSOR);
|
||||||
|
s_PlayedStartCursor = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nextStep && !error)
|
if (nextStep && !error)
|
||||||
{
|
{
|
||||||
COMMON_LOGGER("Start Export Data\n");
|
COMMON_LOGGER("Start Export Data\n");
|
||||||
s_BackupState = EXPORT_TWL_SOUND;
|
s_BackupState = EXPORT_TWL_SOUND;
|
||||||
common::PlaySound(common::SOUND_CURSOR);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -227,6 +233,11 @@ void ControlState(::std::vector<std::string>& operationMessage, bool& nextStep,
|
|||||||
case DONE:
|
case DONE:
|
||||||
{
|
{
|
||||||
operationMessage.push_back(::std::string("Backup Done. Pull Out SD Card."));
|
operationMessage.push_back(::std::string("Backup Done. Pull Out SD Card."));
|
||||||
|
if(!s_PlayedSdPullOutCursor)
|
||||||
|
{
|
||||||
|
common::PlaySound(common::SOUND_CURSOR);
|
||||||
|
s_PlayedSdPullOutCursor = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -291,6 +302,8 @@ void InitializeState()
|
|||||||
s_PlayedFailSound = false;
|
s_PlayedFailSound = false;
|
||||||
s_PlayedFinishedSound = false;
|
s_PlayedFinishedSound = false;
|
||||||
s_ExistAPSettingAnnotation = false;
|
s_ExistAPSettingAnnotation = false;
|
||||||
|
s_PlayedStartCursor = false;
|
||||||
|
s_PlayedSdPullOutCursor = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace ConsoleBackup
|
} // namespace ConsoleBackup
|
||||||
|
|||||||
@ -40,6 +40,7 @@ typedef enum RestoreState
|
|||||||
SERIAL_IS_NOT_IN_SD, // シリアルナンバーファイルがSDカードにないことを表示
|
SERIAL_IS_NOT_IN_SD, // シリアルナンバーファイルがSDカードにないことを表示
|
||||||
SERIAL_IN_SD, // シリアルナンバーの情報を表示
|
SERIAL_IN_SD, // シリアルナンバーの情報を表示
|
||||||
UPDATE_IN_PROGRESS, // アップデート中
|
UPDATE_IN_PROGRESS, // アップデート中
|
||||||
|
UPDATE_DONE, // アップデート完了
|
||||||
RESTORE_TWL_SOUND, // TWLサウンドの書き込み中
|
RESTORE_TWL_SOUND, // TWLサウンドの書き込み中
|
||||||
RESTORE_TWL_PHOTO, // TWL写真の書き込み中
|
RESTORE_TWL_PHOTO, // TWL写真の書き込み中
|
||||||
RESTORE_IN_PROGRESS, // 書き込み中
|
RESTORE_IN_PROGRESS, // 書き込み中
|
||||||
@ -71,6 +72,12 @@ bool s_APSettingAnnotation = false;
|
|||||||
bool s_SerialNumberAnnotation = false;
|
bool s_SerialNumberAnnotation = false;
|
||||||
// 失敗サウンドを鳴らしたかどうか
|
// 失敗サウンドを鳴らしたかどうか
|
||||||
bool s_PlayedFailSound = false;
|
bool s_PlayedFailSound = false;
|
||||||
|
// 操作開始サウンドを鳴らしたかどうか
|
||||||
|
bool s_PlayedStartCursor = false;
|
||||||
|
// リブート開始前サウンドを鳴らしたかどうか
|
||||||
|
bool s_PlayedRebootCursor = false;
|
||||||
|
// SD抜き出し前サウンドを鳴らしたかどうか
|
||||||
|
bool s_PlayedSdPullOutCursor = false;
|
||||||
|
|
||||||
// ネットワークアップデートを開始したかどうか
|
// ネットワークアップデートを開始したかどうか
|
||||||
bool s_ExecuteFgNup = false;
|
bool s_ExecuteFgNup = false;
|
||||||
@ -298,6 +305,12 @@ void ControlState(::std::vector<std::string>& operationMessage, bool& nextStep,
|
|||||||
{
|
{
|
||||||
operationMessage.push_back(::std::string("Import Data Mode"));
|
operationMessage.push_back(::std::string("Import Data Mode"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!s_PlayedStartCursor)
|
||||||
|
{
|
||||||
|
PlaySound(SOUND_CURSOR);
|
||||||
|
s_PlayedStartCursor = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nextStep && !error)
|
if (nextStep && !error)
|
||||||
@ -311,20 +324,18 @@ void ControlState(::std::vector<std::string>& operationMessage, bool& nextStep,
|
|||||||
ExecSyncMcuRtc();
|
ExecSyncMcuRtc();
|
||||||
|
|
||||||
s_RestoreState = UPDATE_IN_PROGRESS;
|
s_RestoreState = UPDATE_IN_PROGRESS;
|
||||||
PlaySound(SOUND_CURSOR);
|
|
||||||
}
|
}
|
||||||
else if(needsErase)
|
else if(needsErase)
|
||||||
{
|
{
|
||||||
COMMON_LOGGER("Erase Trash\n");
|
COMMON_LOGGER("Erase Trash\n");
|
||||||
s_RestoreState = ERASE;
|
s_RestoreState = ERASE;
|
||||||
PlaySound(SOUND_CURSOR);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
COMMON_LOGGER("Start Import Data\n");
|
COMMON_LOGGER("Start Import Data\n");
|
||||||
s_RestoreState = RESTORE_TWL_SOUND;
|
s_RestoreState = RESTORE_TWL_SOUND;
|
||||||
PlaySound(SOUND_CURSOR);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -394,8 +405,8 @@ void ControlState(::std::vector<std::string>& operationMessage, bool& nextStep,
|
|||||||
// アップデート完了ファイルを作成
|
// アップデート完了ファイルを作成
|
||||||
CreateUpdateFinishedFile();
|
CreateUpdateFinishedFile();
|
||||||
|
|
||||||
// リブートする
|
s_RestoreState = UPDATE_DONE;
|
||||||
s_RestoreState = REBOOTING;
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -418,6 +429,26 @@ void ControlState(::std::vector<std::string>& operationMessage, bool& nextStep,
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
// アップデート完了
|
||||||
|
case UPDATE_DONE:
|
||||||
|
{
|
||||||
|
operationMessage.push_back(::std::string("Network Update Done."));
|
||||||
|
operationMessage.push_back(::std::string("Press A or START Button to Reboot"));
|
||||||
|
|
||||||
|
if(!s_PlayedRebootCursor)
|
||||||
|
{
|
||||||
|
PlaySound(SOUND_CURSOR);
|
||||||
|
s_PlayedRebootCursor = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (nextStep)
|
||||||
|
{
|
||||||
|
s_RestoreState = REBOOTING;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
|
|
||||||
// TWLサウンド領域の書き込み中
|
// TWLサウンド領域の書き込み中
|
||||||
case RESTORE_TWL_SOUND:
|
case RESTORE_TWL_SOUND:
|
||||||
{
|
{
|
||||||
@ -538,6 +569,12 @@ void ControlState(::std::vector<std::string>& operationMessage, bool& nextStep,
|
|||||||
operationMessage.push_back(::std::string("Restore Done."));
|
operationMessage.push_back(::std::string("Restore Done."));
|
||||||
operationMessage.push_back(::std::string("Press A or START Button to Reboot"));
|
operationMessage.push_back(::std::string("Press A or START Button to Reboot"));
|
||||||
|
|
||||||
|
if(!s_PlayedRebootCursor)
|
||||||
|
{
|
||||||
|
PlaySound(SOUND_CURSOR);
|
||||||
|
s_PlayedRebootCursor = true;
|
||||||
|
}
|
||||||
|
|
||||||
if (nextStep)
|
if (nextStep)
|
||||||
{
|
{
|
||||||
s_RestoreState = REBOOTING;
|
s_RestoreState = REBOOTING;
|
||||||
@ -609,6 +646,12 @@ void ControlState(::std::vector<std::string>& operationMessage, bool& nextStep,
|
|||||||
operationMessage.push_back(::std::string("ALL Done. Pull Out SD Card."));
|
operationMessage.push_back(::std::string("ALL Done. Pull Out SD Card."));
|
||||||
// SDカード抜けのみで次の状態に遷移する
|
// SDカード抜けのみで次の状態に遷移する
|
||||||
|
|
||||||
|
if (!s_PlayedSdPullOutCursor)
|
||||||
|
{
|
||||||
|
common::PlaySound(common::SOUND_CURSOR);
|
||||||
|
s_PlayedSdPullOutCursor = true;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -682,6 +725,9 @@ void InitializeState()
|
|||||||
s_PlayedFailSound = false;
|
s_PlayedFailSound = false;
|
||||||
s_ExecuteFgNup = false;
|
s_ExecuteFgNup = false;
|
||||||
s_FgNupRetryCount = 0;
|
s_FgNupRetryCount = 0;
|
||||||
|
s_PlayedStartCursor = false;
|
||||||
|
s_PlayedRebootCursor = false;
|
||||||
|
s_PlayedSdPullOutCursor = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
u32 GetProgress()
|
u32 GetProgress()
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user