Q-Code User Manual
Ver. 7.0 2021/11/30
103
...
}
Ex.
[ASM]
ABC
{
mvla
5
……
mvam pa
}
[Path]
P1: ABC
; Call Assembly.
Note: Because Q-Code dynamically allocates User RAM, when inserting ASM in Q-Code, users
have to check which Page is RAM defined to. Users need to switch RAM page in
Assembly code.
3.9.23 C-Code
C-Code section allows users to write any legal C code. The code written in this section will directly
copy to C Compiler for compiling.
Q-Code
only parses the function definition. The functions defined in
C-Code section can be called directly by code in
[Path]
.
C language is case sensitivity, but
Q-Code
is not case sensitivity. If there are two functions with the
same name, but cases are different,
Q-Code
will always find the first C function in the
[Path]
section. It
is recommended that do not define the same function names with different cases in C-Code Section.
C-Code section can read / access the defined variables of
section directly. When reading /
accessing variables, please use lowercase letters.
Type
Size
Range
VAR8
8-bit (1-byte)
0 ~ 0xFF
VAR16
16-bit (2-byte)
0 ~ 0xFFFF
VAR32
32-bit (4-byte)
0 ~ 0xFFFFFFFF
The name of available variable starts with A-Z letter, and the second character can start with A-Z, 0-9,
and the bottom line, and cannot conflict with reserved words. The variables used in NX1 are declared
in this paragraph and their data size is defined.
Note: NX1 supports Variable section.