News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

I had a dream....

Started by arnoldemu, 09:42, 04 May 10

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

arnoldemu

I had a dream.. it was simple.

A simple solution which would work for all cpcs, 464, etc.

A hardware interface to plug into the back of cpcs.. or maybe even plug into cassette port, or printer.. or ...?

But the basic interface is the same. A SD card slot, a PIC or ATMega or similar providing some I/O ports and control for sd card. (Just I/O for read/write).

Some rom software for CPC, which patches OS (cas in open/cas in direct etc...) and reads from SD Card. (I would be happy to write this).
SD Card formatted to MS-DOS.

So..?

I was thinking it could be cheap?
it would work for all cpc/plus because no disc interface is needed.. just plug in and enter commands to load.
Ok, it would not work with protected software or anything hitting fdc directly... and then I had another though.. if we really needed this.. why not emulate the fdc controller too?

Is this dream impossible or too expensive?
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

ukmarkh

Don't worry about the cost... make it so  ;)

Actually do worry about the costs, but only if we're talking over £50 - 60.

Ynot.zer0

I like the dream.  very much.


it would help me overcome the limitations of the SymbiFaceII, the custom OS format of BonnyDOS and the limitations of the (lotharek) SD-card reader.


I'd happily purchase a couple of these devices (and would be willing to donate $$$ towards prototype costs, if someone were to take on the hardware construction)

Bryce

Hi Martin Luther,
           we seem to have similar dreams ideas. I've been playing around with a similar project lately, however I was planning to  connect a 2.5in HDD to the expansion port. The idea was to simply connect the data and address bus of the HDD (with a simple address decoder and buffers) directly to the CPC expansion port, plus a dual socket EPROM section to hold the RSXs. Obviously the entire HDD control then needs to be done by the CPC, but it simplifies the Hardware immensly, my initial plan was to avoid using a µProcessor at all on the adapter. I had been looking at using BonnyDOS for the project, but if someone is willing to write a FAT compatible OS, it would have the advantage of being swappable between CPC and PC.
For an SD version, things are slightly more complicated, because the data needs to be converted to be passed to the SD. It means a µP is most likely required, will need further investigation.

Generally though, yes I'm interested and would be willing to take care of the hardware side of things.

Bryce.

Bryce

#4
Hi Arnoldemu,
           I had a very quick look at what the lowest cost solution to connect an SD Card to a CPC would be. Using a low-cost PIC with an SPI bus (PIC16F819 cost about €2.30 here) I could communicate low-level with an SD Card, passing the commands and data on to the CPC using maybe 2 Addresses (8 Bit Data und 8 Bits for Status/Commands). The circuit would be semi-dumb though. It would initialise the SD Card for SPI Mode read/write and from then on just pass the data back and forth. I estimate the entire circuit would cost around €20 to build (not including the EPROMS). Would this be enough for you to base a FAT system on? How much EPROM do you think your code would require?
 
  Bryce.

Gryzor

I like where this is going...

arnoldemu

Quote from: Bryce on 13:07, 04 May 10
Hi Arnoldemu,
           I had a very quick look at what the lowest cost solution to connect an SD Card to a CPC would be. Using a low-cost PIC with an SPI bus (PIC16F819 cost about €2.30 here) I could communicate low-level with an SD Card, passing the commands and data on to the CPC using maybe 2 Addresses (8 Bit Data und 8 Bits for Status/Commands). The circuit would be semi-dumb though. It would initialise the SD Card for SPI Mode read/write and from then on just pass the data back and forth. I estimate the entire circuit would cost around €20 to build (not including the EPROMS). Would this be enough for you to base a FAT system on? How much EPROM do you think your code would require?
 
  Bryce.
This is a great value. It is not a problem that the circuit would be dumb, I don't have a problem with that.

I would like a 16K eprom if possible. 8k would be a push.

I've written a fat reader in the past (source lost), but I'm happy to write a newer one again.

I plan to have the same kind of | commands and interface that amsdos has, but it'll be dos based reading/writing.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Bryce

Ok, I can't promise a circuit tomorrow, but I will look into it within the next few days and get back to you. If it only requires one ROM then that's even better (as far as cost is concerned), BDOS required 3 as far as I can remember. I'll also try to stick with regular thru-pin components (no SMD except for the SD-Card Slot) to keep it "Hobbiest-friendly".
I checked some more component prices, an SD-Card Slot cost €8.50 here!!! Will have to investigate whether there are cheaper sources.

To all: is there any particular address range which I should use (or avoid) to keep things compatible. It's probably best to use an address used by other HDD/Symbiface devices, because the chance of having both connected simultaneously is rather low. Let me know...

Bryce. 

ukmarkh

Please can we design it to sit nicely alongside the CPC or Plus... my Symbiface II is a complete eyesore.

Bryce

When the circuit design is finished, we can work on alternative layouts for individual tastes. It should be a lot smaller than a Symbiface though.

Bryce.

Octoate

I already thought about such an expansion, too and I think that this is a great idea. For the implementation: if you already use a microcontroller, then the microcontroller can handle the FAT implementation. You can then control it via CPC with simple commands (e.g. open file, read x bytes, etc.). I guess that this can speedup the development on the CPC side, because the implementation within the ROM will be much simpler.
--

MacDeath

Personnally, I dream that i have a USB port for my Amstrads.

Working like a USB port on my PC.

How fun would it be to plug a 1gb flash memory key...
Or a modern gamecontroller, Mouse or Wireless keyboard.
Perhaps even internet connection ?

oops.

Ynot.zer0

one dream at a  time   ;)

Devilmarkus

I think FAT16 should be good.
Windows, and also Linux can read/write to it.

So, a FAT16 rom for CPC + IDE interface with SD-Card support would be really cool.
AFAIK sd-cards are formatted in FAT16 as standard.
And sd-cards are cheap today. 4gb ~4-8€
So this would be a great equipment for a CPC!
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

arnoldemu

BTW, My dream didn't include putting dsk files on the sd-card.
Only normal files.

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

gerald

I've started (and never finished :( ) a similar project few years ago, but using a compact flash instead of SD/MMC.
The main reason for using a Compact flash was the erase block size. On CF, it is one block (512byte), on SD this is not fixed and can be bigger than 16K. So write support on SD would require a big buffer for read/modify/write.

Using CF also simplify the design as you only have to deal with a 8bit device using 8 IO addresses. So it's mainly a matter of address decoding and buffers (if you want to support 3.3v CF).


About FAT support :
Support for fat 12/16/32 is equal in complexity. You may still find fat12 on small capacity memory (16Mb).
Support for long name is an other issue when it come to write. But we do not need that on CPC (long name, not write  ;) )


robcfg

I agree the design is much easier with a CF card, but bear in mind that they are increasingly hard to find and they are more expensive than SD cards.


@arnoldemu, I think it would be better that the device supported loading of dsk files (and maybe cdt or sna files) but I know this add a lot of complexity to the design.

Bryce

#17
Although an 8-Bit port on the CF Card may seem like an advantage (I was of this opinion too), the SPI port and addressing offered on all SD/MMC cards (they offer 4 different interface methods!) isn't really that complicated , especially when a lot of µPs from Microchip/Atmel offer a fully programmable SPI port which only requires 3 pins of the µP (Data in, Data Out, Clock), leaving more pins over to control other signals to the CPC. After reading up on SD Cards and their protocols, I changed my mind on which Card I should choose.

µP Embedded FAT: Would mean using a bigger more expensive processor, which would be more or less Symbiface III, the aim of this board should be to minimise and simplify the hardware.

DSK Support: Isn't really necessary if the FAT supports sub-directories, then each directory can be considered a disk (of almost unlimited size), so why bother with DSKs? Or do they offer something more?

Bryce.

Gryzor

€8 for a slot is way too expensive; I guess you could just buy a batch of card readers, say from Deal Extreme and rip them apart for a much lower price :D

As far as formats go, I'd stay clear from FAT16 because who knows how long it survives... plus, I think the limit is 2GB on it? Not great!

arnoldemu

Quote from: Bryce on 22:09, 04 May 10
Although an 8-Bit port on the CF Card may seem like an advantage (I was of this opinion too), the SPI port and addressing offered on all SD/MMC cards (they offer 4 different interface methods!) isn't really that complicated , especially when a lot of µPs from Microchip/Atmel offer a fully programmable SPI port which only requires 3 pins of the µP (Data in, Data Out, Clock), leaving more pins over to control other signals to the CPC. After reading up on SD Cards and their protocols, I changed my mind on which Card I should choose.

µP Embedded FAT: Would mean using a bigger more expensive processor, which would be more or less Symbiface III, the aim of this board should be to minimise and simplify the hardware.

DSK Support: Isn't really necessary if the FAT supports sub-directories, then each directory can be considered a disk (of almost unlimited size), so why bother with DSKs? Or do they offer something more?

Bryce.
Dsk is a dump of a 3" disc.

Note to others: Trying to support that could be a real problem and it would be impossible to support copyprotected ones because of their direct access to the fdc chip.

I was originally thinking just files. As far as fat support, really there is not much in fat12, fat16, fat32, except larger cluster sizes.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Bryce

Most cheap card readers don't have a seperate SD Slot component, it's one big chunk of plastic with 4 or 5 slots, so you'd have to saw off the bit you need. I'm sure there'll be other sources though.

FAT16 is pretty old, and FAT32 is probably a better option and not much different to implement as far as I know.
That's up to Arnoldemu to make that decision though. The cluster sizes on an SD card in SPI mode are fixed at 512bytes. Not sure if this causes an issue or is an advantage? Arnoldemu?

Bryce.

ukmarkh

#21
Quote from: Gryzor on 08:51, 05 May 10
€8 for a slot is way too expensive; I guess you could just buy a batch of card readers, say from Deal Extreme and rip them apart for a much lower price :D

As far as formats go, I'd stay clear from FAT16 because who knows how long it survives... plus, I think the limit is 2GB on it? Not great!

Depends on the OS, 4 GB for FAT16 on a Windows 2000 box. And there are workarounds to get DOS to see a 4GB partition also. I'm not sure FAT32 would work for this project, as its more windows orientated. In fact, I've heard of people formatting a FAT16 partition upto 32 GB? Plus It is very efficient, both in speed and storage, especially on volumes smaller than   256 MB. Did I mention its compatible with almost anything???

  Drive Size
    Default FAT16 Cluster Size
    Default FAT32 Cluster Size
    260 MB–511 MB
    8 KB
    Not supported
    512 MB–1,023 MB
    16 KB
    4 KB
    1,024 MB–2 GB
    32 KB
    4 KB
    2 GB–8 GB
    Not supported
    4 KB
    8 GB–16 GB
    Not supported
    8 KB
    16 GB–32 GB
    Not supported
    16 KB
    > 32 GB
    Not supported
    32 KB



Bryce

Also take into account that those figures are per partition and more than one partition could be created on an SD card. And what's more, how much software actually exists for the CPC? Would you ever fill 32GB, even if you had every game ever released on the drive?

Bryce.

ukmarkh

Quote from: Bryce on 09:49, 05 May 10
Also take into account that those figures are per partition and more than one partition could be created on an SD card. And what's more, how much software actually exists for the CPC? Would you ever fill 32GB, even if you had every game ever released on the drive?

Bryce.

True, listen up peeps, this guy knows his onions.

arnoldemu

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Powered by SMFPacks Menu Editor Mod