Japanese
INDEX ▲ | STN-6 | STN-9 | STN-18 | STN-19 | STN-21 | STN-22 | STN-23

STN-19

How to initialize CD block when using GFS


 issue number:
STN-19
 date of issue:
95/01/20
 media:
○Common ●CD-ROM ○Cartridge ○Others
 connection:
●Program ○Hard ○Manual ○Tools ○Game ○ Bug ○Others
 Information distinction:
○New ●Change ○Addition
 importance:
●Strict observance ○Recommended ○Reference ○Others
 attached file:
●No ○ Yes
 Subject supplement:
Target library: GFS Ver1.13 or later

Contents

The file system initialization function GFS_Init() executes the CD block initialization function CDC_CdInit() to set the ECC/retry count to the maximum value. The specific settings are as follows.

CDC_CdInit(0,0,5,0x0f);
Initialization flag: Default value
Standby time: Default value
ECC number: 5 times
number of retries: 15 times

If you want to change these settings when using GFS, execute the CDC_CdInit function after calling GFS_Init.
It is also possible to specify without changing the settings, so you can change only the desired parameters.

■Sample program

	#include "sega_gfs.h"

	#define STNBY 90 /*Standby time: 90 seconds*/
	#define NOCHG -1 /*Unchanged specification*/

	Sint32 sampleInit(void)
	{
		Sint32 ret;

	/*File system initialization*/
	ret = SGF_Init(......);
	if (ret < 0){
		return NG;
	}

	/*Change standby time (others remain unchanged)*/
	ret = CDC_CdInit(NOCHG, STNBY, NOCHG);
	if (ret! = CDC_ERR_OK) {
		return NG;
	}
	return OK;
that's all
INDEX ▲ | STN-6 | STN-9 | STN-18 | STN-19 | STN-21 | STN-22 | STN-23
Copyright SEGA ENTERPRISES, LTD., 1997