LOAD without auto-running - ZXpand+ *update* also ZXpand classic

Any discussions related to the creation of new hardware or software for the ZX80 or ZX81
sirmorris
Posts: 2811
Joined: Thu May 08, 2008 5:45 pm

LOAD without auto-running - ZXpand+ *update* also ZXpand classic

Post by sirmorris »

I've added a new feature to the LOAD command. By inserting the keyword STOP after the filename the program will be prevented from auto-running.

LOAD "filename STOP "

will load the named program and return to the 0/0 prompt.

It works with LOAD "$" too ;)

Visit the announcements topic for the latest firmware update. You'll be wanting 1.07.

C

*UPDATE* - also now available for ZXpand classic in V2.61 "TROLL". See announcements topic.
User avatar
Andy Rea
Posts: 1606
Joined: Fri May 09, 2008 2:48 pm
Location: Planet Earth
Contact:

Re: LOAD without auto-running - ZXpand+

Post by Andy Rea »

Nice one Mr C this is a welcome feature for sure.

Whilst your programming skill is unsurpassed i think you might need a little help with the counting,....

you seem to have missed 1.02, 1.03, 1.04, 1.05 and 1.06 :lol: :lol:
what's that Smell.... smells like fresh flux and solder fumes...
sirmorris
Posts: 2811
Joined: Thu May 08, 2008 5:45 pm

Re: LOAD without auto-running - ZXpand+

Post by sirmorris »

I may be rubbish at counting but I can't half lift things!
Moggy
Posts: 3267
Joined: Wed Jun 18, 2008 2:00 pm

Re: LOAD without auto-running - ZXpand+

Post by Moggy »

Andy Rea wrote: Mon Jul 10, 2017 10:25 pm Nice one Mr C this is a welcome feature for sure.

Whilst your programming skill is unsurpassed i think you might need a little help with the counting,....

you seem to have missed 1.02, 1.03, 1.04, 1.05 and 1.06 :lol: :lol:
No he didn't miss them, I got stuck with them and as for programming skill learning the full MIDI spec in two hours then producing a working player in under a week is kids stuff.

Moggy hides.
User avatar
PokeMon
Posts: 2264
Joined: Sat Sep 17, 2011 6:48 pm

Re: LOAD without auto-running - ZXpand+

Post by PokeMon »

Good idea, is the opposite handled to like
LOAD "filename RUN" for starting a program with no autostart ? ;)
sirmorris
Posts: 2811
Joined: Thu May 08, 2008 5:45 pm

Re: LOAD without auto-running - ZXpand+

Post by sirmorris »

Haha yes I did consider this! It would have to be started from the first line of the program but I think that would be fine as that's pretty much what you do after loading, isn't it.

LOAD ".."
...
RUN
User avatar
Andy Rea
Posts: 1606
Joined: Fri May 09, 2008 2:48 pm
Location: Planet Earth
Contact:

Re: LOAD without auto-running - ZXpand+

Post by Andy Rea »

erm i would do a GOTO first line... some programs have variables setup already and a RUN destroys them

regards
what's that Smell.... smells like fresh flux and solder fumes...
sirmorris
Posts: 2811
Joined: Thu May 08, 2008 5:45 pm

Re: LOAD without auto-running - ZXpand+

Post by sirmorris »

The behaviour is controlled by the NEXTLN sysvar. Setting it to point to DFILE will stop auto-run, pointing it at the start of a line of BASIC will continue execution from there. There's neither a RUN nor a GOTO per-se so no worries about clearing vars :D

Thinking about it more I reached the conclusion that I will leave this for another day unless there's a big demand as it's really easy to make a program auto-run natively, it was harder to stop it however.
User avatar
siggi
Posts: 990
Joined: Thu May 08, 2008 9:30 am
Location: Wetterau, Germany
Contact:

Re: LOAD without auto-running - ZXpand+

Post by siggi »

sirmorris wrote: Wed Jul 12, 2017 7:13 am The behaviour is controlled by the NEXTLN sysvar. Setting it to point to DFILE will stop auto-run, pointing it at the start of a line of BASIC will continue execution from there. There's neither a RUN nor a GOTO per-se so no worries about clearing vars :D

Thinking about it more I reached the conclusion that I will leave this for another day unless there's a big demand as it's really easy to make a program auto-run natively, it was harder to stop it however.
In my UFM (USB-Filemanger), NFM (Network-Filemanager) and ZeddyFox (Internet browser) I have the option to not-autorun a loaded P-file: I just overwrite NEXTLIN by 0. Then (before returning to BASIC) this modified program can be stored (on USB-Stick or via ZeddyNet) to have a non-autorunning program later. That avoids the problem, that variables could be lost accidentially, when SAVE has to be done manually (maybe after RUN...)

Siggi
My ZX81 web-server: online since 2007, running since dec. 2020 using ZeddyNet hardware
http://zx81.ddns.net/ZxTeaM
User avatar
siggi
Posts: 990
Joined: Thu May 08, 2008 9:30 am
Location: Wetterau, Germany
Contact:

Re: LOAD without auto-running - ZXpand+

Post by siggi »

Equivalent would be:
LOAD "filename STOP THEN SAVE newfilename"

;)

Siggi
My ZX81 web-server: online since 2007, running since dec. 2020 using ZeddyNet hardware
http://zx81.ddns.net/ZxTeaM
Post Reply