TERACOM TCG120 GSM/GPRS Controller User Manual
- June 9, 2024
- TERACOM
Table of Contents
- TERACOM TCG120 GSM/GPRS Controller
- Product Information
- Product Features
- Product Applications
- Product Usage Instructions
- Short description
- Features
- Applications
- Specifications
- Installation
- LED indicators
- Initial setup via USB
- Setup via SMS
- Firmware update
- Factory default settings
- Environment information
- Safety
- Maintenance
- Package content
- Appendix
- References
- Read User Manual Online (PDF format)
- Download This Manual (PDF format)
TERACOM TCG120 GSM/GPRS Controller
Product Information
TCG120 is a remote monitoring controller designed for distributed IO monitoring and control. It has 2 digital inputs, 2 analog inputs, and 1-Wire interface. The controller can support up to 4 Teracom humidity and temperature 1-Wire sensors. The device has 2 relays with normally open and normally closed contacts. The relays can be activated remotely via SMS or HTTP API command, or locally based on the status of the monitored parameters. TCG120 may periodically send data to a remote server, making it suitable for client- server monitoring and control systems.
Product Features
- 2 digital inputs
- 2 analog inputs
- 1-Wire interface
- Supports up to 4 Teracom humidity and temperature 1-Wire sensors
- 2 relays with normally open and normally closed contacts
- Can be activated remotely via SMS or HTTP API command
- Periodically sends data to a remote server
Product Applications
The TCG120 is suitable for various applications, including:
- Remote monitoring and control systems
- Environmental monitoring
- Industrial automation
- Building automation
Specifications
Please refer to page 3 of the TCG120 user manual for detailed specifications.
Product Usage Instructions
Installation
The TCG120 must be installed by qualified personnel. The installation process includes mounting the device, connecting to the GSM network, connecting inputs and outputs, providing power, and configuring via a web browser. The device should not be installed directly outdoors. Before installing the SIM card in the card slot, ensure that the PIN code is disabled.
Mounting
Please refer to section 5.1 of the TCG120 user manual for detailed mounting instructions.
Connectors
Please follow the correct wiring procedure while connecting the TCG120 to avoid permanent damage to the device or the equipment it is connected to. Before wiring, disconnect the power supply. Digital inputs and analog inputs are NOT galvanic isolated. The maximum cable length for a digital input or an analog input should be up to 30 meters. The device supports TST1xx, TST2xx, and TSH2xx temperature and humidity-temperature sensors. Up to 4 1-Wire sensors can be connected to the controller. Please refer to section 5.2.4 of the TCG120 user manual for detailed sensor connection instructions.
Power Supply Connection
The TCG120 is designed to be supplied by adapter SYS1308-2412-W2E or a similar adapter intended for use in the conditions of overvoltage category II. The power supply equipment must be resistant to short circuit and overload in the secondary circuit. When in use, do not position the equipment so that it is difficult to disconnect the device from the power supply.
Usage
Please refer to the TCG120 user manual for detailed usage instructions, including how to activate relays remotely via SMS or HTTP API command, or locally based on the status of monitored parameters, and how to periodically send data to a remote server.
Short description
TCG120 is a GSM-GPRS remote monitoring controller for distributed IO
monitoring and control. The controller has 2 digital inputs, 2 analog inputs,
and 1-Wire interface. The controller supports up to 4 Teracom humidity and
temperature 1-Wire sensors. The device has 2 relays with normally open and
normally closed contacts.
The relays can be activated either remotely (via SMS or HTTP API command) or
locally – from the status of the monitored parameters. Only one parameter can
control the relay at the same time, but for each parameter, an email or SMS
can be sent on an alarm condition.
TCG120 may periodically send data to a remote server, which makes it suitable
for client-server monitoring and control systems.
Features
- Quad-bands connectivity;
- Setup via USB, SMS and HTTP API;
- 2 digital inputs with ” dry contact” and “logic level” modes;
- 2 analog inputs with 0 to 60 VDC range;
- 2 relays with NO and NC contacts;
- TST1xx, TST2xx and TSH2xx temperature and humidity 1-Wire sensors support; SMS alarm alerts to 5 numbers;
- Email alarm alerts to 5 email recipients, with TLS 1.2 support;
- Single call control from up to 100 numbers;
- Periodical HTTP post with current status in XML or JSON file to remote server;
- HTTP API commands;
- Firmware update over USB or GPRS.
Applications
-
Remote control
The relay outputs can be controlled with SMS, HTTP command or by a single call from an authorized number. -
Humidity and temperature control
TCG120 supports TST1xx, TST2xx and TSH2xx temperature and humidity- temperature 1-wire sensors. The relay outputs can be controlled from the value of the measured parameters. -
Status reporter
SMS and E-mail alerts can be sent to the authorized recipients. The alerts can be triggered if some of the measured parameters (temperature, humidity, analog inputs, and digital inputs) are in the alarm state. -
SCADA systems
TCG120 be easily integrated into SCADA systems. The periodical HTTP post is suitable for client-server configurations.
Specifications
- Physical characteristics
- Dimensions: 107 x 72 x 32 mm
- Weight: 130 g
- Mounting: wall
- Environmental limits
- Operating Temperature: 0 to 40°C
- Storage Temperature: -25 to 60°C
- Ambient Relative Humidity: 5 to 85% (non-condensing)
- Standards and Certifications
- Safety: EN 60950-1:2006+A11:2009+A1:2010+A12:2011+A2:2013; EN 61010-1:2010
- EMC: EN 55022:2010, EN 55024:2010, EN 61000-3-2:2014, EN 61000-3-3:2013 EN 301489-1 V1.9.2, EN 301489-7 V1.3.1
- RFSU: EN 301511 V9.0.2
- Green Product: RoHS
- Warranty
- Warranty period: 3 years
- Power requirements
- Input Voltage: 10 to 28 VDC
- Input Current: 240 mA @ 12 VDC
- Cellular interface
- Standards: GSM/GPRS
- Bands: 850/900/1800/1900 MHz
- GPRS multi-slot class: 12, 1~12 configurable
- GPRS terminal device class: Class B
- Compliant to GSM Phase 2/2+: Class 4 (2W@850/ 900MHz), Class 1 (1W@1800/1900MHz) SIM card size: Standard
- Antenna connector: SMA-F
- Analog inputs
- Isolation: Nonisolated
- Type: Single ended
- Resolution: 10 bits
- Input Range: 0 to 60 VDC
- Accuracy: ±1%
- Sampling Rate: 500mS per channel (averaged value of 500 samples)
- Input Impedance: 1 mega-ohms (min.)
- Digital inputs
- Isolation: Nonisolated
- Type: Dry contact and logic level
- Minimum high-level input voltage for digital inputs: +2.5VDC
- Maximum low-level input voltage for digital inputs: +0.8VDC
- Maximum input voltage for digital inputs: +5.5VDC
- Sampling rate: 10mS
- Digital filtering time interval: 30mS
- Relay outputs
- Type: Form C (N.O. and N.C. contacts)
- Contact current rating: 3 A @ 24 VDC, 30 VAC (resistive load)
- Initial insulation resistance: 100 mega-ohms (min.) @ 500 VDC
- Mechanical endurance: 10 000 000 operations
- Electrical endurance: 100 000 operations @ 3 A resistive load
- Contact resistance: 50 milli-ohms max. (initial value)
- Pulse output: 0.1 Hz at rated load
- 1-Wire interface
- Output voltage: 5.0 ± 0.3 VDC
- Maximum output current: 200 mA
- Internal FLASH memory
- Endurance: 100 000 cycles (Every relay status and settings change is a memory cycle)
Installation
This device must be installed by qualified personnel. The installation
consists of mounting the device, connecting to the GSM network, connecting
inputs and outputs, providing power and configuring via a web browser. This
device must not be installed directly outdoors.
Attention! Before installing the SIM card in the card slot, please ensure that
the PIN code is disabled.
Mounting
TCG120 should be mounted in a clean and dry location on a not flammable
surface. Ventilation is recommended for installations where the ambient air
temperature is expected to be high.
Mount the device to a wall by using two plastic dowels 8x60mm (example Würth
GmbH 0912 802 002) and two dowel screws 6x70mm (example Würth GmbH 0157 06
70). Attach the screws to the surface vertically. See Appendix C, fig. 1 for
mechanical details.
Maintain spacing between adjacent equipment. Allow 50 mm of space on all
sides, as shown in fig.2 in Appendix C, this provides ventilation and
electrical isolation.
Connectors
Attention! Disconnect power supply before wiring. The correct wiring procedure is as follows:
- Make sure power is turned off;
- Make wiring connections to the terminals;
- Apply power.
It is recommended to test and configure TCG120 without any controlled device.
Make sure that wires are properly attached to the terminals and that the
terminals are tightened. Not proper wiring and configuration can cause
permanent damage of TCG120 or the equipment to which it is connected or both.
Inputs and outputs locations are shown below:
-
Connector 1 – Power – 2.1×5.5mm connector, central positive
-
Connector 2, Pin1 – Digital input 1 (Din1) Connector 2, Pin2 – Digital input 2 (Din2) Connector 2, Pin3 – Ground
-
Connector 2, Pin4 – Analog input 1 (Ain1) Connector 2, Pin5 – Analog input 2 (Ain2) Connector 2, Pin6 – Ground
-
Connector 2, Pin7 – 1-Wire data
-
Connector 2, Pin8 – 1-Wire power supply Connector 3 – mini USB
-
Connector 4 – SIM card holder
-
Connector 5 – GSM Antenna
-
Connector 6, Pin1 – NC Relay2
-
Connector 6, Pin2 – COM Relay2
-
Connector 6, Pin3 – NO Relay2
-
Connector 7, Pin1 – NC Relay1
-
Connector 7, Pin2 – COM Relay1
-
Connector 7, Pin3 – NO Relay1
-
Operating mode is selected by jumper DI1/DI2 – closed for “dry contact” and open for “logic level”. By default, jumpers are closed.
Power supply connection
TCG120 is designed to be supplied by adapter SYS1308-2412-W2E or similar,
intended for use in the conditions of overvoltage category II. The power
supply equipment shall be resistant to short circuit and overload in the
secondary circuit.
When in use, do not position the equipment so that it is difficult to
disconnect the device from the power supply.
Digital inputs connection
Attention! Digital inputs are NOT galvanic isolated.
The TCG120 digital inputs can be used in two modes – “dry contact” and “logic
level”. The mode is determined by the jumper, close to the corresponding
input. To change the operation mode, the plastic enclosure must be opened.
Closed jumper determines “dry contact” mode while open “logic level”. By
default digital inputs are in “dry contact” mode.
In “dry contact” mode digital inputs can be used to monitor the state of a
discrete device – door contact switch, push button, PIR detector etc.
The following picture illustrates how a dry contact switch can be connected to
the input (or inputs) of TCG120. One side of the contact is connected to
“Digital In” and the other side is connected to “GND” terminals.
The maximum cable length for a digital input should be up to 30 meters
.
Analog inputs connection
Attention! Analog inputs are NOT galvanic isolated.
Analog inputs of TCG120 can be used for monitoring of DC voltage up to 60VDC.
They can be connected directly to batteries, solar panels, power supplies etc.
Built-in functionality “Multiplier”, “Offset” and “Dimension” for every analog
input gives the possibility to monitor sensors with analog outputs and see
directly the measured parameter. It is also possible to monitor voltages
higher than 60 VDC with external resistive dividers.
The following picture illustrates how a battery can be connected to the analog
input of TCG120. One side of the contact is connected to “Analog In” and the
other side is connected to “GND” terminals.
The maximum cable length for a digital input should be up to 30 meters.
Sensor connection
The device supports TST1xx, TST2xx and TSH2xx temperature and humidity-
temperature sensors. Up to 4 1-Wire sensors can be connected to the
controller.
1-Wire is a registered trademark of Maxim Integrated Products, Inc. It is
designed to connect several sensors over a short wiring. It is not suitable
for long distances or environments with EMC interference. We recommend reading
Maxim’s 1-Wire tips at http://www.maxim-ic.com/app-notes/index.mvp/id/148.
The sensors have three wires – positive voltage (+VDD), ground (GND) and
bidirectional data (Data). The colors of wires for every sensor are specified
in its user manual.
It is strongly recommended to use “daisy-chained” (linear topology) for
multiple sensors:
“Star” topology can be used only as a last resort for up to 4 sensors and total cable length up to 10 meters:
There are many parameters which determine the maximum length of the wires –
type of cable, the number of sensors, ambient electromagnetic noise and sensor
network topology.
It is strongly recommended to use only UTP/FTP cables and keep total cable
length up to 30 m. Although functionality has been achieved in the longer
distance, we cannot guarantee error-free operation over mentioned wiring
length.
We guarantee proper operation only with Teracom 1-Wire sensors.
Relay connection
The relay contacts are internally connected directly to the terminal connectors. For all relays normally open, normally closed and common contacts are available. For loads with higher switchable current/voltage than specified, an external relay should be used.
When mechanical relays switch inductive loads such as motors, transformers, relays, etc., the current will arc across the relay contacts each time the contacts open. Over time, this cause wears on the relay contacts which shorten their life. When switching an inductive load, it is recommended that relay contact protection devices are used.
LED indicators
LED indicators show the status of the controller:
- REL1 – REL2 (green) – the LED is ON when the corresponding relay is activated (the NO contact is connected to COM);
- SIG (red) – indicates the status of the device together with STA
- STA (yellow) – indicates the status of the device together with SIG.
The following states are displayed:
- Controller initialization – after power-on and firmware update SIG and STA turn ON for a second, after this turn OFF for another second.
- Searching for GSM network – after initialization, SIG is OFF, STA flashes (flash length –200ms)
- Connected to GSM network – after successful connection to a mobile network, STA shows the type of connection, while SIG shows the signal strength.
STA flashes ones for 200mS in period of 2S – there is GSM connection only ;
STA flashes twice for 200mS in a period of 2S – there is GSM and GPRS connection.
At the same time SIG has 5 states:
- SIG flashes 1 time in period of 2S – signal strength is between 0 and 20%;
- SIG flashes 2 times in period of 2S – signal strength is between 21 and 40%;
- SIG flashes 3 times in period of 2S – signal strength is between 41 and 60%;
- SIG flashes 4 times in period of 2S – signal strength is between 61 and 80%;
- SIG is solid ON – signal strength is between 81 and 100%;
- Error message – in case of error after initialization, SIG will stay solid OFF, STA will flash showing the type of error.
STA flashes ones for 1S – master phone number is not set;
STA flashes permanently for 1S in a period of 2S – permanent hardware error .
Initial setup via USB
The initial setup of TCG120 controller is done with a computer running Windows 7 or newer Microsoft Windows operating system. After power-up, the controller should be connected to the computer with USB cable. Once the USB cable is connected, the operating system automatically starts to install the drivers for the communication with the device. The following message appears:
The following drivers will be installed:
- Microchip composite device
- USB serial port driver
If for some reason the USB serial port driver cannot be installed automatically, it must be installed manually. The driver can be downloaded from the TCG120 product page at www.teracomsystems.com. After successful driver installation, the device will be recognized as Mass storage, the following window appears on the screen:
The only file stored on the mass storage is a tool called “TConfig”. This tool
enables the communication between the TCG120 and PC. After starting the
TConfig tool, the following program will appear:
Pressing the “Start” button will start your web browser and display the
Monitoring page of your TCG120 controller.
Monitoring page
Monitoring page displays the current I/O state of TCG120 controller. The page
has 4 sections – “Sensors”, “Digital inputs”, “Analog inputs” and “Relays”.
For every parameter (sensor, input, relay) there is a description of up to 20
characters. The default descriptions can be changed in “Setup-Input/Output”
menu.
The Monitoring page is automatically refreshed every second.
Sensors section
All detected 1-Wire sensors are shown in this section. Sensor detection is
done either after power-on or by pressing “Scan for new sensors” button. All
found sensors are shown in ascending order refer their unique ID number. For
every sensor, there are a description, value, and ID information.
Teracom temperature sensors readings are shown in the Value 1 column. TSH2xx
temperature-humidity sensors have the 2nd parameter shown on the Value 2
column.
It is possible to lock a sensor on a specific position. To do this all sensors
should be added one by one. After every addition, a new scan should be done
and newly found sensor should be locked on the position. If all sensors are
locked, removing one “in the middle” will not change the positions of
following sensors after reset.
Digital inputs section Digital inputs can be used for monitoring the state
of discrete devices – motion sensor, door contact, relay contact, alarm output
etc.
Digital inputs are sampled every 10mS. The change of input status is
considered valid if the same value is read in 3 consecutive samples (30mS
).
Status of every input is shown by text and by color.
The default descriptions and status names can be changed in “Setup-
Input/Output”.
Analog inputs section
Analog inputs can be used for monitoring of DC voltage sources – analog
sensors, batteries, power supplies, solar panels etc.
Analog inputs are sampled faster, but the new actual value is changed in 0.5
seconds. All 250 readings between the value changes are averaged.
For every analog input “Unit”, “Multiplier” and “Offset” can be set in
“Setup-> Input/Output” section.
Relay section
The section displays the current state of the relays. Each relay can be
activated either remotely or locally from the status of a monitored parameter.
For locally activated relays a text description of the controlling parameter
is displayed rather than buttons. It is possible to disable locally control
for a while from checkbox “Enable”.
Pulse duration and parameters for local relay activation can be set separately
for each relay in “Setup->Input/Output->Relay outputs”. In the time when a
pulse command is executed, a new pulse command is rejected.
Setup
SMS/Call
SMS Setup
SMS Alarm recipients can be set in this section.
The “Master” has special rights to change the device settings using SMS
commands. This number always receive the SMS alarm messages.
The remaining 4 recipients can receive SMS messages if any of the parameters
is in alarm state. To receive SMS messages, the number should be enabled in
the checkbox “Alarm Notification”. These 4 recipients can also ask by SMS for
parameter state/value.
By pressing “send test SMS” button all SMS recipients will receive a test SMS.
All commands, their syntax, and answers are described in “Setup via SMS”.
Phone call Setup
The relay outputs of TCG120 controller can be controlled (only pulse) by a single call from an authorized number. The maximum number of the authorized numbers is 100. These numbers can be set manually or by sending an SMS message from the Master.
SMTP
SMTP Setup
Mail server address can be set either by hostname (for example
mail.teracomsystems.com) or IP address.
The e-mails can be sent with or without an encrypted connection.
The default SMTP port without encryption is 25. Almost all ISP’s block this
port to avoid hacker’s attacks. Ask your ISP for details.
The only supported method for encrypted connection from most of the public
email servers is TLS. TCG120 supports TLS 1.0, TLS 1.1 and TLS 1.2 with
RSA_WITH_AES_128_GCM_SHA256 and RSA_WITH_AES_128_CBC_SHA cipher suites. This
ensures successful operation with almost all public servers. STARTTLS is not
supported.
Be careful with the terms SSL, TLS, and STARTTLS used in email server
settings, supplied by the provider. Some providers as Gmail uses SSL instead
of TLS and TLS instead of STARTTLS. This can provoke mismatches with the port
number.
Sender e-mail, username, and password are standard authentication details. For
the most SMTP servers, sender’s e-mail and username are the same.
There is a button for server settings test with a feedback. In this test
sender and recipient of the e-mail is the same.
Alarm destination
Up to 5 email recipients can be set. Every recipient can be activated independently by a checkbox.
Email details
The subject, body header, body and body footer can be customized. For this customization, a set of keys is used. All they are described on the page.
Input/Output
- Sensors
For every sensor, a description, up to 20 symbols can be set. These descriptions will appear on the monitoring page, conditions page, XML/JSON data, SMS and e-mail alerts.
Analog inputs
For every analog input, a description, up to 20 symbols can be set. These
descriptions will appear on the monitoring page, conditions page, XML/JSON
data, SMS and e-mail alerts.
For every analog input, fields “Unit”, “Multiplier” and “Offset” are available
to convert the raw voltage/current into meaningful engineering units. The
shown value is calculated by:
DV[Un] = (AV – OF) * MU
Where:
- DV – displayed value;
- Un – unit;
- AV – real analog voltage from source;
- MU – multiplier in dimension [parameter/Volt];
- OF – offset.
Example:
For humidity sensor HIH-4000-003 following parameter (coming from datasheet)
should be set for fine work:
- Unit – %RH
- Offset – 0.826
- Multiplier – 31.74, the value is inversed of slope parameter (1/0.0315);
If the output voltage of this sensor is 3.198V on the monitoring page will be
shown 75.28% RH:
75.28 = (3.198 – 0.826) * 31.74
By default and after “Factory default settings” procedure:
- Unit – V
- Offset – 0.00
- Multiplier – 1.00
Digital inputs
For every digital input, a description, up to 20 symbols and states up to 20 symbols can be set. These descriptions will appear on the monitoring page, conditions page, XML/JSON data, SMS and e-mail alerts.
Relay outputs
For every relay description, up to 20 characters can be set. These
descriptions will appear on the monitoring page, XML/JSON data, SMS and e-mail
alerts.
The pulse duration can be different for both relays. The resolution is 0.1
second, the maximum pulse value is 3600 seconds.
Both relays can be activated either remotely by SMS/single call/HTTP command
or locally from the status of a monitored parameter. This setting is made from
the “Activated from” drop-down menu, the possible options are:
- SMS/HTTP – by selecting this option the relay outputs can be activated by SMS from authorized number or by sending HTTP command (detailed description in “Push mode” section);
- Phone call – by selecting this option the relay outputs can be activated (pulse only) by a single call from an authorized number.
For local activation, alarm conditions for different sources are used. They are set up in section “Setup->Conditions”. Following choices to assign a parameter to relay are possible:
- S? – “S” stands for “Sensor 1-Wire”. The relay is activated from a value measured from specified 1-Wire sensor and rules for ranges specified in “Setup->Conditions”. Question mark masks number from 1 to 4;
- Analog input? The relay is activated from a value measured from specified analog input and rules for ranges specified in “Setup->Conditions”. Question mark masks number from 1 to 2;
- Digital input? The relay follows the state of the specified digital input. Question mark masks number from 1 to 2;
The drop-down menu “Action on alarm/event” specifies which action will take place when the alarm/event occurs. Following choices are possible:
- Turn on – the relay will turn on and will remain on until the parameter stays in alarm state;
- Single pulse – the relay will be activated for the set pulse duration.
Conditions
This section is used for parameterization of the trigger and alert conditions for 1-Wire sensors, analog, and digital inputs.
1-Wire sensors and analog inputs
For every sensor two type of fields are presented – one for the trigger
conditions (“Min”, “Max” and “Hys.”) and another one for the wanted action.
“Min” and “Max” indicate the border of working range for the monitored
parameter. A “Max” trigger condition occurs when the value exceeds the trigger
set point. A “Min” trigger condition occurs when the value is lower than the
trigger set point. In both cases, the monitored parameter goes out of range.
Coming back in range for the monitored parameter is considered when the value
goes higher than (Min + Hys) or lower than (Max – Hys). Hysteresis (“Hys”) is
used to prevent excessively triggering when the value fluctuates around the
trigger point.
Example:
TCG120, TST100, and appropriate heater are used to control the room
temperature. The wanted minimum temperature is 19°C. The initial temperature
is 17°C.
TST100 is assigned to the first position for 1-Wire sensors.
For Relay1 local activation from Sensor1 is set.
Following parameters are set for Sensor1: Min=19, Max=100 and Hys=0.5
.
When the controller is switched on, Relay1 is immediately activated because
the monitored temperature is out of range. This switches the heater on. The
temperature rises.
When the temperature reaches 19.5°C (19.0 + 0.5) it goes in range (trigger
condition) and Relay1 is deactivated. The heater is switched off.
The temperature falls and when it reached 19°C it goes out of range (trigger
and alert conditions). The relay is activated (heater is switched on) and
e-mail is sent.
The “Max” value is set far enough from the wanted temperature to avoid
trigger/alert conditions around it.
For every sensor or analog input, there are 3 independent ways of alert when
there is an alarm condition – email, SMS, and post (HTTP post with XML/JSON
file). Each alarm notification method is activated by a checkbox.
Globally for all sensors and for all analog inputs, there is a checkbox
“Return notification”. If this option is chosen there will be notification
also when parameter returns in range.
Globally for all sensors and for all analog inputs, there is a “Notification
delay” parameter. It is very useful like a filter for short alarm conditions.
Digital inputs
For every digital input, the alarm state should be chosen – Open or Close.
When the input goes in alarm state 3 independent alert actions are possible –
email, SMS, and post (HTTP post with XML/JSON file). Each alarm notification
method is activated by a checkbox.
Globally for all digital inputs, there is a checkbox “Return notification”. If
this option is chosen there will be notification also when parameter returns
in range.
Globally for all digital inputs, there is a “Notification delay” parameter. It
is very useful like a filter for short alarm conditions.
In the time when the input is in an alarm state, on „Monitoring page“, the
appropriate input will be colored in red.
There are two delays – low-to-high and high-to-low for digital input change.
These delays are added to the standard delay of 30mS. They have 0.1-second
resolution and by default are zero.
These options can be used for additional filtering.
System
The page for some general settings.
System status
There is information about the general status of the controller here.
The only possible setting here is “Data in roaming” checkbox. By default, it
is disabled to avoid extra charges for data transfer in roaming.
If you are using another operator’s card, you must activate “Data in roaming”.
Otherwise, you will not be able to use all GPRS services – emails, HTTP Post,
NTP, etc.
GPRS setup
To set the GPRS connection it is necessary to enter the APN (Access Point Name). This setting can be different for each GSM service provider. By default, it is set to “internet”. Some providers may require also username and password.
Mobile network connection reset
For areas with low signal strength or where the mobile network frequently
drop/block, automatic restarting of the network connection can be used. This
could prevent permanently losing the connection with the device.
The automatic restart will be done once per day.
By default, the automatic restart is disabled.
General setup
The section for some general settings.
The temperature and pressure units can be changed with preferable ones.
Writing mode change the alignment in the WEB interface and SMS.
Hostname, System name, System location, and System contact are sent in
XML/JSON files and can be used for flexible identification of the device.
These parameters can be also included in the body of the e-mails.
The checkboxes on the right define what to be displayed on the “Monitoring
page”. By default, they all are enabled.
Device restart
In this section there are tools for full device restart and reset to factory default settings.
Time
Internal RTC (real-time clock) of the controller can be set automatically
only.
For automatic clock synchronization, the controller supports NTP (Network Time
Protocol) and all necessary parameters for automatic synchronization are
available in this section.
The clock synchronization is made on “Interval” time. If the attempt was not
successful, the next synchronization will be on “If not found” time.
Pressing the “Save and synchronize” button initiates time synchronization. The
information for “Status” in the blue box is very useful for the availability
of time server and Internet at all.
The current system time is sent in XML/JSON file when HTTP Post is enabled
By default, NTP server – time.google.com, port – 123, Timezone +00:00 and
interval of 12 hours.
Services
HTTP Post
HTTP Post is used for periodically upload an XML/JSON file to HTTP server by
HTTP requests (POST method). The XML/JSON file contains current status of all
monitored parameters and extra system information. The file format is chosen
from the drop-down menu.
The HTTP server can be addressed either by domain name or IP address.
The “Period” can be set between 1 and 255 minutes. This parameter can be
changed remotely also by HTTP API. The “Period” determines at what time the
control software receives up-to-date information from TCG120 and can,
therefore, make changes to some of the parameters. The shorter is “Period”,
the closer to the real-time operation is the system. On the other hand, as
shorter is the “Period” as higher is the data traffic through the mobile
network.
If the checkbox “Connect on any alarm” is selected, the HTTP Post request will
be sent in an alarm condition.
The “Key” field is user defined. Its value is sent in XML/JSON file and can be
used for device identification.
If “Process Answer” option is enabled, TCG120 will execute the commands, sent
by the remote server as an answer to HTTP Post.
A typical communication session between TCG120 and remote server is shown
below:
- Step 1 – HTTP POST request with XML data is sent to the remote server
- Step 2 – the server responds with HTTP response message, which contains “set r1=on” command as a brief text in the message body
- Step 3 – new HTTP POST request is sent to the server to confirm the reception of the “set r1=on” command.
- Step 4 – the server sends new HTTP response, which includes “set FIN” in the message body. This indicates that there are no pending commands and the session can be closed.
- Step 5 – when the Push period timer expires, TCG120 sends new HTTP POST request to the server
- Step 6 – the server answers with “set FIN” – there is no pending commands and the session can be closed.
HTTP Post command format:
set yyy=xxx
Where:
yyy is the command;
xxx is the parameter.
List of HTTP API commands:
Command | Description |
---|
r n =x
| Turn relay n ON (x=1) or OFF (x=0) ( n is 1 or 2 for the respective relay) r1=1 – will turn ON relay 1
r2=0 – will turn OFF relay 2
r1=1&r2=1| Turn both relays ON
r1=0&r2=0| Turn both relays OFF
r n =tg
| Toggle relay n
( n is 1 or 2 for the respective relay) r2= tg – will toggle relay 2
---|---
r n =pl
| Pulse relay n
( n is 1 or 2 for the respective relay) r2=pl – will pulse relay 2 *
|
vn f =10.0
| Set Min of analog input to 10.0
( f is 1 or 2 for the respective input) vn1=10.0 will set Min for analog input 1
vx f =20.0
| Set Max of analog input to 20.0
( f is 1 or 2 for the respective input) vx2=20.0 will set Max for analog input 2
vy f =1.0
| Set Hys of analog input to 1.0
( f is 1 or 2 for the respective input) vy1=1.0 will set Hys for analog input 1
sn pt =30.0
| Set Min of sensor to 30.0
( p is 1,2,3 or 4 for the respective sensor
t is 1 or 2 for the respective parameter of sensor) sn12=30.0 will set Min for sensor 1, parameter 2
sx pt =40.0
| Set Max of sensor to 40.0
( p is 1,2,3 or 4 for the respective sensor
t is 1 or 2 for the respective parameter of sensor) sx42=40.0 will set Max for sensor 4, parameter 2
sy pt =2.0
| Set Hys of sensor to 2.0
( p is 1,2,3 or 4 for the respective sensor
t is 1 or 2 for the respective parameter of sensor) sy41=2.0 will set Hys for sensor 4, parameter 1
|
delsen=xxxx| Notification delay for sensors
(xxxx is between 0 and 3600)
delanl=xxxx| Notification delay for analog inputs
(xxxx is between 0 and 3600)
deldig=xxxx| Notification delay for digital inputs
(xxxx is between 0 and 3600)
|
dda1=xxxx| Low to high delay for digital input 1
(xxxx is between 0 and 3600)
ddd1=xxxx| High to low delay for digital input 1
(xxxx is between 0 and 3600)
dda2=xxxx| Low to high delay for digital input 2
(xxxx is between 0 and 3600)
ddd2=xxxx| High to low delay for digital input 2
(xxxx is between 0 and 3600)
|
---|---
dataf=x| Data format XML/JSON for HHTP Post – 0 XML, 1 JSON
purl=yyy
| URL for HTTP Post to Server 1, where yyy is a full path to php file Example:
purl=212.25.45.120:30181/xampp/test/pushtest.php
pper=xxx| HTTP Post period in minutes
(xxx is between 1 and 255)
dk=xxx| HTTP Post key – xxx is up to 17 characters
save| Save all previous changes (except relays’ one) in the FLASH memory. As
every save reflects the FLASH cycles (endurance), this command should be used
very carefully.
pper=120&save – will set Post period to 120 seconds and save it
FIN| Terminate session
(it makes sense only for HTTP Post)
*In the time when a pulse command is executed, any new pulse command is rejected.
The typical monitoring application is shown in the picture below:
The structure of Status.xml is shown in Appendix A, while Status.json is shown in Appendix B.
Administration
Backup/Restore
TCG120 supports backup and restore of all user setting. All settings are saved in XML backup file. This file can be used after this for restore on many devices. This is very useful for multiplying similar settings to a batch of controllers
Firmware update TCG120 supports firmware update over the WEB
interface.
It is very simple. Download the latest firmware from
www.teracomsystems.com, choose the file and
press “upload” button.
Attention! Don’t turn off the power supply during the update. Turning off
the power supply will damage the device.
Setup via SMS
TCG120 supports SMS commands for parameters change and status reports,
including firmware update over the air. The commands will be executed if they
are sent from previous set 5 phone number. Some of the commands require Master
user rights.
Below is a list of the supported SMS commands. Note that the underscore
character “˽” must be replaced by one space character.
-
Set new master number
-
Rights: Master
-
Syntax: set˽master˽
-
Where
is a mobile number in the international format -
Example
-
Command: set master +359885885885
-
Answer: You are the new master!
-
-
Set SMS users numbers – this message is used to add/delete SMS users
-
Rights: Master
-
Syntax: set˽sms˽user˽
: -
Where
is a mobile number in the international format can be u1, u2, u3 or u4 -
Example
-
Command: set sms user u1:+359885887766
-
Answer: u1:+359885887766,u2,u3,u4
-
Command: set sms user u2:+359885999888
-
Answer: u1:+359885887766, u2:+359885999888,u3,u4
-
Command: set sms user u1:
-
Answer: u1, u2:+359885999888,u3,u4
-
-
Display SMS users numbers
-
Rights: Master, Users
-
Syntax: display˽sms˽users
-
Example
-
Command: display sms users
-
Answer: m:+359885885885,u1:+359885887766,u2:+359885999888,u3,u4
-
Set email users – this message is used to add/delete email users
-
Rights: Master
Syntax: set˽email˽user˽: -
Where
– a valid email address can be e1, e2, e3, e4 or e5 -
Example
-
Command: set email user e1:mail1@teracomsystems.com
-
Answer: e1: mail1@teracomsystems.com
-
Command: set email user e2: mail2@teracomsystems.com
-
Answer: e2: mail2@teracomsystems.com
-
Command: set email user e2:
-
Answer: e2:
-
-
Display email users – this message is used to request the email of a user
-
Rights: Master, Users
-
Syntax: display˽email˽
-
Where
can be one of: e1, e2, e3, e4 or e5 -
Example
-
Command: display email e1
-
Answer: e1: mail1@teracomsystems.com
-
Command: display email e2
-
Answer: e2: mail2@teracomsystems.com
-
-
Add call users – this message is used to add/delete call users
-
Rights: Master
-
Syntax: add˽call˽user˽
-
Where
is a mobile number in the international format -
Example
-
Command: add call user +359885111111
-
Answer: +359885111111 added
-
-
Display call users – this message is used to request a list of call users
-
Rights: Master, Users
-
Syntax: display˽call˽users˽
-
Where
– number from 1 to 10 -
If U=1, the answer will contain the numbers from 1 to 10. If U=5, the answer will contain the numbers from position 41 to 50 etc.
-
Example
-
Command: display call users 3
-
Answer: +359885122112+359885322343+359885431276+359885128734 +35988343434 +359885239854+359885233298+359885120954 +359885098765+35988345678
-
-
Remove call user – this message is used to delete call users
-
Rights: Master
-
Syntax: remove˽call˽user˽
-
Where
is mobile numbers in the international format
-
Example
-
Command: remove call user +359885111111
-
Answer: +359885111111 removed
-
-
Status of system – requests main parameters of the device
- Rights: Master, Users
- Syntax: status˽system
- Example
- Command: status system
- Answer: 01.03.2018,16:09:06,gprs=y,ss=80%,fw=2.02,call=2/100
-
Status of parameter – requests status of digital input (di), analog input (ai), relay (r) and sensor(s)
-
Rights: Master, Users
-
Syntax: status˽
-
Where
is one of: di1, di2, ai1, ai2, r1, r2, s11, s12, s21, s22, s31, s32, s41, s42 -
Example
-
Command: status di1
-
Answer: di1(Garage_door)=CLOSED
-
Command: status s22
-
Answer: s22(Office)=34.5%RH
-
-
Set a relay – this message is used to switch on/off the selected relay output
-
Rights: Master, Users
-
Syntax: set˽
= ˽[option] -
Where
is r1, r2 is 1, 0 [option] -w -
Example
-
Command: set r1=1
-
Answer: r1=on,r2=off
-
Command: set r1=0
-
Answer: r1=off,r2=off
-
Command: set r1=1 -w
-
Answer: no answer
-
Command: set r1=0 -w
-
Answer: no answer
-
-
Set pulse for a relay – this message is used to pulse the selected relay output
-
Rights: Master, Users
-
Syntax: set˽
= ˽[option] -
Where
< pulse relay > is pl1, pl2is 1 [option] –w -
Example
-
Command: set pl1=1
-
Answer: r1=on,r2=off
-
Command: set pl2=1
-
Answer: r1=off,r2=on
-
Command: set pl1=1 -w
-
Answer: no answer
-
Note: In the time when a pulse command is executed, a new pulse command is rejected
-
-
Post URL – sets URL for HTTP Post
-
Rights: Master
-
Syntax: set˽purl=
-
Where
is the address of remote server (domain or IP) -
Example
-
Command: set purl=www.teracomsystems.com:8801/posttest.php
-
Answer: post=off,period=5, url= www.teracomsystems.com:8801/posttest.php
-
-
Status URL – status URL’s for HTTP Post
- Rights: Master, User
- Syntax: status˽purl
- Example
- Command: status purl
- Answer: purl=www.teracomsystems.com:8801/posttest.php,post=on,period=5
-
Post period – sets HTTP Post period
-
Rights: Master
-
Syntax: set˽pper=
-
Where
is a number between 1 and 255 (minutes) -
Example
-
Command: set pper=10
-
Answer: post=off, period=10, url= www.teracomsystems.com:8801/posttest.php
-
-
Post on – sets HTTP Post on
- Rights: Master
- Syntax: set˽post=on
- Example
- Command: set post=on
- Answer: post=on, period=10, url= www.teracomsystems.com:8801/posttest.php
-
Post off – sets HTTP Post off
- Rights: Master
- Syntax: set˽post=off
- Example
- Command: set post=off
- Answer: post=off, period=10, url= www.teracomsystems.com:8801/posttest.php
-
Set a time server
- Rights: Master
- Syntax: set˽ts=url:port
- Example
- Command: set ts=time.google.com:123
- Answer: ts=time.google.com:123,tz=+02:00
-
Set a time zone
- Rights: Master
- Syntax: set˽tz=±hh:mm
- Example
- Command: set tz=+03:00
- Answer: ts=time.google.com:123,tz=+03:00
-
Set the hostname
- Rights: Master
- Syntax: set hostname=host_name
- Example
- Command: set hostname=teracomsystems
- Answer: hostname=teracomsystems
-
Restart – restarts the device
- Rights: Master
- Syntax: restart
- Example
- Command: restart
- Answer: Device is restarting!
-
Send test email – a message for sending a test email to the email users
- Rights: Master
- Syntax: test˽email
- Example
- Command: test email
- Answer: Emails are sending!
-
Send test SMS – a message for sending a test SMS to the authorized users
- Rights: Master
- Syntax: test˽sms
- Example
- Command: test sms
- Answer: This is a test SMS!
-
Update – a message for update the device over the air (GPRS)
-
Rights: Master
-
Syntax: update˽
-
Where
is a valid URL to public server, pointing update (.cod) file -
Example
-
Command: update www.teracomsystems.com/docs/TCG120-v2.02-P-S.cod
-
Answer 1: Downloading firmware…
-
Answer 2: Firmware file downloaded. Updating…
-
-
Following answers are also possible in different situations:
- Answer: File corrupt or wrong version!
- Answer: Can’t connect to server!
- Answer: Download time out!
- Answer: GPRS is not connected!
- Answer: Connection lost!
- Answer: Response timeout!
- Answer: Socket error!
-
Status Mobile network connection reset
- Rights: Master, User
- Syntax: status mncr
- Example:
- Command: status mncr
- Answer: mncr=on,10:00:00
-
Set Mobile network connection reset
-
Rights: Master
-
Syntax: set mncr=
,hh:mm:ss -
Where
– “on” or “off” -
Example: enable mobile network connection reset and set time
-
Command: set mncr=on,10:00:00
-
Answer: mncr=on,10:00:00
-
Example: disable mobile network connection reset
-
Command: set mncr=off
-
Answer: mncr=off,10:00:00
-
-
Set a sensor notification delay
-
Rights: Master
-
Syntax: set delsen=xxxx
where
xxxx – notification delay in seconds (0-3600) -
Example:
-
Command: set delsen=5
-
Answer: delsen=5
-
-
Set a sensor limits
-
Rights: Master
-
Syntax: set lspt=naaaa,xbbbb,ycccc
where
p sensor number; valid values 1,2,3 or 4;
t parameter of the sensor; valid values 1 or 2;
n stands for “Min”
aaaa value for limit “Min”;
x stands for “Max”
bbbb value for limit “Max”
y stands for “Hys”
cccc value for “Hys”. -
Example: set of sensor 1 parameter 1 (temperature):
-
Command: set ls11=n25.0,x35.0,y1.0
-
Answer: ls11=n25.0,x35.0,y1.0
-
Command: set ls11=n31.0
-
Answer: ls11=n31.0,x35.0,y1.0
-
Example: set of sensor 1 parameter 2 (humidity):
-
Command: set ls12=n45.0,x60.0,y1.0
-
Answer: ls12=n45.0,x60.0,y1.0
-
Firmware update
TCG120 supports firmware update over the WEB interface and over the air.
For firmware update over the WEB interface please see 7.4.2. FW update.
For firmware update over the air (GPRS) please follow the steps below:
- Upload the update file (.cod extension) on public HTTP server ;
- Send firmware update command (the syntax of the SMS message is described in 8. Setup via SMS).
Please note that only the Master can send this message.
The firmware will be downloaded and verified. The download via GPRS takes
around 3 minutes. If the file is correct, the Master will receive confirmation
SMS message. The update procedure takes around 2 minutes. Once the firmware
update is complete (about 5 minutes), TCG120 will restart.
Attention! Don’t turn off the power supply during the update. Turning off
the power supply will damage the device.
Factory default settings
TCG120 can be restored to its original factory default settings, following the steps below:
- Turn off the power supply;
- Press and hold the RESET button then turn on the power supply;
- STA and SIG LEDs will turn ON;
- Release the RESET button.
- The controller will restore its default settings.
Environment information
This equipment is intended for use in a Pollution Degree 2 environment, at altitudes up to 2000 meters. When the controller is a part of a system, the other elements of the system shall comply with the EMC requirements and shall be intended for use in the same ambient conditions.
Safety
This device must not be used for medical, life-saving purposes or for any
purpose where its failure could cause serious injury or the loss of life.
To reduce the risk of fire, only flexible stranded wire, with cross section
0.5mm² or larger for wiring of digital and analog inputs and relay output of
the device should be used.
To avoid electric shock and fire hazard, do not expose this product to
liquids, rain, or moisture. Objects filled with liquids, such as vases, should
not be placed on this device.
There is a risk of overheating (damage) of the controller, if recommended free
spaces to adjacent devices are not ensured. The joint part with external
component shall have space for attachment/removal of the cable after
installation.
Teracom does not guarantee successful operation of the product if the product
was used under conditions deviating from the product specifications.
Maintenance
Upon completion of any service or repairs to the device or once per year, safety check must be performed to determine that this product is in proper operating condition. Clean the device only with dry cloth. Do not use a liquid cleaner or an aerosol cleaner. Do not use a magnetic/static cleaning device (dust remover) or any kind of abrasive materials to clean the device.
Package content
- TCG120
- GSM antenna
- Quick start guide
Appendix
Appendix A
Structure of Status.xml file:
Monitor>
Appendix B
The JSON file structure:
{
“Monitor”: {
“DeviceInfo”: {
“DeviceName”: “TCG120”,
“HostName”: “TCG120”,
“ID”: “863071015406348”,
“FwVer”: “v2.08”,
“MnfInfo”: “www.teracomsystems.com“,
“SysContact”: “info@teracomsystems.com“,
“SysName”: “TCG120”,
“SysLocation”: “Location”
},
“S”: {
“S1”: {
“description”: “S1:TST1xx”,
“id”: “28C4C109030000C5”,
“item1”: {
“value”: “14.9”,
“unit”: “°C”,
“alarm”: “0”,
“min”: “-40.0”,
“max”: “85.0”,
“hys”: “8.5”
},
“item2”: {
“value”: “—“,
“unit”: “—“,
“alarm”: “0”,
“min”: “—“,
“max”: “—“,
“hys”: “—”
}
},
“S2”: {
“description”: “S2:TSH2xx”,
“id”: “015225B71700FF45”,
“item1”: {
“value”: “22.6”,
“unit”: “°C”,
“alarm”: “0”,
“min”: “-40.0”,
“max”: “85.0”,
“hys”: “8.5”
},
“item2”: {
“value”: “57.9”,
“unit”: “%RH”,
“alarm”: “0”,
“min”: “0.0”,
“max”: “100.0”,
“hys”: “10.0”
}
},
“S3”: {
“description”: “S3”,
“id”: “0000000000000000”,
“item1”: {
“value”: “—“,
“unit”: “—“,
“alarm”: “0”,
“min”: “—“,
“max”: “—“,
“hys”: “—”
},
“item2”: {
“value”: “—“,
“unit”: “—“,
“alarm”: “0”,
“min”: “—“,
“max”: “—“,
“hys”: “—”
}
},
“S4”: {
“description”: “S4”,
“id”: “0000000000000000”,
“item1”: {
“value”: “—“,
“unit”: “—“,
“alarm”: “0”,
“min”: “—“,
“max”: “—“,
“hys”: “—”
},
“item2”: {
“value”: “—“,
“unit”: “—“,
“alarm”: “0”,
“min”: “—“,
“max”: “—“,
“hys”: “—”
}
}
},
“AI”: {
“AI1”: {
“description”: “Analog Input 1”,
“value”: “0.889”,
“unit”: “V”,
“multiplier”: “1.000”,
“offset”: “0.0000”,
“alarm”: “0”,
“min”: “0.000”,
“max”: “2.000”,
“hys”: “0.500”
},
“AI2”: {
“description”: “Analog Input 2”,
“value”: “5.726”,
“unit”: “V”,
“multiplier”: “1.000”,
“offset”: “0.0000”,
“alarm”: “1”,
“min”: “0.000”,
“max”: “2.000”,
“hys”: “0.500”
}
},
“DI”: {
“DI1”: {
“description”: “Digital Input 1”,
“value”: “OPEN”,
“valuebin”: “1”,
“alarmState”: “CLOSED”,
“alarm”: “0”
},
“DI2”: {
“description”: “Digital Input 2”,
“value”: “OPEN”,
“valuebin”: “1”,
“alarmState”: “CLOSED”,
“alarm”: “0”
}
},
“R”: {
“R1”: {
“description”: “Relay 1”,
“value”: “ON”,
“valuebin”: “1”,
“pulseWidth”: “5.0”,
“control”: “0”
},
“R2”: {
“description”: “Relay 2”,
“value”: “ON”,
“valuebin”: “1”,
“pulseWidth”: “2.0”,
“control”: “0”
}
},
“HTTPPush”: {
“Key”: “”,
“PushPeriod”: “1”
},
“signalpercent”: “80”,
“hwerr”: “”,
“Alarmed”: “1”,
“Scannig”: “”,
“Time”: {
“Date”: “05.02.2019”,
“Time”: “12:11:02”
},
“NetworkInfo”: {
“Name”: “Mobiltel EAD”,
“SC”: {
“MCC”: “284”,
“MNC”: “01”,
“LAC”: “28200”,
“CID”: “38449”,
“SQ”: “-63”
}
}
}
}
Appendix C
Fig.1
Fig.2
References
- Remote monitoring and control solution for your automation challenges
- Mixed-signal and digital signal processing ICs | Analog Devices
- Remote monitoring and control solution for your automation challenges
- Remote monitoring and control solution for your automation challenges
Read User Manual Online (PDF format)
Read User Manual Online (PDF format) >>