I got one here and am doing the same thingppe wrote:tofro wrote:The software part is more interesting. I don't know if any other device drivers have been written in C on the QL but it's been quite a ride.

I think I can help if problems arise.
I got one here and am doing the same thingppe wrote:tofro wrote:The software part is more interesting. I don't know if any other device drivers have been written in C on the QL but it's been quite a ride.
You can never have too much good documentation. And anything that exposes "foibles" in a device, etc, can only be a good thing -- and will help anyone doing similar stuff.ppe wrote:I'm hoping to have the energy to also write some blog posts about some of the gotchas I ran into on the way. Perhaps documenting some of the (for me) trickier parts may be interesting to future code archaeologists.
That's to the point. And I think in terms of memory footprint and practicability, offloading TCP/UDP to a different CPU has the edge.ppe wrote:Actually, in the case of W5300, one should talk about a "TCP/UDP controller" rather than an "ethernet controller".
I wrote the first working QL-SD driver (derived from QL-HD and never released) in C, but with an ancient K&R style compiler named PDQC.ppe wrote:I don't know if any other device drivers have been written in C on the QL but it's been quite a ride.
Ah, group therapy feels so good! I was also struggling with some of the TRAP #3 stuff, plus memory allocation library calls being quite borked. The struggle is real... qdos-gcc to the rescue. Unfortunately, the libraries still seem to come from the C68 distribution but at least the optimiser works plus there's a functioning inline "asm" directive which makes it easier to work around some of the more ....ahem... "interesting" parts.Peter wrote:I wrote the first working QL-SD driver (derived from QL-HD and never released) in C, but with an ancient K&R style compiler named PDQC.
Also recently my simple PS/2 mouse driver for Q68 Minerva, where I'm stuck with C68 bugs regarding TRAP #3.
Thank you for your extremely kind words, Peter!Peter wrote:Good luck and it's nice seeing your project! I think you're doing a fantastic job!
True, but as someone who worked a lot with qdos-gcc I found my share of pain there as well, e.g. macro related bugs. Overall, I find C68 slightly more reliable.ppe wrote:The struggle is real... qdos-gcc to the rescue. Unfortunately, the libraries still seem to come from the C68 distribution but at least the optimiser works plus there's a functioning inline "asm" directive which makes it easier to work around some of the more ....ahem... "interesting" parts.