MultiLoad Slate
Reference Guide
Including:
MultiLoad II Slate
MultiLoad II SMP Slate
MultiLoad II SCS Slate
Firmware Version 4.34.01
Aug 2019
T O P T E C H S Y S T E M S
MultiLoad Slate Reference Guide
Toptech Systems
1124 Florida Central Parkway
Longwood, FL 32750
Phone 407.332.1774
Disclaimer
Toptech Systems assumes no responsibility for damages resulting from installation or use of its products.
Toptech Systems will not be liable for any claims of damage, lost data, or lost time as a result of using its
products.
Table of Contents
Overview ............................................................................................. 1
Chapter 1 SQLite ......................................................................... 2
How to Create a Database Schema ......................................................... 2
Chapter 2 Lua ............................................................................... 3
Syntax ...................................................................................................... 3
Data Types ............................................................................................... 4
How to Execute SQL Commands ............................................................ 5
Scripts ...................................................................................................... 7
Functions ................................................................................................. 8
2.5.1 Prompting Functions ................................................................................................. 8
2.5.2 BOL Functions ........................................................................................................ 24
MultiLoad Variables ............................................................................... 29
2.6.1 Parameter Format Types ........................................................................................ 29
2.6.2 MultiLoad Information Parameters .......................................................................... 57
2.6.3 RCU Level Parameters ........................................................................................... 65
2.6.4 SCS Level Parameters ........................................................................................... 86
2.6.5 Bay Level Parameters ............................................................................................. 88
2.6.6 Preset Level Parameters ........................................................................................ 99
2.6.7 Meter Level Parameters ........................................................................................ 135
2.6.8 Component Level Parameters .............................................................................. 167
2.6.9 Additive Level Parameters .................................................................................... 192
2.6.10 Sampler Level Parameters ................................................................................. 214
2.6.11 Transaction Parameters ...................................................................................... 219
2.6.12 Totalizer Parameters ........................................................................................... 237
2.6.13 Product Definition Parameters ............................................................................ 250
Chapter 3 REST API ............................................................... 261
Authentication ...................................................................................... 261
Methods ............................................................................................... 261
Responses ........................................................................................... 262
3.3.1 GET ....................................................................................................................... 262
3.3.2 POST .................................................................................................................... 262
3.3.3 PUT ....................................................................................................................... 262
3.3.4 DELETE ................................................................................................................ 263
Link Headers ........................................................................................ 263
URL Templates .................................................................................... 264
API Resources ..................................................................................... 264
3.6.1 REST Entry Point .................................................................................................. 264
3.6.2 Database ............................................................................................................... 265
3.6.3 Files ....................................................................................................................... 266
3.6.4 Logs ...................................................................................................................... 267
3.6.7 Transactions .......................................................................................................... 267
3.6.8 Last Transaction .................................................................................................... 268
3.6.9 MultiLoad Information............................................................................................ 268
3.6.10 Equipment Parameters ....................................................................................... 268
3.6.11 Totalizers ............................................................................................................. 269
Examples ............................................................................................. 269
3.7.1 Creating a database record .................................................................................. 269
3.7.2 Fetching a database record .................................................................................. 270
3.7.3 Updating a database record .................................................................................. 270
3.7.4 Deleting a database record ................................................................................... 271
Additional Resources ........................................................................... 271
3.8.1 Postman ................................................................................................................ 271
3.8.2 Learn REST: A RESTful Tutorial .......................................................................... 271
Chapter 4 Code Samples ...................................................... 273
License ................................................................................................ 273
sql_init.sql ............................................................................................ 273
authorize_transaction.lua ..................................................................... 275
authorize_batch.lua .............................................................................. 280
process_transaction.lua ....................................................................... 283
build_bol.lua ......................................................................................... 284
background.lua .................................................................................... 287
Chapter 5 Firmware Revision History ............................... 290
Table Of Figures
Example Code 1.1 Initialize Database Schema ....................................................2
Example Code 2.1 Table Constructor ...................................................................4
Example Code 2.2 Functions ................................................................................5
Example Code 2.3 SQLite .....................................................................................6
Example Code 2.4 SQLite Prepare and Evaluate .................................................7
Example Code 2.5 Processing a Transaction ................................................... 237
Example Code 2.6 Product Management .......................................................... 253
Example Code 2.7 Products Schema................................................................ 255
Example Code 2.8 Product Creation Example .................................................. 257
Example Code 4.1 sql_init.sql ........................................................................... 274
Example Code 4.2 authorize_transaction.lua .................................................... 279
Example Code 4.3 authorize_batch.lua............................................................. 282
Example Code 4.4 process_transaction.lua ...................................................... 283
Example Code 4.5 build_bol.lua ........................................................................ 286
Example Code 4.6 background.lua ................................................................... 289
MULTILOAD SLATE REFERENCE GUIDE
1
Overview
The traditional MultiLoad II process flow has three basic steps: collect and validate data before a transaction
occurs; automate and control the loading process and the equipment; process and package the transaction
information. MultiLoad Slate gives you the ability to customize steps one and three by using SQLite
(http://sqlite.org/ and http://lua.sqlite.org/) and the Lua scripting language (http://www.lua.org/).
To help get you up to speed quickly, we have included sample code which creates a driver database table using
SQLite. We have also provided some example Lua scripts which display a series of prompts, validates the user’s
input, and builds a custom BOL. The purpose of this document is to use example code to help illustrate how
MultiLoad Slate works and to help you get acquainted with SQLite, Lua, and our RESTful API.
Chapter one will cover SQLite and how to create a database schema. Chapter two will briefly go over the Lua
programming language and provide all the functions and variables available for use in your Lua scripts. Chapter
three will cover the REST API, and chapter four contains the example code which mimics the basic standalone
functionality of a regular MultiLoad.
The sample code in this guide is provided as-is and for exemplary purposes only. Your use of the sample code and
this guide is your responsibility. The sample code is not supported under any standard Toptech Systems support
program or service.
All sample code in this manual is Copyright (c) 2016 Toptech Systems and is provided to you under the MIT
license. A copy of the MIT license can be found here: https://opensource.org/licenses/MIT
Note that this guide covers Slate functionality only. For information about base MultiLoad firmware please
consult the MultiLoad II Users Guide. For information about wiring please consult the MultiLoad II Installation
Guide. For information about the MultiLoad register interface and Modbus communication, please reference the
MultiLoad II Communications Guide. Updated versions of all manuals, including this one, are available on our
website at http://www.toptech.com.
2
Chapter 1 SQLite
MultiLoad Slate incorporates the SQLite database engine in its firmware. SQLite offers a full-featured SQL
implementation and is ACID compliant.
This chapter contains one section, and it will cover how to create a database schema and provide some example
code.
How to Create a Database Schema
A database schema defines the structure of the database. Using SQL, you will construct how the data is organized
and formulate the constraints that will be applied to that data.
After the processing mode has been configured to SLATE, the firmware will look for a sql_init.sql file on the SD
card when the unit boots up. The sql_init.sql file is where the database schema is defined.
CREATE TABLE Driver(
id INTEGER PRIMARY KEY AUTOINCREMENT,
driver_no char( 8) NOT NULL,
name char(50) ,
pin_req char( 1) , -- Y/N/F
pin_code char( 4) , -- PPPP
access_from char( 8) , -- HH:MM:SS
access_to char( 8) , -- HH:MM:SS
access_days char( 7) , -- YYYYYYY
locked char( 1) , -- Y/N
lockout_reason char(40) ,
UNIQUE (driver_no) );
Example Code 1.1 Initialize Database Schema
In example code 1.1, the CREATE TABLE command is used to define a table named Driver. A CREATE TABLE
command specifies the table name, the name of each column (field) in the table, the declared type of each field
(char, integer, etc...), and some constraints (optional).
The idfield is declared as an integer and is defined as the primary key. The keyword PRIMARY KEY is used to
declare a field that must be unique. Each table can only have one primary key, but the primary key can be made
of up of multiple fields.
Chapter
1
3
Chapter 2 Lua
Lua is a scripting language that will be executed by the firmware at different times during the loading process.
The loading process is broken down into four stages, with each stage having its own Lua script file. There is also
one additional script file that will always be running in the background. Please note that Lua version 5.3 is the
current version being used by the MultiLoad firmware.
This chapter will cover the Lua scripting scripting language and how it can be used with MultiLoad Slate. Section
one and two will cover some basic concepts and information of the lua language. Section three will explain how
to execute SQL commands from your scripts. Section four will explain how the scripts work and when they will be
executed. Sections five through seven will describe all the functions and variables that are available for use in
your scripts.
This chapter does not cover everything about the Lua language, but the reference manual and tutorials for Lua
can be found at http://www.lua.org and at http://lua.sqlite.org.
Syntax
Lua looks and feels like many other programming languages. It is considered a free-form language that ignores
spaces and comments. Comments start with a double hyphen (--) and run until the end of the line unless the
double hyphen is immediately followed by a double bracket ([[). The double bracket allows for larger block
comments which will run until the corresponding closing double brackets (--[[ comment ]]).
Variable names can be any string of letters, digits, and underscores. However, they cannot start with a number
and cannot be any of the following keywords:
and
false
local
then
break
for
nil
true
do
function
not
until
else
goto
or
while
elseif
if
repeat
end
in
return
Chapter
2
4
Literal strings can be defined using single or double quotes, and can be concatenated using two dots (..) see
the code snippet below for an example:
LogMsg(LOG_LEVEL_INFORMATIONAL, "SQL Err: " .. db:error_message())
Data Types
There are eight basic types: nil, boolean, string, number, table, function, userdata, and thread; for this document
we will cover the first six.
The type nil represents the absence of a useful value. When a new variable is declared and is not defined a value,
itsvalue will be initialized to nil. If nil is used in an expression, it will be evaluated as false. The type boolean can
only have two values, true and false.
The type string represents a sequence of bytes which can contain any 8-bit value. A value of zero can be
represented as\0’.
The type number can be represented as a 32-bit integer or a 64-bit floating point number. Lua will automatically
convert numbers between the two types if needed.
The type table is like an array in the C programming language, except that it is an associative array. Therefore,
arrays can be indexed by using any Lua value type except nil. Tables can also have a mix of value types and all Lua
value types are acceptable. See the example code below:
a = { j = 4; “y”; 20; [50] = “hello”; test = 65 }
-- Now we will create a table b
-- which will be the equivalent of table a
b = {}
b[j] = 4
b[1] = “y”
b[2] = 20
b[50] = “hello”
b.test = 65
-- table a is equal to table b
Example Code 2.1 Table Constructor
When declaring a table, you can create key/value pairs by wrapping the key with brackets. So, the following line
from the example code above creates a key/value pair with the key being “50 and the value being “hello”:
b[50] = “hello”
The function type lets you store a block of code into a variable. That variable can then be used in multiple places
to execute the same block of code without having to duplicate it. Functions are defined by using the keyword
function in the following format:
function foo (arg1, arg2) return arg1 + arg2 end
5
The code snippet above defines a function to a variable named foo, which takes in two arguments that is
specified inside the parenthesis (arg1, arg2). This function adds the two arguments together and uses the
keyword return to return the result. Functions in Lua are different from functions in other programming
languages, like C. Lua functions are a data type just like a string or a number. So, this means that the
variable named foo, which has value of type function, can be changed at runtime. This is different than C
where a function cannot be changed after compile time. It is also important to note that functions are
passed by reference, so when you assign a function to another variable you are passing a “handle” to that
same function. If the function foo is assigned to other variables and foo changes, all the variables
referencing foo will also change. See the example code below for some examples of how functions can be
defined and called:
function foo (arg1, arg2) return arg1 + arg2 end
-- This is the same as the above
foo = function (arg1, arg2) return arg1 + arg2 end
x = foo(1, 2) -- x = 3
x = foo(4, 5, 6) - extra arguments are dropped and x = 9
-- it is possible to define a function a varying number of
-- arguments by using three dots (...)
foo = function (...) t= {...} print(t[2]) return end
foo(“x”, “y”, “z”) - calling foo outputs: “y”
-- it is possible to return more than one value
function foo (x, y) return x+y, x, y end
result, arg1, arg2 = foo(1, 2) -- result =3, arg1 =1, arg2 =2
-- it is possible to add a function to a table
t = {f= foo}
result, arg1, arg2 = t.f(1, 2) -- result =3, arg1 =1, arg2 =2
Example Code 2.2 Functions
How to Execute SQL Commands
This section will cover how to execute SQL commands from your Lua scripts. The following is an outline of some
of the core SQLite routines that will need to be used to execute SQL commands in Lua:
open()
prepare()
step()
finalize()
close()
The open method opens a new connection to a SQLite database file and returns a database object. This
will be the first SQLite call after loading the SQLite3 package. Once a connection to the database file has
6
been made, you will need to call the prepare function every time you want to execute a SQL statement.
This will convert the SQL statement string into a statement object. The prepare function does not
actually evaluate the SQL statement; it simply “prepares” the statement to be evaluated later using one of
the SQLite evaluation methods.
The step method is one of many methods available that can be used to evaluate a SQL statement. The
step method evaluates the prepared statement and returns a value indicating whether a new row of data
is available to be processed and can be called multiple times until the entire statement is done being
evaluated or an error occurs. There are many other evaluations that can be used besides the step
method, please refer to www.lua.sqlite.org for more information on all the methods available.
The finalize function destroys the prepared statement, and every prepared statement needs to be
destroyed to prevent memory leaks from occurring. The close routine should be called at the very end of
the Lua script, and this routine will close the connection to the database. All prepared statements should
be destroyed before closing the connection.
The following code snippet shows how to include the SQLite package, open the database file, and creates a
function that calls the SQLite prepare function and returns the prepared SQL statement object.
-- The line below includes the SQLite package and everything after
-- the equal sign MUST be used exactly the same way as below.
sqlite3 = require('sqlite3')
-- Opens the database file and load it into memory
db = sqlite3.open('file:/auto/mmc_1/SQL/MULTILOAD.B?cache=shared')
function db_prepare (s)
local stmt
-- log sql message
LogMsg(LOG_LEVEL_INFORMATIONAL,s)
stmt = db:prepare(s)
-- check sql error
if(stmt == nil) then
LogMsg(LOG_LEVEL_INFORMATIONAL,"SQL Err: " .. db:error_message())
end
return stmt
end
Example Code 2.3 SQLite
The following line is very important:
sqlite3 = require('sqlite3')
This line includes the SQLite package and everything after the equal sign must be used the same way as
seen above. The next line is used to open the database file and load it into memory:
db = sqlite3.open('file:/auto/mmc_1/SQL/MULTILOAD.B?cache=shared')
In chapter one we demonstrated how to create a SQL database schema, on bootup the firmware uses the
sql_init.sql file to create the schema and store everything into a database file named MULTILOAD.B. When
a Lua script file runs, it will directly access the database file. Opening a connection directly to the
MULTILOAD.B file makes all database writes atomic..
The db_prepare is just a wrapper function that calls the LogMsg routine before calling the SQL
prepare function. It is not necessary to create such a function; however, this allows you to trace every
7
SQL statement if needed and can be turned on/off by a configuration parameter in the MultiLoad. The
following line is needed to prepare the SQL statement:
stmt = db:prepare(s)
The argument “s” is the SQL statement string that was passed into the function. Once you have a prepared
statement object, you can use any of the evaluation methods provided by the SQLite package
(www.lua.sqlite.org). The code snippet below demonstrates one example of how to prepare and evaluate a
SQL statement:
stmt = db_prepare("SELECT * FROM Driver
WHERE driver_no = '" .. driverNumber .. "';")
if(stmt:step() == sqlite3.ROW) then
driver = stmt:get_named_values()
else
driver = nil
end
stmt:finalize()
Example Code 2.4 SQLite Prepare and Evaluate
The first line calls the db_prepare function that we created earlier with the SQL statement we want to
execute. It prepares the statement to be executed and returns the prepared statement object. The next
line calls the step method to evaluate the next iteration of the prepared statement. It will return one of
the following values:
sqlite3.BUSY
sqlite3.DONE
sqlite3.ROW
sqlite3.ERROR
sqlite3.MISUSE
If the step method returns sqlite3.ROW then a row of data is available, and you can now call a
method like get_named_values to retrieve a Lua table with name/value pairs for each column in that
row. The step method can be called again to retrieve the next row of data if one is available. If
sqlite3.ROW is not returned, the statement has either finished executing or some sort of error has
occurred. Remember to always destroy the prepared SQL statement by calling the finalize method.
Scripts
There are five different scripts that you can create to customize the loading process to fit your needs or the
needs of your customer. Each script has a specific filename that must be used and stored on the SD card in
the LUA directory (root_directory/LUA) for the firmware to be able to execute it. The five available scripts
are listed below:
authorize_transaction.lua
authorize_batch.lua
process_transaction.lua
build_bol.lua
background.lua
8
Each one of these scripts will be executed at different stages of the loading process. With the only
exception being the background.lua script, this script is always meant to run in the background.
The authorize_transaction.lua script is the first script to run when someone cards in from the idle screen
(or presses the NEXT key if a card reader is not being used). This is where you can display prompts and
validate user input to authorize them to start a transaction.
The authorize_batch.lua script will be executed when a user attempts to authorize a new batch. This is
done in the following ways:
When an arm is selected on the load screen (screen that displays a list of all loading arms), a batch
hasn’t already been authorized for that arm, and the user presses ENTER.
After a previous batch has already been completed. The user can select the arm on the load
screen, and press ENTER. This will bring them to the control screen for that arm, from here the
user can press the CLR key which will clear the previous batch and then run the
authorize_batch.lua script.
The process_transaction.lua script is run after the transaction has been ended by the user (card pull or by
pressing the EXIT key twice). This script allows you to take the data from the MultiLoad firmware and insert
it into your own transaction database.
The build_bol.lua script gives you the ability to insert text into a spooler which will then be sent to a printer
if one is configured. This script will be called when any of the following occurs:
After a transaction has been completed and processed. The configuration parameter “Print Ticket”
(located at the RCU level) must be enabled.
Going into Views & Inquiries->Transactions, and selecting an old transaction to be reprinted.
Calling the ReprintBOL function from another script.
The background.lua script will only be started once on bootup. You must contain everything in a never-
ending loop if you would like it to continuously run in the background. If the script does happen to exit, you
will have to power cycle the unit for it to run again.
Functions
2.5.1 Prompting Functions
The firmware comes with a handful of functions that we have created to help perform MultiLoad specific tasks.
All available functions are listed below:
AuthorizePreset(preset, authorize, product_index, preset_volume, compartment)
Description
Arguments
9
Returns
AuthorizeTransaction(driver)
Description
Arguments
Returns
CalculateGsv(gov, temp, api_table, {})
Description
Arguments
10
Returns
11
ClearScreen(void)
Description
Arguments
Returns
EnablePreset(preset, authorize)
Description
Arguments
Returns
Exit(void)
Description
Arguments
Returns
12
FindLastTransaction(card_id, time_limit)
Description
Arguments
Returns
GetDate(format_string)
Description
Arguments
13
14
Returns
GetCustomLogicValue(custom_logic_line)
Description
Arguments
Returns
15
SetCustomLogicValue(custom_logic_line, value)
Description
Arguments
Returns
GetEntry(void)
Description
Arguments
Returns
GetFCMPort(fcm_number, fcm_port)
Description
Arguments
Returns
SetFCMPort( fcm_number, fcm_port, value)
Description
Arguments
Returns
16
GetInput({row, col, length, password})
Description
Arguments
Returns
GetTermKey(void)
Description
Arguments
Returns
17
GetTime(void)
Description
Arguments
Returns
IsAutoLoad(void)
Description
Arguments
Returns
LogMsg(log_level, message)
Description
Arguments
Returns
18
Message(message)
Description
Arguments
Returns
MessageDenied(message)
Description
Arguments
Returns
MessageDeniedLarge(message)
Description
Arguments
Returns
Outstr(text)
Description
Arguments
Returns
Outstrap({row, col, foreground, background, inverse} , text)
Description
19
Arguments
Returns
Outstrc(row, text)
Description
Arguments
Returns
OutstrcBottom(text)
Description
20
Arguments
Returns
OutstrcBottomLarge(text)
Description
Arguments
Returns
OutstrcLarge(row, text)
Description
Arguments
Returns
OutstrLarge(text)
Description
Arguments
Returns
Outstrp(column, row, text)
Description
Arguments
Returns
21
OutstrpLarge(column, row, text)
Description
Arguments
Returns
Picklist(length, items_text, items_value, input_length, prompt)
Description
Arguments
Returns
Prompt(input_length, text)
Description
Arguments
Returns
22
PromptPIN(length, text)
Description
Arguments
Returns
ReprintBOL(index)
Description
Arguments
Returns
SaveInit(void)
Description
Arguments
Returns
SaveVariable(value, name)
Description
Arguments
Returns
23
SetupWait(void)
Description
Arguments
Returns
Sleep(seconds)
Description
Arguments
Returns
SendCommand(command)
Description
Arguments
Returns
TermKeyNext(void)
Description
Arguments
Returns
24
TermKeyPrev(void)
Description
Arguments
Returns
TraceMessage(trace_level, text)
Description
Arguments
Returns
uSleep(microseconds)
Description
Arguments
Returns
2.5.2 BOL Functions
CopyLinesAbs(src_start_line, src_end_line, dest_start_line)
Description
Arguments
Returns
25
GetCursorLin(void)
Description
Arguments
Returns
GetCursorPos(void)
Description
Arguments
Returns
MoveCursorAbs(line, position)
Description
Arguments
Returns
MoveCursorRel(line_offset, position)
Description
Arguments
Returns
MoveLinesAbs(src_start_line, src_end_line, dest_start_line)
Description
Arguments
26
Returns
WriteCorrectedToMessageRel(line_offset, position)
Description
Arguments
Returns
WriteDateAbs(line, position, epoch_time)
Description
Arguments
Returns
WriteDateRel(line_offset, position, epoch_time)
Description
Arguments
27
Returns
WriteString(max_length, text)
Description
Arguments
Returns
WriteStringAbs(line, position, max_length, text)
Description
Arguments
Returns
WriteStringRel(line_offset, position, max_length, text)
Description
Arguments
Returns
28
WriteStringCenteredAbs(line, center_position, max_length, text)
Description
Arguments
Returns
WriteStringCenteredRel(line_offset, center_position, max_length, text)
Description
Arguments
Returns
29
WriteTimeAbs(line, position, epoch_time)
Description
Arguments
Returns
WriteTimeRel(line_offset, position, epoch_time)
Description
Arguments
Returns
MultiLoad Variables
There are several MultiLoad internal variables that are accessible via Lua. This section will cover everything
that is available.
Nomenclature:
Permissions - This indicates whether the set of parameters have read and/or write access
Firmware Location - This indicates where the parameter is located in the menu structures of the
firmware
Reference - This illustrates how to reference the variables in your Lua scripts.
2.6.1 Parameter Format Types
The parameter format types are used in conjunction with the equipment level parameters. The format types are
represented as strings and determine how the parameter’s value should be interpreted. For example, the format
type for the Card Reader parameter is called CARD_READER_TYPE, which lets the MultiLoad know that the
30
numeric value of this parameter represents which type of card reader has been installed (disabled, captive, non-
captive, etc.). The purpose of this section is to explain how to interpret the values related to each format type.
ADDITIVE_MODE
Description
Parameter type is used to select the when to start injecting additive.
Enum Value
45
Values
Selection
Numerical
Value
START ON BATCH
0
START ON HIGH FLOW
1
START ON VOLUME
2
ADDITIVE_TYPE
Description
Parameter type is used to select the type of additive injector that will be used.
Enum Value
32
Values
Additive Type
Numerical
Value
SOLENOID WITH METER
0
PISTON WITH NORMAL FEEDBACK
1
PISTON WITH INVERTED FEEDBACK
2
PISTON WITH NO FEEDBACK
3
ANALOG VALVE WITH METER (4-20 mA)
4
ANALOG VALVE WITH METER (0-20 mA)
5
ALARM_COUNT_RESET_MODE
Description
Parameter type is used to select how the alarm promotion counter is reset.
31
Enum Value
22
Values
Selection
Numerical
Value
AUTHORIZED
0
CLEAR
1
2 MIN
2
5 MIN
3
15 MIN
4
30 MIN
5
60 MIN
6
3 HRS
7
6 HRS
8
12 HRS
9
24 HRS
10
ALARM_LEVEL
Description
Parameter type is used to set how an alarm can be cleared. This is used for an
alarms Alarm Level and Promoted Level parameters.
Enum Value
14
Values
Selection
Numerical
Value
AUTO
0
DRIVER
1
REMOTE
2
PROGRAM
3
W&M
4
ALARM_TO_HOST_MODE
Description
Parameter type is used to select whether an alarm will be sent to a host system, or
whether it will only be displayed on the device.
32
Enum Value
38
Values
Selection
Numerical
Value
TO HOST
0
LOCAL
1
API_54YG_PRODUCT_TYPE
Description
Parameter type is used to select the type of product that will be used for the
ASTM1250-1980 54YG API table.
Enum Value
33
Values
Product Name
Numerical
Value
NO PRODUCT
0
PROPANE
1
PROPENE
2
BUTANE
3
ISOBUTANE
4
ISOBUTENE
5
CIS-BUT-2-EN
6
TRANS-BUT-2-EN
7
BUT-1-EN
8
BUT-1,3-DIEN
9
METHANOL
10
ETHANOL
11
ISOPROPANOL
12
ISOBUTANOL
13
MTBE
14
TAME
15
BENZOL
16
TOLUOL
17
O-XYLOL
18
M-XYLOL
19
P-XYLOL
20
33
API_ASTM_D1555_PRODUCT_TYPE
Description
Parameter type is used to select the product type that will be used with the ASTM
D1555 API table.
Enum Value
48
Values
Product Name
Numerical
Value
NO PRODUCT
0
BENZENE
1
CUMENE
2
CYCLOHEXANE
3
ETHYLBENZENE
4
STYRENE
5
TOLUENE
6
M-XYLENE
7
O-XYLENE
8
P-XYLENE
9
300 - 350°F HYDROCARBON
10
350 - 400°F HYDROCARBON
11
API_BIO_PRODUCT_TYPE
Description
Parameter type is used to select the type of product that will be used for the PTB-
BIO API table.
Enum Value
36
Values
Product Name
Numerical
Value
NO PRODUCT
0
E5
1
E10
2
E80
3
E85
4
34
E100
5
BENZIN/PETROL
6
DIESEL
7
B5 RM2
8
B7 RME
9
B100 RME
10
B5 SME
11
B7 SME
12
B100 SME
13
API_TABLE_NAME
Description
Parameter type is used to select an API table.
Enum Value
17
Values
API Table Name
Enumeration Name
Numerical
Value
None
NONE
0
ASTM1250-1980 Table 6A
TABLE_6A
49
ASTM1250-1980 Table 6B
TABLE_6B
50
ASTM1250-1980 Table 6C
TABLE_6C
70
ASTM1250-1980 Table 6D
TABLE_6D
85
ASTM1250-1980 Table 23E
TABLE_23E
97
ASTM1250-1980 Table 24A
TABLE_24A
51
ASTM1250-1980 Table 24B
TABLE_24B
52
ASTM1250-1980 Table 24E
TABLE_24E
83
ASTM1250-1980 Table 53B
TABLE_53B
82
ASTM1250-1980 Table 54
TABLE_54
65
ASTM1250-1980 Table 54A
TABLE_54A
53
35
ASTM1250-1980 Table 54B
TABLE_54B
54
ASTM1250-1980 Table 54C
TABLE_54C
56
ASTM1250-1980 Table 54D
TABLE_54D
88
ASTM1250-1980 Table 54AG
TABLE_54AG
73
ASTM1250-1980 Table 54BG
TABLE_54BG
90
ASTM1250-1980 Table 54CG
TABLE_54CG
75
ASTM1250-1980 Table 54DG
TABLE_54DG
74
ASTM1250-1980 Table 54XG
TABLE_54XG
76
ASTM1250-1980 Table 54YG
TABLE_54YG
79
ASTM1250-1980 Table 59E
TABLE_59E
98
ASTM1250-1980 Table 60o
TABLE_60O
99
Table 901A
TABLE_901A
100
TEC
TABLE_TEC
57
TEC Ethanol US
TABLE_TEC_ETH_US
71
TEC Ethanol B40
TABLE_TEC_ETH_B40
201
TEC Ethanol B100
TABLE_TEC_ETH_B100
200
TEC Ethanol E40
TABLE_TEC_ETH_E40
202
TEC Ethanol E100
TABLE_TEC_ETH_E100
203
BIO-PTB
TABLE_BIO_PTB
204
Ethanol Brazil NBR 5992
TABLE_ETH_BRAZIL
205
Hydrocarbon Brazil
TABLE_HYDRO_BRAZIL
206
ASTM1250-2004 Table 5A
TABLE_2004_5A
1013
ASTM1250-2004 Table 5B
TABLE_2004_5B
1014
36
ASTM1250-2004 Table 5D
TABLE_2004_5D
1015
ASTM1250-2004 Table 5X
TABLE_2004_5X
1016
ASTM1250-2004 Table 6A
TABLE_2004_6A
1000
ASTM1250-2004 Table 6B
TABLE_2004_6B
1001
ASTM1250-2004 Table 6C
TABLE_2004_6C
1002
ASTM1250-2004 Table 6D
TABLE_2004_6D
1003
ASTM1250-2004 Table 6X
TABLE_2004_6X
1004
ASTM1250-2004 Table 23A
TABLE_2004_23A
1017
ASTM1250-2004 Table 23B
TABLE_2004_23B
1018
ASTM1250-2004 Table 23D
TABLE_2004_23D
1019
ASTM1250-2007 Table 23E
TABLE_2007_23E
1060
ASTM1250-2004 Table 23X
TABLE_2004_23X
1020
ASTM1250-2004 Table 24A
TABLE_2004_24A
1008
ASTM1250-2004 Table 24B
TABLE_2004_24B
1009
ASTM1250-2004 Table 24C
TABLE_2004_24C
1010
ASTM1250-2004 Table 24D
TABLE_2004_24D
1011
ASTM1250-2007 Table 24E
TABLE_2007_24E
1061
ASTM1250-2004 Table 24X
TABLE_2004_24X
1012
ASTM1250-2004 Table 53A
TABLE_2004_53A
1030
ASTM1250-2004 Table 53B
TABLE_2004_53B
1031
ASTM1250-2004 Table 53D
TABLE_2004_53D
1032
ASTM1250-2007 Table 53E
TABLE_2007_53E
1062
ASTM1250-2004 Table 54A
TABLE_2004_54A
1021
37
ASTM1250-2004 Table 54B
TABLE_2004_54B
1022
ASTM1250-2004 Table 54C
TABLE_2004_54C
1023
ASTM1250-2004 Table 54D
TABLE_2004_54D
1024
ASTM1250-2007 Table 54E
TABLE_2007_54E
1063
ASTM1250-2004 Table 59A
TABLE_2004_59A
1033
ASTM1250-2004 Table 59B
TABLE_2004_59B
1034
ASTM1250-2004 Table 59D
TABLE_2004_59D
1035
ASTM1250-2007 Table 59E
TABLE_2007_59E
1064
ASTM1250-2004 Table53/59X
TABLE_2004_59X
1036
ASTM1250-2004 Table 60A
TABLE_2004_60A
1025
ASTM1250-2004 Table 60B
TABLE_2004_60B
1026
ASTM1250-2004 Table 60C
TABLE_2004_60C
1027
ASTM1250-2004 Table 60D
TABLE_2004_60D
1028
ASTM1250-2007 Table 60E
TABLE_2007_60E
1065
ASTM1250-2004 Table54/60X
TABLE_2004_60X
1029
Ethanol OIML Table 6
TABLE_ETH_OIML_6
1056
Ethanol OIML Table 7
TABLE_ETH_OIML_7
1057
ASTM D1555-09 Hydrocarbon
TABLE_ASTM_D1555
1080
DIN EN14214 FAME
TABLE_ASTM_FAME
1090
ASTM D4311-04 Asphalt
TABLE_ASTM_D4311
1100
38
BLEND_ON_LEAD_TYPE
Description
Parameter type is used to select which component will be used to determine the
target flow rates when using the blend on lead functionality.
Enum Value
37
Values
Selection
Numerical
Value
NONE
0
FIRST COMPONENT IN RECIPE
1
HIGHEST PERCENTAGE
2
LOWEST PERCENTAGE
3
BLEND_TYPE
Description
Parameter type is used to select the blending type allowed on the unit.
Enum Value
42
Values
Selection
Numerical
Value
NONE
0
RATIO
1
SEQUENTIAL
2
RATIO AND SEQUENTIAL
3
WATERCUT
4
RATIO NON PROPORTIONAL
5
RATIO EXCLUDING LOW FLOW
6
CARD_READER_TYPE
Description
Parameter type is used to select the type of card reader that is installed.
39
Enum Value
26
Values
Card Reader Type
Numerical
Value
DISABLED
0
BUCKET
1
BUCKET NON-CAPTIVE
2
SLOT
3
SLOT NON-CAPTIVE
4
IBUTTON
5
BUCKET DUAL NON-CAPTIVE
6
SLOTE DUAL NON-CAPTIVE
7
COMMODITY_TYPE
Description
Parameter type is used to select the type of product being loaded.
Enum Value
28
Values
Commodity Type
Enumeration Name
Numerical
Value
NONE
COMMODITY_TYPE_NONE
0
CRUDE
COMMODITY_TYPE_CRUDE
1
REFINED
COMMODITY_TYPE_REFINE
2
LUBRICATING OILS
COMMODITY_TYPE_LUBRIC
3
DEADMAN_MODE
Description
Parameter type is used to select the DEADMAN operating mode.
Enum Value
35
Values
Operating Mode
Numerical
Value
40
NONE
0
CONTINUOUS HOLD
1
HOLD & RELEASE
2
PUSH
3
DECIMAL_MARK_TYPE
Description
Parameter type is used to select whether to display a comma or a dot when
displaying a decimal separator.
Enum Value
46
Values
Selection
Numerical
Value
DECIMAL (DOT)
0
COMMA
1
DELIVER_TYPE
Description
Parameter type is used to select the delivery type, which is what the driver will
enter in for the preset amount and what the MultiLoad will target for the delivery
amount.
Enum Value
40
Values
Selection
Numerical
Value
GOV
0
GSV
1
MASS
2
IV
3
41
DENSITY_UOM_TYPE
Description
Parameter type is used to select a unit of measure for density.
Enum Value
30
Values
Unit of Measure
Enumeration Name
Numerical
Value
kg/m
3
DENSITY_UOM_TYPE_KG
0
API GRAVITY
DENSITY_UOM_TYPE_API
1
RELATIVE DENSITY
DENSITY_UOM_TYPE_REL
2
DISABLE_ENABLE
Description
Parameter can either be disabled or enabled.
Enum Value
11
Values
Selection
Numerical
Value
DISABLED
0
ENABLED
1
DISPLAY_LOAD_TYPE
Description
Parameter type is used to select what will be displayed when using the Display Load
Volume functionality.
Enum Value
60
Values
Selection
Numerical
Value
DISABLED
0
GOV
1
42
GSV
2
MASS
3
EXP_COEF_UOM_TYPE
Description
Parameter type is used to select a unit of measure for the expansion coefficient.
Enum Value
29
Values
Unit of Measure
Enumeration Name
Numerical
Value
FAHRENHEIT (1/F)
EXP_COEF_UOM_TYPE_FAHRENHEIT
0
CELSIUS (1/C)
EXP_COEF_UOM_TYPE_CELSIUS
1
FCM_ADDRESS_ANALOG_INPUT
Description
Parameter is used for addressing FCM analog input ports. The value is represented
as a Lua table, or a JSON object.
Enum Value
66
Values
Property
Data Type
Description
fcm_number
Number
FCM address
port_number
Number
Port number
custom_logic
Boolean
Indicates whether the input is looking at a
custom logic line rather than a physical
input.
enabled
Boolean
Indicates whether this parameter is enabled
or not.
analog_input_type
Number
A value of zero indicates mA, and a value of
one indicates Voltage.
custom_logic_index
Number
If the custom_logic flag is true, this
parameter indicates which custom logic line
will be referenced. If the custom_logic flag is
false, this property will not exist.
43
FCM_ADDRESS_INPUT
Description
Parameter is used for addressing FCM input ports. The value is represented as a Lua
table, or a JSON object.
Enum Value
12
Values
Property
Data Type
Description
fcm_number
Number
FCM address
port_number
Number
Port number
custom_logic
Boolean
Indicates whether the input is looking at a
custom logic line rather than a physical
input.
enabled
Boolean
Indicates whether this parameter is enabled
or not.
invert
Boolean
Indicates if the input logic will be inverted.
custom_logic_index
Number
If the custom_logic flag is true, this
parameter indicates which custom logic line
will be referenced. If the custom_logic flag is
false, this property will not exist.
FCM_ADDRESS_OUTPUT
Description
Parameter is used for addressing FCM output ports. The value is represented as a
Lua table, or a JSON object.
Enum Value
41
Values
Property
Data Type
Description
fcm_number
Number
FCM address
port_number
Number
Port number
custom_logic
Boolean
Indicates whether the output will be sent to
a custom logic line rather than a physical
output.
enabled
Boolean
Indicates whether this parameter is enabled
or not.
44
invert
Boolean
Indicates if the output logic will be inverted.
custom_logic_index
Number
If the custom_logic flag is true, this
parameter indicates which custom logic line
will be referenced. If the custom_logic flag is
false, this property will not exist.
FCM_TYPE
Description
Parameter type is used to select the FCM type.
Enum Value
43
Values
FCM
Numerical
Value
NOT SPECIFIED
0
FCM 1
1
4ACOUT DCIN
2
6ACIN 110V
3
6ACOUT 220V
4
6DCIN
5
6DCOUT
6
AC IO BOARD
7
4ACOUT 4DCIN ANALOG
8
AC IO BOARD ANALOG
9
DC IO BOARD ANALOG
10
2 METER IO BOARD ANALOG
11
SCS IO BOARD
12
FLOW_RATE_MODE
Description
Parameter type is used to select whether the flow rate is to be calculated per
minute or per hour.
Enum Value
47
Values
Flow Rate
Numerical
Value
45
MINUTES
0
HOURS
1
LANGUAGE
Description
Parameter type is used to select a language.
Enum Value
21
Values
Language
Numerical
Value
ENGLISH
0
SPANISH
1
PORTUGUESE
2
FRENCH
3
GERMAN
4
SIMPLIFIED CHINESE
5
TRADITIONAL CHINESE
6
THAI
7
MASS_MEASURES
Description
Parameter type is used to select the unit of measure when delivering in mass.
Enum Value
39
Values
Mass Unit of Measure
Numerical
Value
NONE
0
POUNDS
1
SHORT TONS
2
LONG TONS (IMPERIAL TONS)
3
KILOGRAMS
4
KILOGRAMS AIR
5
46
METRIC TONS
6
MEASURES
Description
Parameter type is used to select a unit of measure.
Enum Value
20
Values
Unit of Measure
Numerical
Value
GALLONS
0
LITRES
1
CUBIC_METERS
2
TONNES
3
KILOGRAMS
4
GRAMS
5
POUNDS
6
BARRELS
7
NO_MEASURE
8
LITERS
9
DECALITERS
10
METER_OUTPUT_PULSE_TYPE
Description
Parameter type is used to select which volume calculation will be used when
sending output pulses associated with the Meter Level -> Output Pulse FCM#
parmater.
Enum Value
74
Values
Selection
Numerical
Value
IV
0
GOV
1
47
METER_TYPE
Description
Parameter type is used to select how the alarm promotion counter is reset.
Enum Value
23
Values
Meter Input Type
Numerical
Value
VOLUME PULSE
0
MASS PULSE
1
VOLUME ANALOG
2
VOLUME KHRONE
3
VOLUME MICROMOTION
4
NA
Description
Parameter is not used or is not available in this version of firmware.
Enum Value
0
Values
None
NETWORK_MODE_TYPE
Description
Parameter type is used to select the type of network configuration.
Enum Value
57
Values
Network Mode Type
Numerical
Value
DISABLED
0
STATIC
1
DHCP
2
48
PERCENT
Description
Parameter is an unsigned integer but has an implied decimal. The last 2 digits of the
number are displayed to the right of the decimal. It is the equivalent of dividing the
number by 100.
Enum Value
10
Values
0 to 4,294,967,295 (equivalent: 0.00 to 42,949,672.95)
PERCENT_DIV10000
Description
Parameter is an unsigned integer but has an implied decimal. The last 4 digits of the
number are displayed to the right of the decimal. It is the equivalent of dividing the
number by 10000.
Enum Value
15
Values
0 to 4,294,967,295 (equivalent: 0.0000 to 429,496.7295)
PRESSURE_UOM_TYPE
Description
Parameter type is used to select a unit of measure for pressure.
Enum Value
31
Values
Unit of Measure
Enumeration Name
Numerical
Value
PSIG
PRESSURE_UOM_TYPE_PSIG
0
kPA
PRESSURE_UOM_TYPE_KPA
1
BAR
PRESSURE_UOM_TYPE_BAR
2
49
PROCESS_MODE_TYPE
Description
Parameter type is used to select the processing mode of the unit.
Enum Value
27
Values
Processing Mode Type
Numerical
Value
STANDALONE
0
REMOTE
1
UAP
2
UAP GATE
3
SLATE
4
SAMPLER_UOM_TYPE
Description
Parameter type is used to select the unit of measure for sampler injections.
Enum Value
61
Values
Unit of Measure
Numerical
Value
NONE
0
CC
1
OZ
2
SCS_DEFAULT_REPORT_TYPE
Description
Parameter type is used to select which report type will be the default when using
the ‘4446’ reports shortcut workflow.
Enum Value
75
50
Values
Selection
Numerical
Value
TRANSACTION
0
SAMPLE POT
1
LINE
2
SCS_PROMPTS_DISPLAY_TYPE
Description
Parameter type is used to select when the SCS prompts will be displayed during the
loading process.
Enum Value
64
Values
Unit of Measure
Numerical
Value
AFTER
0
BEFORE
1
SCS_PROMPT_MODE_TYPE
Description
Parameter is used for selecting which SCS prompts will be displayed during the
loading process. It is a bit field struct represented as an unsigned integer.
Enum Value
58
Values
Bits
Field
0
BSW
1
Density
2
GOV
51
3
Temperature
SECURITY_COMPLEXITY_MODE
Description
Parameter is used for selecting how complex a password must be. It is a bit field
struct represented as an unsigned integer.
Enum Value
59
Values
Bits
Field
0
Alphabetical character required
1
Numeric number required
2
Special character required
SECURITY_LEVEL_MODE
Description
Parameter type is an unsigned integer and it is used to set the security level for a
parameter or a group.
Enum Value
62
Values
0 10
SIGNED_DIV10
Description
Parameter is a signed integer but has an implied decimal. The last digit of the
number is displayed to the right of the decimal. It is the equivalent of dividing the
number by 10.
Enum Value
9
52
Values
-2,147,483,648 to 2,147,483,647 (equivalent: -214,748,364.8 to 214,748,364.7)
SIGNED_DIV100
Description
Parameter is a signed integer but has an implied decimal. The last 2 digits of the
number are displayed to the right of the decimal. It is the equivalent of dividing the
number by 100.
Enum Value
8
Values
-2,147,483,648 to 2,147,483,647 (equivalent: -21,474,836.48 to 21,474,836.47)
SIGNED_DIV1000
Description
Parameter is a signed integer but has an implied decimal. The last 3 digits of the
number are displayed to the right of the decimal. It is the equivalent of dividing the
number by 1000.
Enum Value
24
Values
-2,147,483,648 to 2,147,483,647 (equivalent: -2,147,483.648 to 2,147,483.647)
SIGNED_DIV10000
Description
Parameter is a signed integer but has an implied decimal. The last 4 digits of the
number are displayed to the right of the decimal. It is the equivalent of dividing the
number by 10000.
Enum Value
34
Values
-2,147,483,648 to 2,147,483,647 (equivalent: -214,748.3648 to 214,748.3647)
53
SIGNED_INT
Description
Parameter is formatted as a signed integer.
Enum Value
4
Values
-2,147,483,648 to 2,147,483,647
TANK_MODE
Description
Parameter type is used to select the operating mode of a specific tank.
Enum Value
56
Values
Selection
Numerical
Value
DEACTIVE
0
LOADING
1
UNLOADING
2
UNLOAD & LOADING
3
TEMPERATURE_UOM_TYPE
Description
Parameter type is used to select the Fahrenheit or Celsius.
Enum Value
44
Values
Temperature Unit of
Measure
Enumeration Name
Numerical
Value
CELSIUS
TEMPERATURE_UOM_TYPE_CELSIUS
0
FAHRENHEIT
TEMPERATURE_UOM_TYPE_FAHRENHEIT
1
54
TIME_HH_MM
Description
Parameter type is used to configure time.
Enum Value
63
Values
0 to 2359 (equivalent of 00:00 23:59)
TOTALIZER_SELECTION
Description
Parameter is used for which totalizers to store in a transaction. It is a bit field struct
represented as an unsigned integer.
Enum Value
25
Values
Bits
Field
0
Preset
1
Meter
2
Component
3
Additive
4
Sampler
UNSIGNED_INT
Description
Parameter is an unsigned integer.
Enum Value
3
55
Values
0 to 4,294,967,295
UNSIGNED_DIV10
Description
Parameter is an unsigned integer but has an implied decimal. The last digit of the
number is displayed to the right of the decimal. It is the equivalent of dividing the
number by 10.
Enum Value
16
Values
0 to 4,294,967,295 (equivalent: 0.00 to 429,496,729.5)
UNSIGNED_DIV100
Description
Parameter is an unsigned integer but has an implied decimal. The last 2 digits of the
number are displayed to the right of the decimal. It is the equivalent of dividing the
number by 100.
Enum Value
7
Values
0 to 4,294,967,295 (equivalent: 0.00 to 42,949,672.95)
UNSIGNED_DIV1000
Description
Parameter is an unsigned integer but has an implied decimal. The last 3 digits of the
number are displayed to the right of the decimal. It is the equivalent of dividing the
number by 1,000.
Enum Value
6
Values
0 to 4,294,967,295 (equivalent: 0.000 to 4,294,967.295)
56
UNSIGNED_DIV10000
Description
Parameter is an unsigned integer but has an implied decimal. The last 4 digits of the
number are displayed to the right of the decimal. It is the equivalent of dividing the
number by 10,000.
Enum Value
5
Values
0 to 4,294,967,295 (equivalent: 0.0000 to 429,496.7295)
ZP2_UNSIGNED_INT
Description
Parameter is an unsigned integer and is zero padded with two zeros. The equivalent
of formatting a string with “%02u”.
Enum Value
71
Values
0 to 4,294,967,295
ZP3_UNSIGNED_INT
Description
Parameter is an unsigned integer and is zero padded with three zeros. The
equivalent of formatting a string with “%03u”.
Enum Value
13
Values
0 to 4,294,967,295
ZP4_UNSIGNED_INT
Description
Parameter is an unsigned integer and is zero padded with four zeros. The equivalent
of formatting a string with “%04u”.
Enum Value
49
Values
0 to 4,294,967,295
57
ZP_UNSIGNED_INT
Description
Parameter is an unsigned integer and is zero padded with seven zeros. The
equivalent of formatting a string with “%07u”.
Enum Value
1
Values
0 to 4,294,967,295
ZP_SIGNED_INT
Description
Parameter is a signed integer and is zero padded with seven zeros. The equivalent
of formatting a string with “%+07d”.
Enum Value
2
Values
-2,147,483,648 to 2,147,483,647
2.6.2 MultiLoad Information Parameters
Permissions: Read
Firmware Location:
No location available.
Script Reference:
ml.info.<variable_name>
Card Data
Variable Name
Data Type
Description
58
Card Facility Number
Variable Name
Data Type
Description
Card Inserted
Variable Name
Data Type
Description
Card Number
Variable Name
Data Type
Description
Current Component
Variable Name
Data Type
Description
Current Preset
Variable Name
59
Data Type
Description
Current Screen
Variable Name
Data Type
Description
Screen Name
NO_SCREEN
PRELOAD_SCREEN
LOAD_SCREEN
PRETERMINATE_SCREEN
INTERVENTION_SCREEN
PRESET_SCREEN
COMPARTMENT_PRESET_SCREEN
CONTROL_SCREEN
STATUS_SCREEN
COMPONENT_STATUS_SCREEN
ADDITIVE_STATUS_SCREEN
60
SAMPLER_STATUS_SCREEN
SINGLE_COMPONENT_STATUS_SCREEN
METER_PROVING_PRECONFIGURATION_SCREEN
METER_PROVING_RESULTS_1_SCREEN
METER_PROVING_RESULTS_2_SCREEN
METER_PROVING_RESULTS_3_SCREEN
METER_PROVING_RESULTS_4_SCREEN
END_SAMPLER_BATCH_SCREEN
END_SAMPLER_BATCH_PROMPT_SCREEN
END_SAMPLER_BATCH_DETAIL_SCREEN
ALARM_CLEAR_AUTH_SCREEN
End of Day Transaction Report Details
Variable Name
Data Type
Description
61
End of Day Line Report Details
Variable Name
Data Type
Description
End of Month Transaction Report Details
Variable Name
Data Type
Description
62
End of Month Line Report Details
Variable Name
Data Type
Description
Previous Screen
Variable Name
Data Type
Description
Screen Name
NO_SCREEN
63
PRELOAD_SCREEN
LOAD_SCREEN
PRETERMINATE_SCREEN
INTERVENTION_SCREEN
PRESET_SCREEN
COMPARTMENT_PRESET_SCREEN
CONTROL_SCREEN
STATUS_SCREEN
COMPONENT_STATUS_SCREEN
ADDITIVE_STATUS_SCREEN
SAMPLER_STATUS_SCREEN
SINGLE_COMPONENT_STATUS_SCREEN
METER_PROVING_PRECONFIGURATION_SCREEN
METER_PROVING_RESULTS_1_SCREEN
METER_PROVING_RESULTS_2_SCREEN
METER_PROVING_RESULTS_3_SCREEN
METER_PROVING_RESULTS_4_SCREEN
END_SAMPLER_BATCH_SCREEN
END_SAMPLER_BATCH_PROMPT_SCREEN
64
END_SAMPLER_BATCH_DETAIL_SCREEN
ALARM_CLEAR_AUTH_SCREEN
Program Mode Key Inserted
Variable Name
Data Type
Description
RCU Status
Variable Name
Data Type
Description
RCU Status
IDLE
AUTH_BAY
MENU_MODE
DIAG_MODE
AUTHORIZING_LOAD
COMPLETING_LOAD
TRANSACTION_DONE
TRANSACTION_CANCEL
65
PULLING_TRANSACTION
ARCHIVING_TRANSACTION
TRANSACTION_AUTHORIZED
RCU_NOT_CONFIGURED
RCU_POWER_UP
INITIALIZING
NO_TRANSACTION
REMOTE_AUTH_PRESET114 (this can be any preset number from 1 to 14)
User Security Bypass
Variable Name
Data Type
Description
Weights & Measures Key Inserted
Variable Name
Data Type
Description
2.6.3 RCU Level Parameters
Permissions: Read and Write
66
Firmware Location:
Main Menu -> Configuration -> RCU Setup
Script Reference:
ml.equipment.rcu.<variable_name>
Reload ROM Lang File
Variable Name
reload_rom_lang_file
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
Driver Language
Variable Name
driver_language
Format Type
LANGUAGE
Default
ENGLISH
Minimum
ENGLISH
Maximum
THAI
ProgramMode Language
Variable Name
program_mode_language
67
Format Type
LANGUAGE
Default
ENGLISH
Minimum
ENGLISH
Maximum
THAI
Card Reader Type
Variable Name
card_reader_type
Format Type
CARD_READER_TYPE
Default
DISABLED
Minimum
DISABLED
Maximum
SLOTE DUAL NON-CAPTIVE
Prox Card Pull Secs
Variable Name
prox_card_pull_secs
Format Type
UNSIGNED_INT
Default
3
Minimum
2
Maximum
30
68
Processing Mode
Variable Name
processing_mode
Format Type
PROCESS_MODE_TYPE
Default
REMOTE
Minimum
STANDALONE
Maximum
SLATE
Message Swap Delay
Variable Name
message_swap_delay
Format Type
UNSIGNED_INT
Default
3
Minimum
1
Maximum
60
Message Hold Delay
Variable Name
message_hold_delay
Format Type
UNSIGNED_INT
Default
10
Minimum
1
Maximum
60
69
Auto Authorize
Variable Name
auto_authorize_enabled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
MM/DD/YYYY Date
Variable Name
mmddyy_date_enabled
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
Mass Measure Used
Variable Name
mass_measure_used
Format Type
MASS_MEASURES
Default
NONE
Minimum
NONE
70
Maximum
METRIC TONS
Load Date From End
Variable Name
load_date_from_end_enabled
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
Measure Used
Variable Name
measure_used
Format Type
MEASURES
Default
GALLONS
Minimum
GALLONS
Maximum
DECALITERS
Print Blend Details
Variable Name
print_blend_details
Format Type
UNSIGNED_INT
Default
1
71
Minimum
0
Maximum
2
Compartment Entry
Variable Name
compartment_entry
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Config Timeout Mins
Variable Name
config_timeout_mins
Format Type
UNSIGNED_INT
Default
20
Minimum
0
Maximum
99
Print Totalizers
Variable Name
totalizer_selection
Format Type
TOTALIZER_SELECTION
72
Default
NONE
Minimum
NONE
Maximum
PMCAS (Preset, Meter, Component, Additive, and Sampler)
Simulation Mode
Variable Name
simulation_mode
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Large Prompts
Variable Name
large_prompts
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Confirm Flow Starts
Variable Name
confirm_flow_starts
73
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Display Adtv as CCs
Variable Name
disp_adtv_as_cc
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Display Hundredths
Variable Name
disp_hunds
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
74
Use Hundredths
Variable Name
use_hunds
Format Type
DISABLE_ENABLE
Default
DISABLE
Minimum
DISABLED
Maximum
ENABLED
W&M Density Lock
Variable Name
density_wm_controlled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Print Ticket
Variable Name
print_ticket_enabled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
75
Form Feed After Tckt
Variable Name
formfeed_after_ticket_enabled
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
Capture Grind Out Data
Variable Name
capture_grindout_data_enabled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Meter Arch Timeout
Variable Name
transaction_timeout_secs
Format Type
UNSIGNED_INT
Default
120
Minimum
0
76
Maximum
120
Inactivity Timeout
Variable Name
inactivity_timeout_mins
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
60
No Prox Pull If Flow
Variable Name
no_prox_pull_if_flow
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Host Down Timeout
Variable Name
host_down_timeout_secs
Format Type
UNSIGNED_INT
Default
120
77
Minimum
999
Maximum
30
Host Wait Timeout
Variable Name
host_wait_timeout_secs
Format Type
UNSIGNED_INT
Default
999
Minimum
60
Maximum
999
Prt Alibi Log on PCM
Variable Name
print_alibi_log_on_pcm_enabled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Alibi Log PCM#
Variable Name
alibi_log_pcm
Format Type
UNSIGNED_INT
78
Default
0
Minimum
0
Maximum
3
Swing Arm Secondary
Variable Name
swing_arm_secondary
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Screen Saver Timeout
Variable Name
screensaver_seconds
Format Type
UNSIGNED_INT
Default
600
Minimum
0
Maximum
65535
Screen Saver Bright
Variable Name
screensaver_brightness_pct
79
Format Type
PERCENT
Default
5000
Minimum
0
Maximum
10000
Min Time Change Secs
Variable Name
min_time_change_seconds
Format Type
UNSIGNED_INT
Default
60
Minimum
0
Maximum
65535
Display Load Volume
Variable Name
display_load_del_type
Format Type
DISPLAY_LOAD_TYPE
Default
DISABLED
Minimum
DISABLED
Maximum
MASS
80
Display Help
Variable Name
display_help
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
Measure on Load Scrn
Variable Name
measure_on_load_screen
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Status Scrn Lockout
Variable Name
status_screen_lockout
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
81
Load Screen Timeout
Variable Name
load_screen_timeout
Format Type
UNSIGNED_INT
Default
60
Minimum
65535
Maximum
0
Preset Slct Timeout
Variable Name
preset_select_timeout
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Pixel Test
Variable Name
pixel_test_enabled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
82
Maximum
ENABLED
Meter Proving Mode
Variable Name
meter_proving_mode
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Decimal Mark Type
Variable Name
decimal_mark
Format Type
DECIMAL_MARK_TYPE
Default
DECIMAL
Minimum
DECIMAL (DOT)
Maximum
COMMA
Display Preset Totalizer
Variable Name
display_preset_totalizer_enable
Format Type
DISABLE_ENABLE
Default
DISABLED
83
Minimum
DISABLED
Maximum
ENABLED
Default Driver Number
Variable Name
default_driver_number
Format Type
UNSIGNED_INT
Default
1
Minimum
1
Maximum
9999999
Default Facility Code
Variable Name
default_facility_number
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
9999999
Sample UOM
Variable Name
sampler_uom
Format Type
SAMPLER_UOM_TYPE
84
Default
NONE
Minimum
NONE
Maximum
OZ
SCS Prompting Display
Variable Name
scs_prompt_display
Format Type
Error! Reference source not found.
Default
AFTER
Minimum
Error! Reference source not found.
Maximum
Error! Reference source not found.
Max Lines on a Ticket
Variable Name
ticket_max_lines
Format Type
UNSIGNED_INT
Default
66
Minimum
0
Maximum
106
Startup Keypad Locked
Variable Name
startup_keypad_locked
85
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Screen Brightness
Variable Name
screen_brightness_pct
Format Type
PERCENT
Default
10000
Minimum
500
Maximum
10000
W&M Key FCM#
Variable Name
wm_key_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
86
Program Key FCM#
Variable Name
program_key_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
RCU Address
Variable Name
rcu_address
Format Type
ZP3_UNSIGNED_INT
Default
1
Minimum
0
Maximum
999
2.6.4 SCS Level Parameters
Permissions: Read and Write
Firmware Location:
Main Menu -> Configuration -> SCS Setup
Script Reference:
ml.equipment.scs.<variable_name>
87
SCS Default Report Type
Variable Name
scs_default_report_type
Format Type
SCS_DEFAULT_REPORT_TYPE
Default
LINE
Minimum
TRANSACTION
Maximum
LINE
Default Report Day Trigger
Variable Name
default_report_day_trigger
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
28
Default Report Time Trigger
Variable Name
default_report_time_trigger
Format Type
TIME_HH_MM
Default
0
Minimum
0
Maximum
2359
88
SCS Prompting
Variable Name
scs_prompt_mode
Format Type
SCS_PROMPT_MODE_TYPE
Default
NONE
Minimum
NONE
Maximum
BDGT (BSW, Density, GOV, and Temperature)
2.6.5 Bay Level Parameters
Permissions: Read and Write
Firmware Location:
Main Menu -> Configuration -> Equipment Setup -> Bay
Script Reference:
ml.equipment.bay.<variable_name>
Number Bay Presets
Variable Name
number_of_presets
Format Type
UNSIGNED_INT
Default
1
Minimum
0
Maximum
12
89
Number of FCMs
Variable Name
number_of_fcms
Format Type
UNSIGNED_INT
Default
1
Minimum
0
Maximum
32
Number of PCMs
Variable Name
number_of_pcms
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
3
Temperature UOM
Variable Name
temperature_uom
Format Type
TEMPERATURE_UOM_TYPE
Default
FAHRENHEIT
Minimum
CELSIUS
Maximum
FAHRENHEIT
90
Canada API Limits
Variable Name
canada_api_limits
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Number of Tanks
Variable Name
number_of_tanks
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
10
Bay Number (Skid Number)
Variable Name
bay_number
Format Type
UNSIGNED_INT
Default
0
Minimum
0
91
Maximum
9999
Number External Presets
Variable Name
number_of_external_presets
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
12
Output Pulse Type
Variable Name
output_pulse_type
Format Type
DELIVER_TYPE
Default
GOV
Minimum
GOV
Maximum
IV
Start Transaction FCM#
Variable Name
start_transaction_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
92
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
End Transaction FCM#
Variable Name
stop_transaction_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Output Pulse FCM#
Variable Name
output_pulse_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Output Pulse Factor
Variable Name
output_pulses_per_vol_thous
Format Type
UNSIGNED_DIV1000
93
Default
10000
Minimum
1
Maximum
50000
Deadman Mode
Variable Name
deadman_mode
Format Type
DEADMAN_MODE
Default
NONE
Minimum
NONE
Maximum
PUSH
Input Deadman FCM#
Variable Name
input_deadman_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Deadman Stop Timer
Variable Name
deadman_stop_timer
94
Format Type
UNSIGNED_INT
Default
180
Minimum
0
Maximum
65535
Output Deadman FCM#
Variable Name
deadman_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Deadman Warning Timer
Variable Name
deadman_warning_timer
Format Type
UNSIGNED_INT
Default
30
Minimum
0
Maximum
65535
95
Deadman Bypass Key FCM#
Variable Name
deadman_bypass_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Alarm Out FCM#
Variable Name
alarm_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Authorized FCM#
Variable Name
authorized_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
96
Permiss 0 FCM#
Variable Name
permissive0_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss 1 FCM#
Variable Name
permissive1_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss 2 FCM#
Variable Name
permissive2_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
97
Maximum
Please refer to the format type description
Permiss 3 FCM#
Variable Name
permissive3_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss 4 FCM#
Variable Name
permissive4_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss 5 FCM#
Variable Name
permissive5_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
98
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss 6 FCM#
Variable Name
permissive6_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss 7 FCM#
Variable Name
permissive7_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss Out FCM#
Variable Name
permissive_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
99
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
2.6.6 Preset Level Parameters
Permissions: Read and Write
Firmware Location:
Main Menu -> Configuration -> Equipment Setup -> Preset
Script Reference:
ml.equipment.preset[preset_num].<variable_name>
Number of Meters
Variable Name
number_of_meters
Format Type
UNSIGNED_INT
Default
1
Minimum
1
Maximum
5
Number of Components
Variable Name
number_of_components
Format Type
UNSIGNED_INT
100
Default
1
Minimum
1
Maximum
8
Number of Additives
Variable Name
number_of_additives
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
16
Preset Enable
Variable Name
preset_enable
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
Blending Type
Variable Name
blending_type
101
Format Type
BLEND_TYPE
Default
NONE
Minimum
NONE
Maximum
RATIO EXCLUDING LOW FLOW
W&M Controlled
Variable Name
wm_controlled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Proving Flow Rate
Variable Name
proving_flow_rate
Format Type
UNSIGNED_INT
Default
600
Minimum
0
Maximum
25000
102
Excess Flw Alrm Rate
Variable Name
excess_flow_alarm_rate
Format Type
UNSIGNED_INT
Default
1100
Minimum
0
Maximum
25000
Overrun Alarm Vol
Variable Name
overrun_alarm_vol
Format Type
UNSIGNED_INT
Default
5
Minimum
0
Maximum
65535
Low Flow Start Vol
Variable Name
low_flow_start_vol
Format Type
UNSIGNED_INT
Default
50
Minimum
0
Maximum
65535
103
Low Flow Restart Vol
Variable Name
low_flow_restart_vol
Format Type
UNSIGNED_INT
Default
15
Minimum
0
Maximum
65535
Low Flow Rate
Variable Name
low_flow_rate
Format Type
UNSIGNED_INT
Default
150
Minimum
0
Maximum
25000
High Flow Rate
Variable Name
high_flow_rate
Format Type
UNSIGNED_INT
Default
600
Minimum
0
104
Maximum
25000
Proving Low Flow Vol
Variable Name
proving_low_flow_vol
Format Type
UNSIGNED_INT
Default
50
Minimum
0
Maximum
65535
Line Flush Vol
Variable Name
line_flush_vol
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Line Flush Min Vol
Variable Name
line_flush_min_vol
Format Type
UNSIGNED_INT
Default
0
105
Minimum
0
Maximum
65535
Line Flush Comp#
Variable Name
line_flush_comp_no
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
8
Take L.F. from Match
Variable Name
line_flush_from_match
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
Take L.F. from First
Variable Name
line_flush_from_first
Format Type
DISABLE_ENABLE
106
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Take L.F. from Last
Variable Name
line_flush_from_last
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Compute Blend Density
Variable Name
compute_blend_density
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Alt. High Flow Rate
Variable Name
alt_high_flow_rate
107
Format Type
UNSIGNED_INT
Default
600
Minimum
0
Maximum
25000
Stop Start Delay
Variable Name
stop_start_delay_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Blnd Chk Start Vol
Variable Name
blend_chk_start_vol
Format Type
UNSIGNED_INT
Default
60
Minimum
0
Maximum
65535
108
Blnd Chk Restart Vol
Variable Name
blend_chk_restart_vol
Format Type
UNSIGNED_INT
Default
10
Minimum
0
Maximum
65535
Blnd Chk Alarm %
Variable Name
blend_chk_alarm_pct
Format Type
PERCENT
Default
500
Minimum
10
Maximum
10000
Blnd Chk Alarm Vol
Variable Name
blend_chk_alarm_vol
Format Type
UNSIGNED_INT
Default
25
Minimum
0
Maximum
65535
109
Blnd Chk Alarm Time
Variable Name
blend_chk_alarm_time
Format Type
UNSIGNED_INT
Default
10
Minimum
0
Maximum
65535
Low Flow Start Percentage
Variable Name
low_flow_start_vol_by_percentage
Format Type
PERCENT
Default
0
Minimum
0
Maximum
10000
Blnd On Lead Comp
Variable Name
blend_on_lead_component
Format Type
BLEND_ON_LEAD_TYPE
Default
NONE
Minimum
NONE
110
Maximum
LOWEST PERCENTAGE
Blnd Adj Start Vol
Variable Name
blend_adj_start_vol
Format Type
UNSIGNED_INT
Default
60
Minimum
0
Maximum
65535
Blnd Adj Restart Vol
Variable Name
blend_adj_restart_vol
Format Type
UNSIGNED_INT
Default
10
Minimum
0
Maximum
65535
Blnd Adj Dev %
Variable Name
blend_adj_dev_pct
Format Type
PERCENT
Default
100
111
Minimum
0
Maximum
10000
Blnd Adj Dev Vol
Variable Name
blend_adj_dev_vol
Format Type
UNSIGNED_INT
Default
5
Minimum
0
Maximum
65535
Blnd Adj Time
Variable Name
blend_adj_delay_time
Format Type
UNSIGNED_INT
Default
5
Minimum
0
Maximum
65535
Proving Low Flow Rate
Variable Name
proving_low_flow_rate
Format Type
UNSIGNED_INT
112
Default
150
Minimum
0
Maximum
25000
Min Preset Value
Variable Name
min_preset
Format Type
UNSIGNED_INT
Default
100
Minimum
0
Maximum
9999999
Default Preset Value
Variable Name
default_preset
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
9999999
Max Preset Value
Variable Name
max_preset
113
Format Type
UNSIGNED_INT
Default
10000
Minimum
0
Maximum
9999999
Auto Batch Authorize
Variable Name
auto_batch_authorize
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Deliver Type
Variable Name
deliver_type
Format Type
DELIVER_TYPE
Default
GOV
Minimum
GOV
Maximum
IV
114
BlkValve Open Delay
Variable Name
blk_val_open_delay
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
B.V. Open Alrm Time
Variable Name
blk_val_open_alarm_time
Format Type
UNSIGNED_INT
Default
10
Minimum
2
Maximum
65535
B.V. Close Alrm Time
Variable Name
blk_val_close_alarm_time
Format Type
UNSIGNED_INT
Default
10
Minimum
2
Maximum
65535
115
Open Loading
Variable Name
open_loading
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Output Pulse FCM#
Variable Name
output_pulse_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Output Pulse Factor
Variable Name
output_pulses_per_vol_thous
Format Type
UNSIGNED_DIV1000
Default
10000
Minimum
1
116
Maximum
50000
Output Pulse Type
Variable Name
output_pulse_type
Format Type
DELIVER_TYPE
Default
GOV
Minimum
GOV
Maximum
IV
Alt High Flow Start Delay
Variable Name
alt_high_flow_rate_start_delay
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
999
Alt High Flow Stop Delay
Variable Name
alt_high_flow_rate_stop_delay
Format Type
UNSIGNED_INT
Default
0
117
Minimum
0
Maximum
999
Permissive Alarm Time
Variable Name
permissive_alarm_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
999
Excess Flow Alarm Time
Variable Name
excess_flow_alarm_time
Format Type
UNSIGNED_DIV10000
Default
0
Minimum
0
Maximum
65535
BSW1 Sensor FCM#
Variable Name
bsw_1_sensor_fcm_address
Format Type
FCM_ADDRESS_ANALOG_INPUT
118
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Default BSW
Variable Name
default_bsw_hunds
Format Type
UNSIGNED_DIV100
Default
0
Minimum
0
Maximum
10000
Alarm Low BSW1
Variable Name
alarm_low_bsw_1_hunds
Format Type
SIGNED_DIV100
Default
-1000
Minimum
-1000
Maximum
11000
Alarm High BSW1
Variable Name
alarm_high_bsw_1_hunds
119
Format Type
SIGNED_DIV100
Default
11000
Minimum
-1000
Maximum
11000
BSW Alarm Time
Variable Name
bsw_alarm_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
60
BSW1 @ Low Value
Variable Name
bsw_1_at_low_value_hunds
Format Type
UNSIGNED_DIV100
Default
0
Minimum
0
Maximum
10000
120
BSW1 @ High Value
Variable Name
bsw_1_at_high_value_hunds
Format Type
UNSIGNED_DIV100
Default
10000
Minimum
0
Maximum
10000
BSW1 Offset
Variable Name
bsw_1_offset_in_hunds
Format Type
SIGNED_DIV100
Default
0
Minimum
-300
Maximum
300
BSW2 Sensor FCM#
Variable Name
bsw_2_sensor_fcm_address
Format Type
FCM_ADDRESS_ANALOG_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
121
BSW Alarm Volume
Variable Name
bsw_alarm_volume
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
9999999
Alarm Low BSW2
Variable Name
alarm_low_bsw_2_hunds
Format Type
SIGNED_DIV100
Default
-1000
Minimum
-1000
Maximum
11000
Alarm High BSW2
Variable Name
alarm_high_bsw_2_hunds
Format Type
SIGNED_DIV100
Default
11000
Minimum
-1000
122
Maximum
11000
BSW2 @ Low Value
Variable Name
bsw_2_at_low_value_hunds
Format Type
UNSIGNED_DIV100
Default
0
Minimum
0
Maximum
10000
BSW2 @ High Value
Variable Name
bsw_2_at_high_value_hunds
Format Type
UNSIGNED_DIV100
Default
10000
Minimum
0
Maximum
10000
BSW2 Offset
Variable Name
bsw_2_offset_in_hunds
Format Type
SIGNED_DIV100
Default
0
123
Minimum
-300
Maximum
300
Oil Density
Variable Name
oil_density_tenths
Format Type
UNSIGNED_DIV10
Default
0
Minimum
0
Maximum
99999
Water Density
Variable Name
water_density_tenths
Format Type
UNSIGNED_DIV10
Default
0
Minimum
0
Maximum
99999
Flow Rate Mode
Variable Name
flow_rate_mode
Format Type
FLOW_RATE_MODE
124
Default
MINUTES
Minimum
MINUTES
Maximum
HOURS
Number of Samplers
Variable Name
number_of_samplers
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
20
Diverter Valve FCM#
Variable Name
diverter_val_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Divert BSW Value
Variable Name
divert_bsw_value
125
Format Type
SIGNED_DIV100
Default
11000
Minimum
-1000
Maximum
10000
Divert Start Time
Variable Name
divert_time_start
Format Type
UNSIGNED_INT
Default
30
Minimum
0
Maximum
60
Divert Restart Time
Variable Name
divert_time_restart
Format Type
UNSIGNED_INT
Default
15
Minimum
0
Maximum
60
126
BSW Divert Alarm Time
Variable Name
bsw_divert_alarm_time
Format Type
UNSIGNED_INT
Default
10
Minimum
0
Maximum
60
BSW Stabilization Time
Variable Name
bsw_stablilization_time
Format Type
UNSIGNED_INT
Default
5
Minimum
0
Maximum
60
Remote Clear FCM#
Variable Name
remote_clear_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
127
Alt. H.F. Rate FCM#
Variable Name
alt_high_flow_rate_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Close Blk Val FCM#
Variable Name
close_blk_val_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Blk Val Status FCM#
Variable Name
blk_val_status_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
128
Maximum
Please refer to the format type description
Open Blk Val FCM#
Variable Name
open_blk_val_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Flow Active FCM#
Variable Name
flow_active_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Batch Authorized FCM#
Variable Name
batch_authorized_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
129
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Remote Start FCM#
Variable Name
remote_start_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Swing Arm FCM#
Variable Name
swing_arm_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Meter Stop FCM#
Variable Name
meter_stop_fcm_address
Format Type
FCM_ADDRESS_INPUT
130
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Alarm Out FCM#
Variable Name
alarm_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Authorized FCM#
Variable Name
authorized_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss FCM#
Variable Name
permissive_fcm_address
131
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss Out FCM#
Variable Name
permissive_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Recipe Select Bit 0 FCM#
Variable Name
recipe_select_bit0_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
132
Recipe Select Bit 1 FCM#
Variable Name
recipe_select_bit1_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Recipe Select Bit 2 FCM#
Variable Name
recipe_select_bit2_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Recipe Select Bit 3 FCM#
Variable Name
recipe_select_bit3_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
133
Recipe Select Bit 4 FCM#
Variable Name
recipe_select_bit4_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Recipe Output Bit 0 FCM#
Variable Name
recipe_out_bit0_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Recipe Output Bit 1 FCM#
Variable Name
recipe_out_bit1_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
134
Maximum
Please refer to the format type description
Recipe Output Bit 2 FCM#
Variable Name
recipe_out_bit2_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Recipe Output Bit 3 FCM#
Variable Name
recipe_out_bit3_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Recipe Output Bit 4 FCM#
Variable Name
recipe_out_bit4_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
135
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
2.6.7 Meter Level Parameters
Permissions: Read and Write
Firmware Location:
Main Menu -> Configuration -> Equipment Setup -> Meter
Script Reference:
ml.equipment.preset[preset_num].meter[meter_num].<variable_name>
Flow Control Module#
Variable Name
fcm_number
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
31
Side-Stream on Mtr#
Variable Name
side_stream_on_meter_no
Format Type
UNSIGNED_INT
Default
0
136
Minimum
0
Maximum
5
Side-Strm on Any Mtr
Variable Name
side_stream_on_any_meter
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Meter Address
Variable Name
meter_address
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
255
Meter Type
Variable Name
meter_type
Format Type
METER_TYPE
137
Default
VOLUME PULSE
Minimum
VOLUME PULSE
Maximum
VOLUME MICROMOTION
Max Quad Errors
Variable Name
max_quad_encoding_errors
Format Type
UNSIGNED_INT
Default
10
Minimum
0
Maximum
65535
Reset Quad Errors
Variable Name
max_quad_encoding_pulses
Format Type
UNSIGNED_INT
Default
10000
Minimum
1000
Maximum
65535
Low Flow Alarm Rate
Variable Name
low_flow_alarm_rate
138
Format Type
UNSIGNED_INT
Default
10
Minimum
0
Maximum
65535
Low Flow Alarm Time
Variable Name
low_flow_alarm_time
Format Type
UNSIGNED_DIV1000
Default
10000
Minimum
0
Maximum
999999
Excess Flw Alrm Rate
Variable Name
excess_flow_alarm_rate
Format Type
UNSIGNED_INT
Default
800
Minimum
0
Maximum
25000
139
Minimum Flow Rate
Variable Name
min_flow_rate
Format Type
UNSIGNED_INT
Default
50
Minimum
0
Maximum
25000
Maximum Flow Rate
Variable Name
max_flow_rate
Format Type
UNSIGNED_INT
Default
650
Minimum
0
Maximum
25000
Low Flow DB Rate
Variable Name
low_flow_deadband_rate
Format Type
UNSIGNED_INT
Default
40
Minimum
0
Maximum
9999
140
High Flow DB Rate
Variable Name
high_flow_deadband_rate
Format Type
UNSIGNED_INT
Default
40
Minimum
0
Maximum
9999
1st Stage DB Rate
Variable Name
first_stage_deadband_rate
Format Type
UNSIGNED_INT
Default
40
Minimum
0
Maximum
9999
2nd Stage DB Rate
Variable Name
second_stage_deadband_rate
Format Type
UNSIGNED_INT
Default
40
Minimum
0
141
Maximum
9999
Valve Cntl Alrm Time
Variable Name
valve_control_alarm_time
Format Type
UNSIGNED_DIV1000
Default
10000
Minimum
0
Maximum
65535
Valve Fault Alrm Vol
Variable Name
valve_fault_alarm_vol
Format Type
UNSIGNED_INT
Default
30
Minimum
0
Maximum
65535
Creep Reset Time
Variable Name
creep_reset_time
Format Type
UNSIGNED_INT
Default
0
142
Minimum
0
Maximum
65535
Ratio Adj P. Factor
Variable Name
ratio_adj_proportional_factor
Format Type
UNSIGNED_DIV100
Default
1000
Minimum
0
Maximum
65535
Ratio Adj D. Factor
Variable Name
ratio_adj_derivative_factor
Format Type
UNSIGNED_DIV100
Default
30
Minimum
0
Maximum
65535
Meter Creep Alrm Vol
Variable Name
meter_creep_alarm_vol
Format Type
UNSIGNED_INT
143
Default
15
Minimum
0
Maximum
65535
Flow Scan Time
Variable Name
flow_scan_time
Format Type
UNSIGNED_DIV1000
Default
100
Minimum
100
Maximum
1000
Valve Dwell Time
Variable Name
flow_scan_time
Format Type
UNSIGNED_DIV1000
Default
1000
Minimum
10
Maximum
65535
Valve Dwell StepRate
Variable Name
valve_dwell_step_rate
144
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
9999
Valve Dwell StepTime
Variable Name
valve_dwell_step_time
Format Type
UNSIGNED_DIV1000
Default
0
Minimum
0
Maximum
5000
Adaptive Valve Control
Variable Name
adaptive_valve_control_enabled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
145
Analog Valve Control
Variable Name
analog_valve_control_enable
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
4-20mA Increase Step
Variable Name
valve_ma_increase_step
Format Type
UNSIGNED_DIV1000
Default
80
Minimum
0
Maximum
4000
4-20mA Decrease Step
Variable Name
valve_ma_decrease_step
Format Type
UNSIGNED_DIV1000
Default
800
Minimum
0
Maximum
4000
146
Excess Flow Alarm Time
Variable Name
excess_flow_alarm_time
Format Type
UNSIGNED_DIV1000
Default
0
Minimum
0
Maximum
65535
Analog Valve No Flow mA
Variable Name
valve_ma_no_flow
Format Type
UNSIGNED_DIV1000
Default
0
Minimum
0
Maximum
20000
Analog Meter Flow Rate @ 4mA
Variable Name
analog_meter_flow_rate_at_4ma
Format Type
UNSIGNED_INT
Default
0
Minimum
0
147
Maximum
9999
Analog Meter Flow Rate @ 20mA
Variable Name
analog_meter_flow_rate_at_20ma
Format Type
UNSIGNED_INT
Default
600
Minimum
0
Maximum
9999
Analog Meter Flow Rate Offset
Variable Name
analog_meter_flow_rate_offset_thous
Format Type
SIGNED_DIV1000
Default
0
Minimum
-9999
Maximum
9999
Analog Meter Flow Rate Cutoff
Variable Name
analog_meter_flow_rate_cutoff
Format Type
UNSIGNED_INT
Default
0
148
Minimum
0
Maximum
9999
Density Sensor FCM#
Variable Name
density_sensor_fcm_address
Format Type
FCM_ADDRESS_ANALOG_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Default Density
Variable Name
default_density_tenths
Format Type
UNSIGNED_DIV10
Default
0
Minimum
0
Maximum
99999
Alarm Low Density
Variable Name
alarm_low_density_tenths
Format Type
UNSIGNED_DIV10
149
Default
0
Minimum
0
Maximum
99999
Alarm High Density
Variable Name
alarm_high_density_tenths
Format Type
UNSIGNED_DIV10
Default
12000
Minimum
0
Maximum
99999
Density Alarm Time
Variable Name
density_alarm_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
60
Density @ Low Value
Variable Name
density_at_low_value_tenths
150
Format Type
UNSIGNED_DIV10
Default
0
Minimum
0
Maximum
40000
Density @ High Value
Variable Name
density_at_high_value_tenths
Format Type
UNSIGNED_DIV10
Default
12000
Minimum
0
Maximum
40000
Density @ High Value
Variable Name
density_at_high_value_tenths
Format Type
UNSIGNED_DIV10
Default
12000
Minimum
0
Maximum
40000
151
Density Offset
Variable Name
density_offset_in_tenths
Format Type
SIGNED_DIV10
Default
0
Minimum
-300
Maximum
300
Pressure Sensor FCM#
Variable Name
pressure_sensor_fcm_address
Format Type
FCM_ADDRESS_ANALOG_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Default Pressure
Variable Name
default_pressure_hunds
Format Type
UNSIGNED_DIV100
Default
0
Minimum
0
152
Maximum
999999
Alarm Low Pressure
Variable Name
alarm_low_pressure_hunds
Format Type
UNSIGNED_DIV100
Default
10000
Minimum
0
Maximum
999999
Alarm High Pressure
Variable Name
alarm_high_pressure_hunds
Format Type
UNSIGNED_DIV100
Default
45000
Minimum
0
Maximum
999999
Pressure Alarm Time
Variable Name
pressure_alarm_time
Format Type
UNSIGNED_INT
Default
0
153
Minimum
0
Maximum
60
Pressure @ Low Value
Variable Name
pressure_at_low_value_hunds
Format Type
UNSIGNED_DIV100
Default
0
Minimum
0
Maximum
400000
Pressure @ High Value
Variable Name
pressure_at_high_value_hunds
Format Type
UNSIGNED_DIV100
Default
65000
Minimum
0
Maximum
400000
Pressure Offset
Variable Name
pressure_offset_in_hunds
Format Type
SIGNED_DIV100
154
Default
0
Minimum
-3000
Maximum
3000
Relative Density Sensor FCM#
Variable Name
relative_density_sensor_fcm_address
Format Type
FCM_ADDRESS_ANALOG_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Default Relative Density
Variable Name
default_relative_density_tenthous
Format Type
UNSIGNED_DIV10000
Default
0
Minimum
0
Maximum
20000
Alarm Low Relative Density
Variable Name
alarm_low_relative_density_tenthous
155
Format Type
UNSIGNED_DIV10000
Default
0
Minimum
0
Maximum
20000
Alarm High Relative Density
Variable Name
alarm_high_relative_density_tenthous
Format Type
UNSIGNED_DIV10000
Default
12000
Minimum
0
Maximum
20000
Relative Density Alarm Time
Variable Name
relative_density_alarm_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
60
156
Relative Density @ Low Value
Variable Name
relative_density_at_low_value_tenthous
Format Type
UNSIGNED_DIV10000
Default
0
Minimum
0
Maximum
40000
Relative Density @ High Value
Variable Name
relative_density_at_high_value_tenthous
Format Type
UNSIGNED_DIV10000
Default
12000
Minimum
0
Maximum
40000
Relative Density Offset
Variable Name
relative_density_offset_in_tenthous
Format Type
SIGNED_DIV10000
Default
0
Minimum
-3000
Maximum
3000
157
2% MF Limit Ref
Variable Name
meter_factor_limit_reference
Format Type
UNSIGNED_DIV10000
Default
0
Minimum
0
Maximum
65535
Adjacent MF Dev Limt
Variable Name
meter_factor_adjacent_limit
Format Type
UNSIGNED_DIV10000
Default
0
Minimum
0
Maximum
1000
Temp Offset Limit
Variable Name
temp_offset_limit_in_hunds
Format Type
UNSIGNED_DIV100
Default
0
Minimum
300
158
Maximum
500
Output Pulse FCM#
Variable Name
output_pulse_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Output Pulse Factor
Variable Name
output_pulses_per_vol_thous
Format Type
UNSIGNED_DIV1000
Default
10000
Minimum
1
Maximum
50000
Output Pulse Type
Variable Name
output_pulse_type
Format Type
METER_OUTPUT_PULSE_TYPE
Default
GOV
159
Minimum
IV
Maximum
GOV
Alarm Out FCM#
Variable Name
alarm_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Authorized FCM#
Variable Name
authorized_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss FCM#
Variable Name
permissive_fcm_address
Format Type
FCM_ADDRESS_INPUT
160
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss Out FCM#
Variable Name
permissive_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Meter K-Factor
Variable Name
meter_pulses_per_vol
Format Type
UNSIGNED_INT
Default
50
Minimum
1
Maximum
65535
Quad Check Enable
Variable Name
meter_quad_check_enable
161
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Temperature Offset
Variable Name
temp_offset_in_hunds
Format Type
SIGNED_DIV100
Default
0
Minimum
-500
Maximum
500
Temperatr Alarm Time
Variable Name
temp_alarm_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
60
162
Temp Sensor FCM#
Variable Name
temp_sensor_fcm_address
Format Type
FCM_ADDRESS_ANALOG_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Temperature Sensor
Variable Name
temp_sensor_enabled
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
Default Temperature
Variable Name
default_temp_tenths
Format Type
SIGNED_DIV10
Default
9999
Minimum
-9999
163
Maximum
9999
Alarm Low Temp
Variable Name
alarm_low_temp_tenths
Format Type
SIGNED_DIV10
Default
-9999
Minimum
-9999
Maximum
9999
Alarm High Temp
Variable Name
alarm_high_temp_tenths
Format Type
SIGNED_DIV10
Default
9999
Minimum
-9999
Maximum
9999
Temp Module Type
Variable Name
temp_module_type
Format Type
UNSIGNED_INT
164
Default
1
Minimum
0
Maximum
13
Temperature @ Low Value
Variable Name
temp_at_low_value_tenths
Format Type
SIGNED_DIV10
Default
-500
Minimum
-9999
Maximum
9999
Temperature @ High Value
Variable Name
temp_at_high_value_tenths
Format Type
SIGNED_DIV10
Default
3500
Minimum
-9999
Maximum
9999
165
API Gravity Sensor FCM#
Variable Name
api_gravity_sensor_fcm_address
Format Type
FCM_ADDRESS_ANALOG_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Default API Gravity
Variable Name
default_api_gravity_tenths
Format Type
SIGNED_DIV10
Default
0
Minimum
-1000
Maximum
11000
Alarm Low API Gravity
Variable Name
alarm_low_api_gravity_tenths
Format Type
SIGNED_DIV10
Default
-1000
166
Minimum
-1000
Maximum
11000
Alarm High API Gravity
Variable Name
alarm_high_api_gravity_tenths
Format Type
SIGNED_DIV10
Default
11000
Minimum
-1000
Maximum
11000
API Gravity Alarm Time
Variable Name
api_gravity_alarm_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
60
API Gravity @ Low Value
Variable Name
api_gravity_at_low_value_tenths
167
Format Type
SIGNED_DIV10
Default
0
Minimum
-1000
Maximum
11000
API Gravity @ High Value
Variable Name
api_gravity_at_high_value_tenths
Format Type
SIGNED_DIV10
Default
11000
Minimum
-1000
Maximum
11000
API Gravity Offset
Variable Name
api_gravity_offset_in_tenths
Format Type
SIGNED_DIV10
Default
0
Minimum
-30
168
Maximum
30
2.6.8 Component Level Parameters
Firmware Location:
Main Menu -> Configuration -> Equipment Setup -> Component
Permissions: Read and Write
Script Reference:
ml.equipment.preset[preset_num].component[component_num].<variable_name>
Meter#
Variable Name
component_meter_no
Format Type
UNSIGNED_INT
Default
1
Minimum
1
Maximum
5
High Flow Rate
Variable Name
high_flow_rate
Format Type
UNSIGNED_INT
Default
600
Minimum
0
Maximum
25000
169
1st Stage Trip Vol
Variable Name
first_stage_trip_vol
Format Type
UNSIGNED_INT
Default
70
Minimum
0
Maximum
65535
1st Stage Flow Rate
Variable Name
first_stage_flow_rate
Format Type
UNSIGNED_INT
Default
225
Minimum
0
Maximum
25000
2nd Stage Trip Vol
Variable Name
second_stage_trip_vol
Format Type
UNSIGNED_INT
Default
20
Minimum
0
170
Maximum
65535
2nd Stage Flow Rate
Variable Name
second_stage_flow_rate
Format Type
UNSIGNED_INT
Default
150
Minimum
0
Maximum
25000
Final Trip Vol
Variable Name
final_trip_vol_hunds
Format Type
UNSIGNED_DIV100
Default
115
Minimum
0
Maximum
65535
Final Trip Max Time
Variable Name
final_trip_max_time
Format Type
UNSIGNED_DIV1000
Default
5000
171
Minimum
0
Maximum
65535
Final Trip Vol Lock
Variable Name
final_trip_vol_lock
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Unauth Flow Alrm Vol
Variable Name
unauth_flow_alarm_vol
Format Type
UNSIGNED_INT
Default
10
Minimum
0
Maximum
65535
Tank Group
Variable Name
tank_group
Format Type
UNSIGNED_INT
172
Default
0
Minimum
0
Maximum
9999999
W&M Recipe Percentage
Variable Name
wm_recipe_percentage
Format Type
UNSIGNED_DIV100
Default
0
Minimum
0
Maximum
10000
BlkValve Open Rate
Variable Name
blk_val_open_rate
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
25000
BlkValve Open Delay
Variable Name
blk_val_open_delay
173
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
B.V. Open Alrm Time
Variable Name
blk_val_open_alarm_time
Format Type
UNSIGNED_INT
Default
10
Minimum
2
Maximum
65535
B.V. Close Alrm Time
Variable Name
blk_val_close_alarm_time
Format Type
UNSIGNED_INT
Default
10
Minimum
2
Maximum
65535
174
B.V. Close Alrm Time
Variable Name
blk_val_close_alarm_time
Format Type
UNSIGNED_INT
Default
10
Minimum
2
Maximum
65535
Pump Start Delay
Variable Name
pump_start_delay
Format Type
UNSIGNED_INT
Default
3
Minimum
0
Maximum
65535
Pump Stop Delay
Variable Name
pump_stop_delay
Format Type
UNSIGNED_INT
Default
30
Minimum
0
Maximum
65535
175
Pump Start Alrm Time
Variable Name
pump_start_alarm_time
Format Type
UNSIGNED_INT
Default
2
Minimum
2
Maximum
65535
Flow Start Delay
Variable Name
flow_start_delay
Format Type
UNSIGNED_INT
Default
5
Minimum
0
Maximum
65535
Unauth Reset Time
Variable Name
unauth_reset_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
176
Maximum
65535
Fallback Rate
Variable Name
fallback_rate
Format Type
UNSIGNED_INT
Default
350
Minimum
0
Maximum
25000
Fallback Time
Variable Name
fallback_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Fallback Retry Time
Variable Name
fallback_retry_time
Format Type
UNSIGNED_INT
Default
0
177
Minimum
0
Maximum
65535
Fallback Retry Vol
Variable Name
fallback_retry_vol
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Fallback Minimum Pressure
Variable Name
fallback_min_pressure_hunds
Format Type
UNSIGNED_DIV100
Default
0
Minimum
0
Maximum
999999
Fallback Minimum Rate
Variable Name
fallback_min_rate
Format Type
UNSIGNED_INT
178
Default
0
Minimum
0
Maximum
25000
Fallback Increase Rate
Variable Name
fallback_increase_rate
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
25000
Fallback Decrease Rate
Variable Name
fallback_decrease_rate
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
25000
Fallback Retry Min Pressure
Variable Name
fallback_retry_min_pressure
179
Format Type
UNSIGNED_DIV100
Default
0
Minimum
0
Maximum
999999
Fallback Vapor Pressure
Variable Name
fallback_vapor_pressure_enable
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
API Table
Variable Name
api_table_name
Format Type
API_TABLE_NAME
Default
None
Minimum
None
Maximum
ASTM D4311-04 Asphalt
180
API 54YG Product
Variable Name
api_54yg_product
Format Type
API_54YG_PRODUCT_TYPE
Default
NO PRODUCT
Minimum
NO PRODUCT
Maximum
P-XYLOL
API Extrapolated Range
Variable Name
api_extrapolated_range
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
API BIO
Variable Name
api_bio_product
Format Type
API_BIO_PRODUCT_TYPE
Default
NO PRODUCT
Minimum
NO PRODUCT
Maximum
B100 SME
181
API Gravity
Variable Name
default_api_gravity_tenths
Format Type
SIGNED_DIV10
Default
0
Minimum
-1000
Maximum
11000
Relative Density
Variable Name
default_relative_density_tenthous
Format Type
UNSIGNED_DIV10000
Default
0
Minimum
0
Maximum
90000
Default Density
Variable Name
default_density_tenths
Format Type
UNSIGNED_DIV10
Default
0
182
Minimum
0
Maximum
99999
Expansion Coef.
Variable Name
api_expansion_coef_tenths
Format Type
UNSIGNED_DIV10
Default
0
Minimum
0
Maximum
20000
Hydrometer Used
Variable Name
api_hydrometer_used
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Commodity Type
Variable Name
commodity_type
Format Type
COMMODITY_TYPE
183
Default
REFINED
Minimum
NONE
Maximum
LUBRICATING OILS
Expansion Coef. UOM
Variable Name
exp_coef_uom
Format Type
EXP_COEF_UOM_TYPE
Default
CELSIUS (1/C)
Minimum
FAHRENHEIT (1/F)
Maximum
CELSIUS (1/C)
Density UOM
Variable Name
density_uom
Format Type
DENSITY_UOM_TYPE
Default
kg/m3
Minimum
kg/m3
Maximum
RELATIVE DENSITY
Pressure UOM
Variable Name
pressure_uom
184
Format Type
PRESSURE_UOM_TYPE
Default
BAR
Minimum
PSIG
Maximum
BAR
Reference Temperature
Variable Name
reference_temp
Format Type
UNSIGNED_INT
Default
60
Minimum
0
Maximum
9999
API Alarm Time
Variable Name
api_alarm_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
120
185
Compressibility Factor
Variable Name
compressibility_factor
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
99999
API ASTMD1555 Product
Variable Name
api_astm_d1555_product
Format Type
API_ASTM_D1555_PRODUCT_TYPE
Default
NO PRODUCT
Minimum
NO PRODUCT
Maximum
350 - 40F HYDROCARBON
Output Pulse FCM#
Variable Name
output_pulse_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
186
Output Pulse Factor
Variable Name
output_pulses_per_vol_thous
Format Type
UNSIGNED_DIV1000
Default
10000
Minimum
1
Maximum
50000
Output Pulse Type
Variable Name
output_pulse_type
Format Type
DELIVER_TYPE
Default
GOV
Minimum
GOV
Maximum
IV
Close Blk Val FCM#
Variable Name
close_blk_val_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
187
Maximum
Please refer to the format type description
Blk Val Status FCM#
Variable Name
blk_val_status_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Open Blk Val FCM#
Variable Name
open_blk_val_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Pump Run FCM#
Variable Name
pump_run_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
188
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Pump Kill FCM#
Variable Name
pump_kill_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Pump Status FCM#
Variable Name
pump_status_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Alarm Out FCM#
Variable Name
alarm_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
189
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Authorized FCM#
Variable Name
authorized_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss FCM#
Variable Name
permissive_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss Out FCM#
Variable Name
permissive_out_fcm_address
190
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Meter Factor #1
Variable Name
meter_factor_1
Format Type
UNSIGNED_DIV10000
Default
10000
Minimum
8000
Maximum
12000
Meter Factor #1 Rate
Variable Name
meter_factor_rate_1
Format Type
UNSIGNED_INT
Default
150
Minimum
0
Maximum
25000
191
Meter Factor #2
Variable Name
meter_factor_2
Format Type
UNSIGNED_DIV10000
Default
10000
Minimum
8000
Maximum
12000
Meter Factor #2 Rate
Variable Name
meter_factor_rate_2
Format Type
UNSIGNED_INT
Default
200
Minimum
0
Maximum
25000
Meter Factor #3
Variable Name
meter_factor_3
Format Type
UNSIGNED_DIV10000
Default
10000
Minimum
8000
Maximum
12000
192
Meter Factor #3 Rate
Variable Name
meter_factor_rate_3
Format Type
UNSIGNED_INT
Default
400
Minimum
0
Maximum
25000
Meter Factor #4
Variable Name
meter_factor_4
Format Type
UNSIGNED_DIV10000
Default
10000
Minimum
8000
Maximum
12000
Meter Factor #4 Rate
Variable Name
meter_factor_rate_4
Format Type
UNSIGNED_INT
Default
800
Minimum
0
193
Maximum
25000
# Meter Factors Used
Variable Name
meter_factor_rate_4
Format Type
UNSIGNED_INT
Default
4
Minimum
1
Maximum
4
2.6.9 Additive Level Parameters
Firmware Location:
Main Menu -> Configuration -> Equipment Setup -> Additive
Permissions: Read and Write
Script Reference:
ml.equipment.preset[preset_num].additive[additive_num].<variable_name>
Additive Enable
Variable Name
additive_enable
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
194
Flow Control Module#
Variable Name
fcm_number
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
31
FCM Port#
Variable Name
port_number
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
3
W&M Controlled
Variable Name
wm_controlled
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
195
Maximum
ENABLED
Upstream Block Valve
Variable Name
upstream_block_valve
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Additive Type
Variable Name
additive_type
Format Type
ADDITIVE_TYPE
Default
SOLENOID WITH METER
Minimum
SOLENOID WITH METER
Maximum
ANALOG VALVE WITH METER (0-20 mA)
Additive P Factor
Variable Name
additive_pid_p_factor_thous
Format Type
UNSIGNED_DIV1000
Default
1000
196
Minimum
0
Maximum
100000
Additive I Time
Variable Name
additive_pid_i_time_thous
Format Type
UNSIGNED_DIV1000
Default
3000
Minimum
0
Maximum
60000
Additive D Time
Variable Name
additive_pid_d_time_thous
Format Type
UNSIGNED_DIV1000
Default
0
Minimum
0
Maximum
60000
Additive No Flow mA
Variable Name
additive_no_flow_ma
Format Type
UNSIGNED_DIV1000
197
Default
0
Minimum
0
Maximum
20000
Additive Mode
Variable Name
additive_mode
Format Type
ADDITIVE_MODE
Default
START ON BATCH
Minimum
START ON BATCH
Maximum
START ON VOLUME
Start Volume
Variable Name
start_volume
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
198
Restart Volume
Variable Name
restart_volume
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Solenoid Shut Pulses
Variable Name
solenoid_shut_pulses
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
255
Shutoff Vol From End
Variable Name
shutoff_pt
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
199
LastInj Vol From End
Variable Name
last_inject_pt
Format Type
UNSIGNED_INT
Default
20
Minimum
0
Maximum
65535
Line Flush Min Vol
Variable Name
line_flush_min_vol
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Assigned Component
Variable Name
assigned_component
Format Type
UNSIGNED_INT
Default
0
Minimum
0
200
Maximum
8
W&M Recipe Percentage
Variable Name
wm_recipe_percentage
Format Type
PERCENT_DIV10000
Default
0
Minimum
0
Maximum
65535
Additive Chk Start Vol
Variable Name
add_chk_start_vol
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Additive Vol/Inject
Variable Name
vol_10thous_per_inject
Format Type
UNSIGNED_DIV10000
Default
200
201
Minimum
0
Maximum
65535
Vol/Inject Cal Factr
Variable Name
vol_factor
Format Type
UNSIGNED_DIV10000
Default
10000
Minimum
1
Maximum
65535
Additive Tol Percentage
Variable Name
add_alarm_percentage
Format Type
PERCENT
Default
0
Minimum
0
Maximum
10000
Additive Mtr K-Factr
Variable Name
pulses_per_vol
Format Type
UNSIGNED_INT
202
Default
2600
Minimum
0
Maximum
65535
Additive Mtr Factor
Variable Name
pulse_factor
Format Type
UNSIGNED_DIV10000
Default
10000
Minimum
1
Maximum
65535
Max Pstn Missed Inj
Variable Name
max_piston_missed_injects
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
MaxSolenoid Inj Time
Variable Name
max_solenoid_injection_time
203
Format Type
UNSIGNED_DIV1000
Default
4000
Minimum
0
Maximum
10000
Under Add Alrm # Inj
Variable Name
under_add_alarm_injects
Format Type
UNSIGNED_INT
Default
3
Minimum
0
Maximum
65535
Over Add Alrm # Inj
Variable Name
over_add_alarm_injects
Format Type
UNSIGNED_INT
Default
3
Minimum
0
Maximum
65535
204
Check Add Tol Time
Variable Name
check_add_tol_time
Format Type
UNSIGNED_INT
Default
10
Minimum
0
Maximum
65535
Unauth Flow Alrm Vol
Variable Name
unauth_flow_alarm_vol
Format Type
UNSIGNED_DIV1000
Default
100
Minimum
0
Maximum
65535
Valve Fault Alrm Vol
Variable Name
valve_fault_alarm_vol
Format Type
UNSIGNED_DIV1000
Default
300
Minimum
0
Maximum
65535
205
Over Inject Vol
Variable Name
over_inject_vol
Format Type
UNSIGNED_DIV1000
Default
0
Minimum
0
Maximum
65535
Creep Reset Time
Variable Name
creep_reset_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
Unauth Reset Time
Variable Name
unauth_reset_time
Format Type
UNSIGNED_INT
Default
0
Minimum
0
206
Maximum
65535
Max Pistn Throw Time
Variable Name
max_piston_throw_time
Format Type
UNSIGNED_DIV1000
Default
1800
Minimum
100
Maximum
10000
Pump Start Alrm Time
Variable Name
pump_start_alarm_time
Format Type
UNSIGNED_INT
Default
2
Minimum
2
Maximum
65535
Meter Creep Alrm Vol
Variable Name
meter_creep_alarm_vol
Format Type
UNSIGNED_DIV1000
Default
0
207
Minimum
150
Maximum
65535
Remote Calibration
Variable Name
remote_cal_enable
Format Type
DISABLE_ENABLE
Default
ENABLED
Minimum
DISABLED
Maximum
ENABLED
B.V. Open Alrm Time
Variable Name
blk_val_open_alarm_time
Format Type
UNSIGNED_INT
Default
10
Minimum
2
Maximum
65535
B.V. Close Alrm Time
Variable Name
blk_val_close_alarm_time
Format Type
UNSIGNED_INT
208
Default
10
Minimum
2
Maximum
65535
Pump Stop Delay
Variable Name
pump_stop_delay
Format Type
UNSIGNED_INT
Default
5
Minimum
0
Maximum
65535
Flush Pump Run Time
Variable Name
flush_pump_run_time
Format Type
UNSIGNED_INT
Default
30
Minimum
0
Maximum
65535
Meter Flushed
Variable Name
meter_flushed
209
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
Solenoid Flushed
Variable Name
solenoid_flushed
Format Type
DISABLE_ENABLE
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
W&M Alarm Promo Count
Variable Name
wm_alarm_promo_count
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
210
W&M Alarm Reset Mode
Variable Name
wm_alarm_reset_mode
Format Type
ALARM_COUNT_RESET_MODE
Default
AUTHORIZED
Minimum
AUTHORIZED
Maximum
24 HRS
Flush Pump Run FCM#
Variable Name
flush_pump_run_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Close Blk Val FCM#
Variable Name
close_blk_val_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
211
Blk Val Status FCM#
Variable Name
blk_val_status_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Open Blk Val FCM#
Variable Name
open_blk_val_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Test Button FCM#
Variable Name
test_button_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
212
Maximum
Please refer to the format type description
Pump Run FCM#
Variable Name
pump_run_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Pump Kill FCM#
Variable Name
pump_kill_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Pump Status FCM#
Variable Name
pump_status_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
213
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Alarm Out FCM#
Variable Name
alarm_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Authorized FCM#
Variable Name
authorized_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss FCM#
Variable Name
permissive_fcm_address
Format Type
FCM_ADDRESS_INPUT
214
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss Out FCM#
Variable Name
permissive_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
2.6.10 Sampler Level Parameters
Firmware Location:
Main Menu -> Configuration -> Equipment Setup -> Sampler
Permissions: Read and Write
Script Reference:
ml.equipment.preset[preset_num].sampler[sampler_num].<variable_name>
Sampler Enable
Variable Name
sampler_enable
Format Type
DISABLE_ENABLE
Default
ENABLED
215
Minimum
DISABLED
Maximum
ENABLED
Flow Control Module#
Variable Name
fcm_number
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
31
FCM Port#
Variable Name
port_number
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
3
W&M Controlled
Variable Name
wm_controlled
Format Type
DISABLE_ENABLE
216
Default
DISABLED
Minimum
DISABLED
Maximum
ENABLED
W&M Alarm Promo Count
Variable Name
wm_alarm_promo_count
Format Type
UNSIGNED_INT
Default
0
Minimum
0
Maximum
65535
W&M Alarm Reset Mode
Variable Name
wm_alarm_reset_mode
Format Type
ALARM_COUNT_RESET_MODE
Default
AUTHORIZED
Minimum
AUTHORIZED
Maximum
24 HRS
Sampler Vol/Sample
Variable Name
vol_10thous_per_sample
217
Format Type
UNSIGNED_DIV10000
Default
200
Minimum
0
Maximum
65535
Vol/Sample Cal Factr
Variable Name
vol_factor
Format Type
UNSIGNED_DIV10000
Default
10000
Minimum
1
Maximum
65535
Injection Time
Variable Name
injection_time_msec
Format Type
UNSIGNED_DIV1000
Default
1000
Minimum
1
Maximum
65535
218
Alarm Out FCM#
Variable Name
alarm_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Authorized FCM#
Variable Name
authorized_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Permiss FCM#
Variable Name
permissive_fcm_address
Format Type
FCM_ADDRESS_INPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
219
Permiss Out FCM#
Variable Name
permissive_out_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
Hi Limit FCM#
Variable Name
hi_limit_fcm_address
Format Type
FCM_ADDRESS_OUTPUT
Default
DISABLED
Minimum
Please refer to the format type description
Maximum
Please refer to the format type description
2.6.11 Transaction Parameters
A transaction is represented as a single header and multiple details. The header contains basic information about
the transaction (BOL number, start and stop times, driver number, etc...). The details contain the measurement
data (GOV, GSV, mass, weighted average values, etc). You can reference the most recent transaction by using the
ml.transactions.header table, and the ml.transactions.details table. You can reference previous transactions my
using the ml.transactions.archives table.
2.6.11.1 Header Parameters
Firmware Location:
Main Menu -> Views & Inquiries -> Transactions
220
Permissions: Read Only
Script Reference:
ml.transactions.header.<variable_name>
ml.transactions.archives[bol_index].header.<variable_name>
BOL Number
Variable Name
Data Type
Description
Card ID
Variable Name
Data Type
Description
Load Start Date & Time
Variable Name
Data Type
Description
221
Load Stop Date & Time
Variable Name
Data Type
Description
Number of Details
Variable Name
Data Type
Description
2.6.11.2 Detail Types
Each detail inside of a transaction will be given a type. The type will specify how the data is to be interpreted. The
type is represented as a number, and is assigned to the field name type (page 226). All detail types are listed
below:
UNUSED
Value
Description
SALEABLE
Value
222
Description
COMPONENT
Value
Description
ADDITIVE
Value
Description
METER
Value
Description
SAMPLER
Value
223
Description
FREE
Value
Description
TOTALIZER_PRESET
Value
Description
TOTALIZER_METER
Value
Description
TOTALIZER_COMPONENT
Value
Description
TOTALIZER_ADDITIVE
Value
224
Description
TOTALIZER_SAMPLER
Value
Description
OBSERVED_VALUES
Value
Description
INITIAL_TOTALIZER_PRESET
Value
Description
INITIAL_TOTALIZER_METER
Value
Description
INITIAL_TOTALIZER_COMPONENT
Value
225
Description
INITIAL_TOTALIZER_ADDITIVE
Value
Description
INITIAL_TOTALIZER_SAMPLER
Value
Description
2.6.11.3 Detail Parameters
Permissions: Read Only
Script Reference:
ml.transactions.details[detail_num].<variable_name>
ml.transactions.archives[bol_index].details[detail_num].<variable_name>
Note: The number of details in a transaction may vary so it is important to read the number of details from the
header before attempting to access them, or use the length operator
Preset
Variable Name
Data Type
Description
226
Index
Variable Name
Data Type
Description
Detail Type
Index Type
COMPONENT
Component
number
METER
Component
number
ADDITIVE
Additive
number
SAMPLER
Sampler
number
TOTALIZER_METER
Meter number
TOTALIZER_COMPONENT
Component
number
TOTALIZER_ADDITIVE
Additive
number
TOTALIZER_SAMPLER
Sampler
number
INITIAL_TOTALIZER_METER
Meter number
INITIAL_TOTALIZER_COMPONENT
Component
number
227
INITIAL_TOTALIZER_ADDITIVE
Additive
number
INITIAL_TOTALIZER_SAMPLER
Sampler
number
Alarm (Flag)
Variable Name
Data Type
Description
Type
Variable Name
Data Type
Description
Measured For Trade
Variable Name
228
Data Type
Description
Detail Type
Scenario
SALEABLE
TRUE (value = 1): If only one meter involved in
the transaction (ie single component product).
FALSE (value = 0): If multiple meters involved
in the transaction (ie blended product).
COMPONENT
FALSE (value = 0): If the component is assigned
to a side stream meter. Side-Stream on Mtr#
(Meter Level Parameter) 0.
FALSE (value = 0): If the Blending Type (Preset
Level Parameter) is set to WATERCUT.
Otherwise it is TRUE (value =1).
METER
TRUE (value = 1): Always
Density/API Gravity/Relative Density Type
Variable Name
Data Type
Description
Type
Value
229
None
0
Density
1
API Gravity
2
Relative Density
3
Corrected Density/API Gravity/Relative Density Type
Variable Name
Data Type
Description
Type
Value
None
0
Density
1
API Gravity
2
Relative Density
3
Product Code
Variable Name
Data Type
230
Description
IV Delivered
Variable Name
Data Type
Description
GOV Delivered
Variable Name
Data Type
Description
GSV Delivered
Variable Name
Data Type
Description
NSV Delivered
Variable Name
Data Type
231
Description
Mass Delivered
Variable Name
Data Type
Description
Temperature
Variable Name
Data Type
Description
Pressure
Variable Name
Data Type
Description
Density/API Gravity/Relative Density
Variable Name
232
Data Type
Description
Type
Implied Decimal
Density
tenths
API Gravity
tenths
Relative Density
ten-thousandths (to the left of
the last four digits)
Compartment
Variable Name
Data Type
Description
API Expansion Coefficient
Variable Name
Data Type
Description
233
Corrected Density/API Gravity/Relative Density
Variable Name
Data Type
Description
Type
Implied Decimal
Density
tenths
API Gravity
tenths
Relative Density
ten-thousandths (to the left of
the last four digits)
Volume Correction Factor (or CTPL)
Variable Name
Data Type
Description
BSW
Variable Name
Data Type
234
Description
Alarms
Variable Name
Data Type
Description
Detail Type
Alarm Level
SALEABLE
Preset
COMPONENT
Component
METER
Meter
ADDITIVE
Additive
SAMPLER
Sampler
Temperature Correction Factor (CTL)
Variable Name
Data Type
Description
235
Pressure Correction Factor (CPL)
Variable Name
Data Type
Description
Weighted Meter Factor
Variable Name
Data Type
Description
Meter Pulses per Volume (K-Factor)
Variable Name
Data Type
Description
2.6.11.4 Processed
Permissions: Read and Write
Script Reference:
236
ml.transactions.archives[bol_index].processed
This parameter is intended to be used to flag when a transaction has been processed (e.g. insert data into
SQL table, or upload data to a webservice etc…).
2.6.11.5 Example Code
Here is a simple example of how to process a transaction using the ml.transactions.archives table. This code was
designed to be run in the background.lua script.
-- ============================================================================
-- background.lua
--
-- This script runs in the background and is responsible for periodically
-- checking if there are unprocessed transactions needed to be inserted into
-- the TransactionHeader table.
-- ============================================================================
-- Add informational message for possible debugging assistance.
LogMsg(LOG_LEVEL_INFORMATIONAL, "Start of background.lua script.")
-- Requires
local sqlite3 = require("sqlite3")
while true do
local err = false
if ml.info.rcu_status ~= 'IDLE' then
goto sleep
end
-- Loop through all transactions stored in flash memory
for index=1, #ml.transactions.archives do
local db, e = sqlite3.open('file:/auto/mmc_1/SQL/MULTILOAD.B?cache=shared')
local stmt_header =
db:prepare(
[[INSERT INTO TransactionHeader
( driver_id, bol_no, load_start, load_stop, gov, gsv, temp, product_code )
VALUES
( :driver_id, :bol_no, :load_start, :load_stop, :gov, :gsv, :temp, :prod_code );
]]
)
local stmt_driver =
db:prepare("SELECT id FROM Driver WHERE driver_number = ?")
local transaction = ml.transactions.archives[index]
if transaction then
if not transaction.processed then
db:exec("BEGIN TRANSACTION;")
local header = {}
local driver_id = nil
-- Insert card_id into SQL statement
stmt_driver:bind(1, transaction.header.card_id)
-- Execute SQL statement to retrive the id from the Driver table
if stmt_driver:step() == sqlite3.ROW then
237
driver_id = stmt_driver:get_value(0)
else
LogMsg(
LOG_LEVEL_ERROR,
"Database error retrieving driver_id from Driver: " ..
db:errmsg())
driver_id = 0
end
header.driver_id = driver_id
header.bol_no = transaction.header.bolno
-- Format the date from epoch time to a string (YYYY-MM-DD HH:MM:SS)
header.load_start =
os.date("%Y-%m-%d %H:%M:%S", transaction.header.load_start)
header.load_stop =
os.date("%Y-%m-%d %H:%M:%S", transaction.header.load_stop)
for index,detail in ipairs(transaction.details) do
-- All details are assigned a type which indicates
-- how to interpret the data. Detail Type == 1
-- is called a SALEABLE type, which means it will
-- contain the total volume that passed through
-- the preset. A detail type == 2, is called a
-- COMPONENT type which only contains the volumetric
-- data for a particular component.
-- Please reference section 2.6.9.2 in the Slate reference guide.
if detail.type == 1 then -- If SALEABLE type
header.prod_code = detail.prod_code
-- Temp stored with an implicit 2 decimal
header.temp = detail.temp_hund / 100
-- if hundredths is configured, convert to decimal
if ml.equipment.rcu.use_hunds == 1 then
header.gov = detail.gov_del / 100
header.gsv = detail.gsv_del / 100
else
header.gov = detail.gov_del
header.gsv = detail.gsv_del
end
end
end
-- Insert variables into prepared SQL statement
if stmt_header:bind_names(header) ~= sqlite3.OK then
LogMsg(
LOG_LEVEL_ERROR,
"Database error creating prepared statement: " .. db:errmsg())
goto next_transaction
end
-- Execute SQL statement
if stmt_header:step() ~= sqlite3.DONE then
LogMsg(
LOG_LEVEL_ERROR,
"Database error inserting TransactionHeader: " .. db:errmsg())
goto next_transaction
end
ml.transactions.archives[index].processed = true
db:exec("COMMIT TRANSACTION;")
goto next_transaction
end
end
238
:: next_transaction ::
stmt_header:finalize()
stmt_driver:finalize()
db:close()
Sleep(1)
end
LogMsg(LOG_LEVEL_INFORMATIONAL, "End of process_transaction.lua script.")
::sleep::
if db and db:isopen() then
db:close()
end
Sleep(30) -- Sleep for 30 seconds
end
-- Shouldn't reach this point (unless all coroutines die)
LogMsg(LOG_LEVEL_INFORMATIONAL, "End of background.lua script.")
Example Code 2.5 Processing a Transaction
2.6.12 Totalizer Parameters
There are two sets of totalizers accessible via Lua, non-resettable and resettable totalizers. They are both
read only, but the resettable totalizers can be reset back to zero.
Preset (Line for SCS) Totalizers
Firmware Location:
Main Menu -> Views & Inquiries -> Totalizers
Permissions: Read Only
Script Reference:
ml.totalizers.preset[preset_num].<variable_name>
ml.resettable_totalizers.preset[preset_num].<variable_name>
Total IV
Variable Name
Description
239
Authorized IV
Variable Name
Description
Unauthorized IV
Variable Name
Description
Total GOV
Variable Name
Description
Authorized GOV
Variable Name
Description
240
Unauthorized GOV
Variable Name
Description
Alibilog Daily GOV
Variable Name
Description
Total GSV
Variable Name
Description
Authorized GSV
Variable Name
Description
241
Unauthorized GSV
Variable Name
Description
Alibilog Daily GSV
Variable Name
Description
Total Mass
Variable Name
Description
Authorized Mass
Variable Name
Description
242
Unauthorized Mass
Variable Name
Description
Alibilog Daily Mass
Variable Name
Description
Component Totalizers
Permissions: Read Only
Script Reference:
ml.totalizers.preset[preset_num].component[component_num].<variable_name>
ml.resettable_totalizers.preset[preset_num].component[component_num].<variable_name>
Total IV
Variable Name
Description
243
Authorized IV
Variable Name
Description
Unauthorized IV
Variable Name
Description
Total GOV
Variable Name
Description
Authorized GOV
Variable Name
Description
244
Unauthorized GOV
Variable Name
Description
Alibilog Daily GOV
Variable Name
Description
Total GSV
Variable Name
Description
Authorized GSV
Variable Name
Description
245
Unauthorized GSV
Variable Name
Description
Alibilog Daily GSV
Variable Name
Description
Total Mass
Variable Name
Description
Authorized Mass
Variable Name
Description
246
Unauthorized Mass
Variable Name
Description
Alibilog Daily Mass
Variable Name
alibi_log_daily_mass_del
Description
This totalizer is used in conjunction the FEODLOG command that can be sent by a host
system to the unit. The totalizer follows the Total Mass totalizer movement. The difference
is that the Alibilog Daily Mass can be reset by having a host system send the FEODLOG
command.
Note: This totalizer is only available as a resettable totalizer. So you will need to reference it
by using the ml.resettable_totalizer prefix. Referencing
ml.totalizers.preset[preset_num].component[component_num].alibi_log_daily_mass_del
will always return zero.
Meter Totalizers
Permissions: Read Only
Script Reference:
ml.totalizers.preset[preset_num].meter[meter_num].<variable_name>
ml.resettable_totalizers.preset[preset_num].meter[meter_num].<variable_name>
Total IV
Variable Name
Description
247
Authorized IV
Variable Name
Description
Unauthorized IV
Variable Name
Description
Total GOV
Variable Name
Description
Authorized GOV
Variable Name
Description
Unauthorized GOV
Variable Name
248
Description
Alibilog Daily GOV
Variable Name
Description
Meter Creep GOV
Variable Name
Description
Additive Totalizers
Permissions: Read Only
Script Reference:
ml.totalizers.preset[preset_num].additive[additive_num].<variable_name>
ml.resettable_totalizers.preset[preset_num].additive[additive_num].<variable_name>
249
Total GOV
Variable Name
Description
Authorized GOV
Variable Name
Description
Unauthorized GOV
Variable Name
Description
Alibilog Daily GOV
Variable Name
Description
250
Meter Creep GOV
Variable Name
Description
Sampler Totalizers
Permissions: Read Only
Script Reference:
ml.totalizers.preset[preset_num].sampler[sampler_num].<variable_name>
ml.resettable_totalizers.preset[preset_num].sampler[sampler_num].<variable_name>
Total GOV
Variable Name
Description
Alibilog Daily GOV
Variable Name
Description
251
2.6.13 Product Definition Parameters
Products are broken up into four types Saleable, Components, Additives, and Samplers. However, they all reside
in one big array. The way a product is structured, is illustrated below using C programming syntax:
int MAX_PRODUCTS = 100
int MAX_COMPONENTS = 8
int MAX_ADD_PROD = 12
int MAX_SAMPLER_PROD = 4
struct products_def
{
unsigned int hazard_idx; // index to hazard array
char code[6]; // product code
char long_desc[25]; // long product description
char desc[10]; // product description
struct blend_def
{
unsigned int product_index; // component product index
unsigned int pct; // component percent 999v99%
} component[MAX_COMPONENTS];
struct prod_additive_def
{
unsigned int product_index; // additive product index
unsigned int pct; // additive percent 9v9999%
} additive[MAX_ADD_PROD];
struct prod_sampler_def
{
unsigned int product_index; // sampler product index
unsigned int pacing_rate_hunds; // sampler pacing rate (999v99)
} sampler[MAX_SAMPLER_PROD];
} products[MAX_PRODUCTS];
Here is some sample code that illustrates how to create and delete products:
-----------------------------------------------------------------------
-- This function deletes all products from the configuration
-----------------------------------------------------------------------
function clear_products()
local prod_idx = 1
for prod_idx = 1, MAX_PRODUCTS-1 do
ml.config.products[prod_idx].code = ''
ml.config.products[prod_idx].desc = ''
ml.config.products[prod_idx].long_desc = ''
ml.config.products[prod_idx].hazard_idx = 0
local comp_idx = 1
for comp_idx = 1, MAX_COMPONENTS do
ml.config.products[prod_idx].component[comp_idx].product_index = 0
ml.config.products[prod_idx].component[comp_idx].pct = 0
end
252
local MAX_ADD_PROD = 12
local add_idx = 1
for add_idx = 1, MAX_ADD_PROD do
ml.config.products[prod_idx].additive[add_idx].product_index = 0
ml.config.products[prod_idx].additive[add_idx].pct = 0
end
local MAX_SAMPLER_PROD = 4
local samp_idx = 1
for samp_idx = 1, MAX_SAMPLER_PROD do
ml.config.products[prod_idx].sampler[samp_idx].product_index = 0
ml.config.products[prod_idx].sampler[samp_idx].pacing_rate_hunds = 0
end
end
end
--------------------------------------------------------------------------------
-- This function finds the next available position in the list of products
--------------------------------------------------------------------------------
function find_empty_product_index()
for prod_idx = 1, MAX_PRODUCTS-1 do
if ml.config.products[prod_idx].component[1].product_index == 0 then
LogMsg(LOG_LEVEL_ERROR, "Found Empty Slot: " .. prod_idx)
return prod_idx
end
end
return 0
end
--------------------------------------------------------------------------------
-- This function creates a base component, and inserts in the next available
-- position in the list of products
--------------------------------------------------------------------------------
function createBaseComponent(code, short_desc, long_desc)
local index = find_empty_product_index()
if index == 0 then
return 0
end
ml.config.products[index].code = code
ml.config.products[index].desc = short_desc
ml.config.products[index].long_desc = long_desc
ml.config.products[index].component[1].product_index = index
ml.config.products[index].component[1].pct = 10000
return index
end
--------------------------------------------------------------------------------
-- This function creates a base additive, and inserts in the next available
-- position in the list of products
--------------------------------------------------------------------------------
function createBaseAdditive(code, short_desc, long_desc)
local index = find_empty_product_index()
if index == 0 then
return 0
end
253
ml.config.products[index].code = code
ml.config.products[index].desc = short_desc
ml.config.products[index].long_desc = long_desc
ml.config.products[index].component[1].product_index = index
ml.config.products[index].component[1].pct = 10000
ml.config.products[index].additive[1].product_index = index
ml.config.products[index].additive[1].pct = 0
return index
end
--------------------------------------------------------------------------------
-- This function creates a base sampler, and inserts in the next available
-- position in the list of products
--------------------------------------------------------------------------------
function createBaseSampler(code, short_desc, long_desc)
local index = find_empty_product_index()
if index == 0 then
return 0
end
ml.config.products[index].code = code
ml.config.products[index].desc = short_desc
ml.config.products[index].long_desc = long_desc
ml.config.products[index].component[1].product_index = index
ml.config.products[index].component[1].pct = 10000
ml.config.products[index].sampler[1].product_index = index
ml.config.products[index].sampler[1].pacing_rate_hunds = 0
return index
end
-------------------------------------------------------------------------------------------------
-- This function creates a saleable product, and inserts in the next available
-- position in the list of products
--
-- recipe is a table of all the recipe components:
-- { product_index = index of the base component, additive, or sampler
-- percentage = percentage (or pacing rate for smapler) of product pointed to by product_index
-- type = type of base component (Component, Additive, or Sampler)
-- }
--------------------------------------------------------------------------------------------------
function createSaleable(code, short_desc, long_desc, recipe)
local index = find_empty_product_index()
if index == 0 then
return 0
end
ml.config.products[index].code = code
ml.config.products[index].desc = short_desc
ml.config.products[index].long_desc = long_desc
local comp_idx = 1
local add_idx = 1
254
local samp_idx = 1
local recipe_index
for recipe_index=1,#recipe do
if(recipe[recipe_index].type == 'C') then
ml.config.products[index].component[comp_idx].product_index =
recipe[recipe_index].product_index
ml.config.products[index].component[comp_idx].pct = recipe[recipe_index].percentage
comp_idx = comp_idx +1
elseif(recipe[recipe_index].type == 'A') then
ml.config.products[index].additive[add_idx].product_index =
recipe[recipe_index].product_index
ml.config.products[index].additive[add_idx].pct = recipe[recipe_index].percentage
add_idx = add_idx +1
elseif(recipe[recipe_index].type == 'S') then
ml.config.products[index].sampler[samp_idx].product_index =
recipe[recipe_index].product_index
ml.config.products[index].sampler[samp_idx].pacing_rate_hunds =
recipe[recipe_index].percentage
samp_idx = samp_idx +1
end
end
return index
end
Example Code 2.6 Product Management
Here is an example of a schema that can be used for managing products in SQLite:
CREATE TABLE Base(
id INTEGER PRIMARY KEY AUTOINCREMENT,
code char( 6) NOT NULL,
short_desc char(10) ,
long_desc char(25) ,
type char( 1) , -- (C)omponent, (A)dditive, or (S)ampler
UNIQUE (code) );
-- ===============================================================================================
-- Start Loading Data in (Base) Table
-- ===============================================================================================
INSERT INTO `Base` (code, short_desc, long_desc, type) VALUES (
'REG87' , 'Regular 87', 'Regular 87' , 'C');
INSERT INTO `Base` (code, short_desc, long_desc, type) VALUES (
'PREM93', 'Premium 93', 'Premium 93' , 'C');
INSERT INTO `Base` (code, short_desc, long_desc, type) VALUES (
'ADT01' , 'Toptch Adt', 'Toptech Additive' , 'A');
255
CREATE TABLE Saleable(
id INTEGER PRIMARY KEY AUTOINCREMENT,
code char( 6) NOT NULL,
short_desc char(10) ,
long_desc char(25) ,
UNIQUE (code) );
--==================================================================================================
-- Start Loading Data in (Saleable) Table
--=================================================================================================
INSERT INTO `Saleable` (code, short_desc, long_desc) VALUES (
'REG' , 'Regular' , 'Regular Gasoline' );
INSERT INTO `Saleable` (code, short_desc, long_desc) VALUES (
'PREM' , 'Premium' , 'Premium Gasoline' );
INSERT INTO `Saleable` (code, short_desc, long_desc) VALUES (
'MID' , 'Mid 60/40' , 'Mid Grade' );
CREATE TABLE Recipe(
id INTEGER PRIMARY KEY AUTOINCREMENT,
saleable_id INTEGER NOT NULL,
base_id INTEGER NOT NULL,
percentage INTEGER NOT NULL,
pacing_rate INTEGER NOT NULL,
FOREIGN KEY (saleable_id) REFERENCES Saleable(id),
FOREIGN KEY (base_id) REFERENCES Base(id));
-- ================================================================================================
-- Start Loading Data in (Recipe) Table
-- ================================================================================================
-- Create Single Products
INSERT INTO `Recipe` (id, saleable_id, base_id, percentage, pacing_rate) VALUES (
NULL,
(SELECT id FROM Saleable WHERE code='REG' ),
(SELECT id FROM Base WHERE code='REG87' ),
10000,
0);
INSERT INTO `Recipe` (id, saleable_id, base_id, percentage, pacing_rate) VALUES (
NULL,
(SELECT id FROM Saleable WHERE code='PREM'),
(SELECT id FROM Base WHERE code='PREM93'),
10000,
0);
-- Create Blended Product
INSERT INTO `Recipe` (id, saleable_id, base_id, percentage, pacing_rate) VALUES (
NULL,
(SELECT id FROM Saleable WHERE code='MID' ),
(SELECT id FROM Base WHERE code='REG87' ),
6000,
0);
256
INSERT INTO `Recipe` (id, saleable_id, base_id, percentage, pacing_rate) VALUES (
NULL,
(SELECT id FROM Saleable WHERE code='MID' ),
(SELECT id FROM Base WHERE code='PREM93'),
4000,
0);
Example Code 2.7 Products Schema
The sample code below illustrates how to create products and add them to the configuration using the
functions created in Example Code 2.6 and the schema created in Example Code 2.7:
-- Delete all products from configuration
clear_products()
--------------------------------------------------------------------------------------------------
-- Lookup base components, additives, and samplers from SQL
-- Add them to the products configuration
--------------------------------------------------------------------------------------------------
-- create lookup table that stores where the new products are inserted
local prod_lookup_table = {}
stmt = db_prepare("SELECT * FROM Base;")
for base in stmt:nrows() do
local retval = 0
if base.type == 'C' then
retval = createBaseComponent(base.code, base.short_desc, base.long_desc)
elseif base.type == 'A' then
retval = createBaseAdditive(base.code, base.short_desc, base.long_desc)
elseif base.type == 'S' then
retval = createBaseSampler(base.code, base.short_desc, base.long_desc)
end
if retval ~= 0 then
prod_lookup_table[base.code] = retval
end
end
-- end
stmt:finalize()
--------------------------------------------------------------------------------------------------
-- End create base components
--------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------
-- Lookup saleable products from SQL
-- Lookup recipe components that are associated with the saleable from SQL
-- Add saleable product to the configuration
--------------------------------------------------------------------------------------------------
local saleable
for saleable in db:nrows("SELECT * FROM Saleable") do
257
local recipe_list = {}
for recipe in db:nrows("SELECT * FROM Recipe WHERE saleable_id=" .. saleable.id) do
stmt = db_prepare("SELECT * FROM Base WHERE id='" .. recipe.base_id .. "'")
if (stmt:step() == sqlite3.ROW) then
local base = stmt:get_named_values()
table.insert(recipe_list,
{product_index=prod_lookup_table[base.code], percentage=recipe.percentage, type=base.type})
end
stmt:finalize()
end
local retval = createSaleable(saleable.code, saleable.short_desc, saleable.long_desc, recipe_list)
if retval ~= 0 then
prod_lookup_table[saleable.code] = retval
end
end
------------------------------------------------------------------------------------------------
-- End create saleable product
------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------
-- Assign products to the components, so that the flow parameters
-- (API tables, meter factors, etc...) match the correct component product code
-- Assign the saleable products to the preset’s authorized products so that they can be loaded
------------------------------------------------------------------------------------------------
for preset_id = 1,ml.equipment.bay.number_of_presets do
-- Clear all authorized products
for auth_product=1, MAX_RECIPES do
ml.config.preset[preset_id].authorized_products[auth_product] = 0
end
-- Assign the base component products to the correct components in the configuration
ml.config.preset[preset_id].component[1].product_index = prod_lookup_table["REG87"]
ml.config.preset[preset_id].component[2].product_index = prod_lookup_table["PREM93"]
-- Allow all three saleable products to be loaded on all arms
ml.config.preset[preset_id].authorized_products[1] = prod_lookup_table["REG"]
ml.config.preset[preset_id].authorized_products[2] = prod_lookup_table["PREM"]
ml.config.preset[preset_id].authorized_products[3] = prod_lookup_table["MID"]
end
Example Code 2.8 Product Creation Example
2.6.13.1 Product Parameters
Firmware Location:
Main Menu -> Configuration -> Products -> Product Setup
Permissions: Read and Write
Script Reference:
258
ml.config.products[product_index].<variable_name>
Code
Variable Name
Description
Hazard Index
Variable Name
Description
Short Description
Variable Name
Description
Long Description
Variable Name
Description
Components
Variable Name
259
Description
Additives
Variable Name
Description
Samplers
Variable Name
Description
2.6.13.2 Blend Component Parameters
Firmware Location:
Main Menu -> Configuration -> Products -> Product Setup -> <select_product> -> Edit Recipe
Permissions: Read and Write
Script Reference:
ml.config.products[product_index].component[index]<variable_name>
Product Index
Variable Name
Description
260
Percentage
Variable Name
Description
2.6.13.3 Additive Parameters
Firmware Location:
Main Menu -> Configuration -> Products -> Product Setup -> <select_product> -> Edit Recipe
Permissions: Read and Write
Script Reference:
ml.products[product_index].additive[index]<variable_name>
Product Index
Variable Name
Description
Percentage
Variable Name
Description
2.6.13.4 Sampler Parameters
Firmware Location:
Main Menu -> Configuration -> Products -> Product Setup -> <select_product> -> Edit Recipe
Permissions: Read and Write
261
Script Reference:
ml.products[product_index].sampler[index]<variable_name>
Product Index
Variable Name
Description
Percentage
Variable Name
Description
262
Chapter 3 REST API
In order to create a positive developer experience and ease integration with other software, MultiLoad Slate
exposes a RESTful API for managing database data, fetching log messages, and more.
This section will cover the HTTP requests used and their possible response codes. Then it will go over what is
accessible via the REST API and how to access the data. The last two sections will provide you with some
examples, and additional resources that can be used to help with your development.
Authentication
The REST API uses the same authentication method as the MultiLoad web interface, HTTP Digest Authentication,
as defined in RFC 7616. All requests must include a valid Authorization header.
A sample request Authorization header using default credentials follows:
GET /api/dbschema HTTP/1.1
Host: 10.54.49.30
Authorization: Digest username="admin", realm="MultiLoad II", nonce="1487616767", uri="/api/dbschema",
qop=auth, nc=00000074, cnonce="dbecb622eb460223", response="43fc9d9bd751ac9d2ac02db6a81b9b45", opaque=""
Methods
The REST API uses a subset of valid HTTP methods, which are analogous to database CRUD operations as
follows:
HTTP Verb
Operation
GET
Retrieve
POST
Create
PUT
Update
DELETE
Delete
Chapter
3
263
Responses
The API returns a subset of valid HTTP status codes. The following list is not exhaustive.
401 Unauthorized - A valid Authorization header was not present.
404 Not Found - The requested resource was not found.
405 Method Not Allowed - The HTTP method in the request is not valid for the specified resource.
500 Internal Server Error - An internal error has occurred. Try your request again later.
3.3.1 GET
GET operations should return one of the following:
200 OK
The request was successful. The result of the request will be returned as JSON.
400 Bad Request
The request was malformed. The result may be empty or contain a JSON object describing the error.
3.3.2 POST
POST operations should return one of the following:
201 Created
The request was successful, and the resource(s) were created. The result of the request will be JSON
representing the newly created resource.
400 Bad Request
The request was malformed. The result should contain a JSON object describing the error.
3.3.3 PUT
PUT operations should return one of the following:
264
201 Created
The request was successful, and the resource was updated. The result of the request will be JSON representing
the newly updated resource.
400 Bad Request
The request was malformed. The result should contain a JSON object describing the error.
3.3.4 DELETE
DELETE operations should return one of the following:
204 No Content
The request was successful, and the resource was deleted. The response body is zero length.
400 Bad Request
The request was malformed. The result should contain a JSON object describing the error.
Link Headers
MultiLoad supports pagination for some of the API resources. Information about pagination is provided in the
Link header of an API call. Link headers provide links that relate to the resource that was fetched. For example:
Request:
http://<ip_address>/api/equipment/presets/2
Response Header:
Content-Length:57438
Content-Type:application/json; charset=utf-8
Date:Wed, 06 Sep 2017 00:55:53 GMT
Link:<http://ip_address/api/equipment/presets/1>; rel="first",
<http://ip_address/api/equipment/presets/1>; rel="prev", <http://<ip_address>/api/equipment/presets/3>;
rel="next", <http://ip_address/api/equipment/presets/3>; rel="last"
Server:MultiLoad II
The Link field contains four URLs and their relationship type separated by a comma. rel=”first” says that
/api/equipment/presets/1 is the first preset available based on the configuration. rel=”prev” indicates the
previous preset, rel=”next” indicates the next preset, and rel=”last” indicates the last preset. This tells you that
you will have to loop from preset 1 through preset 3 to retrieve the configuration parameters for all of the
presets that are configured.
Note: Not all API resources provide Link headers.
265
URL Templates
We have provided a few additional endpoints that can be used to retrieve templates of the URLs used to access the
available resources. These templates are returned as a key-value pair to assist developers from having to hard code the
URLs into their application. These templates can be leveraged to produce robust code that will assist with future
compatibility if the URLs change in future versions of firmware. There are also many third-party JavaScript libraries out
there that allow you to easily replace parameters in a URL (or URI) template.
Example:
Request URL:
http://<ip_address>/api/
Response:
{
"last_transaction_url":"http://10.54.49.116/api/last_transaction/",
"totalizers_url":"http://10.54.49.116/api/totalizers/",
"ml_info_url":"http://10.54.49.116/api/mlinfo/",
"transactions_url":"http://10.54.49.116/api/transactions{/bolno}",
"wm_logs_url":"http://10.54.49.116/api/logs/wm{?page,per_page}",
"audit_logs_url":"http://10.54.49.116/api/logs/audit{?page,per_page}",
"equipment_url":"http://10.54.49.116/api/equipment/",
"dbschemas_url":"http://10.54.49.116/api/dbschemas{/table_name}{?show_columns}",
"message_logs_url":"http://10.54.49.116/api/logs/message{?page,per_page}",
"dbtables_url":"http://10.54.49.116/api/dbtables/{table_name}{/id}{?page,per_page}",
"resettable_totalizers_url":"http://10.54.49.116/api/resettable_totalizers/"
}
In this example, I have accessed the /api/ endpoint (which happens to be the API entry point) and it has
returned a JSON object containing all the available URLs as templates. All the parameters are indicated between
curly brackets “{}”.
Note: anywhere that you see {?page, per_page} means that it is possible to set limits on the amount of data that
is returned. To do this, use ?Limit=<number>&offset=<number>. This will allow you to fetch the data in chunks.
API Resources
3.6.1 REST Entry Point
3.6.1.1 /api/
This resource is used to fetch the available URLs that are available.
GET
Returns all available URLs as a JSON object.
266
3.6.2 Database
3.6.2.1 /api/dbschemas
This resource is used to manage the database schema. The following methods are supported.
GET
Returns the database schema as a JSON array.
3.6.2.2 /api/dbschemas/<table_name>
This resource is used to manage the database schema for a single table. The following operations are
supported.
GET
Returns the schema for the specified table as a JSON object.
3.6.2.3 /api/dbtables/<table_name>
This resource is used to manage the data of a specified table. The following methods are supported:
GET
Returns all rows as a JSON array. Each row is a single object with keys corresponding to column names.
POST
Creates a record or records in the database. A single record is created by a request with a body containing a
JSON object representing the record to be created. Multiple records can be created by a request with a body
containing a JSON array with one or more JSON objects representing the records to be created. On success the
newly created records are returned, including the rowid.
DELETE
267
Deletes all rows from the specified table.
3.6.2.4 /api/dbtables/<table_name>/<row_id>
This resource is used to manage the data of a specified row in a table. The following methods are supported:
GET
Returns the specified row as a JSON object.
PUT
Updates the specified row in the table. The response is the updated record.
DELETE
Deletes the specified row from the table.
3.6.3 Files
3.6.3.1 /api/files/<dir>
This resource is used to manage files on the SD card. The following methods are supported:
GET
Returns a directory listing as an array of JSON objects. Note this call only works on directories.
POST
Creates the specified directory.
DELETE
Deletes the specified file or directory.
268
3.6.4 Logs
3.6.4.1 /api/logs/message
This resource is used to fetch message logs.
GET
Returns the message log as an array of JSON objects, one per log entry.
3.6.5 /api/logs/wm
This resource is used to fetch weights & measures logs.
GET
Returns the weights & measures log as an array of JSON objects, one per log entry.
3.6.6 /api/logs/audit
This resources is used to fetch audit logs.
GET
Returns the audit log as an array of JSON objects, one per log entry.
3.6.7 Transactions
3.6.7.1 /api/transactions/
This resource is used to fetch the transactions. The following methods are supported.
GET
Returns the transactions as a JSON array.
269
3.6.7.2 /api/transactions/<bol number>
This resource is used to fetch a single transaction. The following operations are supported.
GET
Returns the transaction as a JSON object.
3.6.8 Last Transaction
3.6.8.1 /api/last_transaction/
This resource is used to fetch the last transaction. The following methods are supported.
GET
Returns the last transactions as a JSON array.
3.6.9 MultiLoad Information
3.6.9.1 /api/mlinfo/
This resource is used to fetch Multiload information like current_preset, is_card_inserted, current_component
etc. The following methods are supported.
GET
Returns the Multiload information as a JSON array.
3.6.10 Equipment Parameters
3.6.10.1 /api/equipment/
This resource is used to fetch the available URLS and URL templates for the equipment configuration
parameters. Use the URL templates to fetch all the equipment parameters. The following methods are
supported.
GET
270
Returns all available URLS as a JSON object.
3.6.11 Totalizers
3.6.11.1 /api/totalizers/
This resource is used to fetch the available URLS and URL templates for the totalizers. Use the URL templates to
fetch the data. The following methods are supported.
GET
Returns all available URLS as a JSON object.
Examples
3.7.1 Creating a database record
In this example we will create a new driver record. We presume that an appropriate database schema exists in
MultiLoad.
We send an HTTP request with the record to be created in the request body. Note the Content-Type is set to
application/json.
POST /api/dbtables/Driver HTTP/1.1
Content-Type: application/json
Authorization: Digest username="admin", realm="MultiLoad II", nonce="1487616767",
uri="/api/dbtables/Driver", qop=auth, nc=00000074, cnonce="dbecb622eb460223",
response="69445b1f7fac5cf3a87839613ba3ae88", opaque=""
{
"term_id": "TOPTEC1",
"driver_no": "00000001",
"pin_required": "Y",
"pin_code": "1111",
"exp_date": "2025-01-01",
"access_days": "YYYYYYY",
"def_supplier_no": "",
"def_cust_no": "",
"def_acct_no": ""
}
The response is the newly created record. Note that the rowid of the newly inserted row is included in the
response.
HTTP/1.1 201 Created
Date: Thu, 23 Mar 2017 16:57:45 GMT
Server: MultiLoad II
Content-Type: application/json
Content-Length: 225
271
{
"def_cust_no":"",
"driver_no":"00000001",
"pin_required":"Y",
"def_supplier_no":"",
"pin_code":"1111",
"term_id":"TOPTEC1",
"rowid":6,
"exp_date":"2025-01-01",
"def_acct_no":"",
"access_days":"YYYYYYY"
}
3.7.2 Fetching a database record
We sent an HTTP request with the rowid to be fetched in the URL.
GET /api/dbtables/Driver/6 HTTP/1.1
Authorization: Digest username="admin", realm="MultiLoad II", nonce="1487616767",
uri="/api/dbtables/Driver/6", qop=auth, nc=00000074, cnonce="dbecb622eb460223",
response="3017f7bf9589a70882d0a944ca33ed0c", opaque=""
The response contains the record as a JSON object.
HTTP/1.1 200 OK
Date: Thu, 23 Mar 2017 17:03:55 GMT
Server: MultiLoad II
Content-Type: application/json
Content-Length: 225
{
"def_cust_no":"",
"driver_no":"00000001",
"pin_required":"Y",
"def_supplier_no":"",
"pin_code":"1111",
"term_id":"TOPTEC1",
"rowid":6,
"exp_date":"2025-01-01",
"def_acct_no":"",
"access_days":"YYYYYYY"
}
3.7.3 Updating a database record
To update a record we make an HTTP PUT request. The rowid of the record to be updated is in the URL. In this
example we’re changing the pin_required and pin_code fields.
PUT /api/dbtables/Driver/6 HTTP/1.1
Authorization: Digest username="admin", realm="MultiLoad II", nonce="1487616767",
uri="/api/dbtables/Driver/6", qop=auth, nc=00000074, cnonce="dbecb622eb460223",
response="a0a8d7a3dbcdc2eacbac2955971170bd", opaque=""
{
"def_cust_no":"",
"driver_no":"00000001",
"pin_required":"N",
"def_supplier_no":"",
"pin_code":"",
"term_id":"TOPTEC1",
272
"rowid":6,
"exp_date":"2025-01-01",
"def_acct_no":"",
"access_days":"YYYYYYY"
}
The response from the server is the newly updated record.
HTTP/1.1 200 OK
Date: Thu, 23 Mar 2017 17:11:25 GMT
Server: MultiLoad II
Content-Type: application/json
Content-Length: 221
{
"def_cust_no":"",
"driver_no":"00000001",
"pin_required":"N",
"def_supplier_no":"",
"pin_code":"",
"term_id":"TOPTEC1",
"rowid":6,
"exp_date":"2025-01-01",
"def_acct_no":"",
"access_days":"YYYYYYY"
}
3.7.4 Deleting a database record
To delete a record we make an HTTP DELETE request. The rowid of the record to be updated is in the URL.
DELETE /api/dbtables/Driver/6 HTTP/1.1
Host: 10.54.49.30
Authorization: Digest username="admin", realm="MultiLoad II", nonce="1487616767",
uri="/api/dbtables/Driver/6", qop=auth, nc=00000074, cnonce="dbecb622eb460223",
response="7330e3245c4b21ca893a4c6a5effeb73", opaque=""
We get back a zero-length response with a success HTTP status code.
HTTP/1.1 204 No Content
Date: Thu, 23 Mar 2017 17:18:49 GMT
Server: MultiLoad II
Content-Type: application/json
Content-Length: 0
Additional Resources
3.8.1 Postman
Postman is a utility for making HTTP requests. You can save requests, generate collections of requests and even
automate a series of requests.
https://www.getpostman.com/
3.8.2 Learn REST: A RESTful Tutorial
http://www.restapitutorial.com/
273
274
Chapter 4 Code Samples
This chapter provides example code for implementing a traditional standalone MultiLoad application. In this
application there is only one database table used for containing driver information. The authorization prompting
only prompts for a driver and pin number, and the authorize batch prompting displays a picklist of products
from the authorized preset products already configured in the MultiLoad.
License
All code in this manual is provided under the MIT License, as follows:
Copyright (c) 2016-2017 Toptech Systems
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
sql_init.sql
-- ============================================================================
-- SQLite Initialization Script (LUA)
-- ============================================================================
CREATE TABLE Driver(
id INTEGER PRIMARY KEY AUTOINCREMENT,
driver_no char( 8) NOT NULL,
name char(50) ,
pin_req char( 1) , -- Y/N/F
pin_code char( 4) , -- PPPP
access_from char( 8) , -- HH:MM:SS
access_to char( 8) , -- HH:MM:SS
access_days char( 7) , -- YYYYYYY
Chapter
4
275
locked char( 1) , -- Y/N
lockout_reason char(40) ,
UNIQUE (driver_no) );
-- ====================================================================================================
-- Start Loading Data in (Driver) Table
-- ====================================================================================================
INSERT INTO `Driver` (
id,
driver_no,
name,
pin_req,
pin_code,
access_from,
access_to,
access_days,
locked,
lockout_reason
) VALUES (
NULL, -- Since set to autoincrement, this number will be assigned automagically by SQLite
'00001111',
'John Doe ',
'Y',
'1111',
'00:00:00',
'23:59:59',
'YYYYYYY',
'N',
' '
);
Example Code 4.1 sql_init.sql
276
authorize_transaction.lua
-- ============================================================================
-- Authorize Transaction Script (LUA)
-- ============================================================================
--
-- This script authorizes a driver and allows them to "offload" their product.
--
-- ============================================================================
-- Add informational message for possible debugging assistance.
TraceMessage("Start of authorize_transaction.lua script.")
LogMsg(LOG_LEVEL_INFORMATIONAL, "Start of authorize_transaction.lua script.")
-- The line below includes the SQLite package and everything after the equal sign
-- MUST be used exactly the same way as below.
sqlite3 = require('sqlite3')
-- Opens the database file and load it into memory
db = sqlite3.open('file:/auto/mmc_1/SQL/MULTILOAD.B?cache=shared')
-- ============================================================================
-- real start of application script
-- ============================================================================
-- load trim function
function trim (s) return (string.gsub(s, "^%s*(.-)%s*$", "%1")) end
function db_prepare (s)
local stmt
-- log sql message
LogMsg(LOG_LEVEL_INFORMATIONAL,s)
stmt = db:prepare(s)
-- check sql error
if(stmt == nil) then
LogMsg(LOG_LEVEL_INFORMATIONAL,"SQL Err: " .. db:error_message())
end
return stmt
end
-- clear values otherwise values from previous driver still exists
-- TODO: this is no longer needed since LUA instance restarted each time
driver = nil
-- Get current Date and Time
current_date = GetDate("%Y-%m-%d")
current_time = GetDate("%H:%M:%S")
current_date_time = GetDate("%Y-%m-%d %H:%M:%S")
current_os_date_time = os.time({year=GetDate("%Y"), month=GetDate("%m"), day=GetDate("%d"),
hour=GetDate("%H"), min=GetDate("%M"), sec=GetDate("%S")})
LogMsg(LOG_LEVEL_DEBUG, "OS Time: ".. current_os_date_time)
-- ============================================================================
-- Prompt while loop for state machine
-- ============================================================================
prompt = 1
while 1 do
-- ::HandlePrevKeyAtTop::
if prompt == 0 then
Exit()
277
-- ---------------------------------
-- ::PromptDriver Number::
-- ---------------------------------
elseif prompt == 1 then
entry = Prompt(6, "Enter Driver Number: ") -- Blocks until a terminating key is pressed
if not TermKeyPrev() then
if entry == nil then
-- Something was not entered incorrectly for Driver Number?
MessageDenied("Invalid Driver Number")
Exit()
elseif tonumber(entry) == nil then
-- 10 20 30 40
-- 1234567890123456789012345678901234567890
Outstrc(2, "Invalid Driver Number, Must Enter A Number")
Outstrp(0, 4, "Driver No:")
Outstrp(11, 4, string.format("%s", entry))
Outstrc(13, "To re-enter a VALID Driver Number")
OutstrcBottom("Press ENTER to Continue") -- OutstrcBottom - will make the line turn RED
SetupWait()
GetEntry()
prompt = prompt - 1 -- decrement the "prompt" count ( go back to ::PromptDriver:: )
else
driverNumber = string.format("%08u", tonumber(entry))
stmt = db_prepare("SELECT * FROM Driver WHERE driver_no = '" .. driverNumber .. "';")
if(stmt:step() == sqlite3.ROW) then
driver = stmt:get_named_values()
else
driver = nil
end
stmt:finalize()
end -- if entry == nil then
end -- end if not TermKeyPrev()
if TermKeyPrev() then
prompt = prompt - 1 -- go to previous prompt
else
prompt = prompt + 1 -- go to next prompt
end
-- ---------------------------------
-- ::ValidateDriver Number::
-- ---------------------------------
elseif prompt == 2 then
ClearScreen()
if driver == nil then
MessageDenied("Invalid Driver Number") -- Blocks until a terminating key is pressed (ENTER, NEXT,
or PREV)
Exit()
else
-- ------------------------------------
-- Verify the driver is NOT locked out
-- ------------------------------------
if driver.locked == "Y" then
LogMsg(LOG_LEVEL_ERROR, "Driver " .. driver.name .. " is locked.")
Outstrc(0, "Toptech Terminal")
-- 10 20 30 40
-- 1234567890123456789012345678901234567890
Outstrc(2, string.format("%s", driver.name))
Outstrc(5, "YOU HAVE BEEN LOCKED OUT")
-- 1234567890123456789012345678901234567890
Outstrc(7, "Reason:")
if string.len(trim(driver.lockout_reason)) > 0 then
Outstrc(9, trim (driver.lockout_reason))
else
278
Outstrc(9, "No Explanation on File")
end
-- 10 20 30 40
-- 1234567890123456789012345678901234567890
Outstrc(14, "Contact Fred Durst For Assistance")
OutstrcBottom("Exit Enter Next Prev") -- OutstrcBottom - will make the line turn RED
SetupWait() -- Blocks until a terminating key is pressed (ENTER, NEXT, or PREV)
Exit()
end
-- -----------------------------------------------------------------------------
-- Validate the Driver can load on this day (Su, Mo, Tu, We, Th, Fr, Sa)
-- -----------------------------------------------------------------------------
-- The GetDate ("%w") returns the day of the week [0-6]. Need to add 1 to the value.
cur_day_of_week = tonumber(GetDate("%w")) + 1
-- The string.sub (s, "start", "end")returns the sub-string from "start" - "end".
-- The string.sub ("SMTWTFS", "5", "5") Returns T(hursday) (5).
if string.sub (driver.access_days, cur_day_of_week, cur_day_of_week) ~= "Y" then
Outstrc(0, "Toptech Terminal")
-- 10 20 30 40
-- 1234567890123456789012345678901234567890
Outstrc(2, string.format("%s", driver.name))
-- 10 20 30 40
-- 1234567890123456789012345678901234567890
Outstrc(5, "You Do NOT have Access TODAY!")
Outstrc(7, "You ONLY have access on:")
Outstrp(10, 9, "Su Mo Tu We Th Fr Sa")
Outstrp(10, 10, string.sub (driver.access_days, 1, 1))
Outstrp(13, 10, string.sub (driver.access_days, 2, 2))
Outstrp(16, 10, string.sub (driver.access_days, 3, 3))
Outstrp(19, 10, string.sub (driver.access_days, 4, 4))
Outstrp(22, 10, string.sub (driver.access_days, 5, 5))
Outstrp(25, 10, string.sub (driver.access_days, 6, 6))
Outstrp(28, 10, string.sub (driver.access_days, 7, 7))
Outstrc(14, "Contact Fred Durst For Assistance")
OutstrcBottom("Exit Enter Next Prev") -- OutstrcBottom - will make the line turn RED
SetupWait() -- Blocks until a terminating key is pressed (ENTER, NEXT, or PREV)
Exit()
end
-- -------------------------------------------------
-- Validate the drive can load at this time
-- -------------------------------------------------
access_from = os.time(
{year=GetDate("%Y"),
month=GetDate("%m"),
day=GetDate("%d"),
hour=string.sub(driver.access_from, 1, 2),
min=string.sub(driver.access_from, 4, 5),
sec=string.sub(driver.access_from, 7, 8)})
access_to = os.time(
{year=GetDate("%Y"),
month=GetDate("%m"),
day=GetDate("%d"),
hour=string.sub(driver.access_to , 1, 2),
min=string.sub(driver.access_to , 4, 5),
sec=string.sub(driver.access_to , 7, 8)})
--os.difftime (t2, t1)
--Returns the difference, in secs, from time t1 to time t2 (where the times are values returned by
--os.time). In POSIX, Windows, and some other systems, this value is exactly t2-t1
from_diff_time = os.difftime(current_os_date_time, access_from)
to_diff_time = os.difftime(access_to, current_os_date_time)
if (from_diff_time < 0 or to_diff_time < 0) then
279
LogMsg(LOG_LEVEL_DEBUG, "Driver Access From OS Tim: ".. access_from)
LogMsg(LOG_LEVEL_DEBUG, "Driver From Diff: ".. from_diff_time)
LogMsg(LOG_LEVEL_DEBUG, "Driver Access To OS Tim: ".. access_to)
LogMsg(LOG_LEVEL_DEBUG, "Driver To Diff: ".. to_diff_time)
Outstrc(0, "Toptech Terminal")
-- 10 20 30 40
-- 1234567890123456789012345678901234567890
Outstrc(2, string.format("%s", driver.name))
-- 10 20 30 40
-- 1234567890123456789012345678901234567890
Outstrc(5, "You DO NOT have Access at this TIME")
Outstrc(7, "Current Time: " .. current_time)
Outstrp(10, 9, "From:")
Outstrp(26, 9, "To:")
Outstrp(8, 10, driver.access_from)
Outstrp(23, 10, driver.access_to)
OutstrcBottom("Exit Enter Next Prev") -- OutstrcBottom - will make the line turn RED
SetupWait() -- Blocks until a terminating key is pressed (ENTER, NEXT, or PREV)
Exit()
end
LogMsg(LOG_LEVEL_INFORMATIONAL, "Driver " .. driver.driver_no .. " attempting to card in.")
end -- if driver == nil
if TermKeyPrev() then
prompt = prompt - 1 -- go to previous prompt
else
prompt = prompt + 1 -- go to next prompt
end
-- ---------------------------------
-- ::DriverPIN::
-- ---------------------------------
elseif prompt == 3 then
-- Prompt will clear the screen, and wait for a terminating key to be pressed (ENTER, NEXT, or PREV)
entry = Prompt(4, "Enter Driver Pin: ")
if not TermKeyPrev() then
ClearScreen()
if entry == nil or tonumber(entry) == nil then
MessageDenied("Invalid Pin Number")
Exit()
else
driverPin = string.format("%04u", tonumber(entry))
stmt = db_prepare(
"SELECT * FROM Driver
WHERE driver_no = '" .. driver.driver_no .. "'
AND pin_code = '" .. driverPin .. "';") - whole statement should be on one line
if(stmt:step() == sqlite3.ROW) then
pin = stmt:get_named_values()
else
pin = nil
end
stmt:finalize()
if pin == nil then
MessageDenied("Invalid Pin Number")
Exit()
else
LogMsg(LOG_LEVEL_INFORMATIONAL, "Driver " .. driver.driver_no .. " is authorized to load.")
end -- if pin == nil then
end -- if entry == nil then
end -- end if not termKeyPrev
if TermKeyPrev() then
280
prompt = prompt - 1 -- go to previous prompt
else
break -- break out of prompting sequence and authorize transaction
end
end -- if prompt == 0
end -- while 1 do (end state machine while loop)
--archive important variables into Startup Chunk stored in NVRAM
SaveInit()
SaveVariable(driver, "driver")
-- Enable all presets
for preset_id = 1,ml.equipment.bay.number_of_presets do
-- Equivalent to MEM command, but preset(1..12)
-- 0 = disable
-- 1 = not auth
-- 2 = auth
EnablePreset(preset_id, 2)
LogMsg(LOG_LEVEL_INFORMATIONAL, "Preset " .. preset_id .. " Enabled.")
end
-- Authorize the transaction for this driver.
-- Equivalent to T`A command
AuthorizeTransaction(driver.driver_no)
TraceMessage("End of authorize_transaction.lua script.")
LogMsg(LOG_LEVEL_INFORMATIONAL, "End of authorize_transaction.lua script.")
Example Code 4.2 authorize_transaction.lua
281
authorize_batch.lua
-- ============================================================================
-- Authorize Batch Script (LUA)
-- ============================================================================
-- Add informational message for possible debugging assistance.
TraceMessage("Start of authorize_batch.lua script.")
LogMsg(LOG_LEVEL_INFORMATIONAL, "Start of authorize_batch.lua script.")
sqlite3 = require('sqlite3')
-- open database
db = sqlite3.open('file:/auto/mmc_1/SQL/MULTILOAD.B?cache=shared')
-- get currently selected preset number
preset = ml.info.current_preset
selected_product_idx = 0
-- prompt while loop for state machine
prompt = 1
while 1 do
-- ----------------------------------------
-- ::HandlePrevKeyAtTop::
-- ----------------------------------------
if prompt == 0 then
Exit()
-- ---------------------------------
-- ::PromptSelectRecipe::
-- ---------------------------------
elseif prompt == 1 then
-- --------------------------------------------------
-- Create a picklist of Recipes For Preset
-- --------------------------------------------------
picklist_index = 0
picklist_text = {}
picklist_return = {}
-- build and display picklist
for auth_idx = 1, MAX_RECIPES, 1 do
product_idx = ml.config.preset[preset].authorized_products[auth_idx]
if(product_idx ~= 0) then
picklist_index = picklist_index + 1
picklist_text[picklist_index] = ml.config.products[product_idx].long_desc
picklist_return[picklist_index] = product_idx
end
end
-- If atleast one item in the picklist
if picklist_index > 0 then
-- display picklist, and block until a terminating key has been pressed
entry = Picklist(40, picklist_text, picklist_return, 0, "Select the Product:")
if not TermKeyPrev() then
selected_product_idx = entry
end -- end if termKeyPrev
else
Exit()
end -- if picklist_index > 0
if TermKeyPrev() then
prompt = prompt - 1 -- go to previous prompt
else
prompt = prompt + 1 -- go to next prompt
end
282
-- -------------------------------------------------------------------------------------
-- ::PromptVolume::
-- -------------------------------------------------------------------------------------
elseif prompt == 2 then
ClearScreen()
-- /***********************************************************/
-- /* 0123456789012345678901234567890123456789 */
-- /* 00" PRESET 02 SCREEN " */
-- /* 01" " */
-- /* 02"PRODUCT: XXXXXXXXXXXXXXXXXXXXXXXXX " */
-- /* 03"PRESET QUANTITY: XXXXXXX " */
-- /* 04 " */
-- /* 05" " */
-- /* 06" " */
-- /* 07" " */
-- /* 08" " */
-- /* 09" " */
-- /* 10" " */
-- /* 11" " */
-- /* 12" " */
-- /* 13" " */
-- /* 14"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" */
-- /* 15" Next Prev Exit Enter " */
Outstrc(0, "PRESET " .. preset .. " SCREEN")
Outstrp(0, 2, "PRODUCT: " .. ml.config.products[selected_product_idx].long_desc)
Outstrp(0, 3, "PRESET QUANTITY: ")
OutstrcBottom("Next Prev Exit Enter")
term_key,entry = GetInput({row=3, col=17, length=7})
if(term_key == "ENTER") then
if(entry ~= nil and tonumber(entry) ~= nil) then
preset_volume = math.floor(entry)
min = ml.equipment.preset[preset].min_preset
max = ml.equipment.preset[preset].max_preset
if(preset_volume < min or preset_volume > max) then
OutstrcBottom("Invalid Preset: Min(".. min .. ") Max(" .. max .. ")")
GetInput()
else
break -- Break out of loop if valid preset volume
end
else
OutstrcBottom("Invalid Entry")
GetInput()
end
elseif (term_key == "PREV") then
prompt = prompt - 1 -- go to previous prompt
end
end
end -- end state machine while loop
if(selected_product_idx ~= 0) then
-- -------------------------------------------------------------------------------------
-- ::Authorize Batch::
-- -------------------------------------------------------------------------------------
-- authorize preset MAMpppaxxxxxxxx
-- where MAM = Authorize Preset
-- ppp= preset number (1-12)
-- a = 0-cancel 1-authorize
283
-- iii = product index
-- vvvvvvvvv = Preset Volume
-- cc = compartment #
AuthorizePreset(preset, 1, selected_product_idx, preset_volume, "1")
end
TraceMessage("End of authorize_batch.lua script.")
LogMsg(LOG_LEVEL_INFORMATIONAL, "End of authorize_batch.lua script.")
Example Code 4.3 authorize_batch.lua
284
process_transaction.lua
LogMsg(LOG_LEVEL_INFORMATIONAL, 'Start of process_transaction.lua file.')
sqlite3 = require('sqlite3')
db = sqlite3.open('file:/auto/mmc_1/SQL/MULTILOAD.B?cache=shared')
--db:exec("INSERT INTO Transactions VALUES ('" .. driver.name .. "');")
--stmt = db:prepare("SELECT * FROM Transactions;")
--while(stmt:step() == sqlite3.ROW) do
-- trans = stmt:get_named_values()
-- LogMsg(LOG_LEVEL_DEBUG, "Transactions: " .. trans.name)
--end
--stmt:finalize()
db:close()
LogMsg(LOG_LEVEL_INFORMATIONAL, 'End of process_transaction.lua file.')
Example Code 4.4 process_transaction.lua
285
build_bol.lua
-- load trim function
function trim (s) return (string.gsub(s, "^%s*(.-)%s*$", "%1")) end
header_start_lin = GetCursorLin(0)
WriteStringCenteredAbs( 0, 40, 50, "BILL OF LADING")
WriteStringCenteredRel(2, 40, 50, trim(driver.name))
WriteStringRel(2, 26, 12, "BOL: ")
WriteStringRel(0, 43, 4, trim(ml.transactions.header.bolno))
WriteStringRel( 2, 26, 12, "LOAD START: ")
WriteDateRel( 0, 38, ml.transactions.header.load_start)
WriteTimeRel(0, 48, ml.transactions.header.load_start)
WriteStringRel(1, 26, 12, "LOAD STOP: ")
WriteDateRel(0, 38, ml.transactions.header.load_stop)
WriteTimeRel(0, 48, ml.transactions.header.load_stop)
-- adjust cursor to new line
MoveCursorRel(1, 0)
WriteStringRel(
1,
0,
80,
"PRE CODE TEMP PRES DENSITY GOV GSV ALARM")
WriteStringRel(
1,
0,
80,
" (kPa) (Kg/cu.M) ")
WriteStringRel(
1,
0,
80,
"-------------------------------------------------------------------------------")
header_end_lin = GetCursorLin(0)
-- loop through all details
nbr_dtl = ml.transactions.header.nbr_dtl
for detail_index = 1, nbr_dtl do
-- get detail record
detail = ml.transactions.details[detail_index]
-- adjust cursor to new line
MoveCursorRel(1, 0)
-- only print saleable
if (detail.type == 1) then
-- print preset number
WriteStringRel( 0, 0, 2, string.format("%-2d", detail.preset))
-- print product code
WriteStringRel( 0, 4, 6, string.format("%-6s", detail.prod_code))
-- print temperature
WriteStringRel( 0, 11, 8, string.format("%-+6.2f", detail.temp_hund / 100.0) )
286
-- print pressure
WriteStringRel( 0, 20, 8, string.format("%-+6.2f", detail.pressure_hund / 100.0) )
-- print density or gravity
WriteStringRel( 0, 29, 8, string.format("%-8d", detail.densitygravity))
-- print gov
WriteStringRel( 0, 38, 10, string.format("%-8.0f", detail.gov_del))
-- print gsv volume
WriteStringRel( 0, 49, 10, string.format("%-8.0f", detail.gsv_del))
-- print alarm
if detail.alarm ~= 0 then
WriteStringRel( 0, 60, 5, "Alarm")
end -- end if alarm
end -- end if saleable
end -- end for detail_index loop
WriteStringRel(
1,
0,
80,
"-------------------------------------------------------------------------------")
footer_start_lin = GetCursorLin(0) + 2
WriteStringRel(
2,
0,
80,
"This is to certify that the listed materials are properly classified and are in")
WriteStringRel(
1,
0,
80,
"proper condition for transportation according to regulations of the Dept. of ")
WriteStringRel(
1,
0,
80,
"Transportation & Interstate Commerce Commission and the carrier certifies the ")
WriteStringRel(
1,
0,
80,
"proper cargo container used. ")
col_start_lin = GetCursorLin()
WriteStringRel( 2, 0, 39, "LOADED BY:")
WriteStringRel( 3, 0, 39, "_______________________________________")
WriteStringRel( 1, 0, 10, "Driver: "); WriteString(8, driver.driver_no)
WriteStringRel( 1, 0, 39, trim(driver.name))
left_col_lin = GetCursorLin(0)
MoveCursorAbs(col_start_lin, 0)
287
WriteStringRel( 2, 41, 39, "RECEIVED BY:")
WriteStringRel( 3, 41, 39, "_______________________________________")
WriteStringRel( 1, 41, 39, "I certify that the quantity was ")
WriteStringRel( 1, 41, 39, "received as indicated above, ")
WriteStringRel( 1, 41, 39, "except as noted. ")
Example Code 4.5 build_bol.lua
288
background.lua
-- ============================================================================
-- background.lua
--
-- This script runs in the background and is responsible for periodically
-- checking if there are unprocessed transactions needed to be inserted into
-- the TransactionHeader table.
-- ============================================================================
-- Add informational message for possible debugging assistance.
LogMsg(LOG_LEVEL_INFORMATIONAL, "Start of background.lua script.")
-- Requires
local sqlite3 = require("sqlite3")
while true do
local err = false
if ml.info.rcu_status ~= 'IDLE' then
goto sleep
end
-- Loop through all transactions stored in flash memory
for index=1, #ml.transactions.archives do
local db, e = sqlite3.open('file:/auto/mmc_1/SQL/MULTILOAD.B?cache=shared')
local stmt_header =
db:prepare(
[[INSERT INTO TransactionHeader
( driver_id, bol_no, load_start, load_stop, gov, gsv, temp, product_code )
VALUES
( :driver_id, :bol_no, :load_start, :load_stop, :gov, :gsv, :temp, :prod_code );
]]
)
local stmt_driver =
db:prepare("SELECT id FROM Driver WHERE driver_number = ?")
local transaction = ml.transactions.archives[index]
if transaction then
if not transaction.processed then
db:exec("BEGIN TRANSACTION;")
local header = {}
local driver_id = nil
-- Insert card_id into SQL statement
stmt_driver:bind(1, transaction.header.card_id)
-- Execute SQL statement to retrive the id from the Driver table
if stmt_driver:step() == sqlite3.ROW then
driver_id = stmt_driver:get_value(0)
else
LogMsg(
LOG_LEVEL_ERROR,
"Database error retrieving driver_id from Driver: " ..
db:errmsg())
driver_id = 0
end
header.driver_id = driver_id
header.bol_no = transaction.header.bolno
-- Format the date from epoch time to a string (YYYY-MM-DD HH:MM:SS)
header.load_start =
289
os.date("%Y-%m-%d %H:%M:%S", transaction.header.load_start)
header.load_stop =
os.date("%Y-%m-%d %H:%M:%S", transaction.header.load_stop)
for index,detail in ipairs(transaction.details) do
-- All details are assigned a type which indicates
-- how to interpret the data. Detail Type == 1
-- is called a SALEABLE type, which means it will
-- contain the total volume that passed through
-- the preset. A detail type == 2, is called a
-- COMPONENT type which only contains the volumetric
-- data for a particular component.
-- Please reference section 2.6.9.2 in the Slate reference guide.
if detail.type == 1 then -- If SALEABLE type
header.prod_code = detail.prod_code
-- Temp stored with an implicit 2 decimal
header.temp = detail.temp_hund / 100
-- if hundredths is configured, convert to decimal
if ml.equipment.rcu.use_hunds == 1 then
header.gov = detail.gov_del / 100
header.gsv = detail.gsv_del / 100
else
header.gov = detail.gov_del
header.gsv = detail.gsv_del
end
end
end
-- Insert variables into prepared SQL statement
if stmt_header:bind_names(header) ~= sqlite3.OK then
LogMsg(
LOG_LEVEL_ERROR,
"Database error creating prepared statement: " .. db:errmsg())
goto next_transaction
end
-- Execute SQL statement
if stmt_header:step() ~= sqlite3.DONE then
LogMsg(
LOG_LEVEL_ERROR,
"Database error inserting TransactionHeader: " .. db:errmsg())
goto next_transaction
end
ml.transactions.archives[index].processed = true
db:exec("COMMIT TRANSACTION;")
goto next_transaction
end
end
:: next_transaction ::
stmt_header:finalize()
stmt_driver:finalize()
db:close()
Sleep(1)
end
LogMsg(LOG_LEVEL_INFORMATIONAL, "End of process_transaction.lua script.")
::sleep::
if db and db:isopen() then
db:close()
end
290
Sleep(30) -- Sleep for 30 seconds
end
-- Shouldn't reach this point (unless all coroutines die)
LogMsg(LOG_LEVEL_INFORMATIONAL, "End of background.lua script.")
Example Code 4.6 background.lua
291
Chapter 5 Firmware Revision History
Firmware version: 4.32.04
- Lua: Added support for accessing transaction archive.
- REST API: Added support for fetching transactions.
- Change internal structure of transactions to use POSIX timestamps. This will result in transaction
archive being wiped on upgrade.
- REST API: Add root endpoints to REST API (e.g "/api/", "/api/equipment").
- REST API: Add support for "equipment" tables to REST API.
- Lua: Added support for FCM address types to ml.equipment Lua table.
- REST API: Add support for FCM address types to REST API.
- REST API: Add support for reading/writing FCM Mapping Type to REST API.
- Increase max connections allowed in web server.
- Added support for generating a FCM mapping report in the webpage.
- REST API: Added support for downloading the equipment registers via the REST API.
- Increase max number of sockets to prevent "502 Bad Gateway" and other network errors
- Enhancements to RCU ditto:
- Only send update if screen has changed to reduce bandwidth
- Only send diffs of changes to reduce bandwidth
- Lower case characters will be translated to upper case
- Fix: BSOD on file upload when file can't be opened
- Lua: Added the "processed" field to the transaction table
- REST API: Add support for generating Link Header for equipment resources (presets, meters,
components, etc.)
Firmware version: 4.32.05
- Fix: Exiting of batch_authorization lua script by pressing the Exit key. If attempting to re-enter the
script after exiting via the exit key, the term_key variable was not being reset so it would stop the
execution of the script immediately after starting it.
- Lua: Added new function, Outstrap({col, row, foreground, background, inverse}, string)
- Fix: Standalone processing mode bug that prevented drivers from loading.
- Added the ability to create transactions when volume delivered is less than .5 gallons.
- Remove excessive tracing of when a host opens/closes a network connection.
- Capture custom logic configuration changes in audit log.
Chapter
5
292
- Return hundredths for gross/net/mass (Custom Logic and Modbus) if RCU -> Use Hundredths
parameter is enabled.
- Change how often we search directories for old files to delete from every 24 hours to every 12 hours.
- Fix: Alibilog and PTB print lines could be kept high after going to Views & Inquiries -> Print All Param
or Views & Inquiries -> Print W&M param
- Fix: display bug in the transaction report summary screen when the language was configured for
anything other than English.
- Added: Sampler Feedback Type parameter. This will allow the users to setup a feedback signal that
can be used to verify that a sample was actually taken.
- Updated NR2, and NR4 to database versions 3.32.05.
- Remove the restriction of only being allowed to run automated reports while in idle.
- Added the ability to scroll through presets, meters, additives, etc. using the right and left arrow keys
while in the equipment setup pages.
- Enhancement: Added a stabilization timer for the fallback flow rate functionality. If the flow rate falls
below the target, the fallback timer is started. The MultiLoad will sample the flow rate periodically,
and if the flow rate comes back up to the target (greater than or equal to target minus deadband),
the MultiLoad will only reset the fallback timer after the flow rate has stabilized at the target flow
rate for more than 2 seconds. Previously, this timer would be reset immediately when the rate came
into the target.
- Added the Fallback Start Volume parameter which allows a user delay the fallback functionality until
X number of gallons have been delivered.
- Fix Lua: Referencing of ml.transactions.header and ml.transactions.details tables.
Firmware version: 4.34.00
- Fix: NTP server functionality.
- Fix: Printing of totalizers that are more than 10 digits in the transactions report (when using
hundredths).
- Fix: BSOD caused by manually modifying or creating SQL records via the screen.
- Fix: Bug that prevented users from selecting records that aren’t on page one.
- Fix: FCM mapping report that was incorrectly showing solenoid outputs on ports 2 and 3 when flow
control valve type was set to NONE.
- Fix: Third bay permissive alarm that was not displayed in the Alarms Setup screen and wasn’t
configurable in MultiMate Plus.
- Added the ability to reference the last keypress (A-Z, NEXT, PREV, etc) in Custom Logic.
- Fix: Over additive injection alarm logic. The firmware was comparing against the under additive
alarm injection parameter.
- Removed all PCM functionality.
- Added RCU Level -> Max Unprinted Alibi Log Events parameter that allows the user to delay the
*PRINTER ERROR alarm from being thrown.
- Modified the PTB (alibi log) *PRINTER ERROR alarm logic to not alarm during a transaction.
- Added support for 3-digit facility codes for 26-bit and 37-bit prox cards (R962 command).
- Created a new Access ID register (R601 & U601) that comma separates the data.
- Created a new read transaction register (R801) that comma separates the data.
- API 21.2 Changes:
- Renamed gross and net to GOV and GSV (all internal variables and screen outputs).
293
- Added IV and NSV calculations.
- Modified the Preset Status screen to display new values.
- Modified the Component Status screen to display IV, MF (Meter Factor), and K-Factor.
- Added IV, NSV, K-Factor, and Weighted MF to the transaction records.
- Added IV totalizers (R126 register) and NSV totalizers (R127 register).
- Modified the layout and the data captured in the reports (transaction, line, sample pot,
and batch).
- Added new RCU Level -> Save Totalizers to Transaction parameter which allows the user
to save opening and closing totalizers to the transaction without printing them on the
BOL (Default Value: PM).
- Added Meter Name parameters that can be configured from the Product Setup screens.
- Added IV option to the Preset Level -> Deliver Type parameter.
- Added Output Pulse Type parameter at the meter level
- Added RCU level -> Capture Grindout Data parameter that allows users to fill out a form to
capture grindout data when ending a sampler batch.
- Changed the meter report to a line report.
- Excluded all reports (except for the transaction report) from MultiLoad and SMP firmware.
- Fix: Pulse output bug in custom logic. The pulse output function would remain high even when
after the timer expired. This would occur if the pulse was triggered and the unit was power
cycled.
- Added serial flash hardware check to the firmware upgrade process to prevent users from
downgrading firmware on a CPU board that cannot support older firmware (see service bulletin
SB0009 -v4-20190110_2106).
- Fix: Transaction report layout bug. The report was printing the corrected gravity in the wrong
column.
- Increased NVRAM block 1 version to 4.34.00 which will erase the usernames and passwords
defined at the RCU General Setup level. After a firmware upgrade, users will have to manually
reconfigure their user accounts.
- Created a new shortcut workflow (SCS ONLY) for generating reports from the idle screen (‘4446 +
NEXT’).
- Added new SCS Level -> Default Day Trigger parameter.
- Added new SCS Level -> Default Time Trigger parameter.
- Added the ability to reference the new Default Day and Time Trigger parameters from
the automated reports trigger parameters.
- Modified the line flush behavior when ratio blending. The firmware will no longer come to a
complete stop if it does not have to. The firmware will simply bump out the target volume by the
flush amount and continue loading.
- Fix: Line flush logic when loading in mass. The firmware would not add the mass line flush
quantity to the transaction or the mass totalizers.
- Fix: Pressing the NEXT or PREV key in the End Sampler Batch screen caused the screen to lock up.
- Fix: Resolved an issue with mismatch totalizers at the preset, meter and component levels when
flow continues after a batch is cleared.
- Lua: Modified the garbage collection settings to be more aggressive which improves
performance and stops potential BSODs.
294
- SQLite: Fixed BSODs caused by accessing an in-memory database from multiple threads. A BSOD
was being triggered when a database backup was occurring. The architecture has been changed
to open the database connection directly to the MULTILOAD.B file.
- Performance will be impacted because SQLite will now correctly lock/unlock tables when
multiple processes are trying to access a table at the same time. Testing has shown that
performance speeds will be acceptable for most applications. However, Users will have
to follow best practices (wrap multiple operations with BEGIN TRANSACTION; ...
COMMIT TRANSACTION; statements as well as limit the number of operations being
performed in a loop) when creating their applications.
- Added ml.equipment.scs table, IV and NSV totalizers to Lua and the REST API.
- Excluded batch and line reports data from Lua and REST API for non SCS builds.
- Changed the WriteDateRel, WriteTimeRel, WriteDateAbs and WriteTimeAbs functions to use an
epoch time instead of text to format the date and time.
Firmware version: 4.34.01
- Modified the Alarm Setup -> "Send E-Mail Notification" paramater to be Alarm Setup -> "E-Mail
Trigger Count".
- Increased the size of NVRAM_BLOCK_2. After an upgrade, the users will lose all their transactions.
- Added the ability to delay the sending of an email when an alarm is raised. The user can now
configure an "E-Mail Trigger Count" parameter that will wait until the alarm has been raised X
number of times before sending an email notifying the user of the alarm. Once the email is sent the
counter will be reset. Note: The counter is a separate counter from the alarm "Promotion Count"
functionality.
- Fix: Bug in the SCS shortcut reports menu didn't display the most recent 'previous' month in the
picklist.
- Added product code to line, sampler batch and sampler reports (API 21.2 requirement).
- Added iv_del, nsv_del, weighted_meter_factor, and meter_pulses_per_vol to all transaction_detail
lua tables.
- Expose API Calculation Function in Lua by adding CalculateGsv(...) routine to calculate a GSV from
GOV, temp and API Table. The routine accepts the following inputs: gov, temp, api_table, and an
option table with optional input variables. It returns gsv, ctl, cpl, and corrected density.
- Pressing the +/- key when entering text inputs, the '-' (dash) character. For example. in the Preset
Product Setup screen, the 'Name' can be 'Preset-001' instead of 'Preset 001'.
- Fix: Set all the meter factor cal points to 1.0000 if they haven't been initialized.
- Fix: Removed the gravity flag from API Table 2004_6C because it has no affect on the calculation.
- Fix: A sql_init.sql file that took longer than a few seconds to execute could cause the MTL to reboot
itself before finishing the entire script.