Interrupt 13h Question

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
renovatio
Member
Member
Posts: 57
Joined: Fri May 23, 2008 5:13 am

Interrupt 13h Question

Post by renovatio »

What is the maximum number of sectors I can read with 2h function?

Is there any limitation apart from the AL register (255 max) and the amount of memory?

Thanks...
User avatar
bewing
Member
Member
Posts: 1401
Joined: Wed Feb 07, 2007 1:45 pm
Location: Eugene, OR, US

Re: Interrupt 13h Question

Post by bewing »

These sorts of questions are exactly what Ralf Brown's Interrupt List (RBIL) is supposed to help with.
Unfortunately, the answer is BIOS-specific. I haven't looked at my copy of RBIL, but I'd expect that you had best keep your transfers below 64K, and probably <128 sectors (NOT including 128). I have heard that some BIOSes have problems with transfers of 128 sectors, for a different Int13h command -- and I would expect it would happen for all Int13h commands on that BIOS. I always use max 32K transfers, myself.
renovatio
Member
Member
Posts: 57
Joined: Fri May 23, 2008 5:13 am

Re: Interrupt 13h Question

Post by renovatio »

I'm sorry if I seemed to be lazy, I didn't know RBIL list of interrupts could help me. Anyway, thanks for your reply.
User avatar
abachler
Member
Member
Posts: 33
Joined: Thu Jan 15, 2009 2:21 pm

Re: Interrupt 13h Question

Post by abachler »

with sub function 0x02h there is a maximum of 255 sectors per call, use subfunction 0x42h if you want to read more per call, as its limit is 65535 per call
User avatar
Love4Boobies
Member
Member
Posts: 2111
Joined: Fri Mar 07, 2008 5:36 pm
Location: Bucharest, Romania

Re: Interrupt 13h Question

Post by Love4Boobies »

Not really. The extended services (AH=42H) only allow you to read 127 sectors at a time.
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
Post Reply