User`s manual
mikroBASIC
- Basic Compiler for Microchip PIC microcontrollers
We recommend careful use of absolute directive, because you may overlap two
variables by mistake. For example:
dim Ndot as byte absolute $33
' Variable will occupy 1 byte at address $33
dim Nrem as longint absolute $30
' Variable will occupy 4 bytes at $30, $31, $32, $33,
' so changing Ndot changes Nrem highest
' byte at the same time
mikroBasic uses internal algorithm to distribute variables within RAM. If there is
a need to have variable at specific predefined address, use the directive absolute.
Also if, for some reason, you want to overlap existing variables, use the directive
absolute.
program lite
' example for P16F877A
dim image_trisa as byte absolute 133
main:
image_trisa = $ff
end.
MikroElektronika:
Development
tools
-
Books
-
Compilers
mikroBASIC
making it simple...
49
page
Example
Important
Runtime
Behavior