CF card makes RC2014 crazy

496 views
Skip to first unread message

Olev Toom

unread,
Oct 30, 2023, 3:43:49 PM10/30/23
to RC2014-Z80

Hello all,

recently I ordered some CF cards from Aliexpress, because I wanted to make some backups and/or different versions of the file system.

I have 2 machines: a Pro from 2020, and a Zed from 2022 which runs ROMWBW.

Because the Zed is nearer to me, I first copied the current CF card to a new one (I always use Win32Diskimage). The copy was successful, but when I inserted the new CF, the machine didn’t start (it seemingly went no further than the Picoterm message).

Next day I did similar procedure with the Pro. Again, copying the original CF card went easily, and, again, the Pro didn’t get up. But there I had a logical analyzer connected, and it shows that the machine isn’t dead but some program is running (see the picture). Maybe it is busy digging bitcoins :P

http://valorem.ee/pildid/logic.jpg

Searching the forum, I found some issues related to CF card, but nothing like this.

The chinese CF looks like this:

http://valorem.ee/pildid/transcend.jpg

Any help is appreciated, including any recommendations what I should investigate next.

Yours

Olev Toom

Spencer Owen

unread,
Oct 30, 2023, 4:11:11 PM10/30/23
to rc201...@googlegroups.com

Hi Olev,

What revision of the Compact Flash module do you have?  I suspect from those dates that it might be the v1.3 or earlier.  These modules were fussy about which cards work with them. I sometimes had to try cards from different vendors to find reliable ones.

There was a revised circuit from Tadeusz Pycio that improved things, and this has been incorporated in to v2.1 onwards, which gives much better compatibility with almost all compact flash cards. See https://rc2014.co.uk/modules/compact-flash-module/ for more details and a link to Tadeusz's findings.

However, there are still some Chinese cards which I have found that just don't play well with anything.  So it may well be that the card is just dodgy.


Spencer

--
You received this message because you are subscribed to the Google Groups "RC2014-Z80" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rc2014-z80+...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/rc2014-z80/ab02824a-5cf2-4d2f-9f56-da241d97a538n%40googlegroups.com.

Olev Toom

unread,
Nov 1, 2023, 10:37:21 AM11/1/23
to rc201...@googlegroups.com
Hello!
Thank you, Spencer! Yes, my cards are of some early version (only 1 chip to the left of CF socket). I think I'll order a version 2 card and see what happens.
So far, no more questions.

olev


Virus-free.www.avg.com

Olev Toom

unread,
Nov 1, 2023, 10:59:01 AM11/1/23
to rc201...@googlegroups.com
... but, having seen the shipping costs, I will think  a bit...
olev


Virus-free.www.avg.com

Spencer Owen

unread,
Nov 2, 2023, 7:29:13 AM11/2/23
to rc201...@googlegroups.com

Hi Olev,

Yeah, unfortunately to comply with EU tax laws, using DHL is the cheapest and easiest way.  However, for single items or low value orders it is prohibitively expensive.  For big orders shipping cost do not increase, so relatively speaking works out cheaper.  But I do understand.

Spencer

Mark T

unread,
Nov 2, 2023, 6:32:37 PM11/2/23
to RC2014-Z80
If you think you can manage the compact flash connector soldering you might try and source the parts and order a set of pcbs from china.

It might take five attempts to solder that connector without melting the plastic:)

Bill Shen

unread,
Nov 2, 2023, 8:27:54 PM11/2/23
to RC2014-Z80
Can you take a picture of your board?  A 100 ohm/100pF resistor capacitor filter is the best solution, but maybe difficult to solder.  Sometimes a 100pF capacitor across the CF read line and nearby ground can do wonder.
Bill

Olev Toom

unread,
Nov 5, 2023, 1:12:36 PM11/5/23
to rc201...@googlegroups.com
Hello again, and thanks for help!

Bill -- there are the photos:


Mark -- I have done some soldering of SMD components so that would not be the biggest problem. Also the parts are not hard to obtain. But I think the PCB files (Gerber or smth) are not public domain.

Best,
olev



Virus-free.www.avg.com

Mark T

unread,
Nov 5, 2023, 1:27:14 PM11/5/23
to RC2014-Z80
Tadeusz’s github has license CC BY-NC 4.0 and includes a zip file which appears to be gerber files for JLCPCB.

Olev Toom

unread,
Nov 5, 2023, 2:40:30 PM11/5/23
to rc201...@googlegroups.com
Thank you, Mark! I'll investigate.
olev

Virus-free.www.avg.com

Bill Shen

unread,
Nov 5, 2023, 9:02:54 PM11/5/23
to RC2014-Z80
So you have version 1.1 of CF module which does not have the 100ohm/100pF filter for /RD line.  Looking at the CF schematic on RC2014.co.uk, you see there is a 100ohm resistor (R6) and 100pF capacitor (C2) on /RD of the version 1.2 schematic.  The 100ohm/100pF filter increases the compatibility with more brands of CF disks.  Even a 100pF capacitor across /RD and ground is helpful although it may load down the /RD bus signal.  In the attached picture the white arrow points where the /RD connects to CF adapter.  You can see a vertical trace runs directly from CF adapter to /RD of RC2014 bus.  Next to the trace is the ground pad so if you can do fine-pitch soldering, you may want to scrap away some solder mask and solder one terminal of a 100pF capacitor to the /RD trace and other terminal of the capacitor to the ground pad marked 'GND'.  If it is up to me, I would solder a SMT 100pF capacitor across the /RD trace and ground pad, then cut the trace and bridge the cut with a SMT 100 ohm resistor thus forming the 100ohm/100pF filter.
  Bill
RC2014_CF_ver1_1_top.jpg

Olev Toom

unread,
Nov 6, 2023, 8:43:21 AM11/6/23
to rc201...@googlegroups.com
Bad luck... the other module I have is ver. 1.3 and it has the RC filter. But the "Transcend" CF card doesn't work on this either.
olev


Virus-free.www.avg.com

You received this message because you are subscribed to a topic in the Google Groups "RC2014-Z80" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/rc2014-z80/EYQ7AGomanw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to rc2014-z80+...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/rc2014-z80/8053d520-c775-440e-ac4e-84f3449f9ad7n%40googlegroups.com.

Spencer Owen

unread,
Nov 6, 2023, 9:15:50 AM11/6/23
to rc201...@googlegroups.com
If it is a Transcend branded card then that is even more bad news.  Even with the v2.1 board that has Tadeuszs modifications.

The issue with most cards seems to be timing related and either the RC filter or the latched chip select helps a lot.  However, I have tested a lot of Transcend cards, and cannot get any of them to work.  My current assumption is that they only work in 16 bit more, but not 8 bit mode.  It is just an assumption though, and I am not sure how I can prove this.

Spencer

Tadeusz Pycio

unread,
Nov 6, 2023, 9:52:46 AM11/6/23
to RC2014-Z80
Transced's Compact Flash cards with symbols TS32M~1GCF80 will not operate correctly on CF v2.x modules at a system clock of 7.37MHz. At higher bus frequencies >15MHz they will work. It is likely that their controller was prepared for UDMA modes, as their manufacturer offers the same models of TS32M~1GCF80-P cards which are prepared for PIO mode and should work reliably (I have not tested this).

Bill Shen

unread,
Nov 6, 2023, 9:57:21 AM11/6/23
to RC2014-Z80
The 100ohm/100pF RC filter is the first patch I'd apply and it will help with many brands of CF disks, but not every brands.  There are two more issues and some brands of CF disk are more sensitive than others:
1. Assertion of CF read and CF write (setup time)
2. Negation of CF write (hold time)

To help with 1), setup time, CF's chip select should not be qualified with /IORQ so CF chipselect is stable when CF read or CF write is is asserted.  But because CF chipselect is not qualified with /IORQ, /RD and /WR needs to be qualified with /IORQ to avoid spurious CF read/write.  So that's additional logic, usually two OR gates is sufficient.

2) is generally not a problem with Zx80 because the timing of /RD and /WR.  It is an issue with 68K and 6502 CF interfaces.

These were various brands of CF disk I used to test my designs.  Cisco brand seems most stable.  Transcend CF will work with appropriate setup time.

Just read Tadeusz's comment with Transcend's TM32M~1GCF80.  I've not tested it on my setup.  I'll go looking for one to buy.
  Bill
DSC_71640107.jpg

Bill Shen

unread,
Nov 6, 2023, 11:21:33 AM11/6/23
to RC2014-Z80
I like to test ver 1.1 RC2014 CF board against my batch of CF disks then modify it and re-test.  Anyone in USA who is interested in this experiment, please PM me.  I'll do the modification and testing free and I'll pay the shipping back to you, but I ask you to pay for the shipping to me.  No money is involved this way.  Hopefully you'll received back a modified CF board that can work with a larger number of CF disks.  I live in New Mexico, USA.
  Bill

Olev Toom

unread,
Nov 6, 2023, 1:52:54 PM11/6/23
to rc201...@googlegroups.com
If anybody wants "my" Transcend CF card for testing, please let me know.
olev


Virus-free.www.avg.com

--
You received this message because you are subscribed to the Google Groups "RC2014-Z80" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rc2014-z80+...@googlegroups.com.

Alan Cox

unread,
Nov 6, 2023, 2:36:01 PM11/6/23
to rc201...@googlegroups.com
On Mon, 6 Nov 2023 at 14:15, Spencer Owen <spe...@sowen.com> wrote:
If it is a Transcend branded card then that is even more bad news.  Even with the v2.1 board that has Tadeuszs modifications.

The issue with most cards seems to be timing related and either the RC filter or the latched chip select helps a lot.  However, I have tested a lot of Transcend cards, and cannot get any of them to work.  My current assumption is that they only work in 16 bit more, but not 8 bit mode.  It is just an assumption though, and I am not sure how I can prove this.

Plug it into a PPIDE card where it does work. Send it the command to do 8bit it will reply indicating the command was executed with no error, and it will then work fine if you then use 8bit transfers. All CF cards support 8bit mode. It's a requirement for the CF branding mark. PATA devices other than non CF devices generally do not but you can still get half capacity from them by pretending they have 256 byte sectors.

The Cisco branding is a problem because Cisco branded a range of third party cards that were compatible with their router products and not all work with the RC2014 CF. Also at this point however it's fairly useless because there are people putting fake Cisco labelling on any old small CF card to sell it.

Later CF devices expect very good power delivery, very clean edges and are sensitive to glitches a couple of nanoseconds wide, and to any incorrect timings. The CF adapter is a hack, a neat hack but a hack. Even more unfortunately CRC checking across entire transactions only arrived in SATA so corruption is often silent.

Alan

Alan Cox

unread,
Nov 6, 2023, 2:46:08 PM11/6/23
to rc201...@googlegroups.com
On Mon, 6 Nov 2023 at 14:52, Tadeusz Pycio <ta...@wp.pl> wrote:
>
> Transced's Compact Flash cards with symbols TS32M~1GCF80 will not operate correctly on CF v2.x modules at a system clock of 7.37MHz. At higher bus frequencies >15MHz they will work. It is likely that their controller was prepared for UDMA modes, as their manufacturer offers the same models of TS32M~1GCF80-P cards which are prepared for PIO mode and should work reliably (I have not tested this).

I have never seen the -P in the real world, however I imagine it is
just firmware tweaked to not negotiate higher modes. Hard to believe
anyone would fab a special version. Even then all the commands and
initial negotiating always happens at PIO0 (including the identify
transfer which is the same timing as a disk read).

Tadeusz Pycio

unread,
Nov 6, 2023, 4:12:13 PM11/6/23
to RC2014-Z80
I obtained the information from this document. What is puzzling is why these cards work correctly with Z1...@18.43MHz and not on Z...@7.37MHz, regardless of the CF module version used (I just checked the operation on CF module v1.0, without any mods).
TSxMCF80.pdf

Tadeusz Pycio

unread,
Nov 6, 2023, 4:49:36 PM11/6/23
to RC2014-Z80
Update: It's been a while since I checked the Transced card (TS1GCF80) and it turns out that it runs at 7.37MHz on my buffered CF module and on v2.0 with time waveform patches. With module version 1.0 the copying failed. I remember there was a problem with this card - but I need to find the thread where I noted this, as well as Spencer reporting that these cards were not working. Suddenly it decided to work properly?! I checked under RomWBW 3.2.1 by copying the contents of one disk to another.

Bill Shen

unread,
Nov 6, 2023, 10:36:54 PM11/6/23
to RC2014-Z80
Looking at the TSxMCF80 datasheet I realized I have several disks all along.  The one I have is TS128MCF80 which is in the photo of CF disks I have (middle of third row).  I ran tests on it (disk-to-disk PIP with verify) on several different systems at 7.37MHz, 9.22MHz, 14.7MHz, and 22MHz and it worked at these CPU frequencies.  It did failed on Z80all which is 25.175MHz; I will look into that.
  Bill

Olev Toom

unread,
Nov 27, 2023, 3:32:35 PM11/27/23
to rc201...@googlegroups.com
Hello again!

The reason for the radio silence was 1) that I was waiting for Mr. Cousins' CF module SC145 and 2) that life got in the way, not allowing me to solder it together for a while.
Now it works, and with it the "Transcend" and "Sandisk" CF cards came to life. The latter behaved quite comically with version 1.3 of the CF module.
When with a working CF card the directory of one drive was like this:

image.png

then "Sandisk" showed something different:

image.png

(the contents of both cards were, of course, identical).

If anyone is interested, I read the following information from the cards:
"Sandisk":
Serial: YJ2J10Y0300M007xxxx
Firmware: 0V0627 9
Model: PWFC21M8C-SI I
size: 65 011 713

"Transcend":
Serial: 02014091 FC01xxxx
Firmware: 02012020
Model: RTNACSNE D
size: 63 479 809

Anyway, for me the case is closed. Thank you all for help!

olev


Virus-free.www.avg.com

--
You received this message because you are subscribed to the Google Groups "RC2014-Z80" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rc2014-z80+...@googlegroups.com.

Bill Shen

unread,
Nov 28, 2023, 12:27:08 AM11/28/23
to RC2014-Z80
Just want to make sure I understand you correctly:  you are saying Sandisk and Transcend are displaying the directories correctly with Steve Cousins SC145?  The screenshot of directories dropping every other characters was from previous non-working CF board?  Have you tried file copy with verify?  It is the best way of checking CF reading and writing correctly.

To read the disk ID correctly, you need to swap byte order, so 
Model: RTNACSNE D  With bytes swapped reads TRANSCEND

  Bill

Olev Toom

unread,
Nov 28, 2023, 4:24:32 AM11/28/23
to rc201...@googlegroups.com
Hello all!
Bill:
Yes, you understood correctly: with SC145 both cards work (not only displaying directories but doing all read-write operations correctly so far I tried). The abnormal screenshot was displayed when the "Sandisk" card was in the "Compact Flash Storage" module (no difference if this was ver. 1.1 or ver. 1.3).
I use Win32diskimager to work with CF cards on PC, and do Verify every time I write some CF. (No errors so far). And this character-dropping "Sandisk" started to work normally in SC145.
olev
P.S. Thank you for the byte-swap tip!
olev
 

Virus-free.www.avg.com

Bill Shen

unread,
Nov 28, 2023, 11:58:26 AM11/28/23
to RC2014-Z80
Good to hear SC145 can handle the more difficult CF disks successfully.  That design should handle most, if not all, CF disks (new or used) you can buy from eBay.
  Bill

Tadeusz Pycio

unread,
Nov 28, 2023, 2:45:29 PM11/28/23
to RC2014-Z80
I think there will be some unsupported cards. I think I found a configuration that doesn't want to work with this type of CF module. So far this is unconfirmed, so I am not reporting this problem. However, if anyone has a Z80 configuration, a 16C450/550 UART and a CF module built to my design, please check that the cards are detected under RomWBW 3.2.1 (I'm not ruling out software either, here Wayne would have to comment on whether this is a possibility, but it's unlikely).

Wayne Warthen

unread,
Nov 28, 2023, 3:01:10 PM11/28/23
to RC2014-Z80
On Tuesday, November 28, 2023 at 11:45:29 AM UTC-8 Tadeusz Pycio wrote:
I think there will be some unsupported cards. I think I found a configuration that doesn't want to work with this type of CF module. So far this is unconfirmed, so I am not reporting this problem. However, if anyone has a Z80 configuration, a 16C450/550 UART and a CF module built to my design, please check that the cards are detected under RomWBW 3.2.1 (I'm not ruling out software either, here Wayne would have to comment on whether this is a possibility, but it's unlikely).

I agree with Tadeusz that it is "unlikely" to be a software issue in RomWBW because I have investigated and resolved all incompatibilities reported.  No CF Card software issues have been identified in a very long time.  However, it cannot be ruled out and I am always happy to research any examples where it may be software.

Thanks,

Wayne 

Tadeusz Pycio

unread,
Nov 28, 2023, 3:44:50 PM11/28/23
to RC2014-Z80
I probably misspoke, my Tarzan-English sometimes plays tricks ;)
The existence of a bug in RomWBW is at the last place in my suspicions, especially since this configuration with other CF modules works. Here, some timing dependencies on the bus must play a key role and it will require a deeper analysis of what causes these crashes. It is interesting that this manifests itself only with the 16C450/550 UART. I will check this when I have more time, as it requires more measurement equipment.

Bill Shen

unread,
Nov 28, 2023, 4:03:10 PM11/28/23
to RC2014-Z80
What brand of CF is it?  Adjusting supply voltage sometimes can make the problem show up or go away.  If it is noise, higher voltage may make it worse.  If it is insufficient access time, higher voltage may fix it.
  Bill

Tadeusz Pycio

unread,
Nov 28, 2023, 4:26:55 PM11/28/23
to RC2014-Z80
At the moment I'm still checking the Transcend 1GB cards (the ones with DMA) as they have unexpectedly started working on two different models of CF modules, which is a complete surprise to me, I had previously treated them as unusable. I hope to find some time at the weekend, as the timing analysis of the bus requires a logic state analyser and oscilloscope to be correctly connected, and this takes a lot of time. It is possible that I have made some mistake in my Z80+UART module that I do not see.

cpu16450.jpg
Reply all
Reply to author
Forward
0 new messages