1. Obtaining, Toolboxes, Prices and Infos about PowerBASIC
1.1. The Current Versions of PowerBASIC
1.2. The Original Distributors of PowerBASIC
1.3. German Speaking Area
1.4. German PowerBASIC Prices
1.5. Denmark, Norway, Sweden and Finland
1.6. New in Version 3.1 of PowerBASIC
1.7. New in Version 3.2 of PowerBASIC
1.8. New in Version 3.5 of PowerBASIC
1.9. PowerBASIC 4.0 - The next Generation / Wishlist
1.1. The Current Versions of PowerBASIC
The current Version of PowerBASIC in Germany (in January 1998) is
Version 3.50. This Version has been available in the US and other
countries since December 1997.
1.2. The Original Distributors of PowerBASIC
PowerBASIC was and is developed in the United States and there are
multiple possibilites to get contact to these people. Here are the
currently known addresses from PowerBASIC Inc.:
Address:
PowerBASIC, Inc.
1978 Tamiami Trail S.#200
Venice, FL 34293
Ordering : +1 (800) 780-7707
Service : +1 (941) 408-8700
Fax : +1 (941) 408-8820
InterNet:
World Wide Web : www.powerbasic.com
List of InterNet Sites : info@powerbasic.com
Ordering : order@powerbasic.com
Sales and Marketing : sales@powerbasic.com
Technical Support : support@powerbasic.com
Suggestions for future
PowerBASIC Versions : suggest@powerbasic.com
FTP- & WWW-Sites:
Newsgroups and Conferences on the Web:
1.3. German Speaking Area
In Germany PowerBASIC is distributed by "Kirschbaum Software GmbH".
The current address is:
Kirschbaum Software GmbH
Kronau 15
83550 Emmering
GERMANY
Phone: +49-8067-9038-0
Fax : +49-8067-903898
The current Version of PowerBASIC is Version 3.50. Following Toolboxes
are available from Kirschbaum:
PB/DLL - PowerBASIC DLL-Compiler for Windows
PowerGRAPH - for graphical Menu systems (PCX, Fonts, etc.)
PowerISAM - Databases (also available in English from PowerBASIC Inc.)
PowerTOOLS - SAA-Shell, Helpsystem, helpfull Routines
PB/xtra - Collection of Shareware programs and Source code
Kirschbaum does not have a Mailbox or any official EMail addresses!
There are some EMail addresses and Support-Areas or unofficial
Newsgroups etc. from the Toolbox Developers. In this case please see
the Manual of the Toolbox.
1.4. German PowerBASIC Prices
All prices noted here are NOT validated. Changes can occur at any time!
A currently valid pricing Information can be optained from Kirschbaum
by FAX.
Complete Version: 199,-DM
Complete Version 3.5 for Students, Pupils: 150,-DM
Update from VOBIS-Basisversion 2.10f to V3.5: 149,-DM
Update from V2.10 to V3.5: 149,-DM
Update from a 3.x-Version to V3.5: 36,80DM
1.5. Denmark, Norway, Sweden and Finland
In some european countries (incl. Germany and Austria) PowerBASIC is
distributed by:
Berggreen Service
Lodsgaarden A 111
DK-2791 Dragoer
DENMARK
info@berggreen.dk
http://www.berggreen.dk
1.6. New in Version 3.1 of PowerBASIC
- Userdefined Type- and Union-Variables can be compared directly.
- Constants in Binary, Hex or Octal Format (&B, &H, &O) can be set
to a specific Datatype, by simply adding the correct Identifier.
Examples:
A?? = &HFFFF?? '= 65535
B% = &HFFFF% '= -1
- Constants (%Test) can have a 64-Bit Range (signed) from this
PowerBASIC Version on.
Examples:
%MaxNumber = 500000
%Konst1 = &HFFFF '= -1 (Integer)
%Konst2 = &H0FFFF '= 65535 (Long)
When using Binary, Hexdecimal or Octal Numbers, adding a proceeding
Zero defines whether the calculated Value is signed or not.
- BIN$, HEX$ and OCT$ can now calculate Values up to 32Bit Long-
Integer.
- From Version 3.1 on you can give alternative Names to SUBs or
FUNCTIONs, with which you can call these Subroutines from within
OBJ-Routines (compiled with Assembler or C).
Example:
SUB MySub ALIAS "_my_sub" (Var1%,Var2$) PUBLIC
PRINT "Hello", Var1%, Var2$
END SUB
- The keyword ANY in a definiton of a Procedure allows the passing of
a parameter of any type. The parameter is then passed by REFERENCE
as a 32Bit Address. To let the Programm know what kind of type it
is you should pass a Type identification as the first parameter to the
Procedure. When this Procedure is coded in PowerBASIC, the Inline-
Assembler must be used to pass on the parameters.
Example:
i% = 11
CALL TestAny(0,i%) 'the free parameters must be Variables
s$ = "Hello"
CALL TestAny(1,s$)
SUB TestAny(ParamType AS INTEGER, ANY)
DIM Int.Param AS INTEGER
DIM String.Param AS STRING
SELECT CASE ParamType
CASE 0 'Integer
! les bx, [bp+6] :Load Offset of Var. in BX
! mov ax, es:[bx] ;Load Value of Var. in AX
! mov Int.Param, ax ;Load Varibale to AX
PRINT Int.Param
CASE 1 'String
;Load Offset of Stringmarker
! les bx, [bp+6] ;into BX
! mov ax, es:[bx] ;Load Stringmarker into AX
! mov String.Param,AX
PRINT String.Param
END SELECT
END SUB
- The Return value of FUNCTIONs written with the Inline-Assembler can
now be set without using a temporary Variable. The Keyword FUNCTION
is used for this.
Example:
PRINT AsmTest(2)
FUNCTION AsmTest(BYVAL int.param AS INTEGER) AS INTEGER
! mov ax, int.param
! inc ax
! mov FUNCTION, ax ;the Value will be returned
END FUNCTION
(Also see chapter 'Hints with the Inline-Assembler')
- The use of FUNCTION instead of the Functionname is also possible
with FUNCTIONs coded in BASIC.
Example:
PRINT FuTest(2)
FUNCTION FuTest(BYVAL int.param AS INTEGER) AS INTEGER
FUNCTION = int.param + 1
END FUNCTION
- The Function FRE() was extended:
FRE(-3) returns the free Space on the Stack
FRE(-4) returns the maximum Length available for dynamic Strings, set
using $STRING
FRE(-5) returns the Number of used Stringsegments
FRE(-6) returns the Number of unused Blcoks in the current
Stringsegment
FRE(-7) returns the amount of unused Memory in the current
Stringsegment
1.7. New in Version 3.2 of PowerBASIC
- Data Pointers
- Code Pointers
Following Jumps can now be executed directly in BASIC:
"CALL DWORD x", "GOTO DWORD x" ans "GOSUB DWORD x". In this case "x"
is the 32Bit Pointer to a SUB/Function or the Label. (There is a
DIR$- Demo to the new Pointer- Functions.)
- 32-Bit implementation of: STRPTR32, VARPTR32 und CODEPTR32
- Pointer to Structures can now be passed on to a SUB/FUNCTION using
the "BYVAL" Keyword.
Example:
DECLARE SUB MySUB(x AS INTEGER)
DIM z AS INTEGER PTR
z = &HB8000000
CALL MySUB(BYVAL z)
- 16550 UART Support
- The LEN() Function now also returns the length of User-defined
Structures.
- Labels ans Variables can now contain the so-calles Underlines '_' so
that they can be kept appart easier.
1.8. New in Version 3.5 of PowerBASIC
- some important Bugfixes
- ASCIIZ strings: Dim xyz as Asciiz * 100.
- Arrays as User Type Members, may have one or two static dimensions.
- & operator is recognized for string concatenation.
- STRING PTR is now legal as a Type/Union member.
- $ELSEIF metastatement.
- ASC(x$,n) function and statement offer an optional starting position.
- REDIM PRESERVE of the outer bound of dynamic and huge arrays only.
- RND() is a legal substitute for RND.
- RND(x,y) returns a LONG INTEGER in the range of x -> y.
- TRIM$() is a combination of LTRIM$() and RTRIM$().
- Indexed pointers: @xyz[2]
- DIM VIRTUAL x(1000000) arrays in ems memory, may not be dynamic strings
nor used as a ByRef parameter.
- HUGE and VIRTUAL Arrays may use LONG INTEGER indexes. With this
expansion, you may see a slight increase in the size of some code
generation. When a segment is now very close to the 64k limit, it
may require that $SEGMENT metastatements be moved.
- ERRCLEAR statement resets the error flag to nul.
- ERRCLEAR function returns ERR, then resets the error flag to nul.
- ERRCLEAR is a synonym for the old function Errtest.
- CVI(x$[,n]), CVL... offer an optional starting position in the string
- CVL(x$,3) would extract the 3rd through 6th bytes of x$, and
convert the 4 bytes to the corresponding long integer value.
In this case, x$ must be at least 6 bytes long.
- SIZEOF(var) function returns the physical size of a variable,
- particularly useful for determining the maximum length of a fixed-
length string, ASCIIZ string, or user-defined type.
- It always returns 2 for a dynamic string.
- STDIN x, y$ reads up to x characters from the standard input device
(which may be redirected), and assigns them to the string variable
specified. If less than x characters are ready immediately, then a
string shorter than x bytes is returned.
- STDIN LINE, y$ reads one line of text from the standard input device
(which may be redirected), and assigns them to the string variable
specified. When enf-of-file is reached, a one-byte string consisting
of a CHR$(26) is returned.
- STDOUT x$ [;] outputs the string expression x$ to the standard output
device (which may be redirected), followed by a cr/lf. If an optional
trailing semi-colon is included, then the cr/lf is suppressed.
- SETEOF #1 statement has been added to truncate an open file to
its current position.
- FRE(-11) returns the number of unallocated bytes of EMS memory.
1.9. PowerBASIC 4.0 - The next Generation / Wishlist
Such a short time before the release of V3.5 of the Compiler it is
naturally very, very hard to find Points for improvement, but they do
exist anyways.
- XMS Support for VIRTUAL Arrays
- SORT ARRAY Support fuer VIRTUAL Arrays
- 32bit Inline-Assembler
- Syntax Highlighting within the IDE
- A better IDE