2. User Guide

Describing Elecard CodecWorks

Elecard CodecWorks is a professional software solution for encoding/transcoding, real-time multiplexing into MPEG-2/AVC/HEVC with up to 16K resolution supporting multiscreen encoding and HLS/MPEG-DASH adaptive streaming technologies. CodecWorks operates on the base of a wide range of hardware.

Activation

There are the following ways to activate Elecard CodecWorks:

  • HWkey License — a unique identifying code is compiled using a special utility based on the target PC hardware configuration, and CodecWorks build is tied to this code. To receive the utility, contact Elecard Technical Support Team or your project coordinator;

  • HASP License — Elecard mails a HASP key which has a unique code and should be plugged into a PC where CodecWorks is going to be used.

Licensing and Technical Support

Elecard CodecWorks is available as a demo version or a registered product. By installing, copying, or otherwise using the SOFTWARE PRODUCT or any UPDATES, you agree to be bound by the terms of the “Elecard” End-User License Agreement (“EULA”). This EULA is a legal agreement between you (either an individual or a single entity) and Elecard for the “Elecard” software product(s) accompanying this EULA, which include(s) computer software and may include “online” or electronic documentation, associated media, and printed materials (“SOFTWARE PRODUCT”).

For sales and licensing information, contact the Elecard Sales Department.
For technical support, contact the Elecard Technical Support Team.

System Requirements

When choosing servers for CodecWorks, the following should be taken into consideration:

  • CPU performance is of crucial importance for real time encoding processes. Take it into account when you choose hardware for the encoding server.

  • The disk selected for the program installation should have enough free space for saving the system log (for highly detailed logs) and memory dump files (if the application fails or abnormally closes).

  • QuickSync hardware accelerated encoding requires an integrated Intel® Graphics processor.

  • Nvidia hardware accelerated encoding requires an Nvidia graphics card.

  • To manage an encoding server via the SNMP protocol, the corresponding service must be installed in the system.

System requirements depend on several factors:

  • the task type (encoding, transcoding, multiplexing, etc.);

  • the format, resolution and bit rate of input/output streams;

  • signal processing functions (frame size changing, deinterlacing, frame conversion, etc.);

  • the number of channels to be processed.

The minimal system requirements recommended for proper operation of Elecard CodecWorks:

  • Windows 10/11/ Server 2019(64 bit), Linux Ubuntu Desktop/Server 22.04/24.04

  • SSD/HDD from 256 GB

  • RAM 16 GB (two-channel mode is required)

CPU encoding

GPU encoding (Intel QuickSync)

GPU encoding (Nvidia)

CPU (Intel from 4 gen, Xeon e7/5/3 v3 and higher, Xeon E/W/D, AMD zen gen and higher)

CPU (Intel from 5 gen, Xeon e3, Xeon E)

CPU (Intel from 5 gen, Xeon e3, Xeon E)

Graphics card is not required

An integrated or discrete Intel Graphics

Nvidia card

CodecWorks outgoing traffic:

  1. 1535/TCP (required), 53700/TCP (optional) — used for communication between the different CodecWorks services on the network.

  2. 1545/UDP (required) — used to discover other CodecWorks services in the network.

  3. 8088/HTTP/HTTPS (required, default) — used for communication with the browser as well as for downloading logs and task configurations.

  4. 8080/HTTP — used for the OTT pull mode streaming.

  5. 162/UDP (default) — used for sending SNMP trap messages. A port can be configured on the SNMP notifications settings page.

Installation

Follow the installation procedure as described for your operating system:

Windows

  1. Run Elecard CodecWorks Setup and follow the instructions.

  2. The software will be installed to C:\Program Files\Elecard\Elecard CodecWorks

  3. The created schemas will be saved to C:\ProgramData\Elecard\CodecWorks

Ubuntu

Before installation, we recommend to run the following commands:

sudo apt update
sudo apt upgrade

To install all packages 1 at once, run the installer:

sudo apt install ./Elecard-CodecWorks*.deb
The software will be installed to /usr/bin/Elecard/CodecWorks.
The created schemas will be saved to /etc/Elecard/CodecWorks.

Note

For correct installation, Internet access is required to download dependencies. However, our technical support team can prepare a standalone package for your server in case there is no direct access to the Internet.

1

Installing CodecWorks on Ubuntu involves installing the following parts:

  1. Server — the server part of CodecWorks responsible for the work of tasks, transcoding/multiplexing.

  2. Base — the base installation includes a console manager for managing CodecWorks; this option is suitable for scripting.

  3. GUI — the graphic control application. Optional installation.

  4. Web — the web interface.

Additional Driver Installation

Drivers for Intel QS Ubuntu

sudo apt install libdrm2 libva2 libva-drm2 libigdgmm12 intel-media-va-driver-non-free libmfx1
sudo usermod -a -G video <user>
sudo usermod -a -G render <user>
sudo reboot

Specify a real username instead of <user>. To validate the driver installation, use the command:

sudo vainfo

Drivers for Nvidia Ubuntu

sudo apt install nvidia-cuda-toolkit

To validate the driver installation, use the command:

sudo vainfo

Decoding AC3 Audio

sudo apt install gstreamer1.0-libav

Deletion

To remove Elecard CodecWorks from your computer, follow the steps that are described for your operating system:

Windows

  1. Open the folder C:\Program Files\Elecard\Elecard CodecWorks and run Uninstall.exe

  2. To complete the uninstallation of Elecard CodecWorks, follow the onscreen instructions.

Ubuntu

Run the following command:

sudo apt remove elecard-codecworks*

Features

CodecWorks provides the following functionality:

  • Adaptive streaming support over HLS/MPEG-DASH protocols;

  • Encoding schemas configurator;

  • Centralized control over several encoding servers via GUI and web-interface;

  • Accelerated GPU-based encoding for highest density possible;

  • A mechanism for quick back up in 1+1, N+1, N+M modes;

  • Redundancy mode and immediate automatic failover to a redundant source in case of input stream absence, CC errors, or if PID loss occurs;

  • Seamless stream redundancy via the SMPTE-2022-7 protocol;

  • Error notifications over the SNMP protocol;

  • Activation of the Color Bar Generator in case of stream input absence, CC errors, or if PID loss occurs.

  • Stream encryption using a BISS key or CAS SimulCrypt;

  • Ability to overlay the logo, change resolution and frame rate, convert interlaced video to progressive video, adjust audio levels.

Product Structure Description and Module Purpose

One operating system may contain only one encoding server that comprises the following modules:

  • Encoding console is a software designed to create (start) an encoding schema. It receives and processes control commands from the manager (via an intermediary layer, i.e. CodecWorks dispatcher), as well as controlling license restrictions. Depending on the number of licenses purchased, one or more consoles are started per server. An encoding console is represented by a task in the web interface.

  • Dispatcher is a software (a console or a system service, depending on the user’s choice) that monitors encoding consoles, their initial startup, emergency restarts, communication with other devices on the network. It also obtains the server load statistics. One channel manager is run on one server.

  • Watcher is a software (a console or a system service, depending on the user’s choice) that monitors the dispatcher operation and its emergency restart. Watcher, dispatcher, encoding consoles can be started as a system service or console applications, depending on the user’s choice.

  • CodecWorks Manager is a GUI software that controls encoding console operation, configures and starts encoding schemas according to user actions, and collects statistics. One manager can be used to control multiple servers.

  • CodecWorks Manager (console) is a console application for controlling the operation of the encoding server from the command line.

  • Encoding schema is an XML document that contains all the information about the structure of a DirectShow encoding graph or a GStreamer pipeline and its settings (it is similar to a GRF file used by the Graph Edit application). Usually, the schema can only be used on a specific server and with a specific input stream.

  • Encoding schema configurator is a module designed to create encoding schemas based on a set of predefined sections. Each section is a fragment of an encoding graph describing its structure and parameter values, designed to perform a specific function (stream reception, decoding, encoding, etc.). In addition, templates can be used to prepare schemas.

  • Template is an XML document that is used for creation of encoding schemas. It contains a limited set of sections defining the range of encoding tasks for which the template is designed. The use of templates is advisable in cases when complex non-standard encoding schemas are required. Templates are prepared by Elecard specialists.

Web Interface

Authentication and Managing User Roles

User authentication is used for differentiating access rights between various user groups. It also provides the possibility to identify the author of changes.
When launching CodecWorks for the first time, use the default Administrator username and admin password to log in the web interface. To change the password or add a new account, go to the user permissions page.
To open the page, click the username in the right upper corner and select the Security Settings option from the menu. User groups are displayed in the left part of the window. They unite users with similar management rights.

The Administrators group is default and cannot be deleted. To create a new group, click the Add Group button, and specify the group name. To save changes, click the Apply button. When clicking a group, its settings will open in the right part of the page. In the Permissions tab, you can set permissions for actions with the CodecWorks service and with encoding consoles. In the Users tab, the members of a chosen group are listed. In this tab, you can create users or change their passwords. To set a new password, select a user and click the editUser icon. Type in the old password, then fill in a new one and confirm it. Click Apply.

Task Configurator

To open the task creation page, click the Create Task button on the Home page. The page contains the Source, Transform, and Output columns. To the right is a panel for working with the settings of elements that will be added to the columns. You can change the task name in the field above the panel.

_images/taskCreation_en.png

First, add a source. Select a protocol on the panel to the right and click the Add button. Fill in the source data and click the green circle with a check mark. The IP (demux) source type implies UDP/RTP/SRT/RIST protocols with subsequent demultiplexing for further stream processing.

You can create a source template to avoid inputting data each time. To do this, click the Create Source Template button without selecting a source. Select a protocol and input data as described above. Then provide the template name and click Save & Exit. The source template will be saved in the (Cached) Network section.

After inputting and confirming data, CodecWorks will try to receive a stream and show available services of the source. If you click the downward arrow to the right of the service name, a list of all its elementary streams will open.

To the left of each service or stream name, there is a checkbox. You can add a service or a stream to the transform stage by ticking the corresponding checkbox. Alternatively, to exclude a service or a stream from the schema, deselect the checkbox. Confirm your choice by clicking on the green circle with a check mark.

Next, proceed to transcoding settings by clicking on the element in the Transform column. On the panel to the right, you will see elementary streams for a certain service, the name of which will be above the list of streams. If you have selected multiple services during the previous stage, you will see multiple names. You can switch to another service by clicking on its name. For each elementary stream, select the required encoding format. Next, select a streaming protocol in the elementary video stream and click Apply to all.

Go to the Output column and fill in the fields required for streaming. If necessary, change the schema name; then click Save & Exit. The created task will appear in the list of inactive tasks on the home page.

You can add tasks with a redundant source. To do this, add a second source with the IP(reserving) type before saving the task. Specify the fields required for a redundant source, and CodecWorks will make this source redundant.

Note

To prepare multi-bitrate tasks, the templates for multi-profile tasks should be added to the installation packet. You can contact technical support to add the necessary templates for a specific task.

Managing Task

As soon as the task is created, it appears in the Inactive Tasks list. To the left of each task name, there are management buttons.

For new tasks that have never been started, the Start startButton and Prepare prepareButton buttons will be displayed. When clicking the Prepare button, the coding schema is uploaded to the console but is not run. Thus, you can view the schema and edit it before starting, if necessary. If you want to run the task without viewing and editing the schema, click the Start button.

For tasks that have been started and then stopped, the Start and Restart restartButton buttons will be available. The latter one restarts the coding console. After you start the task, it will appear in the Active Tasks list, and the Start button next to it will be replaced with the Stop stopButton button.

Each task in the list has a checkbox to the left of the management buttons. If you tick the checkbox of a certain task, you will see a panel below that will have the Start, Stop, and Restart buttons for the selected task. The panel will also have the Rebuild rebuildButton and Delete deleteButton buttons. A click on the first button rebuilds the encoding process when the input stream changes. If you want to delete a task, click the second button. The panel also holds a box where you can change the task configuration.

When clicking a task name, a page with the statistics and parameters of this task will open. On this page, you can also view the logs of a particular task.

Configuring Server

In the General tab on the Service Settings page, you can change the Service name, Multicast address for searching CodecWorks services in the network, IP address of a network interface that will be used for that, and IP address of a web interface. The Service start delay (s) parameter specifies the delay before starting a CodecWorks service.

Note

When 0.0.0.0 is specified as the network interface, all available network interfaces will be used.

Configuring Service Redundancy

In the Source Redundancy tab on the Service Settings page, you can change the settings of conditions under which CodecWorks switches to a redundant source. A failover to a redundant source occurs when one of the following events takes place:

  • CC Errors — a failover occurs if 15 or more errors are detected every second for 5 seconds. The state ends when no errors are detected for 10 seconds.

  • No video signal for/no audio signal for — implies the PID Loss/PMT changed states and the absence of audio/video data for 3 seconds. The state ends when video data becomes present for 3 seconds, and audio data is present for 2 seconds.

In case the source has not any redundant sources, and one of the events occurs, the CBG will be enabled if it is allowed in the task.

The Switch back to primary source option allows reverse switching to the primary source when it restores. If this parameter is disabled, the redundant source is considered equal to the primary one, and the failover between two sources occurs only in case of problems with the working stream.

Log and Rotation Settings

In the Logging tab, you can specify a folder for storing log files. Also, you can set logging levels for dispatcher, SNMP, access, and server events. When setting up consoles, you can specify the same logging level for all consoles or select a logging level for a certain console.

In the Rotation tab, you can set a storage period and size for the following files:

  • Log files — system messages recorded into the log.

  • Crash dumps — process dumps created in various situations caused by incorrect operation.

  • Redundant copies of schemas — schemas saved as backups in the console /backup folder after each schema setting change so that these changes can be reversed.

You can also specify a rotation period for log files, which is measured from the moment the dispatcher starts. During rotation, the storage period and file size thresholds are checked. Files exceeding the thresholds will be deleted.

SNMP

Configuring the SNMP Agent

Install the SNMP service:

sudo apt-get install snmpd

Specify a community and path to a CodecWorks agent in the etc/snmp/snmpd.conf file:

rwcommunity elecard
rocommunity elecard

Indicate a network interface address for the SNMP agent:

agentaddress interface address,[::1]

At the end of the file, add the path to the agent:

dlmod libcwSnmpAgent /bin/Elecard/CodecWorks/libcwSnmpAgent.so

Restart the SNMP service:

sudo systemctl restart snmpd.service

Note

If you reinstall Elecard CodecWorks in the future, it is necessary to restart the SNMP service too.

Configuring SNMP notifications

CodecWorks offers a possibility to send SNMP notifications to a desired trap point. They are used to report about problems related to an input stream, the start/stop of encoding schema work, a failover to a redundant source, etc.

The installed version of CodecWorks contains two MIB files:

To configure SNMP notifications, go to the SNMP Settings section on the Service Settings page. The section contains the Community Settings and Severity Levels tabs. You can show or hide tabs using the SNMP Settings checkbox.

In the Community Settings tab, you can create a new SNMP community. To do this, click the Add button, enter the community name and click Ok. Then you need to add a destination address to which notifications for the selected community will be sent. First, click on the plus sign to the left of the created community name to show the list of destination addresses. Then, click the Add button, enter the address and port; click Ok. If you need to use multiple addresses, repeat adding destination addresses.

The Severity Levels tab contains the Task States and Events sections. In these sections, you can set up sending notifications for task states and events that should be tracked.

  • Events are mostly connected to a state change, e.g. a failover to a redundant server. The notifications of this type come only once. To enable tracking of a certain event, tick the checkbox to the left of its name and select the severity level of the event.

  • Task States have both active and cleared levels indicating the beginning and the end of an event. The notifications are sent twice: when entering an event based on specific triggers and when exiting the event. To enable tracking a certain state, tick the checkbox to the left of its name and set the severity level in the Active Level and Cleared Level columns.

Structure of SNMP Notifications

There are four types of SNMP trap notifications described in the ELECARD-CODECWORKS-MIB.mib file.

Events for CodecWorks service and for active tasks.
States of CodecWorks service and active tasks.

1. Notifications about changing the CodecWorks service state (codecWorksState)

Such notifications characterize a certain state of the service and are sent twice: when an event occurs and when it ends. The notification contains the following fields:

  • status — a state status (active — if a state has occurred, cleared — if a state has ended);

  • trapName — a notification name;

  • trapMessage — a detailed notification description;

  • severityLevel — a notification severity level;

  • referenceNumber — a notification sequence number;

  • sequenceId — a parameter linking the start and end of a state (a state identifier is unique for each pair of notifications).

2. Notifications about an event that has occurred with the CodecWorks service (codecWorksEvent)

These notifications are sent only once when a certain event occurs. Such a notification contains the following fields:

  • trapName — a notification name;

  • trapMessage — a detailed notification description;

  • severityLevel — a notification severity level;

  • referenceNumber — a notification sequence number.

3. Notifications about a change in the state of CodecWorks encoding consoles (codecWorksChannelState)

Such notifications indicate a certain state of the encoding console and are sent twice: when an event occurs and when it ends. Such a notification contains the following fields:

  • status — a state status (active — if a state has occurred, cleared — if a state has ended);

  • trapName — a notification name;

  • trapMessage — a detailed notification description;

  • severityLevel — a notification severity level;

  • channelNumber — an encoding console number;

  • taskName — an encoding schema name;

  • referenceNumber — the sequence number of a notification;

  • sequenceId — a parameter linking the start and end of a state (a state identifier is unique for each pair of notifications).

4. Notifications about events of an encoding console (codecWorksChannelEvent)

These notifications are sent once a certain event happens. Such a notification contains the following fields:

  • trapName — a notification name;

  • trapMessage — a detailed notification description;

  • severityLevel — a notification severity level;

  • channelNumber — an encoding console number;

  • taskName — an encoding schema name;

  • referenceNumber — the sequence number of a notification.

Possible Values of Some Notification Fields

The severityLevel field can take the following values:

  • ok (1);

  • warning (2);

  • error (3);

  • major (4);

  • fatal (5).

The values of trapName and trapMessage fields are described in the table below.

trapName

trapMessage

Description

Backup server

Host <host:port> is down, backup started

Backup server start

Service start

Service started

Service start

Service stop

Service stopped. <reason>

Service disabling

Console stop

<reason>

Stop of encoding console

Channel error

<reason>

Error when transcoding

Stream switch

Stream switch

Switching to other source

Channel start player error

<reason>

Encoding start error

Channel start error

<reason>

Encoding console start error

Transcoding stop

Transcoding stopped

Transcoding stop

Transcoding start

Transcoding started

Transcoding start

No video signal

Stream <stream number> - no video

No video signal

No video decoded

Stream <stream number> - no decoded video frames

Video stream cannot be decoded

No audio signal

Stream <stream number> - no audio

Audio signal is not found

No audio decoded

Stream <stream number> - no decoded audio frames

Audio stream cannot be decoded

No input

Stream <stream number> - no input

Input stream is not found

No output

Stream <stream number> - no output on HLS Stream
Stream <stream number> - no output on DASH

HTTP protocol error when trying sending a segment

TS errors

Stream <stream number> - CC errors

Errors in transport stream

Color bar

Stream <stream number> track <track number> - generating color bar
Stream <stream number> track <track number> - generating silence

Enabling the CBG by video or silence in audio streams

Setting Up Options

Options are presented as a table of service parameters that the user can utilize at their discretion. The user can use a set of existing options and also add their own.

Options can be added or configured via the web interface.

To add an option, click PlusIcon—a new row will appear in the table with the following columns:

  • Name — the name of the option. Enter your own name or select one of the existing entries.

  • Description — the option description.

  • Value — the option value, which can be an integer or a string.

    When selecting one of the existing options, the default value will be set automatically (if available).

To delete an option, click the deleteButton button.

Note

Existing options with the app prefix are service parameters of the application—such parameters can be interpreted by the application itself and affect its behavior. Avoid using this prefix when adding new entries: new app options may conflict with future versions of the application and unpredictably affect the service’s operation.

Click to expand the drop-down list with descriptions of the existing app options

app.LogDirectory

The directory where CodecWorks writes log files. By default, this is the log directory for the current application domain.

app.GraphToROT

[Windows][DirectShow] Registers supported DirectShow graphs in the Windows Running Object Table (ROT) so external graph tools can connect to them. By default, the parameter is not specified (mode disabled); 1 enables it, 0 disables it.

app.StartDelay

The total latency before consoles start in seconds. Prior to total latency, individual console latency is applied. Default value: 0 (no additional latency). A positive value sets the interval.

app.StatLogTime

The statistics write interval in seconds; app.Reserved2 selects CSV output. Default value: 0 (statistics logging disabled). A positive value sets the interval.

app.DumpLevel

Controls the creation and detail level of crash dumps. By default, the parameter not specified, and the built-in mode is used; on Windows, -1 disables dumps, and -2 creates a full memory dump.

app.IgnoreAutoRun

Prevents the graph from starting automatically, even if AutoRun is enabled in the channel configuration. By default, the parameter is not specified (mode disabled); 1 enables it, 0 disables it.

app.HideConsoles

[Windows] Launches child processes on Windows without visible console windows when enabled. Default value: 1 (mode enabled); 0 disables it.

app.RebuildSchema

Rebuilds the schema when the graph launches. By default, the parameter is not specified (mode disabled); 1 enables it, 0 disables it.

app.SoundAlertFile

The audio file for sound alerts. By default, the parameter is not specified; the component’s built-in behavior applies.

app.StartTimeout

The maximum graph start-up time in seconds, after which the console is restarted. Default value: 10.

app.AutoConnect

Automatically connects input and output sections when building a schema at the configuration step. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.AutoStop

Stops the graph upon receiving End-of-Stream. Default value: 1 in CS (stop enabled)—not specified in other domains; 0 disables the stop.

app.DefaultDecoder

The preferred default decoder, such as Soft, QuickSync, or Nvidia, if the schema does not require a specific decoder. By default, the parameter is not specified; the component’s built-in behavior applies.

app.AvailableHardwareAcceleration

Sets a comma-separated list of hardware acceleration types available to the client. By default, the parameter is not set, and all known types are allowed; a non-empty value restricts the available list.

app.FastRebuild

Uses fast graph rebuilding without waiting for all demux pins. By default, the parameter is not specified (mode disabled); 1 enables it, 0 disables it.

app.RebuildTimeout

The maximum waiting time for demux pins during graph building or rebuilding in seconds. Default value: 10.

app.RestartAfterRebuild

Restarts the console after rebuilding the graph. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.PreferredClock

A comma-separated list of preferred graph clock filter names. By default, the parameter is not set; the component’s built-in behavior applies.

app.UI

Selects the new user interface data model with additional info about the graph, statistics, URL, and license. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.GraphRestartInterval

The minimum interval between event graph restarts in seconds. By default, the parameter is not set; the component’s built-in behavior applies.

app.GPU

Selects the GPU load metric displayed in the user interface. By default, the parameter is not set; the component’s built-in behavior applies.

app.SourceReservingRestart

Restarts the console when switching to a redundant source. In GStreamer, a restart is always used. By default, the parameter is not specified (mode disabled); 1 enables it, 0 disables it.

app.PlaybackConsoles

A comma-separated list of playback console numbers and ranges. By default, the parameter is not set; the component’s built-in behavior applies.

app.WsPort

[Deprecated] Sets the port of the legacy WebSocket endpoint. By default, the parameter is not set; port 9003 is used for Converter Studio and 9002 for other domains.

app.WsLog

[Deprecated] Logs requests and responses when communicating with the dispatcher over WebSocket. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.SafeStop

Stops graph filters individually, from sources to sinks, and then stops the entire graph. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.RestartOnStartupError

Restarts the console after a graph startup error. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.ServiceAsUser

[Windows] Runs the dispatcher process with the credentials of the logged-in user. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.UseProxy

Enables the use of a proxy; the explicit proxy address is set by the app.Proxy parameter. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Proxy

The explicit proxy address. If not set, the platform’s system proxy may be used. By default, the parameter is not set; the component’s built-in behavior applies.

app.CheckFilterAvailability

Restricts the processing of schemas and templates to filters available in the current system. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.ReservingPingTimeout

The maximum waiting time for a response from a reserved node to a ping request in milliseconds. Default value: 1000.

app.FailedAutoRunRestartTimeout

Sets the retry time for a failed automatic graph startup before the console is restarted. By default, the parameter is not set, and timeout-based restart is disabled; a positive value sets the timeout in seconds.

app.System.Statistics.GPU.Update.Timeout

The GPU statistics update interval in milliseconds. Default value: 1000.

app.System.Statistics.GPU.Metric.Type

[Linux] Selects the GPU metric used when collecting system statistics on Linux. By default, the parameter is not set; the component’s built-in behavior applies.

app.Channel.Redundancy.Source.NoStreamSwitch.Time

The no-data time in milliseconds, after which a redundant source is considered inactive. Default value: 5000.

app.Channel.Redundancy.Source.StreamSwitch.StopGraph

Stops the graph when switching between redundant sources. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Channel.Graph.Stop.Method.NWSource

Stops the graph via the Network Source stop parameter so that End-of-Stream could spread on the subsequent components. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Channel.Graph.Demuxer.Pin.PreferredSection

The preferred schema section for the demux pin. By default, the parameter is not set; the component’s built-in behavior applies.

app.Channel.Graph.Build.Validation

Continuously validates graph abstractions by creating and connecting native components during configuration. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Channel.Graph.Build.Demuxer.Timeout

The number of attempts to find new dynamic demux pins during graph building. By default, the parameter is not set; the component’s built-in behavior applies.

app.Channel.Graph.Load.Parameters.SkipDefault

Skips applying parameters the values of which match the default values when loading the graph. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Channel.Terminate.Dump

Creates a crash dump on forced termination of the console. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Dispatcher.Terminate.Dump

Creates a crash dump on forced termination of the dispatcher. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Dispatcher.StopProcess.Timeout

The time given to a child process to stop before it is forced to terminate by the dispatcher in seconds. Default value: 20.

app.Login.Session.MaxAge

The maximum login session age, in hours. Default value: 24.

app.HostStatusUpdateTimeout

Sets the interval for collecting and storing script-based node statistics from consoles in minutes. By default, the parameter is not set; the component’s built-in behavior applies.

app.Clock.SystemAndGPSOffset

The offset between the Unix epoch and the GPS epoch in seconds. Default value: 315964800.

app.Clock.GPSAndUTCOffset

The current offset between GPS and UTC time, accounting for leap seconds. Default value: 18.

app.System.SNMP.Trap.Resend.Active.Period

[SNMP] When built with SNMP support, sets the resend interval for active alarm traps in milliseconds. By default, the parameter is not set; the component’s built-in behavior applies.

app.System.SNMP.Trap.Resend.Cleared.Period

[SNMP] When built with SNMP support, sets the resend interval for cleared alarm traps, in milliseconds. By default, the parameter is not set; the component’s built-in behavior applies.

app.System.SNMP.Trap.Resend.Cleared.Count

[SNMP] When built with SNMP support, sets the number of additional sends for each cleared alarm trap. By default, the parameter is not set; the component’s built-in behavior applies.

app.GRPC.Deadline

The deadline for gRPC requests, for example between the dispatcher and the console, in seconds. Default value: 10.

app.GRPC.Console.ReconnectBackoff.Init

The initial backoff for console gRPC reconnection in milliseconds. Default: 200.

app.GRPC.Console.ReconnectBackoff.Min

The minimum backoff for console gRPC reconnection in milliseconds. Default: 200.

app.GRPC.Console.ReconnectBackoff.Max

The maximum backoff for console gRPC reconnection in milliseconds. Default: 3000.

app.UseDeprecatedGraphDetails

[Deprecated] Uses the legacy GraphDetails implementation. Default value: 0 (mode disabled); 1 enables it.

app.Probe.Update.Period

The automatic Probe update interval in seconds. Default value: 10.

app.GRPC.SafeRequest.Enabled

Checks the gRPC connection between the dispatcher and the console before sending a request. Default value: 1 (mode enabled); 0 disables it.

app.GRPC.SafeRequest.Timeout

The time given to the preliminary gRPC connection check in milliseconds. Default value: 500.

app.NetworkWatcher

Monitors changes to network interfaces. Default value: 1 (mode enabled); 0 disables it.

app.NetworkWatcher.ResetAttemptsTimeout

The interval between attempts to reconnect affected listeners and senders after network issues, in milliseconds. Default value: 2000.

app.Sandbox.IdleTimeout

The idle time of the cwNativeSandbox remote configuration process before termination, in minutes. Default value: 60.

app.RemoteServicesController.Timeout

The lifetime of the search for remote services controller after the last request, in seconds. Default value: 30.

app.RemoteTask.Timeout

The retention time of an unused timeout remote task in the controller, in seconds. Default value: 60.

app.RemoteServicesController.ON

Enables the remote services management controller. Default value: 1 (mode enabled); 0 disables it.

app.RSC.LegacyPerformance

Reads and publishes legacy server performance info in cluster announcements. Default value: 0 (mode disabled); 1 enables it.

app.Sandbox.Rebuilder.IdleTimeout

The idle time of the cwNativeSandbox process in rebuilder mode before termination, in seconds. Default value: 10.

app.WebServer.DraftValidateTimeout

The interval at which the dispatcher checks the activity of remote configurator drafts, in seconds. Default value: 3600.

app.AnnouncesListener.RetryTimeout

The no-data time for multicast announcements before the listener rejoins the group, in seconds. Default value: 20.

app.ActivateLikeConsole

Allows activating the local dispatcher as a console via the Local Service menu. Default value: 0 (mode disabled); 1 enables it.

app.Log.SetParameters

Logs every read and change of every filter parameter. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Log.Local.MaxSize

The maximum size of the local log file, after which a new file is created. Default value: 2 GB.

app.Log.Shared.MaxSize

The maximum size of the shared log file, after which a new file is created. Default value: 100 KB.

app.UserRightsPolicy.Optional

Allows user rights to be enabled and disabled in the configuration if the license permits an optional policy. Default value: 0 (mode disabled); 1 enables it.

app.Server.Redundancy.Host.Alive.Action

Selects the action after the primary node recovers. Default value: 0 (stops the recovered primary node); 1 makes it redundant.

app.Media.Framework.Default

[Windows] Selects the multimedia framework. By default, the parameter is not set, and DirectShow is used; 0 selects DirectShow, 1 selects GStreamer.

app.Configurator.CorrectMediatypes.Enabled

Enables Configurator::CorrectMediatypes to correct media types in case there is no input data. Default value: 1 (mode enabled); 0 disables it.

app.Configurator.CorrectMediatypes.SafeStop

Stops the graph while media types are being corrected by Configurator::CorrectMediatypes. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Configurator.UpdateRequiredBitrate.Enabled

Allows the configurator and rebuilder to recalculate the multiplexer’s Required Bitrate parameter. Default: 0 (mode disabled); 1 enables it.

app.Deprecated.Connect

[Deprecated] Uses the legacy random creation order for request pins, for example in case of the multiplexer and DashSink. Default value: 0 (mode disabled); 1 enables it.

app.Channel.Events.Check.Period

The interval at which the event system checks parameter values in milliseconds; the minimum value is 100. Default value: 1000.

app.Events.EOS.Restart

Restarts the graph upon receiving End-of-Stream. Default value: 0 (mode disabled); 1 enables it.

app.LinkedGraphRecursiveStackDeep

The maximum recursion depth when processing linked graphs. Default value: 100 levels.

app.Channel.Graph.ReferencePinsCheck.Period

The reference pin search period; the minimum value is 1. Default value: 30 seconds.

app.SocketListener.AvailableIntefacesCheck.Timeout

The timeout for checking available network interfaces in milliseconds. Default value: 20000.

app.UI.hideInternalConnection

Prevents internal gRPC addresses from being modified in the user interface. Default value: 1 (mode enabled); 0 disables it.

app.GraphElementEvent.Log.Filter

Sets a comma-separated list of GraphElementEvent names to be logged. Default value: parameter not set, and all types are logged; a non-empty value restricts logging to the listed types.

app.Events.2

Enables the version 2 event system. Default value: 0 (mode disabled); 1 enables it.

app.Events.2.PseudoParams

Creates pseudo-parameters with info obtained from component callbacks. Default value: 1 (mode enabled); 0 disables it.

app.Events2.HistoryCapacity

Limits the number of version 2 event history records in memory. Default value: 300 records; 0 disables history.

app.E2.DefaultAudioAlert

The default audio file for version 2 event system alerts. By default, the parameter is not set; the component’s built-in behavior applies.

app.UI.Editor.IndexFiltersRole

Uses additional editor colors to distinguish indexed filter roles. Default value: 1 (mode enabled); 0 disables it.

app.Reserved0

Compatibility switch for the legacy Converter Studio output file naming. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.Reserved2

Writes periodic statistics to CSV instead of the regular log. By default, the parameter is not set (mode disabled); 1 enables it, 0 disables it.

app.AddRecordBranchInGraph

Adds a record branch when building the graph instead of creating it later via a task. Default value: 0 (mode disabled); 1 enables it.

app.TaskScheduler.MaximumNumThreads

The maximum number of working streams the task scheduler can create. Default value: 1000 streams.

app.TaskScheduler.OptimalNumThreads

The preferred number of working streams maintained by the task scheduler. Default value: 8 streams.

app.TaskScheduler.DefaultOvertimeTimeout

The default allowable overtime for scheduled tasks in milliseconds. Default value: 200 milliseconds.

app.Task.NetworkManager.DefaultOvertimeTimeout

The default allowable overtime for network manager tasks in milliseconds. Default value: 2000.

app.GRPC.SandBox.MaxThreads

The maximum number of streams for the native sandbox gRPC server. Default value: 4.

app.GRPC.Probe.MaxThreads

The maximum number of streams for the Probe gRPC server. Default value: 4.

app.GRPC.Console.MaxThreads

The maximum number of streams for the console gRPC server. Default value: 4.

app.GRPC.Dispatcher.MaxThreads

Limits the number of streams for the dispatcher gRPC server. Default value: 0 (no explicit limit); a positive value sets the maximum number of streams.

app.GRPC.SandBox.MessageSize.Maximum

The maximum gRPC message size for the native sandbox in megabytes. Default value: 200 megabytes.

app.GRPC.Probe.MessageSize.Maximum

The maximum gRPC message size for Probe in megabytes. Default value: 200.

app.GRPC.Console.MessageSize.Maximum

The maximum gRPC message size for the console in megabytes. Default value: 200.

app.GRPC.Dispatcher.MessageSize.Maximum

The maximum gRPC message size for the dispatcher in megabytes. Default value: 200.

app.GRPC.Console.WaitForConnected

The time to wait for the gRPC connection to the console to become ready in seconds. Default value: 20.

app.Console.Stdout.Silent

Suppresses the console process output to standard output. Default value: 1 (mode enabled); 0 disables it.

app.Channel.Graph.Build.RTMPSource.FindPins.Timeout

The timeout for finding RTMP Source pins during graph building in milliseconds. Default value: 10000.

app.EnableIPv6Interfaces

Allows network source and sink filters to use IPv6 interfaces. Default value: 0 (mode disabled); 1 enables it.

Setting Up Configurations

A configuration is used to specify settings of encoding consoles (tasks), including reactions on certain events. The default configuration is called Common.

You can choose and (or) set up the required configuration on the Service Settings ➝ Configurations page. Select a configuration from the drop-down list to the right and above, edit the settings if necessary, and click Apply. The current configuration can be downloaded by clicking DownloadIcon. To upload a configuration, use UploadIcon. For deletion, click TrashIcon.

You can create a custom configuration by clicking PlusIcon Add next to the drop-down list. Enter the configuration name and click ОK. If necessary, add multiple configurations and apply them to different tasks.

Each configuration contains 4 sets of settings: Thresholds, Events, Component Logs, and Options — see below for their descriptions.

Thresholds

Thresholds can be configured via the following parameters:

  • Automatically enable the color bar generator—if a trigger you set up in Events goes off, the video stream will be replaced by an image (color bars, by default), and the audio stream will be replaced by silence.

  • Restart conditions:

    • Restart every N minutes—the console will restart at a set interval in minutes.

    • Restart if CPU usage drops to less than N%—restart the console when the CPU load decreases and remains at this level for the specified time.

    • Restart if RAM usage rises higher than N MB—restart the console if the RAM usage exceeds the set threshold for the specified time.

  • Log statistics every N seconds—task statistics will be additionally recorded to the console log at each specified interval.

  • Input record—lets you record input stream segments. To enable the recording, tick the Enable record checkbox, set the segment size and a period for storing records.

  • DOT files*enables you to save your task as DOT files, which in turn can provide additional debug info on the internal state of the components. To enable saving, tick the *Save DOT file checkbox. In case you run into an issue when launching a task, technical support will need these files to look into the issue.

  • Enable OTT folder cleaning—automatically deletes HLS/DASH segments in task-specific folders during the restart of the task.

  • Actions During Incidents—configures a scenario of automatic actions in case of a failure within the task. You can set the timeout for waiting for a response about a status change in seconds, as well as enable the following checkboxes:

    • Unload a schema when the console repeatedly restarts—enables schema unload in case task restarts multiple times.

    • Try to change a task state during—after enabling, you can set the number of attempts during which the system will try to change the task state; 0 means an unlimited number of attempts.

    • Unload a schema when a task connection is lost after—after enabling, you can specify the time in seconds, upon reaching which the task schema will be unloaded.

  • Source Redundancy—ensures that the system switches to a redundant source if the main signal is lost or a failure occurs. In order for the system to switch to a redundant source, the source’s characteristics must comply with the checking criteria.

    • If there are no appropriate redundant sources, the generation of color bars is turned on until an appropriate source appears.

    • If the Switch back to primary source checkbox is enabled, the primary source takes priority.

    • When the primary source is lost, the system will switch to the redundant source. As soon as the primary source signal restores, reverse switching will take place.

    If the options is not enabled, no reverse switching will be applied and the current source will be considered as the main one.

    To learn more about redundancy, see the Configuring Server Redundancy section.

  • Delayed Schema Start—lets you set the delayed start time for the task schema in seconds, and to enable delayed start only when the service starts.

Events

See the Events System section.

Component Logs

This table contains settings for configuring event-based logging related to a specific Elecard CodecWorks component.

To add a row, click on PlusIcon in the top-left part of the table, and then in each column specify the following:

  • Component — Elecard CodecWorks component.

  • Logging level — contains logging levels; the levels are cumulative, i.e., the lowest level trace includes all previous logging levels. It is recommended to use the info level, which is set by default.

  • Log file size — lets you set the maximum log file size in KB, MB, or GB, upon reaching which the logging will stop. The 0 value means the log file size is unlimited. If you enable the Default checkbox, the value will be set to 100 KB, and the field will be locked for editing.

To delete a row, click on the deleteButton button.

Options

See the Setting Up Options section.

Configuring Server Redundancy

During operation, the backup server monitors the operation of the main server by periodically sending special signals to it and monitoring the receipt of responses. If there are no responses from the main server within a configurable period of time, the redundant server activates pre-configured encoding channels under its control. One redundant server can back up several working encoding servers (N+1 model). Also, multiple redundant servers can serve the same set of working servers (N+M model).

On the Home page, click the Redundancy button to open the redundancy page. It contains two columns:

  1. Main Servers — displays the names of main nodes to be backed up by redundant servers.

  2. Redundancy Servers — displays the names of redundant servers that will start in case of problems with main servers.

You can add one or multiple servers to the list by clicking the Add button. When the list is created, click the Save & Exit button. Server redundancy will be set up.

Note

A server on which the redundancy is configured is automatically included in the list of backup servers by default.

The redundant server will start if connection to the working CodecWorks server is lost, i.e. when the dispatcher of the redundant server stops receiving responses from the dispatcher of the main server.

To switch to the redundant server manually, save the settings, then go to the redundancy page and select the server you want to bring out of operation from the main server list. Next, select a redundant server you want to bring in operation and click the transfer button.

If you click the Settings button on the Redundancy page, the Redundancy Settings window opens. In this window, you can configure the update of schemas on the redundant servers, the timeout for switching to the redundant server, and triggers that will be used for switching.

If the Update schemas on redundant servers by time option is enabled, the encoding schemas for redundant servers are automatically updated at the specified interval after the service start or beginning from the time specified by the user.

  • Number of failed requests is a number of consecutive failed requests within a TCP session. If the specified number of failed requests in a row is reached, a redundant server will start.

  • Request timeout (milliseconds) is the time between requests within a TCP session.

  • Failover timeout (milliseconds) is the calculated parameter defining the time between detecting a problem on the primary server and failing over to a redundant server.

Setting conditions for the server deactivation is a functionality that provides switching to the redundant server if one of the specified conditions is satisfied. Deactivation settings are applied to the current server and other servers in a redundancy group. There are the following conditions for deactivation of the server and subsequent switching to the redundant server:

  • No input streams detected — when this condition is chosen, the server will be deactivated if there are no input streams for all active consoles.

  • Failure of publishing segments over WebDAV — when this condition is chosen, the server will be deactivated if all active consoles fail to publish OTT segments via WebDAV to the origin server.

  • CPU Usage — when this condition is chosen, the server will be deactivated if the specified CPU load threshold is exceeded within the set period.

The Action if conditions are met setting helps to configure the server behavior. If one or some conditions occur, a server can become a redundant server or go to a deactivated state.

Note

You can set a server as a redundant one only for 1+1 redundancy mode.

Stream Encryption

Note

The description below uses the following terminology:

  • Conditional Access System (CAS) controls subscriber access to broadcast services.

  • Entitlement Control Message (ECM) is a CAS message containing an encrypted control word (CW) for descrambling the stream.

  • Entitlement Control Message Generator (ECMG) is a CAS part that generates ECM messages.

  • Entitlement Management Message (EMM) is a CAS message containing service data, access information, and special commands (e.g. for changing the subscription, updating the operational key, etc.).

  • Entitlement Management Message Generator (EMMG) is a CAS part that generates EMM messages.

  • Scrambling Control Group (SCG) is a structure gathering together the list of audio and video streams scrambled at the same time with the same control word as well as the list of ECMs with the identifiers of their respective CA systems and with their respective access criteria.

Elecard CodecWorks supports stream encryption with a BISS key as well as by means of different conditional access systems (CAS SimulCrypt). Encryption can be configured both in new and existing tasks. In case of new tasks, open the configurator by clicking Create Task, then add a source and configure the settings in the Transform section. For existing tasks, open a task by clicking on its name on the home page, then click editUser in the top-left corner of the task page that opened.

Note

Encryption is handled by the MPEG Multiplexer component. To ensure the component is included in the schema, streaming must be done via UDP, SRT, RIST, or RTP protocol.

Switch to the Output section, then open the MPEG Multiplexer tab to the right, if unopened. Next, move to the SimulCrypt tab.

_images/SimulCrypt_en.png

Encryption parameters can be set within the interface or directly in a JSON schema. To enable the schema editing mode, use the Edit JSON toggle. After setting everything up, click Save & Exit in the top right corner.

Configuring BISS Encryption

To enable stream encryption with a BISS key, start off with adding an SCG group by clicking on PlusIcon SCG. Add an PlusIcon Entry, then add an ECM stream and a stream element by clicking PlusIcon ECM_Group and then PlusIcon ECM_Group_Element. Next, fill out the CA_system_ID field with a secret key.

Configuring SimulCrypt Encryption

Configuration requires several steps described below.

Adding a Connection to an EMMG

EMMG connection is required for the multiplexer could receive a data flow from the CAS EMMG and insert the data in the transport stream. The data can be either EMMs or PDG-created private data (PD) related to the CAS.

Add a connection by clicking PlusIcon EMMG, then PlusIcon Entry. Fill out the required fields, see the table below for more info:

Parameter

Type

Description

Example

Required

name

String

Data stream name for easy debugging

CAS 1

No

address

String

Multiplexer IP address

10.20.0.3

No

port

String

Multiplexer port number

5008

No

client_id

Number/HexString

ID of the EMM/PD generator connected to the multiplexer; supplied by the CAS provider

0x4ae10003

Yes

data_id

Number/HexString

Data stream ID; supplied by the CAS provider

0x50

Yes

data_type

Number

Data stream type. Possible options include:
0: EMM
1: Private data
2: DVB reserved (ECM)

1

No

bandwidth

Number

Maximum data bitrate in kbit/s

50

No

data_PID

Number/HexString

Stream PID

420

No

CA_system_id

String

A parameter used for setting up a CA descriptor in a CAT if CA_system_id is not equal to 2 high-order bytes in client_id

0x7be0

No

allow_duplicates

Boolean

Allows or disallows creating streams with identical settings

true

No

You can add multiple connections for various CA systems via the PlusIcon Entry button. To delete a connection, click deleteIcon.

Adding a Connection to an ECMG

ECMG connection is required for the multiplexer could send encryption keys to the ECMG, receive ECM messages from it and insert them under a certain PID in the transport stream.

Add a connection by clicking PlusIcon ECMG, then PlusIcon Entry. Fill out the required fields, see the table below for more info:

Parameter

Type

Description

Example

Required

name

String

ECM generator name for easy debugging

CAS 1

No

Super_CAS_id

HexString

ID of a CAS that the multiplexer is trying to connect to; supplied by the CAS-system provider

0x4ae10003

Yes

host

String

ECM generator IP address

10.20.0.4

Yes

port

String

ECM generator port number

4444

Yes

You can add multiple connections for various CAS using the PlusIcon Entry button. To delete a connection, click deleteIcon.

Adding a Closed-Access Group

Add an SCG by clicking PlusIcon SCG. Add an PlusIcon Entry, then add an ECM stream and a stream element by clicking PlusIcon ECM_Group and then PlusIcon ECM_Group_Element. Fill out the required fields, see the table below for more info:

Parameter

Type

Description

Example

Required

name

String

ECM stream name for easy debugging

CAS 1

No

Super_CAS_id

HexString

ID of a CAS that the multiplexer is trying to connect to; the value has to be the same as Super_CAS_id in ECMG

0x4ae10003

Yes

ECM_id

String

ECM stream ID

3

Yes

access_criteria

String/HexString

Data related to CAS and required by ECMG to create ECM messages; supplied by the CAS provider

0301010000 или 0x0301010000

Yes

ECM_PID

String

ECM stream PID

421

No

CA_system_id

String

A parameter used for setting up a CP descriptor in a PMT in case CA_system_id is not equal to 2 high-order bytes in Super_CAS_id

0x7be0

No

Multiple elements, streams and/or groups can be added to support various CA systems. To delete an element, a stream and/or a group, click deleteIcon.

Events System

The CodecWorks events system notifies users about changes in the task or input stream state and reacts to said changes.

A set of recommended events is pre-configured in the system. You can select one of them or create an event from scratch, if needed.

How the Events System Works

The system lets you work with objects of different levels: you can track the state of the entire encoding schema, schema component, component parameter, or parameter pin. The user chooses an event, sets a target object for monitoring and specifies conditions that the object state analysis will be based on. The system receives data from the target object, performs an analysis based on the specified conditions, and determines the current state of the object.

There are three state types:

  • Good—target object operates normally.

  • Bad—target object is facing irregularities.

  • Signal—a call from the target object that is made every time a certain event, such as a log write error, occurs.

If the object state changes, the system notifies the user. Additionally, the user can set an action the system will perform in response to the state change, e.g., create a log record.

Events Page

In order to create or configure an event, first access the Events page. To access it, start off at the CodecWorks home page, then in the top-right corner click Settings ➝ Service Settings. To the left, click on Thresholds, then open the Events tab.

On the left side, you will see a list of pre-configured events for monitoring common issues:

  • Decoded video frames—decoded video not found.

  • Decoded audio frames—decoded audio not found.

  • Video—video not found

  • Audio—audio not found

  • CC errors—CC errors present in the stream

  • Input state—input data not found

  • OTT output state—output OTT data not found.

  • Encoded video frames—encoded video not found.

  • Unavailable interface—interface unavailable.

  • Master playlist is changed—changes in the master playlist.

  • Stream TS data—data not found.

To the right from the list is the area for editing the event configuration. For example, you can specify the event name in the Event display name field. In the Error level drop-down list, you can set the error criticality level: Major, Fatal, Error, Warning, Info, and Unknown. In the Mode drop-down list, the event configuration mode can be specified:

  • Basic lets you browse and configure Conditions for determining the target object state, but you cannot configure the condition type.
  • Advanced lets you browse and configure conditions as well as specify additional Options and Actions that the system would use to react to a changed state.
  • Expert lets you specify and change conditions, options, actions, and Target Objects.

Options

In the Options section, you can set the following:

  • Use only for active stream enables event monitoring only in the active stream, in tasks with a redundant source present.

  • Lock downstream event disables the monitoring for events that are located on the graph after the event with the bad state.

  • Duration sets the time period during which a specified condition should or shouldn’t be met in order to let the system register the corresponding state.

  • Reset events after sets the period after which the event will be reverted to its initial state.

  • No check period sets the period after the schema is run, during which no event monitoring is done.

Actions

In the Actions section, you can set system reactions to states. The list of actions is presented as a table. The table rows include the following drop-down lists:

  • State lets you select a state that would trigger an action.

  • Action lets you select an action.

  • Mark lets you select a schema type: any or with/without redundancy.

To add a row, click PlusIcon in the right part of the table header. To delete a row, click TrashIcon.

Users can set the following actions:

  • Visual alert/Enable sound notification

  • Enable/disable CBG

  • Record input stream

  • Record log

  • Run/stop stream

  • Start Python script

  • Send SNMP

  • Restart console

  • Switch to redundant source

  • Rebuild task

  • Create input buffer dump

  • Create process dump

Some actions require you to provide extra data. With this in view, the table makes it possible to add extra fields:

  • Name lets you specify the name of an argument for passing extra data.

  • Value lets you set data value.

To add new fields, click PlusIcon in the row you need.

The actions that require extra data include:

  • Send SNMP: here you have to set snmp as the name and one of the trap types mentioned below as the value. Note that the type depends on the specified state.

    State

    Value

    Good/Bad

    no_video_signal—video signal not found
    no_video_decoded—video not being decoded
    no_video_encoded—video not being encoded
    no_audio_signal—audio signal not found
    no_audio_decoded—audio not being decoded
    no_audio_encoded—audio not being encoded
    no_input—no data at the input
    no_output—no data at the output
    ts_errors—multiplexer facing CC errors
    generating_color_bar—CBG enabled
    generating_silence—audio stream replacement enabled (silence)
    webdav_error—WebDAV error
    video_decoder_skips—frames skipped
    no_vmx_key_at_start—encryption server key not found at start
    no_vmx_key_during_rotation—encryption server key not found during rotation

    Signal

    transcoding_start—encoding started
    transcoding_stop—encoding stopped
    channel_error—console process error
    channel_start_error—error at the start of encoding
    stream_switch—stream changed
    task_start—task successfully started
    task_stop—task stopped
    pmt_changed—changes in PMT
    rebuild_at_start_ok—schema successfully rebuilt
    rebuild_at_start_fail—schema rebuild failed
  • Start Python script: it is necessary to specify a path to the script. Set path in the Name field and the path itself—such as D:\Scripts\python_script.en—in the Value field. If you need to pass arguments to the script, add new fields, set args as the name then set the argument values.

  • Record input stream: you can set a path to save the stream record. Set path in the Name field and the path itself—such as D:\Dump\Test—in the Value field. You can also adjust the dump size by setting the duration argument as well as the duration value in seconds, such as 10.

    Note

    1. Indicate the schema name at the end of the path. For example, if the schema is named Mainstream, then the path should look like this: D:\Dump\Test\MainStream.

    2. The default path is \CodecWorks\Logs\Dumps\Record, with the duration being 30 seconds.

Target Object

In the Target object section, users can indicate the monitored target object. The following objects are available:

  • Schema—the entire encoding schema (graph) will be monitored.

  • Filter—the component state will be monitored. To add a component for monitoring, enter its name (GUID) in the field under the Filter ID header. You can monitor the state of multiple components simultaneously as part of the same event. In order to insert fields for adding extra components, click PlusIcon next to the header.

  • Parameter lets you monitor the state of a component parameter or a component pin. To set monitoring up, specify the component name in the Filter ID field, then the parameter name in the Parameter ID field.

    A schema can include multiple components that are the same. To explicitly distinguish the component with the monitored parameter, you can specify a custom name for the component in the Filter name field. If you have to monitor the parameter pin, tick the Profile parameters checkbox. You can include multiple parameters in monitoring by clicking PlusIcon. To delete a parameter, click TrashIcon.

    For each parameter, it is possible to set a specific condition for monitoring the state of this particular parameter. Open the Conditions list and choose the item you need. Click the editUser icon to collapse or expand the settings for the chosen condition. To learn more about the settings, see Conditions below.

  • Filter is unknown lets you monitor the component parameter state in case the component is unknown or if there are too many of them. Ensure you set the Parameter ID. You can additionally exclude components out of monitoring by specifying their names in the Exclude filters field. To monitor the parameter of a component pin, tick the Profile parameters checkbox.

Conditions

In the Conditions section, the user sets conditions, based on which the system will determine the state of the target monitoring object. Conditions vary based on which object you choose.

  • For the Schema target object, the GST graph callback condition is available: the system checks the code of a message sent by the graph and notifies the user about a change in the graph state. The condition is set by means of three fields. In the State field select the state, then in the Value field set the message code for the selected state, finally in the Description field enter a notification for the user. See the list of codes here. You can create multiple conditions with various messages. To add a new condition, click PlusIcon. To delete a condition, click TrashIcon.

  • For the Filter target object, the Filter callback condition is available: the system checks the code of a message sent by the component and notifies the user about a change in the component state. In the State field select the state, then in the Code field set the message code for the selected state, finally in the Description field enter a notification for the user. To add a new condition, click PlusIcon. To delete a condition, click TrashIcon.

  • For the Parameter and Filter is unknown target objects, three condition types inside a drop-down list are available:

    • Lower and upper thresholds—the user sets the parameter lower and/or upper threshold. The system compares the data received from the object to the thresholds and determines the object state. To set the lower threshold, tick the checkbox near the corresponding field and enter the required value. If needed, do the same for the upper threshold. If you tick the Relative checkbox, then instead of the current parameter value, the difference between the current and previous value will be compared to the threshold values. The Notify via signal checkbox enables notification sending when the event occurs. In the Good description and Bad description fields, the user can specify messages about the target object state that will be displayed in the interface.

    • Boolean expression works similar to Lower and upper thresholds, except that the thresholds are specified via expressions, such as ( {VALUE}>2 AND {VALUE}<100 ) OR {VALUE}=0 instead of fields. The following operators are supported:

      • Logical AND: AND, and, &&

      • Logical OR: OR, or, ||

      • Equality: =, ==

      • Logical NOT: !

    The system will replace the {VALUE} tag with the parameter values, meaning the tag should always be present in the expression.

  • Special—a special condition for monitoring the state of WebDAV URL addresses. The All or nothing checkbox determines how the system would identify the state. With the checkbox ticked, the system would determine the state as Bad in case at least one URL is invalid. With the checkbox unticked, the system would determine the state as Bad in case all URLs are invalid, or as Signal if only some of the URls are invalid. Use the State change description, Good description and Bad description fields to specify the messages for the Signal, Good, and Bad states correspondingly.

Configuring Events

To configure an event, do the following:

  1. Select a required configuration in the Configuration field in the top-right corner of the Events page.

  2. Select a pre-configured event or create your own by clicking PlusIcon Add Event above the events list.

  3. If needed, specify the Event display name and Error level.

  4. Switch over to expert mode by choosing the corresponding option in the Mode drop-down list.

  5. In the Target object section, choose an object for monitoring and configure it.

  6. In the Conditions section, specify conditions that the system would use to monitor the state of the selected object.

  7. Enter the messages that would show up in response to various states.

  8. In the Options section, enable the required monitoring options.

  9. In the Actions section, set how the system would react to states within the specified event.

  10. Check parameter settings. If needed, you can restore the default settings by clicking RevertIcon on top of the events list. If all is set correctly, click Apply in the top-right corner.

  11. Apply the configuration to a schema.

Events Journal

Events journal shows records about events registered in the system, keeps the history of notifications, and creates event-based logs. By default, the events in the journal are divided into two types: current events that are active at the time the journal is browsed, and complete ones. Current events are always on top and are additionally highlighted with color. By relying on the journal, the user can track active events to address them timely, analyze previous events, and browse the notification history.

_images/EventJournalPage_en.png

To open the events journal, start off at the CodecWorks home page, then hover over the Journals tab in the top-right corner and click Events Journal. You can also open the journal by clicking AlarmJournalIcon in any task row. In this case, the journal will display data related to events for this particular task.

You can filter the data in the journal using filters on top. To enable the selected filters, click Apply. To reset, click Clear Filters.

The journal comprises 8 columns:

  • Level shows an event criticality level: Error or Warning.

  • Name shows an event name.

  • Type shows an event type.

  • Start Time shows when an event started.

  • End Time shows when a completed event ended.

  • Message shows the message set for a certain event state.

  • Task shows the name of a task. Click the name to open the task page (graph).

  • Location pinpoints the path to the target object inside the graph where a certain event took place.

As the amount of data increases, the records are paginated. To browse through the records, use the navigation under the journal.

You can set the number of items to be shown via the Show per page field to the right and above the journal. To update the journal data, click Refresh. To delete data, click Clear history then confirm deletion in the pop-up window. If the journal has no data to provide, the No events to display message will be shown.

Template Configurator

By default, CodecWorks contains templates with pre-configured encoding settings. Users can edit these templates to fit custom requirements or create their own templates from the ground up. To open the template configurator, start off at the CodecWorks home page and click Create Template in the top-right corner above the task list.

When on the configuration page, to the right, you will see drop-down tabs containing templates for various task types. Click on a certain template name to open configurable parameters on the left side. If you make changes and then try to move to another template without saving, the system will warn you that your changes will be discarded. To delete a template, click TrashIcon.

You can create your own template by clicking PlusIcon Add Template. Next, configure all the necessary main template settings and profile settings.

The main settings include the following drop-down lists:

  • Framework lets you specify a framework underpinning the components.

  • Content Format lets you specify the data format, i.e. video, or audio.

  • Content Type lets you specify whether the input data is Compressed or Uncompressed. The compression type determines the task that will be performed and, correspondingly, the profile settings. Selecting Uncompressed will enable encoding, while Compressed will enable transcoding.

  • Extra lets you add one or more component(s) for the entire template. To add a component, click PlusIcon and select the required option from the drop-down list. To delete a component, click TrashIcon.

After configuring the main settings, set up the template profiles:

  • Profile Name lets you set the profile name.

  • Hardware Acceleration lets you set the acceleration type for encoding/transcoding. QuickSync and Nvidia hardware acceleration as well as CPU-based software (Soft) acceleration are available.

  • Codec lets you choose a specific codec. The set of options depends on the value in the Hardware Acceleration field: QuickSync and Soft support MPEG2, AVC, and HEVC, while Nvidia supports AVC and HEVC only.

  • Extra lets you add additional components to this particular profile. To add a component, click PlusIcon.

  • Outputs lets you set one or more outputs in this profile, for example, to support different streaming protocols. The preferred protocol can be selected from the drop-down list. If needed, you can explicitly indicate the output name. To add more outputs, click PlusIcon.

  • Actions contains the TemplateCopyIcon button that creates a copy of the current profile with all the settings.

To create more profiles, click Add Profile and adjust the required settings.

Once done with settings, click Apply. The page will show fields where you can configure component parameter values in the main branch as well as in the profiles. Located to the left and above the fields are the tabs with component names: you can switch between them to configure each component. To the right are the Recommended Values and Default Values buttons. Click the first button to fill out the fields with recommended parameter values; click the second button to restore the default values.

After specifying the required settings and parameters, enter the template name in the corresponding field located in the top-right corner on top of the template. Located to the left from the field is the Template group drop-down list—here you can add the template to a certain group. If no group fits, create one by clicking Add group in the drop-down list and then name it. Click Create Template, and it will appear in the list to the right. After creating a template, you can use it while configuring new or existing tasks, but not the ones that are currently launched. To do that, access the Transcoding section and select the template you need from the drop-down list under the stream name.