Jump to content

Photo

FAT32 XEX loader


327 replies to this topic

#1 candle OFFLINE  

candle

    River Patroller

  • 2,757 posts
  • Location:Lublin, Poland

Posted Sun Jul 17, 2011 5:01 AM

Hi

I felt like putting this into separate thread

currently there are fat32 handling related routines finnished, and i'm starting with some front-end implementation

for now limits are like this:
max 512 entries/directory (including "..") (mainly because of how much memory it consumes - 32 bytes per entry, 16k of memory total)
max 30 chars of long file name is displayed - anything more than this is truncated - this doesn't pose any problem when doing opening such file or directory
only 16 entries are displayed at once on screen - i'm currently using narrow screen for all this

if all goes well, there will be more interactive version in a few hours

Attached Thumbnails

  • side-loader.png


#2 flashjazzcat OFFLINE  

flashjazzcat

    Quadrunner

  • 7,773 posts
  • Location:United Kingdom

Posted Sun Jul 17, 2011 6:05 AM

Nice! :)



#3 rdemming OFFLINE  

rdemming

    Dragonstomper

  • 941 posts
  • Location:The Netherlands, Amstelveen

Posted Sun Jul 17, 2011 6:56 AM

Yeah, long file names :lust:

#4 candle OFFLINE  

candle

    River Patroller

  • Topic Starter
  • 2,757 posts
  • Location:Lublin, Poland

Posted Mon Jul 18, 2011 1:51 AM

here is some WIP - still quite buggy (especially when it comes to changing directory)
any feedback is welcom
currently, only joystick is supported, later i'll add keyboard support

Attached Files



#5 candle OFFLINE  

candle

    River Patroller

  • Topic Starter
  • 2,757 posts
  • Location:Lublin, Poland

Posted Mon Jul 18, 2011 5:07 AM

ok, hopefully bugless version

Attached Files



#6 Philsan ONLINE  

Philsan

    River Patroller

  • 2,700 posts
  • New Orleans Saints Super Bowl XLIV Champions
  • Location:Switzerland

Posted Mon Jul 18, 2011 6:48 AM

Is there a chance to have SIO2SD fast files selection method?

I like SIDE logo but perhaps it should be smaller to leave more space for files.

#7 zaxon OFFLINE  

zaxon

    Chopper Commander

  • 233 posts
  • Location:London ,UK

Posted Mon Jul 18, 2011 6:51 AM



#8 candle OFFLINE  

candle

    River Patroller

  • Topic Starter
  • 2,757 posts
  • Location:Lublin, Poland

Posted Mon Jul 18, 2011 6:59 AM

Philsan, it won't shrink by itself ;)
besides, having 16 entries per page simplifies some functions

Edited by candle, Mon Jul 18, 2011 6:59 AM.


#9 Philsan ONLINE  

Philsan

    River Patroller

  • 2,700 posts
  • New Orleans Saints Super Bowl XLIV Champions
  • Location:Switzerland

Posted Mon Jul 18, 2011 7:26 AM

In zaxon video I see that with left/right you change pages and scroll is very quick.
Therefore I think it's unnecessary to insert SIO2SD fast selection method.
Your loader is already very fast!

#10 candle OFFLINE  

candle

    River Patroller

  • Topic Starter
  • 2,757 posts
  • Location:Lublin, Poland

Posted Mon Jul 18, 2011 7:39 AM

as i wrote, i'll add some keyboard handling, but this is not my goal right now
now its time to actually load something, and iron things a bit
then will be the time for bells and whistlers

#11 zaxon OFFLINE  

zaxon

    Chopper Commander

  • 233 posts
  • Location:London ,UK

Posted Mon Jul 18, 2011 7:44 AM

True :)

#12 a8isa1 OFFLINE  

a8isa1

    Dragonstomper

  • 990 posts

Posted Mon Jul 18, 2011 9:25 AM

Cool project!

I did a quick test in Altirra and then a slightly less quick patching of fat32-myide.xex so that it would work with an internal MyIDE interface.

Not sure I partitioned my CF correctly but all I initally saw on my real 800XL is garbage.

I guessed that your driver wasn't reading my partition table so I mirrored the FAT32 partition to a file (via dd) then wrote the raw data back to the CF. Now it works. I can see the file names on my CF card using my 800XL.

This was a fun exercise!

Please keep up the good work!

-Steve Sheppard

Edited by a8isa1, Mon Jul 18, 2011 9:25 AM.


#13 candle OFFLINE  

candle

    River Patroller

  • Topic Starter
  • 2,757 posts
  • Location:Lublin, Poland

Posted Mon Jul 18, 2011 9:50 AM

if CF card comes formatted as floppy would (no MBR with partition table) then this loader will fail to find FAT32 partition - on my TODO list (rather long list i must say ;) )

#14 flashjazzcat OFFLINE  

flashjazzcat

    Quadrunner

  • 7,773 posts
  • Location:United Kingdom

Posted Wed Jul 20, 2011 10:43 AM

How do we get a container paritition (type $EF) to sit alongside a FAT32 partition on a CF card? I just created two MBR partitions (using special software) on a 2GB CF card: partition one of 512MB, type $EF, and partition 2 of 512MB, FAT32. I copied a bunch of XEX files to the FAT32 partition, but the XEX loader won't find them, since (I later discovered), the partitioning software put the FAT32 paritition inside an extended partition table. It did this because Windows won't allow two primary partitions on a removable device.

This is very relevant to what I'm trying to do with the driver. What's the best way of getting two or more simple, primary partitions in an MBR table?

#15 remowilliams OFFLINE  

remowilliams

    Quadrunner

  • 9,063 posts
  • Location:Detonation Boulevard

Posted Wed Jul 20, 2011 10:49 AM

What's the best way of getting two or more simple, primary partitions in an MBR table?


Linux?

#16 flashjazzcat OFFLINE  

flashjazzcat

    Quadrunner

  • 7,773 posts
  • Location:United Kingdom

Posted Wed Jul 20, 2011 10:51 AM

What's the best way of getting two or more simple, primary partitions in an MBR table?

Linux?

I was thinking of something I can accomplish in about five minutes. ;)

I think I'll boot into Mac OS X...

EDIT: Well - that was every bit as useless as Windows.

Edited by flashjazzcat, Wed Jul 20, 2011 10:59 AM.


#17 kurtm OFFLINE  

kurtm

    Moonsweeper

  • 283 posts
  • Location:Rochester, NY

Posted Wed Jul 20, 2011 11:09 AM

How do we get a container paritition (type $EF) to sit alongside a FAT32 partition on a CF card? I just created two MBR partitions (using special software) on a 2GB CF card: partition one of 512MB, type $EF, and partition 2 of 512MB, FAT32. I copied a bunch of XEX files to the FAT32 partition, but the XEX loader won't find them, since (I later discovered), the partitioning software put the FAT32 paritition inside an extended partition table. It did this because Windows won't allow two primary partitions on a removable device.

This is very relevant to what I'm trying to do with the driver. What's the best way of getting two or more simple, primary partitions in an MBR table?


You can't have two "bootable" partitions. You can do 2 primary partitions. And I even just tried it on my windows desktop to make sure I wasn't talking out of my ass :)

I used a laptop hard drive connected via a USB dock.

#18 flashjazzcat OFFLINE  

flashjazzcat

    Quadrunner

  • 7,773 posts
  • Location:United Kingdom

Posted Wed Jul 20, 2011 11:15 AM

You can't have two "bootable" partitions. You can do 2 primary partitions. And I even just tried it on my windows desktop to make sure I wasn't talking out of my ass :)

I used a laptop hard drive connected via a USB dock.

I don't want two bootable partitions (it makes no sense to do so). 2 primary partitions is what I'm after, but the cards don't seem to be falling right for me.

Laptop hard drives connected via USB don't (AFAIK) have the removable media bit set in their hardware ID, so it's possible to partition them. Not so with USB drives and CF cards. Even the crappy third-party app I downloaded won't contravene Window's refusal to create two primary partitions.

In any case, FDISK will write the MBR on the Atari without any of this fuss, but I wanted a sample table to compare it with.

Edited by flashjazzcat, Wed Jul 20, 2011 11:16 AM.


#19 candle OFFLINE  

candle

    River Patroller

  • Topic Starter
  • 2,757 posts
  • Location:Lublin, Poland

Posted Wed Jul 20, 2011 11:15 AM

its 7:15pm and i'm still working on my work assigment - sorry guys
on my todo for today is loader (that means its load something instead of display directory) and i'll add support for that damn extended partition ;)

#20 flashjazzcat OFFLINE  

flashjazzcat

    Quadrunner

  • 7,773 posts
  • Location:United Kingdom

Posted Wed Jul 20, 2011 11:19 AM

Thanks! Note my previous comment: FDISK will write MBR with two primary partitions, but we also have to deal with the situation of a pre-partitioned card (in which case I'll simply populate an unused slot in the MBR table with the Atari partition). I guess this means FDISK should also observe the damned extended partitions...

#21 kurtm OFFLINE  

kurtm

    Moonsweeper

  • 283 posts
  • Location:Rochester, NY

Posted Wed Jul 20, 2011 11:31 AM

I don't want two bootable partitions (it makes no sense to do so). 2 primary partitions is what I'm after, but the cards don't seem to be falling right for me.

Laptop hard drives connected via USB don't (AFAIK) have the removable media bit set in their hardware ID, so it's possible to partition them. Not so with USB drives and CF cards. Even the crappy third-party app I downloaded won't contravene Window's refusal to create two primary partitions.

In any case, FDISK will write the MBR on the Atari without any of this fuss, but I wanted a sample table to compare it with.


I dug up a CF reader and found windows being much less compliant :)

One thing you can try is a linux install disk (or live CD). I've found linux's fdisk (or cfdisk) to be helpful for similar situations in the past.

#22 candle OFFLINE  

candle

    River Patroller

  • Topic Starter
  • 2,757 posts
  • Location:Lublin, Poland

Posted Wed Jul 20, 2011 11:36 AM

turn your IM on :)

#23 Stephen OFFLINE  

Stephen

    River Patroller

  • 4,448 posts
  • A8 Gear Head
  • Location:Akron, Ohio

Posted Wed Jul 20, 2011 3:05 PM

What's the best way of getting two or more simple, primary partitions in an MBR table?


Linux?

And for the remaining 95% of the users? :P

#24 kurtm OFFLINE  

kurtm

    Moonsweeper

  • 283 posts
  • Location:Rochester, NY

Posted Wed Jul 20, 2011 3:10 PM


What's the best way of getting two or more simple, primary partitions in an MBR table?


Linux?

And for the remaining 95% of the users? :P


OpenBSD :P

#25 candle OFFLINE  

candle

    River Patroller

  • Topic Starter
  • 2,757 posts
  • Location:Lublin, Poland

Posted Wed Jul 20, 2011 3:14 PM



What's the best way of getting two or more simple, primary partitions in an MBR table?


Linux?

And for the remaining 95% of the users? :P


OpenBSD :P


i wanted to write "Linux for dummies" ;)

but seriously, this is version with some bug fixes, and support for extended partition table

Attached Files






0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users