Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > Disk Drive Interrupts
2007-08-18 13:51
Conrad

Registered: Nov 2006
Posts: 849
Disk Drive Interrupts

Hello there.

May I ask if it's possible to get your own interrupt routines running on the disk drive using the VIA timer registers?

Since the drive also has an IRQ vector at $fffe/ffff, I've been trying to get my own IRQ routine to run using timer 1, but unfortunately no luck.

Here's the drive source of the IRQ routine I'm using:
DC_IRQ
	pha
	txa
	pha             
	tya
	pha
	
	bit $180D       ; interrupt from timer 1? (bit 6)
	bvc DC_IRQ_	; no, skip.

	lda $1c00       ; Flash LED to make sure irq runs.
	eor #$08
	sta $1c00

DC_IRQ_
        pla
        tay
        pla             
        tax
        pla
        rti

(This code is similar to the one stored in disk ROM)


I also have FFFF/FFFE vector set at this code location (DC_IRQ).

The problem is I'm not sure which VIA registers to set to enable timer 1 IRQ. I tried setting $180d, $180e and other IRQ related registers (also executing SEI before hand and CLI afterwards) but still nothing.

Could someone please help me which registers to set properly ?

I'm only doing this for tests BTW, just to see if it's possible to do. I'm testing it on 1541-I/II drives.

Cheers if you can help!
Owen.
 
... 10 posts hidden. Click here to view all posts....
 
2007-08-24 21:10
Conrad

Registered: Nov 2006
Posts: 849
@Krill: Don't worry, I've only been doing these somehow useless routines just to (down to it all) learn how disk drives work.... after a couple days of stress it seems that you were right all along :D

Luckily I've purchased 1540/1541 and 1571 disk-drive in-depth technical service manuals, so I should be able to try out some better methods soon.
2007-09-10 18:06
chancer

Registered: Apr 2003
Posts: 347
conrad I just was reading thru an old book.. noticed it mentioned a 1540, they recon it was made for the vic 20. the book say the screen must be turned off during the loading, by changing $d011.

with poke 53265,11

and when the things finished loading poke 53265,27

maybe thats of some use to you, maybe total rubbish, but I can't test that.

2007-09-10 21:27
Danzig

Registered: Jun 2002
Posts: 440
??? the Off-Topic-Detection-Bell is ringing...

conrad is testing around with DRIVE coding, not with switching the SCREEN on/off :D
2007-09-11 13:43
chancer

Registered: Apr 2003
Posts: 347
Quote: ??? the Off-Topic-Detection-Bell is ringing...

conrad is testing around with DRIVE coding, not with switching the SCREEN on/off :D


what is it with certain (not all) alphaflight members? hhmm u went x95, probably explains your attitude.

unless you have a vic 1540 drive,and know 100% about that, then how can you comment, go buy one prove me wrong ;-)

so yer i do think its relivant, or at least trying to be helpful even if its found to be in-correct (unlike your comment), since it's a drive actually designed for the vic 20, that maybe someone might use (chances are small, but who knows)

go and look in a book "com. 64 omnibus - a comprehensive programming handbook" by peter lupton / frazer robinson, page 400 of that.
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
WVL/Xenon
algorithm
Acidchild/Padua
MCM/ONSLAUGHT
DnP
wil
v3nt0r/ibex-crew
Guests online: 124
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.6)
5 The Demo Coder  (9.6)
6 Edge of Disgrace  (9.6)
7 What Is The Matrix 2  (9.6)
8 Uncensored  (9.6)
9 Comaland 100%  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 No Listen  (9.6)
2 Layers  (9.6)
3 Cubic Dream  (9.6)
4 Party Elk 2  (9.6)
5 Copper Booze  (9.6)
6 X-Mas Demo 2024  (9.5)
7 Dawnfall V1.1  (9.5)
8 Rainbow Connection  (9.5)
9 Onscreen 5k  (9.5)
10 Morph  (9.5)
Top Groups
1 Performers  (9.3)
2 Booze Design  (9.3)
3 Oxyron  (9.3)
4 Censor Design  (9.3)
5 Triad  (9.3)
Top Musicians
1 Rob Hubbard  (9.7)
2 Mutetus  (9.7)
3 Jeroen Tel  (9.7)
4 Linus  (9.6)
5 Stinsen  (9.6)

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