Read TOC problem with the USB drive emulating like a CD-ROM drive(in MAC system)

Joined
Jun 25, 2009
Messages
3
Reaction score
0
Points
1
Hello,

I am trying to emulate a USB drive to appear like a CD-ROM drive. I used a tool to generate an ISO image. Then I dump the image to a usb drive, setting the drive as CDROM type by SCSI command . All the host(Windows,Linux,MAC) will also sends Read TOC command to get the TOC data. Since I emulate the USB device as CDROM drive, I just emulate it as single track.

Here is the discuss thread I refer to :
Read TOC problem with USB flash drive emulating optical drive - Club MyCE / CDFreaks - Knowledge is Power

And below is the data I respond to a Read Toc command(all Hex)

The command to the drive:
43 00 00 00 00 00 00 03 24 00

Data returned by the drive (with comments):
00 12 (number of bytes below = 18 decimal)
01 (first track)
01 (last track)
00 (reserved)
14 (adr, control)
01 (track being described)
00 (reserved)
00 00 00 00 (start logical block address 0X00)
00 (reserved)
14 (adr, control)
AA (track being described (leadout))
00 (reserved)
00 00 0C 6C (lead oout start logical block address 0xC6C)

This works fine in both Windows and Linux system, but can't be mounted in MAC system. :Grimmace:

At the same time , I get a USB device which could be emulated as CDROM in MAC system. I get the data back from the USB analyzer and see its response data is as followed (MSF is 1):
00 2E (TOC data length)
01 (First track number)
01 (Last track number)
01 16 00 A0 00 00 00 00 (TOC track descriptor ?)
01 00 00 01 16 00 A1 00 (TOC track descriptor ?)
00 00 00 01 00 00 01 16 (TOC track descriptor ?)
00 A2 00 00 00 00 03 14 (TOC track descriptor ?)
34 01 14 00 01 00 00 00 (TOC track descriptor ?)
00 00 02 00 (?)

Till now I have no clue about its meaning.Morever amazingly, I used this TOC data for my ISO image and MAC system could recognize it !!

Is there any special meaning in this TOC data ? Do anyone knows the meaning of this set of TOC (I can't parse its meaning from MMC-6).

Thanks in advance.
 
OP
C
Joined
Jun 25, 2009
Messages
3
Reaction score
0
Points
1
sorry , I just notice that the command from MAC system is :
43 02 00 00 00 00 00 FF FE 80
which is different to from Windows :
43 02 00 00 00 00 00 03 24 00

The 7th and 8th bytes means the allocation Length , so it's normal that different system issue different value.
But the last byte (which means control byte) in MAC is 0x80 and in Windows is 0x00 .
MMC-6 does not define this byte . But SFF-8090 defines the highest 2 bit of this byte as vendor specific . Any one knows what does MAC require from this ? And What is the diffent between them(0x00 and 0x80) ?

TIA.
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top