SlipKnot-like Browser for QL - Mimir

Anything QL Software or Programming Related.
User avatar
bwinkel67
QL Wafer Drive
Posts: 1602
Joined: Thu Oct 03, 2019 2:09 am

Re: SlipKnot-like Browser for QL - Mimir

Post by bwinkel67 »

This one works a bit better. It's pretty accurate but has one flaw, which is that once a page is loading, there is no simple way to stop it. So if you ESCape, or reach the limits, the page displays, but the modem seems to stop sending. I'm not sure if that's an issue with the communication between the serial port and QemuLator, or the USB-to-Serial, or the Simulant modem, but it causes issues.

So if you load a long page and escape, the next time you try and load a new page, it shows the latter part of the old page. Get's really screwed up. Haven't yet tried it on real hardware but it would still be a problem, even if it keeps running on the server side, because the next time to put in a URL it would pick up the page in mid dump.

I do have a solution:

lynx -dump http://an_example_site > mimir.dump; ed mimir.dump

You skip the next line which tells you the size of the file (might use that to see how much to read). Then you enter "1" for the first line and "return" for each subsequent line. The ed editor will list one line at a time with no other stuff (it's better than more -1 as that gives a prompt). If I need to quit partway through a listing in ed I simply enter a "q" which stops things. So that might be a way to have more control of the page being sent over the serial port. Ideally a "ctrl-break" should stop a listing from a lunx dump, but I think the UNIX system has already thrown it out of its buffer so there is not way to stop it.

In any case the current version works pretty well for small contained pages. I was able to load "http://amayga.orgfree.com" and it loaded just fine. It also fixed a bug to handle things in [] that aren't links, plus if it gets confused it just stops using links altogether and just shows the page as plain text.

MIMIR.zip
(48.62 KiB) Downloaded 1 time

[Edit: I also added a feature where you can try and load the remaining screens of an aborted page...simply enter the following URL: http://+]


User avatar
bwinkel67
QL Wafer Drive
Posts: 1602
Joined: Thu Oct 03, 2019 2:09 am

Re: SlipKnot-like Browser for QL - Mimir

Post by bwinkel67 »

This version works so much better and I only added a small amount of code with the changes not that complex:

MIMIR.zip
(50.37 KiB) Downloaded 3 times

I ended up using the UNIX/Linux ed command, which is a line editor. It really fixes all the issues I had before. So now given a URL, the command I execute behind the scenes on the server side looks like this:

lynx -dump http://some_webpage > mimir.dump; ed - mimir.dump; #]

So the "-" option of ed stops it from printing the size, effectively making it not return anything unless you ask for it. Then you simple type "1" and "enter" to start form the top, and then "enter" for each subsequent line. If you type "q" and "enter" it aborts back to the UNIX prompt. This also means if I abort a page load via ESC it stops listing the remaining pages, so things don't get out of sync.

(Btw, the "#]" is a way I tag the end of the command, and I wait until I see "]" so before loading the page I can skip the server echoing back the line to me -- it could be multiple lines depending on URL length so that was the easiest way to generalize.)

Today I've been surfing the web and it works pretty well. If you type in an unknown page it gives a proper 404 error. page. I went to Action Retro's FrogFind as well as Google's search page. Even tried YouTube which added some junk at the top that I'll have to debug eventually.
Last edited by bwinkel67 on Sat Aug 23, 2025 6:54 am, edited 5 times in total.


User avatar
bwinkel67
QL Wafer Drive
Posts: 1602
Joined: Thu Oct 03, 2019 2:09 am

Re: SlipKnot-like Browser for QL - Mimir

Post by bwinkel67 »

Btw, I opened the QL_Emulator link on this forum and at one point it shows Lynx running. Do some emulators give you connection to the host computers networking infrastructure? Or is Lynx just used to read local html pages?

If Lynx can reach the web, is there any hardware that it works on? I know Q68 has an Ethernet port but I forget if it has software to use it. I think someone was also working on a network card for the QL. Just curious how else you can take an original QL on the web.


User avatar
Peter
Font of All Knowledge
Posts: 2529
Joined: Sat Jan 22, 2011 8:47 am

Re: SlipKnot-like Browser for QL - Mimir

Post by Peter »

bwinkel67 wrote: Sat Aug 23, 2025 6:21 am If Lynx can reach the web, is there any hardware that it works on? I know Q68 has an Ethernet port but I forget if it has software to use it.
I'm mostly using it for TFTP file transfer. IRC client also works. With Martin's driver, Lynx should work, but I never found time to play with it.
Yet unreleased, I have a webserver, the "retawq" webbrowser, and an email client with pointer interface. The latter has become practically useless as it does not support encryption.


User avatar
bwinkel67
QL Wafer Drive
Posts: 1602
Joined: Thu Oct 03, 2019 2:09 am

Re: SlipKnot-like Browser for QL - Mimir

Post by bwinkel67 »

Peter wrote: Sat Aug 23, 2025 7:42 am I'm mostly using it for TFTP file transfer. IRC client also works. With Martin's driver, Lynx should work, but I never found time to play with it.
Yet unreleased, I have a webserver, the "retawq" webbrowser, and an email client with pointer interface. The latter has become practically useless as it does not support encryption.
You mean the webbrowser when you say it's useless because it doesn't have encryption?

Is the Lynx version 2.8.2? That seems to be from 1999 (https://lynx.invisible-island.net/lynx2.8.2/CHANGES) if it's from dilwyn's site, which I'm guessing has similar issues.

Anyone ever port a telnet client to the QL since I would suspect that could be made workable if Lynx can.


User avatar
Peter
Font of All Knowledge
Posts: 2529
Joined: Sat Jan 22, 2011 8:47 am

Re: SlipKnot-like Browser for QL - Mimir

Post by Peter »

bwinkel67 wrote: Sat Aug 23, 2025 8:36 am You mean the webbrowser when you say it's useless because it doesn't have encryption?
No, I mean the email client. The times when email servers accepted a connection without SSL/TLS are over.


User avatar
bwinkel67
QL Wafer Drive
Posts: 1602
Joined: Thu Oct 03, 2019 2:09 am

Re: SlipKnot-like Browser for QL - Mimir

Post by bwinkel67 »

M68008 wrote: Fri Aug 15, 2025 6:12 pm Does it have an option to use the software settings (through the standard COM calls) instead of overriding them?

EDIT: never mind, I found many drivers have similar UI. They should still respond to software changes (e.g. BAUD command on QL side), although I've seen some of them not liking those calls.
So I just figured out the odd behavior that I've been chasing for a while. If I don't set the baud rate on the QDOS (JS) command line to what the modem currently is, my executable seems to struggle to connect, even thought it internally lets me set its own baud rate to match that of the modem. I know on a real QL the executable setting the baud rate is sufficient to change the baud rate on the serial port, but with QemuLator, if I set it on the command line and then start my executable, which sets its own baud rate, the command line baud rate is the one that's kept. Is that a potential bug in the way Qemulator implements the serial interface to the COM port?

P.S. I'm using Digital 'C' SE and its baud() function, which has worked as it is supposed to on my real QL.


User avatar
M68008
Gold Card
Posts: 291
Joined: Sat Jan 29, 2011 1:55 am
Contact:

Re: SlipKnot-like Browser for QL - Mimir

Post by M68008 »

Interesting... I wonder if it may be related to using a word vs long for the baud rate when calling MT.BAUD.


User avatar
bwinkel67
QL Wafer Drive
Posts: 1602
Joined: Thu Oct 03, 2019 2:09 am

Re: SlipKnot-like Browser for QL - Mimir

Post by bwinkel67 »

Ok, this one is even better. It should now work with any page, regardless of size. You can use http or https, either will work.

MIMIR.zip
(45.62 KiB) Downloaded 5 times

It's still a limited prototype, but it will now display the first part of any webpage. I tried https://cnn.com and it worked perfectly. What I do is load as many lines until I reach my limit (80 for now) and once there, I jump to the end of the dump file and pick the reference (20 for now) by executing the "$" and " ?^References$?" commands in ed which jumps to the end and backward searches for "References".

I have a plan to eventually have it read the entire page and grab all the references and I can use ed to basically give them to me in 80 line chunks (i.e. ed acts like my cache but stored on the server, not the QL). I'll also eventually will try and read file types -- i.e. ending in .zip for instance will ask to download a file to a device so someone could go to Dilwyn's software page and directly download files to a floppy (or win drive) and uncompress. Maybe even recognize JPG files and use Photon to display them.


User avatar
bwinkel67
QL Wafer Drive
Posts: 1602
Joined: Thu Oct 03, 2019 2:09 am

Re: SlipKnot-like Browser for QL - Mimir

Post by bwinkel67 »

Below is a link of my browser working. So it turns out that http://SDF.org not only gives you a free account (well, you send them $1 in the mail or paypal them $6 for a lifetime membership) but it also lets you host your own webpage (it's an html directory in your home directory where you put stuff in). The default URL it gives you is your userid appended to freeshell.org, but you can also choose from a list of domains that they support (some were weird, like 36bit.com or 6bit.com).

http://mjonas.freeshell.org/mimir.html

I like running it from F2 (just how I used my QL back in the day since the US ones couldn't display monitor mode on an NTSC TV). The information is on win1_ and the start page to use is: win1_test_htm

[Note1: It can only do the local file stuff since the DOS version of QLAY doesn't give you access to any COM port]
[Note2: It seems readme_txt and keytest_bas are corrupt...they're fine in the zip file that DOSBox uses and within QLAY, but QLAY in DOSBox can't see them so not sure what's going on as I've recreated the individual files and zip file half a dozen times without fixing it]


Post Reply