Page 4 of 4

Re: $$external problem

Posted: Wed Mar 21, 2018 11:33 pm
by EmmBee
Here is my recommended way to test …
First, Enter the SBASIC code …

50 REMark $$external
60 DEFine Function FRA(x)
70 RETurn x - INT(x)
80 END DEFine

Compile with Q_Liberator

Type in and ENTER ... NEW - get rid of the SBASIC program – to avoid any confusion.

LRESPR the created QLIB obj file

And now test: PRINT #0, FRA(3.456)

Re: $$external problem

Posted: Thu Mar 22, 2018 9:55 am
by Artificer
EmmBee wrote:I don't think this works, actually. Neglecting to get rid of the SBASIC code is the culprit. In this case, SBASIC would take precedence over any loaded extension and produce a misleading correct result. Any loaded QLIB extensions never get the chance to be tested.

Let's hope that Wolfgang can come to the rescue.
EmmBee

Doing exactly as you say with the original SBASIC code cleared from the system with a reboot the FRA QLIB external still works on the Q60, I am using the QLib runtimes that are version 3.36mod. I thought they were the version that Thierry Godefroy modified a long time ago but they may also have been patched to work with externals as Dilwyn suggests.

Re: $$external problem

Posted: Thu Mar 22, 2018 4:45 pm
by Dave
Uhhh. *giggles*

I just misread this thread as: $exual problem

Re: $$external problem

Posted: Thu Mar 22, 2018 6:29 pm
by pjw
Dave wrote:Uhhh. *giggles*

I just misread this thread as: $exual problem
A Freudian slip, perhaps?

Re: $$external problem

Posted: Thu Mar 22, 2018 10:31 pm
by EmmBee
Our $exual problem continues...
Artificer wrote:have just tried the demonstration program for FRA(), compiled with QLiberator and LRESPRed and I get it to work when compiled with smsq/e 3.31 or with smsq/e 3.32 on a Q60. I have also QLiberated this demo program on my Aurora system, smsq/e 3.32 mode 4 and it works there as well
I am using smsq/e 3.31 with QPC2, but have never got this to work. I am perhaps hoping that Wolfgang can modify his patch program.
Georgio and Derek also use QPC2 and both have reported it does work for them. I am confused.
It will be interesting to find out how Dilwyn makes out with all this...

Re: $$external problem

Posted: Thu Mar 22, 2018 10:50 pm
by Derek_Stewart
Hi,

Emulators I use: QPC2, SMSQmulator, Q-emulator (Registered)

Everything works OK in Q-emulator with Minerva. But with SMSQ/E QLIB_RUN2 is required to add SBASIC PROCedures and FuNctions to the SBASIC commands.

Probably best to use an Overlays with the added Externals, so they can be unloaded.

Re: $$external problem

Posted: Fri Mar 23, 2018 7:54 am
by EmmBee
dilwyn wrote:qlrun2.zipTried using QLIB_RUN_bas to modify:

1. "Vanilla" unmodified QLIB_run 3.36
2. QLIB_RUN335_mod
3. QLIB_RUN336_mod

Patched files and short readme_txt attached - let me know if these work and then I can make them available via my website. If anyone knows the status of the qlib_run_bas programs, we may then be able to make those available too.
I notice that both QLib_run335_mod2 and QLib_run336_mod2 do not have any dataspace values, while QLib_run2 does.
Is something wrong here?

Re: $$external problem

Posted: Fri Mar 23, 2018 8:51 am
by tofro
EmmBee wrote: I notice that both QLib_run335_mod2 and QLib_run336_mod2 do not have any dataspace values, while QLib_run2 does.
Is something wrong here?
Just checked. The original QLib_run (as it comes from the 3.33 installer disk) has 4k data space set. The same disk has, however, a BOOT program that simply LBYTES QLib_run (which completely disregards the data space settings).

I can't see why a piece of code that is not an executable job would need data space set up, so I would simply assume it's an unnecessary quirk in QLIB and live happily without that data space setting.

Another fancy quirk is that the original BOOT allocates 2 bytes more than are actually loaded.

Tobias

Re: $$external problem

Posted: Fri Mar 23, 2018 5:40 pm
by Artificer
Hi EmmBee

Its not an smsq/e problem its a QLib runtimes problem. This morning I checked the FRA() compiled external on QPC2 4.04 smsq/e 3.32. It worked for me there also.

[/quote]I am using smsq/e 3.31 with QPC2, but have never got this to work. I am perhaps hoping that Wolfgang can modify his patch program.
[/quote]

Then I downloaded QLib_run 3.36 mod from Dilwyn's site and tried that. It did not work. The QLib runtimes I use routinely on QPC2 and Q60 and Aurora have been patched for the external bug so long ago I have forgotten. Use the patched version Dilwyn has put on his site and you should not have a problem with this any longer.

Re: $$external problem

Posted: Sun Mar 25, 2018 6:43 pm
by EmmBee
Hi Artificer,

Thanks for this. I now have it all working properly.
I can confirm that it now works on QPC2 - great!

EmmBee