#1 Burning Software

It is currently Wed Dec 18, 2024 8:23 pm

All times are UTC




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: Setting the Drive-Speeds
PostPosted: Thu Jul 08, 2004 4:21 pm 
Offline

Joined: Thu Jul 08, 2004 8:25 am
Posts: 51
Location: Germany
Hi again.
I'm having trouble setting a DVD-ROM's Read-Speed.
The situation:
DVD-Drive: LG/DVD-ROM DRD8160B/1.00 (Vendor/ProductID/Revision)

I can create the object and get device-information via:
StarBurn_CdvdBurnerGrabber_GetDeviceInformation,
StarBurn_GetDeviceNameByDeviceAddress,
StarBurn_CdvdBurnerGrabber_GetSupportedMediaFormats and
StarBurn_CdvdBurnerGrabber_GetSupportedMediaFormatsEx.
After the call to these functions, all Read-Values are true/all Write-Values are false (naturally)

The call to StarBurn_CdvdBurnerGrabber_GetSpeeds is also successfull (EN_SUCCESS), but the returned values are:
MaxRead = 8448 (OK)
CurRead = 0 !!!! (Why this?)
Both Write-Speeds are 0 (OK with me)

Every attempt to call StarBurn_CdvdBurnerGrabber_SetSpeeds with whatever ReadSpeed will fail! I even tried to set the read-speed to 8448 (the max value) with the write-speed set to 0 or to -1 (0xFFFFFFFF) or 65535 (0xFFFF).
Does this function try to set the Write-Speed even if it's a reader???

Another thing is: How can I determine the possible Read/Write speeds for a Drive? I thought, a good idea would be to set all known speeds (1x, 2x, 4x a.s.o.) and trigger for the return value, but it seems, that my CD-Writer has it's own defaults, eg: setting the Read-Speed to 1400 (8x) will succeed (EN_SUCCESS) but actually set the Read-Speed to 1058 (says StarBurn_CdvdBurnerGrabber_GetSpeeds).
I want to provide a choice (combobox) to the enduser with all possible speeds...any idea?

thankfull for every help

SpinDoctor


Top
 Profile  
 
 Post subject: Re: Setting the Drive-Speeds
PostPosted: Thu Jul 08, 2004 4:57 pm 
Offline
Site Admin

Joined: Fri Jun 18, 2004 12:03 am
Posts: 4089
Location: British Virgin Islands
SpinDoctor,

1) it's up to hardware what to return. Some nice specimens (as you have) return current read speed as zero. Just treat maximum set as current one in such a case (zero was returned).

2) failing to set speed is not normal. However setting write speed for reader is not an error (and we really do not do so). Can you get app called DebugView from www.sysinternals.com and catch extended debug output produced with debug version of StarBurn.dll? I would be very grateful if you'll send me this log. I'll try to help you.

3) drive does not return complete pattern and returns just upper values for current combination of drive + inserted disc. Please use upper returned value and CD increments of 176KBps and DVD increments of 1385 KBps to build complete supported map.

On setting any speed drive returns closest possible to the value you've passed to it. 1400 / 176 is less then 8X so drive sets 6x supported speed (1058 KBps). This is absolutely correct behavior.

Hope I've answered all your questions. Please feel free to ask more if you have them :)

Thanks!


SpinDoctor wrote:
Hi again.
I'm having trouble setting a DVD-ROM's Read-Speed.
The situation:
DVD-Drive: LG/DVD-ROM DRD8160B/1.00 (Vendor/ProductID/Revision)

I can create the object and get device-information via:
StarBurn_CdvdBurnerGrabber_GetDeviceInformation,
StarBurn_GetDeviceNameByDeviceAddress,
StarBurn_CdvdBurnerGrabber_GetSupportedMediaFormats and
StarBurn_CdvdBurnerGrabber_GetSupportedMediaFormatsEx.
After the call to these functions, all Read-Values are true/all Write-Values are false (naturally)

The call to StarBurn_CdvdBurnerGrabber_GetSpeeds is also successfull (EN_SUCCESS), but the returned values are:
MaxRead = 8448 (OK)
CurRead = 0 !!!! (Why this?)
Both Write-Speeds are 0 (OK with me)

Every attempt to call StarBurn_CdvdBurnerGrabber_SetSpeeds with whatever ReadSpeed will fail! I even tried to set the read-speed to 8448 (the max value) with the write-speed set to 0 or to -1 (0xFFFFFFFF) or 65535 (0xFFFF).
Does this function try to set the Write-Speed even if it's a reader???

Another thing is: How can I determine the possible Read/Write speeds for a Drive? I thought, a good idea would be to set all known speeds (1x, 2x, 4x a.s.o.) and trigger for the return value, but it seems, that my CD-Writer has it's own defaults, eg: setting the Read-Speed to 1400 (8x) will succeed (EN_SUCCESS) but actually set the Read-Speed to 1058 (says StarBurn_CdvdBurnerGrabber_GetSpeeds).
I want to provide a choice (combobox) to the enduser with all possible speeds...any idea?

thankfull for every help

SpinDoctor


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 08, 2004 5:49 pm 
Offline

Joined: Thu Jul 08, 2004 8:25 am
Posts: 51
Location: Germany
Hi Anton.

thanks, once again. so...

1) I have feared, THIS will be the answer :? , so I have to learn to live with it :D .. it's OK with me...

2) without having a view in DbgViews online help now (I've just downloaded it 2 minutes ago...), do I have to attach it with a process??? I have just startet it, ran my program and let it call ...SetSpeeds with failure...nothing in DbgViews Window!?!?!?!? Ok, a bit more info now (I missed it in my last post)...SetSpeeds returns EN_SCSI_CDB_FAILED and the CDB_FAILURE_INFORMATION-structure looks like:
- stCDB_FAILURE_INFORMATION {...} _CDB_FAILURE_INFORMATION
m__BOOLEAN__IsValid 1 '␁' unsigned char
m__UCHAR__CDBSizeInUCHARs 12 '␌' unsigned char
+ m__UCHAR__CDB 0x0012ef96 "╗" unsigned char [16]
m__UCHAR__SenseSizeInUCHARs 14 '␎' unsigned char
+ m__UCHAR__Sense 0x0012efa7 "p" unsigned char [32]
m__UCHAR__TransportStatus 4 '␄' unsigned char
m__UCHAR__TargetStatus 2 '␂' unsigned char
m__UCHAR__HostAdapterStatus 0 unsigned char

the output-window in VisualStudio shows:

CStarBurn_CdvdBurnerGrabber::GetCdvdSpeeds(): EXITing with success

CStarBurn_ScsiTransportASPI::ExecuteCDB(): Command failed!!!

SCSI request block dump:
SRB_Status: 0x04, SRB_HaStat: 0x00, SRB_TargStat: 0x02
CDB Length: 12, CDB dump: 0xBB 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00


SCSI sense data dump:
Error Code: 0x70, Is Sense Valid: No, Segment Number: 0x00 (0)
Sense Key: 0x02, Reserved: 0x00, Incorrect Length: No
End Of Media: No, File Mark: No, Information: 0x00 0x00 0x00 0x00
Additional Sense Length: 0x0A (10)
Command Specific Information: 0x00 0x00 0x00 0x00
Additional Sense Code (ASC): 0x3A, Additional Sense Code Qualifier (ASCQ): 0x00

First-chance exception at 0x77e53887 in SnapIt!.exe: Microsoft C++ exception: CStarBurn_Exception @ 0x0012e8f0.


What would DbgView print in such a case??? more information?

Anyway, I don't know, how to interprete this all...sorry
Hope, you know what happend there and that you can tell me, where my fault is.

finally 3) OK, it's a good idea, to do so.

thanks alot for all
Spin


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 08, 2004 6:01 pm 
Offline
Site Admin

Joined: Fri Jun 18, 2004 12:03 am
Posts: 4089
Location: British Virgin Islands
SpinDoctor,

1) I guess workaround for this would not be deadly :)

2) You just need to run DebugView in the backround, enable it to catch the log, run you app w/o compiler IDE running and relax.

3) First of all trace shows you're passing zeros as all values. This is not what you want to do, right? :) Second 0x3A/0x00 means "no disc in drive". Your particular drive does not support settting speeds with disc inserted.

Hope this helped! Thanks.

SpinDoctor wrote:
Hi Anton.

thanks, once again. so...

1) I have feared, THIS will be the answer :? , so I have to learn to live with it :D .. it's OK with me...

2) without having a view in DbgViews online help now (I've just downloaded it 2 minutes ago...), do I have to attach it with a process??? I have just startet it, ran my program and let it call ...SetSpeeds with failure...nothing in DbgViews Window!?!?!?!? Ok, a bit more info now (I missed it in my last post)...SetSpeeds returns EN_SCSI_CDB_FAILED and the CDB_FAILURE_INFORMATION-structure looks like:
- stCDB_FAILURE_INFORMATION {...} _CDB_FAILURE_INFORMATION
m__BOOLEAN__IsValid 1 '␁' unsigned char
m__UCHAR__CDBSizeInUCHARs 12 '␌' unsigned char
+ m__UCHAR__CDB 0x0012ef96 "╗" unsigned char [16]
m__UCHAR__SenseSizeInUCHARs 14 '␎' unsigned char
+ m__UCHAR__Sense 0x0012efa7 "p" unsigned char [32]
m__UCHAR__TransportStatus 4 '␄' unsigned char
m__UCHAR__TargetStatus 2 '␂' unsigned char
m__UCHAR__HostAdapterStatus 0 unsigned char

the output-window in VisualStudio shows:

CStarBurn_CdvdBurnerGrabber::GetCdvdSpeeds(): EXITing with success

CStarBurn_ScsiTransportASPI::ExecuteCDB(): Command failed!!!

SCSI request block dump:
SRB_Status: 0x04, SRB_HaStat: 0x00, SRB_TargStat: 0x02
CDB Length: 12, CDB dump: 0xBB 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00


SCSI sense data dump:
Error Code: 0x70, Is Sense Valid: No, Segment Number: 0x00 (0)
Sense Key: 0x02, Reserved: 0x00, Incorrect Length: No
End Of Media: No, File Mark: No, Information: 0x00 0x00 0x00 0x00
Additional Sense Length: 0x0A (10)
Command Specific Information: 0x00 0x00 0x00 0x00
Additional Sense Code (ASC): 0x3A, Additional Sense Code Qualifier (ASCQ): 0x00

First-chance exception at 0x77e53887 in SnapIt!.exe: Microsoft C++ exception: CStarBurn_Exception @ 0x0012e8f0.


What would DbgView print in such a case??? more information?

Anyway, I don't know, how to interprete this all...sorry
Hope, you know what happend there and that you can tell me, where my fault is.

finally 3) OK, it's a good idea, to do so.

thanks alot for all
Spin


Top
 Profile  
 
 Post subject: geeeeeee, this is great!!!!!!!!!!!!!!!!!!!!!1
PostPosted: Thu Jul 08, 2004 6:22 pm 
Offline

Joined: Thu Jul 08, 2004 8:25 am
Posts: 51
Location: Germany
fine!!!!!
the Drive reports CurReadSpeed of 2816, when there is a disc in it!!!!!
Can I rely on this behavior??? (CurRead==0 w/o disc - CurRead != 0 with disc? what do you think?).

And naturally, setting the drive's read-speed will always return EN_SUCCESS, as long as there is a disc...a bit strange behavior anyway: setting an uncomfortable speed will succeed (EN_SUCCESS) but when quested for current speed afterwards, CurSpeed=0 is reported, so I'll have to "Set And Test" the speed...it's OK

This is a great help at all!!!!!!!

Perhaps there will be some code in the forthcoming samples, that will treat with such circumstances?? Would be very helpfull for others and you would'nt have to waste your time with answering to stupid questions (perhaps you could use this time better with to implementing an "1:1 on the fly" copy of Audio CD's !!!! :lol: :lol: :lol: )

nice to meet you
Spin


Top
 Profile  
 
 Post subject: Re: geeeeeee, this is great!!!!!!!!!!!!!!!!!!!!!1
PostPosted: Thu Jul 08, 2004 6:31 pm 
Offline
Site Admin

Joined: Fri Jun 18, 2004 12:03 am
Posts: 4089
Location: British Virgin Islands
SpinDoctor,

I would recommend you to check the disc in drive BEFORE doing any activities with the drive. StarBurn_CdvdBurnerGrabber_TestUnitReady(...) is what you'd like to call in the very beginning.

I'm sorry but 1:1 copy of the audio CDs would not appear soon. MP3 and WMA direct decompression -- YES, compression WAV -> WMA -- YES (no MP3 compression b/s of the licensing limitations). But no 1:1 DIRECT copy (w/o intermediate imge on the hard disk) for now.

Thanks!

SpinDoctor wrote:
fine!!!!!
the Drive reports CurReadSpeed of 2816, when there is a disc in it!!!!!
Can I rely on this behavior??? (CurRead==0 w/o disc - CurRead != 0 with disc? what do you think?).

And naturally, setting the drive's read-speed will always return EN_SUCCESS, as long as there is a disc...a bit strange behavior anyway: setting an uncomfortable speed will succeed (EN_SUCCESS) but when quested for current speed afterwards, CurSpeed=0 is reported, so I'll have to "Set And Test" the speed...it's OK

This is a great help at all!!!!!!!

Perhaps there will be some code in the forthcoming samples, that will treat with such circumstances?? Would be very helpfull for others and you would'nt have to waste your time with answering to stupid questions (perhaps you could use this time better with to implementing an "1:1 on the fly" copy of Audio CD's !!!! :lol: :lol: :lol: )

nice to meet you
Spin


Top
 Profile  
 
 Post subject: Re: geeeeeee, this is great!!!!!!!!!!!!!!!!!!!!!1
PostPosted: Thu Jul 08, 2004 7:02 pm 
Offline

Joined: Thu Jul 08, 2004 8:25 am
Posts: 51
Location: Germany
[quote=anton (staff)"]...
I'm sorry but 1:1 copy of the audio CDs would not appear soon. MP3 and WMA direct decompression -- YES, compression WAV -> WMA -- YES (no MP3 compression b/s of the licensing limitations). But no 1:1 DIRECT copy (w/o intermediate imge on the hard disk) for now.
...[/quote]
with this reply, you answered a question I posted, while you were writing it...
(that's weired, for sure)
after sending the last post (actually, between sending 2 posts) I added StarBurn_CdvdBurnerGrabber_TestUnitReady to my code :wink:

thanks and bye for today
Spin


Top
 Profile  
 
 Post subject: Re: geeeeeee, this is great!!!!!!!!!!!!!!!!!!!!!1
PostPosted: Thu Jul 08, 2004 7:44 pm 
Offline
Site Admin

Joined: Fri Jun 18, 2004 12:03 am
Posts: 4089
Location: British Virgin Islands
It happens :)

SpinDoctor wrote:
[quote=anton (staff)"]...
I'm sorry but 1:1 copy of the audio CDs would not appear soon. MP3 and WMA direct decompression -- YES, compression WAV -> WMA -- YES (no MP3 compression b/s of the licensing limitations). But no 1:1 DIRECT copy (w/o intermediate imge on the hard disk) for now.
...

with this reply, you answered a question I posted, while you were writing it...
(that's weired, for sure)
after sending the last post (actually, between sending 2 posts) I added StarBurn_CdvdBurnerGrabber_TestUnitReady to my code :wink:

thanks and bye for today
Spin[/quote]


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 27 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group