flat assembler
Message board for the users of flat assembler.

Index > OS Construction > cd-dvd driver

Author
Thread Post new topic Reply to topic
Octavio



Joined: 21 Jun 2003
Posts: 366
Location: Spain
Octavio 10 Jul 2005, 13:26
I´m developping a cd-dvd driver ,i already did a fast reading of the 1000 pages of multimedia scsi commands, but somethings are not clearly explained, the problem that i have now is that when i change the cd disc
i have to reset the driver and retry many times until it works, so i think that perhaps i forget to send some comand to correctly initialize the unit.
some idea about this problem?
after many tries everithing goes fine, all commands works and i can read
data disc or play music disc.
Post 10 Jul 2005, 13:26
View user's profile Send private message Visit poster's website Reply with quote
Dex4u



Joined: 08 Feb 2005
Posts: 1601
Location: web
Dex4u 10 Jul 2005, 16:32
As far as i know this is the normal,as my driver does the same, but i do not do reset, i thought it may be not doing the reset, but as you get the same problem and do it must not be that.
As some cd driver seem to work better than others, dvd driver need more try than cd drives also read cd-rw is better than cd-r, you need to try then a delay and try again about 5 time if not give error.

I think windows/ linux does the same, but hides it .
Post 10 Jul 2005, 16:32
View user's profile Send private message Reply with quote
Octavio



Joined: 21 Jun 2003
Posts: 366
Location: Spain
Octavio 07 Aug 2005, 11:34
For writing a cd driver i´m reading this doc: mmc4r05a.pdf
have done a few tests with some commands, and have a few problems with ´GET CONFIGURATION´ command. When this command is send to the device, the reponse is variable length, i read the reponse data testing bit 3 of ide status port, the device sends 60 bytes of data, but the data lenght in the feature header descriptor is 96 bytes,what is happening?
all the other data is ok with the documentation.
I have already tried to add delays or force to read 96 bytes.
Post 07 Aug 2005, 11:34
View user's profile Send private message Visit poster's website Reply with quote
Dex4u



Joined: 08 Feb 2005
Posts: 1601
Location: web
Dex4u 07 Aug 2005, 12:16
I do not use that command,but if you do the number of byte to read and acknowledge them and you still only get 60 bytes, then maybe the doc wrong as a lot of doc on ATAPI are full of mastakes.
Post 07 Aug 2005, 12:16
View user's profile Send private message Reply with quote
Matrix



Joined: 04 Sep 2004
Posts: 1166
Location: Overflow
Matrix 07 Aug 2005, 13:08
These are interesting things
i havent seen complete informations on ata read write either,

but you can realize the reading retries with:
spinning up disc,
focusing and seeking optical head to track 0, getting toc.

there must be a disk spin up, seek complete, disk read function somewhere.
Post 07 Aug 2005, 13:08
View user's profile Send private message Visit poster's website Reply with quote
Octavio



Joined: 21 Jun 2003
Posts: 366
Location: Spain
Octavio 07 Aug 2005, 22:46
Octavio wrote:
the device sends 60 bytes of data, but the data lenght in the feature header descriptor is 96 bytes,what is happening?
.

Embarassed my mistake was to use the wrong format in numbers ,scsi uses motorola format, not intel. Now the problem is solved.
Post 07 Aug 2005, 22:46
View user's profile Send private message Visit poster's website Reply with quote
Dex4u



Joined: 08 Feb 2005
Posts: 1601
Location: web
Dex4u 08 Aug 2005, 01:10
Thats a easy mistake to make Wink .
Post 08 Aug 2005, 01:10
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
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 vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2023, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.