Hi,
I got a problem with my bootloader problem. I am trying to load a 2nd stage bootloader. However, it seems that it only works if the size of 2nd stage boot loader in less than 512. So basically it just load 1 sector. I couldnt find where it goes wrong, maybe you could help out.
BootLoader Problem
BootLoader Problem
- Attachments
-
- Boot4.zip
- (3.96 KiB) Downloaded 81 times
-
- Member
- Posts: 195
- Joined: Tue Aug 26, 2008 11:24 am
- GitHub: https://github.com/sebihepp
Re: BootLoader Problem
Hi,
I see one mistake:
Use "and" instead of "add".
Greetings Sebihepp
I see one mistake:
Code: Select all
.EVEN_CLUSTER:
add dx, 0000111111111111b ; remove the top 4 bits (significant)
jmp .NEXT_CLUSTER
Greetings Sebihepp
- Firestryke31
- Member
- Posts: 550
- Joined: Sat Nov 29, 2008 1:07 pm
- Location: Throw a dart at central Texas
- Contact:
Re: BootLoader Problem
Just from seeing that I can offer a quick and simple optimization:
Code: Select all
.EVEN_CLUSTER:
;; remove top four bits by shifting them out
shl dx, 4
;; fall through to the odd cluster code, which
;; unshifts the above and by itself handles
;; the odd clusters. Saves a jump!
.ODD_CLUSTER:
shr dx, 4
Last edited by Firestryke31 on Wed Mar 25, 2009 3:01 pm, edited 1 time in total.
Owner of Fawkes Software.
Wierd Al wrote: You think your Commodore 64 is really neato,
What kind of chip you got in there, a Dorito?
Re: BootLoader Problem
thanks so much guy, will try it at home