Здравствуйте, MegaMonster, Вы писали:
хъ
MM>Разобраться самому не получается (как из них вытащить информацию?).
Данные даны по состоянию INF-8090i Rev 5.1
enum format_codes
{
format_TOC = 0x00, /* Returned data - TOC, Track/Session field contains the track number */
format_session_info = 0x01, /* Returned data - Session Information, Track/Session field is reserved */
format_full_TOC = 0x02, /* Returned data - Full TOC, Track/Session field contains Session number */
format_PMA = 0x03, /* Returned data - PMA, Track/Session field is reserved */
format_ATIP = 0x04, /* Returned data - ATIP, Track/Session field is reserved */
format_CDText = 0x05 /* Returned data - CD-Text, Track/Session field contains Session number */
};
struct atip_A1_data
{
unsigned char rec_speed_hight : 4; /* Highest Usable CLV Recording Speed
000b - Reserved
001b - 2X
010b - 4X
011b - 6X
100b - 8X
101b..111b - Refer to Orange Book
*/
unsigned char rec_speed_low : 3; /* Lowest Usable CLV Recording Speed
000b - Reserved
001b - 2X
010b..111b - Refer to Orange Book
*/
unsigned char res1 : 1; /* Must be set to zero */
unsigned char res2 : 1;
unsigned char MPF_value : 3; /* Device value of the Modulation/Power function */
unsigned char power_factor : 3; /* Power Multiplication Factor r */
unsigned char res3 : 1; /* Must be set to zero */
unsigned char res4 : 4;
unsigned char power_ratio : 3; /* Recommended Erase/Write Power Ratio (Pe0/We0) */
unsigned char res5 : 1;
};
struct atip_info
{
unsigned char data_length[2]; /* The number of bytes to be transferred in response to the command. */
unsigned char res1;
unsigned char res2;
unsigned char reference_speed : 3; /* Encoded information indicating the recommended write speed for the media.
00h = reserved.
01h - 2X recording.
Valid only for CD-RW media. */
unsigned char res3 : 1;
unsigned char indicative_DWP : 3; /* Encoded information indicating the media’s recommended initial laser power
setting. The meaning of these bits varies between CD-R and CD-RW media. */
unsigned char res4 : 1; /* Must be set to one */
unsigned char res5 : 6;
unsigned char URU : 1; /* Unrestricted Use Disc (URU) flag
1 - indicates that the mounted CD-R/RW disc is defined for unrestricted use.
0 - the mounted CD-R/RW disc is defined for restricted use.
*/
unsigned char res6 : 1; /* Must be set to zero */
unsigned char valid_A3 : 1; /* 1 - A3 field is valid. */
unsigned char valid_A2 : 1; /* 1 - A2 field is valid. */
unsigned char valid_A1 : 1; /* 1 - A1 field is valid. */
unsigned char disk_subtype : 3; /* Reports the following value according to the Orange Book Part 2 or Part 3 (B1,B2,B3).
000b - Normal Rewritable (CLV) Media
001b - High speed Rewritable (CLV/CAV) Media
010b - Medium type A, low Beta category (A-)
011b - Medium type A, high Beta category (A+)
100b - Medium type B, low Beta category (B-)
101b - Medium type B, high Beta category (B+)
110b - Medium type C, low Beta category (C-)
111b - Medium type C, high Beta category (C+)
*/
unsigned char disk_type : 1; /* 0 - CD-R, 1 - CD-RW */
unsigned char res7 : 1; /* Must be set to one */
unsigned char res8;
/* The start time of the lead-in. The value is read from ATIP and returned in hex format.
Legal values for the M field are 50h through 63h. */
unsigned char leadin_start_time_M; /* ... (Min.). */
unsigned char leadin_start_time_S; /* ... (Sec.) */
unsigned char leadin_start_time_F; /* ... (Frame.) */
unsigned char res9;
/* The last possible start time of lead-out. The value is read from ATIP and returned in hex format.
Valid values for the M field are 0 through 4Fh. */
unsigned char leadout_start_time_M; /* ... (Min.) */
unsigned char leadout_start_time_S; /* ... (Sec.) */
unsigned char leadout_start_time_F; /* ... (Frame.) */
unsigned char res10;
atip_A1_data A1_value;
unsigned char res11;
unsigned char A2_value[3]; /* Reserved */
unsigned char res12;
unsigned char A3_value[3]; /* Reserved */
unsigned char res13;
};