1. General information

System was created to work with inexpensive IP-cameras and  integrate video results to standard RK6 Reports module. 

The picture below  shows the diagram of the system: 

Structure of the system

System consists of software, developed by UCS Company, and hardware from other suppliers.


UCS Video control system can use standard  IP cameras.  D-Link DCS-2102 was tested , but it is possible to use other D-Link cameras with similar API. Later the supported cameras list will be updated.

Main requirements for cameras:

  • support SMB-protocol (possibility to operate as Samba-client) - it is required for recording video files in network resource
  • support of FTP protocol for storing snapshots
  • possibility to record video fragments 1 minute long. File names must indicate date and time *
  • support of NTP-protocol (or SNTP) for time synchronization
  • support DNS (direct and opposit) **
  • support DDNS-client, if cameras use dynamic IP addresses

*  - currently date and time format must correspond with format used by D-Link cameras
** -  it is a specialty of D-Link DCS-2102 model for time synchronizing by NTP protocol

  It is recommended to use  external data storage to make system be more reliable and self-inclusive.  For example, use D-Link DNS-313  (HDD 3,5" must be purchased separately). In general video files can be stored on any network resource - but further description presumes that network resources are connected and available on drive Z:\

2. Software

2.1. Software set

  • Database management system FireBird version 2.1 and higher
  • Set of codecs to be able to view video record  (as a rule, it is supplied together with cameras, but regular codec packs, such as K-Lite codec pack, can be used)
  • Online video controlling module  VideoCamera.exe
  • Utility ScanVideo.exe for scanning for video fragments and creating records about them in database
  • RKeeper V6 terminals from version 6.95 and higher 
  • Module "Reports" version 6.90 9 (and higher) to view corresponding video files directly from viewing receipt (or  list of receipts).

2.2. Software set is stored on UCS FTP at: ../dealers/VideoControl/ folder.

3. Licensing

    it is required to purchase license to operate the video control system . After the payment is transferred, UCS Company provides program key,  which is registered in group of settings of  VideoControl.exe application. Program key is linked to a restaurant's code, so license has to be purchased for each restaurant separately.

Note: In present the amount of  installed cameras is irrelevant for purchasing the license, but later on this approach will change and it will depend on the amount of  cameras installed.

Important: The license number is not just digits, it can be also other symbols. Please pay attention when copying license number from email.

4. System installation and configuration

Time synchronizing

  This part is one of the most important parts for correct work of  the whole system. To make data, received from cameras, correspond with cash operations,  it is necessary to  synchronize time in the following modules:

  • video cameras
  • data storage (if several is used, then synchronize all of them)
  • database server
  • PC with application  AppUdpVideoSrv.exe running

    Also recommended to synchronize time on all computers, working with  Video Control system. 

NoteAs it is written in time synchronization requirements, it is not necessary to synchronize time on cash station.The reason for this is that the time marks on tags are set by AppUdpVideoSrv.exe and thus integrity of information is kept, regardless of date and time set on cash station.

The easiest  way to synchronize time is to  use time server. An external (global) or local resource can act as such server . In the  Internet there is a  lot of information on  how to set time synchronizing servers, for example an article about setting such server in Windows XP on Microsoft site (http://support.microsoft.com/kb/314054)

Setting third-party components

For correct work of  the system it is necessary to install additional components. To do that go to \InstallPlugins distribution kit and run Install.bat.

  Note: for installing this component administrator rights are required.

FireBird database management system installation

Before installing other applications, FireBird database management system must be installed. To do that  download from website http://www.firebirdsql.org/  current version (at the moment of writing this article it is 2.1.2) and set server in the desired configuration. Further description implies that FireBird is installed and operates properly.

In latest versions client library gds.32.dll was renamed into fbclient.dll. For applications compatibility  copy the library  fbclient.dll in directory SYSTEM32 (for 32-bit operating system) and rename it into gds.32.dll

Setting connection to database

All applications of  VideoControl system are attached to database management system with the help of dbexpint.dll, which is used by configuration file sqlconn.pms  in order to receive connection parameters.
Basic parameters  of sqlconn.pms are given below,  other parameters should not be changed without necessity:

Database=\ucs\videocontrol\data\videostorage.fdb - pathname  to the  database,  it can be local or network
User_Name=sysdba - user name (default SYSDBA)
Password=masterkey - password (default masterkey)
.................   SQLDialect=3 - important, do not change! 


Important: Adjusted file sqlconn.pms must be copied into each work directory, from which separate system modules are launched

Setting UDP-server 

The application AppUdpVideoSrv.exe is meant for processing of  UDP-packets, that come from cash account system, and for forming work information in accumulative database. Also this module transfers information about  cash account operations in application-hosts (so called titles).

Important: for each separate restaurant (having different codes in SYSTEM.DB) the copy of running service AppUdpVideoSrv.exe is required.

Application can be adjusted  either by manual editing  of configuration files or with the help of graphic interface. 

If configuration files were not adjusted beforehand, in the time of first start of AppUdpVideoSrv.exe the window will be shown, where the following parameters must be entered.

  •  "Key" - license key;
  • "Port" - port for incoming connections;
  •  "Pathname" - path to the directory, where xml files and tags, received from cash account system, are formed; Important: put slash (\) to the end of the path.
  •  "DB" - path to the accumulative database, in which all the work information is kept;
  • "User" и "Password" - user and password for connecting to the database;
  • in the lower text field host value must be entered, to which information about cash account operations (titles) will be sent. Value for each host must be entered separately , the format is described lower in the manual section  hosts.txt.

Important: If application opens the setting screen everytime you press OK, it means that there is problema and information about it can be checked in the log files. they have name like - log_30_03_2010_09_26_06_2541265.log where name keeps info about date and time when it was created.
NoteIn the accumulative database video files are not kept , video files references only!

 Manual setting consists of  editing of 3 files:  AppUdpVideoSrv.ini, hosts.txt и sqlconn.pms 


KeyID=600966724 - license key 
Path=z:\xml\ - path to the directory to form  xml-files and tags                  XML files will be recorded only if AppUdpVideoSrv.exe cannot write TAGs directly to database. Then these files will written to database by VideoScan.exe
Port=19123 - incoming port to receive data from cash account system


In the file  hosts.txt  hosts are specified, on which AppUdpVideoSrv will send work information  (titles). Each entry line of the file must  have information in the following form:

<IP-address>:<port> (for example, 


<IP-address> - is computer address with application-host running (in this case application-host is VideoControl.exe and/or RealVideoControl.exe)

<port> - is port for incoming connections of application-host (see description RealVideoControl.ini)

In such a way in the file hosts.txt  there must be a number of  entry lines , which must correspond the number of different copies of running application-hosts (VideoControl.exe, RealVideoControl.exe, etc.). In this case copies of application are considered to be different, if the combination  <IP-address>+<port> is unique.


The file of connection parameters is described above.

Setting the application  VideoControl.exe

The module is designed to manage the data book of the system, watching video in real time mode and having access to the video archive files.

Note: Working with video archive is based on work information from accumulative database VIDEOSTORAGE.FDB

Access to the application is protected with password  - in clean default database there is only one user  USER that has got  password  1234567890 and administrator's rights.

Setting groups

The notion "Group" is designed for logic integrity of stations and cameras within one restaurant  (within the limits of one restaurant's code).
To add new group or editing of existing group, go to menu "Video control" -> "Groups".

Noteto add or delete an element of system dictionary buttons "+" or "-" on the toolbar are used.

 To create a group, set its name  (it can be random) and enter basic parameters:


  In the field  "Key" enter license key of the given restaurant (restaurant code), in the field  "Code" - the full restaurant code (don't use separator . in the midle of code). "Main group" option specifies the status "Main" for the group and allows to indicate this group as active in all watching modes.

Important: license key and restaurant code, specified in group settings,  must agree with real restaurant code, denoted in SYSTEM.DB of cash station server. VideoControl application does not check the code and the key, but when they do not match packets from cash stations will not be decoded. Decoding key is attached to the restaurant's code and is purchased for each restaurant separately!
To keep filling in group parameters, it is necessary to fill in data books "Stations" and "Cameras" beforehand.

Setting stations  

 To add and set stations, select "Video control" -> "Stations" in the menu.

 To add a new station, enter its name and specify code. Code is the numeric identifier of the station, which corresponds with number of the stations, denoted in R-Keeper system.

Important: If station's code in  R-Keeper has value less than 10 (01, 02 .... 09), value in the field "Code" must be indicated without 0 (1, 2 ... 9)!



VideoCamera setting 

To add and set video camera, select "Video control" -> "Video cameras".

To add a new camera, enter its name and other parameters:

  •  "Pathname " - complete path to the directory, where video files of the given camera  are kept.
  • "Login" - user name  for remote camera access (is set in a certain camera settings)
  • "Password"  - user password
  • "IP"  -camera  IP-address      (is set in a certain IP camera settings)
  • "Port"  - port for remote camera access (is set in a certain IP camera settings)
  • "URL"  - special address for watching RTSP video from camera

Final setting of groups

After the data books of stations and cameras are completed, final adjustments of groups can be made. For doing that go to  "Video control" -> "Groups".
Next, in the right lower corner select stations, that exist in the system, and specify their corresponding cameras:


Video files scanner VideoScan.exe setting

VideoScan.exe  has service function  -  it scans specified path to check video files exist and records information in database. Also XML files if there are any.

To install the program copy directory VideoScan on disk, for example in C:\UCS\VideoControl\VideoScan

VideoScan directory content:

- dbexpint.dll - Borland driver to work with Interbase/Firebird
- VideoScan.exe - basic application 
- VideoScan.ini - configuration file of the application   - sqlconn.pms - connection to database information 

  File videoscan.ini settings:

FreeCriticalSize = 20 - the percent of emty space in storage, after reaching this value system will start to dlete old files
IntervalForScan = 1200 - interval to run scanning
ScanAllDate = 0 - scan all files located in the folder (Basically used if need to scan all files again).  

It is enough to scan files several times a day, or right before closing the cash station day, since the information for watching videoSetting  is required for "Reports" module.
System will not be able to shutdown when VideoScan.exe is running

Setting cash station 

To transfer data from cash station, copy library VIDEOUDP.DLL in root  RKCLIENT , and in RKEEPER6.INI enter client parameter VideoIP  with specified IP-address of the computer, on which utility AppUdpVideoSrv.exe is running  (or VideoCamera.exe - see below):


Important: Cash station part of  R-Keeper v6 transfers work data like this: tags are created and transmitted by the cash station server , and XML-packets are transmitted by cash station client. So, when selected NT-server is used, VideoIP parameter must be entered in configuration file RKEEPER6.INI of the server!

Note: In present only network client with Novell TCP/IPi support can be used for passing data - later on support of MS TCP/IP stack will be realized.

Module  "Reports" setting

The possibility to watch video files connected with receipt operations is realized in "Reports" module of version 6.90. 

Important: To watch video reports in "Reports" module, user needs a specific right - to set this right, configuration must be changed with the help of DealRK.exe, and then in  "Dispatcher" the right must be given to appropriate users.

To set report module, files from distribution kit \Offline: must be copied in directory RK6: 

- borlndmm.dll
- dbexpint.dll
- getvideoview.dll
- getvideoview.ini
- midas.dll
- sqlconn.pms
- VideoArchive.exe
- vlcax.exe
- vlcax.ini

1. File sqlconn.pms setting was described above

2. Content of file getvideoview.ini:

Position=-5 - defines time shift (in seconds) for the video fragment shown in reports.
Mode=0 - adjustment mode (1 - yes, 0 - no)
ExtVideo=1 - use exterior module  (1 - yes, 0 - no)

Adjustment mode (Mode = 1) allows to show some service information, when information about video fragment is requested from "Reports" module.

ExtVideo parameter dictates how video file will be shown - either with the help of getvideoview.dll or external application VideoArchive.exe

Note: VideoArchive.exe module can not be started as an independent application.

Setting RealVideoControl.exe (archive) application 

This application is designed for watching video from cameras in real time mode, and for showing information about current cash station operations in text mode.

Note: Later the development of this application will depend on user's needs  - today this module is not updated, because all its functions are realized in VideoControl.exe.

To install the application copy directory RealVideo in disk, for example C:\UCS\VideoControl\RealVideo

Content of folder RealVideo:

- config.ini - basic configuration file for different restaurants' parameters
- cconf1.ini
  .................   - configuration files of particular restaurants 
- cconfN.ini
- dbexpint.dll - Borland driver to work with Interbase/Firebird base
- DcsCliCtrl.dll - the library of third-party designer for working with IP-cameras
- DcsSensor.dll - the library of third-party designer for working with IP-cameras
- defclass.dll - secondary library for script processing (Script.pp)
- getvideoview.dll - secondary library for watching videos from external applications 
- install.bat - package file for component registration
- midas.dll - Borland MIDAS Component Package
- RealVideoControl.exe - basic application
- RealVideoControl.ini - configuring file of the application
- Script.pp - pattern-script for text information about cash station operations output (titles)
- sqlconn.pms - special configuration file for database connection, used by dbexpint.dll library
- start.bat -  package file for starting VideoCamera.exe in a particular mode 
- VideoViewDD.exe - special application for watching video from external programmes
- vvconfig.ini - configuration file of VideoViewDD.exe application

1. First,  components od third-party designers must be registered - run package file install.bat for that :

regsvr32 DcsCliCtrl.dll
regsvr32 DcsSensor.dll
regsvr32 midas.dll

Note: Administrator rights are required for component registration.

2. Next set file sqlconn.pms for database connection (only basic parameters are denoted, do not change others without a necessity):


Database=\ucs\videocontrol\db\videostorage.fdb - database pathname, it can be local or network .................
User_Name=sysdba - database user name
Password=masterkey - database user password
SQLDialect=3 - important, do not change! ................. 

3. Next set the configuration of each particular restaurant.

Configuration file names can be random, as an example they are named like cconfN.ini. 

In the file cconfN.ini there must be as many sections [CameraX], as there are physical cameras, installed in a resturant:

[Camera1] ...........

Parameters of section [CameraX]:

RemoteHost = "" -camera address
RemotePort = 80 - port for remote camera access   
Username = admin - user name for camera access (is assigned in camera settings)
Password = "ucs" - password for camera access (is assigned in camera access)
Num=1 - the number of cash station (UNIT), that camera corresponds with 
 Note: If the parameter Num is not assigned  (or assigned wrong), RealVideoControl.exe application will not process data  4. Next basic configuration file config.ini is set   In the config.ini there must be as many sections [RestoranX], as there are physical restaurants, in which VideoControl system operates.  [Restoran1] ............ [Restoran10] .......... 

Parameters of section [RestoranX]:

RCode="199999999" - restaurant code
Name="Restoran1" - restaurant name (for showing in application window)
Path=".\cconf1.ini" - path to restaurant configuration file (look above) - it can be absolute or relative
KeyID=600966724 - key for data decoding. It is provided after license purchase - see below for details

Important: Key for decoding is connected with restaurant code and is generated separately for each restaurant.