2022 version of WimBasic

Basic and Machine Language

Moderator: Moderators

Post Reply
wimoos
Vic 20 Afficionado
Posts: 348
Joined: Tue Apr 14, 2009 8:15 am
Website: http://wimbasic.webs.com
Location: Netherlands
Occupation: farmer

2022 version of WimBasic

Post by wimoos »

Hello all,

A new version of WimBasic has been released. It is available at http://wimbasic.webs.com

A new command has been added: ERASE. This deletes an array that was previously DIM'd. Useful when memory is scarce, an array needs to be reinitialized with zeros or empty strings, or needs to be redimensioned. In a single ERASE command, multiple arrays can be deleted.

Also the autostart feature is fixed. During startup, WimBasic searches for a file called WBSTART. When this file is found, it is loaded and RUN.

Regards,

Wim.
VICE; selfwritten 65asmgen; tasm; maintainer of WimBasic
User avatar
TRIANGULAR OS
Vic 20 Dabbler
Posts: 87
Joined: Wed Mar 09, 2022 4:53 am
Website: https://www.youtube.com/@triangular_uos
Location: Cracow, Poland

Re: 2022 version of WimBasic

Post by TRIANGULAR OS »

Congratulations! It is great project. I trying it and I loving it.

Coincidentally I also released final and ultimate BASIC (V2) version of TRIANGULAR μOS for VIC-20 today (version 1.15/VIC).

I assume that you can only perform GOTO or GOSUB to line number stored in variable by using EXEC command?:
GOTO A => EXEC "GOTO"+STR$(A)
GOSUB A => EXEC "GOSUB"+STR$(A)
TRIANGULAR μOS for VIC-20:
http://www.sleepingelephant.com/ipw-web ... =2&t=10352

TRIANGULAR μOS YouTube channel:
https://www.youtube.com/@triangular_uos
User avatar
Mike
Herr VC
Posts: 4841
Joined: Wed Dec 01, 2004 1:57 pm
Location: Munich, Germany
Occupation: electrical engineer

Re: 2022 version of WimBasic

Post by Mike »

TRIANGULAR OS wrote:I assume that you can only perform GOTO or GOSUB to line number stored in variable by using EXEC command? [...]
Calculated GOTOs/GOSUBs are a recipe for disaster.

They do not provide any advantage beyond what is otherwise doable with the ON X GOTO/GOSUB statement, unless one happens to have a group of jump targets that follow an arithmetic progression, so something like "GOTO 10000+X*1000" could be applied for space savings. In the latter case, a simple RENUMBER that was intended to straighten the line numbers - during or at the end of development - will render that GOTO statement non-functional.
User avatar
TRIANGULAR OS
Vic 20 Dabbler
Posts: 87
Joined: Wed Mar 09, 2022 4:53 am
Website: https://www.youtube.com/@triangular_uos
Location: Cracow, Poland

Re: 2022 version of WimBasic

Post by TRIANGULAR OS »

Mike you're right. Although it will be sometimes great to have possibility to GOTO or GOSUB into some function by using a variable, renumber will totally disable code. I will only work if one keeps its subroutines pack tightly in the begging of program, so they won't be renumbered (if we keep same renumber parameters). Otherwise something like labels and branching to them would have to be implemented in language.
TRIANGULAR μOS for VIC-20:
http://www.sleepingelephant.com/ipw-web ... =2&t=10352

TRIANGULAR μOS YouTube channel:
https://www.youtube.com/@triangular_uos
wimoos
Vic 20 Afficionado
Posts: 348
Joined: Tue Apr 14, 2009 8:15 am
Website: http://wimbasic.webs.com
Location: Netherlands
Occupation: farmer

Re: 2022 version of WimBasic

Post by wimoos »

Mike's comment is completely correct, so I would go for that.

To answer your question: In WimBasic an EXEC "GOTO"+STR$(A) works as intended should you choose to use a computed GOTO.
EXEC "GOSUB"+STR$(A) may run into problems in some scenarios because of the GOSUB stack frame interfering with the EXEC command.
I have not tested that thoroughly (as I mentioned in the documentation).

EXEC is very useful for DOS commands e.g. EXEC">S:FILE" to scratch a file

Regards,

Wim.
VICE; selfwritten 65asmgen; tasm; maintainer of WimBasic
User avatar
chysn
Vic 20 Scientist
Posts: 1205
Joined: Tue Oct 22, 2019 12:36 pm
Website: http://www.beigemaze.com
Location: Michigan, USA
Occupation: Software Dev Manager

Re: 2022 version of WimBasic

Post by chysn »

I used an MCes Jolly Cartridge PCB to make a WimBasic+8K physical cartridge

IMG_5564.jpg

Why 8K? I have some free HM6264s sitting around from a picking error. Apparently it wasn't worth the vendor's time to have them sent back. And they need homes :D


I've got a damn busy week ahead at work, but hopefully I'll be able to squeeze in some time to play with WimBasic.

IMG_5575.jpg
VIC-20 Projects: wAx Assembler, TRBo: Turtle RescueBot, Helix Colony, Sub Med, Trolley Problem, Dungeon of Dance, ZEPTOPOLIS, MIDI KERNAL, The Archivist, Ed for Prophet-5

WIP: MIDIcast BASIC extension

he/him/his
wimoos
Vic 20 Afficionado
Posts: 348
Joined: Tue Apr 14, 2009 8:15 am
Website: http://wimbasic.webs.com
Location: Netherlands
Occupation: farmer

Re: 2022 version of WimBasic

Post by wimoos »

Hey chysn,

It is great to see the fruits of my efforts being used across the world!
Please let me know what you find!

Regards,

Wim.
VICE; selfwritten 65asmgen; tasm; maintainer of WimBasic
User avatar
TRIANGULAR OS
Vic 20 Dabbler
Posts: 87
Joined: Wed Mar 09, 2022 4:53 am
Website: https://www.youtube.com/@triangular_uos
Location: Cracow, Poland

Re: 2022 version of WimBasic

Post by TRIANGULAR OS »

wimoos wrote: Mon Aug 22, 2022 12:52 am Hey chysn,

It is great to see the fruits of my efforts being used across the world!
Please let me know what you find!

Regards,

Wim.
Right, even I'm now considering creating VIC-20 version of TRIANGULAR μOS that will work with your WimBasic. Right now I'm converting it to C64: https://www.lemon64.com/forum/viewtopic.php?t=80381 , so I will sit at this in the future.
TRIANGULAR μOS for VIC-20:
http://www.sleepingelephant.com/ipw-web ... =2&t=10352

TRIANGULAR μOS YouTube channel:
https://www.youtube.com/@triangular_uos
Post Reply