Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Ejecting a boot CD/DVD

5 views
Skip to first unread message

JustinH

unread,
Sep 16, 2005, 9:42:52 AM9/16/05
to
We are developing a XPe system which works without mouse or keyboard.
I have got as far as being able to create a bootable DVD with the aid
of the notes from Slobodan and GregG.
Now comes the tricky bit - we want to be able to send out updated DVD's
which the user can put in the drive and thus boot the new version of
the system. W want to be able to open the drive door for them at the
appropriate time. Is there any way, programmatically, of forcing the
drive door to eject when booted from the DVD. It doesn't appear to be
possible through Explorer since C: is not seen as removable and
selecting 'eject' for th D: CD-Drive volume has no effect.
Any ideas anyone?
please?

Justin

Doug Hoeffel

unread,
Sep 16, 2005, 1:05:36 PM9/16/05
to
JustinH:

Maybe this will help... I used the DOS utility ejectcd.com when I wanted to
eject the CD after having re-imaged a HD using ghost. This was part of a
bat stream on a bootable CD. After the ghost was done we ejected the CD as
my box has no keyboard, mouse or vga monitor.

HTH... Doug

"JustinH" <justin...@brunel.ac.uk> wrote in message
news:1126878172.5...@z14g2000cwz.googlegroups.com...

Matt Kellner (MS)

unread,
Sep 16, 2005, 6:26:17 PM9/16/05
to
Hi Justin. The reason the standard "Eject" function doesn't work in this
case is that the OS locks the CD/DVD drive. You'll notice that on most
CD-ROM drives, pressing the eject button also doesn't work. This is a basic
requirement of the OS, that the boot media always be present, so while the
OS is in use, the CD will basically be locked inside the drive.

On some machines, it is possible to eject the CD even though it's in use and
the drive has been locked in software. When that happens, the OS
immediately bluescreens, complaining that its boot media has disappeared or
is invalid.

Your best bet to do CD/DVD updates is to provide instructions to the user to
manually eject the disk during POST, insert the new disk, then reboot the
system.

Hope this helps! =)

--
Matt Kellner (matt...@online.microsoft.com)
STE, Windows Embedded Group

This posting is provided "AS IS" with no warranties, and confers no rights.
===============================

"JustinH" <justin...@brunel.ac.uk> wrote in message
news:1126878172.5...@z14g2000cwz.googlegroups.com...

Mike Warren

unread,
Sep 16, 2005, 11:08:38 PM9/16/05
to

Hi Justin,

I unlock the CD drive and then eject it in code. The side effect
is the system BSODs but for me that doesn't matter as I have
already instructed my custom micro to switch off the screen
and power down the device.

If you can live with the BSOD I could supply a small exe (or
Delphi code) that will do the job for you.

-Mike

jus...@halls-family.wanadoo.co.uk

unread,
Sep 17, 2005, 5:26:05 AM9/17/05
to
Mike

thanksfor that. The BSOD is not a problem since, like you we will be
forcing a reboot/restart immediately. Since we are dealin with elderly
people we prefer that tey do not need to fidle with the buttone,
especially since timing between switch on and boot up is critical. If
you could send me the Delphi code then we can adapt it to fit into our
application. Many thaks
Justin

Mike Warren

unread,
Sep 17, 2005, 8:42:37 AM9/17/05
to
jus...@halls-family.wanadoo.co.uk wrote:
> The BSOD is not a problem since, like you we will be
> forcing a reboot/restart immediately. Since we are dealin with
> elderly people we prefer that tey do not need to fidle with the
> buttone, especially since timing between switch on and boot up is
> critical. If you could send me the Delphi code then we can adapt it
> to fit into our application.

Justin,

I think you will have a problem with rebooting since in my tests
with several different motherboards the reboot command was
killed as soon as the BSOD occurred. I get around the problem
in my device because I have a custom microcontroller which
controls the power by hardware means.

Anyway, I have uploaded a test program with Delphi source
for you to play with. It's at:

www.cairnscarsound.com.au/tmp/CdEjectTest.zip

I haven't tested it on XPe as I am at home. If you have any problems
I will try it with XPe at work on Monday.

If you manage to get a software reboot happening after a forced
eject please let me know.

-Mike

JustinH

unread,
Sep 19, 2005, 5:49:43 AM9/19/05
to

Mike
Thanks for the file. I haven't got around to looking at XPe error
recovery processes yet - I have only just got as far as getting a
bootable DVD (a long winded process with so many DVD write processes to
do!). From what the guys at Abacus had said I had thought that XPe,
being intended for 'embedded' applications, would have some form of
automatically rebooting in order to recover from fatal errors. If the
worst comes to the worst we will have to have a hardware watchdog
timer, pinged thrugh the parallel port, which will hit the reset button
when the program stops running. I will let you know if I come across
any more elegant solution.
Regards

Justin

Nikolai Vorontsov

unread,
Sep 19, 2005, 5:28:11 AM9/19/05
to
Hello JustinH,
> Any ideas anyone?
> please?

Another isea is to use RAM boot XPE.
You load all XPe to the memory and then you don't need CD at all, you
can eject it, you can insert another one - all is OK.

Browse this NG about RAM booted XPE.


--
Nikolai Vorontsov
Quadrox NV

Mike Warren

unread,
Sep 19, 2005, 10:29:06 AM9/19/05
to
JustinH wrote:
> Thanks for the file. I haven't got around to looking at XPe error
> recovery processes yet - I have only just got as far as getting a
> bootable DVD (a long winded process with so many DVD write processes
> to do!). From what the guys at Abacus had said I had thought that
> XPe, being intended for 'embedded' applications, would have some form
> of automatically rebooting in order to recover from fatal errors. If
> the worst comes to the worst we will have to have a hardware watchdog
> timer, pinged thrugh the parallel port, which will hit the reset
> button when the program stops running. I will let you know if I come
> across any more elegant solution.

Hi Justin,

The other problem you may have is when a system boots from a
hardware reset some (many) motherboards close the open CD
drawer. Because we power down our device it doesn't matter.

-Mike


JustinH

unread,
Sep 20, 2005, 4:34:42 AM9/20/05
to
Nikolai
thanks for the suggestion, but we have a rather large footprint for
that. With AT&T Natural voices our operating system runs out at over a
Gb and for cost reasons we are trying to keep below 256Mb RAM. We have
considered copying the complete operating system to the hard drive and
running it from there, but the boot processes all get more complicated
if the CD is left in the drive and it would take too long to copy the
entire footprint at every boot. Another possibility is to do something
with HORM, but the swapping CD option appeared to have an elegant
simplicity. (Ha!).
Justin

JustinH

unread,
Oct 20, 2005, 4:27:46 AM10/20/05
to
Hi

thanks to everybody for all the suggestions on this topic. Eventually
we decided to 'cheat' somewhat - we used a slimline, laptop style DVD
drive (which cannot automatically retract) and fitted a mechanical
button to the outside which operates the emergency release catch
through the little hole in the front. This allows the user to change
the DVD while the machine is switched off, keepig the oeprating system
happy and prviding a simple clean interface for the users. Our
application is the shell and most of the time if the draw gets opened
accidentally it does not not BSOD, but if it does it is easy to simply
reboot the system. I am afraid this is not an approach which is
universally applicable, but it seems the right way to go for us at
present.

Justin

0 new messages