shorten basic files saved to wespi

Anything Sinclair ZX Basic related; history, development, tips - differences between BASIC on the ZX80 and ZX81
Post Reply
User avatar
msknight
Posts: 386
Joined: Fri Dec 15, 2023 8:26 pm
Location: Sussex, UK

shorten basic files saved to wespi

Post by msknight »

I've been saving files out to the wespi, but even short programs are coming out at over 1k with what seem to be lots of empty lines... well, 76H and thirty two 00H. Obviously, I can't then transfer these to a TZXDuino to load them in via ear on a new 1k zeddy.

I'm presuming that there is already a tool to take these out of a file?

Also, is there a program to view a P file in human readable format please?
User avatar
Paul
Posts: 1517
Joined: Thu May 27, 2010 8:15 am
Location: Germanys west end

Re: shorten basic files saved to wespi

Post by Paul »

If you want to make files for the 1k ZX81 its a good idea to lower RAMTOP before programming.
This way you get a collapsed DFile
In theory, there is no difference between theory and practice. But, in practice, there is.
User avatar
msknight
Posts: 386
Joined: Fri Dec 15, 2023 8:26 pm
Location: Sussex, UK

Re: shorten basic files saved to wespi

Post by msknight »

Ah. Thanks. Also noted ... before... programming :-) So there's no way to reduce a file already created?

(I've already tried cutting out those seemingly empty lines, but that failed to load)
User avatar
msknight
Posts: 386
Joined: Fri Dec 15, 2023 8:26 pm
Location: Sussex, UK

Re: shorten basic files saved to wespi

Post by msknight »

So I use this... yes?

POKE 16388,0
POKE 16389,68
CLEAR
User avatar
Paul
Posts: 1517
Joined: Thu May 27, 2010 8:15 am
Location: Germanys west end

Re: shorten basic files saved to wespi

Post by Paul »

I haven't checked the poke.
But you have to execute NEW instead of clear.
There is a way to reduce it without retyping:
Reduce RAMTOP to 2K and new.
Now you can load from wespi.
After this execute CLS, then save again.
The ZX81 collapses the screen if less than (not exactly shure) 3K of RAM is available.
With 2K you are on the safe side.
In theory, there is no difference between theory and practice. But, in practice, there is.
User avatar
XavSnap
Posts: 1941
Joined: Sat May 10, 2008 4:23 pm
Location: 'Zx81 France' Fb group.

Re: shorten basic files saved to wespi

Post by XavSnap »

Compressed D_File:
https://www.sinclairzxworld.com/viewtop ... 301#p54301

In VB81 XuR, 9999 SAVE"P.TXT"
Or "ZXtocken", PtoText ...
Xavier ...on the Facebook groupe : "Zx81 France"(fr)
Post Reply