What's the criteria for detecting a replaced CD? (Windows)
-
Hello. My program burns CD's/DVD's. Those CD/DVD's are sent out to a lot of receivers, countrywide. Now, I've got error reports from some people who claims that the two CD's they got is identical to eachother. That is not the case. The CD's in question got the same volume label, the same anount of files, with identical file names. But the content of the files differ. When the receiver has read the first CD, ejects it and puts in CD No 2, the information doesn't change (due to the fact that the driver cdrom.sys doesn't notice the changed CD, I guess). And the content of the files (from the first CD) seems cached, so the user sees the files from CD No 1, despite the fact that CD No2 is inserted. F5 doesn't help, since the file system doesn't become refreshed. If the user reads a completely different CD between "my" CD's, the file system is refreshed and the information is correct. My question: What's the criteria (in cdrom.sys) for detecting a replaced CD in the CD-ROM drive? Different volume label, or what? This problem drives "my CD readers" go nuts, and then it hits me... TIA.
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
modified on Wednesday, September 23, 2009 6:19 AM
-
Hello. My program burns CD's/DVD's. Those CD/DVD's are sent out to a lot of receivers, countrywide. Now, I've got error reports from some people who claims that the two CD's they got is identical to eachother. That is not the case. The CD's in question got the same volume label, the same anount of files, with identical file names. But the content of the files differ. When the receiver has read the first CD, ejects it and puts in CD No 2, the information doesn't change (due to the fact that the driver cdrom.sys doesn't notice the changed CD, I guess). And the content of the files (from the first CD) seems cached, so the user sees the files from CD No 1, despite the fact that CD No2 is inserted. F5 doesn't help, since the file system doesn't become refreshed. If the user reads a completely different CD between "my" CD's, the file system is refreshed and the information is correct. My question: What's the criteria (in cdrom.sys) for detecting a replaced CD in the CD-ROM drive? Different volume label, or what? This problem drives "my CD readers" go nuts, and then it hits me... TIA.
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
modified on Wednesday, September 23, 2009 6:19 AM
-
kakan wrote:
The CD's in question got the same volume label, the same anount of files, with identical file names.
Well I guess Windows may not be able to guess that the contents of the files is different.
I know how it works for diskettes, since I modified Windows diskette driver (a long time ago). The diskette driver compares the diskettes serial number to the serial number gotten from the previous access to the diskette. But for a CD/DVD? Maybe I should get a copy of the source code for cdrom.sys and examine it. I'm not sure I got the time for it. I think I'll hang around CP a while before trying that.
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
-
Hello. My program burns CD's/DVD's. Those CD/DVD's are sent out to a lot of receivers, countrywide. Now, I've got error reports from some people who claims that the two CD's they got is identical to eachother. That is not the case. The CD's in question got the same volume label, the same anount of files, with identical file names. But the content of the files differ. When the receiver has read the first CD, ejects it and puts in CD No 2, the information doesn't change (due to the fact that the driver cdrom.sys doesn't notice the changed CD, I guess). And the content of the files (from the first CD) seems cached, so the user sees the files from CD No 1, despite the fact that CD No2 is inserted. F5 doesn't help, since the file system doesn't become refreshed. If the user reads a completely different CD between "my" CD's, the file system is refreshed and the information is correct. My question: What's the criteria (in cdrom.sys) for detecting a replaced CD in the CD-ROM drive? Different volume label, or what? This problem drives "my CD readers" go nuts, and then it hits me... TIA.
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
modified on Wednesday, September 23, 2009 6:19 AM
This may be too late for your purposes, but I have only just seen your question. Take a look at How to receive notification of CD-ROM insertion or removal[^] on MSDN. Google could have saved you a lot of time! :)
Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.”
-
This may be too late for your purposes, but I have only just seen your question. Take a look at How to receive notification of CD-ROM insertion or removal[^] on MSDN. Google could have saved you a lot of time! :)
Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.”
Hello. I did at lot of Googling about the subject. The article you are referring, talks about receiveing and handling WM_DEVICECHANCE messages. In this case, there are no such messsage, and that's the problem. My guess is that it's a driver issue. My question was (and still is): What's the mechanism for the driver to detect that the CD/DVD has been replaced (and consequently send a WM_DEVICECHANCE message)? In other words: What do I have to do with the CD's/DVD's in order to make Windows (and it's cdrom driver) discover that CD/DVD has been replaced?
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson