> > Phillip wrote:
> > Previously (2.7) the CP/M receive direction would fill RAM (approx 54kB) without showing a NAK and then write to disk and repeat, but now (2.9) it only does a few kB before showing repeated NAKs and is very choppy and slow. I replicate this on the same machine receiving the same file, so the only change is xmodem.
> > Any thoughts on what has changed which might cause this different behaviour?
>Tony Nicholson wrote:
> I found that XMODEM sometimes does a NAK if the CP/M file writing takes too long (the timeout settings are hard to get right on faster Z80/Z280 systems). The workaround for me was to reduce the amount of in-memory buffering. Version 2.9 as a new setting /K that allows you to select this. I put /K20 in my XMODEM.CFG file to limit it to 20Kbytes on my problematic system.
Hi Tony, thanks for the hints, but it seems that I've got a different issue.
Firstly, I've isolated it down to just z80/SIO/v2.9. Both z80/ACIA and 8085/ACIA are working as expected. And with the Z80/SIO the v2.7 is working perfectly too.
I've got the code from both v2.7 and v2.9 side by side, and I'm trying to decipher the new code flow. There have been many substantial changes.
I've also spent some time with the logic analyser and traces. The failing process begins when is a block is received and rather than being ACKed(0x06) it is NAKed (0x15). Perhaps noise, but I doubt that. It will be something programmatic causing the CRC to fail (or something). The sender then repeats the block but the receiver then goes into a long time out, before the receiver sends NAK again. At this point the sender then repeats the block a second time the receiver ACKs it, and things continue normally.
So, I'm thinking to try to reduce the timeout before sending that second NAK, to speed up reinitialisation of transmission. But that is a work around.
What I need to do is to find out what is causing the block errors in the first place (given the triage above).