I looked over the changes proposed by Thomas Schmitt in April regarding the extraction of ISRC and MCN data via the READ SUB-CHANNEL command.
I think that most of the changes are a great improvement, including: - clearing the buffer before issuing the command - not relying on the terminating 0 in the returned data - interpreting the TCVAL and TCVAL bits in the returned data - interpreting the length. Nevertheless, I do not see the point in issuing the command twice - first to query the length. While the spec (MMC-4 [1]) allows the device to return less than the requested data, the data structure has fixed length. It is _not_, like for instance for CD-Text, a blob of variable length. It might very well be, that the device encounters a read error and returns less than the requested length. In that case, we do not gain anything though, because we simply abort after the first call. If the data is available, we can get it in the first call. If it is not, the first call tells us that and we abort. Based on this reasoning I would suggest to always request the full data structure (24 bytes). Based on the length field, we can detect whether the returned data includes the ISRC or MCN. Best regards Leon [1] http://www.13thmonkey.org/documentation/SCSI/mmc4r05a.pdf
