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

Re: Detect CD Media Type?



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

It is not dangerous, though, to blank a blanked CD-RW again.


I got no experience with appendable CD-R. (For the purpose of a safe
backup the issue of appending data to CDs is rather counterproductive.)
Maybe you can find a difference in the -atip output :
  ... burn CD and leave session open ...
  cdrecord -atip dev=... >$HOME/atip_session_open
  ... burn same CD again and close session ...
  cdrecord -atip dev=... >$HOME/atip_session_closed
  diff $HOME/atip_session_open $HOME/atip_session_closed


>Oh...I forget to ask another question....the info in atip do not include the 
>write speed about media, right?

If i only knew.
There are some lines about speed in some -atip output. No idea
wether they are trustworthy and what they actually mean.

In general cdrecord is able to find a suitable speed on its own.
When in doubt, set the maximum speed of your drive. If i give
speed=10 and insert a 4x CD-RW then it gets written with speed 4.
(There is a force option but i can hardly see a good reason to use it.)


Have a nice day :)

Thomas



Reply to: