INDEX ▲ | STN-6 | STN-9 | STN-19 | STN-21 | STN-22 | STN-23 | STN-24

STN-21

Recovery of GFS_Init, GFS_LoadDir functions


 issue number:
STN-21
 date of issue:
95/01/20
 media:
○ Communication ● CD-ROM ○ Cartridge ○ Other
 connection:
● Program ○ Hard ○ Manual ○ Tools ○ Game ○ Bug ○ Other
 Information distinction:
● New regulations ○ Change ○ Addition
 importance:
● Strict adherence ○ Recommendation ○ Reference ○ Other
 Attachment:
● None ○ Yes
 Subject supplement:
Target library: GFS Ver1.15

Contents

■ Countermeasures

If an error occurs in the GFS_Init and GFS_LoadDir functions, take the following actions.

● In case of GFS_ERR_CDRD, GFS_ERR_FATAL error
GFS_Init sets the maximum number of ECC / read retries to avoid the <ERROR> state as much as possible. again, When the status is reached, a stop command (seek to the home position) is issued for recovery.
□ If these errors occur, wait for the pause command to enter the "PAUSE" state as shown in the attached program example, and then re-execute. The number of repetitions of re-execution should be 3 or more.
□ If an error occurs even after repeated execution, it is possible that the disk is irreparably scratched. Display a message or switch to multiplayer.

● In case of GFS_ERR_CDNODISC, GFS_ERR_CDOPEN error
Please move to multiplayer.

● For other errors
This is an error that should not occur. Please review the program.
There is a possibility of a GFS library or hardware failure, so please contact us if you do not understand the cause.
In the product version, there is no choice but to move to multiplayer.

■ Sample program


#include "sega_cdc.h"
Sint32 recocGfsInit (void);
Sint32 waitStat (Sint32sts);

/ * GFS_Init, GFS_LoadDir return processing * /
Sint32 revovGfsInit (void)
{
	Sint32 ret;
	CdcPos pos;
	/ * Issue a pause command * /
	CDC_POS_PTYPE (& pos) = CDC_PTYPE_NOCHG;
	ret = CDC_CdSeek (& pos);
	if (ret! = CDC_ERR_OK) {
		return NG;
	}
	/ * Wait until "PAUSE" state * /
	ret = waitStat (CDC_ST_PAUSE);
	return ret;
}
/ * Wait until the specified drive status is reached * /
Sint32 waitStat (Sint32 sts)
{
	Sint32 ret;
	Sint32 stwk;
	CdcStat stat;

	while (TRUE) {/ * Actually, the upper limit of the number of loops is required * /
		/ * Get regular response * /
		ret = CDC_GetPeriStat (& stat);
		if (ret == CDC_ERR_PERI) {
			continue; continue;
		}
		if (ret! = CDC_ERR_OK) {
			return NG;
		}
		stwk = CDC_GET_STC (& stat);
		if (stwk == sts) {
			brake;
		}
	}
	return OK;
}
that's all
INDEX ▲ | STN-6 | STN-9 | STN-19 | STN-21 | STN-22 | STN-23 | STN-24
Copyright SEGA ENTERPRISES, LTD., 1997