Subj : Re: How to detect cdrom tray status (open or closed) To : comp.os.linux From : Eric Date : Fri Oct 15 2004 07:36 am Sybren Stuvel wrote: > Mihai Osian enlightened us with: >> There is a CDROM_DRIVE_STATUS ioctl defined in >> /usr/include/linux/cdrom.h. Perhaps it can help you. > > This is exactly what I need, but *ARGL* my drive reports the wrong > information :( I reports "tray open" when it's closed without a disc. > The CDROM_DISC_STATUS ioctl also returns CDS_NO_INFO in both cases > (tray open / tray closed without disc) > > Sybren Welcome to the real world. This is how a lot of things are designed, they have absolutely no interest in you the programmer. I run into crap like this time and time again. Wasn't it just recently we learned that LG was using the FLUSH_CACHE atapi command to do firmware upload? You have my sympathies, i know what its like to want to create a usefull utility only to find it cant be done because of the designers stupidity. Someday, maybe, new products will go through some kind of "programmers design review" before being released... someday, maybe. Eric .