Hello guest,
default
To benefit from all extra features you need to log in or sign up.
Optical Storage Technical Discussions Discuss, DVD+RW formatting problem at Computer Hardware forum; Dear forum members, I'm writing my own CD/DVD recording software and have encountered a problem when formatting blank (that is, factory new) DVD+RW media. I send the FORMAT UNIT packet with format type 26h to the ATAPI burner. The packet is: 04 11 00 00 00 00 00 00 00

Old Posted: 01-09-2006
default_avatar
konstantinkoll (New on Forum)
Posts: 17
  • Find More Posts by konstantinkoll
Dear forum members,

I'm writing my own CD/DVD recording software and have encountered a problem when formatting blank (that is, factory new) DVD+RW media. I send the FORMAT UNIT packet with format type 26h to the ATAPI burner. The packet is: 04 11 00 00 00 00 00 00 00 00 00 00 - 00 00 00 08 FF FF FF FF 98 00 00 00

On my cheap Samsing SH-S162L, I get the sense code 02 62 20, but the drive starts formatting the media. I get "unit ready" after approx. 2 minutes, and can then either wait or begin writing sectors.

On my LG GSA-4167B, I also get sense code 02 62 20, but sometimes also 04 F4 00. In either case, the medium is NOT formatted, and subsequent writes return error codes due to unformatted media.

Can you see a mistake, esp. in the packet? Thank you very much for your answers!
default_avatar
Today (MyCE Staff)
Posts: 15,596
Old Posted: 06-09-2006
default_avatar
bifmud (CD Freaks Junior Member)
Posts: 71
  • Find More Posts by bifmud
Curious ...
What are these sense codes (sk/asc/ascq) 2/62/20 & 04 F4 00 ? I don't recognize them and can't find them anywhere. What do they mean ?

Your cdb looks OK and as best I can tell your parameter list looks good for a "fresh-out-of-the-box" DVD+RW. Some would set the Immed bit. But it depends on how you have everything else set up. Either way it should work if you don't interupt it.

The problem may be if you try a write command or any command that accesses the media before formatting is complete, some units may terminate the formatting with Check Condition. Maybe your SH-S162L firmware has saftey features that ignore any attempt to access the media until (de-icing) formatting is complete but your
LG GSA-4167B doesn't ? There are lots of poor firmware out there. Not to say that unit has one. It's updated of course ?

Does your routine wait until you no longer get sk/asc/ascq 2/4/4 (Format In Progress) ? After do you send a Read Disc Information command to get BG Format Status ? If you get zero de-icing failed or was stopped. If BG is in progress do you call stop de-icing (Close Function 0) for safety ? and call close session (Close Function 2) to stop
the BG ?

I think your settings for the "Number of Blocks" is asking for the entire formattable capacity. This would basically format the entire disc.That takes a long time. It might be better to use a smaller (much) value? This might also somehow be contributing to the problem with your LG GSA-4167B although technically, if you are waiting for completion correctly, it shouldn't. Most good units will automatically startup BG to accomodate images larger than the currently formatted space. You do not have to do all the BG formatting on a "fresh-out-of-the-box" in one go. But stopping the BG and starting it up again is the your job.

If you haven't checked out Andy Polyakov's growisofs, download it and look through the unit "dvd+rw-format.cpp". I'll do the same (again). We can compare notes. If you fix your problem be sure to post the solution.

Regards,

Bill Mudd
Old Posted: 07-09-2006
default_avatar
konstantinkoll (New on Forum)
Posts: 17
  • Find More Posts by konstantinkoll
Thank you for your answer. My LG-4167B has the latest firmware (DL13). The problem is that formatting never starts. After the format command (regardless of sector count, be it 0x1000 or 0xFFFFFFFF) the unit waits for approx. 4 seconds (without LED blinking), and no formatting takes place, according to GetDiscInfo and to a visual inspection of the surface. Here you see the source of the formatting procedure:

Code:
function FormatDVDPlusRW(Dev: PIDEDevice; DeIceWait: Boolean): Boolean;
var
  Data: RequestSensePage;
  St: String[12];
  Ready: Boolean;
begin
  FormatDVDPlusRW:=False;
{Basic format}
  St:=#0#2#0#8#$FF#$FF#$FF#$FF#$98#0#0#0;
    if DataPacket(Dev^.MasterSlave,pckFormatDVD,6,$FFFF,St[1],dataOut)<>6 then exit;
    repeat begin
    Ready:=not Busy;
      if Ready=True then Ready:=UnitReady(Dev);
    end until Ready=True;
{De-ice anhalten}
  St:=pckCloseSession; St[2]:=#1; St[3]:=#2;
  SendPacket(Dev^.MasterSlave,St,0);
    repeat begin
    Ready:=not Busy;
      if Ready=True then Ready:=UnitReady(Dev);
    end until Ready=True;
  FormatDVDPlusRW:=True;
end;
Old Posted: 07-09-2006
default_avatar
bifmud (CD Freaks Junior Member)
Posts: 71
  • Find More Posts by bifmud
Hi konstantinkoll,

The packet you are sending should work. I see you changed it so now the Immed bit is set. Good. That eliminates one potential problem. I will assume the code in your FormatDVDPlusRW function is good because it works for your SH-S162L.

What do you do before calling the format function ? I would use Get Performance & Set Streaming to get & set the speed, flush the cache (Synchronize Cache command with start LBA = 0 & number of blocks = FFFFh) and use Send OPC Information to have the device set its defaults (set DoOPC with everything else unset). See if that gets it to work.

Is pckCloseSession; St[2]:=#1; St[3]:=#2 equal to Close Track/Rzone with Close Function 2 ?

Also some drives can be very fussy about media quality. Don't use cheapies. Try a Verbatim.

I'm out of ideas for now. Let me know what happens.
It's good to see someone else coding in Delphi pascal. Not too many of us around.

Bill
Old Posted: 08-09-2006
default_avatar
konstantinkoll (New on Forum)
Posts: 17
  • Find More Posts by konstantinkoll
Ok, lets start with the obvious:

- I also assume that the basic format command is ok since it works on the Samsung recorder.
- Yes, I use Verbatim media all the time since they have got an outstanding reputation. Just in case, I've also bought some (cheap) Platinum DVD+R/W. It's the same regardless of meda: Nero Burning ROM formats them, my software doesn't.
- I usually set speed to 0xFFFF for maximum blank performance. Changing this to other values (e.g. 1385 for single speed) doesn't do anything.
- Synchronizing the cache doesn't help either.
- If I perform an OPC, the drive lights up for calibration, but again stops when the FORMAT UNIT is sent.
- The patch of pckCloseTrackSession is ugly code since it's under construction. It stops the Deiceing of the media to quit formatting as soon as possible. When the actual recording starts, formatting is started again by the drive as needed.

I have the following ideas left:
- growisofs mentions a formatting bug on a LG-4163B. I've already asked the maintainer for more specific information, but did not get an answer yet.
- Intercept the commands from Nero. I have tried to use tools like ASPISpy, but they just let Nero crash before logging anything useful. Someone (you?) who can get such a tools working might be able to help out here.
- Ask the support team of LG (a last resort).
Old Posted: 09-09-2006
default_avatar
bifmud (CD Freaks Junior Member)
Posts: 71
  • Find More Posts by bifmud
OK so it comes down to the command itself. Your LG-4163B is not recognizing or accepting it.

Here is what I use for brand new DVD+RW never been formatted. It works everytime and I just now used it on 2 different DVD devices.

format parameter list
0 1 2 3 4 5 6 7 8 9 10 11
00 02 00 08 FF FF FF FF 98 00 00 00 // I use a smaller value for 4-7
// but it makes no difference
cdb
0 1 2 3 4 5
04 11 00 00 00 00

The cdb packet string in your 1st post shows a 12 byte cdb ? Format has only a 6 byte cdb. If this is the case change it to 6 and see what happens.

Re: growisofs
Yes I see this too. Not surprisingly he includes Pioneer with the LG as having a problem with DVD+RWs in getting & setting the speed with Get Performance/Set Streaming. If these fail, fall back to 2A and Set Speed. This is also true for CDs on legacy units. I am not aware of LGs having a problem with the format command itself. I do not see this mentioned in my copy of the growisofs code. Maybe search > CDFreaks Forum > Optical Drives Forum > LG DVD Burner with "format".
Old Posted: 09-09-2006
default_avatar
bifmud (CD Freaks Junior Member)
Posts: 71
  • Find More Posts by bifmud
I just had a hunch based on your comment "the unit waits for approx. 4 seconds
(without LED blinking), and no formatting takes place, ..."

After de-icing, BG formatting takes place "trasparently". In some units, like my Pioneer,
this means there is no LED is blinking or anything else. I seems like nothing is happening
but it is. If you sent a request sense you would get a 2/4/4 "Format In Progress" return.

You have to wait until it is finished doing a BG on your "number of blocks" which is why
(learning from growisofs and others) I use a small value for that parameter. Formatting
may be working fine on your LG-4163B but you are interrupting it ?

"The patch of pckCloseTrackSession is ugly code since it's under construction. It stops the Deiceing of the media to quit formatting as soon as possible."
Take this out and replace it with a function 2 Close Track/Rzone.
Old Posted: 13-09-2006
default_avatar
konstantinkoll (New on Forum)
Posts: 17
  • Find More Posts by konstantinkoll
First of all, sorry for not having answered you in the past few days.


Quote:
The cdb packet string in your 1st post shows a 12 byte cdb ? Format has only a 6 byte cdb. If this is the case change it to 6 and see what happens.
Right, it's 6 byte. But since ATAPI is used as transport layer, all commands (e.g. WRITE 10) have to be padded to 12 byte. I've tried sending 6 byte only, surprisingly not locking up the EIDE controller, but also not getting the DVD formatted.


Quote:
Re: growisofs
Yes I see this too. Not surprisingly he includes Pioneer with the LG as having a problem with DVD+RWs in getting & setting the speed with Get Performance/Set Streaming. If these fail, fall back to 2A and Set Speed. This is also true for CDs on legacy units.
I use SetSpeed with 0xFFFF for reading and writing to get a CD-R/W oder DVD-R/W blanked at maximum speed. I've set the speed to 1385 (decimal) for single DVD speed - no success.


Quote:
I just had a hunch based on your comment "the unit waits for approx. 4 seconds
(without LED blinking), and no formatting takes place, ..."
After de-icing, BG formatting takes place "trasparently". In some units, like my Pioneer,
this means there is no LED is blinking or anything else. I seems like nothing is happening
but it is.
I've thought about that, too. But after visually inspecing the disc surface, it still looks virgin (no dark ring).


Quote:
You have to wait until it is finished doing a BG on your "number of blocks" which is why (learning from growisofs and others) I use a small value for that parameter. Formatting
may be working fine on your LG-4167B but you are interrupting it ?
I've put a readln; in between and waited for 10 minutes before hitting Enter. Nothing.
Old Posted: 14-09-2006
default_avatar
willmore (MyCE Member)
Posts: 210
  • Find More Posts by willmore
Knowing practically nothing of what you're taking about, but following along as it's very interesting, I'd like to ask one thing. When you se the speed to 1385, is it for a media that supports 1x writing on that drive? I don't know your drive, but some of the Lite-ON drives that I use only support, maybe, 4x on some newer media. I'm probably way off base, but I thought I'd at least try to help.
Old Posted: 16-09-2006
default_avatar
konstantinkoll (New on Forum)
Posts: 17
  • Find More Posts by konstantinkoll
Well, any ideas are more than welcome!

When the speed for reading or writing is set to an illegal value (e.g. 1385 for media that can be recorded with 4x speed only), it's the task of the drive to correct these values. That is why 0xFFFF will always result in the right maximum speed.

Just to be sure, I've tried 1385*4 as speed since the disc has got "4x" printed on its surface in a large font. And, no, it doesn't work :-(
Old Posted: 17-09-2006
default_avatar
bifmud (CD Freaks Junior Member)
Posts: 71
  • Find More Posts by bifmud
Use some burner software like Nero or whatever (growisoft or cdrecord is good too)
to format a DVD+RW on the LG. I'm sure it will work but test it anyway.

Then try another format type with your format routine on the LG. Types 00h (Full CD-RW) & 15h (DVD-RW Quick) are both easy to implement.

BillM
Old Posted: 17-09-2006
default_avatar
konstantinkoll (New on Forum)
Posts: 17
  • Find More Posts by konstantinkoll
Now that was a very good idea! Guess what: I can't format a CD-R/W either ! It's just the same as formatting a DVD+R/W, basically nothing happens. There must be something very fishy going on here...
Old Posted: 20-09-2006
default_avatar
konstantinkoll (New on Forum)
Posts: 17
  • Find More Posts by konstantinkoll
Hi folks,

the situation gets even stranger: if I insert an already formatted DVD+R/W into the drive, I can reformat it without any problem. The drive light flashes for approx. 10 seconds.
Old Posted: 22-09-2006
default_avatar
bifmud (CD Freaks Junior Member)
Posts: 71
  • Find More Posts by bifmud
If your format routine works on the SH but not the LG and commercial burner programs can format on the LG then you still have some debugging to do on your routine.

To mention it again maybe because it caused me many problems ... you absolutely have to wait until the formatting is complete. This means your sense returns have to be
accurate and you must have a wait routine. I start a Repeat/Until loop immediately after my call to the format command ...

Repeat
TestReady;
Until (sense return <> Format In Progress);

This ensures the next line of code can't be executed until it's done. Then any calls to close session or whatever can occurr.

If you are already doing this all I can say is keep slogging. You'll get it. After that you'll be able to do it in your sleep

regards,

BillM
Old Posted: 29-09-2006
default_avatar
steve b (CDFreaks Resident)
Posts: 562
  • Find More Posts by steve b
The symptom you have is interesting. I had the same exact problem. I had my DVD burner plugged into a Promise SATA/IDE controller PCI card. The DVD burner worked well. The only thing I couldn't do is format a new DVD+RW. Everything else worked. Just like you, I could format a DVD+RW that had already been formatted.

My fix was to plug my burner directly into my motherboard. Promise says this controller is only for hard drives. Strangely though, it handled my DVD burner perfectly except it wouldn't format a new DVD+RW disc. I didn't try a DVD-RW.
Old Posted: 01-10-2006
default_avatar
kondra (New on Forum)
Posts: 6
  • Find More Posts by kondra
Maybe you should use bushound to see what Nero does? On this way you know that the cdb is correct. Also see if they do different things on the two different burners.
There's more to MyCE.com

Listen up, we've got more. Product information on 107,830 products. Our experts have written 523 articles. We've gathered 16,131 news items for you to always keep updated.

Active Commenters

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

People who found this also searched for

  • dvd+rw-format not recognize dvd rw
  • set streaming
  • 0xffff
  • 5 30 10 medium not formatted help dvdrw
  • blank dvd-rw format
  • cmd dvd rw format
  • dvd format problems
  • dvd formatting problem
  • dvd recorder reviews dvr670ku
  • dvd rw de format sorunu
  • dvd rw format problems
  • dvd rw formatieren probleme
  • dvd rw gets smaller after format
  • dvd+rw format problem
  • dvd+rw formatfehler
  • dvd+rw-format -blank=full illegal command-line option for this media
  • dvd+rw-format exits without format
  • dvd+rw-format illegal command-line option for this media blank
  • dvd+rw-format user parameters
  • dvd-rw format problem
  • dvd-rw format tool
  • dvd-rw formatter
  • dvd-rw formatting tools
  • dvr670ku problems
  • factory format dvd rw
  • format dvd rw problem
  • format dvd rw tool
  • format dvd+rw problem
  • formatting problem dvds
  • growisofs -z dev dvd= dev zero
  • growisofs -z dev zero failed
  • growisofs stop de-icing failed
  • growisofs stop de-icing faled
  • growisoft how to
  • infrarecorder probleme format dvd-rw
  • probleem formatteren dvd+rw download
  • problem dvd rw formatering
  • problem formatting dvd rw
  • problems formating dvd+rw
  • problems formatting dvd dvr670ku
  • problems formatting dvd+rw
  • tevion dvd+rw format problem
All times are GMT +2. The time now is 06:55.
Top