[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Detect CD Media Type?



scdbackup@gmx.net wrote:

> Hi,
> >
> > Now I can detect CD-R, CD-RW very well by -atip
> >but are there information about the CD-R is closed, or it's blank, can write 
> >or not?
> >I look and look...but can't find any info about that in -atip
>
> I just compared a used CD-R with an unused one (Platinum cheapos).
> There is no difference in the -atip output.
> Same with blank/non-blank CD-RW.
> I can distinguish them by this shell code snippet which does a 1 byte
> test read :
>   if dd if=/dev/sr0 of=/dev/null bs=1 count=1
>   then 
>     echo "Has data"
>   else 
>     echo "Seems to be empty"
>   fi

This does not work correctly in all cases.

Use the "official" way and call readcd sectors=0-0

Jörg

-- 
 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.fraunhofer.de	(work) chars I am J"org Schilling
 URL:  http://www.fokus.fraunhofer.de/usr/schilling ftp://ftp.berlios.de/pub/schily



Reply to: