User Tools

Site Tools


vbasic

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
vbasic [2020/09/16 13:54] – [VBADLINE] silverdrvbasic [2022/11/24 09:40] (current) – [DLOFF] silverdr
Line 25: Line 25:
 ====== Initialisation ====== ====== Initialisation ======
  
-As part of initialisation process VBASIC installs itself in the RAM area, address of which is normally occupied by BASIC ROM code, and adds additional routines at the very top of memory available for BASIC programs. It also verifies the presence of an installed BeamRacer card and activates it if found. Thanks to that your programs do not need to perform any additional steps to check and activate BeamRacer. Last but not least it adds helper routines and modifies several system variables and vectors in order to provide correct information about available memory and enable seamless experience with all the standard behaviour for STOP, STOP/RESTORE etc. working as usual, while actively maintaining both the VBASIC extension and BeamRacer active.+As part of initialisation process VBASIC installs itself in the RAM area, address of which is normally occupied by BASIC ROM code, and adds additional routines at the very top of memory available for BASIC programs. It also verifies the presence of an installed BeamRacer card and activates it if found. Thanks to that your programs do not need to perform any additional steps to check and activate BeamRacer. Last but not least it adds helper routines and modifies several system variables and vectors. This allows to provide correct information about available memory and enables seamless BASIC programming experience. As a result all the standard behaviour for STOP, STOP/RESTORE etc. remains unchanged, while actively maintaining both the VBASIC extension and BeamRacer active at the same time.
  
 ====== Features ====== ====== Features ======
Line 175: Line 175:
 which configures which configures
  
-  * PORT #0+  * Conveyor #0 (connected to VASYL PORT #0)
   * to point to VASYL memory address 0 ($0000)   * to point to VASYL memory address 0 ($0000)
   * with the default step of 1   * with the default step of 1
Line 320: Line 320:
  
 __Examples__: __Examples__:
-  100 DLOFF : REM TURN DISPLAULIST EXECUTION OFF+  100 DLOFF : REM TURN DISPLAYLIST EXECUTION OFF
  
 ==== DLON ==== ==== DLON ====
Line 554: Line 554:
 __Synopsis__: ''RACER <NUM>'' __Synopsis__: ''RACER <NUM>''
  
-Where <NUM> can be 0, 1, 2 meaning+Where <NUM> can be 0, 1, 2, 3 meaning
   * 0 - BeamRacer inactive   * 0 - BeamRacer inactive
   * 1 - BeamRacer active but RUN/STOP-RESTORE combination deactivates it   * 1 - BeamRacer active but RUN/STOP-RESTORE combination deactivates it
   * 2 - BeamRacer active and automatically reactivated after every RUN/STOP-RESTORE (default)   * 2 - BeamRacer active and automatically reactivated after every RUN/STOP-RESTORE (default)
 +  * 3 - Disable VBASIC without changing BeamRacer status (VBASIC V1.2 and higher)
  
 __Examples__: __Examples__:
Line 590: Line 591:
 STATEMENT: Assembles [[:isa#badline|BADLINE <RASTERLINES>]] and stores the result in memory STATEMENT: Assembles [[:isa#badline|BADLINE <RASTERLINES>]] and stores the result in memory
  
-__Synopsis__: ''VBADLINE <RASTERLINES>''+__Synopsis__: ''VBADLINE [<RASTERLINES>''
   * RASTERLINES is a 3-bit integer number in the range 0..7   * RASTERLINES is a 3-bit integer number in the range 0..7
  
Line 607: Line 608:
 ==== VBRA ==== ==== VBRA ====
 ---- ----
-DISPLAYLIST: Continue Display List execution at offset <OFFSET>+DISPLAYLIST: Continue Display List execution at address <address>
  
-STATEMENT: Assembles [[:isa#bra|BRA <OFFSET>]] and stores the result in memory+STATEMENT: Assembles [[:isa#bra|BRA <ADDRESS>]] and stores the result in memory
  
-__Synopsis__: ''VBRA <OFFSET>''+__Synopsis__: ''VBRA <ADDRESS>|*<OFFSET>'' 
 +  * ADDRESS is a memory address within the -128..127 range from the current one
   * OFFSET is an 8-bit signed number from range -128..127   * OFFSET is an 8-bit signed number from range -128..127
  
Line 624: Line 626:
 999 VEND 999 VEND
 </code> </code>
-FUNCTION: TBD 
  
 +<code basic [highlight_lines_extra="2"]>
 +[...]
 +200 VBRA 100 : REM CONTINUE AT ADDRESS $64
 +999 VEND
 +</code>
  
 +<code basic [highlight_lines_extra="2"]>
 +[...]
 +200 VBRA *-2 : REM INFINITE LOOP
 +999 VEND
 +</code>
 +FUNCTION: Returns assembled [[:isa#bra|BRA <OFFSET>]]
 +
 +__Synopsis__: ''VBRA(*<OFFSET>)''
 +
 +__Examples__:
 +  A = VBRA(*+10): REM ASSEMBLE AND ASSIGN THE RESULT TO A VARIABLE
 +  
 +__Discussion__: While it is technically possible to use VBRA(<ADDRESS>) notation also in function mode, it is not very useful.
 ==== VDECA ==== ==== VDECA ====
 ---- ----
Line 640: Line 659:
 110 VWAIT $33,0  : REM WAIT FOR FIRST PAPER LINE 110 VWAIT $33,0  : REM WAIT FOR FIRST PAPER LINE
 120 VSETA 12     : REM TWELVE TIMES 120 VSETA 12     : REM TWELVE TIMES
-130 VLABEL A%    : REM LOOP CODE BEGINS HERE+130 LABEL A%     : REM LOOP CODE BEGINS HERE
 140 VMOV $21, 14 : REM LIGHT BLUE 140 VMOV $21, 14 : REM LIGHT BLUE
 150 VDELAYV 8    : REM DELAY EIGHT RASTERLINES 150 VDELAYV 8    : REM DELAY EIGHT RASTERLINES
vbasic.1600289671.txt.gz · Last modified: 2020/09/16 13:54 by silverdr