cdrom3/3

ZXNet echo conference «hardware.zx»

From Boris Sokol To All 13 November 1999

Hello, All! (file: cd3.txt)───────────── Appendix A Drive Status Codes (taken from CD driver in Linux) /* first byte */ char *sense_key_texts[16] = { 0 "No sense data", 1 "Recovered error", 2 "Not ready" 3 "Medium error", 4 "Hardware error", 5 "Illegal request", 6 "Unit attention", 7 "Data protect" 8 "(reserved)", 9 "(reserved)", a "(reserved)", b "Aborted command", c "(reserved)", d "(reserved)", e "Miscompare", f "(reserved)", }; /* second and third bytes */ struct { short asc_ascq; char *text; } sense_data_texts[] = { { 0x0000, "No additional sense information" }, { 0x0011, "Audio play operation in progress" }, { 0x0012, "Audio play operation paused" }, { 0x0013, "Audio play operation successfully completed" }, { 0x0014, "Audio play operation stopped due to error" }, { 0x0015, "No current audio status to return" }, { 0x0200, "No seek complete" }, { 0x0400, "Logical unit not ready - cause not reportable" }, { 0x0401, "Logical unit not ready - in progress (sic) of becoming ready" }, { 0x0402, "Logical unit not ready - initializing command required" }, { 0x0403, "Logical unit not ready - manual intervention required" }, { 0x0600, "No reference position found" }, { 0x0900, "Track following error" }, { 0x0901, "Tracking servo failure" }, { 0x0902, "Focus servo failure" }, { 0x0903, "Spindle servo failure" }, { 0x1100, "Unrecovered read error" }, { 0x1106, "CIRC unrecovered error" }, { 0x1500, "Random positioning error" }, { 0x1501, "Mechanical positioning error" }, { 0x1502, "Positioning error detected by read of medium" }, { 0x1700, "Recovered data with no error correction applied" }, { 0x1701, "Recovered data with retries" }, { 0x1702, "Recovered data with positive head offset" }, { 0x1703, "Recovered data with negative head offset" }, { 0x1704, "Recovered data with retries and/or CIRC applied" }, { 0x1705, "Recovered data using previous sector ID" }, { 0x1800, "Recovered data with error correction applied" }, { 0x1801, "Recovered data with error correction and retries applied" }, { 0x1802, "Recovered data - the data was auto-reallocated" }, { 0x1803, "Recovered data with CIRC" }, { 0x1804, "Recovered data with L-EC" }, { 0x1805, "Recovered data - recommend reassignment" }, { 0x1806, "Recovered data - recommend rewrite" }, { 0x1a00, "Parameter list length error" }, { 0x2000, "Invalid command operation code" }, { 0x2100, "Logical block address out of range" }, { 0x2400, "Invalid field in command packet" }, { 0x2600, "Invalid field in parameter list" }, { 0x2601, "Parameter not supported" }, { 0x2602, "Parameter value invalid" }, { 0x2603, "Threshold parameters not supported" }, { 0x2800, "Not ready to ready transition, medium may have changed" }, { 0x2900, "Power on, reset or bus device reset occurred" }, { 0x2a00, "Parameters changed" }, { 0x2a01, "Mode parameters changed" }, { 0x3000, "Incompatible medium installed" }, { 0x3001, "Cannot read medium - unknown format" }, { 0x3002, "Cannot read medium - incompatible format" }, { 0x3700, "Rounded parameter" }, { 0x3900, "Saving parameters not supported" }, { 0x3a00, "Medium not present" }, { 0x3f00, "ATAPI CD-ROM drive operating conditions have changed" }, { 0x3f01, "Microcode has been changed" }, { 0x3f02, "Changed operating definition" }, { 0x3f03, "Inquiry data has changed" }, { 0x4000, "Diagnostic failure on component (ASCQ)" }, { 0x4400, "Internal ATAPI CD-ROM drive failure" }, { 0x4e00, "Overlapped commands attempted" }, { 0x5300, "Media load or eject failed" }, { 0x5302, "Medium removal prevented" }, { 0x5700, "Unable to recover table of contents" }, { 0x5a00, "Operator request or state change input (unspecified)" }, { 0x5a01, "Operator medium removal request" }, { 0x5b00, "Threshold condition met" }, { 0x5c00, "Status change" }, { 0x6300, "End of user area encountered on this track" }, { 0x6400, "Illegal mode for this track" }, { 0xbf00, "Loss of streaming" }, Appendix B Some sector formats (Taken from Linux) ┌───────────────────────────────┬─── ─────────────────┬──────────────────┐ │ Audio disc (red book): │ audio_sample_bytes │ │ │ │ 2352 │ │ ├───────────────────────────────┼─── ───┬──────┬──────┼─────┬──────┬─────┤ │ Data (yellow, mode 1): │ sync │ head │ data │ EDC │ zero │ ECC │ │ │ 12 │ 4 │ 2048 │ 4 │ 8 │ 276 │ ├───────────────────────────────┼─── ───┼──────┼──────┼─────┴──────┴─────┤ │ Data (yellow, mode2): │ sync │ head │ data │ │ │ │ 12 │ 4 │ 2336 │ │ ├───────────────────────────────┼─── ───┼──────┼──────┼──────┬─────┬─────┤ │ XA data (green, │ │ │ │ │ │ │ │ mode2 form1): │ sync │ head │ sub │ data │ EDC │ ECC │ │ │ 12 │ 4 │ 8 │ 2048 │ 4 │ 276 │ ├───────────────────────────────┼─── ───┼──────┼──────┼──────┼─────┼─────┤ │ XA data (green, │ │ │ │ │ │ │ │ mode2 form2): │ sync │ head │ sub │ data │ EDC │ ││ │ 12 │ 4 │ 8 │ 2324 │ 4 │ │ └───────────────────────────────┴─── ───┴──────┴──────┴──────┴─────┴─────┘ ######################################################################### PS/ Initially, this document was compiled exclusively for internal use due to the inability to find a company description ATAPI-CD standard. Since all information was taken from disassembled drivers, Linux source codes and disassembled ACER665 firmware, Certain discrepancies with the standard are quite possible. Despite it seems to me that even such a description represents a certain value. An incomplete description is better than no description at all. I still have some information left, for example, CD driver texts, firmware, etc., which were considered unimportant. If necessary, You can insert excerpts from the drivers into this document. Revisions: 08/10/1996 - fragmentary data was collected and somehow systematized 09/19/1996 - for the first time he was given over to be torn to pieces. Suggestions, comments, swearing, etc. please send to 2:5030/163.44 Konstantin Norvatoff, KonNor You can also try to find me at: konnor@small.spb.su (file: cd3.txt)───────────── Boris.