Qu-Bot, A Quickly Programmable Robot User’s Manual
Page
41
of
52
7. Programming in Qu-Bot Visual LAB (Operational Blocks)
Many a times we need variables which change values depending upon the as the code
progresses.
7.1. Data Types
There are three types of variables in Qu-Bot.
1.
Character Variable : 0-255
2.
Integer Variable: -327868 to 32767
3.
Long Variables: -2147483648 to 2147483647
7.2. Variables in Qu-Bot
Following is the list of general purpose variables in Qu-Bot
1.
32 Character Variables: CHAR1 to CHAR32
2.
32 Integer Variables: INT1 to INT32
3.
10 Long Variables: LONG1 to LONG10
4.
10 Counter variables: CNT1 to CNT10 (Character Data Type)
7.3. Variable Block
This block is used to initialize variables. This block can initialize any variable in section
7.2 and UART Input and IR Input. Left click on the variable block in code flow and
check attribute explorer.
Variables can be initialized like blow.
1.
Variable1 = Constant
2.
Variable1 = Variable2
Select Variable1 from variable name dropdown box.
Select Value type from “Variable” or “Constant”.
If you have selected Variable choose variable from the list or else type constant value.
Once the variables are initialized then only they will be populated in condition builder
block variable list.
7.3.1. Special Cases
This block is used to initialize UART Input and IR Input. Select Variable Name as any
one of them in attribute explorer window.
In this case rest of the blocks needs not to be initialized.
These variables are kept separate because of some reason.
7.3.1.1. UART Input
Refer section 4.5.4 where we used Serial Terminal. Here we have not used output
window. This window can be used to transfer characters to Qu-Bot. Whenever you