Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
 Welcome to our latest new user Coinoperator ! (Registered 2024-06-17) You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > Disk ID causing trouble
2005-05-28 22:36
Cybernator

Registered: Jun 2002
Posts: 154
Disk ID causing trouble

Apparently when the 1541 seeks a track (using the ROM routines), it _doesn't_ ignore the ID which is inside the header block, but compares it to the ID stored on zeropage (can't recall the exact address right now). The seek command is issued by the "execute" jobcode ($e0) and, unless I loaded something from the disk before, the seek fails. To overcome the problem, I invoke the initialize routine at $d005 as first thing in my loader. Now two problems arise:
1. Unless run on a stock 1541, the loader locks up immediately (e.g. SpeedDOS)
2. If I flip the disk, I need to invoke "initialize" once again, but for some reason it fails this time (locking up). And I'm dangerously low on memory, so I cannot write my own routines which would eventually ignore the ID.
A simple solution is to format both sides with the same ID, but that would complicate copying, which is completely undesirable. I've been trying to catch up something in AAY1541, but no luck so far.

Any suggestions? Is there a way to tell DOS to ignore the ID, or set it as unknown so that DOS reads it from disk before seeking?

Btw, the problem might actually be occuring while seeking a sector using the routine at $f50a.
 
... 8 posts hidden. Click here to view all posts....
 
2005-05-30 13:00
Graham
Account closed

Registered: Dec 2002
Posts: 990
The drive uses the write protect sense to find out if a new disk has been inserted. Shortening the sense will cause a lot of trouble.
2005-05-30 16:50
V-12

Registered: Nov 2003
Posts: 206
anix: aah understand..I didn't readed carefully your last post :) well maybe only with changing the ROM of the drive it would work...but I know another solution which did my friend. He added the reset for the solved lines... I really would like to remove that "disk id mismatch" too without another electronic modifications.
2005-05-31 09:38
Kisiel
Account closed

Registered: Jul 2003
Posts: 56
Murdock I think it worst solution to fix this problem. As Graham sayed "Shortening the sense will cause a lot of trouble".. the problems will come then you change disk to even other side and traying to write some things with wrong ID (old). To fix this problem you must check every time disk ID before read and write.... for me it's stupid solution.
2005-05-31 11:13
V-12

Registered: Nov 2003
Posts: 206
Kisiel: check this: it works. ask Reiter:

http://www.filety.lh.pl/index.php?strona=arty/sprzet/pamietnik/..

greetz
Pawel
2005-06-01 07:18
Kisiel
Account closed

Registered: Jul 2003
Posts: 56
murdock this site does not give us any improvments. After adding switch , you have to press the button on every disk change. For me it's very not convenient solution. BTW we talking about 0,2 to 0,5 Eu and few minutes of work... isn't??? Rom change will cost much more.
2005-06-01 08:04
Graham
Account closed

Registered: Dec 2002
Posts: 990
A ROM change doesn't help anything. The drive still cannot detect disk changes and still doesn't know when to look for a new ID.
2005-06-01 09:28
Kisiel
Account closed

Registered: Jul 2003
Posts: 56
hmm I have idea to fix this problem, add switch to closing device. So if you have 1541-II you must add switch over the header (placed on top cover of disk drive.. glued or something.. inside cover) and this solution works as is:
when you oppening door drive, the steel plate inside drive will press the button (swich) and will give information abut changes to cpu. So now you will have mechanical detector :o)
2005-06-01 12:34
TNT
Account closed

Registered: Oct 2004
Posts: 189
Better idea would be adding monostable multivibrator and send 50 ms low pulse every time the real protection status changes from high to low. That way 1541 DOS detects disk changes but disk is still write enabled.
2005-06-01 14:27
Graham
Account closed

Registered: Dec 2002
Posts: 990
I've got an even better idea: Leave the write protect sense in place and only deactivate it when you need it deactivated.
2005-06-01 17:55
TNT
Account closed

Registered: Oct 2004
Posts: 189
Probably the best idea is to buy disk notcher :)
Previous - 1 | 2 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Hoogo/Padua
Mason/Unicess
Acidchild/Padua
mutetus/Ald ^ Ons
megasoftargentina
ccr/TNSP
Guests online: 107
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.7)
5 Edge of Disgrace  (9.7)
6 No Bounds  (9.6)
7 Uncensored  (9.6)
8 Comaland 100%  (9.6)
9 Wonderland XIV  (9.6)
10 Aliens in Wonderland  (9.6)
Top onefile Demos
1 Layers  (9.6)
2 Cubic Dream  (9.6)
3 Party Elk 2  (9.6)
4 Copper Booze  (9.6)
5 Rainbow Connection  (9.5)
6 It's More Fun to Com..  (9.5)
7 Dawnfall V1.1  (9.5)
8 Daah, Those Acid Pil..  (9.5)
9 Birth of a Flower  (9.5)
10 Quadrants  (9.5)
Top Groups
1 Nostalgia  (9.4)
2 Oxyron  (9.3)
3 Booze Design  (9.3)
4 Censor Design  (9.3)
5 SHAPE  (9.3)
Top Fullscreen Graphicians
1 Joe  (9.7)
2 Veto  (9.6)
3 Facet  (9.6)
4 The Sarge  (9.6)
5 Carrion  (9.5)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.043 sec.