You are on page 1of 157

Xiamen Sunford Industry&Trade Co., Ltd.

SF-VPC Manual

Xiamen Sunford Industry&Trade Co., Ltd.


Manual Conventions

The following conventions are used throughout this manual.

Form 1. Products Catalog


Model Specifications Reference Image
1. SF-VPC-21V One door Vehicle type
2. SF-VPC Two doors door Vehicle type
3. SF-VPC-MG Multi-door Vehicle type
4. SF-VPC-21V-GGM One door Vehicle type with GGM Module
Two doors door Vehicle type with GGM
5. SF-VPC-GGM
Module

6. SF-VPC-MG-GGM Multi-door Vehicle type with GGM Module

7. SF-VPC-S11 One door Standard type


8. SF-VPC-S22 Two doors door Standard type
9. SF-VPC-WG Wide-gate Standard type
10. SF-VPC-S11-GGM One door Standard type with GGM Module
Two doors door Standard type with GGM
11. SF-VPC-S22-GGM
Module
12. SF-VPC-AT1 Anti-trailing single door
13. SF-VPC-AT2 Anti-trailing two doors
NOTE:

1. For the convenience of description, the following abbreviation will be used to instead of full name.
SF-VPC is made up of two devices:
Four-Channels Image Processor (Vehicle Video People Counter), called VPC for short.
Binocular StereoCamera (SF-BSC), called Camera for short.

Xiamen Sunford Industry&Trade Co., Ltd. 2 / 157


Warnings and Important Notices:

Mark Definition
In
Out
In/out
pause
Refresh The press-button in the VPC-Client side

Warning:

Information to alert you to potential damage to a program, system or device or

potential personal injury.

Note:

Indicates important features or instructions to observe

Xiamen Sunford Industry&Trade Co., Ltd. 3 / 157


Contents

1 KNOWING VPC .....................................................................................................................................- 9 -

1.1 VERIFY THE CONTENTS OF THE BOX ......................................................................................................... - 9 -


1.2 VPC INTRODUCTION ......................................................................................................................... - 10 -
1.3 VPC HARDWARE VERSION ................................................................................................................. - 11 -
1.3.1 Counter Hardware Version ................................................................................................... - 11 -
1.3.2 StereoCamera Version ......................................................................................................... - 15 -
1.3.3 GGM Versions...................................................................................................................... - 16 -
1.4 ORDER INFORMATION ....................................................................................................................... - 18 -
1.4.1 Counter Functions Selection ................................................................................................. - 18 -
1.4.2 Camera Selection ................................................................................................................. - 18 -

2 TECHNICAL SPECIFICATIONS ...............................................................................................................- 19 -

2.1 MAIN FEATURES .............................................................................................................................. - 19 -


2.2 ENVIRONMENTAL SPECIFICATIONS ........................................................................................................ - 19 -
2.3 LIGHTING REQUIREMENTS .................................................................................................................. - 19 -
2.4 PRODUCT CHARACTERISTICS ............................................................................................................... - 20 -
2.4.1 BSC Size ............................................................................................................................... - 20 -
2.4.2 Counter Size......................................................................................................................... - 21 -
2.5 HARDWARE SPECIFICATIONS ............................................................................................................... - 22 -
2.5.1 Power Supply ....................................................................................................................... - 22 -
2.5.2 RJ45 Ethernet ...................................................................................................................... - 22 -
2.5.3 RS232 .................................................................................................................................. - 23 -
2.5.4 RS485 .................................................................................................................................. - 23 -
2.5.5 GPI ...................................................................................................................................... - 23 -
2.5.6 GPO..................................................................................................................................... - 24 -
2.5.7 CVBS INPUT ......................................................................................................................... - 24 -
2.5.8 CVBS OUTPUT ...................................................................................................................... - 24 -
2.5.9 USB1.1................................................................................................................................. - 25 -
2.5.10 IR-LED.................................................................................................................................. - 25 -
2.5.11 Records ............................................................................................................................... - 25 -

3 INSTALLATION VPC.............................................................................................................................- 26 -

3.1 INSTALLATION NOTES........................................................................................................................ - 26 -


3.1.1 Camera Selection ................................................................................................................. - 26 -
3.1.2 VPC Connecting Other Devices ............................................................................................. - 28 -
3.1.3 Avoid Ground Reflections ..................................................................................................... - 28 -
3.2 INSTALLATION STEPS ......................................................................................................................... - 28 -
3.2.1 Installation Plan................................................................................................................... - 28 -
3.2.2 Prepare Cables..................................................................................................................... - 32 -
3.2.3 Installation StereoCamera.................................................................................................... - 34 -
3.2.4 Installation Counter ............................................................................................................. - 37 -
3.2.5 Connection Door Status ....................................................................................................... - 38 -
3.2.6 GPO Output ......................................................................................................................... - 45 -
3.2.7 CVBS Out ............................................................................................................................. - 46 -
3.3 DEBUG .......................................................................................................................................... - 46 -

Xiamen Sunford Industry&Trade Co., Ltd. 4 / 157


3.3.1 Verify Left and Right Image.................................................................................................. - 46 -
3.3.2 Verify Door Status Signal...................................................................................................... - 49 -
3.3.3 Verify Counting Accuracy ..................................................................................................... - 50 -
3.3.4 Verify Data Transmission ..................................................................................................... - 50 -
3.4 HARDWARE SETTINGS ....................................................................................................................... - 50 -
3.4.1 8-DIP Switch ........................................................................................................................ - 50 -
3.4.2 Hardware Restore Factory Settings ...................................................................................... - 51 -
3.4.3 Run Backup System.............................................................................................................. - 52 -
3.5 BUILDING INSTALLATION EXAMPLE ....................................................................................................... - 52 -

4 VPC-CLIENT SOFTWARE ......................................................................................................................- 56 -

4.1 COUNTER WORKING MODE ............................................................................................................... - 56 -


4.1.1 Default Mode ...................................................................................................................... - 56 -
4.1.2 Debug Model ....................................................................................................................... - 57 -
4.1.3 Backup System..................................................................................................................... - 57 -
4.2 COUNTER LED AND SOUND FEEDBACK .................................................................................................. - 57 -
4.3 VPC-CLIENT INTRODUCTION .............................................................................................................. - 60 -
4.3.1 Introduction......................................................................................................................... - 60 -
4.3.2 Upgrade Client Software ...................................................................................................... - 60 -
4.4 VPC-CLIENT OPERATION STEPS ........................................................................................................... - 60 -
4.4.1 Connection Hardware Correctly............................................................................................ - 60 -
4.4.2 Installation VPC-Client ......................................................................................................... - 62 -
4.4.3 Power ON Counter ............................................................................................................... - 62 -
4.4.4 Change Computer IP ............................................................................................................ - 63 -
4.4.5 Firewall configuration .......................................................................................................... - 67 -
4.4.6 Change Network Adapter Settings........................................................................................ - 67 -
4.4.7 Run VPC-Client..................................................................................................................... - 68 -
4.4.8 Shutdown VPC-Client ........................................................................................................... - 74 -
4.5 VPC-CLIENT OPERATIONS .................................................................................................................. - 74 -
4.5.1 Counter Parameter .............................................................................................................. - 74 -
4.5.2 Server/Video ........................................................................................................................ - 77 -
4.5.3 Detect ................................................................................................................................. - 81 -
4.5.4 IO and Record ...................................................................................................................... - 90 -
4.5.5 USB Disk operation .............................................................................................................. - 95 -

5 APPLICATION......................................................................................................................................- 98 -

5.1 GGM ........................................................................................................................................... - 98 -


5.2 SERIAL PORTS ................................................................................................................................. - 98 -
5.3 GPO OUTPUT ................................................................................................................................. - 98 -
5.4 ETHERNET CONNECTION .................................................................................................................... - 99 -
5.5 SMS .......................................................................................................................................... - 100 -
5.6 MULTI-DOOR ............................................................................................................................... - 100 -
5.7 WIDE-GATE ................................................................................................................................. - 100 -
5.8 ANALOG VIDEO OUTPUT ................................................................................................................. - 100 -

6 VPC-GGM VERSION ...................................................................................................................... - 101 -

6.1 DEVICE TYPE OF VPC WITH GGM...................................................................................................... - 101 -

Xiamen Sunford Industry&Trade Co., Ltd. 5 / 157


6.2 GGM MODULE INSTALLATION........................................................................................................... - 101 -
6.2.1 Install Module.................................................................................................................... - 101 -
6.2.2 Connect Antenna ............................................................................................................... - 102 -
6.2.3 Install SIM for GGM Module............................................................................................... - 102 -
Step 1: Look for SIM slot in the back panel of VPC .............................................................................. - 102 -
Step 2: .............................................................................................................................................. - 103 -
Step 3: .............................................................................................................................................. - 103 -
6.3 SERIAL PORT FUNCTION DECLARATION FOR VPC WITH GGM .................................................................... - 104 -
6.4 VPC-GGM SOFTWARE SETTING ....................................................................................................... - 104 -
6.4.1 Server Video Settings ...................................................................................................... - 105 -
6.4.2 GPS/GPRS Settings.......................................................................................................... - 105 -
6.4.3 Upload GPS Data ............................................................................................................... - 106 -
6.4.4 Check Settings ................................................................................................................... - 106 -
6.5 RECORDS FORMAT ......................................................................................................................... - 107 -
6.6 GSM PROTOCOL ........................................................................................................................... - 108 -
6.6.1 Protocol Brief..................................................................................................................... - 108 -
6.7 CONDITION WHEN SEND MORE DATA: ................................................................................................. - 110 -
6.8 GGM SEND DATA COMMUNICATE PROTOCOL ....................................................................................... - 110 -
6.8.1 Client type no. Define as below: ......................................................................................... - 110 -
6.8.2 Communicate type:............................................................................................................ - 111 -
6.8.3 Communicate protocol....................................................................................................... - 111 -
6.9 COMMUNICATE DIAGRAM ............................................................................................................... - 113 -

7 VPC-MG VERSION ......................................................................................................................... - 116 -

7.1 COUNTER INFO SHOWS DEVICE TYPE IS VPC-MG. ....................................................................... - 116 -


7.2 COUNTER TYPE.............................................................................................................................. - 116 -
7.3 COUNTERS CONNECTION ................................................................................................................. - 116 -
7.4 SOFTWARE SETTINGS ...................................................................................................................... - 117 -
7.4.1 Set Current Counter as a Master Counter ........................................................................... - 118 -
7.4.2 Set Current Counter as a Slave Counter .............................................................................. - 119 -
7.5 VERIFY ........................................................................................................................................ - 120 -

8 VPC-WG VERSION ......................................................................................................................... - 121 -

8.1 WIDE GATE SYSTEM ....................................................................................................................... - 121 -


8.2 DEVICE TYPE ................................................................................................................................. - 121 -
8.3 COUNTERS CONNECTION ................................................................................................................. - 122 -
8.4 SOFTWARE SETTINGS ...................................................................................................................... - 123 -
8.4.1 Set Current Counter as a Master Counter ........................................................................... - 123 -
8.4.2 Set Current Counter as a Slave Counter .............................................................................. - 124 -
8.5 VERIFY ........................................................................................................................................ - 125 -

9 ANTI-TAILGATING VERSION .......................................................................................................... - 127 -

9.1 DETECT OBJECTS WITHIN THE REGION ................................................................................................ - 127 -


9.2 ACROSS COUNTING ........................................................................................................................ - 127 -

10 *BE SERVER NETWORK PROTOCOL............................................................................................... - 129 -

10.1 NETWORK COMMUNICATION PROTOCOL ............................................................................................. - 129 -

Xiamen Sunford Industry&Trade Co., Ltd. 6 / 157


10.2 TCP DEFINE THE FIELD OF TCP DATA PACKET ........................................................................................ - 130 -
10.3 TCP COMMAND LIST ...................................................................................................................... - 131 -
10.4 TCP/IP COMMAND DESCRIPTION ...................................................................................................... - 132 -
10.4.1 Get VPC Time..................................................................................................................... - 132 -
10.4.2 VPC Time synchronization .................................................................................................. - 132 -
10.4.3 Get VPC Parameters .......................................................................................................... - 132 -
10.4.4 Update VPC Network Parameters....................................................................................... - 132 -
10.4.5 Get record total number .................................................................................................... - 133 -
10.4.6 Delete All Records .............................................................................................................. - 133 -
10.4.7 Reset Counter .................................................................................................................... - 134 -
10.4.8 Download all the records ................................................................................................... - 134 -
10.4.9 GetCounter Value .............................................................................................................. - 135 -
10.4.10 GPIO Configuration ........................................................................................................ - 136 -
10.4.11 GPIO State Search .......................................................................................................... - 136 -

11 *BE CLIENT NETWORK PROTOCOL ................................................................................................ - 138 -

11.1 0X0202: REGISTRATION PACKAGE .................................................................................................. - 138 -


11.2 0X0208: HEARTBEAT PACKAGE ..................................................................................................... - 139 -
11.3 0X0048: RECORD PACKAGE ......................................................................................................... - 139 -

12 *BE CLIENT NETWORK PROTOCOL OF GPRS.................................................................................. - 141 -

12.1 DEFINITION OF CLIENT TYPE .............................................................................................................. - 141 -


12.2 COMMUNICATION MODE ................................................................................................................ - 142 -
12.3 COMMUNICATION PROTOCOL ........................................................................................................... - 142 -
12.3.1 0x0208 Registration Package ......................................................................................... - 142 -
12.3.2 0x1008 Heartbeat Package Without GPS Info .............................................................. - 143 -
12.3.3 0x1008 Heartbeat Package With GPS info ................................................................... - 143 -
12.3.4 0x1000 Record Package ..................................................................................................... - 143 -

13 *RS232 AND RS485 PROTOCOL..................................................................................................... - 147 -

13.1 INTRODUCTION ............................................................................................................................. - 147 -


13.2 NOUNS CONSTRAINTS ..................................................................................................................... - 147 -
13.3 CONFIGURATION ........................................................................................................................... - 147 -
13.4 PROTOCOL FRAME FORMAT ............................................................................................................. - 148 -
13.5 RS232-GUI TOOL ....................................................................................................................... - 148 -
13.6 TEST SERIAL PORT CONNECTION ........................................................................................................ - 149 -
13.7 RS232/485 COMMAND DESCRIPTION ............................................................................................... - 150 -
13.7.1 Handshaking Protocol ........................................................................................................ - 150 -
13.7.2 Baud Rate Settings............................................................................................................. - 151 -
13.7.3 Get VPC Time..................................................................................................................... - 151 -
13.7.4 Set VPC Time ..................................................................................................................... - 152 -
13.7.5 Reset Counters................................................................................................................... - 152 -
13.7.6 Read Total Record Numbers ............................................................................................... - 153 -
13.7.7 Download One Record ....................................................................................................... - 153 -
13.7.8 Download All Records ........................................................................................................ - 154 -
13.7.9 Delete All Records .............................................................................................................. - 155 -
13.7.10 Send Real Time Record ................................................................................................... - 155 -

Xiamen Sunford Industry&Trade Co., Ltd. 7 / 157


13.7.11 *Read Current Counter Value ......................................................................................... - 156 -
13.7.12 VPC restart\reset ........................................................................................................... - 156 -
13.7.13 Restore to factory setting ............................................................................................... - 156 -
13.7.14 Read Version.................................................................................................................. - 157 -
13.8 SERIAL PORTS APPLICATIONS ............................................................................................................ - 157 -

Xiamen Sunford Industry&Trade Co., Ltd. 8 / 157


1 Knowing VPC
1.1 Verify the contents of the box
When you receive the VPC, first of all, please check the outward appearance any obvious damage (product
packaging material can meet most unexpected impacts during transport). Then open the box, check whether
accessories are complete, and the product with a purchased part list card of the device to facilitate your check.

Figure 1. One unit VPC include One Counter and Two/One StereoCamera

Figure 2. VPC Package Diagram


Note: Compartment box has VPC wiring, according to different hardware versions wiring.

Form 2. VPC Packing List


No. Content QTY Note
1. VPC (DSP-A) 1pcs A for Vehicle type, B for Standard
2. StereoCamera (SF-BSC) 1 or 2 pcs According to your order
3. 6 pin AIR OUTLET Female Connector and Tail wire 1 or 2 pcs According to your order
4. 26 pin connectors and wires 1pcs all or parts by order
5. CD 1pcs Software and documents
6. GPS Antenna 1pcs GGM accessories
7. GPRS Antenna 1pcs GGM accessories
8. Lifting bracket Optional
Note: Package contents are subject to packing list inside the box.

Xiamen Sunford Industry&Trade Co., Ltd. 9 / 157


1.2 VPC Introduction
VPC is a compact, automatic, non-contact high-tech intelligent vision product which is based on binocular
stereoscopic vision technology. It has been designed for people counting in the door/ways of buses, trains and
buildings. VPC can distinguish the number of people in/out or stays in a closed area.

This passenger counter can be easily adapted to a variety of different application requirements and installation
environment.

Due to the split design and complete installation accessories, making it easy to install, maintain, and debug.
The Counter and BSC could be quickly and easily installed in the door, ceiling, bus etc.

VPC could connect two StereoCamera, support detect two doors or two channels in two-way (in and out)
people counting in simultaneously.

VPC support many VPCs collaborative work to Detect more doors or channels via Ethernet or direct connect
network cable.

VPC could detect 120cm-1020cm wide gate by StereoCamera can be arranged in a straight line.

StereoCamera gets the left and right two images of one scenarios in real time. Because the Infrared-LED inside,
VPC can work in any type of lighting environments or even full darkness.

StereoCamera should be installed perpendicular to the ground. To achieve this goal, our StereoCamera have
two fixed bracket, were able to provide bi-directional 0-60 degree and 90 degree adjustment, and each
minimum adjustment angle is 2.5 degrees. Due to the design of the adjustable stand allows StereoCameras can
be installed and fixed in position and not vertical surfaces.

The VPC judge the objects moved direction (in/out) under the Camera by detecting and analysing the height,
shape, direction of objects and record the in/out information in real time. The records can be saved in the
recordable compact storage of VPC then can be downloaded and used for report analysis.

Binuclear Stereo Vision is an important technology of machine vision. It is based on the parallax theory and
using imaging equipment from different location to obtain two images of tested object, then compute image
corresponding points between position deviation to obtain object three-dimensional geometrical information.
Combine images obtained by two eyes and observe the differences between them, we can obtain significant
feeling of depth and establish corresponding relations among the characteristics. The two images that have
differences in the distance, we call the Disparity image. Stereo Video vision has higher precision than
monocular two-dimensional video analysis.

Left Camera image Right Camera image Disparity

Figure 3. StereoCamera Detect Image

Xiamen Sunford Industry&Trade Co., Ltd. 10 / 157


1.3 VPC Hardware Version
The Counter and StereoCamera of the VPC have several hardware version, we sell the last version default.

1.3.1 Counter Hardware Version

Counter has several appearance versions from the back panel as the following. And there are two versions in
the status bar in the VPC-Client.exe. The two hardware versions are different.

Counter Hardware Versions Counter Hardware Versions


Note
in appearance in VPC-Client Status Bar
V2.0.0 V2.0.0 20pin connector
V2.0.2 additional line inside
V2.0.3 V2.0.2
V2.0.5 White 26pin connector
V2.0.6 Black 26pin connector
V2.0.7 additional line inside
Note: The following article says hardware version generally refers to Counter Hardware Versions in VPC-Client
Status Bar.

1.3.1.1 Vehicle Type VPC_V2.0.0

Figure 4. Vehicle Type: VPC_V2.0.0 Hardware

Xiamen Sunford Industry&Trade Co., Ltd. 11 / 157


Figure 5. Vehicle Type_V2.0.0 Hardware

1.3.1.2 Standard Type VPC_V1.0

Figure 6. Standard Type VPC_V1.0

1.3.1.3 Vehicle Type VPC_V2.0.2&V2.0.3

Figure 7. Vehicle Type VPC_V2.0.2&V2.0.3

Xiamen Sunford Industry&Trade Co., Ltd. 12 / 157


1.3.1.4 Vehicle Type VPC_V2.0.5

Omission.

1.3.1.5 Vehicle Type VPC_V2.0.6

Figure 8. Vehicle Type VPC_V2.0.6

Xiamen Sunford Industry&Trade Co., Ltd. 13 / 157


Figure 9. V2.0.6 Cables

Xiamen Sunford Industry&Trade Co., Ltd. 14 / 157


Figure 10. V2.0.6 Back Panel

1.3.2 StereoCamera Version

1.3.2.1 SF-BSC_V3.0

Figure 11. The Diagram of StereoCamera

Figure 12. StereoCamera V3.0

1.3.2.2 SF-BSC_V3.1

Figure 13. StereoCamera V3.1

Xiamen Sunford Industry&Trade Co., Ltd. 15 / 157


1.3.2.3 SF-BSC_V4.0

The StereoCamera tail lines:

Left Analog Video Output: 1 or White BNC connector.

Right Analog Video Output: 2 or Yellow (or Blacks) BNC connector.

DC Female Connector: DC12V power input from the Counter DC12V power output of the DC Male connector.

Figure 14. StereoCamera_V4.0 Front View

Figure 15. StereoCamera Unique ID

1.3.3 GGM Versions

1.3.3.1 SF-GGM_V1.0

Xiamen Sunford Industry&Trade Co., Ltd. 16 / 157


Figure 16. SF-GGM_V1.0 Real Photo
1.3.3.2 SF-GGM_V2.0

Figure 17. SF-GGM_V2.0 Real Photo


1.3.3.3 SF-GGM_V2.1

Figure 18. SF-GGM_V2.1 Real Photo


Note: SF-GGM_V2.1 is an upgraded modification version of the SF-GGM_V2.0, there is more than a fly line in
appearance. And you need use the corresponding SF-4CH-V_V2.0.7 (with SF-4CH-V_V2.0.6) board has you
must fly line. At the same time, it needs using a different firmware. (For more details, please contact US)

Xiamen Sunford Industry&Trade Co., Ltd. 17 / 157


1.4 Order Information

1.4.1 Counter Functions Selection

Form 3. VPC Functions Choices


No. Function Optional Specification Note
1. Channel/Door Amount 1 2 Others One Multi-Door system up to 32 Cameras
2. Channel/Door width within 150cm one door
3. GPRS+GPS YES NO Selected, no serial port function
4. GPI Amounts None 1-4pcs 5-8pcs
5. GPI Type Voltage Switch
6. GPO Amounts None 1 2 3 4
7. RS485 YES NO Selected, no GPRS+GPS Function
8. RS232 YES NO Selected, no GPRS+GPS Function
9. Communication Way RS232 RS485 GPRS See this article VPC Application
TCP/IP GPO

1.4.2 Camera Selection

According to the StereoCamera installation height, need use different lens. See this article Measurement of
the VPC installation Position

Xiamen Sunford Industry&Trade Co., Ltd. 18 / 157


2 Technical Specifications
2.1 Main Features
High reliability
Easy installation
Easy connection of multiple units
Software installation-friendly
StereoCamera (default acquisition rate: 50 frames rate per second )
Reliable operations in any type of lighting condition (even in complete darkness) with infrared light
High counting accuracy (ideal condition can amount to 98%)
IP65 Environmental protection level
Can save the massive122880/61440 records, using FIFO storage method
Simple multi-functional interfaces:
Power port (Input: DC 8-35V; Output: DC 12V)
RS4851 standard serial port
RS2321 standard serial port
RJ451 standard Ethernet port
USB1.11port universal serial bus ports(Optional)
Eight digital optical coupling isolation GPI input, two GPO relay output
A four-channels segmentation of video output and a configurable video output
Easily connect debugging/installation ports
GPS+GPRS module (Optional)

2.2 Environmental Specifications


MTBF:>6000 hours
Operation temperature range:-25~+55
Relative humidity:10% - 90%(non condensing)
Heat radiating :passive heat output(natural cooling)
EMC Electromagnetic standard:
EN55022:2010
EN55024:2010

2.3 Lighting Requirements


There are no strict lighting requirements (if the infrared LED illumination is set to maximum intensity, the VPC
can even work in complete darkness). However, were commend that, for optimal performance, users should
provide constant diffused illumination (approx.500-1000Lux, i.e. standard light intensity for an interior office
space). Users should also avoid direct sunlight or strong light pointing in the detection area.

Xiamen Sunford Industry&Trade Co., Ltd. 19 / 157


2.4 Product Characteristics
Form 4. VPC Characteristics
StereoCamera (SF-BSC) VPC
Shell material Die-casting aluminum alloy
Surface process Surface oxidization
Color Black
LWH 1265048.5mm 15412045mm
Net Weight 280g 480g

2.4.1 BSC Size

Figure 19. StereoCamera Size

Xiamen Sunford Industry&Trade Co., Ltd. 20 / 157


2.4.2 Counter Size

Figure 20. DSP-A Size


Figure 21.

Figure 22. DSP-B Size

Xiamen Sunford Industry&Trade Co., Ltd. 21 / 157


2.5 Hardware Specifications

2.5.1 Power Supply

The VPC does not contain an internal power supply. It has to be provided by an external facility acc. to the
specified technical data and has to be connected to the intended interface. Please refer to the above specific
wiring different hardware versions of the label.

Counter Specifications Note


If you need to use a higher voltage input, such as 10V DC 60V
Power supply DC8-36V
DC, please contact US
When the power is greater than 36V 1.85A, the fuse will
Resettable fuse Built-in automatically disconnect, protect the car circuit external to the
VPC will not be burned.
Power Consume 4W (DC 24V150mA) Not supply to StereoCamera, no GGM inside.
ONLY supply to StereoCamera.
DC12V Output 3A
If short circuit , it will likely burn the Counter.
When the input DC power supply positive and negative reversed,
Anti-reverse protection Yes
Counter will automatically protected, it will not burn Counter.
StereoCamera Specifications Note
Counter DC12V output is only for supplying StereoCamera, so,
Power supply DC 12V Counter requires an input voltage higher than 13.5V DC
(DC13.5V-36V)
Power Consume 350mA, 4.5W IR-LED all lighting
SF-GGM Module Specifications Note
Power Consume 50mA, 0.7W When power supply to Counter is DC12V

Figure 23. Counter Power Input and Output

2.5.2 RJ45 Ethernet

Two LED lights, display Connection and work status.

Adaptable 10Base-T/100Base-TX

Automatic support without crossover and straight-through cable.

Completely compatible IEEE 802.3u.

Xiamen Sunford Industry&Trade Co., Ltd. 22 / 157


2.5.3 RS232

Form 5. RS232 Specifications


Name Specifications Note
Positive output supply voltage range, V+ 0.3 V to 6 V
Negative output supply voltage range, V 0.3 V to 7 V
Supply voltage dierence, V+ V 13 V
Input voltage range, VI: Driver 0.3 V to 6 V
Receiver 25 V to 25 V
Output voltage range, VO: Driver 13.2 V to 13.2 V
Receiver 0.3 V to VCC + 0.3 V
Transfer Speed Operates Up To 250 kbit/s Support 4800/9600/19200/38400/115200 bps

2.5.4 RS485

Form 6. RS485 Specifications


Name Specifications Note
Logic -0.3V toVCC+0.5V
Input Driver -0.3V toVCC+0.5V
Receiver 15V
Logic -0.3V toVCC+0.5V
Driver 15V
Output
Receiver -0.3V to VCC+0.5V

Transfer Speed Operates Up To 5M bps Support 4800/9600/19200/38400/115200 bps

2.5.5 GPI

Counter has 0/4/8 General Purpose Input(GPI) optocoupler by factory configured. Each GPI can be configured
to level input or switch input mode, the user can customize mode, please contact us.

GPI is the external signal input of the VPC. According to the VPC factory configuration, GPI could detect three
external signals as following:

Switch Signal
Voltage Level Signal
Pulse Signal (one of the Votage Level Signal)

Form 7. GPI Specifications


Name Specifications Note
Collectoremi er voltage 55 V (Min)
Current transfer ratio 50(minutes)

Xiamen Sunford Industry&Trade Co., Ltd. 23 / 157


Isolation voltage 2500 Vrms
Turn-on/Turn-off time 2-3s (Ta=25C) VCC = 10 V; IC = 2 mA; RL = 100
UL recognized UL1577file No.E67349 or UL1577, file No.E152349
Note: When use external level input to GPI, its better to use power common ground.

2.5.6 GPO

Form 8. Each relay has the same index


Name Specifications Note
Maximum Switching Power 30W (resistive) 37.5 VA (resistive)
Maximum Switching Voltage 220Vdc / 250Vac
Maximum Switching Current 1A
Maximum Carrying Current 1A
Minimun Contact Ratings 10 mV.dc10A
Initial Contact Resistance 100m
Operate Time (Excluding Bounce) Approximately 2 ms
Release Time (Excluding Bounce) Approximately 1 ms without diode
Insulation Resistance 1000 M at 500 Vdc

2.5.7 CVBS INPUT

Counter support 4-channel analog video input in real time. Also supports two-channel analog video input
switching, but always has 4-channels in real time.

2.5.8 CVBS OUTPUT

Counter has two CVBS analog video signal output for driving 75 DC level, it can be connected directly to a TV
monitor or DVR. The CVBS connector is BNC.

VideoOut1: The "4" BNC in AIR OUTLET A, the quad CVBS analog video output in real time.

VideoOut2: The "3" BNC in AIR OUTLET A, as with real-time display of the OSD quad CVBS analog video output.

Figure 24. CVBS Output


Left and right VideoOut of the StereoCamera is CVBS t, use analog video cable (75-3 or 75-5) to connect the
Counter CVBS input. The CVBS connector is BNC.

Xiamen Sunford Industry&Trade Co., Ltd. 24 / 157


2.5.9 USB1.1

Optional.
It supports full-speed (12Mbps) and low speed (1.5 Mbps) USB transfer
In line with USB1.1 specification.

2.5.10 IR-LED

Different version of the StereoCamera has different amounts and light intensity infrared lights. There are
interior lighting in the bus in the evening. Generally, the factory configure infrared LED should satisfy light and
make image clear. For more light, please contact us.

2.5.11 Records

Records has dozens of types of records.


Without GPS information record is 16 bytes, Counter can save 122 880
With GPS information is 32 bytes. Counter can hold 61,440.
Counter has 2M of space and is divided into five sectors, using FIFO way to save the record.
Records can be limited by the network, GPRS, serial, USB download and erase.
Record once erased CAN NOT be recovered.

Xiamen Sunford Industry&Trade Co., Ltd. 25 / 157


3 Installation VPC
3.1 Installation Notes

3.1.1 Camera Selection

3.1.1.1 Choose the right lens

Camera lens size and installation height can directly affects the VPC counting accuracy, user need to measure
before ordering. Please refer to the following table.

Form 9. The table of lens focus and corresponding installation height


Lens Focus Min Height Max Height Camera NO. Door Width Blind Area
2.1mm 185cm 195 cm 21#***** 120cm 10cm
2.3mm 193 cm 200 cm 23#***** 120cm 12cm
2.5mm 195cm 205cm 25#***** ***** 25# 120cm 14cm
2.8mm 200cm 215cm 28#***** ***** 28# 120cm 16cm
3.6mm 210cm 226cm 36#***** ***** 36# 120cm 22cm
4mm 225cm 240cm 4#***** ***** 4# 120cm 25cm
6mm 239cm 260cm 6#***** ***** 6# 140cm 35cm
8mm 250cm 280cm 8#***** ***** 8# 140cm 45cm
Note:

The Camera NO. column, "#" is anyone of English letters a-z, a-z; "* means Arabic numerals.

There are maybe two suitable lens in same height, please contact us to choose the best.

3.1.1.2 Choose the bracket

StereoCamera offers two mounting brackets (as explained in the following brackets), asking the user to select
proper bracket according to the actual situation,

Under normal circumstances, the "L" type bracket for vehicle, lifting bracket for fixed places.

1. L Bracket

There are 44 holes on "L" bracket and the holes make it easy to adjust angle of the StereoCamera lens surface
and ground. L has respectively left and right rotation adjustment feature, adjustable angle to 0 60 degrees
and 90 degrees, the minimum spacing of 2.5 degrees.

Xiamen Sunford Industry&Trade Co., Ltd. 26 / 157


Figure 25. StereoCamera Assembly Drawing

Item QTY Photo NO. Part Code


1 2 BAY-SMB-12 Shape Ladjust bracket
2 1 BAY-SMB1/2 Basis Installation
3 4 ------ M3*6
4 4 ------- 3mm spring washer
5 4 ------- 3mm flat washer

2. Lifting Bracket

VPC offer lifting bracket (as below), which can fix any standard Camera bracket. It can adjust angel, to make it
perpendicular to the ground as possible.

Figure 26. Camera Adjustable lifting bracket map

Xiamen Sunford Industry&Trade Co., Ltd. 27 / 157


3.1.2 VPC Connecting Other Devices

In order to monitor in real time the boarding and exiting of passengers, VPC can connect with other devices on
the vehicle through the RS485/232 interface and transmit data real time. For example on embedded DVR or
GPS/GPRS, VPC by GPRS/3G upload passenger real-time data to the background, make it easier to see.

VPC integrates with isolated digital I/O interfaces can get signals about the door switches status in order to
guarantee that VPC can count when the door is open. For example: VPC can stop counting when the door is
closed.

Please see the 5 Application chapter.

3.1.3 Avoid Ground Reflections

The VPC passenger detecting and statistic function sare based on Binocular Stereo Vision technical, in other
words, it measures the objects height present in the view fields by two Cameras, and tracking .It performances
robust and excellent precision against changes in the illumination.

However, highly reflective, geometric structures situate do nor near the floor, such as the metallic parts for
door operating mechanisms, which cause extreme pattern so flight and darkness when
illuminatedbystronglight(e.g.directsunlightordirectionalhalogenlighting)couldleadtoflaweddistance
measurements.

To avoid performance degradation due to the se effects, high reflective material surfaces should be avoided as
much as possible in the area within the ameras view, also lighting in the gate area should be diffused and not
spot-like. The floor reflective in dex should be kept below 0.7(e.g. white acrylic paint) and should not display
regular geometric repetitive patterns. Metallic or shiny objects (such as door handles, bars, glass or protective
glossy strips)should not cover a significant part of the visual field. If this is not avoidable, the reflectivity of
these items should be reduced by means of non-reflective materials.

Figure 27. Typical ground reflection picture

3.2 Installation Steps

3.2.1 Installation Plan

3.2.1.1 Find Place

Plan and choose place of Camera and place of Counter.

Xiamen Sunford Industry&Trade Co., Ltd. 28 / 157


Figure 28. Counter and StereoCamera

Figure 29. Front StereoCamera Rear StereoCamera

Figure 30. Front StereoCamera Rear StereoCamera

Figure 31. Counter Inside Dashboard Counter Hide Above Windshield


1. Camera install above the door, straight-line distance from the door 20-50cm.
2. Counter can be installed: above the front door, the top of the windshield, inside the dashboard, the
equipment boxes behind the driver if have it, or other place.

Xiamen Sunford Industry&Trade Co., Ltd. 29 / 157


Strong Suggestions: Fill in the file <<VPC Measurement of Installation Environment>> and send us, we will give
the best installation position.

3.2.1.2 Get Power

One unit VPC only the Counter need input power supply of the DC24V in bus, StereoCamera is powered by
Counter (DC12V only). Counter does not necessarily need to connect the ACC signal, it may connect the ACC
level signal input to the Counter GPI, as the external signal detection, when needs the ACC signal. Choosing
getting power location is based on the customer's application, it is recommended to use the first method to
take power:

1. Get power behind the battery switch of the bus, VPC will power off after bus driver manually turn off the
whole bus power daily.
2. Get power before battery switch, VPC is power on 7*24 hours.
3. Get power from other places suited to user demand.

3.2.1.3 Get Door Status

Ask and get help from the bus repair staff, find the voltage level signal line of the door valve (generally under
the door). Please see the Connection Door Status in this article.

If the bus door appeared in the image, then we need connect the door status signal to the Counter, excluding
the impact of closing the door on the counting accuracy.

Possible generating door status signal place:

Limit switch detect swing arm of the door valve, with the door open and closed state corresponding to
the occurrence of opened and closed.
Interior lights near the door, with the door opening and closing state and the corresponding light and off.
On the dashboard, door status lamp, with doors opening and closing state and the corresponding light
and off.
Door switch for driver is a button (press down will bounce back) or switch (press down not bounce back),
if the button is generated is a pulse signal, and if the switch, the resulting sustained an electrical or not
electrical signal.
If could not find a suitable door status signal in bus, you may install a limit switch to detect the door
status.

Observe and estimate the signal source selected at the door open, closed when the signal changes
corresponding to what may be the way: SWITCH MODE, LEVEL MODE, PULSE MODE.

Xiamen Sunford Industry&Trade Co., Ltd. 30 / 157


Figure 32. Three place to get door status

3.2.1.4 Others connection

1. GPRS Antenna:

Find a place can be fixed in the bus.

2. GPS antenna:

Recommendation behind the vehicle windshield, against the sky with good visibility, ensuring at the same time
be covering three or more satellite signals.

3. Serial RS232:
2
Three-core shielded power cable, cross-sectional area of approximately 0.5 mm .

4. Serial RS485 line:

Two core shielded power cable, cross-sectional area of approximately 0.5 mm2.

5. External GPIO

Cross-sectional area of about 0.5 mm2

Xiamen Sunford Industry&Trade Co., Ltd. 31 / 157


3.2.2 Prepare Cables

3.2.2.1 Connection Diagram

Since the bus or in the building might install the Counter and Camera in two separate location, and therefore,
Counter is not equipped with all the connecting cables at the factory, or require users to produce their own
customized.

Figure 33. Cable and Connection Diagram


3.2.2.2 Installation Material List

Form 10. Material and Wire List


Name Standard Notes
(SYV-)75-3 or 75-5 Ohm , 96 series or 128 series Connect Counter and
Coaxial Cable (shielded layer is made of 96 fine lines) video line Camera
or better coaxial cable. Any brand will do. Prepare 2 cables for Counter
to the front door
Power line for Camera Prepare 2 cables for Counter
Two core copper wire (at least 0.3mm2 ).
to the back door
DC24V for Counter
Signal line for door
Video line connector Q9 Connector 8-10 PCS
RS485 2 core shielding
RS232 3 core shielding
NOTE: Video cable MAKE SURE to use Single Wire Coaxial Cable with 75 ohm, otherwise it will damage the
image quality, which leads to inaccurate counting precision.

Xiamen Sunford Industry&Trade Co., Ltd. 32 / 157


Figure 34. Wire Shield and Power Line for StereCamera and Video Cable

Figure 35. RS232 and RS485 Data Cable

Figure 36. Q9 connector (BNC Male) for Video Cable

Figure 37. Self Tapping Screws

Xiamen Sunford Industry&Trade Co., Ltd. 33 / 157


3.2.3 Installation StereoCamera

3.2.3.1 Right Lens Central

Determine the installation position of the Camera, the RIGHT LENS should be for door width center, around
the middle, and mark the installation "L" bracket screw holes before mounting holes. Right lens is away from
the light-sensitive side.

3.2.3.2 Installation Height and Verticality

Installation height is located 230cm from the ground (the first step or the second step, using 4mm Lens). In this
position, the detection area is between 120cm-200cm from ground (if the bus is the distance from the first
step). The blind area is between 25cm-40cm from camera glass.

Camera must install vertically, perpendicular to the ground away from the axis preferably less than plus or
minus 5 degrees, the maximum should not exceed 15 degrees. The following diagram shows:

Figure 38. Installation Height Picture

3.2.3.3 Drilling Holes Fix

Choose the right opening tool to open hole, fix Camera according to the following installation method.

3.2.3.4 L Bracket Installation

There are four screw holes in Cameras sides for using screws to fix the Camera on the ceilings, we suggest
using 4pcs M3 screws with washer. Between the "L" shaped bracket and the camera body with two M3 screws
fixed together.

Xiamen Sunford Industry&Trade Co., Ltd. 34 / 157


Figure 39. Camera Fix Diagram

Figure 40. Camera Adjustable L Bracket


The L bracket could adjust 0-60 degrees in two-way, the minimum is 2.5 degrees.

Warning:

Please dont open the Camera, otherwise it would cause the two Cameras physical location
changed, once moved (destroyed) the relative relationship between the two Cameras, there will
be an inaccurate count, and users cannot repair it by themselves so you have to send it back to
factory.

Xiamen Sunford Industry&Trade Co., Ltd. 35 / 157


Figure 41. Camera installation diagram

Figure 42. The installation imaging drawings of two-steps-door & four-steps-door


3.2.3.5 Top Bracket

There are 4 small screws on the back of Camera, using the M2.5*5 screws are equipped with lifting
attachments, using ordinary Camera bracket or self-made Suspender, fixed the lifting Camera, as in the glass
door or on the ceiling. You can use lead waterproof joint, as below:

Xiamen Sunford Industry&Trade Co., Ltd. 36 / 157


Figure 43. Top Bracket Installation Figure

Important Note:

Once the Video Camera installed, no longer have any movement Video Camera does not
require any additional equipment or glass shield to protect the lens and infrared light. If you
want to install external shell, such as explosion-proof housing, ensure the 400-900nm visible
light can through the shell.

3.2.4 Installation Counter

Counter can be mounted inside the top of the front.

Or mounted inside the dashboard, and the vehicle easy to connect a DVR or GPS device.

Xiamen Sunford Industry&Trade Co., Ltd. 37 / 157


3.2.5 Connection Door Status

It is a GPI function that using GPI detecting the door status signal, the ways as following:

3.2.5.1 LEVEL MODE

Recommended use high and low voltage level signal input: one door use one signal line (high/low level).

3.2.5.1.1 Explanations
Vehicle doors are generally true state detection mechanism, the signal may be sent to the vehicle CAN bus
door status signals to locate and measure their true status:
Door is opened, the line keeps has voltage (or no voltage)
Door is closed, the line keeps without voltage (or has voltage)

3.2.5.1.2 Measurements
Observation of door opening / closing, if there is a Limit Switch triggered by door valve driving arm, and then
along the limit-switch lines, try to find the output signal lines, then:

Measuring these lines whether there is voltage or not while the door open or closed.
Or using a Multimeter to measure one line with the ground line happen ON and OFF.
Or using test pencil measured these lines whether there is a pulse signal.

Figure 44. Automotive Test Pencil and Multimeter


Automotive test pencil ground wire connect to the vehicle ground (all buses common ground are
same), using the pencil to measure each line whether has voltage.

Xiamen Sunford Industry&Trade Co., Ltd. 38 / 157


With a multimeter DC voltage profile 200V range (greater than or circuit voltage range), measure
these lines has voltage or not.
Need to repeatedly let the door open and close several times. If the line voltage with the door
opening and closing change, then this line is available for high/low level mode for Counter GPI.

Door Opened Door Closed


Result 1 The line keeps high voltage(8V) The line keeps low (no) voltage(3V)
Result 2 The line keeps low (no) voltage(3V) The line keeps high voltage(8V)
The figure is at the top of the door limit switch can detect the door opening and closing status:

Figure 45. Door Valve Drive this Limit Switch

Find the limit switch is connected to the line where that equipment, measuring lines of this device, the red
circle in the figure below the line ahead of all the measuring probe signal line lighting or three tables, to find
such a signal line:

Xiamen Sunford Industry&Trade Co., Ltd. 39 / 157


Door is opened, the line keeps has voltage (or no voltage)
Door is closed, the line keeps without voltage (or has voltage)

3.2.5.1.3 Connection Signal Wire


Front door of high / low signal line is connected to the Counter GPI1

Backdoor high / low signal line is connected to the Counter GPI2

Because the whole bus Ground Lines are interlinked and can only take high / low that line, the ground could
not connect. As shown below:

3.2.5.1.4 Client Settings


Set as the following diagram in the IO/Record tab in VPC-Client.exe:

Xiamen Sunford Industry&Trade Co., Ltd. 40 / 157


OR

Figure 46. GPI Settings


3.2.5.1.5 Verification
The settings are correct, press the door button a few times on the dashboard, with the VPC-Client software
refresh the image, to see whether change OSD door status, or download records, if there are some door
open or closed records, it shows connections and settings are all properly.

3.2.5.2 SWITCH MODE

3.2.5.2.1 Explanations
Counter access door status is a "SWITCH", the opening and closing of the door, a switch can detect the state of
occurrence of car "open" and "closed" changes, And one door corresponding to one "SWITCH", you can use
the Switch-Mode access GPI5 and GPI6.

Figure 47. External Input Switch-Mode Signal


Note:
There is no voltage between the Switch two ends and the Ground in bus.
Moreover, the Switch works well while the Switch two ends both have been connected to the Ground Line
in bus, this connection does not affect the function and application of the switch.

3.2.5.2.2 Measurements
With a multimeter to measure this "switch" ohm on both sides, whether there will be "opened/ closed"
situation and, if present, indicates it is Switch Mode.

Xiamen Sunford Industry&Trade Co., Ltd. 41 / 157


Door Opened Door Closed
Result 1 The SWITCH keeps closed The SWITCH keeps opened
Result 2 The SWITCH keeps opened The SWITCH keeps closed

3.2.5.2.3 Connection Signal Wire


Front door: both ends of the "SWITCH", and a termination of Counter GPI5, a termination Counter ground.

Backdoor: both ends of the " SWITCH ", and a termination of Counter GPI6, a termination Counter ground.

GPI type according to the factory configuration, determine the type GPI5 and GPI6 level mode or switch mode.

As shown below:

3.2.5.2.4 Client Settings


Set as the following diagram in the IO/Record tab in VPC-Client.exe:

OR

Xiamen Sunford Industry&Trade Co., Ltd. 42 / 157


3.2.5.2.5 Verification
The settings are correct, press the door button a few times on the dashboard, with the VPC-Client software
refresh the image, to see whether change OSD door status, or download records, if there are some door
open or closed records, it shows connections and settings are all properly.

3.2.5.3 PULSE MODE

3.2.5.3.1 Explanations
One door has two wires respectively represent opened and closed.

One wire represents Door Opened when it has a pulse.

One wire represents Door Closed when it has a pulse.

Figure 48. One Door Status Need Two GPI Pulse Signal
Door Opened Door Closed
This wire has one pulse level(8V) while press the This wire has one pulse level(8V) while press the
Result open-door button. close-door button.
The pulse will disappear after release the button. The pulse will disappear after release the button.

3.2.5.3.2 Measurements
Generally, the pulse signal are generated by open/close door button.

Figure 49. Open/Close Door Button Generate Pulse Signal

Xiamen Sunford Industry&Trade Co., Ltd. 43 / 157


3.2.5.3.3 Connection Signal Wire
GPI1 connecting the pulse signal line of the front door open;

GPI2 connecting the pulse signal line of the front door close;

GPI3 connecting the pulse signal line of the back door open;

GPI4 connecting the pulse signal line of the back door close;

3.2.5.3.4 Client Settings


GPI1: CH1 Start Counting
GPI2: CH1 Stop Counting
GPI3: CH2 Start Counting
GPI4: CH2 Stop Counting

3.2.5.3.5 Verification
The settings are correct, press the door button a few times on the dashboard, with the VPC-Client software
refresh the image, to see whether change OSD door status, or download records, if there are some door
open or closed records, it shows connections and settings are all properly.

Important Note:

Not recommended for use in the following ways:


This requires the use of a pulse signal way, but, VPC every time regardless of the current state
of the door after the restart, VPC default to open the door until the door the next pulse, then
VPC only knows the correct door status.

Xiamen Sunford Industry&Trade Co., Ltd. 44 / 157


3.2.6 GPO Output

Counter has 0-4 relays GPO according to factory configuration. Each relay output has COM, NC, NO three lines
(Common; Normal Closed; Normal Opened). Principle relationship three line diagram below:

Figure 50. COM, NC, NO Relationship Diagram


When power off the Counter, the resistance between the COM and NC should be 0 ohm (connected), the COM
and NO gigantic(disconnected).

The relay can trigger a variety of circumstances, such as IN, OUT, Overload etc.

When input voltage to COM, Counter will change status after triggered or untriggered as following:

Figure 51. Normal Relay Status Triggered Relay Status


When input without voltage line to COM, Counter will change status after triggered or untriggered as
following:

Figure 52. Normal Relay Status Triggered Relay Status

Xiamen Sunford Industry&Trade Co., Ltd. 45 / 157


3.2.7 CVBS Out

Counter has two analog CVBS video output, video output is similar to the Camera, can be connected to the
DVR video input channel, for recording.

VideoOut1: The "4" BNC of the Air Head AIR OUTLET A, the quad CVBS analog video output in real time.

VideoOut2: The "3" BNC of the Air Head AIR OUTLET A, as with real-time display of the OSD quad CVBS analog
video output.
Screen OSD Display Description

DOOR: door state. Red CLOSE is off, green OPEN ON.

RUN: count status. Black OFF shows could not count; green ON
current can be counted. The current normal channel image,
background saving, opening the door for the state, is the state
can be counted.

IN: enter cleared after the cumulative number.

OUT: After clearing out the cumulative number.

Left ID: consistent with the objectives assigned to each detection


condition ID.

Left Green Line: Tracking line of tracked ID's.


Connection VPC-Client software, in the "Server / Video" tab page set as follows:

VideoOut 1 :( split video output) VPC quad original video output; no OSD.
VideoOut 2: (DSP video output) VPC configurable video output; optional quad screen display with OSD
and "no" video output.

When no video output on VideoOut DSP 2 recording, select "None."

3.3 Debug

3.3.1 Verify Left and Right Image

StereoCamera has Left and Right image, requirements properly connected, could not be reversed. At the same
time, the ID of the StereoCamera in VPC-Client of each channel, should be corresponding to the real
installation one.

Judgment Way 1:

1. If Cameras are installed on the top of ones head, you can let one person stand under the Camera, click
on the "Refresh All Pictures" button and ensure that the person faces to the top of the computer screen,
as shown in the following figure:

Xiamen Sunford Industry&Trade Co., Ltd. 46 / 157


Figure 53. Picture from Client that a man standing under the Camera
2. At present, cover the StereoCamera "left" that is Camera on left-hand side of the people who stood
below the Camera, click on the " Refresh All Pictures " button, if you block images appear in the left
picture of the VPC-Client, then the left and right connection of the StereoCameras is correct. ( Error image
instance is below)

Figure 54. Error image

Judgment Way 2:

1. Left hand take the left side of the camera(with the IR Sensor side), and let the camera's perspective and
consistent with your eyes, as shown:

2. Using left finger cover the lens of the left side, as shown:

Xiamen Sunford Industry&Trade Co., Ltd. 47 / 157


3. Click the Refresh button in the VPC-Client, if the covering finger appeared in the Left Image, it represents
the left and the right camera output to Counter is correct. as shown:

4. Thus, mounted on the camera, updates the corresponding parameter file(Camera ID) in the channel and
save background of the channel, and then to stand at the bottom of the camera, refresh the image and
the background can be obtained following the normal background and foreground detection Figure:

Xiamen Sunford Industry&Trade Co., Ltd. 48 / 157


Explanation:

Detection figure more white part represents the higher part in the image.

Background right edge appears white block image is the image edge and texture less likely to cause
interference, generally will not affect the counting accuracy.

3.3.2 Verify Door Status Signal

The settings are correct, press the door button a few times on the dashboard, with the VPC-Client software
refresh the image, to see whether change OSD door status, or download records, if there are some door
open or closed records, it shows connections and settings are all properly.

When the VideoOut 2 is set as 4 IN 1, you will in the VPC-Client as following:

Figure 55. Door Closed and Opened Status OSD

Xiamen Sunford Industry&Trade Co., Ltd. 49 / 157


3.3.3 Verify Counting Accuracy

Please see the <<VPC-FAQ>>.

3.3.4 Verify Data Transmission

According to the transmission mode to use, see the other sections of this article.

Verify that the serial connection, see "13.6 Test serial connection" section of this article.

3.4 Hardware Settings

3.4.1 8-DIP Switch

Users generally do not need to set the DIP switch, and only after you select whether to use GGM module
function, only need to modify the DIP switches to match Have GGM function.

Different hardware versions of the counter eight DIP switch settings have different effects;

3.4.1.1 V2.0.0 Hardware DIP

Open VPC box, there is a 8-dip-switch on the board:

Figure 56. Dip switch diagram

VPC factory default Settings as switch value, General-Purpose Input state of GPI are defined as follows:

Form 11. Hardware V2.0.0 DIP Switch Functions


DIP Switch Status(ON) Status(OFF) Note
Software watchdog Software watchdog The first and the second position are to set the
Switch 1
Disable Enable software watchdog function and must be used
Software watchdog Software watchdog together. Software Watchdog enable value is
Switch 2
Enable Disable default factory settings.
Switch 3 Switch Level GPI 1(Default ON)(front door status)
Switch 4 Switch Level GPI 2(Default ON)(back door status)
Switch 5 Switch Level GPI 3(Default ON)
Switch 6 Switch Level GPI 4(Default ON)

Xiamen Sunford Industry&Trade Co., Ltd. 50 / 157


Switch 7 Reserved Reserved Factory setting OFF
Switch 8 Reserved Reserved Factory setting OFF
Note: Software watchdog Disable is only for be connected by the Emulator.

Note:

Switch position 3-6 (GPI 1- GPI 4) are all individually optically isolated.

3.4.1.2 V2.0.2 Hardware DIP

Form 12. Hardware V2.0.2 DIP Switch Functions


DIP Switch Status(ON) Status(OFF) Note
Software watchdog Software watchdog The first and the second position are to set the
Switch 1
Disable Enable software watchdog function and must be used
Software watchdog Software watchdog together. Software Watchdog enable value is
Switch 2
Enable Disable default factory settings.
Switch 3 RS232 TX in Panel With GGM GPI 1(Default ON)(front door status)
Switch 4 RS232 RX in Panel With GGM GPI 2(Default ON)(back door status)
Switch 5 With GGM RS485 TX in Panel GPI 3(Default ON)
Switch 6 RS485 RX in Panel With GGM GPI 4(Default ON)
Switch 7 Reserved Reserved Factory setting OFF
Switch 8 Reserved Reserved Default Value is ON, or Counter would not
start.
Note: Software watchdog Disable is only for be connected by the Emulator.

3.4.2 Hardware Restore Factory Settings

When you forget the VPC's IP address, user name, password, and other information, cannot login and connect,
or set wrong parameters that cannot count properly, using the following way to restore hardware factory
settings.

Please using network cable to connect your computer and Counter, and run cmd program in your computer,
input ping 192.168.1.111 -t, waiting for the ping result.

3.4.2.1 V2.0.2 Hardware Restore Factory Settings

In standby mode, press and hold the reset button for 3 seconds or more within 8 seconds, Counter performs a
factory reset function. The VPC's IP address recover to be : 192.168.1.111

Xiamen Sunford Industry&Trade Co., Ltd. 51 / 157


Figure 57. Reset Button in Front Panel
3.4.2.2 V2.0.0 Hardware Restore Factory Settings

Omitted (please contact us).

Note: Restore software to factory settings, please refer to VPC-Client Software chapter.

3.4.3 Run Backup System

If the firmware upgrade fail, phenomenon is counter can't start (if power on, the buzzer is ringing always),
need to start to counter own backup system, upgrade again, and the specific steps are as follows

1) Counter is power off, long press and hold the reset button, then power up the VPC, for 3 seconds, VPC
issue "beep-beep-beep" three short chirps, then a ringing, VPC starts to backup system;
2) The VPC's IP address recover to be : 192.168.1.111;
3) Login VPC with the client software. Click on the "Refresh All Pictures" button, screen of the Camera lens is
not displayed when the VPC is backup system, you can only read time, parameters, update the firmware.
4) Use the main system firmware to update to the VPC, until the update succeeds. After the restart VPC,
restart the client software, can successfully log in VPC's main system, indicating that the master system
has been successfully restored.

3.5 Building Installation Example


The typical Video Camera is installed between225-240cm in height (with the lens perpendicular to the ground
glass). VPC detection height is between 100 5cm from the ground to 200 5cm. Change the Video Camera
installation height will change the detection range. The smallest distance is 25cm detection range from the
Camera. Video Camera angle is 70 degrees, as shown below:

Xiamen Sunford Industry&Trade Co., Ltd. 52 / 157


70

230cm

Ground
120cm

NOTE:

After installation, the system must use the "VPC-Client.exe" client.

For further information please refer to the client software operation details.

85cm away from the eyes at the Camera perpendicular to the detection zone (not ground) area is about 120
90cm, notethat the detection area is rectangular, angle relative to the long side of the rectangle is 70 degrees,
relative to the short side of the rectangle is 55 degrees, as shown said:

Figure 58. StereoCamera Detect Area

Xiamen Sunford Industry&Trade Co., Ltd. 53 / 157


If the Video Camera installed above the door, then the terminal and the wall distance "D" should be large
enough to avoid conflict with the structure above the door. D L * tan (55 / 2 = 27.5 ) L * 0.52, the
terminal side (connector side) close to the door side.

One VPC connects two StereoCameras into front and back vehicle doors.

Xiamen Sunford Industry&Trade Co., Ltd. 54 / 157


Figure 59. Counter and Camera Connections

Xiamen Sunford Industry&Trade Co., Ltd. 55 / 157


4 VPC-Client Software
VPC-Client software is a tool for setting and debug the VPC. It would not connect to VPC anymore after
finished settings.

You need to use a video cable and power wires to connect correctly the cameras and Counter when you use
VPC-Client to operate the VPC. Then, you may access the VPC via correct IP address, set VPC parameters, and
let VPC working.

4.1 Counter Working Mode


Counter working mode is divided into:

1. Default Mode: Counter independent normal working condition, no client connections.

2. Debug Mode: When the VPC-Client connection and commissioning.

3. Backup System Mode: work status after Counter running backup firmware system, generally only used to
upgrade the main system.

Note:

Debug mode causes Counter run more slowly, maybe appear missing counting phenomenon
(especially fast movement of people), upon completion of settings, be sure to switch to the
default mode of operation (Shutdown the VPC-Client).

4.1.1 Default Mode

VPC default work mode, it is to point to VPC has normal start standby and dont connect with client software,
but can connect center server (software), at this time, VPC processing speed is fastest and the accuracy is
highest .There is someone that is coming or leave the detection area, VPC internal will save a number of
records, including record number, date, time, type, and direction; The records can be saved in the recordable
compact storage of VPC via FIFO storage method then can be downloaded though network (TCP/IP)USB
RS-485 interfacing.

Important Notice:

After power, VPC automatically initialize, begin to work automatically after successful start, even
if not connected to any external computer. This is very useful for the place where the computer
cannot be installed such as public transport bus board. Users can use a U disk or notebook
computer to connect the VPC after work (the bus is not driving) to download records and set the
counter. Or use homemade network devices or serial devices to get records and set VPC.

We offer a central server software (or the record collection software that user's own developed)
must have been turned on and stay connected with Counter to receive every real-time records
data from every VPC.

Xiamen Sunford Industry&Trade Co., Ltd. 56 / 157


4.1.2 Debug Model

In this mode, the client software can connect VPC, start the real-time view video function to display real-time
image, and can draw count information people in/out on an image of channel 1/2 n in real time, easy to
observe and debug counts effect.

Important Notice:

VPC is the default mode when you start VPC normally to enter the normal counting state.
Therefore, in order to obtain accurate results of counting, VPC must be set correctly. That is, in
the each process of save background (about 10 seconds), it cannot allow any moving objects and
people in Video vision camera, that is to keep the true "background 3D image." Each time the

camera moves, the corresponding channel must be re-learning background.

4.1.3 Backup System

When the main system is damaged, maybe lost power in upgrading period, the Counter could not start and
you could not login and ping it, you need to start the backup system to upgrade the main system; Referring to
start into the backup system backup system;

In this mode, the Counter can not be counted or image detection parameters to operate, user can update their
main system firmware, get Counter date&time. Once the main system firmware update successfully in this
mode, power off again, restart Counter, you can enter the main system default mode.

4.2 Counter LED and Sound Feedback


Counter will feedback with buzz sounds and LED blinking when using VPC-Client or U Disk operating.

Figure 60. Led in Front Panel

Form 13. VPC-Client Operation Feedback


Red Green Green Green
Functions Buzzer
LED(Power) LED1(Status) LED2(Signal) LED3(GGM)
Light On 2-5S Ring100ms
Power On Light On Light On 2-5S Light On 2-5S Blink 4times Interval 2-5S
100ms Ring 300ms

Xiamen Sunford Industry&Trade Co., Ltd. 57 / 157


Light On
100ms
Interval 2S
1
Stand by(Can not counting)* Light On / / / /
*2
Stand by(Can counting) Light On Light On / / /
Ring 100ms
Light On Light On
VPC Start Interval 3S
200ms 200ms
Ring 100ms
Light On
Ring 100ms
100ms
Interval
Interval 200ms
200ms
Light On
Ring 100ms
100ms
Interval
Interval 200ms
200ms
Light On
Login Ring 100ms
100ms
Interval
Interval 200ms
200ms
Light On
Ring 100ms
100ms
Interval
Interval 200ms
200ms
Light On
Ring 100ms
100ms
Light On
Get VPC Time Ring 100ms
100ms
Light On
Set VPC Time Ring 100ms
Light On 100ms
Light On
Get Network Parameters Ring 100ms
100ms
Ring 100ms
Light On
Save Network Parameters Light On 200ms Interval 3S
200ms
Ring 100ms
Light On
100ms
Ring 100ms
Interval
Interval 3S
Light On
Save As Param File Ring 100ms
100ms
Interval 3S
Interval
Ring 100ms
Light On
100ms
Light On
Import Param File Ring 100ms
100ms
Ring 100ms
Light On Light On
Restore Factory Setting Interval 3S
200ms 200ms
Ring 300ms
Light On Ring 100ms
Restart Counter
200ms Interval 3S

Xiamen Sunford Industry&Trade Co., Ltd. 58 / 157


Ring 100ms
Light On
Ring 100ms
100ms
Main Firmware Interval
Interval 30S
Update Successfully 200ms
Light On
Ring 300ms
100ms
Main Firmware
Light On Light On Ring
Update Failure
Light On
Ring 100ms
100ms
Backup Firmware Interval
Interval 20S
Update Successfully 200ms
Light On
Ring 300ms
100ms
Backup Firmware
Light On Light On Ring
Update Failure
Light On
Refresh All Pictures Ring 100ms
100ms
Light On
Choose Channel Ring 100ms
100ms
Light On
Reset Counter Ring 100ms
100ms
Light On
Get Server Netwrok Para Ring 100ms
100ms
Light On Ring 100ms
100ms Interval
Save Server Netwrok Para Interval 200ms 200ms
Light On Light On
100ms 100ms
Create Socket
Light On
Show Video Ring 100ms
100ms
Light On
Close Video Ring 100ms
100ms
Light On
Save Background Ring 100ms
100ms
Light On
Update Camera Param Ring 100ms
100ms
Light On
Get Detecting Param Ring 100ms
100ms
Light On
Save Detecting Param Ring 100ms
100ms
Light On
GPI(1/2/3/4) test Ring 100ms
100ms
GPO(1/2) test
Light On
Get All Record Number Ring 100ms
100ms

Xiamen Sunford Industry&Trade Co., Ltd. 59 / 157


Light On
Download Ring 100ms
100ms
Light On
Arase All Records Ring 100ms
100ms
Write Commands to a File In
/ / /
U-Disk
Record File Transfer / / /

Note: Counter normal standby include: Counter normal power-up (red light), access the camera left / right
image in the normal work period, has been updated camera parameters, and save background images,
detection parameters are set correctly (green 1 lit), work when someone enters or leaves the detection area,
start counting.

4.3 VPC-Client Introduction

4.3.1 Introduction

SF-VPC-Client.exe is a green free graphical installation interface (GUI) for Windows client, support
Windows2000 /Windows XP / Windows 2003/Vista/Win7/Win8/Win10. The program will take VPC as a server
and VPC-Client as client software, the client program does not require additional software environment to
support. The program can connect a number of VPC through TCP/IP (LAN or the Internet straight line) to can
be viewed and set.

4.3.2 Upgrade Client Software

When you get a new software program, can override or upgrade installed on your computer. Detailed upgrade
steps please see related content in the VPC-Client Operation Steps.

4.4 VPC-Client Operation Steps


The followings are a list of the software used steps when working with the VPC

1. Connect the hardware correctly


2. Install the client software
3. VPC is power on and enter standby correctly
4. Run VPC-Client.exe on the computer
5. Set parameter correctly
6. Exit

4.4.1 Connection Hardware Correctly

According to the Chapter 3.2.2.1 Connection Diagram of the hardware connection requirements and
instructions, properly connected VPC with the equipment.

Note: VPC and computer connection instructions

Xiamen Sunford Industry&Trade Co., Ltd. 60 / 157


There are two connection types, one is network cable directly connected, one is connected via a switch/router
in the LAN.

Take a piece of RJ-45 cables (direct connection with VPC computer using a network cable, if connected through
a switch, you can directly use the straight line), using this network cable to link your computer's network card
and VPC (LAN) port, in accordance with the following methods to change the computer's and VPCs IP address.

Important Notice:

VPC's IP network dont support routing feature for the time being, communication between one or
more VPC and your computer must only be within the same local area network, to ensure normal
communication.

Note: Ethernet network lines production methods:

Materials and tools:

1. A piece of twisted pair cable (8 core, the length can be determined according to the actual needs, within the
effective transmission distance 100m), two standard RJ45 Crystal head, a RJ45 special line pressing tools

2. Advice: Prepare a network testing tool that you can make a test on network cable you made.

PIN definition:

Produce network lines meets the requirements according circumstance, there are two circumstances as the
following:

1. VPC connect the router or network switch HUB or other network devices, making network connections
according to the below left figure.
2. VPC is connected directly to your computer, make the network connector by through line according to the
below right figure.

Figure 61. Making Cable Crystal Head


When the VPC when properly connected to the network, the RJ45 socket indicator light up; when there is data
to send and receive network indicator flashes.

VPC factory default IP address: 192.168.1.111. Ensure TCP/IP protocol can be accessed; ports like TCP8000,
UDP6666, UDP5403 can work properly.

If your network has more than one VPC or VPC's default IP address conflicts with existing computers, network
equipment; your VPC address must be on a local area network (or direct-attached) change to the IP address
conflict-free, so your VPC can connect to the network

Xiamen Sunford Industry&Trade Co., Ltd. 61 / 157


4.4.2 Installation VPC-Client

We can send the latest software to our client through email. If you do not get the software, please connect our
support department. .

When received the software, just copy it on the PC, and run it directly.

If you use 64-bit operation system, please set the VPC-Client.exe as following:

Figure 62. Run VPC-Client.exe In Compatibility Mode

4.4.3 Power ON Counter

When VPC has power (DC13.5-36V), wait about 6-8 seconds, VPC goes into standby status. As soon as voltage
is above 36V, VPC resettable fuses will automatically cut off the power supply to protect.

4.4.3.1 LED status description

Figure 63. LED Status Description


Power LED: Light on when power on.
Status: Light on when can count passenger.
Signal: Light on when operate using VPC-Client.exe.(The version with GGM module, GPS signal light when
close the door)

Xiamen Sunford Industry&Trade Co., Ltd. 62 / 157


GGM Status: GGM module current status (Connect or not connect)

4.4.3.2 The description of the power supply on the vehicle

General in bus, power is DC24V or DC12V. VPC has a wide voltage power input, combined with different power
supplies on the bus (such as car keys direct switching power supply or battery powered), you can access
individually or together. StereoCamera power supply is DC12V input, so it is best to fetch by VPC DC12V
output.

4.4.4 Change Computer IP

VPC Image Processor default IP address is: 192.168.1.111, belongs to 192.168.1.0/254 network segment
therefore before you change VPC processors IP address, has to setup Host PCs IP address into 192.168.1.0/24
segment then can modify the VPC Processors IP address

1. Select Start Control Panel

2. Select Network Connections- Local Area Connection

Xiamen Sunford Industry&Trade Co., Ltd. 63 / 157


3. Select Local Area Connection Properties:

4. In General menu select Internet Protocol(TCP/IP) ,Click Properties

Xiamen Sunford Industry&Trade Co., Ltd. 64 / 157


5. Follow IP address as below to change Host PCs IP address and Subnet mask

6. In the IP address field enter the following

192 . 168 . 1 . 209

Note:

The IP address can be altered to meet the end users requirements; the last three fields should
be numbers ranging from 0 to 254.

The Host PC address must be different from the VPC address.

7. In the Subnet mask field enter the following

Xiamen Sunford Industry&Trade Co., Ltd. 65 / 157


255 . 255 . 255 . 0

8. Click on the OK button of each Dialog Box until all are closed.
9. Click Start button ,select Run enter CMD then click OK button to run it.

Xiamen Sunford Industry&Trade Co., Ltd. 66 / 157


10. Enter ping 192.168.1.111 -t, press Enter button

11. If comes out the result as above ,means network connect successful

Note:

Due to network protocol rules, before you run PING command make sure that the Host PC

IP is the same network segment with VPC Processor

4.4.5 Firewall configuration

If the host PC has a firewall running, the following ports must be open:

Form 14. Computer Ports and Protocol


Port Protocol Direction
8000 TCP
6666 UDP
5403 UDP

4.4.6 Change Network Adapter Settings

Computer directly connected the Counter, be sure the computer's network card is set to 10M half-duplex or
10M full-duplex network cable.

Xiamen Sunford Industry&Trade Co., Ltd. 67 / 157


Figure 64. Set 10M Half-duplex

4.4.7 Run VPC-Client

By double-clicking the VPC-Client.exe and click the Login button in the bellow left image, the following
graphical interface will appear as the right below picture:

Figure 65. VPC client landing interface


Counter IP: Default value is 192.168.1.111
Port: Default is 8000
Username: Default is admin
Password: Default is 123
Login: Via TCP/IP use VPC-Client.exe connect VPC directly.
Open Param File: Open a parameter file of VPC saved, to off-line overview these parameters of this VPC.
See more at Save As Param File(.DSP) . This function let you can see the VPC parameters in the bus, and
also, you can send this Parameter-file to Boanying to get better support.

Note: Once you change IP, user name, password, port; next time login, you need to verify the new IP, user
name, password and port.

Xiamen Sunford Industry&Trade Co., Ltd. 68 / 157


When login successfully, the VPC-Client.exe will send three orders including (Refresh All Picture, Get Network
Param, Get Detect Param) to VPC, and get some information and show in the VPC-Client.exe interface. So the
buzzer will ring three times.

4.4.7.1 Login failed treatment method

The VPC will appear below chart tip if you cannot login and connect VPC successfully:

Figure 66. VPC client login failed


Please ensure you have input these right information.

Appears two tips as above pictures, you can check the following aspects:

1. The client connects counter without any response

"Start"-"run" in the CMD command prompt, use ping counter command IP and see if I can ping Tong; ping pass,
you may use a client that does not support program "VPC-Client.exe";

"Start" - "run" in the CMD command prompt, use ping counter IP command, see whether ping can pass; If Ping
can pass, may be use the wrong version of the Client program "VPC - Client exe."

2. Unable to connect to device

Counter did not enter the standby correctly

Counter and PC are not on the same network segment

Connect the network cable is not correct (LAN using twisted pairwire, otherwise use crosswire )

3. Ping works, but the counter is not responding

There is no completely closed client in Task Manager, clear the tasks first

4. Counter ping is impassable

Counter network port is blocked, green connect light is on. Yellow data light keeps flashing, turn off the client,
unplug and re-plug the network cable, restart the counter

4.4.7.2 Login Successfully

Client software interface is as follows after connect VPC successfully,

Xiamen Sunford Industry&Trade Co., Ltd. 69 / 157


Figure 67. VPC-Client Main Interface
Important Note:

When you click the Login button and input the correct informationes after you have login one VPC, the
windows will appear:

Click Yes, you can login two VPC. There are two tab bar in the VPC-Client.exe as bellow:

1. Title: Show this current VPC`s IP.


2. Counter Info: Show all status of the VPC.
3. Counter Param Tab: can set the time, the network parameters, software upgrade, etc.
4. Server/Video Tab: Used to set the server address and port services when upload data.
5. Detect Tab: Read and Set all detecting-parameters.
6. IO/Record Tab: GPIO and Record operation.
7. USB Tab: Use USB instead of network to operate VPC.
8. Left camera: 360x288 pixel window.

Xiamen Sunford Industry&Trade Co., Ltd. 70 / 157


9. Right camera: 360x288 pixel window
10. Background: display as 180x144 pixels window.
11. Detect: display as 180x144 pixels window.
12. CH1 Counter: The counter of Channel 1.
13. CH2 Counter: The counter of Channel 2.
14. Total Counter: The total numbers of the CH1 and CH2.
15. Status bar: Including firmware and software version, Counter ID, etc.

Figure 68. Tab page of CounterParam,Server/Video, Detect

Figure 69. Tab page of IO/Record, USB,Multi-Gate

Xiamen Sunford Industry&Trade Co., Ltd. 71 / 157


4.4.7.3 VPC-Client main interface introduce

VPC is power on and in standby state, if one of the three conditions is happen: left/right lost, not save
background, or no camera parameters file, the VPC cannot count

1. Title bar:

Show current VPC IP address and software name.

2. VPC Information:
1) Counter IP: The current VPC IP address.
2) Port: Show the TCP/IP connected port in computer.
3) Status: Show the TCP connected status. The green Connected is connected status, and the red
Connected is disconnected status.
4) Device Type: Show VPC22 or VPC21.
5) Working Time: The current VPC counting period of the two channels. From 00:00:00 to 23:59:59, you can
save this working time with Save Detecting Parameters in Detect Tab.
6) Channel 1 Camera ID: CH 2 Camera ID (in camera parameter and shown in IR-LED)
7) Left Ok/Left Lose : Left Camera Image Status of CH1.
8) Left Ok/Left Lose :Right Camera Image Status of CH1.
9) Channel 2 Camera ID: CH1 Camera ID (in camera parameter and shown in IR-LED)
10) Left Ok/Left Lose : Left Camera Image Status of CH2.
11) Left Ok/Left Lose : Right Camera Image Status of CH2.
12) Current CH: Choose the channel for current operating.
13) CH1/CH2 Reset Counters: Reset the counter of current channel to zero.
14) Refresh ALL Pictures: Get a camera frame to show.

Important Note

Show "left/right image is not normal" could be caused by several reasons: the camera does not
power up properly, camera video cable is poor connect, or the camera CCD is bad; the VPC image is

detected is not normal, is displayed in red font, as shown in the following figure

Once the video input return to narmal, it will be as below:

You cant save the background once either iamge of the two channals is abnormal; If the client show Right OK
/ Left OK, click Refresh All Pictures, if the two pictures both are black and with fuzzy shadow, as following
picture shows, please check whether the power supply is loose or lack.

Xiamen Sunford Industry&Trade Co., Ltd. 72 / 157


3. Login: Press the Login button, the login windows will appear.

Important Note

login: click on the button, there will be landing and VPC or embedded devices for the connection
login window;; Double click IP address in the tab bar of interface, that is, shut down the current
connected VPC window

4. Counter:

CH 1 Counter: Show channel 1 IN and OUT numbers in real time.


CH 2 Counter: Show channel 2 IN and OUT numbers in real time.
Total Counter: Add IN numbers and minus OUT numbers of CH1 and CH2. In the bus, this number is
Left. If it is a negative number, we show it 0.

Note: Whatever the VPC-Client.exe is running or connected VPC, these counters will show the VPC
cumulative people number from the power or last Reset Counter or restart VPC resetting the counter.

5. Status Bar:

Counter ID: VPC ID (the last eight NO of net port MAC address)
Main Firmware: software version of the embedded products on the VPC
Hardware: Current VPC-image processor version.
Client Ver.: Current VPC-Client.exe software version.

Xiamen Sunford Industry&Trade Co., Ltd. 73 / 157


6. Function Tab Bar:

Different VPC Version will appear different contents in the Function Tab Bar.

Figure 70. Functions Tab


Counter Param: View and set functional parameters.
Server/Video: view and set server network parameters, and view real-time video
Detect: view and set the VPC detection related parameters
IO/Record: view and set with VPC GPIO and serial (RS232 and RS485) and record.
USB: build VPC file of commands on the USB memory stick (VPC.BAT) Action tab of the page.

4.4.8 Shutdown VPC-Client

At any time, double-click on the client device's title bar to close the corresponding COUNTER network
connection. As shown below:

You can also directly shutdown the VPC-Client software and close all COUNTER connections.

4.5 VPC-Client Operations

4.5.1 Counter Parameter

Counter Parameter menu for Image Processor settings to achieve the best effectitive.

4.5.1.1 Time Set

Under Counter client device network connection status, the client will automatically be read once per second
Counter current time, so the client interface can see the time is kept beating, when the time does not
automatically jump, may be a network disconnected or the clock chip is damaged;

1. Get Time

Press Get Time button, you will get the date and time of VPC. Format: YYYY-MM-DD HH-MM-SS.

2. Set Time

Xiamen Sunford Industry&Trade Co., Ltd. 74 / 157


Press this button, It will be synchronize date and time of the connected computer to the VPC. Please adjust the
computer time if the computer time is not accurate. The format is YYYY-MM-DD HH-MM-SS.

4.5.1.2 Local Network Configuration

The "Counter Network Config" in "VPC parameters" allow you to change network settings for VPC. Click "Read
Network Param" button to get current information, and then modify the parameters on the basis of current
information, then click "Save Network Param" button, VPC automatically restart and new addresses take effect
after restart. Before you modify the network parameters to ensure that no conflict with existing IP addresses
on the network

Figure 71. Counter Network configuration


1) Counter IP: The IP address of VPC.
2) Subnet mask: The VPC IP address subnet mask.
3) Gateway: The VPC gateway .If VPC to visit other segment of the computer need to set up the
gateway address
4) Port: TCP/IP port for external connections
5) Username: Login VPC with username. The maximum is 32 characters.
6) Password: The maximum is 32 characters.
7) Counter Name: Defaults is VPC, you can name it as you like. The maximum is 32 characters.
8) MAC: the current VPC Network NO., it is read-only.

Get Network Param: Read the VPC network parameters.

Set Network Param: Save these parameters value to the VPC. Restart after change and need to use the new
parameters such as IP to land and connect.

4.5.1.3 Export Param File(.DSP)

Click this button will save currentVPC parameters including all parameters and generate one XXXXXXXX.DSP
file.( XXXXXXXX is the VPC MAC address).

This parameter file can be open using VPC-Client.exe and can import another VPC.

Xiamen Sunford Industry&Trade Co., Ltd. 75 / 157


4.5.1.4 Import Param File(.DSP)

Save all parameters in XXXXXXXX.DSP file to current VPC. If you change the counter, you can use this
function, and you may not setting the parameters in the new VPC.

4.5.1.5 Restore factory setting

This button can put the VPC all the parameters set back to factory default value. This operation will not delete
the VPC records. Click on the "Restore Factory Setting" button, hear the sound "3 + 1 short chirp ", this process
takes about ten seconds, said factory default success. Login again need to use VPC factory default network
Settings information. Once done restore factory default operation, the following items will be returned to the
factory default, please reinstall according to situation.

Network Settings Detect Param GPIO RS232/RS485 Others


Username: WorkingTime: GPI1-GPI4: Bandrate: BK Image:
admin 00:00:00-23:59:59 All is disable 19200bps None
Password: Derection: GPO1/GPO2: Data bits: MinObject:
123 Up is IN, Down is OUT 200ms None 5000
IP: CameraHeight MaxObject:
192.168.1.111 225cm-230cm 8000
Submask: Line1: VotedOut1:None Shelter:
255.255.255.0 80 VotedOut2:None 90%
Gateway: Line2: Height:
192.168.1.0 208 225-230cm
DetectArea:
Port:8000
Full
Direction:
CounterName:
Up is In and
VPC-1
down is out
Note: The Camera parameter file does not change, only need save background again.

4.5.1.6 Restart counter

When press restart counter, we will hear one beep, the software of VPC-client will disconnect and then
connect again. And all the parameter wont change, the value of IN/OUT will continue to the value of the last
time .

4.5.1.7 Update the firmware

1. Update Main Firmware (.BIN)

If you have the VPC new Main Firmware, you can use this function to update the newer firmware. It need
about 60seconds. In the updating progress, the connection will be disconnected for a while, and connected

Xiamen Sunford Industry&Trade Co., Ltd. 76 / 157


automatically. Update the firmware program does not change the saved parameters, including the network
parameters and the background image.

Warnings:

In the process of update firmware, please ensure the power supply, the internet is connect, no
electromagnetic interference source near. Otherwise the update will fail or the VPC will be
damaged, and the VPC can't work normally. If the upgrade failed, VPC can't restart, please see
the file start to backup system, carries on the recovery

2. Update Backup Firmware (.BIN)

Update the backup system means update the backup system software. There are some products without
backup system in VPC series. Through the network to upgrade backup system firmware program, can make its
have backup system, easy to maintain in the future. Or, when we think it is necessary to issue a new backup
system software, will be released to the customers to update.

4.5.2 Server/Video

This tag is used to view\set server network parameters and view real-time video.

Xiamen Sunford Industry&Trade Co., Ltd. 77 / 157


Figure 72. Server/Video surface chart
4.5.2.1 GPRS Server Config

This is for the type VPC-GGM, which has a GPRS and GPS module inside, that can send the data to Server.

Please see this article VPC-GGM Version.

4.5.2.2 RJ45 Server Config

Server IP: Counter current data is sent to the computer's IP address in the local network, the Server received
all VPC records, such as SF-PC- Server.exe.

Port: central server software running on the computer where the router port mapping, the default of 6000.
Make sure there is no firewall software to disable the port number and the port number is not occupied by
other software.

Counter No.: Counter is a unique number in the LAN, the range of 1-65535. The default value is 1.

RJ45 Resend: Enable / disable LAN recording retransmission, the default value is enabled.

Note: check the port 6000 using or not:

Run cmd, input netstat aon|Findstr6000 , if you find the 6000 port in the cmd windows, it shows the
6000 port is using now.

4.5.2.3 Real Time Video

Real Time Video is the Left Original View of the current channel, and in the image shows tracking, counting
process of people into/out of channel.

Local IP: The computer IP address which the VPC-Client.exe in. It cannot be modified. Please run the
VPC-Client while ensuring only ONE IP address in this computer.

Port: The port of the computer connected the VPC.

Xiamen Sunford Industry&Trade Co., Ltd. 78 / 157


Video Type: Show this current channel video type, you can choose the Left or right of this current
StereoCamera.

DrawCounInfo: Show the counting information in the real video, include object rectangular box, Line 1, Line 2,
in and out counting numbers.

Enable this function, there are some information in the Video Output2, such as object tracking line,
Counting-Line1/2, counted objects will change red tracking-line. When Video Output 2 has been choose 4 In
1, refresh All Pictures, there are some draw information in the left image, such asIn:29, Out:18 etc..

Note:
One connection can be created between one computer and one VPC.

One VPC only create one real time video connection.


Min Obj: Set the minimum target value of real-time image per frame, unit is pixels. Min obj Should be set to
a value less than the frame that one people pass, such as when a person passed, its 10 consecutive frames
between the minimum value of the image is 7000-15000, 5000-6000 is recommended that you set the
minimum target value. The default value is 5,000 (The whole screen total is 360*288=103,680 pixels).

Max Obj: The maximum pixels of every object in each frame. The default is 8000. (Need no modify)

In order to set up a more accurate pixel size of actual people and filter interferential image, the software
provides real-time display the pixel size of one persons head size (minimum target) and all profiles (maximum
target), makes it easy for users to observe and set. Note that if two people appear simultaneously, client will
only display minimum and maximum goals pixels of the first occurrence of person.

Create/Stop Socket: Create or socket connection with the VPC. After created, the button become Socket,
you can disconnect the socket connection by click or colse the VPC-Client.exe.

Show Video: Show the real time video in the windows.

Close Video: Close the real time video in the windows.

Video Option: Record Video frame, form 1 to 25 frame per second (FPS).

RecordVideo: Enable this selection box, you can record the video to a file.

Xiamen Sunford Industry&Trade Co., Ltd. 79 / 157


Figure 73. Record Real Video
4.5.2.4 Video output 1/2 settings

In VPC back panel, there are two video output BNC connectors. You should configure them in VPC-Client first,
Then the Counter will restart. Default is 4 IN 1 in VideoOut 1 and None in VideoOut 2.

Figure 74. Video Output Configuration


1. Video Output1/2 Settings

Video Output1:

4 In 1: Include two StereoCameras four original videos output in one four-quad (without any OSD).
None: No video output.

Video Output2:

CH1 Left Video: Video out with channel 1 left camera.


CH2Left Video: Video out with channel 2 left camera.
4 in 1: Include two StereoCameras four videos output in one four-quad (with OSD).
None: No analog signal video out from the VPC.

Xiamen Sunford Industry&Trade Co., Ltd. 80 / 157


Figure 75. VideoOut 1 and VideoOut 2 @4 IN 1

Note:

After changing Video Output2 in the list, the VPC will automatically restart within 10 seconds.

The video output 1: 4 in 1 is set in the program, so we cant change it.

The video output 2: there are several selections. The default is none. If we select 4 IN 1, it will restart the
VPC, and when refresh the image, we can see the image like the picture .Thus we can see the status of the
doors and whether the VPC is running.

If you select debug mode, when you connect the output to one display device, you can see the detect image,
like the picture:

4.5.3 Detect

Detection Parameters tab, all press channel 1 and 2 are provided, respectively, valid for the current channel.
Depending on the VPC models can not function display.

Xiamen Sunford Industry&Trade Co., Ltd. 81 / 157


4.5.3.1 Working Period

We can set the working time, when over the time, the VPC wont count.

4.5.3.2 Automatic Restart

Counter set daily scheduled reboot time.

Enable: and set the reboot time.

Disabled: Do not enable Counter daily scheduled reboot function. Set 25 in hour blank, it means disable.

4.5.3.3 IN/OUT Direction

In or Out direction depends on your definition. There are two directions:

From image bottom to image top, use Line 1 and Line 1 Starting Point to judge counting.
From image top to image bottom, use Line 2 and Line 2 Starting Point to judge counting.

From left to right movement and conversely in the image is not be counted.

Changing the direction value, the three counters will be exchanged the IN and OUT numbers automatically.

Xiamen Sunford Industry&Trade Co., Ltd. 82 / 157


4.5.3.4 Line 1/2

Line 1 functions: It will generate a counted number when a person appear near the bottom of the image and
move to the top the image and across the Line 1.

Line 2 functions: It will generate a counted number when a person appear near the top of the image and move
to the bottom of the image and across the Line 2.

Line 1 and Line 2 ranges are 0-288 pixel. If the Line 1/2 value is set to the line near the edges of the image will
cause does not count.

You may choose the Line 1/2 position by using the mouse click the left image. Please choose the Draw button,
then click.

4.5.3.5 Line 1(/2) Starting Point

Line 1 Starting Point is to set a Y coordinate value is greater than Line 1 Y-coordinate value in the image. After
this point with a line parallel to the image edge is divided the image into upper and lower two rectangular
areas. Does not contain Line 1 rectangular area (the lower half of the image) is defined as Target Appear Area
of Line 1. When a person appears from the Target Appear Area of Line 1, and then across the Line 1, Counter
will produce a count.

Line 2 Starting Point is to set a Y coordinate value is less than Line 2 Y-coordinate value in the image. After this
point with a line parallel to the image edge is divided the image into upper and lower two rectangular areas.
Does not contain Line 2 rectangular area (the higher half of the image) is defined as Target Appear Area of
Line 2. When a person appears from the Target Appear Area of Line 2, and then across the Line 2, Counter will
produce a count.

Valid target: the person target block center, must appear in the Target Appear Area of Line 1, will participate
in the judgment of the counting rules.

The range of Line 1 Starting Point: 0-288; typically set Y coordinate values of Line 1 plus between 80-120. The
default value is 208.

The range of Line 2 Starting Point: 0-288; typically set Y coordinate values of Line 1 minus between 80-120.
The default value is 80.

Xiamen Sunford Industry&Trade Co., Ltd. 83 / 157


Figure 76. Line 1(/2) Starting Point
4.5.3.6 Detect Area

VPC image size is 360 288, the coordinates of the image is (0,0), (360,0), (0,288), (360,288). Default value of
the detection area is full screen, ie left: 0; right: 360; on: 0; follows: 288.

The purpose is to set the does not detect the left and right area from watching the image is people get in and
get off through its center must be avoided in the does not detect area, otherwise the situation will count
missing.

The purpose is to set the does not detect the top and bottom area from watching the image is avoided the
door interference.

But, the no-detection-area could not be set too large, it will happen missing counting.

If the left margin is set to 20, the right margin is set to 340, it means that within the detection area (20,0) to
(340,288) of the rectangular area, namely blank portion in the figure below; no detection area is on both sides
of the ramp line portion, as shown below:

Xiamen Sunford Industry&Trade Co., Ltd. 84 / 157


Figure 77. Left and Right no-detection-area
4.5.3.7 Min/Max Objects

Min Object: The detected objects pixels. Less than the pixel will be ignored. The default value is 5000, if
missing passengers happened, you can set it 3000 or 4000.

Max Object: The default value is 8000.

These two value can accord to the Min Obj and the Max Obj in the Real Time Video at Server/Video
table.

4.5.3.8 Installation Height

According to the installation height to choose this value.

4.5.3.9 Ignore Height

According to you want ignore none counting height from the ground, you can choose the value. The default
value is 120 cm.

4.5.3.10 Closed Door Rules

The default value is Enable.

When enable the Engable CloseDoor Counting Rule, when people get in, when the door is closed, people
remaining anywhere in the detection area will be counted as IN. The counter will be amended accordingly.

When the door is open, every person already within the door threshold line (line 1) and the portion of
detection area facing the doors, will be counted as OUT if they leave the detection area, again, the counter will
be amended accordingly.

Xiamen Sunford Industry&Trade Co., Ltd. 85 / 157


When Engable CloseDoor Counting Rule is disable, When people get in, the the protion of detection area
facing the doors have not crossed the Line 2 will not count as IN. When people get out, the the protion of
detection area facing the doors have not crossed the Line 1 will not count as OUT.

4.5.3.11 Door line

Door line is defined a position line under 1 meter of the door closed, it is using for avoid wrong counting by the
door movement interference. Door line is different from the detect area, it is only effective during the door
open or closed 1-3 seconds.

Door Interfere Area: The rectangle area between the door line and image edge of near the door.

Figure 78. Door Interference


When door open or closed, the object in the Door Interfere Area will not be counted, see the yellow area in
the following picture:

Figure 79. Door Line And Door Interfere Area


4.5.3.12 Buzz

Enable or disable buzz beep when VPC-Client to operate it.

4.5.3.13 *Overload Alarm

Some type of VPC has this functions.

Alarm Numbers:
Period after Door Opened:
Period After Nobody In Area:

Xiamen Sunford Industry&Trade Co., Ltd. 86 / 157


4.5.3.14 Save Background Image

Each channel (StreroCamera) have a static background image depth of its independent scene. So the need for
channel 1/2 were preserved in order for all normal channels 1/2 and accurate count.

Static background image is an image height values describe the scene no one moving object or when. It would
have been recorded in the VPC, or restart after each boot will be with real-time background updating
continuously updated and changed and saved.

Click the button to save the background image will pop up prompt window:

Choose Yes, depending on the network situation, about 10-20 seconds, VPC will sound / light tips saved
successfully.

When update or change the Camera parameter . we should save the background, or the VPC wont count.

Note:

1) Camera ID is corresponding to the real connected.


2) Left lens image (near the IR Sensor) shows on the left image of the VPC-Client window.
3) Make sure door opened.
4) Make sure nobody under the Camera.
5) We suggest save the background at daytime, because the light is enough. When save at night ,please turn
on the light on the bus .
6) When finished, the Background windows will be the real height value using grey pixel. the Detect
windows will be a pure darkness windows.

Figure 80. GOOD Background and Detect Image


Judge Background Image:

1) One good background image: you may see the high or low objects in the scene through the grey value,
the brighter parts represent higher object, the black parts represent low object.
2) One good detect image: it should be pure darkness when there is none object or person under the
camera.
3) If one person stand under the camera, it should have many layers in the image.

Xiamen Sunford Industry&Trade Co., Ltd. 87 / 157


4.5.3.15 Update Camera Parameter File

Look into the Camera glass , and we can find a serial number, each Camera has the related parameter . When
press the button,and select the related parameter (-8t14), the VPC-client.exe will disconnect and reconnect .
Then login again, you will find the whether the parameter is updated.

Channel 1 Camera ID is the AIR OUTLET A connected camera ID.

Channel 2 Camera ID is the AIR OUTLET B connected camera ID.

Figure 81. Camera ID in AIR OUTLET A is Channel 1


4.5.3.16 Get Detect Parameters

VPC-Client get all the detect parameters from the Counter.

4.5.3.17 Set Detect Parameters

VPC-Client save all the detect parameters to the Counter.

Xiamen Sunford Industry&Trade Co., Ltd. 88 / 157


4.5.3.18 Counting system Disparity Map

Xiamen Sunford Industry&Trade Co., Ltd. 89 / 157


4.5.4 IO and Record

4.5.4.1 GPI Settings

Depending on the hardware version and the factory configuration, VPC has a 1-8 GPI.

When GPI properly connected external signal (see "2.5.5 GPI" and "3.2.5 GPI access switch gate signal" section
of this article), please use the following features need to be set.

Xiamen Sunford Industry&Trade Co., Ltd. 90 / 157


GPI 1~4 is Voltage Level Input , GPI 5~8 is Switch Input.

1. Disable:
VPC will ignore the GPI signal received on the input line.

2. Test:
Allows the operator to test the four GPI input lines:

3. Reset CH1 Counter:


Channel 1 Counter reset after get the GPI input signal.

4. Reset CH2 Counter

Channel 2 Counter reset after get the GPI input signal.

5. Channel 1 Start/Stop Counting

Channel 1 start/stop count after get the GPI input signal.

6. Channel 2 Start/Stop Counting


Channel 1 start/stop count after get the GPI input signal.

4.5.4.2 GPO Settings

Depending on the hardware version and the factory configuration, VPC has a 0-4 GPO. The different firmware
version, the function maybe different.

When GPO properly connected external signal (see "2.5.6 GPO" and "3.2.6 GPO output" section of this article),
please use the following features need to be set.

Figure 82. GPO Settings

Xiamen Sunford Industry&Trade Co., Ltd. 91 / 157


Disabled: The GPO is disabled, could not happen Change Status Output.
Test: Test the GPO is normal.
CH1 IN: People IN occurs, the GPO will happen Change Status Output.
CH1 OUT: People OUT occurs, the GPO will happen Change Status Output.
CH1 IN/OUT: People IN or OUT occurs, the GPO will happen Change Status Output.
Overload Alarm: When Total Number is greater than settings, the GPO will happen Change Status
Output.
Delay Period: After an event happened, the GPO need delay this period, then will happen Change Status
Output.
Status Period: The Period of the GPO will happen Change Status Output.

4.5.4.3 GPIO Test

This is for test the hardvare . If we set the GPI 1 is high voltage ,function select test, and we input the high
voltage to the GPI ,then we press the GPI 1 Test , it will turn gray.

When the function select test, press the GPO test , we can hear one beep.

When Choose this function, you can click the GPO1Test button, the right box

will be fill full with the grey, like this: .

4.5.4.4 Serial Ports Settings

We can send commands through a serial port tool, the commands are in chapter4.

Baud Rate: default is 19200bps

Send ral time: as long as the Counter generate a record, it will send by serial port.

Record Resend: Retention.

4.5.4.5 Records Operations

1. Download Records:

Xiamen Sunford Industry&Trade Co., Ltd. 92 / 157


1) Click the Get All Record Number button, there is a total numbers appear, here is 1429 in figure.
2) Choose download way: by Numbers or by time period.
3) Click the Download" button, choose the path and file name, waiting for downloading.

2. Erase Records:

When we want to get records or erase all the records. We can press get the records first ,then press
download or erase. If press the erase button, the VPC-Client.exe will disconnect and then reconnect
again. VPC can save 122880 records .

Erase all the records can not be recovered.

3. Record File of Download

Figure 83. Download Record File

No. Item Description


1 ID NO. From 00000 start
2 DATE DATE fromat:XXXX_XX_XX
3 TIME TIME format:hour:minute:second
4 TYPE Channel
5 IN Incoming number
6 OUT Outgoing number

There are "record number", "date", "time", "type", "Enter", "out" (longitude, latitude, speed) and other fields
in the records file.

1) Record Number: 00000 increments from without GGM module versions, each recording information
accounted for 16 bytes, can save up to 122,880 records, so the record number of up to 122 879;
With GGM module versions, each recording information accounted for 32 bytes, can save up to 61,440
record, so the record number of up to 61399;
2) Date: Emergence of this record / month / day;

Xiamen Sunford Industry&Trade Co., Ltd. 93 / 157


3) Time: When this record produced / minute / second;
4) Type: See the following "Data Type Description";
5) IN: CH1 and CH2, respectively, the total number of accumulated entry, after restart or execution counter
COUNTER cleared the operation, the number will begin to accumulate from 0;
6) OUT: CH1 and CH2, respectively, the total number of accumulated out, after a reboot or execution
counter VPC cleared the operation, the number will begin to accumulate from 0;
7) Longitude: GPS positioning equipment to where the vehicle is currently located longitude;
8) Latitude: GPS positioning equipment to the current vehicle location latitude;
9) Speed: vehicle speed, unit: miles / hour;

Note: Only with GGM module VPC only longitude, latitude, speed.

4. Records Types

See the 10.4.5 Get record total number in this article.

Xiamen Sunford Industry&Trade Co., Ltd. 94 / 157


4.5.5 USB Disk operation

Note: No USB function from the Hardware V2.0.6

Except we offered TCP/IP network connection to control counting processor, we also offer USB Operation
Mode to control counting processor.

Use USB disk please make sure USB is FAT32 file format.

Download records into USB Disk

Xiamen Sunford Industry&Trade Co., Ltd. 95 / 157


USB disk offer two different ways to download records , by date or all records download.

When finished select then Click and select USB Disk directory that in

your USB disk will generate VPC_SYS.BAT batch command file and XXXXXXXX.REC records file automatically.

Note:

Before you download into USB Drive ,please format the U disk into FAT32 file format.

Do not rename or change the contents in file :VPC_SYS.BAT

Put USB Disk into processors USB port will trigger 3beeps represent USB Disk detected and 20 beeps means
records in download situation. In USB Disk will generate XXXXXXXX.REC file.

Exchange file (.REC .TXT)

Transfer USB Disk record format XXXXXXXX.REC into XXXXXXXX.TXT test file , can open in
PC directly

Clear all record

Select Clear all record then Click Write order to U Disk ,all the records in counting processors will be
deleted. This operation will occur 3 beeps then 20beeps about 10seconds means finished operation.

Get counter devices parameter back to us (.DSP)

Xiamen Sunford Industry&Trade Co., Ltd. 96 / 157


Select Get counter devices param back to us (.DSP), the counting processors data and status will download
into USB Disk and generate XXXXXXXX.DSP file.

You can send this XXXXXXXX.DSP file back to us and we can check the processors situation and offer further
technical support to you.

Update hardware Parameters

Factory will follow XXXXXXXX.DSP file to modify all the hardware parameters then send back to user and
user can use our Update .. functions to correct hardwares parameters via USB Disk.

Note:
. IVPC_PRM.TXT : Counting devices parameters
IVPC_NET.TXT : Network parameters
XXXXXXXX.CP1:must be Channel 1 Cameras parameters
XXXXXXXX.CP2:must be Channel 2 Camera parameters
Channel 1 and Channel 2 Cameras ID can not mix up,otherwise, USB disk can not recognize

Xiamen Sunford Industry&Trade Co., Ltd. 97 / 157


5 Application
VPC has multiple firmware versions to fit supports the following applications:

Figure 84. VPC Applications Figure

5.1 GGM
Built by GGM module and server connections, deliver real-time record in the database. For more information,
see "VPC-GGM version" section of this article. Communication protocol, refer to the section "GPRS client
network communication protocol" herein.

SF-VPC-Server-GGM.exe server software for the VPC-GGM and VPC-MG-GGM firmware.

5.2 Serial Ports


On through the serial port (RS232 or RS485) transmit real-time recording to a connected serial devices, such as
DVR, or GPS device. According to demand, there is connection scheme "push mode", "pull mode" or "push-pull
mode" are three more information, see the section of this article serial protocol and "VPC with DVR docking
solutions." Communication protocols, refer to the section "RS232 and RS485 serial protocol" herein.

5.3 GPO output


Counter can be set to detect a person to enter, when the output signal level mode switch or to other devices.
For more information, see the section of this article client software.

Xiamen Sunford Industry&Trade Co., Ltd. 98 / 157


5.4 Ethernet Connection
In buildings and other applications, you can use the LAN connection, and out of the number of multiple
Counter records transmitted to the server in real time.

Figure 85. Local Ethernet Connection


If the customer would like to develop their own server, depending on application requirements, connectivity
options are "push mode", "pull mode" or "push-pull mode" three kinds, see "counter and DVR docking
schemes Recommendations" document. The communication protocol details, please see the "client network
protocol" and "server network protocol" section.

SF-VPC-Server.exe server software is available for all firmware RJ45 network port of the server software,
regardless of whether with GGM Counter module.

SF-PC-Server software is a server program based TCP / IP protocol, each VPC counter are the client, the server
program to get real-time record of all LAN VPC produced the record written to the database . The server
software can only receive the records of VPC in the same LAN (same segment, such as 192.168.1.xxx).

SF-VPC-Server.exe server software is available for all firmware RJ45 network port of the server software,
whether with GGM module.

Client software settings, see the section of this paper, the client software "RJ45 Server Settings" section. Server
software to participate in the following documents:

1. "SF-VPC-Server Server Software User's Guide":

2. SF-VPC-Server.exe server software

3. SF-VPC-Client.exe set terminal software:

Xiamen Sunford Industry&Trade Co., Ltd. 99 / 157


4. SF-Report.exe reporting software:

5. "SF-Report Database Structure Description": for customers to develop their own statistical reporting
software.

5.5 SMS
If VPC built GGM module, it can in real time some of the overcrowding and alarm information is sent to a
designated phone number via SMS text message. Note that this approach may cause SMS charges. This feature
requires customization.

5.6 Multi-Door
In three or four or more doors of the car, you may be more than one Counter (up to eight) is connected via a
LAN together (two Counter can be directly connected to the network cable without switch), through the main
equipment GGM module, all up and down the number of recording channels of real-time counter and sent to
the server. For more information, see "multi-door version of the legend" section of this article.

5.7 Wide-Gate
At the door width exceeds 150cm scenario, multiple Cameras are lined up to detect a wider channel the flow
of people. Counter supports up to 16 stations and 32 StereoCameras. For more information, see "wide doors
Release Notes" section of this article.

5.8 Analog Video Output


VPC's CVBS analog video output is equivalent to an analog output of the Camera is connected to the monitor
with CVBS display or the DVR for recording. Image content is about two StereoCamera image four split screen
(four pictures). For more information, see the section of this article client software.

Xiamen Sunford Industry&Trade Co., Ltd. 100 / 157


6 VPC-GGM Version
SF-GGM module is designed for SF-VPC series counters with GPS and GPRS functions module. When the VPC
increase the SF-GGM module, the VPC can automatic send the GPS geographic information the passengers
records to a computer in the internet via GPRS.

SF-GGM module support Quad-Band 850/900/18001900MHz.

The VPC back panel and front panel as the bellow after add SF-GGM module. Increase two antennas and one
LED light.

(Figure 36:VPC with GGM Module)

6.1 Device Type of VPC with GGM


Counter Info shows Device Type is VPC-GGM. (Or VPC-21V-GGM according to the VPC type)

6.2 GGM module Installation

6.2.1 Install Module

Since SF-GGM is an optional module, It connect the VPC board via a 10 Pins connector. It needs two
11mm-coppor-hole and four M4 screws to fix it on the VPC board.

Xiamen Sunford Industry&Trade Co., Ltd. 101 / 157


(Figure 37:GGM Module)

Note:

If you need to adjust the 8-DIP, you need to remove the SF-GGM module first.

6.2.2 Connect Antenna

SF-GGM module need correctly connect own antenna before it working. The inner two antennas of the VPC
are as bellow. And the antennas out of the VPC box, you must connect right.

Figure 86. GGM Module Antenna connection diagram

6.2.3 Install SIM for GGM Module

Installing the SIM card dont need to open the VPC housing. Just card-core side is facing down, the triangle
angle deficiency side of the SIM is inside , then install the SIM card and lock. As shown in Figure:

Step 1: Look for SIM slot in the back panel of VPC

Xiamen Sunford Industry&Trade Co., Ltd. 102 / 157


Figure 87. SIM Slot
Step 2: Insert the SIM card carefully, note the card direction.

Figure 88. Insert SIM Card


Step 3: Use finger to jog once after you insert the card and feel card has a rebound, the work is complete.

Xiamen Sunford Industry&Trade Co., Ltd. 103 / 157


Figure 89. SIM Card Installed

6.3 Serial Port function declaration for VPC with GGM


Because the VPC-GGM has added GGM module, the serial ports(RS232 and RS485) of VPC-GGM has been
occupied by the GGM module, so these two serial port can not received command anymore. They just both
can send real time records. User can receive these data by using other device, such as a LED-Screen

Figure 90. LED display the number of the people in the vehicle

6.4 VPC-GGM Software Setting


After inserting the SIM card to the SF-GGM module into the SF-VPC-2xV, the VPC_Client.exe software must be
correctly set to make the module work and send data to the right place.

Running the VPC_Client.exe software, log on correctly, you can the Device Type will appear VPC-GGM in
the Counter Info. Figure:

Xiamen Sunford Industry&Trade Co., Ltd. 104 / 157


If the Device Type is not VPC-GGM, please update it first or contact us.

In the VPC_Client.exe, we must set the "Server/Video" and "IO/Record".

6.4.1 Server Video Settings

In Server/Video tab, Server Config is setting the network parameters of the computer receiving data from
GPRS with the fixed public IP address.

(Figure 43:Center server setting diagram)

In VPC_Client.exe setting interface, set the "Server/Video" as bellow:

Server IP: There is a fixed IP address of a server to receive the data; all Counter records and GPS data in
this VPC will send to the server address through GPRS. And the server should be install a software to
receive these data. such as our SF-PC-Server.exe softwart.
Ports: a fixed IP address of the server's port, the number is fixed at 6000 (make sure the server's 6000
port is not occupied)
Counter No.: Counter current distribution number.
After setting, click the "Save a Server Net Param" button to save the settings

6.4.2 GPS/GPRS Settings

In VPC_Client.exe setting interface, set the IO/Record as bellow:

(Figure 43: GPS/GPRS setting diagram)

APN: Access Point Name. You can ask your local GSM SIM card supplier. (The maximum character is 64.)
APN Name: You can ask your local Mobile supplier. The maximum character is 32.
APN Pass: You can ask your local Mobile supplier. The maximum character is 32.
GPS Upload: You can choice Enable or Disable.

Xiamen Sunford Industry&Trade Co., Ltd. 105 / 157


Enable: Each GPS Upload Rate time, the VPC will send one record to the Server computer, but it
will use GPRS flow.
Disable: This will shut down the sending GPS record to the Server computer.
GPS Upload Rate: The frequency of GPS data upload to the server per second of you set. The default is 30
seconds. The maximum value is 65535 seconds.
GPS Record Save Rate: Set how often to generate a GPS record and save to VPC. The default is 10
minutes. You can also set 0 to do not save the GPS data to the record. The maximum value is 65535
minutes.

6.4.3 Upload GPS Data

Note:

Only when VPC obtain the two doors are both CLOSED, the GPS data will be uploaded to SF-PC-Server.exe or
other software user developed..

About obtaining doors status, see <<SF-VPC Manual>>

Test GPS data upload, do as the bellow:

1. The factory setting of GPI1 and GPI2 is Switch, means the 3rd and 4th in 8-DIP switch are ON position.
If not, please set to ON position.
2. Setting VPC-Client.exe

Figure 91. VPC client setting diagram

Form 15. Open/Close door signal setting diagram


Mode Status Function
Channel 1/GPI1 Switch Colse CH1Start count
Channel 2/GPI2 Switch Colse CH2 Start count
Note: These setting means: The signal of the two doors ( Channel 1 and Channel 2)

3. Make sure the GPI1 and GND are disconnected, and the GPI2 and GND are disconnected too.
4. The GPS data will send to SF-PC-Server.exe as you set time interval.

6.4.4 Check Settings

6.4.4.1 Indicator verification

(Table 7: GGM module LED diagram)

Function Red LED Green LED 1 Green LED 2 Green LED 3 Buzzer
Lights on 100ms
GGM Unnormal Lights On / Interval 100ms / /
Interval 5S(Can be set*)

Xiamen Sunford Industry&Trade Co., Ltd. 106 / 157


Light on100ms
GGM Normal and Lights on 100ms
Lights On / Interval 100ms /
GPS Signal Reliable Interval 2S
Interval 5S(Can be set*)
Lights on 100ms
Interval 100ms
GGM Normal and Lights on 100ms
Lights On / Lights on 100ms /
GPS Signal Unreliable Interval 2S
Interval 100ms
Interval 5S(Can be set*)
Note: * Means GPS Upload Rate in VPC-Client.exe you have set.

6.4.4.2 Verify Connection

Run the SF-PC-Server.exe in the having fix IP address server computer.(Please ensure you have installed the
database software first, you can reference our <<SF-PC-Server.exe Manual>>). When the SF-PC-Server.exe
shows the VPC information in the windows, it is show you have set correctly. Figure:

(Figure 46: VPC connect information diagram).

Note, when each power on, the GPS start is Cold-start, the time of searching satellite is often long, usual
need 50-60 seconds. If the GPS signal is bad, the time is longer. And, maybe some initial records when VPC
started have not the GPS data (Longitude Latitude, Speed) in it.

6.4.4.3 Verify Upload Data

About how to inquiry and verify the records using database or SF-Report software of each VPC connected the
SF-PC-Server.exe, please reference our<<SF-PC-Server.exe Manual>> and <<SF_Report.exe Manual>>.

6.5 Records Format


The records format of the VPC-GGM as bellow, each record has added Longitude Latitude, Speed data:

The record of VPC has 12 byes, the VPC-GGM has 32 bytes after adding 20 bytes of GPS data. The adding 20
bytes as bellow:

GPS Data Latitude Latitude Latitude LongitudeLongitudeLongitude Speed Speed Server


Reliable (Integer) (Decimal) Direction (Integer) (Decimal) Direction (Integer) (Decimal) Feedback
Flag Flag
1 Byte 2 Byte 4 Byte 1 Byte 2 Byte 4 Byte 1 Byte 2 Byte 2 Byte 1 Byte

Xiamen Sunford Industry&Trade Co., Ltd. 107 / 157


.TXT file format of VPC records:

There are more three part of the records within VPC-GGM

Latitude format: N-North Latitude, S-South Latitude.Deg Deg Minute Minute. Minute Minute Minute Minute
Minute Minute

Longitude format: E-East Longitude,W-West Longitude, Deg Deg Minute Minute. Minute Minute Minute
Minute Minute Minute

Speed Format : kilometer/hour

6.6 GSM Protocol

6.6.1 Protocol Brief

Form 16. Network communication protocol description table


No. Content Description
1 By TCP session Verify command reliable transmission
2 Default TCP port:8000 User define ,better more than >32768
3 Default IP address: 192.168.1.111 Can be modify by user
4 MAC: as 0X0123456789ab The MAC usually use ID of encryption chip, its unique
for the chip .user can modify the MAC.
5 Mask:255.255.255.0 Can be modified by user
6 Default gateway:192.168.1.1 Can be modified by user

6.6.1.1 TCP/TP Data Package Structure

6.6.1.2 HeartBeat Package Structure

1. SF-VPC-GGM -> Computer:

VPC MAC Counter ID Reserved Identifier 1 Identifier 2 GPS Data


6byte 2byte 3byte 2byte(FFFF) 2byte 20byte
1) When Identifier 2 is 0xFFFE, there is not GPS data in this package.
2) When Identifier 2 is 0xFFFF, there is GPS data in this package.
3) Computer Send Feedback Command:

Xiamen Sunford Industry&Trade Co., Ltd. 108 / 157


Heartbeat Package Feedback
12byte("heart beat")
4) GPS Data Package structure:

Effectiveness of Latitude Latitude Latitude Longitude Longitude Longitude


GPS Data Identifier (Int.) (Decimals) Identifier (Int.) (Decimals) Identifier
1byte(A,V) 2byte 4byte 1byte(S,N) 2byte 4byte 1byte(E,W)

Speed
Speed(Int.) End Identifier
(Decimals)
2byte 2byte 1byte(FF)
GPS Data is Effectiveness when GPS Data Identifier is A.

Sample of GPS Latitude, Longitude, Speed Specifications:

Char strDouble[20]

Memset(strDouble,0,sizeof(strDouble));

sprintf(strDouble,%d.%d, Integer,Decimal);

double I = atof(strDouble);

6.6.1.3 Record Data Package Structure

1. VPC -> Computer:

MAC VPC ID Reserved Identifier 1 Record Data Identifier 2


6byte 2byte 3byte 2byte(FFFF) 55byte 2byte
2. Computer Send Command
1) SF-GGM Version :

Command Head Record ID CRC


1byte(0x06) 4byte 0-4 ^
2) SF-MG-GGM Version

This is Multi-Gate with GGM module

Length VPC ID Record ID CRC


0x06 2byte 4byte 0-6 ^
Note:

When VPC ID is 0x0505, the current counter is Master Counter (The ID is 0) in Multi-Gate Version.

3) Record Data Structure:

Package head Record ID Type Date IN Out GPS Data CRC


4byte(0x93 0x25 0x31 0x30) 3byte 1byte 5byte 3byte 3byte 20byte 1byte

6.6.1.4 GGM Resend Machanism

When GPRS lost or have no signal, counter and Server communicate will lose data, or the data received is not
enough. To ensure the record data hasnt been send out and the record data is not enough, add GPRS data
resend mechanism in this model.

Xiamen Sunford Industry&Trade Co., Ltd. 109 / 157


Using 32 byte to keep every record of GGM, using the last type mark whether the center server have received
this record or not:

Every record send by device received successfully by the server will resend the received record no (Such as the
device sends 100 records to the server, if server received, it will resend 100 to the device). When device
received the feedback from server, it will write 1 according to the last byte of the record no (such as 100), then
this data transfer has been finished.

After counter transfer data to Server, the counter will automatic search the record in the current flash.
Counter initiate the timer, resending mechanism every 5 minutes, researching the records in the flash. Counter
1 frame search one record, equal to one second search 20 records. Once searching the record has no feedback
it will send it out, until all the records receive the feedback from center server.

6.7 Condition when send more data:


1) After sending the data to server, the server feedback data lost or data fault, which lead to send
more data.
2) When start resend, it will produce new record data. Before new record receive the feedback from
the center sever, it search the location of the new record, at this time this record has not received
the feedback from center server, it will resend the data record.

VPC received the feedback from server, when write the last byte of record, the flash fault will also lead to
record send more. This condition is less.

6.8 GGM send data communicate protocol

6.8.1 Client type no. Define as below:

Form 17. Client type table


ClientModuleType Name No. Remark
VPC-Rule.exe 0
IVS intelligent video analysis 1 Reserve
Rule setting management 2 Reserve
Alarm processing end 3 Reserve
IVS image processor 4 Reserve
VPC people counter 5

Xiamen Sunford Industry&Trade Co., Ltd. 110 / 157


6.8.2 Communicate type:

Figure 92. Communication diagram


VPC-Rule and VPC counter connect to the server and register server, after register the client will feedback
server; one server can link to many VPC counters and many VPC-Rule.

6.8.3 Communicate protocol

6.8.3.1 Register server

Type no. and ID no. One byte

Rule send register information to server:

VPC-Rule -> SERVER

Length Command checksum Block No. CH choose Type no. ID no.

00 0C 02 08 xx xx 00 00 00 0x VPC-Rule no. 00

VPC -> SERVER

Length Command checksum Block no. CH choose Type no. ID no. MAC
Add.

00 12 02 08 xx xx 00 00 00 0x VPC-Rule no. 00 6 byte

6.8.3.2 Heart Beat Package Structure with GPS

VPC with GPRS and no GPS.

VPC -> SERVER

Length Command checksum Block no. CH choose Type no. ID no. MAC Add
00 26 10 08 xx xx 00 00 00 0x xx 00 6 byte

Xiamen Sunford Industry&Trade Co., Ltd. 111 / 157


6.8.3.3 Heart Beat Package Structure with GPS

Length Command checksum Block no. CH choose Type no. ID no. MAC Add Data
00 26 10 08 xx xx 00 00 00 0x xx 00 6 byte 20 byte
Data segment:

GPS data Latitude Latitude Latitude Longitude Longitude Longitude


reliability flag integer part fractional part direction integer part fractional part direction
1 byte 2byte 4 byte 1 byte 2 byte 4 byte 1 byte

Speed integer part Speed decimal part Reserve


2 byte 2 byte 1 byte

Heartbeat packets feedback:

SERVER -> VPC

Length Command checksum Block no. CH choose Type no. ID no.


00 0C 10 08 xx xx 00 00 00 0x xx 00

6.8.3.4 Current record data package:

VPC -> SERVER

Length Command checksum Block no. CH choose Type no. ID no. MAC Data
00 37 10 00 xx xx 00 00 00 0x xx 00 6 byte 37 byte

Data segment:

Device no. Record no. Record data


2 byte 3byte 32 byte

Record data(12 byte)

Type Record Time IN count(chnl) OUT count(err type)


1byte 5-byte 3-byte 3-byte
year month day hour min sec CC BB AA FF EE DD

Record data20 byte

GPS data Latitude Latitude Latitude Longitude Longitude Longitude


reliability flag integer part fractional part direction integer part fractional part direction
1 byte 2byte 4 byte 1 byte 2 byte 4 byte 1 byte

Speed integer part Speed decimal part Reserve


2 byte 2 byte 1 byte

Record feedback:

Xiamen Sunford Industry&Trade Co., Ltd. 112 / 157


SERVER -> VPC

Length Command checksum Block no. CH choose Type no. ID no. Data
00 11 10 00 xx xx 00 00 00 0x xx 00 5 byte

Device no. Record no.

2 byte 3 byte

Data segment:

Except above protocol have been changed, others like time, internet, parameter setting, refresh image and
update etc. Still the same with TCP/IP protocol before.

Data segment diagram:

6.9 Communicate Diagram


Below chart is the communication example of refresh image and send real-time data segment, VPC-Rule,
server and VPC.

Xiamen Sunford Industry&Trade Co., Ltd. 113 / 157


Server VPC
VPC-Rule
2Receive
command
1Click refresh image
button, send image
request command to
3According MAC
default device
address achieve
objective socket

4Change the no.


Of received client,
and forwarding 5Receive
data package command,send
image
6Receive image
data
package,According
the Client no. And
ID no. Search the
objective socket

7Modify the no.


Of Client and the
ID,, and
8Receive image
forwarding data
information, finish
package
image request.

Refresh image communication diagram

Xiamen Sunford Industry&Trade Co., Ltd. 114 / 157


VPC-Rule Sever Database

1.send real-time 2. Receive record


record date package: data package

3According the
client no. Achieve
objective socket

4Analysis record
date and write it
to database; Statistical the
written record in
the report

Figure 93. Send real-time data package communication diagram

Xiamen Sunford Industry&Trade Co., Ltd. 115 / 157


7 VPC-MG Version
7.1 Counter Info shows Device Type is VPC-MG.

7.2 Counter Type


Master Counter: There is only one master counter in a multi-doors system. The master counter can add a
SF-GGM module, and has GPS and GPRS functions.

Slave Counter: There are more than one slave counter in a multi-doors system. Each slave counter sends its
records in real time.

7.3 Counters Connection


1. Two Counters Connection
In a two counters multi-doors system, you can directly with a network cable (straight line net working/ cross
cable) connect them. Specific definition of the following diagram:

Xiamen Sunford Industry&Trade Co., Ltd. 116 / 157


2. Three Counters or Above
You need use a switch to connect three or above counters if you have three counters or above as the bellow.

7.4 Software Settings


You need respectively set master counter and slave counters in the Multi-Doors table in a multi-doors system.
So that each counter knows how many and where is the other counters in this multi-doors system.

Xiamen Sunford Industry&Trade Co., Ltd. 117 / 157


7.4.1 Set Current Counter as a Master Counter

Example:

Master Counter
IP: 192.168.1.130
Slave Counters
IP: 192.168.1.131
192.168.1.132
192.168.1.133

1. Current Master Counter Setting


Multi-Doors Status: Choose Enable
Current Counter Type: Choose Master
Current Counter No.: Input 0. Default is 0.
2. Add Other Slave Counters Information
In one multi-doors system, the maximum slave counter is 8 (means total is 9 set counters and 18 set Cameras).
All master counter and slave counters are in the same network segment, they can not repeat (192.168.1.xxx).
IP: Input the IP address of the adding slave counter
Ports: Input the Ports value of the adding slave counter that communicate with the master counter.
Default is 8000.
Add: Save these inputting values to the current master counter after click the Add button.
Slave Counter List: Show the added and saved slave counters information, include IP, Ports, ID,
Connect Status. Only when you saved, these value will be effective.
Delete: Choose one counter(Set Blue) you want to delete in the Slave Counter List, and click the
Delete button, and, ONLY when you saved, the Delete action will effective.

Get Counter Status: Read the all slave counters status that have been saved in current master
counter and show in the Slave Counter List.
Get Parameters: Read current master counter multi-doors parameters.
Save Parameters: Save all inputting values to the current master counter. Saved will be effective
without restart VPC.

Xiamen Sunford Industry&Trade Co., Ltd. 118 / 157


7.4.2 Set Current Counter as a Slave Counter

Example:

Slave Counter(current)
IP: 192.168.1.131
Adding master counter IP:
192.168.1.130

1. Current Slave Counter Setting


MultiDoorsStatus: Choose Enable
Current Counter Type: Choose Slave
Current Counter No.: Input 1. Default is 1.
2. Other Counters Info:
In one multi-doors system, the maximum slave counter is 8 (means total is 9 set counters and 18 set
StereoCamera). All master counter and slave counters are in the same network segment, they can not
repeat (192.168.1.xxx).
IP: Input the IP address of the adding master counter
Ports: Input the Ports value of the adding master counter that communicate with the slave counters.
Default is 8000.
Add: Save these inputting values to the current slave counter after click the Add button.
Master Counter List: Show the added and saved ONLY master counter information, include
IP,Ports, ID, Connect Status. Only when you saved, these value will be effective.
Delete: Choose the only onemaster counter(Set Blue) you want to delete in the Master Counter
List, and click the Delete button, and, ONLY when you saved, the Delete action will effective.

Get Counter Status: Read the the master counter status that you have been saved in current slave
counter and show in the Master Counter List.
Get Parameters: Read current slave counter multi-doors parameters.
Save Parameters: Save all inputting values to the current slave counter. Saved will be effective
without restart VPC.

Xiamen Sunford Industry&Trade Co., Ltd. 119 / 157


7.5 Verify
Click the Get Parameters button and watch the connection status at the Multi-Doors table in the
VPC-Client.exe.

Generated several records in each door in this multi-doors system, such as IN/OUT, open door/close door etc,
and download the master counter records. If there are each counters record, that means this multi-doors
system is correctly.

Xiamen Sunford Industry&Trade Co., Ltd. 120 / 157


8 VPC-WG Version
8.1 Wide Gate System
If gates wider than 120 cm, it is also possible to connect two or more Passenger Counters together, thus
providing a wider detection area, for the same individual won't repeat count. Each 60cm need to increase a
counter. Its limited to 8 machines for one channel (16 pieces Cameras).Please contact with us, if its not
enough for your requirement.

SF-VPC-WG Model

Model VPC-WG180 VPC-WG240 VPC-WG300 VPC-WG360 VPC-WG420 VPC-WG480 VPC-WG540 VPC-WG600


VPC
1 pcs 2 pcs 2 pcs 3 pcs 3 pcs 4 pcs 4 pcs 5 pcs
Numbers
Camera
2 pcs 3 pcs 4 pcs 5 pcs 6 pcs 7 pcs 8 pcs 9 pcs
Numbers
Model VPC-WG660 VPC-WG720 VPC-WG780 VPC-WG840 VPC-WG900 VPC-WG960 VPC-WG1020
VPC If need counting
5 pcs 6 pcs 6 pcs 7 pcs 7 pcs 8 pcs 8 pcs
Numbers more wide gate,
Camera please contact us
10 pcs 11 pcs 12 pcs 13 pcs 14 pcs 15 pcs 16 pcs
Numbers

8.2 Device Type


1. Counter Info shows Device Type is VPC-WG.

Xiamen Sunford Industry&Trade Co., Ltd. 121 / 157


2. Counter Type
1) Master Counter: There is only one master counter in a wide-door system. The master counter
can add a SF-GGM module, and has GPS and GPRS functions.
2) Slave Counter: There are one to seven slave counters in a wide-door system. Each slave
counter sends its records in real time.

8.3 Counters Connection


1. Connection of Two VPC
If there are two VPC in a wide-gate system, you need a network wire to connect them directly
asbellow. The master VPC can add a SF-GGM.

2. Connection of more than two VPC


If there are three VPC in a wide-gate system, you need a switch to connect them as bellow:

Xiamen Sunford Industry&Trade Co., Ltd. 122 / 157


8.4 Software Settings
You need respectively set master counter and slave counters in the Wide-Door table in a Wide-Door
system. So that each counter knows how many and where is the other counters in this Wide-Door
system.

8.4.1 Set Current Counter as a Master Counter

Example:

Master CounterIP:
192.168.1.147
Slave CountersIP:
192.168.1.151
192.168.1.152
192.168.1.153

1. Current Master Counter Setting


WideGateStatus: Choose Enable
Current Counter Type: Choose Master

Xiamen Sunford Industry&Trade Co., Ltd. 123 / 157


Current Counter No.: Input 0. Default is 0.
2. Add Other Slave Counters Information
In one Wide-Gate system, the maximum slave counter is 8 (means total is 9 set counters and 18 set
StereoCamera). All master counter and slave counters are in the same network segment, they can not
repeat (192.168.1.xxx).

IP: Input the IP address of the adding slave counter


Ports: Input the Ports value of the adding slave counter that communicate with the
master counter. Default is 8000.
Add: Save these inputting values to the current master counter after click the Add
button.
Slave Counter List: Show the added and saved slave counters information, include
IP,Ports, ID, Connect Status. Only when you saved, these value will be effective.
Delete: Choose one counter(Set Blue) you want to delete in the Slave Counter List,
and click the Delete button, and, ONLY when you saved, the Delete action will
effective.
Get Counter Status: Read the all slave counters status that have been saved in current
master counter and show in the Slave Counter List.

Get Parameters: Read current master counter wide-gate parameters.


Save Parameters: Save all inputting values to the current master counter. Saved will be
effective without restart VPC.

8.4.2 Set Current Counter as a Slave Counter

1. Current Slave Counter Setting

WideGateStatus: Choose Enable


Current Counter Type: Choose Slave
Current Counter No.: Input 1. Default is 1.
Space:Each Camera space.

Xiamen Sunford Industry&Trade Co., Ltd. 124 / 157


2. Add Master Counter Information

In one Wide-Gate system, the maximum slave counter is 8 (means total is 9 set counters and 18 set
StereoCamera). All master counter and slave counters are in the same network segment, they can not
repeat (192.168.1.xxx).
IP: Input the IP address of the adding master counter
Ports: Input the Ports value of the adding master counter that communicate with the
slave counters. Default is 8000.
Add: Save these inputting values to the current slave counter after click the Add button.
Master Counter List: Show the added and saved ONLY master counter information,
include IP,Ports, ID, Connect Status. Only when you saved, these value will be
effective.
Delete: Choose the only one master counter(Set Blue) you want to delete in the
Master Counter List, and click the Delete button, and, ONLY when you saved, the
Delete action will effective.
Get Counter Status: Read the the master counter status that you have been saved in
current slave counter and show in the Master Counter List.

Get Parameters: Read current slave counter wide-gate parameters.


Save Parameters: Save all inputting values to the current slave counter. Saved will be
effective without restart VPC.

8.5 Verify
Click the Get Parameters button and watch the connection status at the Wide-Gate table in the
VPC-Client.exe.

Generated several records in each door in this wide-gate system, such as IN/OUT, open door/close door etc,
and download the master counter records. If the master counter has the all records of each Camera, that
means this wide-gate system is correctly.

Xiamen Sunford Industry&Trade Co., Ltd. 125 / 157


Product serial number: the factory NO.;
Product ID: product type, 0x00000001 SF VPC product;
Hardware version: version of the PCB, and V represent the major version, R means reversion .
Type of parameter validation: in order to facilitate test the production and status of the products,
types are defined as follows:
(Type&0x0F) ==0x00------channel 1 does not have Camera parameters
(Type&0x0F) ==0x01------channel 1 has been update Camera parameters
(Type&0xF0) ==0x00------channel 2 does not have Camera parameters
(Type&0xF0) ==0x01------channel 2 has been update Camera parameters
Type==0x11------channel 1,2 have been update Camera parameters (OK)
the lower 4 bits of 1 byte is the channel 1 status indicator, t he upper 4 bits for channel 2 status
indication;

Xiamen Sunford Industry&Trade Co., Ltd. 126 / 157


9 Anti-Tailgating Version
9.1 Detect Objects Within the Region
In some access control and channel identity authentication system, such as a 120cm 100cm enclosed area,
need to detect how many people in this area under the StereoCamera field of view. If one person, then open
the door. to determine whether the number of people out of the "one."

1. VPC GPI 1 as a signal of the beginning of the number of the detected signal input port, when connected to a
12V GPI1 high pulse (required duration of 100 ~ 200ms,), VPC immediately begin to count the number of
regions will be 1 second after the bell, the result of detection by GPO1 or GPO2 or GPO3 mouth, the only
exclusive output can be set to a GPO changed state duration of 12V level signal (or digital signal), the time
range is 100ms-65535ms.

2. GPO output signal, said:

GPO1: 1 area

GPO2: 2 or more people in the region

GPO3: 0 people in the region

9.2 Across Counting

Xiamen Sunford Industry&Trade Co., Ltd. 127 / 157


Xiamen Sunford Industry&Trade Co., Ltd. 128 / 157
10 *Be Server Network Protocol
The Be Server Network Protocol refers to VPC as a server-side, other computer equipment as the client
network communication protocols, such as the VPC-Client.exe software uses this protocol to connect VPC is to
use the protocol.

We allow users to manipulate the VPC and use the existing VPC data do further analysis.

We provide open, flexible, easy to use, extensible application programming interface for developers. Therefore,
for users who already use other monitoring systems, you can through the TCP/IP application protocols to put
the VPC passenger flow data in the original system

10.1 Network Communication Protocol


Form 18. Protocol Specifications
No. Content Description
1 By TCP session Verify command reliable transmission
2 Default TCP port: 8000 User define, better more than >32768
3 Default IP address: 192.168.1.111 Can be modify by user
4 MAC: such as 000123456789ab The MAC usually use ID of encryption chip, its unique for the
chip. User can modify the MAC.
5 Mask:255.255.255.0 Can be modified by user
6 Default gateway:192.168.1.1 Can be modified by user

Xiamen Sunford Industry&Trade Co., Ltd. 129 / 157


10.2 TCP Define the field of TCP data packet
Length Command Checksum Serial No. Channel no. Keep Data
(2 bytes) (2 bytes) (2 bytes (2 bytes) (2bytes) (2bytes) 0~1448 bytes
Data packet=Length + Command +Checksum +Serial No. +Channel No. +keep +Data

1) Length:

2 bytes, length for Data packet.L Such as 1027=0x0403 bytes, show in the field is 04 03.

2) Command:

2 bytes, such as 0x05,show in the field is 00 05.

3) Checksum:

Verify the data packet

Sender algorithm:

Step 1: chksumtemp =0,buf[4] = 0, buf[5] = 0;

Step 2:

for(i=0;i<len;i+=2)
{
chksumtemp += ((unsigned short)buf[i]<<8) | buf[i+1];
}
Step 3:
checksum = (unsigned short)(1+(~ chksumtemp));
Padding packet:buf[4] =(unsigned char) (checksum>>8);
buf[5] =(unsigned char)checksum;
Receiver algorithm:
chksumtemp =0
for(i=0;i<len;i+=2)
{
chksumtemp += ((unsigned short)buf[i]<<8) | buf[i+1];
}
if(0 == chksumtemp)
{
Checksum OK!
}
else
{
Checksum FAIL!
}
4) Block No.:

Review block # of TFTP. If data packet more length than ethernet MTU

5) Channel No.:

2 bytes, 00 00 is Channel One, 00 01 is Channel Two

Xiamen Sunford Industry&Trade Co., Ltd. 130 / 157


6) Reserved:

2bytes, default is 00 00, for expand use

7) Data:

One data packet max length is 1448 bytes

10.3 TCP Command List


Form 19. Command Table
Command Content Description
1.Read system date & time Read the current PC date and time
2.Time synchronization The PC time synchronization to the Counter
3.Read TCP/IP parameters Read the the TCP/IP parameters from the configurator file of PC.
4.update TCP/IP parameters Update the the TCP/IP parameters from the configurator file of iVPC.
5.Read the total of records Read the total of records
6.Delete all the records Erase all the current data records
7.Reset VPC Reset counter to Zero
8.Download records Download all the records from counter
9.Read VPC data Read counter In/Out data
10. GPIO setting Setup GPIO function
11. GPIO signal test Setup GPIO in setting status ,this command can test IO situation

Xiamen Sunford Industry&Trade Co., Ltd. 131 / 157


10.4 TCP/IP Command Description
The following list will be listed in the command description and command applications

10.4.1 Get VPC Time

PC send command:

Length Command checksum Block no. Channel Reserve Data


00 0C 00 0E xx xx 00 00 00 00 00 00 N/A
VPC -> PC:

Length Command checksum Serial no. Channel Reserve Data


00 13 00 0F xx xx 00 01 00 00 00 00 Sec |min |time |week |day|month|year(7 BYTES)
Note:Channel default setting is 00 00

10.4.2 VPC Time synchronization

PC send command:

Length Command checksum BlockNo. Channel Reserve Data


00 13 00 10 xx xx 00 00 00 00 00 00 Sec |min |time |week |day|month|year(7 bytes)
VPC -> PC:ACK

Length Command checksum Block No. Channel Reserve Data


00 10 FF FA xx xx 00 00 00 00 00 00 00 10 00 00
VPC: when time synchronization will occur 2 beeps

VPC -> PC: NACK(wrong data )

Length Command checksum Block No. Channel Reserve Data


00 10 FF FA xx xx 00 00 00 00 00 00 00 10 00 01

10.4.3 Get VPC Parameters

PC send command:

Length Command checksum Block No. Channel Reserve Data


00 0C 00 11 xx xx 00 00 00 00 00 00 N/A
VPC -> PC:

Length Command checksum Block No. Channel Reserve Data


00 xx 00 12 xx xx 00 01 00 00 00 00 xx xx xx xx

10.4.4 Update VPC Network Parameters

PC send command:

Length Command checksum Block No. Channel Reserve Data


00 92 00 13 xx xx 00 00 00 00 00 00 xx xx xx xx

Xiamen Sunford Industry&Trade Co., Ltd. 132 / 157


Note: Channel default 00 00

Network parameters define:

Login Login IP Mask Gateway PORT DEVICE MAC REV


name password 16-byte IP IP 2-byte NAME 6-byte 20-byte
20-byte 20-byte 16-byte 16-byte 20-byte
String String String String String Byte String Byte Reserved
Note:

That in the packaging segment, you must put all the space to be 0, because it involves string manipulation, so
the name and password valid only 19 bytes, the last one must be 0; IP is the same, with string representation
"192.168.1.111" 13 bytes, followed by 3 bytes are all 0;

PORT: High byte first, low byte in the post, such as 8000, said: 1F 40

MAC only display cannot modify.

VPC -> PC: ACK

Length Command Checksum Block no. Channel Reserve Data


00 10 FF F9 xx xx 00 00 00 00 00 00 00 13 00 00
VPC Synchronize network parameters will occur 2 beeps

VPC -> PC: NACK(Wrong data)

Length Command Checksum Block no. Channel Reserve Data


00 10 FF F9 xx xx 00 00 00 00 00 00 00 13 00 01

10.4.5 Get record total number

PC send command:

Length Command Checksum Block no. Channel Reserve Data


00 0C 00 09 xx xx 00 00 00 00 00 00 N/A
Note:Channel invalid default 00 00

VPC -> PC:

Length Command Checksum Block no. Channel Reserve Data


00 10 00 0A xx xx 00 00 00 00 00 00 AA BB CC DD
Rec_num_all = ((unsigned int) 0xAA<<24)|( (unsigned char) 0xBB<<16)|( (unsigned char)0xCC<<8)| 0xDD.

10.4.6 Delete All Records

PC send command:

Length Command Checksum Block No. Channel Reserve Data


00 0C 00 0D xx xx 00 00 00 00 00 00 N/A
VPC Delete FLASH records, about 10seconds will occur 2 beeps means empty records

VPC->PC :ACK:

Length Command Checksum Block no. Channel Reserve Data

Xiamen Sunford Industry&Trade Co., Ltd. 133 / 157


00 10 FF FB xx xx 00 00 00 00 00 00 00 0D 00 00

10.4.7 Reset Counter

PC send command:

Length Command Checksum Block no. Channel Reserve Data


00 0C 00 21 xx xx 00 00 00 00 00 00 8 bytes
Reseting Counter of Channel 1 is 0000;

Reseting Counter of Channel 2 is 0001.

VPC->PC :ACK:(w/out NACK)

Length Command Checksum Block No. Channel Reserve Data


00 10 FF F2 xx xx 00 00 00 00 00 00 00 21 00 00

10.4.8 Download all the records

PC send command:

Length Command Checksum Block No. Channel Reserve Data


00 10 00 0B xx xx 00 00 00 00 00 00 N/A
When VPC received PC "read all records command (0x000B) ", they begin to return to record data packets,
each received a "read all records command (0x000B) ", to return a packet, which is to be Attention

Length Command Checksum Block No. Channel Reserve Data


xx xx xx xx
05 B4 00 0C xx xx 00 01 00 00 00 00
(0x05B4-0x0C)
Length Command Checksum Block No. Channel Reserve Data
xx xx xx xx
05 B4 00 0C xx xx 00 02 00 00 00 00
(0x05B4-0x0C)
Length Command Checksum Block No. Channel Reserve Data
xx xx xx xx
05 B4 00 0C xx xx 00 03 00 00 00 00
(0x05B4-0x0C)
Length Command Checksum Block No. Channel Reserve Data
xx xx xx xx
02 9C 00 0C xx xx 00 04 00 00 00 00
(0x029C-0x0C)
Record format:

Type-year-month-day-hour-min-sec.-In-Out

Type(1Byte) Record Timely(5Bytes) IN (3Bytes) OUT (3Bytes) Reserve Resending Flag


0~22 Y M D H M S UP1 UP2 UP3 DW1 DW2 DW3 3byte 1byte
Record type:
0 --- VPC power on
1 --- Channel 1 IN
2 --- Channel 1 OUT
3 --- Reset counter

Xiamen Sunford Industry&Trade Co., Ltd. 134 / 157


4 --- Deleted records
5 --- Channel 2 IN
6 --- Channel 2 OUT
7 --- Channel 1 covered
8 --- Channel 1 uncovered
9 --- Channel 2 covered
10 --- Channel 2 uncovered
11--- Channel 1 open door
12--- Channel 1 close door
13--- Channel 2 open door
14--- Channel 2 close door
15--- Start recording video (Reserved)
16--- Stop recording video (Reserved)
17--- Video input abnormal (Include 4 channels)
18--- (Total IN and OUT from this open and close the both doors)
20--- GPI4 on (GPI4 is power on, for other function. Reserved)
22---GPS information (reference GGM chapter: 7.5 Records Format)

Record Date&Time:

5 Bytes, year and month use 1 byte, year use high 4 bits, month use low 4 bits.

Year: 0x0~0xF,Half byte, 16 hex means year 2008~ year 2024, 0x0 means year 2008, 0x1 means year 2009,
Total 16years
Month: 0x01~0x0C, Half byte, 16 hex means 1~12month
Day: 0x01~0x1F, 16 hex means 1~31day
Hour: 0x00~0x17, 16 hex means 0~23 hour
Minute: 0x00~0x3B, 16 hex means 0~59 minute
Second: 0x00~0x3B, 16 hex means 0~59 second

Total Incoming Persons and Total Outgoing Persons:

Example:

200801011212120001100022 means:

2008-01-0112:12:12 , the 11th incoming person and the 22th outgoing person

IN counter = 0xCCBBAA

OUT counter = 0xFFEEDD

10.4.9 GetCounter Value

PC send command:

Length Command checksum Block no. Channel Reserve Data


00 0C 00 20 xx xx 00 00 00 00 00 00 N/A
PC send command:

Length Command checksum Block no. Channel Reserve Data

Xiamen Sunford Industry&Trade Co., Ltd. 135 / 157


AA BB CC DD (IN1)
EE FF GG HH(OUT1)
00 1C 00 20 xx xx 00 00 00 00 00 00
AA BB CC DD (IN2)
EE FF GG HH (OUT2)
Channel 1 IN : Value: 0xAABBCCDD

Channel 1 OUT: Value: 0x EE FF GG HH

Channel 2 IN: Value: 0xAA BB CC DD

Channel 2 OUT: Value: 0xEEFFGGHH

10.4.10 GPIO Configuration

Send the command can be configured for GPIO functions

PC send command:

Length Command checksum Block no. Channel Reserve Data


0x00 15 0x00 31 xx xx 00 00 00 00 00 00 9bytes
Data segment format:

Valid GPI1 GPI2 GPI3 GPI4 GPO1 High level GPO2 High level
Flag function function function function time(reserve) time(reserve)
type type type type
8bit 1 byte 1 byte 1 byte 1 byte 2 bytes 2 bytes
Valid Flag:

Subsequent data segment is used to represent a valid state

Define: GPIO input : 0x01 , 0x02 , 0x04 , 0x08 means GPI1~4

GPIO output : 0x10 , 0x20 means GPO1~2

Example: Only setup GPI3, the Valid Flag will be 0000 0100 , 0x04;

Setup GPI2 and GPI3 together, the Valid Flag will be 0000 0110, 0x06;

GPI function type define:

=0 =1 =2 =3 =4
N/A Test Empty counter Open/Close door Start/Stop to count

10.4.11 GPIO State Search

When GPI is set to test station, this order can test IO work or not.

PC Send:

Length Command Checksum Block no. Channel Reserve Data


00 0C 0x00 33 xx xx 00 00 00 00 00 00 none
VPC resend:

Length Command checksum Block no. Channel Reserve Data

Xiamen Sunford Industry&Trade Co., Ltd. 136 / 157


00 11 FF ED xx xx 00 00 00 0X 00 00 9byte
Data segment:

GPI1 GPI2 GPI3 GPI4 GPO1 GPO2


Value
Function Function Function Function High voltage High voltage
Flag
type type type type time time
8bit 1 byte 1byte 1byte 1byte 2byte 2byte

Xiamen Sunford Industry&Trade Co., Ltd. 137 / 157


11 *Be Client Network Protocol
The Be Client Network Protocol refers to VPC as a client-side to connect the server.

11.1 0x0202: registration package


VPC -> PC

Length Cmd checksum Block NO Channel Reserve Client type ClientNo


00 011 02 02 xx xx 00 00 00 0X 00 00 1 byte 4 byte
(nClientNo) =
pDataBuffer[13]<< 24 | pDataBuffer[14]<< 16 | pDataBuffer[15]<< 8 | pDataBuffer[16];
ClientNObetween 1 and 65535;
Checksum:
Verify the data packet
Sender algorithm:
Step 1: chksumtemp =0,buf[4] = 0, buf[5] = 0;
Step 2:
for(i=0;i<len;i+=2)
{
chksumtemp+=(( unsigned short)buf[i]<<8)|(((i+1)<buf.length)?
(unsigned short)buf[i+1]:0);
}
Step 3:
checksum = (unsigned short)(1+(~ chksumtemp));
Padding packet:buf[4] =(unsigned char) (checksum>>8);
buf[5] =(unsigned char)checksum;
Receiver algorithm:
chksumtemp =0
for(i=0;i<len;i+=2)
{
chksumtemp+=(( unsigned short)buf[i]<<8)|(((i+1)<buf.length)?
(unsigned short)buf[i+1]:0);
}
if(0 == chksumtemp)
{
Checksum OK!
}
else
{
Checksum FAIL!
}

Xiamen Sunford Industry&Trade Co., Ltd. 138 / 157


11.2 0x0208: Heartbeat package
Without GPS info:

VPC -> Server

Length Cmd Checksum Block No Channel Reserve


00 0C 02 08 xx xx 00 00 00 00 00 00

ServerVPC

Length Cmd Vhecksum BlockNo Channel Reserve


00 0C 02 08 xx xx 00 00 00 00 00 00

With GPS info:

VPC Server

Length Cmd Checksum BlockNo Channel Reserve


00 20 0x0048 xx xx 00 00 00 0x 00 00

Destination Address Record info GPS info Reserve


1 byte 15 byte 20 byte 4 byte

Server VPC

Length Cmd Check sum BlockNo Channel Reserve Device No Record no


00 12 0x0048 xx xx 00 00 00 0x 00 00 2 byte 4 byte

11.3 0x0048: Record package

VPC -> Server

Length Cmd Checksum BlockNo Channel Record data


00 0C 00 48 xx xx 00 00 00 00 20 byte

Record data

Destination Addresses RecordNo Record


0x30 3 byte 16 byte

Record:

Record type Date and time IN OUT Reserve Resend Flag


1 byte 5 byte 3 byte 3 byte 3 byte 1 byte

Xiamen Sunford Industry&Trade Co., Ltd. 139 / 157


Xiamen Sunford Industry&Trade Co., Ltd. 140 / 157
12 *Be Client Network Protocol of GPRS
The Be Client Network Protocol of GPRS refers to VPC as a client-side to connect a Server through GPRS
connection. Such as SF-PC-Server.exe .

12.1 Definition of client type


Name ID Remark
Server Server NO
VPC-Client Client 0 VPC-CLIENT.EXE
Intelligent Video Analysis Computer IVAC 1 Reserve
Rule Rule 2 VPC-RULE.EXE
Alert System Alert 3 Reserve
Intelligent Video Analysis IVS 4 Reserve
People counter VPC 5 SF-VPC-GGM
The received packet party must return the ACK / NACK command packet to sender. Commands such as Read
records, taking records, read the terminal time, update firmware, restore factory settings and so on can
refer to the above approach.

Central server registry

Register:

CLIENT -> SERVER

Length Cmd Checksum Block NO Channel Type NO ID NO


00 0C 02 08 xx xx 00 00 00 0x Client Type 00
Client type and ID NO are all 1 type.

VPC -> SERVER

Length Cmd Checksum Block NO Channel Client Type ID NO MAC


00 12 02 08 xx xx 00 00 00 0x 05 00 6 byte

There are two tables in Server to store the registration info from Client, registration info table and ID
distribution table.

Typedef struct RegisterInfo


{
SOCKET ClientSocket;
Unsigned char MAC[6];
Unsigned char IPAddr[16];
Unsigned short Port;
}REGISTERINFO;

REGISERINFO g_registerClient[6][256]; //[6] is client type[256] is ID distribution.

// if using people counter, the client type is 05;


ID distribution

Xiamen Sunford Industry&Trade Co., Ltd. 141 / 157


//ID initial value is 0xFF
Typedef struct IDInfo
{
Unsigned short VPCClientNum; //Number of connected client
Unsigned short AlarmClientNum;
Unsigned short AnalyseClientNum;
Unsigned short VPCNum;
Unsigned char VPCClient[256]; // initial value is 0xFFwhen connected, distribute ID NO.
0~255
Unsigned short AlarmClient[256];
Unsigned short AnalyseClient[256];
Unsigned short VPC[256];
}IDINFO;

12.2 Communication Mode

VPC-GGM VPC Rule

fo
In
nt
ie
Cl

VPC-GGM Server Client Info VPC Rule


Cl
ie
nt
In
fo

VPC-GGM VPC Rule


Record

database

12.3 Communication protocol


Depending on the application, VPC-GGM communication protocol implements the following four protocols,
to transmit all records to the server.

12.3.1 0x0208 Registration Package

CLIENT -> SERVER

Length Cmd Checksum BlockNo Channel Type ID NO

Xiamen Sunford Industry&Trade Co., Ltd. 142 / 157


00 0C 02 08 xx xx 00 00 00 00 Client type 00

VPC -> SERVER

Length Cmd Checksum Block No Channel Client type ID NO MAC


00 12 02 08 xx xx 00 00 00 00 05 00 6 byte

12.3.2 0x1008 Heartbeat Package Without GPS Info

VPC -> SERVER

Length Cmd checksum Block No Channel Client type ID No MAC


00 12 10 08 xx xx 00 00 00 00 05 00 6 byte

12.3.3 0x1008 Heartbeat Package With GPS info

VPC -> SERVER

Length Cmd Checksum Block No Channel Client Type ID NO MAC Record data
00 26 10 08 xx xx 00 00 00 0x 05 00 6 byte 20 byte
Record data

Reliability Latitude Longitude Speed Flag


Integer Decimal N/S Integer Decimal W/E Integer Decimal
1byte 1byte
2bytes 4bytes 1byte 2bytes 4bytes 1byte 2bytes 2bytes

SERVER -> VPC

Length Cmd Checksum BlockNo Channel Client Type ID No


00 0C 10 08 xx xx 00 00 00 0x 05 00

12.3.4 0x1000 Record Package

VPC -> SERVER

Length Cmd Checksum BlockNo Channel Client type ID No MAC Device number Record data GPS data

00 37 10 00 xx xx 00 00 00 0x 05 00 6 byte 2byte 15 byte 20 byte

Record data:

Record NO. Record Type Record time In Amount Out Amount


3byte 1byte 5byte 3byte 3byte

GPS data:

Reliability Latitude Longitude Speed Resend Flag


1byte Integer Decimal N/S Integer Decimal W/E Integer Decimal 1byte

Xiamen Sunford Industry&Trade Co., Ltd. 143 / 157


2bytes 4bytes 1byte 2bytes 4bytes 1byte 2bytes 2bytes
1) Longitude: faaabb.cccccc
FW or E
aaadegree
bb.ccccccminutes
2) Latitude: faabb.cccccc
FS or N
aadegree
bb.ccccccminutes
3) When Reliability of GPS is A (0x41), GPS data is valid.
4) For example
D7093E300B0053== S2519.733246
Integer 2byte D7 09 2519=7*1+D *16+9 *256
Decimal 4byte 3E 30 0B 00 733246=E*1+3*16+0*256+3*4096+B*65536+0*..+0*..+0*..
53 (ASCII) == S
6 Checksum:
Verify the data packet
Sender algorithm:
Step 1: chksumtemp =0,buf[4] = 0, buf[5] = 0;
Step 2:
for(i=0;i<len;i+=2)
{
chksumtemp+=(( unsigned short)buf[i]<<8)|(((i+1)<buf.length)?
(unsigned short)buf[i+1]:0);
}
Step 3:
checksum = (unsigned short)(1+(~ chksumtemp));
Padding packet:buf[4] =(unsigned char) (checksum>>8);
buf[5] =(unsigned char)checksum;
Receiver algorithm:
chksumtemp =0
for(i=0;i<len;i+=2)
{
chksumtemp+=(( unsigned short)buf[i]<<8)|(((i+1)<buf.length)?
(unsigned short)buf[i+1]:0);
}
if(0 == chksumtemp)
{
Checksum OK!
}
else
{
Checksum FAIL!
}

SERVER -> VPC

Xiamen Sunford Industry&Trade Co., Ltd. 144 / 157


Length Cmd Checksum Block No Channel Client type ID No Record data
00 11 10 00 xx xx 00 00 00 0x xx 00 5byte

Record data

Device No Record No
2byte 3byte

int nlen = pIOPortInfo->pBuffer[0]<<8|pIOPortInfo->pBuffer[1];//Length


int cmd = pIOPortInfo->pBuffer[2]<<8|pIOPortInfo->pBuffer[3];//Cmd
int nChanl = pIOPortInfo->pBuffer[8]<<8|pIOPortInfo->pBuffer[9];//Channel

//-------------------------------------------------
//GPS
unsigned short nW1;
unsigned long intnW2;
unsigned short nJ1;
unsigned long int nJ2;
unsigned short nS1;
unsigned short nS2;
int nRecordPos = 13;

memcpy(&nW1,&pDataBuffer[nRecordPos+16],2);
memcpy(&nW2,&pDataBuffer[nRecordPos+18],sizeof(int));

memcpy(&nJ1,&pDataBuffer[nRecordPos+23],2);
memcpy(&nJ2,&pDataBuffer[nRecordPos+25],sizeof(int));

memcpy(&nS1,&pDataBuffer[nRecordPos+30],2);
memcpy(&nS2,&pDataBuffer[nRecordPos+32],2);

Xiamen Sunford Industry&Trade Co., Ltd. 145 / 157


CString strW;
CString strJ;
CString strS;
strW.Format("%c%d.%d",pDataBuffer[nRecordPos+22],nW1,nW2);
strJ.Format("%c%d.%d",pDataBuffer[nRecordPos+29],nJ1,nJ2);
strS.Format("%d.%d",nS1,nS2);
if (pDataBuffer[nRecordPos+15] == 'A')
{
Record.strW = strW;
Record.strJ = strJ;
Record.strSpeed = strS;
}
else
{
Record.strW = "0000";
Record.strJ = "0000";
Record.strSpeed = "0000";
}
//-------------------------------------------------

Xiamen Sunford Industry&Trade Co., Ltd. 146 / 157


13 *RS232 and RS485 Protocol
13.1 Introduction
The count meter scale with two serial ports, a configuration for RS232, a configuration for RS485, can't modify.
If need to change type, please contact with us.

About other software or other equipment (such as GPS equipment) that you develop based on VPC serial ports,
we provide a debug program (SF_PC_RS232_GUI. Exe), and provide the source code to facilitate your
secondary development and debugging

Note:

In VPC-GGM, because the two serial ports to connect the GGM module, so, the only RS232 TX
Can send the real time records and Baud rate is only 115200bps. The RS232 and RS485 could not
receive commands any more.

13.2 Nouns Constraints


Master: VPC RS-232 protocol is usually connected to computer, we call the computer PC.
Slave: Usually its a VPC
ACK: Response frame

NOTE: There are two ports with different function on VPC, they are configured as RS232 and RS485.

1. VPC 232 port can receive and send and support all the commands list in the below table.
2. VPC485 port can receive and send, but the operation of receive and send cannot at the same time,
support all the commands list in the below table.

13.3 Configuration
1. You need set up the following parameters in IO/Record of VPC-Client.exe of the two serial ports:
Baud rate: 19200bps
Start bit: 1Bit
Data Length: 8Bit
Stop bit: 1Bit
No parity bit
2. RS232/485 communication diagram:

Xiamen Sunford Industry&Trade Co., Ltd. 147 / 157


13.4 Protocol Frame Format
Head Data Length Data Checksum

0x93 N data0=Master addr N -1(byte) XOR or XNOR, CRC

1. Head: default 0x93


2. Data Length:0~255
3. Data: the Ns data

Device Address:

Device Name Address


VPC 0x20
PC or equipment via RS-232 connect to VPC 0x31
PC or equipment via RS-232 connect to VPC 0x30
4. Data checksum: the N XOR or XNOR
5. CRC=data0^data1^data2^^dataN-1

13.5 RS232-GUI TOOL


SF-PC-RS232-GUI.exe serial port debugging tool can send command to VPC, after VPC received the command,
it will feedback. As in the chapter 6.6.6 read time and 6.6.5 Clear counter value.

Xiamen Sunford Industry&Trade Co., Ltd. 148 / 157


13.6 Test Serial Port Connection
1. Connect the serial port of Counter and PC (such as a laptop, if there is no serial port in laptop, you can use
the USB to RS232 device is connected, remember that both ends of the serial line connection is "revenue
RX" access "fat TX", "send TX" then "receive RX".
2. Counter and Master must have set same baud rate, and set Hexadecimal displa.
3. Open the VPC-Client.exe and Login, then set as following:
Baud Rate: 19200bps
Choose Send real time option.
Click the Reset CH1 Counter button, the master will get one record, and when Counter counted once,
mater will get one record.
4. Connection as following:

Figure 94. Counter Serial Port Connect PC

Figure 95. USB Convert RS232 Device

Xiamen Sunford Industry&Trade Co., Ltd. 149 / 157


Figure 96. RS232 Convert to RS485 Device

Figure 97. Serial Port Push Records Settings

13.7 RS232/485 Command Description


Form 20. Commands Table
Commands Content Commands Description
Handshaking protocol 0x55 Check the serial port is normal or abnormal
Baud rate setting 0x20 Setting serial port Baud rate
Read VPC time 0x25 Read current VPC time
Set VPC time 0x24 Synchronize PC time with VPC
Reset counter 0x2D Read the current data records total num.
Read total record numbers 0x26 Delete VPC all the data records
Download one record 0x40 Setup counter all the in and out into zero
Download all the records 0x2E Download all the records from VPC
Delete all the records 0x2A Export one record
Export real-time record 0x30 When generate a record, as writing it into the flash, the
VPC will send the record via serial port.
Read current counter value 0x41 Read the number in and out of channel 1 and channel 2
VPC restart 0x2B Restart VPC
Read version 0x23 Read the current version of VPC software\hardware
Restore to factory setting 0x2C Restore all VPC parameters to factory stings
Note: RS232 and RS485 have the same command, so we can switch the tail wire under according to the
requirement.

13.7.1 Handshaking Protocol

Commands Specifications: To identify the serial port communication is work or not

Master Send:

Xiamen Sunford Industry&Trade Co., Ltd. 150 / 157


Header Length Data0 Data1 Data CRC
0x93 0x02 Addr(0x20) 0x55 CRC
VPC Send:

Header Length Data 0 Data1 Data 2 Data CRC


0x93 0x03 Addr 0x55 0xAA CRC

13.7.2 Baud Rate Settings

Commands Specifications: To setup Baud rate

Master Send:

Header Length Data 0 Data1 Data2 Data CRC


0x93 0x03 0x20 0x20 N CRC
Data2:
04800 bps (bits per second),
19600,
214400,
319200,[Default]
438400,
557600,
676800,
7115200,
Note: Every time VPC restore factory settings, the baud rate will restore the default values: 19200bps.

13.7.3 Get VPC Time

Commands Specifications: Read the VPC current date and time.

Master Send:

Header Length Data0 Data1 Data CRC


0x93 0x02 Addr(0x20) 0x25 CRC
VPC Send:

Header Length Data0 Data1 Time Data CRC


0x93 0x09 Addr 0x25 sec min hour week day month year CRC
Use the RS-232-GUI debugging tool:

Input command: 93 02 20 25 05, click send out button;

VPC output result: 93 09 31 25 27 26 0b 04 17 02 0c 03(When send out time is different, the output result will
be different too.)

Xiamen Sunford Industry&Trade Co., Ltd. 151 / 157


13.7.4 Set VPC Time

Commands Specifications: Synchronize the master device date and timeto the VPC.

Master Send:

Header Length Data0 Data1 Time Data CRC


0x93 0x09 Addr(0x20) 0x24 sec min hour week day month year CRC
Time (HEX),ex:35 seconds=0x23

Week:1~7,1-Monday,7-Sunday.

Year: year+2000,ex: 08 means 2008

13.7.5 Reset Counters

Commands Specifications: Reset the the two channels counter of the VPC.

Master Send:

Header Length Data0 Data1 Data CRC


0x93 0x02 Addr(0x20) 0x2D CRC
VPC Send:

Header Length Data0 Data 1 Data2 Data CRC


0x93 0x03 Addr 0x2D 0x55 CRC

Xiamen Sunford Industry&Trade Co., Ltd. 152 / 157


Use the RS-232-GUI debugging tool:

Input command: 93 02 20 2D 0D, click send out button;

Feedback (VPC Output): 93 11 31 30 00 01 10 03 24 0d 0a 2c 36 00 00 00 00 00 00 2a (time) 93 03 31 2D


55 49

13.7.6 Read Total Record Numbers

Commands Specifications: Get the read total record number of the VPC.

Master Send:

Header Length Data Data CRC


0x93 0x02 Addr(0x20) 0x26 CRC
VPC Send:

Header Length Data Checksum


0x93 0x06 Addr 0x26 C1 C2 C3 C4 CRC
Record num. =C1+C2*256+C3*65536

13.7.7 Download One Record

Commands Specifications: Download one record of the specific record number.

Master Send:

Header Data Length Addr Command Record Number Checksum


0x93 0x05 Addr(0x20) 0x40 C1 C2 C3 CRC
Record Number =(int)C1<<16&(0x00ff000000)+(int)C2<<8&(0x0000ff00)+C3

Record Numbe range: 0 Maximum record number

VPC Send:

Header Data Length Addr Command Current Record Number Record Data Checksum
0x93 0x11 0x31 0x30 3 Bytes 16 Bytes CRC
Record Data:

Type(1Byte) Record Timely(5Byte) IN (3Byte) OUT (3Byte) Reserve Resending Flag


0~20 Y M D H M S UP1 UP2 UP3 DW1 DW2 DW3 3bytes 1byte

1. Record
0 --- system reset or hardware boot 10 ---channel 2 uncovered type:
1 --- in by channel 1 11--- channel 1 open
2 --- out by channel 1 12--- channel 1 closed
3 --- clear 13--- channel 2 open
4 --- delete 14--- channel 2 closed
5 --- in by channel 2 15--- start to record
6 --- out by channel 2 16--- stop recording
7 --- channel 1 covered 17--- Video input anomalies
8 --- channel
Xiamen 1 uncovered
Sunford Industry&Trade Co., Ltd. 153at/ this
20 --- Total in and out 157 time

9 --- channel 2 covered 22--- switch on (GPI4 on,reserved)


2. Record Timer: 5Bytes, Year and Month share 1 byte, Year use top 4 bit , Month use low 4 bit.
3. Year: 0x0~0xF,Half byte, HEX exchange to2008~2024,0x0 expressed 2008, 0x1 expressed 2009, and so on,
total is 16 years.
4. Month: 0x01~0x0C, Half byte, HEX exchange to1~12 month.
5. Day: 0x01~0x1F, HEX exchange to1~31 day.
6. Hour: 0x00~0x17, HEX exchange to0~23 hour.
7. Minute: 0x00~0x3B, HEX exchange to0~59 minute.
8. Second: 0x00~0x3B, HEX exchange to0~59 second.
9. IN: 0x0000~0xFFFF, Hexadecimal format means IN number is 0~65535

(UP1*256*256) +(UP2256)+UP3

10. OUT: 0x0000~0xFFFF , Hexadecimal format means out number is 0~65535

(DW1256256)+(DW2256)+DW3

11. Resending Flag: 0mean this record has not be sent successfully. 1 mean this record has be sent
successfully.

13.7.8 Download All Records

Commands Specifications: Download all the records of the VPC flash.

Master Send:

Header Data Length Data Checksum


0x93 0x02 Addr(0x20) 0x2E CRC
VPC Send:

Header Data length Data Checksum


0x93 0x0E Addr 0x2E 16bytes Record Data CRC
Record Data

Type(1Byte) Record Timely(5Byte) IN (3Byte) OUT (3Byte) Reserve Resending Flag


0~20 Y M D H M S UP1 UP2 UP3 DW1 DW2 DW3 3bytes 1byte
If no record is useful or finish send record, VPC will send back the over signal.

VPC Send:

Header Data length Data Checksum


0x93 0x03 Addr 0x2E 0x55 CRC
Note: get TXT file format, records include NO., date,time,status,in/out numberetc.

Xiamen Sunford Industry&Trade Co., Ltd. 154 / 157


13.7.9 Delete All Records

Commands Specifications: Clear all records of the VPC flash.

Master Send:

Header Length Data Checksum


0x93 0x02 Addr(0x20) 0x2A CRC
VPC Send:

Header Length Data Checksum


0x93 0x03 Addr 0x2A 0x55 CRC

13.7.10 Send Real Time Record

Commands Specifications: VPC send each real time record to a master device.

VPC Send:

Head Length Data Checksum


0x11; 3byte 16byte
0x93 Addr 0x30 CRC
0x25(GPS)* Record Number Record Data
The 16 bytes of the record content form as below:

1) No multi-door version:

Record Type Record Time IN OUT Reserve Resending Flag


1byte 5byte UP1 UP2 UP3 DW1 DW2 DW3 3byte 1byte
2) Multi-door Version:

Record Record IN OUT Device Reserve Resending Flag


Type Time no.
1byte 5byte UP1 UP2 UP3 DW1 DW2 DW3 1byte 2bytes 1byte
* is the data with the GPS data in SF-VPC-GGM. Reference 7.3 Records Format.

Input video strange:

Head Length Data Checksum


3byte 16byte
0x93 0x11 Addr 0x31 CRC
Record Number Record Data
16 byte Record Data:

Record Type Record Time In Out Reserve Resending Flag


0x11 5byte 0x00 0x00 A* 0x00 0x00 0x00* 3byte 1byte
*Note:

1) The value of VideoIn channel number specifications:

A= Video input position(0x00=channel 1 left, 0x01=channel 1 right, 0x02=channel 2left, 0x03=channel 2 right)

2) The value of VideoIn status specifications:

Xiamen Sunford Industry&Trade Co., Ltd. 155 / 157


The feedback is 0x00: Means the image of this channel is missing.
The feedback is 0x01: Means the image of this channel is normal.

13.7.11 *Read Current Counter Value

Commands Specifications: By sending this command, reading the current counter value of in and out people in
channel 1 and channel 2.

Master send:

Header Length Data Checksum


0x93 0x02 0x20 0x41 CRC
SF-VPC return ACK packet:

Header Length Data Checksum


0x93 0x0a Addr(0x31) 0x41 Counter value 61
Current counter value:

CH1 in CH1 out CH2 in CH2 out


1byte 1byte 1byte 1byte 1byte 1byte 1byte 1byte
top 8 bits low8bits top8bits low8bits top8bits low8bits top8bits low8bits
State:

The people in and out of each channel shows by a hexadecimal number which is 2 byte. Max means decimal
system 65535;

If clear, repower or power off the counter value will start from 0, if not the counter value will accumulate.

13.7.12 VPC restart\reset

Commands Specifications: Restart VPC by sending this command.

Master send:

Header Length Data 0 Data 1 Checksum


0x93 0x02 Addr(0x20) 0x2B CRC
VPC buzzer will issue one short chirp after receive command and restart. It will chirp one time after successful
estart.

1. VPC restart 0x2B Restart VPC


2. Read version 0x23 Read the current version of VPC software\hardware
3. Restore to factory setting 0x2C Restore all VPC parameters to factory stings

13.7.13 Restore to factory setting

Commands Specifications: Restore to factory settings by sending this command.

Master send:

Header Length Data 0 Data 1 Checksum


0x93 0x02 Addr(0x20) 0x2C CRC
All parameters will restore to the factory settings after VPC receive the command.

Xiamen Sunford Industry&Trade Co., Ltd. 156 / 157


13.7.14 Read Version

Commands Specifications: Read the current version of VPC software\hardware by sending this command.

Master send:

Header Length Data 0 Data 1 Checksum


0x93 0x02 Addr(0x20) 0x23 CRC

VPC Return:

Product Product Hardware


Header Length Data0 Data1 Version DeviceID Checksum
Series ID Version
0x93 0x1C Addr 0x23 4bytes 6bytes 8 bytes 4 bytes 4 bytes CRC
Firmware version: firmware version of VPC;
Device ID: the unique ID number for each VPC, corresponds to the low 4 bytes and USB file names,
and also corresponds to the MAC address of the network;

13.8 Serial Ports Applications


The application of the Serial port has two ways: PUSH and PLUG, please see more in VPC Application
chapter in this article.

Xiamen Sunford Industry&Trade Co., Ltd. 157 / 157

You might also like