!FTPc triggering system hang? (+ serial TCP/IP on A3000)

chat about arc/risc pc gaming & RISC OS software here (NOT the core OS!)Related forum: adventures


Post Reply
Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

!FTPc triggering system hang? (+ serial TCP/IP on A3000)

Post by Badwolf » Fri Oct 25, 2019 10:33 pm

I've had a snoop around and can't see anyone else reporting a similar issue to me -- in fact everyone seems to use FTPc as the FTP client of choice so:

Can anyone tell me what I'm doing wrong?

System is a 4Mb ARM2 A3000 under RISCOS 3.11 with Uniboot31, Acorn internet and working PPP connection.

Running !FTPc on the unmodified above system just complains about an out of date CallAWSI module. Finding PlingSystem.zip and RMLoading CallASWI, Clib and FPEmulator (the modules !FTPc will complain about) results in a complete system hang.

Installing these to System:Modules doesn't make any difference (and I've had the entire boot process hang, when trying a bulk upgrade from PlingSystem, so more cautiously loading them on demand for now) and bypassing !Boot entirely and loading only the bare minimums to get things running (ie. not even with !Internet running) still results in complete system lockup.

Am I doing something completely wrong? Is !FTPc not ARM2 compatible? Is PlingSystem the culprit?

Thoroughly confused now as even !sFTP, which was working, is now giving an 'undefined instruction at &19919A0' error now! Telnet and ping working fine. I've gone through more Uniboot installations (including the full one from the !Browse CD) and !Internet reconfigurations than you could shake a stick at and have hit a dead end.

Advice appreciated.

Cheers,

BW.
Last edited by Badwolf on Mon Nov 04, 2019 2:27 pm, edited 1 time in total.

User avatar
danielj
Posts: 7560
Joined: Thu Oct 02, 2008 4:51 pm
Location: Manchester
Contact:

Re: !FTPc triggering system hang?

Post by danielj » Sat Oct 26, 2019 7:12 am

I've had it working happily on 3.11 on my A3020 (not set up at the moment) - as to where the modules should go in UniBoot, this should help: http://www.riscos.org/support/boot.html

It definitely does work on ARM2(50)/ARM3.

d.

sirbod
Posts: 1020
Joined: Mon Apr 09, 2012 8:44 am
Location: Essex
Contact:

Re: !FTPc triggering system hang?

Post by sirbod » Sat Oct 26, 2019 7:29 am

I know NetTime was causing issues at one point, I don't know if that was resolved.

Can you pin it down to one specific Module?

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang?

Post by Badwolf » Tue Oct 29, 2019 9:48 pm

sirbod wrote:
Sat Oct 26, 2019 7:29 am
I know NetTime was causing issues at one point, I don't know if that was resolved.

Can you pin it down to one specific Module?
Hiya,

I'm a bit of a RISCOS n00b, so I'm not really sure how to debug this -- certainly not sure how I'd identify the module causing the problems.

The simplest thing I've tried is to copy into the !FTPc bundle the modules it asks for (in this case the three mentioned above), then reboot without loading Uniboot (holding down ESC). There ought to be no soft loaded modules at this point. I'll then manually load the three modules it demands and try running the !FTPc package either from the GUI or command line.

I get no feedback before a full on system freeze that requires a hard reset.

Perhaps one of you kind folks who *do* have it working under 3.11 could let me have copies of your FPEmulator, CLib and CallASWI modules to rule out it being a duff source of those?

Many thanks,

BW.

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang?

Post by Badwolf » Thu Oct 31, 2019 10:36 am

So assuming this is something related to my Uniboot configuration (of which I now have five variants zipped up!) I decided to try the "Fancyboot" (http://www.snowstone.org.uk/riscos/docu ... yboot.html).

This is obviously aimed at bigger machines than the A3000 as it can't properly boot up, running out of module memory and requiring me to kill processes to get to the desktop. HOWEVER, it did let me run !FTPc without hanging. Obviously useless as the TCP/IP connection isn't up, but progress of sorts.

I went back to Uniboot31 (http://www.riscos.com/ftp_space/310/index.htm) but copying over matching modules from the Fancyboot install (plus the two it doesn't provide -- Clib and FPEmulator): hard system lockup again.

I'm completely puzzled now. Perhaps it's something else that's (not?) running in Uniboot31 that is(n't) in Fancy?

Infuriating!

BW.

User avatar
IanS
Posts: 1039
Joined: Mon Aug 31, 2009 6:02 pm
Contact:

Re: !FTPc triggering system hang?

Post by IanS » Thu Oct 31, 2019 10:11 pm

Not sure how useful this is, but I'll post it anyway.

This is a (fairly) minimum setup of !Scrap !System !Internet and !FTPc (probably not the latest version). !Internet only has drivers for the Ether3 card I'm using. But I can boot and run this with nothing else. It's a bit maunal, open a filer window, double click on !Internet, then double click on !FTPc.

I've even managed to run this from a floppy. So nothing else should be required and all the modules work together.

I tend not to use Uniboot on RISC OS 3.11 machine, it's a bit too much of a bloat.
Attachments
ftpmin.zip
(361.01 KiB) Downloaded 4 times

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang?

Post by Badwolf » Fri Nov 01, 2019 10:39 am

IanS wrote:
Thu Oct 31, 2019 10:11 pm
I tend not to use Uniboot on RISC OS 3.11 machine, it's a bit too much of a bloat.
Ian,

This is great. Many thanks. I'll give that a go tonight.

I'm coming around to that point of view having spent another evening enabling and disabling different parts of Uniboot only to watch things fail in variously different guises!

The piece de resistance for me yesterday was trying Paul Vernon's Uniboot2 (https://www.retro-kit.co.uk/page.cfm/co ... r-RISC-OS/) package which purports to do exactly what I want -- run !FTPc on an old Archie with a fairly targetted set of modules -- and it not even being able to boot to the pinboard!

I'm starting to worry about a hardware fault now. I upgraded this to 4Mb and build a small RAM test program that seemed to give it the all clear, but now I'm wondering if I donated the old 1 meg expansion to the RiscOS Show's charity stall a little prematurely!

Will give these a try and report back. You're a gent.

BW.

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang?

Post by Badwolf » Fri Nov 01, 2019 10:26 pm

Well I'll be jiggered.

Thanks, Ian. It turns out it wasn't my Uniboot settings at all! Your copy of !FTPc works just fine with what I had before and indeed with your minimal installation.

Looks like something changed with !FTPc itself between this version (1.37) and the two downloadable ones on the Iconbar website (1.54 and 1.48). For starters this one doesn't complain about my CallAWSI version, nor does it demand Clib and FPEmulator. I surmise therefore that some of those newer modules are the culprits. Perhaps not 26-bit compatible?

Now onto phase two of the work: debugging my serial connection. High percentage of dropped packets with both the !Internet PPP driver and the shareware one. I reckon I must have wired or configured my flow control lines wonky.

Thanks again, Ian. :)

BW

User avatar
IanS
Posts: 1039
Joined: Mon Aug 31, 2009 6:02 pm
Contact:

Re: !FTPc triggering system hang?

Post by IanS » Fri Nov 01, 2019 10:41 pm

Badwolf wrote:
Fri Nov 01, 2019 10:26 pm
Thanks, Ian. It turns out it wasn't my Uniboot settings at all! Your copy of !FTPc works just fine with what I had before and indeed with your minimal installation.
Excellent news, more and more stuff is not really checked that it still works on 3.11. I try and stick with what works, and only upgrade when I've got a backup to go back to.

How are you doing the PPP serial connection. What is on the other end? What baud rate are you trying to do. The Arc serial ports were not noted for reliably working at high speeds. High speed serial cards were a popular upgrade when trying to do Dial-up internet.

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang?

Post by Badwolf » Sun Nov 03, 2019 8:38 pm

Thanks, Ian.

At the moment I've got a Raspi with a USB-Serial dongle on it. Unstressed it works really well. That is to say that small packets using a low percentage of the bandwidth work nicely.

For example I can telnet into the raspi and tap away happily. Rarely are packets dropped and life is good.

If decide to transmit files of a decent size via FTP from the A3000 to the pi, speeds are, obviously, not great but are within expectations of the technology. However if I try to retrieve from the raspi such that all bandwidth is required, a high rejection of packets (CRC error) is seen.

To me this implies flow control isn't working correctly. The raspi can keep up with a 19200 bps reception rate without breaking sweat, so the A3000->Pi flow I would expect to be unaffected. The reverse is, however, not true since the A3000 is working at the very limit of its capability.

I've been breadboarding out the serial (null modem style) interface between the two using the reference material at http://www.riscos.org/csafaq/part2.html and the fact that the serial driver supplies both 'Acorn' and 'PC' wiring modes. There is also the (quite distinct) possibly that the USB-Serial adapter I'm using simply doesn't 'do' the RTS and CTS lines which the raspi side expects.

All fun and games!

BW.

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang? (+ serial TCP/IP on A3000)

Post by Badwolf » Mon Nov 04, 2019 2:44 pm

Quick update on where this has gone since I managed to get FTP working.

Situation: A3000 talking to TCP/IP network via "internalpc" serial chip and PPP via null modem to Raspberry Pi.

Symptom: at 19200bps, A3000 can interact fully on the network with no obvious droped ping packets and interactive sessions work well. A3000 can FTP push to internet, but retreival of file of more than a couple of kilobytes stalls with effective throughputs of only around 2000bps.

My first thought was this was down to handshaking. Perhaps when the link became busy transferring data from the more capable Pi to the co-operative A3000 we were unable to empty the buffer fast enough such that resends were being needed and effective rate was dropping.

This turns out not to be so. I've checked out the handshaking with a breadboard between the two machines and snooping on the lines and RTS is being asserted and observed properly. Also the line is not maxed out. Other sessions such as interactive telnet and ping continue happily whilst the FTP transfer grinds to a halt.

That said, there are still high packet rejection rates on the A3000 side of the PPP link which could imply that simply the RTS/CTS handshaking is not good enough at this speed. When reducing the data rate to 9600, the problems effectively evaporate.

Ian has said, and I've seen mentioned elsewhere, that 'high speed' (by which I assume 9600 & 19200 on an A3000) serial was unreliable on early Archimedes. Not knowing the detail here, is it possible that this unreliability is related to timing issues on the flow control side of things? If the machine is not able to deassert readiness to receive quickly enough such that the buffer overflows anyway and the consequential high packet failure rate means the TCP/IP rate determination system never gets to accelerate, then I could believe these symptoms.

What's odd however, is that if I use two terminal emulators and ZModem, transfers are reliable and at full(ish) speed (15kps+). Of course there's no competion on the line in that case, but a little curious.

Anyway, I shall continue to investigate.

Cheers for the help so far, everyone.

BW.

BTW: the SLIP module that comes with Freenet2 seems terrible in comparison to the two PPP modules I've found. 40%+ packet loss unstressed. Has anyone managed to use with any efficacy at all?

hubersn
Posts: 171
Joined: Sun Aug 14, 2016 7:59 pm
Contact:

Re: !FTPc triggering system hang? (+ serial TCP/IP on A3000)

Post by hubersn » Mon Nov 04, 2019 3:31 pm

Badwolf wrote:
Mon Nov 04, 2019 2:44 pm
Quick update on where this has gone since I managed to get FTP working.
...
Random thoughts from past experience with the A3000 serial stuff.

Always use an Acorn-style serial cable and "Internal" blockdriver, never "InternalPC". Always use the patched serial driver when using RISC OS 3.10 (I think it was "SerialUtils" or something like that?), only 3.11 incorporated that by standard. Always use David Pilling's SerialBuffer module with 16K input and 4K output buffer.

Back in the day, I used SLIP and PPP for Telnet/FTP stuff when connecting to the university's server, and it worked fine. When modems got faster than 14k4 however, I upgraded to a Dual Serial Card (The Serial Port) which made life much easier.

Have fun
hubersn

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang? (+ serial TCP/IP on A3000)

Post by Badwolf » Mon Nov 04, 2019 4:34 pm

hubersn wrote:
Mon Nov 04, 2019 3:31 pm
Always use an Acorn-style serial cable and "Internal" blockdriver, never "InternalPC".
That's interesting. Does the 'InternalPC' one add some additional overhead, then? Could that be what I'm seeing?

I've not quite got my head around how the Acorn handshaking worked and following the Archie <-> RiscPC diagram from the above linked site didn't seem to get me as far as using an RTS/CTS wiring, but that might be worth more investigation.
Always use the patched serial driver when using RISC OS 3.10 (I think it was "SerialUtils" or something like that?), only 3.11 incorporated that by standard.
I'm on 3.11, fortunately.
Always use David Pilling's SerialBuffer module with 16K input and 4K output buffer.
Interesting. I'll look into that. Thanks.
Back in the day, I used SLIP and PPP for Telnet/FTP stuff when connecting to the university's server, and it worked fine. When modems got faster than 14k4 however, I upgraded to a Dual Serial Card (The Serial Port) which made life much easier.

Have fun
hubersn
Thanks for this. I'm not sure why I'm seeing such terrible performance from the SLIP driver. Perhaps I've a shonky version. I'd quite like to get that working to prove it's not just PPPD papering over the cracks.

Cheers,

BW.

hubersn
Posts: 171
Joined: Sun Aug 14, 2016 7:59 pm
Contact:

Re: !FTPc triggering system hang? (+ serial TCP/IP on A3000)

Post by hubersn » Mon Nov 04, 2019 9:39 pm

Badwolf wrote:
Mon Nov 04, 2019 4:34 pm
I'm not sure why I'm seeing such terrible performance from the SLIP driver. Perhaps I've a shonky version. I'd quite like to get that working to prove it's not just PPPD papering over the cracks.
I forgot to mention that during my "serial IP world" phase, I always used Freenet1 as a TCP/IP stack. I only switched to Acorn TCP/IP stack once I got an ethernet NIC IIRC.

Have fun
hubersn

hubersn
Posts: 171
Joined: Sun Aug 14, 2016 7:59 pm
Contact:

Re: !FTPc triggering system hang? (+ serial TCP/IP on A3000)

Post by hubersn » Mon Nov 04, 2019 9:42 pm

Badwolf wrote:
Mon Nov 04, 2019 4:34 pm
hubersn wrote:
Mon Nov 04, 2019 3:31 pm
Always use an Acorn-style serial cable and "Internal" blockdriver, never "InternalPC".
That's interesting. Does the 'InternalPC' one add some additional overhead, then? Could that be what I'm seeing?
No, "Internal" and "InternalPC" are basically the same, only there to cater for the differing cabling needed (A3000 is 6551 and therefore needs the special cable, while the later "PC-style I/O" machines you can choose).

What you see sounds a bit like broken handshaking along with insufficient buffering to me. However, the fact that ZModem file transfer is fine really speaks against this.

Hope you'll sort it out
hubersn

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang? (+ serial TCP/IP on A3000)

Post by Badwolf » Mon Nov 04, 2019 10:09 pm

hubersn wrote:
Mon Nov 04, 2019 9:42 pm
No, "Internal" and "InternalPC" are basically the same, only there to cater for the differing cabling needed (A3000 is 6551 and therefore needs the special cable, while the later "PC-style I/O" machines you can choose).
Oh! Does that mean the InternalPC differences don't actually have an effect on the A3000? That would certainly make a dent in design.

BW.

Badwolf
Posts: 18
Joined: Wed Oct 02, 2019 11:18 pm
Contact:

Re: !FTPc triggering system hang? (+ serial TCP/IP on A3000)

Post by Badwolf » Tue Nov 05, 2019 12:28 am

Badwolf wrote:
Mon Nov 04, 2019 10:09 pm
hubersn wrote:
Mon Nov 04, 2019 9:42 pm
No, "Internal" and "InternalPC" are basically the same, only there to cater for the differing cabling needed (A3000 is 6551 and therefore needs the special cable, while the later "PC-style I/O" machines you can choose).
Oh! Does that mean the InternalPC differences don't actually have an effect on the A3000? That would certainly make a dent in design.
A little bit of experimentation tonight and it does look like the 'internalpc' driver does what it says on the tin: the serial port behaves more like a PC one with RTS and CTS controlling flow rather than RTS and DSR. I rewired everything and switched to 'Internal' with no obvious difference in results. I'm going to chalk that one down as a red herring.

I also had a go with the serial buffers module from David Pilling -- thanks for the recommendation. It didn't make any difference to the headline issue even when whacking the buffer up to hundreds of kilobytes, but will surely be good to have in the chain.

Using the new 'Internal' configured null modem connection I can comfortable push ~1800cps (14k4 bps) over modem. I've configured PPP to use both software and hardware flow control and am using the internal driver + buffers and basically sustained connections simply stall after 20K or so to drop to a sub 1kbps long-term average. Other packets go back and forth happily, but watching the rx line there is genuinely no data for the majority of the time.

Changing gear down to 9600 pegs the rx line on and produces around 770cps (~6200bps) on average -- this is pretty much bang on full spec for 9600.

Hard to explain all of this. I might try to make a video over the weekend if I'm still working at it.

Currently my theory is there looks to be something strange in the TCP/IP stack. Struggling to empty the buffers at over 9600bps. I think I'll have a go with Freenet next to see if that makes any difference.

Thanks everyone for the help and advice so far. I hope this will be of interest to someone later on. It's certainly curious!

BW.

Post Reply