I am experimenting
with the eZ80 (eZ80F92) processor within my RC2014 platform.
I am having issues
with the compact flash module. I only have Spencer’s older V1
module, without the additional delays for RD/WR – not sure if that
will help or not.
My understanding is
that the non compliance timing issue with CF module, is that the time
between IORQ(CF chip-select) and the RD/WR lines when they activate,
is way to short to be compliant:
Extracted from the
analysis at: https://www.vtsys.pl/interface-compact-flash/
As per Tadeuzd Pycio’s explanation, there needs to be at least 70ns between CS and IORD.
In my design, I have
mapped the eZ80 CS2 line for IO to the RC2014 bus’s IORQ line.
This line only activates when the eZ80 wants to access an external
I/O device. I have also configured more than sufficient wait states
and bus-cycle counts. Its configured to drive the bus in Z80
compatible mode.
One interesting
aspect of using the CS2 as the signal for IORQ, is the fact that this
line goes low way before RD/WR signals go low.
Given this delay,
the effective duration between the Compact flash’s CS and IORD is
well beyond the 70ns minimum. Also the lines are both held low for
more than 160ns.
But it don't work!
I seem to get garbled values back.
I am wondering if
the issue I have, is as the signals transition to high state. For
the eZ80 configuration, both of these lines go high at the same time.
No delay at all.
I think there is
a subtle difference between Z80 and eZ80, in the timing of the
control signals when they transition from low to high. For the eZ80
they seem to go high at the same time, but I think for the Z80 there
is a small delay. Not sure though?
I can keep
experimenting with this, but I do wonder if anyone here as some
insights that might help me – I could be going down the wrong path
with my analysis – and completely misunderstood something (I am
certainly no expect here – just an amateur for the last few years)
Cheers
Dean
PS: project is on hackaday.io – but they seem to be having a major outage this weekend.
Wayne: I believe what you're interested in looking at is the SET FEATURES command within the ATA specifications. After doing an IDENTIFY, you can then find the highest PIO and DMA rates supported by the ATA device then use SET FEATURES to update the PIO & DMA modes. Note that different devices on the same channel may have different maximum modes.
The theory:
All commands must be sent in PIO0 always
Data transfer rates may be negotiated by set features commands (and
reset on an error reset) after having checked they are available using
IDENTIFY (if IDENTIFY fails as it may do for ATA-1 you have no set
features)
The reality
It's really complicated and pointless doing all the exact PIO timings
in modern hardware when you can build a device that just accepts the
signals anywhere between PIO 0 and 5, so whilst old stuff cares,
random CF cards generally do not. DMA modes are a different kettle of
fish, and UDMA is quite different.
--
You received this message because you are subscribed to the Google Groups "retro-comp" group.
To unsubscribe from this group and stop receiving emails from it, send an email to retro-comp+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/retro-comp/c8ab50b0-a745-41a5-9e37-12ce954a0da7n%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/retro-comp/00e7a6f8-c1c8-481d-bcf4-91c262353683n%40googlegroups.com.
It seems that the question of mode of operation is a contractual concept. Not every card supports the SET FEATUERES 0x03 command, and there are some CF cards that operate in higher PIO modes without supporting the /IORDY signal (e.g. SunDisk), although the specification for PIO modes 3 and above requires this, correctly operating with timings compatible with higher PIO modes. I don't know how it used to be implemented, but I suspect that the maximum PIO mode and its timing that is included in IDENTIFY DEVICE is always available, regardless of the mode set in SET FEATURES.
--
You received this message because you are subscribed to the Google Groups "retro-comp" group.
To unsubscribe from this group and stop receiving emails from it, send an email to retro-comp+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/retro-comp/cf59a310-ec1c-4759-ac85-a4935986a25cn%40googlegroups.com.