#1 Burning Software

It is currently Thu Dec 19, 2024 7:19 am

All times are UTC




Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: Slow FindDevice with network burner
PostPosted: Sun May 11, 2008 11:57 pm 
Offline

Joined: Tue Oct 31, 2006 12:25 am
Posts: 43
Hi

I've had a report of my app (with StarBurn 7.2.20.544) taking a particularly long time to perform drive discovery with a network burner.

Here is our log with seconds on the left:

65 - [BurnerLog] UpStartEx
65 - [GetTransportType] UseSptiTransport: True
65 - [PrepareBurnerList] Start
65 - [BurnerLog] CdvdBurnerGrabber_GetDeviceInformation
65 - [BurnerLog] CdvdBurnerGrabber_GetSupportedMediaFormats
65 - [BurnerLog] CdvdBurnerGrabber_GetSupportedMediaFormatsExEx
65 - [BurnerLog] CdvdBurnerGrabber_ProbeSupportedWriteModes
65 - [BurnerLog] CdvdBurnerGrabber_ProbeSupportedReadModes
66 - [BurnerLog] CdvdBurnerGrabber_TestUnitReady
66 - [BurnerLog] Destroy: Grabber
129 - [BurnerLog] CdvdBurnerGrabber_GetDeviceInformation
129 - [BurnerLog] CdvdBurnerGrabber_GetSupportedMediaFormats
129 - [BurnerLog] CdvdBurnerGrabber_GetSupportedMediaFormatsExEx
177 - [BurnerLog] CdvdBurnerGrabber_ProbeSupportedWriteModes
226 - [BurnerLog] CdvdBurnerGrabber_ProbeSupportedReadModes
226 - [BurnerLog] CdvdBurnerGrabber_TestUnitReady
242 - [BurnerLog] Destroy: Grabber
242 - [PrepareBurnerList] Device 0: E: DVD RW DRU-820A
242 - [PrepareBurnerList] Device 1: F: WRR-4848
242 - [cbDrivesChange] Selected Device 0: 0^E: DVD RW DRU-820A
242 - [PrepareBurnerList] End, Burner count: 2


IOW it takes nearly two minutes to fully initialize StarBurn and get a list of all burners.

On our test systems with regular burners it is reasonably quick, but there is still a noticeable pause.

Is there an easy way for the burner information to be persisted between sessions to speed this up?

Also, I may call StarBurn_FindDevice twice (initializing the list and again before burning to ensure they have a valid disk inserted). Is there a better way I can simply refresh the status of a particular device (in particular to get details on the inserted disk).


Regards

x


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 12, 2008 1:50 am 
Offline
Site Admin

Joined: Fri Jun 18, 2004 12:03 am
Posts: 4089
Location: British Virgin Islands
It's a very bad idea to use FindDevice as it's ASPI call acually. Re-check SPTI and SPTD samples, they have totally different device enumeration loop. ASPI lookup is made slow as it uses polling (backward compatiblity with Windows 98 broken "get device" call). Just don't call it at all...


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 12, 2008 4:42 am 
Offline

Joined: Tue Oct 31, 2006 12:25 am
Posts: 43
Hi Anton

If it's such a bad idea, why is it done in the (GUI) demo projects? :shock:

So is Samples\Console\Pascal\FindDevice.dpr a suitable code model?

(In tandem with StarBurn_CdvdBurnerGrabber_CreateEx if SPTI transport is enabled).


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 12, 2008 5:46 am 
Offline
Site Admin

Joined: Fri Jun 18, 2004 12:03 am
Posts: 4089
Location: British Virgin Islands
Just b/c the world is not perfect.

No. Use FindDeviceEx (SPTI) and FindDeviceExE (SPTD) samples as a basement for enumeration loop.

xexx wrote:
Hi Anton

If it's such a bad idea, why is it done in the (GUI) demo projects? :shock:

So is Samples\Console\Pascal\FindDevice.dpr a suitable code model?

(In tandem with StarBurn_CdvdBurnerGrabber_CreateEx if SPTI transport is enabled).


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 12, 2008 7:24 am 
Offline

Joined: Tue Oct 31, 2006 12:25 am
Posts: 43
Sorry I gave you bad information :oops:

We have an SPTI option which is enabled by default on compatible systems and thus the call is to StarBurn_CdvdBurnerGrabber_CreateEx (rather than StarBurn_FindDevice as it would be if they were restricted to using ASPI).

The user in this case is using SPTI.

So let's just pretend our little exchange didn't take place :wink:

I guess what i am looking for is some advice from you on what functions during a typical burner discovery are slow (rather than our timing it on a range of system configurations, I'm hoping you can rattle them off the top of your head).

In that way we can best make some decisions on optimizing our code.


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 12, 2008 7:30 am 
Offline
Site Admin

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

Just don't use ASPI and replace it with both SPTI and SPTD. Their lookup sequence is fast.

xexx wrote:
Sorry I gave you bad information :oops:

We have an SPTI option which is enabled by default on compatible systems and thus the call is to StarBurn_CdvdBurnerGrabber_CreateEx (rather than StarBurn_FindDevice as it would be if they were restricted to using ASPI).

The user in this case is using SPTI.

So let's just pretend our little exchange didn't take place :wink:

I guess what i am looking for is some advice from you on what functions during a typical burner discovery are slow (rather than our timing it on a range of system configurations, I'm hoping you can rattle them off the top of your head).

In that way we can best make some decisions on optimizing our code.


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 12, 2008 11:43 pm 
Offline

Joined: Tue Oct 31, 2006 12:25 am
Posts: 43
Thanks Anton,

SPTD was surprisingly painless to implement (FYI StarBurn_CdvdBurnerGrabber_CreateExEx is not actually declared in StarBurn.pas). For some reason I always imagine StarBurn code will be harder to implement than it is (must be all the C declarations) :?

I've added it as a third transport option which may help on some problematic systems. Because it requires secondary installation, it can't really be used as a default option.

I'll have the 2-minute-discovery user test it to see if it offers any improvement.


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 14, 2008 8:36 am 
Offline

Joined: Fri Jan 11, 2008 6:13 am
Posts: 200
Location: BVI
Yes, SPTD is very much like SPTI...

CreateExEx is missing from 7.xx builds but we've already added it to the Pascal 10.xx headers.

Well... No :) SPTD comes as standard component of Alcohol 120%, Daemon Tools and also few other software titles on the market. So you have a great chances uses ALREADY has it. Also it can be installed silently so I personally don't see any use in messing with SPTI (unless backward compatibility).

Sure! Please keep us updated :)

xexx wrote:
Thanks Anton,

SPTD was surprisingly painless to implement (FYI StarBurn_CdvdBurnerGrabber_CreateExEx is not actually declared in StarBurn.pas). For some reason I always imagine StarBurn code will be harder to implement than it is (must be all the C declarations) :?

I've added it as a third transport option which may help on some problematic systems. Because it requires secondary installation, it can't really be used as a default option.

I'll have the 2-minute-discovery user test it to see if it offers any improvement.


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 21, 2008 6:54 am 
Offline

Joined: Tue Oct 31, 2006 12:25 am
Posts: 43
Those are not applications that are typically installed by typical users, so i'd have to say there is only a chance, rather than a great one :wink:

I can't find much info on SPTD, such as:
- How can one determine if SPTD is installed?
- How can one install it silently?


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 21, 2008 10:07 am 
Offline
Site Admin

Joined: Fri Jun 18, 2004 12:03 am
Posts: 4089
Location: British Virgin Islands
Use StarBurn SDK samples they have SPTD related API.

sptd.exe /s or /silient

www.duplexsecure.com

xexx wrote:
Those are not applications that are typically installed by typical users, so i'd have to say there is only a chance, rather than a great one :wink:

I can't find much info on SPTD, such as:
- How can one determine if SPTD is installed?
- How can one install it silently?


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

All times are UTC


Who is online

Users browsing this forum: Google [Bot] and 32 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