Re: Update IDEJD6

From: Jim Brain (brain_at_jbrain.com)
Date: 2008-04-15 16:45:29

ruud.baltissen@apg.nl wrote:
> The above strengthes my opinion to add some extra RAM when using the
> 16-bits interface. Piggybacking another 2KB SRAM and, to keep it simple,
> only using 1 KB of it, solves the problem. Someone able to add the IDE
> interface should be capable of adding this SRAM as well IMHO. And with a
> bit of luck I can program the FS so that it has at least two extra
> buffers available.
>   
I have no issues with requiring a bit more RAM. 

The way uIEC and sd2iec work is that they use a single 512 byte buffer 
as a scratchpad buffer.  It is then used when one needs to chain a new 
FAT cluster, do a partial write (the case you describe), and any other 
operation which needs a bit of breathing room (mkfs, etc.)

It contains a bit of metadata to know what partition and what LBA block 
it is referring to.  Each read or write then passes in this 
information.  It also contains a dirty flag.  So, if a "seek" is needed 
to complete the operation, the seek function will sync and dump the 
buffer if dirty, replacing it with the new seek location's buffer.

The library deals with the same issue you note: lack of RAM. 

I would add the RAM but not count them as buffers, just reserve some 
dedicated space and use it.

> That's what I'm doing using the CP command, the same one as used in CMD
> drives. @CP:5 for example swithes to partition 5.
>   
True, but you will eventually run out of partitions.  I was looking for 
something to do when that happens.

Jim

       Message was sent through the cbm-hackers mailing list

Archive generated by hypermail pre-2.1.8.