Programming
in STEP 7-Micro/Win
8.6 Variable Memory Allocation
The following describes the variable memory allocation.
Variable memory for the library MicroScale
Variable
memory-
Byte
Name Type
Default
Comment
VB n
Actual_Process_Value
BYTE
B#16#0
Display, which process value is currently output to position
VW n+2.
0: Gross/Net weight
1: Tare weight
2: Gross process value
3: Net process value
4: Tare process value
5: Filtered raw value
6: Unfiltered raw value
To use the process value, the number must correspond with
the definition in position VB n+10. The value that is output to
position VW n+2 only corresponds with the desired selection
in position VB n+10 if the number matches.
VB n+1 Reserved
INT
0
Reserved
VW n+2 Process_Value
WORD
W#16#0
Current process value
VB n+4 Bit_Messages
BYTE
B#16#0
Information on command processing:
Bit0: Command is processed
Bit1: Command processed with no error
(TRUE for 1 cycle)
Bit2: During command processing, an
error has occurred (=synchronous error)
(TRUE for 1 cycle)
Bit3...7: Reserve
VB n+5 Synchronous_Error_Code
INT
0
Synchronous error messages
Number of the message if bit 2 was set in variable VB n+4
for one cycle.
VB n+6 Asynchronous_Error_Bits
BYTE
B#16#0
Asynchronous error messages
Operating error bits Allocation see chapter 7-40
VB n+7 Refresh_Counter
BYTE
B#16#0
Refresh counter
Number of the measurement cycle in the SIWAREX module,
which originates from the current process value.
VW n+8 Scale_Status_Bits
WORD
0
Scale status
Status bits see chapter 5-32
VB n+10 Select_Process_Value
BYTE
B#16#0
Current process value selection for the display in position
VW n+2:
(see also VB n: “Actual_Process_Value”)
VB n+11 Command_Code
INT
0
Command code
Number of the command that is to be triggered next. Always
enter the number of the command first and then trigger the
command (VB n+12, Bit 0).
VB n+12 Bit_Commands
BYTE
B#16#0
Bit commands:
Bit 0: Command trigger:
Bit is set by the edge, which sets the bit back again
automatically.
Bit 1…7: Reserved
Reserved
INT
0 Reserved
VW n+14 Preset_Tare_Value
INT
0
Preset tare weight
This variable is used for defining a “preset” tare weight.
VW n+16 Lifebit_Counter
WORD
W#16#0
Internal counter to lifebit check
(Only to be used for library MicroScale)
VW n+18 Lib_Error_Bits
WORD
W#16#0
Error during library processing
(=Library parameter “SBR_Error_Bits”)
n = Start byte in variable memory, see library parameter “FirstVB_POINTER”
Table 8-1
Variable memory allocation
SIWAREX MS 8-49