Is SBASIC programming on SMSQE difficult?

Anything QL Software or Programming Related.
User avatar
NormanDunbar
Forum Moderator
Posts: 2251
Joined: Tue Dec 14, 2010 9:04 am
Location: Leeds, West Yorkshire, UK
Contact:

Re: Is SBASIC programming on SMSQE difficult?

Post by NormanDunbar »

Hi ralf,

I suspect he means to update his QLIberator on his SMS2 computer, not to update SMS2.

Cheers,
Norm.


Why do they put lightning conductors on churches?
Author of Arduino Software Internals
Author of Arduino Interrupts

No longer on Twitter, find me on https://mastodon.scot/@NormanDunbar.
User avatar
dilwyn
Mr QL
Posts: 2753
Joined: Wed Dec 01, 2010 10:39 pm

Re: Is SBASIC programming on SMSQE difficult?

Post by dilwyn »

When it comes to QLiberator external procedures, there's been extensive discussion about them here and how people couldn't get them to work on SMSQ/E systems up to and including v3.36 of QLiberator. Some versions of SMSQ/E even came with a patch program for QLIB_run and QLIB_ext files to help get Externals to work. I presume (I have no exerience to know) that this applies to SMS/SMS2 as well.

Versions of QLIberator AFTER v3.36 (the versions worked on by EmmBee and Per Witte and others) have had a lot of work done on them and there are references in the updated documents to changes made in more recent versions - might be worth looking through the documents with the various version to see if any changes were made relevant to your needs.


Tinyfpga
Gold Card
Posts: 252
Joined: Thu Sep 27, 2018 1:59 am

Re: Is SBASIC programming on SMSQE difficult?

Post by Tinyfpga »

Post by dilwyn » Sat Jan 22, 2022 8:38 pm
When it comes to QLiberator external procedures, there's been extensive discussion about them (on this forum)
Thank you for the tip. I searched for the discussions and found them. I will do my usual trick of collating the posts into a single document to read at a later date.

Using Norm's update idea, here is my UPDATE:-
Collating posts into a readable format is time consuming. As there is so much useful info on this forum, wouldn't it be great if one could just "press a button" to do this automatically.

And, yes, as Norm surmised, I am going to update Qlib on my various platforms, but sadly I can't update SMS2 itself. My ideal "QL" system would be SMS2 on Qzero or better still Stella on Qzero. One could even place such a system in a slimline "QL" case for those that admire the retro look.


User avatar
NormanDunbar
Forum Moderator
Posts: 2251
Joined: Tue Dec 14, 2010 9:04 am
Location: Leeds, West Yorkshire, UK
Contact:

Re: Is SBASIC programming on SMSQE difficult?

Post by NormanDunbar »

Your wish might be difficult to grant. The forum runs on something called phpBB. It probably uses a mysql database to hold posts, topics, etc -- but don't quote me because I didn't check!

I did look for tools to combine/merge multiple posts into one document, with no luck.

Here's a thought experiment. The URL for viewing a post is viewtopic.php?f=3&t=4027 where f is the forum and t is the topic. Pagin is hanfled by taghing on "&start=nn" to thr url. Nn appears to be in multiples of 10. The first page has no start.

Given the url etc, a scraper program might be possible where it grabs the content of the url and somehow works through grabbing the html for each page until it gets a not found 404 error. Then the html could be stripped out and a text file created?

Cheers,
Norm.


Why do they put lightning conductors on churches?
Author of Arduino Software Internals
Author of Arduino Interrupts

No longer on Twitter, find me on https://mastodon.scot/@NormanDunbar.
User avatar
XorA
Site Admin
Posts: 1358
Joined: Thu Jun 02, 2011 11:31 am
Location: Shotts, North Lanarkshire, Scotland, UK

Re: Is SBASIC programming on SMSQE difficult?

Post by XorA »

NormanDunbar wrote:Your wish might be difficult to grant. The forum runs on something called phpBB. It probably uses a mysql database to hold posts, topics, etc -- but don't quote me because I didn't check!

I did look for tools to combine/merge multiple posts into one document, with no luck.

Here's a thought experiment. The URL for viewing a post is viewtopic.php?f=3&t=4027 where f is the forum and t is the topic. Pagin is hanfled by taghing on "&start=nn" to thr url. Nn appears to be in multiples of 10. The first page has no start.

Given the url etc, a scraper program might be possible where it grabs the content of the url and somehow works through grabbing the html for each page until it gets a not found 404 error. Then the html could be stripped out and a text file created?

Cheers,
Norm.
Isn’t it as easy as hitting print view on the spanner at top?


User avatar
NormanDunbar
Forum Moderator
Posts: 2251
Joined: Tue Dec 14, 2010 9:04 am
Location: Leeds, West Yorkshire, UK
Contact:

Re: Is SBASIC programming on SMSQE difficult?

Post by NormanDunbar »

Never seen that option before!


Why do they put lightning conductors on churches?
Author of Arduino Software Internals
Author of Arduino Interrupts

No longer on Twitter, find me on https://mastodon.scot/@NormanDunbar.
Derek_Stewart
Font of All Knowledge
Posts: 3928
Joined: Mon Dec 20, 2010 11:40 am
Location: Sunny Runcorn, Cheshire, UK

Re: Is SBASIC programming on SMSQE difficult?

Post by Derek_Stewart »

Tinyfpga wrote:Given that Derek had no problems with $$external, I thought I would check the version of Qlib installed om my setups. I found that, although I thought I was using v3.36, I am, in fact, using v3.31 which does not support the directive.
I did not say that, I had problems with SMSQ/E, there was no problems with Minerva.

I will have a look on older version of Qliberator.


Regards,

Derek
User avatar
Andrew
Aurora
Posts: 786
Joined: Tue Jul 17, 2018 9:10 pm

Re: Is SBASIC programming on SMSQE difficult?

Post by Andrew »

XorA wrote:Isn’t it as easy as hitting print view on the spanner at top?
For phpBB v3.0.x there was an add-on that allowed printing of a full topic, not only the current page.
I do not know if it works with the current phpBB version


User avatar
NormanDunbar
Forum Moderator
Posts: 2251
Joined: Tue Dec 14, 2010 9:04 am
Location: Leeds, West Yorkshire, UK
Contact:

Re: Is SBASIC programming on SMSQE difficult?

Post by NormanDunbar »

It seems that option only "prints" the page you are on.

Cheers,
Norm.


Why do they put lightning conductors on churches?
Author of Arduino Software Internals
Author of Arduino Interrupts

No longer on Twitter, find me on https://mastodon.scot/@NormanDunbar.
User avatar
NormanDunbar
Forum Moderator
Posts: 2251
Joined: Tue Dec 14, 2010 9:04 am
Location: Leeds, West Yorkshire, UK
Contact:

Re: Is SBASIC programming on SMSQE difficult?

Post by NormanDunbar »

mk79 wrote:Well, in reality PEEK_L returns a float, so in principle one could do a PEEK_UL if one wanted.
So I did one! And PEEK_UW as well. I'll be using this as an excuse to do some more work on the next instalment of the eMagazine, but for now, have a PEEK_UL and PEEK_UW on me. PEEK_U isn't required as it returns unsigned values only.

The source code is well enough commented, if anyone cares. And there are two versions, a QDOS version and an SMSQ/E version. QDOS is bigger, at 260 bytes over 230, as it has the code to float a long onto the maths stack embedded while SMSQ/E has a maths package operation to float a long.

Oh, yes, I noticed an error in the S*BASIC example I posted back a while. I was adding 2^32 and should have been adding 2^31. Duh!
PEEK_UL.SMSQ.zip
(3.33 KiB) Downloaded 54 times
PEEK_UL.QDOS.zip
(3.36 KiB) Downloaded 50 times
UPDATED PLEASE RE_DOWNLOAD

There's nothing clever here, just grab an address, peek it and get a long result, if we want a word, clear the low word and swap the high word down. Float the result, Test if the float is negative and if so, add 2^31 for longs or 2^15 for words and return the result. I'd forgotten how much fun it was making sure A1 was set correctly!

Cheers,
Norm.


Why do they put lightning conductors on churches?
Author of Arduino Software Internals
Author of Arduino Interrupts

No longer on Twitter, find me on https://mastodon.scot/@NormanDunbar.
Post Reply