Peter wrote: Sat Oct 14, 2023 10:56 pm
I can confirm that SERNET works now, and FSERVE works on top. The Q68 getting a file or directory from the QL appears fast, although this involves the bitwise write access to the ROM port.
I might speed this up a bit by unrolling the loop, as discussed by mail.
The other direction (QL reading from Q68) is painfully slow, probably due to the fact that the driver does not (and can not) use receive interrupts. Probably at least a polled interrupt service routine is needed to resume receive operation after blocking. (It is late and I might be wrong.)
It has probably to do with the speed at which the QL can digest data from the fifo. 115200 bps means 288 bytes per 20ms, since the fifo is 512 bytes it should be emptied every frame interrupt. Writing to a physical device will stall interrupts for some time so should be avoided, only RAMdisk is safe.
Also keep in mind that there is no hardware flow control. This shouldn't be a problem if data is sent in packets (I'm not sure how long they are in SERnet, probably 256 bytes like 'ordinary' QLNet?).
An extra interrupt handler would have to read bytes from the fifo and store them in an even larger buffer (like in SMSQ/E) but the higher layers still have to be able to digest the data fast enough, else you will have the same problem if the large buffer eventually overflows.
The current version of the driver doesn't check the overrun bit, maybe a PEEK will show it? Will reading a byte from the receive fifo reset it?
By the way, I think it would be better to use SRX4 and STX4, so there is no confusion with the QL's two ports and Hermes' extra port. SER4 should also be a valid device name for normal serial port operation.
Allright, will change that.
Jan