This repository was archived by the owner on Aug 27, 2021. It is now read-only.
forked from aanon4/BlueBasic
-
Notifications
You must be signed in to change notification settings - Fork 2
_IF
JBtje edited this page Jun 8, 2015
·
4 revisions
IF <expression>
...
END
IF <expression>
...
ELSE
...
END
IF <expression>
...
ELIF <expression>
...
ELSE
...
END
This code is rather self explaining. Besides mathematical operations, the following logical operators can be used.
& and
| or
^ xor
> larger than
>= larger than or equal
< smaller than
<= smaller than or equal
== is equal
!= is not equal
NEW
10 IF A = 0
20 PRINT "A = 0"
30 END
40 DIM A = 2
50 IF A = 1
60 PRINT "This is not executed"
70 ELIF A > 1
80 PRINT "A=2"
90 END
RUN
The above code prints A=0 and A=2. Note that the variable A is 0 by default.
FOR
IF
GOSUB
DIM
LIST
MEM -
NEW
RUN
END
GOTO
REM
PRINT
REBOOT
RETURN
AUTORUN
CONFIG -
ABS
LEN !
RND
+
-
*
/
%
&
|
^
>
>=
<
<=
=
==
!=
<<
>>
//
TIMER
MILLIS -
DELAY
PINMODE
RISING -
FALLING -
INTERRUPT -
ATTACH -
DETACH -
SERIAL
SPI
ANALOG
I2C
WIRE
TIMEOUT -
WAIT -
PULSE -
BATTERY
GATT
WRITENORSP -
NOTIFY -
INDICATE -
GATT ONREAD -
GATT ONWRITE -
GATT ONCONNECT
GATT ONDISCOVER -
ADVERT
SCAN
ACTIVE -
DUPLICATES -
BTPOKE
BTPEEK