Exacqvision Serial Integration User's Guide
Exacqvision Serial Integration User's Guide
1 Purpose
The purpose of this document is to provide guidance for configuring and understanding the exacqVision serial
interface. This guide provides step-by-step instructions and also explains more complex topics in-depth.
2 Overview
Serial data refers to unencrypted, clear text, or ASCII characters received by exacqVision. It is referred to as serial
data because it is sent as a series of characters over a UART (RS-232 or RS-485) interface or in a TCP/IP packet over
Ethernet.
exacqVision processes serial data in many ways. For example, the data can simply be stored as human-readable
text and overlaid on live views; or it can be used to trigger actions such as calling a PTZ preset on a camera,
recording video, triggering an alarm output, changing a view, sending an email, and more.
4 USB-to-RS-232 Adapter
A USB-to-RS-232 can be used if an RS-232 port is not available on the exacqVision system. Most adapters require
the installation of device drivers per the manufacturer’s instructions. After driver installation, verify the COM port
has been detected by the Windows operating system, as described in the following section.
Serial Integration User’s Guide
2 3 4 5 6 7 8 9 10 11 12 13 14
1 15
1. Click on Serial Ports in the navigation tree of the exacqVision Client software.
2. Enter a unique name, if desired.
3. Select an option from the Use drop down menu:
6. Select a rate of data transmission for the Baud Rate. This must match the rate configured in the serial device.
7. Data Bits defaults to 8. This must match the rate configured in the serial device.
8. Stop Bits defaults to 1. This must match the rate configured in the serial device.
9. Parity defaults to None. This must match the rate configured in the serial device.
10. Flow Control defaults to None. This must match the rate configured in the serial device.
11. Max Line Length defaults to 80. This is the maximum number of characters before assuming an END OF LINE.
12. Line Ending is a character or set of characters that defines the END OF LINE.
Serial Integration User’s Guide
13. Timeout is the interval in seconds at which END OF LINE is inserted.
14. Status displays the status of the port. Open means that the port is ready to send or receive data; unused
means that the port is disabled or unconfigured.
15. Click Apply when finished.
Serial Integration User’s Guide
IP
An IP-based serial port is the same as UART, except that the serial data is received over TCP/IP or an Ethernet
network.
3 4 5 6 7 8 9 10 11 12
2 13
1. Click on Serial Ports in the navigation tree of the exacqVision Client software.
2. Click New.
3. Enter a unique name, if desired.
4. Select an option from the Use drop down menu:
5. Select a serial profile to process the data received by this serial port:
UART and IP
Selecting POS, ATM, or Access Ctrl in the Use field results in Serial Profiles in Profile/Protocol field.
POS, ATM, and Access Ctrl are the same functionally; they simply change the look of the icon that appears in Live
view in exacqVision:
POS:
ATM:
Access Ctrl:
When POS, ATM, or Access Ctrl is selected, you must make a Profile selection. If no profiles exist, New is the only
option. Selecting New displays the Serial Profile page immediately following the completion of the Serial Port
configuration. (Serial Profiles do not apply to UART ports if PTZ is selected in Use field.)
For UART ports, selecting PTZ allows you to configure PTZ control, typically for analog PTZ-capable cameras. For
this reason, the Profile/Protocol field displays a list of supported PTZ protocols instead of Serial Profiles. Generally,
the COM port associated with the RS-485 network should be selected.
Serial Integration User’s Guide
1. Max Line Length determine the EOL when this character count is reached.
2. Line Ending determines the EOL when a specific character string is matched.
3. Timeout determines the EOL after a certain time interval, in seconds, has elapsed (0 = disabled).
NOTE: It might appear that no data is being received if the criteria for one of these three methods is not met. Or,
data might be received but it is not in the expected format.
Let’s use the following stream of serial data to perform each of the three EOL methods. There are 50 printable
characters here, and two control characters that are invisible and non-printable. These control characters are
represented by \x0D and \x0A. (More on control characters later.)
Line Ending = x
(NOTE: We’ve set Max Line Length to 80.)
Timeout = 1
(NOTE: We’ve set Line Ending to blank.)
Line Ending
Line ending assumes that there will be a particular character or string of characters at the end of a line. Windows
and Linux use different strategies for appending their EOL characters:
Windows terminates the EOL with a carriage return and line feed (\x0D\x0A).
Linux terminates the EOL with just a line feed (\x0A).
Leaving the Line Ending field blank causes exacqVision to try to match a carriage return and line feed (\x0D\x0A)
automatically for Windows operating systems or just a line feed (\x0A) for Linux operating systems. Therefore, the
user does not have to enter anything in this field for this matching to occur. However, if the user wants to match
something other than the standard control characters, any character or string of characters can be entered into
this field. It is important to understand that once a character is typed into this field, the automatic matching of
carriage returns and line feeds is disabled, and exacqVision will attempt to match the entry in this field instead.
In the previous example, we entered an “x” into the Line Ending field. This told exacqVision to match an x in the
data string instead of trying to match a carriage return and line feed (\x0Ax\0D). This separated the line into two
parts, between the x and the next character. The rest of the characters appeared on the next line.
Timeout
Timeout pulls a segment of data from the serial data stream at a regular interval, specified in seconds. If neither
Line Length nor Line Ending result in the capture of data, setting Timeout to 1 second could reveal the data. This
method is useful for troubleshooting. NOTE: A setting of zero means timeout is disabled.
In this example, let’s assume that there are no carriage returns or line feeds, and the data size is less than the Max
Line Length value. Therefore, there is nothing to tell exacqVision that an EOL has occurred. Let’s also assume that
the data source is continuously producing the same line of data. If we set the Timeout field to 1, we might see
something like the following
1 second gap
welcome to this example string of unencrypted data
welcome to this example string of unencrypted data
welcome to this example string of unencrypted data
Serial Integration User’s Guide
1a
a
1 3
1b 4
a. If New was selected in the Profile field while configuring the serial port, exacqVision
automatically creates a blank profile named New Profile 1. Select this profile and continue to
step 3.
b. If the profile list is empty, click New. exacqVision initially names the first new profile New Profile
1. However after completing the next two steps, go back to the Serial Ports page and select your
newly created profile in the Profile field of the serial port.
2. Change the name of the profile to something meaningful.
3. Leave SOT Marker (start of transaction) and EOT Marker (end of transaction) blank and Marker Type as
Standard.
4. Click Apply.
A blank profile has been created and associated with a serial port. A conduit now exists for routing serial data from
the wire into exacqVision. From here, it is important to have an understanding of the nature of the data you will be
formatting.
Serial Integration User’s Guide
5 6
Serial Integration User’s Guide
The two examples to the right are from the Search page in
exacqVision. They illustrate the difference between using SOT
and EOT to construct a point of sale transaction and leaving
those fields blank. Leaving SOT and EOT fields blank is
equivalent to having each line be a unique transaction.
Serial Integration User’s Guide
12 Marker Type
The marker type allows the user to select between two methods for identifying the structure of the data: standard
and XML.
Standard
Standard tells exacqVision to expect plain text characters without any special formatting or structure in mind.
Following is a piece of XML data that will be processed as Standard, clear text input. The text is a character match
as it exists in the file. No special processing has taken place.
XML
XML tells exacqVision to identify XML formatting syntax, including angle brackets and a hierarchical structure.
exacqVision assumes an opening and closing element for all pieces of data. exacqVision also disables user input to
the EOT field, because it will generate the proper closing EOT based on what has been entered in the SOT field. For
now, in this example, the SOT and EOT have been left blank.
NOTE: When entering an SOT for XML data, you must prepend the
opening angle bracket (<). For example, you would enter the SOT as
“<TRANSACTION.” exacqVision then generates the EOT when you
click Apply.
Serial Integration User’s Guide
13 Event Keywords 1
1
3 4 5 6
2 7
NOTE: Selecting only the serial profile name “New Profile 1” without the “ - Door 1” appended to it will cause
ALL keywords defined in the serial profile to be matched.
An Event Linking action has now been configured so that when exacqVision receives the serial string “Door1,” the
camera selected will move to a PTZ preset position. The options available in Action Type and Action Target vary
based on other features of the exacqVision system, along with available cameras and components.
Serial Integration User’s Guide
It is also possible to match keywords on a specific serial port, as opposed to all serial ports. In this example, Serial
Port is chosen as the Event Type. The Event Source box contains the names of the configured serial ports. You can
select the serial port name, without any appended keywords (to match all keywords configured), or you can select
the serial port name with individual keywords appended.
Serial Integration User’s Guide
Using Keywords in Event Monitoring
Event Monitoring allows you to set up event-based actions that change the way the client displays cameras, views,
and video. For a full discussion of Event Monitoring, see the exacqVision User Manual. A simple example is shown
here for verification of how keywords in the Serial Profile are shown in Event Monitoring.
1
3
6 7 8
5
In this example, Event Monitoring has been configured so that when exacqVision receives the serial string “Door1,”
exacqVision Client switches the video currently being displayed to the camera selected in the Action Target. The
options available in Action Type and Action Target vary based on other features of the exacqVision system, along
with the cameras and components connected to the system.
Serial Integration User’s Guide
14 Line Masks
Line masks are used for masking out entire line segments. Line Masks work by matching a character string entered
by the user to a character string embedded in the serial data segment. When a match is found, the entire segment
is removed from the transaction. The Live and Search checkboxes provide control of where and how you want the
line segment removed.
Live removes line segment from Live View, but still writes the data to database for searching.
Search prevents line from being written to database, and therefore it cannot be searched.
NOTE: Selecting Search but not Live results in seeing the line segment in live view, but not saving it to the
database.
Here are the before and after results of this Line Mask in the Serial Preview Window. The entire line containing
GOLDFISH has been removed from Serial Preview.
Before After
Serial Integration User’s Guide
Here are the results in the Search Page of exacqVision. Notice that, with the Search box checked when we created
the line mask, the line segment does not appear in search results because it was not written to the database. This
means the data has not been saved. Use caution when creating line masks and configuring the Search and Live
checkboxes.
Before After
Serial Integration User’s Guide
15 String Replacements
String replacements are used to replace an anticipated character string in the serial data with a character string
defined by the user. String Replacements can be visible in the exacqVision Live and Search views:
Live performs replacement in Live View but still writes the original data to database.
Search replaces of data written to the database but leaves data displayed in Live View unchanged.
1
1. Select the String Replacements tab.
2. Click New.
3. Enter the string to replace.
4. Enter the replacement string.
5. Click Apply
3 4
The Live and Search checkboxes enable or disable the
masking effects in exacqVision for the Live or Search pages.
2
Remember, the original data is not deleted, and it is saved in
the database.
4
Here are the before and after results of this String Replacement.
Before After
Serial Integration User’s Guide
Here are the result on the Search age. Notice that, with the Search box checked when we created the string
replacement, the data written to the database was the substituted data of “BUBBLE GUM,” not the original data of
“GOLDFISH.” Use caution when selecting the Search and Live checkboxes.
Before After
Serial Integration User’s Guide
16 Serial Rules
Serial Rules provide a way to perform simple logic algorithms on serial data.
2
3 4 5 6
7 8
3. Field Position tells exacqVision where the field is positioned relative to its associated value in the serial data
segment:
4. Field is the variable. This can be a previously defined Event Keyword, or it can be declared in the text box:
6. Value is the value for which the comparison will be made (+ and - signs are respected).
7. Add Sub-Rule
Subtract Sub-Rule
Event Linking
Event Monitoring
Serial Search
You might set up a rule for encountering the word “void” this way.
1. The word “void” occurs before, or to the left of, the actual
value (-10.00). Therefore, choose Before for Field Position.
2. Enter the word that you want exacqVision to address as
the variable. In this case, it is “void.”
3. Enter the operator type.
4. Enter the value you want to compare.
This rule will become TRUE when a void occurs on an item less than
or equal to $-10.00.
1 2 3 4
1 1 1
Serial Integration User’s Guide
Event Monitoring with Serial Rules
In Event Monitoring, Serial Rules become Event Sources. When the Serial Rule becomes true, the Action Type and
Action Target mechanisms are executed.
1. exacqVision assumes that a numerical value is the value to be operated if any characters 0-9 are found.
2. exacqVision interprets the numerical value it finds in one of two ways:
a. If a decimal point is not found, exacqVision interprets the numerical value as an integer.
b. If a decimal point is found, exacqVision interprets the data as a floating point value.
3. Minus and plus signs are respected if they precede a numeric value.
4. If neither floating point nor an integer is detected, exacqVision interprets the value as text.
5. An equal sign operator also serves as a match operator when matching character strings instead of
numeric values.
6. Less than “<” and greater than “>” operators apply ONLY to numeric values.
Serial Integration User’s Guide
17 Data Retention
The Data Retention feature of Serial Profiles
allows you to determine how long serial data
remains stored in the database before it is
automatically deleted. By default, this value is
set to 60 days.
It is recommended that you set the data retention equal to the retention of video on the exacqVision system.
Serial Integration User’s Guide
18 Known Issue
NULL Character (0x00)
There is a known issue when NULL characters (0x00) are received and stored by exacqVision. When NULL
characters are saved in the database, it can cause searches to return partial data.
As a workaround, add an entry to the String Replacement feature in the Serial Profiles page. In this example, we
are replacing the NULL character with a SPACE character. This causes a space to be written permanently into the
database in place of NULL characters. This enables searches to work as expected in the future.
NOTE: Data already written to the database before enabling a string replacement will NOT be replaced by the
string.
19 More Information
The intent of this document was to provide guidance in configuring and using exacqVision’s serial integration
capabilities. Please see the following resources for more help: