New version of WimBasic

Basic and Machine Language

Moderator: Moderators

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

New version of WimBasic

Postby wimoos » Mon Apr 16, 2012 5:53 am

Hello all,

There is a new version of WimBasic available. Please check http://wimbasic.webs.com .

The main improvements include:
- fixes in the ROUND() function
- fixes in using defined functionkeys
- fix in the FIND command
- slight change in the SuperNumbers implementation: it no longer uses the IERROR vector, but now hooks in the LET-routine (where it should be).

Regards,

Wim.
Last edited by wimoos on Sun Sep 03, 2017 6:12 am, edited 1 time in total.
PAL, two-prong VIC20 on 65C02 with 3k RAM expansion internal, 32k NOVRAM expansion external, DS1307 RTC and S-Video mod; 64HDD in FreeDOS on a thin-client; selfwritten 65asmgen; tasm; maintainer of WimBasic

User avatar
MicroPet
Vic 20 Amateur
Posts: 60
Joined: Sat Apr 07, 2012 5:55 am

Postby MicroPet » Mon Apr 16, 2012 1:31 pm

Forgive me if this is a silly question but can other people run programs written in WimBASIC on a stock Vic 20?

User avatar
Mike
Herr VC
Posts: 2925
Joined: Wed Dec 01, 2004 1:57 pm
Location: Munich, Germany
Occupation: electrical engineer

Postby Mike » Mon Apr 16, 2012 1:41 pm

MicroPet wrote:can other people run programs written in WimBASIC on a stock Vic 20?

Nearly all BASIC extensions must be loaded in and started before any program that uses them. These toolkits contain new routines to execute the additional commands and functions, and these routines do not 'magically' become part of your own program when you save it to disk.

WimBASIC is located in BLK5, so it must either be present as (EP)ROM in a cartridge or be soft-loaded with a RAM expansion that maps into BLK5. Either way, this isn't a stock VIC-20 anymore.

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

Yet another new version of WimBasic

Postby wimoos » Fri Jul 20, 2012 9:14 am

There is a new version of WimBasic available at http://wimbasic.webs.com

This new version contains a new command, called DIVMOD.
This command is used to calculate the quotient and the remainder of two unsigned integers (0..65535). The results are put in two variables DQ and DR.

Thanks to Marco for inspiration !

Also at the site a ZIP with a few sample programs in that make extensively use of WimBasic functions.

Enjoy!

Wim.
PAL, two-prong VIC20 on 65C02 with 3k RAM expansion internal, 32k NOVRAM expansion external, DS1307 RTC and S-Video mod; 64HDD in FreeDOS on a thin-client; selfwritten 65asmgen; tasm; maintainer of WimBasic

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

Yet another new version

Postby wimoos » Mon Oct 29, 2012 12:15 pm

This new version, that can be found at http://wimbasic.webs.com/wimbasic.zip has some major improvements:

1. Directory to screen (>$) now also works in VICE.

2. It is now possible to CHAIN programs using EXEC"(up-arrow)PROGRAM"

3. It is now possible to perform a calculated GOTO using EXEC"GOTO"+STR$(A+B*C)

Regards,

Wim.
PAL, two-prong VIC20 on 65C02 with 3k RAM expansion internal, 32k NOVRAM expansion external, DS1307 RTC and S-Video mod; 64HDD in FreeDOS on a thin-client; selfwritten 65asmgen; tasm; maintainer of WimBasic

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

And another new version

Postby wimoos » Tue Dec 25, 2012 11:03 am

In this version RENUM was fixed to handle the following properly:

IF cond THEN linenumber ELSE linenumber

The linenumber after ELSE would not be renumbered. To circumvent this, a colon before ELSE was needed. The new version fixes this

Also the following was not handled properly:

ON byte GOTO line1,,line2,line3 (note the missing number between the first and second comma).

This could gobble up the program. The new version fixes this.

WimBasic is available from http://wimbasic.webs.com as always.

Regards

Wim.
PAL, two-prong VIC20 on 65C02 with 3k RAM expansion internal, 32k NOVRAM expansion external, DS1307 RTC and S-Video mod; 64HDD in FreeDOS on a thin-client; selfwritten 65asmgen; tasm; maintainer of WimBasic

User avatar
buzbard
Vic 20 Devotee
Posts: 208
Joined: Sun Jul 03, 2005 9:10 am

Postby buzbard » Tue Dec 25, 2012 1:27 pm

When I add wimbasic.prg in vice (xvic.exe) I get:

Code: Select all

Main CPU: JAM at $BBC1


I've noticed the same in the last few versions.
Ray..

User avatar
buzbard
Vic 20 Devotee
Posts: 208
Joined: Sun Jul 03, 2005 9:10 am

Postby buzbard » Tue Dec 25, 2012 4:41 pm

I was trying to attach it as a cartridge at $A000, but if I load it into RAM at $A000 it works ok.

And if I add zeros at the end to make the file exactly 8k +2 bytes (for load address) it works fine as a cartridge.

@wimoos: if you add:

Code: Select all

.org $bfff
.byte $ff
as the last 2 lines line of the source it should fill the remaining space with $FF so that it works as a cartridge image in vice.
Works in DASM anyway.
Ray..

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

Postby wimoos » Wed Dec 26, 2012 2:43 am

@wimoos: if you add:
Code:
.org $bfff
.byte $ff
as the last 2 lines line of the source it should fill the remaining space with $FF so that it works as a cartridge image in vice.


Thanks for the suggestion, I fixed it


Regards,

Wim.
PAL, two-prong VIC20 on 65C02 with 3k RAM expansion internal, 32k NOVRAM expansion external, DS1307 RTC and S-Video mod; 64HDD in FreeDOS on a thin-client; selfwritten 65asmgen; tasm; maintainer of WimBasic

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

Re: New version of WimBasic

Postby wimoos » Mon Oct 19, 2015 7:03 am

Yet another new version of WimBasic is available.

I managed to create enough space to reinstate the HARDCOPY statement. In order to retain backward compatibility with ExBasic, I assigned it the same token value it had there. The token value for UNNEW thus changed: this should not present a problem.

Wrapping it up: WimBasic is ExBasic, minus the DEC() function, but plus a load of extra features (such as SuperNumbers, WHILE-WEND), bugs fixed and speed improvements ! Enjoy !

You can find WimBasic at http://wimbasic.webs.com

Regards,

Wim.
PAL, two-prong VIC20 on 65C02 with 3k RAM expansion internal, 32k NOVRAM expansion external, DS1307 RTC and S-Video mod; 64HDD in FreeDOS on a thin-client; selfwritten 65asmgen; tasm; maintainer of WimBasic

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

Re: New version of WimBasic

Postby wimoos » Wed Aug 30, 2017 11:57 am

After two years, I have released yet another new version of WimBasic, in which more improvements have been implemented.

The most noticeable improvements are around the PRINT USING statement.

In previous versions:
1) a formatting string containing double quotes would be misinterpreted
2) the syntaxis for printing to a file (PRINT USING#1, "<format>") was incorrect
3) the tape-buffer was used for temporary storage of the output string (limiting the output to 192 characters and interfering with tape I/O)
4) the implementation of rounding decimals was dodgy

This is now fixed:
1) the format string may now hold double quotes and yield correct results
2) the syntaxis is now PRINT#1,USING "<format>", this also works with the CMD statement
3) regular stringbuffer storage is now used for the output string
4) the dodgy code is removed, so now it truncates (use ROUND() to obtain rounded values)

Regards,

Wim.
PAL, two-prong VIC20 on 65C02 with 3k RAM expansion internal, 32k NOVRAM expansion external, DS1307 RTC and S-Video mod; 64HDD in FreeDOS on a thin-client; selfwritten 65asmgen; tasm; maintainer of WimBasic


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 1 guest