diff --git a/VideoData/ExampleCode/make/Makefile.Darwin b/VideoData/ExampleCode/make/Makefile.Darwin new file mode 100644 index 00000000..06ef0f17 --- /dev/null +++ b/VideoData/ExampleCode/make/Makefile.Darwin @@ -0,0 +1,48 @@ +############################################################################### +## (c) Copyright, Real-Time Innovations, All rights reserved. ## +## ## +## Permission to modify and use for internal purposes granted. ## +## This software is provided "as is", without warranty, express or implied. ## +## ## +############################################################################### + +# Note: +# - This is a convenience makefile that you can use in the case that you build +# on Linux but there is no specific makefile for the architecture that you are +# building for. Normally, the architecture is hardcoded into the makefile, +# like you can see in Makefile.x64Darwin12clang4.1. In stead, this makefile +# tries to figure out what your installed architecture is by scanning your +# DYLD_LIBRARY_PATH. + +# - To use this Makefile, you must have the 'NDDSHOME' environment variable +# set to the location of RTI Connext and DYLD_LIBRARY_PATH must contain +# the RTI DDS libraries. An easy way to achieve this is by sourcing the +# RTI-provided environment script found in $NDDSHOME/resource/srcipts, +# for example +# . $NDDSHOME/resource/scripts/rtisetenv_x64Darwin12clang4.1.bash +# +# - You need to invoke the make command from the root directory of this example. +# +# - To enable debugging information, set the Makefile variable 'DEBUG' to '1'. +# +# Example: +# make -f make/Makefile.Darwin + +# Defines required Make variables. They will be used in the Makefile.common +# to define the rules to define the build process for this application. +ifndef ARCH +NDDS_LIBNAME := libnddsc.dylib +LDLP := $(subst :, ,$(DYLD_LIBRARY_PATH)) +NDDSC := $(wildcard $(addsuffix /$(NDDS_LIBNAME),$(LDLP))) +ARCH := $(subst /,,$(subst $(abspath $(dir $(NDDSC))/..),,$(dir $(NDDSC)))) +$(info Found architecture: $(ARCH)) +endif + +CXX = clang++ +CXXFLAGS = -DRTI_UNIX -DRTI_DARWIN -DRTI_DARWIN10 -DRTI_64BIT -m64 -Wno-return-type-c-linkage +CXXLD = clang++ +CXXLDFLAGS = -m64 +SYSLIBS = -ldl -lm -lpthread + +# The rest of the rules are in the 'Makefile.common' +include make/Makefile.common diff --git a/VideoData/ExampleCode/make/Makefile.Linux b/VideoData/ExampleCode/make/Makefile.Linux new file mode 100644 index 00000000..0c7ed72e --- /dev/null +++ b/VideoData/ExampleCode/make/Makefile.Linux @@ -0,0 +1,55 @@ +############################################################################### +## (c) Copyright, Real-Time Innovations, All rights reserved. ## +## ## +## Permission to modify and use for internal purposes granted. ## +## This software is provided "as is", without warranty, express or implied. ## +## ## +############################################################################### + +# Note: +# - This is a convenience makefile that you can use in the case that you build +# on Linux but there is no specific makefile for the architecture that you are +# building for. Normally, the architecture is hardcoded into the makefile, +# like you can see in Makefile.i86Linux2.6gcc4.4.5. In stead, this makefile +# tries to figure out what your installed architecture is by scanning your +# LD_LIBRARY_PATH. + +# - To use this Makefile, you must have the 'NDDSHOME' environment variable +# set to the location of RTI Connext and LD_LIBRARY_PATH must contain +# the RTI DDS libraries. An easy way to achieve this is by sourcing the +# RTI-provided environment script found in $NDDSHOME/resource/srcipts, +# for example +# . $NDDSHOME/resource/scripts/rtisetenv_i86Linux3.xgcc4.6.3.bash +# +# - You need to invoke the make command from the root directory of this example. +# +# - To enable debugging information, set the Makefile variable 'DEBUG' to '1'. +# +# Example: +# make -f make/Makefile.Linux + + +# Defines required Make variables. They will be used in the Makefile.common +# to define the rules to define the build process for this application. +NDDS_LIBNAME := libnddsc.so +LDLP := $(subst :, ,$(LD_LIBRARY_PATH)) +NDDSC := $(wildcard $(addsuffix /$(NDDS_LIBNAME),$(LDLP))) +ARCH := $(subst /,,$(subst $(abspath $(dir $(NDDSC))/..),,$(dir $(NDDSC)))) + +CXX := g++ +CXXFLAGS := -DRTI_UNIX -DRTI_LINUX +CXXLD := g++ +CXXLDFLAGS := -static-libgcc +SYSLIBS := -ldl -lnsl -lm -lpthread -lrt + +ifeq ($(ARCH),$(filter i86%,$(ARCH))) + CXXFLAGS += -m32 + CXXLDFLAGS += -m32 +endif +ifeq ($(ARCH),$(filter x64%,$(ARCH))) + CXXFLAGS += -DRTI_64BIT -m64 + CXXLDFLAGS += -m64 +endif + +# The rest of the rules are in the 'Makefile.common' +include make/Makefile.common diff --git a/VideoData/ExampleCode/make/Makefile.common b/VideoData/ExampleCode/make/Makefile.common index 43740dda..643639ed 100644 --- a/VideoData/ExampleCode/make/Makefile.common +++ b/VideoData/ExampleCode/make/Makefile.common @@ -21,164 +21,344 @@ # - SYSLIBS: additional system libraries to append to the CXXLD command-line ############################################################################### -# Ensure this Makefile is invoked with the right variable set -############################################################################### -ifeq ($(ARCH), ) -all: - @echo "***************************************************************" - @echo "You cannot use this Makefile directly, instead use the" - @echo "architecture-specific Makefile. For example:" - @echo " gmake -f make/Makefile.i86Linux2.6gcc4.4.5" - @echo "***************************************************************" - @false +# Helpers for debugging and streamlining +############################################################################### + +# Use make SILENT= -f to show verbose information +SILENT := @ + +############################################################################### +# Information messages for cases of incorrect setups +############################################################################### + +define CONNEXT_NOARCH_MSG + +*************************************************************** +You cannot use this Makefile directly, instead use the +architecture-specific Makefile. For example: + gmake -f make/Makefile.i86Linux2.6gcc4.4.5 +*************************************************************** + +endef + +define CONNEXT_NOHOME_MSG + +*************************************************************** +The environment variable 'NDDSHOME' or 'RTIMEHOME is not set! +To use this makefile you need to set NDDSHOME to the directory +where you have RTI Connext Pro installed or set RTIMEHOME to +the directory where you have RTI Connext Micro installed. +*************************************************************** + +endef + +############################################################################### +# Check whether architecture was set +############################################################################### + +ifeq (,$(ARCH)) +$(error $(CONNEXT_NOARCH_MSG)) else +$(info Building for architecture $(ARCH)) +endif + ############################################################################### -# Ensure $NDDSHOME is defined +# Derive Connext edition from target ############################################################################### -ifeq ($(NDDSHOME), ) -all: - @echo "***************************************************************" - @echo "The environment variable 'NDDSHOME' is not set!" - @echo "To use this makefile you need to set NDDSHOME to the directory" - @echo "where you have RTI Connext installed." - @echo "***************************************************************" - @false +# +# Avoid secondary expansion complications, read from provided targets directly + +CONNEXT_PRO := pro +CONNEXT_MICRO := micro +CONNEXT_EDITIONS := $(CONNEXT_PRO) $(CONNEXT_MICRO) + +# Default edition is pro (first in list) +ifeq (,$(CONNEXT_EDITION)) +CONNEXT_EDITION := $(firstword $(filter $(CONNEXT_EDITIONS), $(CONNEXT_EDITION))) endif +ifeq (,$(CONNEXT_EDITION)) +CONNEXT_EDITION := $(firstword $(CONNEXT_EDITIONS)) endif +$(info Building for Connext $(CONNEXT_EDITION) edition) -# Define the sources and NDDS search path -INCLUDES = -Isrc/CommonInfrastructure -Isrc/Generated -I$(NDDSHOME)/include \ - -I$(NDDSHOME)/include/ndds -I/usr/include/gstreamer-0.10 \ - -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include \ - -I/usr/include/libxml2 - +############################################################################### +# Figure out what Connext installdir and version name and number we are using +############################################################################### + +ifeq ($(CONNEXT_EDITION),$(CONNEXT_PRO)) +CONNEXT_HOME := $(NDDSHOME) +endif + +ifeq ($(CONNEXT_EDITION),$(CONNEXT_MICRO)) +CONNEXT_HOME := $(RTIMEHOME) +endif + +ifeq (,$(CONNEXT_HOME)) +$(error $(CONNEXT_NOHOME_MSG)) +else +$(info Using Connext installation directory $(CONNEXT_HOME)) +endif + +############################################################################### +# Define settings specific to Connext edition and GStreamer +############################################################################### +ifeq ($(CONNEXT_EDITION),$(CONNEXT_PRO)) +CONNEXT_VERSION := $(strip $(patsubst %, rti_connext_dds-%, $(shell grep base_version $(NDDSHOME)/rti_versions.xml))) +CONNEXT_RTIDDSGEN := $(NDDSHOME)/bin/rtiddsgen +CONNEXT_INCLUDES := -I$(NDDSHOME)/include -I$(NDDSHOME)/include/ndds +CONNEXT_LIBS := $(addprefix -lndds, cpp c core) +endif + +ifeq ($(CONNEXT_EDITION),$(CONNEXT_MICRO)) +CONNEXT_VERSION := $(strip $(patsubst rev_host_rti_me.%, rti_connext_micro.%, $(notdir $(wildcard $(RTIMEHOME)/rev_host_rti_me.*)))) +CONNEXT_RTIDDSGEN := $(RTIMEHOME)/rtiddsgen/scripts/rtiddsgen -micro +CONNEXT_INCLUDES := -I$(RTIMEHOME)/include -I$(RTIMEHOME)/include/rti_me +CONNEXT_LIBS := $(addprefix -lrti_me_, cpp rhsm whsm discdpde discdpse) -lrti_me +endif + +$(info Using Connext version name $(CONNEXT_VERSION)) + +SRCDIR := src +COMMON_SRCDIR := $(SRCDIR)/CommonInfrastructure +COMMON_SRCDIR_EDITION := $(COMMON_SRCDIR)/connext_$(CONNEXT_EDITION) +SRCDIR_IDLGEN := $(SRCDIR)/Generated/$(CONNEXT_VERSION) + +INCLUDES = -I$(SRCDIR) -I$(COMMON_SRCDIR_EDITION) \ + -I$(SRCDIR_IDLGEN) $(CONNEXT_INCLUDES) \ + -I/usr/include/libxml2 \ + $(shell pkg-config --cflags gstreamer-app-1.0) + ############################################################################### # Modify build flags for debug/release ############################################################################### -ifeq ($(DEBUG),1) -CXXFLAGS += -g -O0 -D__STDC_CONSTANT_MACROS -ifeq ($(SHAREDLIB),1) -NDDSLIBS = -lnddscppd -lnddscd -lnddscored -else -NDDSLIBS = -lnddscppzd -lnddsczd -lnddscorezd + +ifneq ($(SHAREDLIB),1) +# Static libraries have z added to their names +STATIC_SUFFIX := z endif + +ifeq ($(DEBUG),1) +# Debug versions of libraries have d added to their names +DEBUG_SUFFIX := d +CXXFLAGS_DEBOPT := -g -O0 else -CXXFLAGS += -O2 -D__STDC_CONSTANT_MACROS -ifeq ($(SHAREDLIB),1) -NDDSLIBS = -lnddscpp -lnddsc -lnddscore -else -NDDSLIBS = -lnddscppz -lnddscz -lnddscorez -endif +CXXFLAGS_DEBOPT := -O2 endif -LIBS = -L$(NDDSHOME)/lib/$(ARCH) -L/usr/lib $(NDDSLIBS) $(SYSLIBS) -lglib-2.0 -lgstreamer-0.10 -lgstapp-0.10 +# Compiler flag to be added for all variants +CXXFLAGS += -D__STDC_CONSTANT_MACROS -COMMONSRC = src/CommonInfrastructure/DDSCommunicator.cxx \ - src/CommonInfrastructure/OSAPI.cxx \ - src/CommonInfrastructure/VideoBuffer.cxx \ - src/CommonInfrastructure/VideoSource.cxx \ - src/CommonInfrastructure/VideoOutput.cxx \ - src/CommonInfrastructure/SimCList.cxx +OBJ_SUFFIX := $(DEBUG_SUFFIX).o +LIB_SUFFIX := $(STATIC_SUFFIX)$(DEBUG_SUFFIX) +EXE_SUFFIX := $(LIB_SUFFIX) -COMMON_H = src/CommonInfrastructure/DDSCommunicator.h \ - src/CommonInfrastructure/OSAPI.h \ - src/CommonInfrastructure/DDSTypeWrapper.h \ - src/CommonInfrastructure/VideoBuffer.h \ - src/CommonInfrastructure/VideoSource.h +CONNEXT_LIBS := $(addsuffix $(LIB_SUFFIX), $(CONNEXT_LIBS)) -SOURCES_IDL = src/Generated/VideoData.cxx \ - src/Generated/VideoDataPlugin.cxx \ - src/Generated/VideoDataSupport.cxx +############################################################################### +# Define libraries and their paths for Connext and GStreamer +############################################################################### -VIDEOPUB_H = src/VideoPublisher/VideoPublisher.h +LIBS = -L$(CONNEXT_HOME)/lib/$(ARCH) $(CONNEXT_LIBS) -L/usr/lib $(SYSLIBS) $(shell pkg-config --libs gstreamer-app-1.0) -VIDEOPUBSRC = src/VideoPublisher/VideoPublisher.cxx \ - src/VideoPublisher/VideoPublisherInterface.cxx +############################################################################### +# Define output directories etc +############################################################################### + +# Directory names to be used +BLDDIR := objs +VERSION_BLDDIR := $(BLDDIR)/$(CONNEXT_VERSION) +ARCH_BLDDIR := $(VERSION_BLDDIR)/$(ARCH) -VIDEOSUB_H = src/VideoSubscriber/VideoSubscriber.h +# IDL-related filenames and patterns +IDL_NAME := VideoData +IDL_SRCDIR := $(SRCDIR)/Idl +IDL_FILE := $(IDL_SRCDIR)/$(IDL_NAME).idl +IDL_GENDIR := $(SRCDIR_IDLGEN) +IDL_GENPAT := % %Support %Plugin +IDL_GENPAT_ABS := $(addprefix $(IDL_GENDIR)/,$(IDL_GENPAT)) +IDL_GENPAT_SOURCES := $(addsuffix .cxx,$(IDL_GENPAT_ABS)) +IDL_GENPAT_HEADERS := $(addsuffix .h,$(IDL_GENPAT_ABS)) +IDL_SOURCES := $(subst %,VideoData,$(IDL_GENPAT_SOURCES)) +IDL_HEADERS := $(subst %,VideoData,$(IDL_GENPAT_HEADERS)) +IDL_GENERATED := $(IDL_SOURCES) $(IDL_HEADERS) +IDL_OBJDIR := $(ARCH_BLDDIR)/Common +IDL_OBJPAT_ABS := $(addprefix $(IDL_OBJDIR)/,$(IDL_GENPAT)) +IDL_OBJPAT_OBJS := $(addsuffix $(OBJ_SUFFIX),$(IDL_OBJPAT_ABS)) +IDL_OBJS := $(subst %,VideoData,$(IDL_OBJPAT_OBJS)) +IDL_DEPS := $(addsuffix .d,$(IDL_OBJS)) -VIDEOSUBSRC = src/VideoSubscriber/VideoSubscriber.cxx \ - src/VideoSubscriber/VideoSubscriberInterface.cxx +# Filenames associated with the Common source code files and objects +COMMON_NAME := Common +COMMON_OBJDIR := $(ARCH_BLDDIR)/$(COMMON_NAME) +COMMON_SRCS := $(wildcard $(COMMON_SRCDIR)/*.cxx) +COMMON_OBJS := $(addprefix $(COMMON_OBJDIR)/,$(notdir $(COMMON_SRCS:.cxx=$(OBJ_SUFFIX)))) +COMMON_DEPS := $(addsuffix .d,$(COMMON_OBJS)) +COMMON_OBJDIR_EDITION := $(ARCH_BLDDIR)/$(COMMON_NAME)/connext_$(CONNEXT_EDITION) +COMMON_SRCS_EDITION := $(wildcard $(COMMON_SRCDIR_EDITION)/*.cxx) +COMMON_OBJS_EDITION := $(addprefix $(COMMON_OBJDIR_EDITION)/,$(notdir $(COMMON_SRCS_EDITION:.cxx=$(OBJ_SUFFIX)))) +COMMON_DEPS_EDITION := $(addsuffix .d,$(COMMON_OBJS_EDITION)) -HEADERS_IDL = src/Generated/VideoData.h \ - src/Generated/VideoDataPlugin.h \ - src/Generated/VideoDataSupport.h +# Filenames associated with the VideoPublisher source code files and objects +PUB_NAME := VideoPublisher +PUB_SRCDIR := $(SRCDIR)/$(PUB_NAME) +PUB_OBJDIR := $(ARCH_BLDDIR)/$(PUB_NAME) +PUB_SRCS := $(wildcard $(PUB_SRCDIR)/*.cxx) +PUB_OBJS := $(addprefix $(PUB_OBJDIR)/,$(notdir $(PUB_SRCS:.cxx=$(OBJ_SUFFIX)))) +PUB_DEPS := $(addsuffix .d,$(PUB_OBJS)) +PUB_EXECDIR := $(PUB_OBJDIR) +PUB_EXEC := $(PUB_EXECDIR)/$(PUB_NAME)$(EXE_SUFFIX) -DIRECTORIES = objs.dir objs/$(ARCH).dir objs/$(ARCH)/VideoPublisher.dir \ - objs/$(ARCH)/Common.dir objs/$(ARCH)/VideoSubscriber.dir -SOURCES_NODIR = $(notdir $(COMMONSRC)) $(notdir $(SOURCES_IDL)) -VIDEOPUBSRC_NODIR = $(notdir $(VIDEOPUBSRC)) -VIDEOSUBSRC_NODIR = $(notdir $(VIDEOSUBSRC)) +# Filenames associated with the VideoSubscriber source code files and objects +SUB_NAME := VideoSubscriber +SUB_SRCDIR := $(SRCDIR)/$(SUB_NAME) +SUB_OBJDIR := $(ARCH_BLDDIR)/$(SUB_NAME) +SUB_SRCS := $(wildcard $(SUB_SRCDIR)/*.cxx) +SUB_OBJS := $(addprefix $(SUB_OBJDIR)/,$(notdir $(SUB_SRCS:.cxx=$(OBJ_SUFFIX)))) +SUB_DEPS := $(addsuffix .d,$(SUB_OBJS)) +SUB_EXECDIR := $(SUB_OBJDIR) +SUB_EXEC := $(SUB_EXECDIR)/$(SUB_NAME)$(EXE_SUFFIX) -COMMONOBJS = $(SOURCES_NODIR:%.cxx=objs/$(ARCH)/Common/%.o) -VIDEOPUBOBJS = $(VIDEOPUBSRC_NODIR:%.cxx=objs/$(ARCH)/VideoPublisher/%.o) $(COMMONOBJS) -VIDEOSUBOBJS = $(VIDEOSUBSRC_NODIR:%.cxx=objs/$(ARCH)/VideoSubscriber/%.o) $(COMMONOBJS) -EXEC = VideoPublisher -SUBEXEC = VideoSubscriber +# Accumulated variables +ALL_DEPS := $(IDL_DEPS) $(COMMON_DEPS) $(COMMON_DEPS_EDITION) $(PUB_DEPS) $(SUB_DEPS) +ALL_OBJS := $(IDL_OBJS) $(COMMON_OBJS) $(COMMON_OBJS_EDITION) $(PUB_OBJS) $(SUB_OBJS) +ALL_EXES := $(PUB_EXEC) $(SUB_EXEC) +ALL_DIRS := $(IDL_GENDIR) $(COMMON_OBJDIR) $(COMMON_OBJDIR_EDITION) $(PUB_OBJDIR) $(SUB_OBJDIR) ############################################################################### # Build Rules ############################################################################### -$(ARCH): VideoPublisher VideoSubscriber -VideoPublisher: $(DIRECTORIES) $(VIDEOPUBOBJS) $(EXEC:%=objs/$(ARCH)/VideoPublisher/%.o) \ - $(EXEC:%=objs/$(ARCH)/VideoPublisher/%.out) +# If one of these is used as a target on the command line, just execute +# the rules +.PHONY: $(CONNEXT_PRO) $(CONNEXT_MICRO) link compile generate clean veryclean + +ifeq ($(CONNEXT_EDITION),$(CONNEXT_PRO)) +$(CONNEXT_PRO): link +endif +ifeq ($(CONNEXT_EDITION),$(CONNEXT_MICRO)) +$(CONNEXT_MICRO): link +endif + +############################################################################### +# Linking the executables from their objects +############################################################################### + +# dependencies +link: $(PUB_EXEC) $(SUB_EXEC) + +$(PUB_EXEC): $(PUB_OBJS) $(COMMON_OBJS) $(COMMON_OBJS_EDITION) $(IDL_OBJS) | $(PUB_EXECDIR) +$(SUB_EXEC): $(SUB_OBJS) $(COMMON_OBJS) $(COMMON_OBJS_EDITION) $(IDL_OBJS) | $(SUB_EXECDIR) + +# recipes + +$(PUB_EXEC) $(SUB_EXEC): + $(SILENT) echo Linking $@; \ + $(CXXLD) $(CXXLDFLAGS) $^ $(LIBS) -o $@ + +############################################################################### +# Compiling the objects from source +############################################################################### + +# dependencies -VideoSubscriber: $(DIRECTORIES) $(VIDEOSUBOBJS) $(@:%=objs/$(ARCH)/VideoSubscriber/%.o) \ - $(SUBEXEC:%=objs/$(ARCH)/VideoSubscriber/%.out) +compile: $(ALL_OBJS) +# Make sure that the required directories are generated first +$(IDL_OBJS): | $(IDL_OBJDIR) +$(COMMON_OBJS): | $(COMMON_OBJDIR) +$(COMMON_OBJS_EDITION): | $(COMMON_OBJDIR_EDITION) +$(PUB_OBJS): | $(PUB_OBJDIR) +$(SUB_OBJS): | $(SUB_OBJDIR) -# Building the video publisher application -objs/$(ARCH)/VideoPublisher/%.out: objs/$(ARCH)/VideoPublisher/%.o - $(CXXLD) $(CXXLDFLAGS) -o $(@:%.out=%) $(VIDEOPUBOBJS) $(LIBS) +# recipes +# The compilation rule includes the 'side-effect' of generating dependency files +# See http://make.mad-scientist.net/papers/advanced-auto-dependency-generation/ +# for an explanation -# Building the video subscriber application -objs/$(ARCH)/VideoSubscriber/%.out: objs/$(ARCH)/VideoSubscriber/%.o - $(CXXLD) $(CXXLDFLAGS) -o $(@:%.out=%) $(VIDEOSUBOBJS) $(LIBS) +define do-compile +echo Compiling $@; \ +$(CXX) -MT $@ -MMD -MP -MF $@.Td $(CXXFLAGS) $(CXXFLAGS_DEBOPT) -o $@ $(DEFINES) $(INCLUDES) -c $<; \ +mv -f $@.Td $@.d +endef -objs/$(ARCH)/Common/%.o: src/CommonInfrastructure/%.cxx $(COMMON_H) - $(CXX) $(CXXFLAGS) -o $@ $(DEFINES) $(INCLUDES) -c $< - -objs/$(ARCH)/Common/%.o: src/Generated/%.cxx $(COMMON_H) - $(CXX) $(CXXFLAGS) -o $@ $(DEFINES) $(INCLUDES) -c $< +$(IDL_OBJS): $(IDL_OBJDIR)/%$(OBJ_SUFFIX): $(IDL_GENDIR)/%.cxx $(IDL_OBJDIR)/%$(OBJ_SUFFIX).d + $(SILENT) $(do-compile) -objs/$(ARCH)/VideoPublisher/%.o: src/VideoPublisher/%.cxx $(COMMON_H) $(HEADERS_IDL) - $(CXX) $(CXXFLAGS) -o $@ $(DEFINES) $(INCLUDES) -c $< +$(COMMON_OBJS): $(COMMON_OBJDIR)/%$(OBJ_SUFFIX): $(COMMON_SRCDIR)/%.cxx $(COMMON_OBJDIR)/%$(OBJ_SUFFIX).d + $(SILENT) $(do-compile) -objs/$(ARCH)/VideoSubscriber/%.o: src/VideoSubscriber/%.cxx $(COMMON_H) $(HEADERS_IDL) - $(CXX) $(CXXFLAGS) -o $@ $(DEFINES) $(INCLUDES) -c $< +$(COMMON_OBJS_EDITION): $(COMMON_OBJDIR_EDITION)/%$(OBJ_SUFFIX): $(COMMON_SRCDIR_EDITION)/%.cxx $(COMMON_OBJDIR_EDITION)/%$(OBJ_SUFFIX).d + $(SILENT) $(do-compile) +$(PUB_OBJS): $(PUB_OBJDIR)/%$(OBJ_SUFFIX): $(PUB_SRCDIR)/%.cxx $(PUB_OBJDIR)/%$(OBJ_SUFFIX).d + $(SILENT) $(do-compile) -# Rule to rebuild the generated files when the .idl file change -$(SOURCES_IDL) $(HEADERS_IDL): src/Idl/VideoData.idl - @mkdir -p src/Generated +$(SUB_OBJS): $(SUB_OBJDIR)/%$(OBJ_SUFFIX): $(SUB_SRCDIR)/%.cxx $(SUB_OBJDIR)/%$(OBJ_SUFFIX).d + $(SILENT) $(do-compile) + +$(IDL_OBJDIR)/%$(OBJ_SUFFIX).d $(COMMON_OBJDIR)/%$(OBJ_SUFFIX).d $(COMMON_OBJDIR_EDITION)/%$(OBJ_SUFFIX).d $(PUB_OBJDIR)/%$(OBJ_SUFFIX).d $(SUB_OBJDIR)/%$(OBJ_SUFFIX).d: ; +.PRECIOUS: $(IDL_OBJDIR)/%$(OBJ_SUFFIX).d $(COMMON_OBJDIR)/%$(OBJ_SUFFIX).d $(COMMON_OBJDIR_EDITION)/%$(OBJ_SUFFIX).d $(PUB_OBJDIR)/%$(OBJ_SUFFIX).d $(SUB_OBJDIR)/%$(OBJ_SUFFIX).d + +# Only include dependency files if relevant for the requested target. +ifeq (,$(filter $(MAKECMDGOALS), clean veryclean generate)) +$(info Including dependencies files) +-include $(ALL_DEPS) +endif + +############################################################################### +# Generate source files from the .idl file +############################################################################### + +# dependendies + +generate: $(IDL_GENERATED) +$(COMMON_OBJS) $(COMMON_OBJS_EDITION) $(PUB_OBJS) $(SUB_OBJS): $(IDL_GENERATED) + +$(IDL_GENERATED): $(IDL_FILE) | $(IDL_GENDIR) + +# recipes + +# Need to use a pattern rule here to avoid the rule to be executed multiple times +# See https://www.gnu.org/software/make/manual/make.html#Pattern-Intro for +# an explanation, starting at "Pattern rules may have more than one target." +# To see the difference, trying running make with -j for a parallel make and +# notice that the same rule gets executed only once. + +$(IDL_GENPAT_SOURCES) $(IDL_GENPAT_HEADERS): $(IDL_FILE) ifeq ($(OS_ARCH), i86Win32) - call $(NDDSHOME)/bin/rtiddsgen.bat -d src/idl src/VideoData.idl -replace -language C++ + call $(NDDSHOME)/bin/rtiddsgen.bat -namespace -d $(IDL_GENDIR) $< -replace -language C++ else - $(NDDSHOME)/bin/rtiddsgen -namespace -d src/Generated src/Idl/VideoData.idl -replace -language C++ + $(SILENT) echo Generating code from IDL file $<; \ + $(CONNEXT_RTIDDSGEN) -namespace -d $(IDL_GENDIR) -replace -language C++ $< endif -generate: $(SOURCES_IDL) $(HEADERS_IDL) - +############################################################################### # Here is how we create those subdirectories automatically. -%.dir : - @echo "Checking directory $*" - @if [ ! -d $* ]; then \ - echo "Making directory $*"; \ - mkdir -p $* ; \ - fi; +############################################################################### + +# dependencies: none here + +# recipes + +# Rules to generate any of the directories +$(ALL_DIRS): + $(SILENT) echo "Creating directory $@"; \ + mkdir -p $@ ############################################################################### # Clean target: removes the objs dir ############################################################################### + clean: - @rm -Rf objs/$(ARCH) - @echo "Successfully deleted object and executable files for architecture $(ARCH)" - @echo "To delete ALL the architectures and any generated file use target 'veryclean'" - -veryclean: - @rm -Rf objs - @rm -Rf src/idl - @echo "Deleted all executables, objects and generated files" + $(SILENT) rm $(ALL_DEPS) $(ALL_OBJS) $(ALL_EXES) 2> /dev/null; \ + rmdir -p $(COMMON_OBJDIR_EDITION) $(COMMON_OBJDIR) $(PUB_OBJDIR) $(SUB_OBJDIR) 2> /dev/null; \ + echo "Deleted all dependency, object and executable files for architecture $(ARCH)"; \ + +veryclean: clean + $(SILENT) rm $(IDL_GENERATED) 2> /dev/null; \ + rmdir -p $(IDL_GENDIR) 2> /dev/null; \ + echo "Deleted all IDL-generated files" + +#$(foreach DIR,$(ALL_DIRS), $(shell rmdir -p $(DIR))) diff --git a/VideoData/ExampleCode/make/Makefile.i86Linux2.6gcc4.4.5 b/VideoData/ExampleCode/make/Makefile.i86Linux2.6gcc4.4.5 index 636be902..0efd28b7 100644 --- a/VideoData/ExampleCode/make/Makefile.i86Linux2.6gcc4.4.5 +++ b/VideoData/ExampleCode/make/Makefile.i86Linux2.6gcc4.4.5 @@ -14,20 +14,26 @@ # # - To enable debugging information, set the Makefile variable 'DEBUG' to '1'. # Example: -# make -f make/Makefile.i86Linux2.6gcc4.4.5 DEBUG=1 +# make -f make/Makefile.i86Linux3.xgcc4.6.3 DEBUG=1 # Defines required Make variables. They will be used in the Makefile.common # to define the rules to define the build process for this application. ARCH=i86Linux2.6gcc4.4.5 -CXX = g++ -CXXFLAGS = -DRTI_UNIX -DRTI_LINUX -m32 -WX_FLAGS = -D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -CXXLD = g++ -CXXLDFLAGS = -m32 -static-libgcc -SYSLIBS = -ldl -lnsl -lm -lpthread -lrt - # The rest of the rules are in the 'Makefile.common' include make/Makefile.common +$(CONNEXT_PRO): CXX = g++ +$(CONNEXT_PRO): CXXFLAGS = -DRTI_UNIX -DRTI_LINUX -m32 +$(CONNEXT_PRO): CXXLD = g++ +$(CONNEXT_PRO): CXXLDFLAGS = -m32 -static-libgcc +$(CONNEXT_PRO): SYSLIBS = -ldl -lnsl -lm -lpthread -lrt + +$(CONNEXT_MICRO): CXX = g++ +$(CONNEXT_MICRO): CXXFLAGS = -DRTI_UNIX -DRTI_LINUX -DRTI_POSIX_THREADS -m32 -Wno-write-strings +$(CONNEXT_MICRO): CXXLD = g++ +$(CONNEXT_MICRO): CXXLDLFLAGS = -m32 -static-libgcc +$(CONNEXT_MICRO): SYSLIBS = -ldl -lnsl -lm -lpthread -lrt + + diff --git a/VideoData/ExampleCode/make/Makefile.i86Linux3.xgcc4.6.3 b/VideoData/ExampleCode/make/Makefile.i86Linux3.xgcc4.6.3 new file mode 100644 index 00000000..3fc02736 --- /dev/null +++ b/VideoData/ExampleCode/make/Makefile.i86Linux3.xgcc4.6.3 @@ -0,0 +1,39 @@ +############################################################################### +## (c) Copyright, Real-Time Innovations, All rights reserved. ## +## ## +## Permission to modify and use for internal purposes granted. ## +## This software is provided "as is", without warranty, express or implied. ## +## ## +############################################################################### + +# Note: +# - To use this Makefile, you must have the 'NDDSHOME' environment variable +# set to the location of RTI Connext. +# +# - You need to invoke the make command from the root directory of this example. +# +# - To enable debugging information, set the Makefile variable 'DEBUG' to '1'. +# Example: +# make -f make/Makefile.i86Linux3.xgcc4.6.3 DEBUG=1 + + +# Defines required Make variables. They will be used in the Makefile.common +# to define the rules to define the build process for this application. +ARCH=i86Linux3.xgcc4.6.3 + +# The rest of the rules are in the 'Makefile.common' +include make/Makefile.common + +$(CONNEXT_PRO): CXX = g++ +$(CONNEXT_PRO): CXXFLAGS = -DRTI_UNIX -DRTI_LINUX -m32 +$(CONNEXT_PRO): CXXLD = g++ +$(CONNEXT_PRO): CXXLDFLAGS = -m32 -static-libgcc +$(CONNEXT_PRO): SYSLIBS = -ldl -lnsl -lm -lpthread -lrt + +$(CONNEXT_MICRO): CXX = g++ +$(CONNEXT_MICRO): CXXFLAGS = -DRTI_UNIX -DRTI_LINUX -DRTI_POSIX_THREADS -m32 -Wno-write-strings +$(CONNEXT_MICRO): CXXLD = g++ +$(CONNEXT_MICRO): CXXLDLFLAGS = -m32 -static-libgcc +$(CONNEXT_MICRO): SYSLIBS=-ldl -lnsl -lm -lpthread -lrt + + diff --git a/VideoData/ExampleCode/make/Makefile.x64Darwin12clang4.1 b/VideoData/ExampleCode/make/Makefile.x64Darwin12clang4.1 new file mode 100644 index 00000000..705265cf --- /dev/null +++ b/VideoData/ExampleCode/make/Makefile.x64Darwin12clang4.1 @@ -0,0 +1,41 @@ +############################################################################### +## (c) Copyright, Real-Time Innovations, All rights reserved. ## +## ## +## Permission to modify and use for internal purposes granted. ## +## This software is provided "as is", without warranty, express or implied. ## +## ## +############################################################################### + +# Note: +# - To use this Makefile, you must have the 'NDDSHOME' environment variable +# set to the location of RTI Connext. +# +# - You need to invoke the make command from the root directory of this example. +# +# - To enable debugging information, set the Makefile variable 'DEBUG' to '1'. +# Example: +# make -f make/Makefile.x64Darwin12clang4.1 DEBUG=1 + + +# Defines required Make variables. They will be used in the Makefile.common +# to define the rules to define the build process for this application. +ARCH := x64Darwin12clang4.1 + +# The rules are in the 'Makefile.common' +include make/Makefile.common + +# These are the architecture-specific defines + +$(CONNEXT_PRO): CXX := clang++ +$(CONNEXT_PRO): CXXFLAGS := -DRTI_UNIX -DRTI_DARWIN -DRTI_DARWIN10 -DRTI_64BIT -m64 -Wno-return-type-c-linkage +$(CONNEXT_PRO): CXXLD := clang++ +$(CONNEXT_PRO): CXXLDFLAGS := -m64 +$(CONNEXT_PRO): SYSLIBS := -ldl -lm -lpthread + +$(CONNEXT_MICRO): CXX := g++ +$(CONNEXT_MICRO): CXXFLAGS := -DRTI_UNIX -DRTI_DARWIN -DRTI_POSIX_THREADS -m32 -g +$(CONNEXT_MICRO): CXXLD := g++ +$(CONNEXT_MICRO): CXXLDFLAGS := -m32 -static-libgcc +$(CONNEXT_MICRO): SYS_LIBS := + + diff --git a/VideoData/ExampleCode/make/Makefile.x64Darwin14clang6.0 b/VideoData/ExampleCode/make/Makefile.x64Darwin14clang6.0 new file mode 100644 index 00000000..dff2101a --- /dev/null +++ b/VideoData/ExampleCode/make/Makefile.x64Darwin14clang6.0 @@ -0,0 +1,37 @@ +############################################################################### +## (c) Copyright, Real-Time Innovations, All rights reserved. ## +## ## +## Permission to modify and use for internal purposes granted. ## +## This software is provided "as is", without warranty, express or implied. ## +## ## +############################################################################### + +# Note: +# - To use this Makefile, you must have the 'NDDSHOME' environment variable +# set to the location of RTI Connext. +# +# - You need to invoke the make command from the root directory of this example. +# +# - To enable debugging information, set the Makefile variable 'DEBUG' to '1'. +# Example: +# make -f make/Makefile.x64Darwin14clang6.0 DEBUG=1 + + +# Defines required Make variables. They will be used in the Makefile.common +# to define the rules to define the build process for this application. +ARCH:=x64Darwin14clang6.0 + +# The rest of the rules are in the 'Makefile.common' +include make/Makefile.common + +$(CONNEXT_PRO): CXX = clang++ +$(CONNEXT_PRO): CXXFLAGS = -DRTI_UNIX -DRTI_DARWIN -DRTI_DARWIN10 -DRTI_64BIT -m64 -Wno-return-type-c-linkage +$(CONNEXT_PRO): CXXLD = clang++ +$(CONNEXT_PRO): CXXLDFLAGS = -m64 +$(CONNEXT_PRO): SYSLIBS = -ldl -lm -lpthread + +$(CONNEXT_MICRO): CXX = clang++ +$(CONNEXT_MICRO): CXXFLAGS = -DRTI_UNIX -DRTI_DARWIN -DRTI_DARWIN10 -DRTI_64BIT -m64 -Wno-return-type-c-linkage -Wno-c++11-compat-deprecated-writable-strings +$(CONNEXT_MICRO): CXXLD = clang++ +$(CONNEXT_MICRO): CXXLDFLAGS = -m64 +$(CONNEXT_MICRO): SYSLIBS = diff --git a/VideoData/ExampleCode/resource/small.webm b/VideoData/ExampleCode/resource/small.webm new file mode 100644 index 00000000..da946da5 Binary files /dev/null and b/VideoData/ExampleCode/resource/small.webm differ diff --git a/VideoData/ExampleCode/resource/train.webm b/VideoData/ExampleCode/resource/train.webm new file mode 100644 index 00000000..473a3596 Binary files /dev/null and b/VideoData/ExampleCode/resource/train.webm differ diff --git a/VideoData/ExampleCode/scripts/VideoPublisher.bat b/VideoData/ExampleCode/scripts/VideoPublisher.bat index aae360e5..cdcaedc4 100755 --- a/VideoData/ExampleCode/scripts/VideoPublisher.bat +++ b/VideoData/ExampleCode/scripts/VideoPublisher.bat @@ -1,30 +1,30 @@ -@echo off -setlocal - -set executableName=VideoPublisher.exe -set appName=VideoPublisher - -set scriptDir=%~dp0 -set args=%* -set releaseBinDir=%scriptDir%..\win32\Release\i86Win32VS2010 -set debugBinDir=%scriptDir%..\win32\Debug\i86Win32VS2010 - -set Path=%NDDSHOME%\lib\i86Win32VS2010;%scriptDir%..\thirdparty\gstreamer-sdk\win32\0.10\x86\bin;%Path% - -if exist "%releaseBinDir%\%executableName%" ( - cd %releaseBinDir% - call "%executableName%" %args% -) else if exist "%debugBinDir%\%executableName%" ( - cd %debugBinDir% - call "%executableName%" %args% -) else ( - echo. - echo Error: Could not find %executableName% under %releaseBinDir% - echo or %debugBinDir%. - echo. - echo First, please compile %appName% using - echo the Visual Studio solution you will find under - echo %scriptDir%..\win32 - echo. - exit /b 1 +@echo off +setlocal + +set executableName=VideoPublisher.exe +set appName=VideoPublisher + +set scriptDir=%~dp0 +set args=%* +set releaseBinDir=%scriptDir%..\win32\Release\i86Win32VS2010 +set debugBinDir=%scriptDir%..\win32\Debug\i86Win32VS2010 + +set Path=%NDDSHOME%\lib\i86Win32VS2010;%Path% + +if exist "%releaseBinDir%\%executableName%" ( + cd %releaseBinDir% + call "%executableName%" %args% +) else if exist "%debugBinDir%\%executableName%" ( + cd %debugBinDir% + call "%executableName%" %args% +) else ( + echo. + echo Error: Could not find %executableName% under %releaseBinDir% + echo or %debugBinDir%. + echo. + echo First, please compile %appName% using + echo the Visual Studio solution you will find under + echo %scriptDir%..\win32 + echo. + exit /b 1 ) \ No newline at end of file diff --git a/VideoData/ExampleCode/scripts/VideoPublisher.sh b/VideoData/ExampleCode/scripts/VideoPublisher.sh index 7dc42596..ce9475a1 100755 --- a/VideoData/ExampleCode/scripts/VideoPublisher.sh +++ b/VideoData/ExampleCode/scripts/VideoPublisher.sh @@ -1,21 +1,23 @@ #!/bin/sh -filename=$0 -script_dir=`dirname $filename` -executable_name="VideoPublisher" -bin_dir=${script_dir}/../objs/i86Linux2.6gcc4.4.5/VideoPublisher +video_executable_name=VideoPublisher -if [ -f $bin_dir/$executable_name ] +#Search platform using standard RTI scripts +executable_name=rtiddsspy +script_dir="$(dirname "$(which ${executable_name})")" +source ${NDDSHOME}/resource/scripts/rticommon.sh + +video_bin_dir=objs/${platform_name}/VideoPublisher + +if [ -f $video_bin_dir/$video_executable_name ] then - cd $bin_dir - export LD_LIBRARY_PATH=../thirdparty/proj-4.8.0/lib/i86Linux2.6gcc4.4.5:../thirdparty/wxWidgets-2.9.4/lib/i86Linux2.6gcc4.4.5:$LD_LIBRARY_PATH - ./$executable_name $* + (cd $video_bin_dir; ./$video_executable_name $*) else echo "***************************************************************" echo $executable_name executable does not exist in: echo $bin_dir echo "" echo Please, try to recompile the application using the command: - echo " $ make -f make/Makefile.i86Linux2.6gcc4.4.5" + echo " $ make -f make/Makefile.${ARCH}" echo "***************************************************************" fi diff --git a/VideoData/ExampleCode/scripts/VideoSubscriber.bat b/VideoData/ExampleCode/scripts/VideoSubscriber.bat index 07cdecf4..976c6dcd 100755 --- a/VideoData/ExampleCode/scripts/VideoSubscriber.bat +++ b/VideoData/ExampleCode/scripts/VideoSubscriber.bat @@ -1,30 +1,30 @@ -@echo off -setlocal - -set executableName=VideoSubscriber.exe -set appName=VideoSubscriber - -set scriptDir=%~dp0 -set args=%* -set releaseBinDir=%scriptDir%..\win32\Release\i86Win32VS2010 -set debugBinDir=%scriptDir%..\win32\Debug\i86Win32VS2010 - -set Path=%NDDSHOME%\lib\i86Win32VS2010;%scriptDir%..\thirdparty\gstreamer-sdk\win32\0.10\x86\bin;%Path% - -if exist "%releaseBinDir%\%executableName%" ( - cd %releaseBinDir% - call "%executableName%" %args% -) else if exist "%debugBinDir%\%executableName%" ( - cd %debugBinDir% - call "%executableName%" %args% -) else ( - echo. - echo Error: Could not find %executableName% under %releaseBinDir% - echo or %debugBinDir%. - echo. - echo First, please compile %appName% using - echo the Visual Studio solution you will find under - echo %scriptDir%..\win32 - echo. - exit /b 1 +@echo off +setlocal + +set executableName=VideoSubscriber.exe +set appName=VideoSubscriber + +set scriptDir=%~dp0 +set args=%* +set releaseBinDir=%scriptDir%..\win32\Release\i86Win32VS2010 +set debugBinDir=%scriptDir%..\win32\Debug\i86Win32VS2010 + +set Path=%NDDSHOME%\lib\i86Win32VS2010;%Path% + +if exist "%releaseBinDir%\%executableName%" ( + cd %releaseBinDir% + call "%executableName%" %args% +) else if exist "%debugBinDir%\%executableName%" ( + cd %debugBinDir% + call "%executableName%" %args% +) else ( + echo. + echo Error: Could not find %executableName% under %releaseBinDir% + echo or %debugBinDir%. + echo. + echo First, please compile %appName% using + echo the Visual Studio solution you will find under + echo %scriptDir%..\win32 + echo. + exit /b 1 ) \ No newline at end of file diff --git a/VideoData/ExampleCode/scripts/VideoSubscriber.sh b/VideoData/ExampleCode/scripts/VideoSubscriber.sh index 39afece0..cf28306b 100755 --- a/VideoData/ExampleCode/scripts/VideoSubscriber.sh +++ b/VideoData/ExampleCode/scripts/VideoSubscriber.sh @@ -1,21 +1,23 @@ #!/bin/sh -filename=$0 -script_dir=`dirname $filename` -executable_name="VideoSubscriber" -bin_dir=${script_dir}/../objs/i86Linux2.6gcc4.4.5/VideoSubscriber +video_executable_name=VideoSubscriber -if [ -f $bin_dir/$executable_name ] +#Search platform using standard RTI scripts +executable_name=rtiddsspy +script_dir="$(dirname "$(which ${executable_name})")" +source ${NDDSHOME}/resource/scripts/rticommon.sh + +video_bin_dir=objs/${platform_name}/VideoSubscriber + +if [ -f $video_bin_dir/$video_executable_name ] then - cd $bin_dir - export LD_LIBRARY_PATH=../thirdparty/proj-4.8.0/lib/i86Linux2.6gcc4.4.5:../thirdparty/wxWidgets-2.9.4/lib/i86Linux2.6gcc4.4.5:$LD_LIBRARY_PATH - ./$executable_name $* + (cd $video_bin_dir; ./$video_executable_name $*) else echo "***************************************************************" echo $executable_name executable does not exist in: echo $bin_dir echo "" echo Please, try to recompile the application using the command: - echo " $ make -f make/Makefile.i86Linux2.6gcc4.4.5" + echo " $ make -f make/Makefile.${ARCH}" echo "***************************************************************" fi diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/DDSCommunicator.cxx b/VideoData/ExampleCode/src/CommonInfrastructure/DDSCommunicator.cxx index 8894a4c1..dc0fa7ac 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/DDSCommunicator.cxx +++ b/VideoData/ExampleCode/src/CommonInfrastructure/DDSCommunicator.cxx @@ -2,15 +2,13 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. **********************************************************************************************/ #include "DDSCommunicator.h" -using namespace DDS; - // ------------------------------------------------------------------------- // // Destruction of a DDS communication interface. This first deletes all the // entities created by the DomainParticipant object. Then, it cleans up the @@ -69,69 +67,32 @@ DDSCommunicator::~DDSCommunicator() // ------------------------------------------------------------------------- // // Creating a DomainParticipant with a specified domain ID -DomainParticipant* DDSCommunicator::CreateParticipant(long domain, +DDS::DomainParticipant* DDSCommunicator::CreateParticipant(long domain, DDS::DataReaderListener *discoveryListener, DiscoveryListenerKind listenerKind) { - // If we have a discovery listener installed, create the DomainParticipant - // disabled, so that we can install the listener before the discovery - // process starts. - if (discoveryListener != NULL) - { - PrepareFactoryForDiscoveryListener(); - } - - _participant = - TheParticipantFactory->create_participant(domain, - PARTICIPANT_QOS_DEFAULT, NULL, STATUS_MASK_NONE); - - if (_participant == NULL) - { - std::stringstream errss; - errss << "Failed to create DomainParticipant object"; - throw errss.str(); - } - - - if (discoveryListener != NULL) - { - // Install the discovery listener and enable the DomainParticipant - InstallDiscoveryListener(discoveryListener, listenerKind); - } - - return _participant; + return CreateParticipant(domain, "", "", discoveryListener, listenerKind); } // ------------------------------------------------------------------------- // // Creating a DomainParticipant with a domain ID of zero -DomainParticipant* DDSCommunicator::CreateParticipant() +DDS::DomainParticipant* DDSCommunicator::CreateParticipant() { - _participant = - TheParticipantFactory->create_participant( - 0, - PARTICIPANT_QOS_DEFAULT, - NULL, STATUS_MASK_NONE); - - if (_participant == NULL) - { - std::stringstream errss; - errss << "Failed to create DomainParticipant object"; - throw errss.str(); - } - - return _participant; + return CreateParticipant(0, "", "", NULL, NO_DISCOVERY_KIND); } // ------------------------------------------------------------------------- // // Creating a DomainParticipant with a specified domain ID and specified QoS -DomainParticipant* DDSCommunicator::CreateParticipant( +DDS::DomainParticipant* DDSCommunicator::CreateParticipant( long domain, const std::string &participantQosLibrary, const std::string &participantQosProfile, DDS::DataReaderListener *discoveryListener, DiscoveryListenerKind listenerKind) { + DDS::ReturnCode_t retcode; + // If we have a discovery listener installed, create the DomainParticipant // disabled, so that we can install the listener before the discovery // process starts. @@ -140,15 +101,37 @@ DomainParticipant* DDSCommunicator::CreateParticipant( PrepareFactoryForDiscoveryListener(); } + DDS::DomainParticipantQos participant_qos; + /* Only invoke profile action if not both strings are empty */ + if (!(participantQosLibrary.empty() && participantQosProfile.empty())) { + retcode = Connext::get_participant_qos_from_profile(participant_qos, + participantQosLibrary.c_str(), participantQosProfile.c_str()); + if (retcode != DDS::RETCODE_OK) + { + std::stringstream errss; + errss << "Failed to get ParticipantQos from profile"; + throw errss.str(); + } + } else { + participant_qos = DDS::PARTICIPANT_QOS_DEFAULT; + } + + /* Initialize infrastructure before creating Participant */ + retcode = Connext::initialize_infrastructure(""); + if (retcode != DDS::RETCODE_OK) + { + std::stringstream errss; + errss << "Failed to initialize infrastructure"; + throw errss.str(); + } + _participant = - TheParticipantFactory->create_participant_with_profile( - domain, - participantQosLibrary.c_str(), - participantQosProfile.c_str(), - NULL, - STATUS_MASK_NONE); - - if (_participant == NULL) + TheParticipantFactory->create_participant( + domain, + participant_qos, + NULL, + DDS::STATUS_MASK_NONE); + if (_participant == NULL) { std::stringstream errss; errss << "Failed to create DomainParticipant object"; @@ -162,15 +145,14 @@ DomainParticipant* DDSCommunicator::CreateParticipant( } return _participant; - } // ------------------------------------------------------------------------- // // Creating a DomainParticipant with a specified domain ID, specified QoS file // names, and specified QoS -DomainParticipant* DDSCommunicator::CreateParticipant(long domain, - std::vectorfileNames, +DDS::DomainParticipant* DDSCommunicator::CreateParticipant(long domain, + std::vector fileNames, const std::string &participantQosLibrary, const std::string &participantQosProfile, DDS::DataReaderListener *discoveryListener, @@ -179,100 +161,30 @@ DomainParticipant* DDSCommunicator::CreateParticipant(long domain, // Adding a list of explicit file names to the DomainParticipantFactory // This gives the middleware a set of places to search for the files - DomainParticipantFactoryQos factoryQos; - TheParticipantFactory->get_qos(factoryQos); - factoryQos.profile.url_profile.ensure_length(fileNames.size(), - fileNames.size()); - - for (unsigned int i = 0; i < fileNames.size(); i++) - { - // Note that we copy the file names here, so they cannot go out of - // scope - factoryQos.profile.url_profile[i] = DDS_String_dup( - fileNames[i].c_str()); - } - - ReturnCode_t retcode = TheParticipantFactory->set_qos(factoryQos); - - if (retcode != RETCODE_OK) + DDS::ReturnCode_t retcode = Connext::set_url_profile(fileNames); + if (retcode != DDS::RETCODE_OK) { std::stringstream errss; - errss << "Failed to create DomainParticipant object"; - throw errss.str(); - } - - // If we have a discovery listener installed, create the DomainParticipant - // disabled, so that we can install the listener before the discovery - // process starts. - if (discoveryListener != NULL) - { - PrepareFactoryForDiscoveryListener(); - } - - // Actually creating the DomainParticipant - _participant = - TheParticipantFactory->create_participant_with_profile( - domain, - participantQosLibrary.c_str(), - participantQosProfile.c_str(), - NULL, - STATUS_MASK_NONE); - - if (_participant == NULL) - { - std::stringstream errss; - errss << "Failed to create DomainParticipant object"; + errss << "Failed to set url profiles"; throw errss.str(); - } - - if (discoveryListener != NULL) - { - // Install the discovery listener and enable the DomainParticipant - InstallDiscoveryListener(discoveryListener, listenerKind); } - - - return _participant; - + return CreateParticipant(domain, participantQosLibrary, + participantQosProfile, discoveryListener, listenerKind); } // ------------------------------------------------------------------------- // // Creating a Publisher object. This is used to create type-specific // DataWriter objects in the application -Publisher* DDSCommunicator::CreatePublisher() +DDS::Publisher* DDSCommunicator::CreatePublisher() { - if (GetParticipant() == NULL) - { - std::stringstream errss; - errss << - "DomainParticipant NULL - communicator not properly " << - "initialized"; - throw errss.str(); - } - - // Creating a Publisher. - // This object is used to create type-specific DataWriter objects that - // can actually send data. - // - _pub = GetParticipant()->create_publisher( - PUBLISHER_QOS_DEFAULT, - NULL, STATUS_MASK_NONE); - - if (_pub == NULL) - { - std::stringstream errss; - errss << "Failed to create Publisher"; - throw errss.str(); - } - - return _pub; + return CreatePublisher("", ""); } // ------------------------------------------------------------------------- // // Creating a Publisher object with specified QoS. This is used to create // type-specific DataWriter objects in the application -Publisher* DDSCommunicator::CreatePublisher( +DDS::Publisher* DDSCommunicator::CreatePublisher( const std::string &qosLibrary, const std::string &qosProfile) { @@ -289,11 +201,24 @@ Publisher* DDSCommunicator::CreatePublisher( // This object is used to create type-specific DataWriter objects that // can actually send data. // - _pub = GetParticipant()->create_publisher_with_profile( - qosLibrary.c_str(), - qosProfile.c_str(), - NULL, STATUS_MASK_NONE); - + DDS::PublisherQos publisher_qos; + /* Only invoke profile action if not both strings are empty */ + if (!(qosLibrary.empty() && qosProfile.empty())) { + DDS::ReturnCode_t retcode = Connext::get_publisher_qos_from_profile(publisher_qos, + qosLibrary.c_str(), qosProfile.c_str()); + if (retcode != DDS::RETCODE_OK) + { + std::stringstream errss; + errss << "Failed to get PublisherQoS from profile " << + qosLibrary << "::" << qosProfile; + throw errss.str(); + } + } else { + publisher_qos = DDS::PUBLISHER_QOS_DEFAULT; + } + + _pub = GetParticipant()->create_publisher( + publisher_qos, NULL, DDS::STATUS_MASK_NONE); if (_pub == NULL) { std::stringstream errss; @@ -308,41 +233,15 @@ Publisher* DDSCommunicator::CreatePublisher( // ------------------------------------------------------------------------- // // Creating a Subscriber object. This is used to create type-specific // DataReader objects in the application -Subscriber* DDSCommunicator::CreateSubscriber() +DDS::Subscriber* DDSCommunicator::CreateSubscriber() { - if (GetParticipant() == NULL) - { - std::stringstream errss; - errss << - "DomainParticipant NULL - communicator not properly " << - "initialized"; - throw errss.str(); - } - - // Creating a Subscriber. - // This object is used to create type-specific DataReader objects that - // can actually receive data. The Subscriber object is being created - // in the DDSCommunicator class because one Subscriber can be used to - // create multiple DDS DataReaders. - // - _sub = GetParticipant()->create_subscriber( - SUBSCRIBER_QOS_DEFAULT, - NULL, STATUS_MASK_NONE); - - if (_sub == NULL) - { - std::stringstream errss; - errss << "Failed to create Subscriber"; - throw errss.str(); - } - - return _sub; + return CreateSubscriber("", ""); } // ------------------------------------------------------------------------- // // Creating a Subscriber object with specified QoS. This is used to create // type-specific DataReader objects in the application -Subscriber* DDSCommunicator::CreateSubscriber( +DDS::Subscriber* DDSCommunicator::CreateSubscriber( const std::string &qosLibrary, const std::string &qosProfile) { @@ -361,10 +260,24 @@ Subscriber* DDSCommunicator::CreateSubscriber( // in the DDSCommunicator class because one Subscriber can be used to // create multiple DDS DataReaders. // - _sub = GetParticipant()->create_subscriber_with_profile( - qosLibrary.c_str(), - qosProfile.c_str(), - NULL, STATUS_MASK_NONE); + DDS::SubscriberQos subscriber_qos; + /* Only invoke profile action if not both strings are empty */ + if (!(qosLibrary.empty() && qosProfile.empty())) { + DDS::ReturnCode_t retcode = Connext::get_subscriber_qos_from_profile(subscriber_qos, + qosLibrary.c_str(), qosProfile.c_str()); + if (retcode != DDS::RETCODE_OK) + { + std::stringstream errss; + errss << "Failed to get SubscriberQoS from profile " << + qosLibrary << "::" << qosProfile; + throw errss.str(); + } + } else { + subscriber_qos = DDS::SUBSCRIBER_QOS_DEFAULT; + } + + _sub = GetParticipant()->create_subscriber(subscriber_qos, + NULL, DDS::STATUS_MASK_NONE); if (_sub == NULL) { std::stringstream errss; @@ -382,7 +295,7 @@ Subscriber* DDSCommunicator::CreateSubscriber( // the application to add a listener for discovery. void DDSCommunicator::PrepareFactoryForDiscoveryListener() { - DomainParticipantFactoryQos factoryQos; + DDS::DomainParticipantFactoryQos factoryQos; TheParticipantFactory->get_qos(factoryQos); factoryQos.entity_factory.autoenable_created_entities = false; TheParticipantFactory->set_qos(factoryQos); @@ -395,18 +308,19 @@ void DDSCommunicator::InstallDiscoveryListener( DDS::DataReaderListener *discoveryListener, DiscoveryListenerKind listenerKind) { +#if (CONNEXT_HAS_BUILTINTOPICS == 1) char *discoveryTopic = NULL; if (listenerKind == PARTICIPANT_DISCOVERY_KIND) { - discoveryTopic = (char *)PARTICIPANT_TOPIC_NAME; + discoveryTopic = (char *)DDS::PARTICIPANT_TOPIC_NAME; } if (listenerKind == DATAWRITER_DISCOVERY_KIND) { - discoveryTopic = (char *)PUBLICATION_TOPIC_NAME; + discoveryTopic = (char *)DDS::PUBLICATION_TOPIC_NAME; } if (listenerKind == DATAREADER_DISCOVERY_KIND) { - discoveryTopic = (char *)SUBSCRIPTION_TOPIC_NAME; + discoveryTopic = (char *)DDS::SUBSCRIPTION_TOPIC_NAME; } // Lookup the builtin DataReader to listen for either Participant discovery, @@ -425,8 +339,12 @@ void DDSCommunicator::InstallDiscoveryListener( // Listen for discovery events builtinReader->set_listener(discoveryListener, - DATA_AVAILABLE_STATUS); - + DDS::DATA_AVAILABLE_STATUS); +#elif (CONNEXT_HAS_BUILTINTOPICS == -1) + /* Deliberately empty */ +#else /* CONNEXT_HAS_BUILTINTOPICS */ +#error Incorrect setup: CONNEXT_HAS_BUILTINTOPIC should be defined and have the value -1 or 1 +#endif // Enable the DomainParticipant _participant->enable(); diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/DDSCommunicator.h b/VideoData/ExampleCode/src/CommonInfrastructure/DDSCommunicator.h index c6bd1f62..fc42a8d5 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/DDSCommunicator.h +++ b/VideoData/ExampleCode/src/CommonInfrastructure/DDSCommunicator.h @@ -14,8 +14,7 @@ damages arising out of the use or inability to use the software. #include #include #include -#include "ndds/ndds_cpp.h" -#include "ndds/ndds_namespace_cpp.h" +#include "connext_cpp_common.h" // ------------------------------------------------------------------------- // diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/DDSTypeWrapper.h b/VideoData/ExampleCode/src/CommonInfrastructure/DDSTypeWrapper.h index a74c1933..0fc4de58 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/DDSTypeWrapper.h +++ b/VideoData/ExampleCode/src/CommonInfrastructure/DDSTypeWrapper.h @@ -2,7 +2,7 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. @@ -11,6 +11,8 @@ damages arising out of the use or inability to use the software. #ifndef DDS_TYPE_WRAPPER_H #define DDS_TYPE_WRAPPER_H +#include "connext_cpp_common.h" + // ------------------------------------------------------------------------- // // // DdsAutoType @@ -29,7 +31,7 @@ class DdsAutoType : public T // --- Constructor type for your generated data type --- DdsAutoType() { - if (T::TypeSupport::initialize_data(this) != DDS_RETCODE_OK) + if (T::TypeSupport::initialize_data(this) != Connext::TYPESUPPORT_OK) { throw std::bad_alloc(); } @@ -41,11 +43,11 @@ class DdsAutoType : public T // generated data type (generated from IDL) DdsAutoType(const DdsAutoType &rhs) { - if (T::TypeSupport::initialize_data(this) != DDS_RETCODE_OK) + if (T::TypeSupport::initialize_data(this) != Connext::TYPESUPPORT_OK) { throw std::bad_alloc(); } - if (T::TypeSupport::copy_data(this, &rhs) != DDS_RETCODE_OK) + if (T::TypeSupport::copy_data(this, &rhs) != Connext::TYPESUPPORT_OK) { throw std::bad_alloc(); } @@ -57,11 +59,11 @@ class DdsAutoType : public T // copy of the data into the DdsAutoType DdsAutoType(const T &rhs) { - if (T::TypeSupport::initialize_data(this) != DDS_RETCODE_OK) + if (T::TypeSupport::initialize_data(this) != Connext::TYPESUPPORT_OK) { throw std::bad_alloc(); } - if (T::TypeSupport::copy_data(this, &rhs) != DDS_RETCODE_OK) + if (T::TypeSupport::copy_data(this, &rhs) != Connext::TYPESUPPORT_OK) { throw std::bad_alloc(); } @@ -74,7 +76,7 @@ class DdsAutoType : public T // data type, including pointers. DdsAutoType operator=(const DdsAutoType &rhs) { - if (T::TypeSupport::copy_data(this, &rhs) != DDS_RETCODE_OK) + if (T::TypeSupport::copy_data(this, &rhs) != Connext::TYPESUPPORT_OK) { throw std::bad_alloc(); } diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/OSAPI.cxx b/VideoData/ExampleCode/src/CommonInfrastructure/OSAPI.cxx index 977c5d7b..954bb322 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/OSAPI.cxx +++ b/VideoData/ExampleCode/src/CommonInfrastructure/OSAPI.cxx @@ -2,12 +2,14 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. **********************************************************************************************/ -#include "../CommonInfrastructure/OSAPI.h" +#include "CommonInfrastructure/OSAPI.h" + +#include "connext_cpp_common.h" OSThread::OSThread( ThreadFunction function, @@ -20,7 +22,7 @@ OSThread::OSThread( void OSThread::Run() { -#ifdef RTI_WIN32 +#ifdef _WIN32 _thread = (HANDLE) _beginthread( (void(__cdecl*)(void*))_function, 0, (void*)_functionParam); @@ -37,9 +39,15 @@ void OSThread::Run() #endif } + +void OSThread::Sleep(long seconds, unsigned long nano_seconds) +{ + Connext::sleep(seconds, nano_seconds); +} + OSMutex::OSMutex() { -#ifdef RTI_WIN32 +#ifdef _WIN32 InitializeCriticalSection(&_handleCriticalSection); #else pthread_mutex_init(&_mutex, NULL); @@ -48,7 +56,7 @@ OSMutex::OSMutex() OSMutex::~OSMutex() { -#ifdef RTI_WIN32 +#ifdef _WIN32 DeleteCriticalSection(&_handleCriticalSection); #else pthread_mutex_destroy(&_mutex); @@ -57,7 +65,7 @@ OSMutex::~OSMutex() void OSMutex::Lock() { -#ifdef RTI_WIN32 +#ifdef _WIN32 EnterCriticalSection(&_handleCriticalSection); #else pthread_mutex_lock(&_mutex); @@ -68,7 +76,7 @@ void OSMutex::Lock() void OSMutex::Unlock() { -#ifdef RTI_WIN32 +#ifdef _WIN32 LeaveCriticalSection(&_handleCriticalSection); #else pthread_mutex_unlock(&_mutex); diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/OSAPI.h b/VideoData/ExampleCode/src/CommonInfrastructure/OSAPI.h index 893117dd..550a4598 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/OSAPI.h +++ b/VideoData/ExampleCode/src/CommonInfrastructure/OSAPI.h @@ -2,7 +2,7 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. @@ -19,12 +19,12 @@ damages arising out of the use or inability to use the software. // ------------------------------------------------------------------------- // -#ifdef RTI_WIN32 +#ifdef _WIN32 /* strtok, fopen warnings */ #pragma warning( disable : 4996 ) #endif -#ifdef RTI_WIN32 +#ifdef _WIN32 #define DllExport __declspec( dllexport ) #include #include @@ -65,11 +65,14 @@ class OSThread // Run the thread void Run(); + // A generic sleep function + static void Sleep(long seconds, unsigned long nano_seconds); + private: // --- Private members --- // OS-specific thread definition -#ifdef RTI_WIN32 +#ifdef _WIN32 HANDLE _thread; #else pthread_t _thread; @@ -100,7 +103,7 @@ class OSMutex // --- Private members --- // OS-specific mutex constructs -#ifdef RTI_WIN32 +#ifdef _WIN32 CRITICAL_SECTION _handleCriticalSection; #else pthread_mutex_t _mutex; diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/VideoOutput.cxx b/VideoData/ExampleCode/src/CommonInfrastructure/VideoOutput.cxx index 6f3a328a..aa1e21ff 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/VideoOutput.cxx +++ b/VideoData/ExampleCode/src/CommonInfrastructure/VideoOutput.cxx @@ -90,22 +90,22 @@ static GstBusSyncReply bus_sync_handler( GstBus *bus, GstMessage *message, gpointer user_data) { GstElement *outwin = NULL; - GValue *val = (GValue *)g_value_array_new(1); + GValue val = G_VALUE_INIT; - outwin = gst_bin_get_by_name((GstBin*)user_data,"sink"); + outwin = gst_bin_get_by_name(GST_BIN(user_data),"sink"); if (GST_MESSAGE_TYPE (message) != GST_MESSAGE_ELEMENT) return GST_BUS_PASS; - if (!gst_structure_has_name (message->structure, "prepare-xwindow-id")) + if (!gst_structure_has_name (gst_message_get_structure(message), "prepare-xwindow-id")) return GST_BUS_PASS; - g_value_init(val,G_TYPE_BOOLEAN); - g_value_set_boolean(val,FALSE); + g_value_init(&val,G_TYPE_BOOLEAN); + g_value_set_boolean(&val,FALSE); if (outwin != NULL) { - gst_child_proxy_set_property((GstObject *)(outwin),"sync",val); + gst_child_proxy_set_property(GST_CHILD_PROXY(outwin),"sync",&val); } gst_message_unref(message); @@ -123,33 +123,34 @@ void EMDSVideoDisplayOutput::Initialize() _frameHandler = new DisplayFrameHandler(this); - // Create the video pipeline on Windows (sending to DirectDraw) -#ifdef WIN32 - - _displayPipeline = - (GstPipeline *)gst_parse_launch( - "appsrc name=\"src\" is-live=\"true\" do-timestamp=\"true\" " - "caps=\"video/x-vp8, width=(int)640, height=(int)360, " - "pixel-aspect-ratio=(fraction)1/1, framerate=(fraction)1000/1\" ! " - "queue2 ! vp8dec ! queue2 ! " - "videorate ! video/x-raw-yuv,framerate=25/1 ! " - "ffmpegcolorspace ! " - "directdrawsink name=\"sink\"", - NULL); +#ifdef _WIN32 +// Create the video pipeline on Windows (sending to DirectDraw) +#define PIPELINE_STRING \ + "appsrc name=\"src\" is-live=\"true\" do-timestamp=\"true\" " \ + "caps=\"video/x-vp8, width=(int)640, height=(int)360, " \ + "pixel-aspect-ratio=(fraction)1/1, framerate=(fraction)1000/1\" ! " \ + "queue2 ! vp8dec ! queue2 ! " \ + "videorate ! video/x-raw-yuv,framerate=25/1 ! " \ + "videoconvert ! directdrawsink name=\"sink\"" +#endif -#else +#if defined(__linux__) || defined(__APPLE__) +#define PIPELINE_STRING \ + "appsrc name=\"src\" is-live=\"true\" do-timestamp=\"true\" " \ + "caps=\"video/x-vp8, width=(int)450, height=(int)360, " \ + "framerate=1000/1\" ! " \ + "vp8dec ! videoconvert ! autovideosink " - // Create the video pipeline on Linux (sending to XImageSink) - _displayPipeline = - (GstPipeline *)gst_parse_launch( - "appsrc name=\"src\" is-live=\"true\" do-timestamp=\"true\" " - "caps=\"video/x-vp8, width=(int)640, height=(int)360, " - "framerate=25/1\" ! queue2 ! " - " vp8dec ! ffmpegcolorspace ! ximagesink sync=\"false\" ", - NULL); +// "framerate=1000/1\" ! queue2 ! " \ +// "caps=\"video/x-vp8, width=(int)640, height=(int)360, " \ #endif + const char *pipelineString = PIPELINE_STRING; + printf("Doing pipeline: %s\n", pipelineString); + _displayPipeline = + GST_PIPELINE(gst_parse_launch( pipelineString, NULL)); + // If the video pipeline was not created correctly, exit. // The common causes for this include: // - Plugins referenced by name above not found due to: @@ -168,7 +169,7 @@ void EMDSVideoDisplayOutput::Initialize() bus = gst_pipeline_get_bus( GST_PIPELINE (_displayPipeline)); gst_bus_set_sync_handler (bus, - (GstBusSyncHandler) bus_sync_handler, _displayPipeline); + (GstBusSyncHandler) bus_sync_handler, _displayPipeline, NULL); // Add a watch for EOS events gst_bus_add_signal_watch(bus); @@ -176,8 +177,11 @@ void EMDSVideoDisplayOutput::Initialize() gst_object_unref(bus); // Set the pipeline state to playing, so it actually displays video - gst_element_set_state((GstElement*)_displayPipeline, - GST_STATE_PLAYING); + if (GST_STATE_CHANGE_FAILURE == gst_element_set_state(GST_ELEMENT(_displayPipeline), GST_STATE_PLAYING)) { + std::cout << "Failed to set pipeline state to PLAYING" << std::endl; + //} else { + // std::cout << "Successfully set pipeline state to PLAYING" << std::endl; + } } // ---------------------------------------------------------------------------- @@ -192,8 +196,12 @@ EMDSVideoDisplayOutput::EMDSVideoDisplayOutput() return; } else { - gst_element_set_state((GstElement*)_displayPipeline, - GST_STATE_PLAYING); + if (GST_STATE_CHANGE_FAILURE == gst_element_set_state(GST_ELEMENT(_displayPipeline), + GST_STATE_PLAYING)) { + std::cout << "Failed to set pipeline state to PLAYING" << std::endl; + //} else { + // std::cout << "Successfully set pipeline state to PLAYING" << std::endl; + } } } diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/VideoOutput.h b/VideoData/ExampleCode/src/CommonInfrastructure/VideoOutput.h index edc97ab6..8162b0b0 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/VideoOutput.h +++ b/VideoData/ExampleCode/src/CommonInfrastructure/VideoOutput.h @@ -38,7 +38,6 @@ Real-Time Innovations, Inc. (RTI). The above license is granted with #include #include -#include #include "VideoBuffer.h" #include "VideoEvent.h" @@ -131,7 +130,7 @@ class DisplayFrameHandler : public EMDSFrameHandler // virtual void FrameReady(void *obj, EMDSBuffer *buffer) { - GstAppBuffer *appbuffer = NULL; + GstBuffer *appbuffer = NULL; if(_appSrc == NULL) { @@ -145,12 +144,13 @@ class DisplayFrameHandler : public EMDSFrameHandler // Allocate a new buffer from the GStreamer framework that will be // used to display this video frame. appbuffer = - (GstAppBuffer*)gst_app_buffer_new(buffer->GetData(), - buffer->GetSize(), NULL, NULL); + gst_buffer_new_wrapped(buffer->GetData(), + buffer->GetSize()); // The buffer becomes managed by the GStreamer framework as soon as // we push it, so we do not have to free it. - gst_app_src_push_buffer(_appSrc, (GstBuffer*)appbuffer); + + gst_app_src_push_buffer(_appSrc, appbuffer); } diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/VideoSource.cxx b/VideoData/ExampleCode/src/CommonInfrastructure/VideoSource.cxx index 75290cdb..796044a9 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/VideoSource.cxx +++ b/VideoData/ExampleCode/src/CommonInfrastructure/VideoSource.cxx @@ -38,8 +38,7 @@ Real-Time Innovations, Inc. (RTI). The above license is granted with #include "VideoSource.h" #include #include -#include -#include "../Generated/VideoData.h" +#include "connext_cpp_common.h" static int seqn = 0; @@ -49,6 +48,7 @@ static int seqn = 0; // the provider (from the GStreamer framework) and notifies the frame // ready handler that there is a frame available. // + void *video_source_worker(void *src) { @@ -62,34 +62,70 @@ void *video_source_worker(void *src) while (1) { - - GstBuffer * buffer = - gst_app_sink_pull_buffer((GstAppSink *)videoSource->GetAppSink()); - - if (buffer == NULL) - { - return NULL; - } - - if (GST_BUFFER_SIZE(buffer) > - com::rti::media::generated::MAX_BUFFER_SIZE) - { - std::cout << "Buffer is larger than the max buffer size" - << std::endl; - } - EMDSBuffer *emdsBuffer - = new EMDSBuffer(GST_BUFFER_SIZE(buffer)); - - emdsBuffer->SetData(GST_BUFFER_DATA(buffer), - GST_BUFFER_SIZE(buffer)); - emdsBuffer->SetSeqn(seqn); - seqn++; - - videoSource->GetFrameReadyHandler()->FrameReady( - videoSource->GetHandlerObj(), emdsBuffer); - - delete emdsBuffer; + GstSample * sample = + gst_app_sink_pull_sample(GST_APP_SINK(videoSource->GetAppSink())); + if (sample == NULL) + { + if (gst_app_sink_is_eos(GST_APP_SINK(videoSource->GetAppSink()))) + { + std::cout << "End of stream reached, jumping back to start of video" << std::endl; + GstElement *pipeline = GST_ELEMENT(videoSource->GetPipeline()); + if (!gst_element_seek(pipeline, + 1.0, GST_FORMAT_TIME, GST_SEEK_FLAG_FLUSH, + GST_SEEK_TYPE_SET, 0, + GST_SEEK_TYPE_NONE, GST_CLOCK_TIME_NONE)) { + std::cout << " gst_element_seek failed" << std::endl; + return NULL; + } + if (GST_STATE_CHANGE_FAILURE == gst_element_set_state(pipeline, GST_STATE_PLAYING)) { + std::cout << " gst_element_set_state(PLAYING) failed" << std::endl; + return NULL; + } + } else { + std::cout << "NULL-sample pulled but end of stream not reached" << std::endl; + return NULL; + } + } else { /* if (sample == NULL) */ + GstBuffer * buffer = gst_sample_get_buffer(sample); + if (buffer == NULL) + { + return NULL; + } + + GstMemory * memory = gst_buffer_get_memory (buffer, 0); + if (memory == NULL) + { + return NULL; + } + + GstMapInfo info; + if (gst_memory_map (memory, &info, GST_MAP_READ) == FALSE) + { + return NULL; + } + + if (info.size > com::rti::media::generated::MAX_BUFFER_SIZE) + { + std::cout << "Buffer is larger than the max buffer size, not publishing" + << std::endl; + } else { + EMDSBuffer *emdsBuffer = new EMDSBuffer(info.size); + + emdsBuffer->SetData(info.data, info.size); + emdsBuffer->SetSeqn(seqn); + + seqn++; + + videoSource->GetFrameReadyHandler()->FrameReady( + videoSource->GetHandlerObj(), emdsBuffer); + + delete emdsBuffer; + + gst_buffer_unref (buffer); + } + gst_memory_unmap (memory, &info); + } } return NULL; @@ -127,7 +163,7 @@ static void EMDSVideoSource_detect_new_pad(GstElement *element, GstPad *pad, gpointer data) { // May be muxer or may be appSink depending on platform - GstElement *linkElement = (GstElement *)data; + GstElement *linkElement = GST_ELEMENT(data); GstPad *sinkPad = NULL; if (0 == strncmp(gst_pad_get_name(pad), "video", 5)) @@ -145,7 +181,9 @@ static void EMDSVideoSource_detect_new_pad(GstElement *element, GstPad *pad, << std::endl; } - gst_element_set_state(linkElement, GST_STATE_PLAYING); + if (GST_STATE_CHANGE_FAILURE == gst_element_set_state(linkElement, GST_STATE_PLAYING)) { + std::cout << "Failed to start the sink" << std::endl; + } gst_object_unref(sinkPad); } @@ -305,8 +343,6 @@ bool EMDSVideoSource::IsMetadataCompatible( // int EMDSVideoSource::Start() { - std::cout << "Initializing and starting video source" << std::endl; - // Create video thread _worker = new OSThread(video_source_worker, (void *)this); diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/VideoSource.h b/VideoData/ExampleCode/src/CommonInfrastructure/VideoSource.h index 99c78dea..459e49ca 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/VideoSource.h +++ b/VideoData/ExampleCode/src/CommonInfrastructure/VideoSource.h @@ -105,6 +105,11 @@ class EMDSVideoSource return _handlerObj; } + GstPipeline *GetPipeline() + { + return _videoEncodingPipeline; + } + GstElement *GetAppSink() { return _appSink; diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_cpp_common.cxx b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_cpp_common.cxx new file mode 100644 index 00000000..789573b1 --- /dev/null +++ b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_cpp_common.cxx @@ -0,0 +1,221 @@ +/* Interface */ +#include "connext_cpp_common.h" + +/* Implementation */ +#include +#include "netio/netio_udp.h" +#include "connext_micro_log_trace_handlers.h" + +namespace Connext { + +static bool G_do_multicast = true; +#define VIDEOSTREAM_HISTORY_DEPTH (50) + +/* Convenience function for setting profiles files in the ParticipantFactory */ + +DDS::ReturnCode_t +set_url_profile( + std::vector fileNames) +{ + /* Quick workaround: do nothing, assume multicast for now */ + return DDS::RETCODE_OK; +} + +DDS::ReturnCode_t +initialize_infrastructure(const std::string &interface_name) +{ + DDS::ReturnCode_t result = DDS::RETCODE_ERROR; + DDS::DomainParticipantFactory *factory = NULL; + RT::Registry *registry = NULL; + bool bresult; + DPDE::DiscoveryPluginProperty dpde_properties; + UDP::InterfaceFactoryProperty *udp_property = NULL; + const char *udp_intf = NULL; /* TODO: remove this, should have its own parameter */ + + /* Profile name not important here, ignored */ + factory = DDS::DomainParticipantFactory::get_instance(); + if (NULL == factory) { + std::cout << "Failed to get instance of DomainParticipantFactory" << std::endl; + goto done; + } + + /* Can not install trace handlers before DPF::get_instance() is invoked */ + bresult = LogTraceHandlers_Initialize("VideoDataParticipant"); + if (!bresult) { + std::cout << "Failed to install log or trace handler" << std::endl; + goto done; + } + + registry = factory->get_registry(); + if (NULL == registry) { + std::cout << "Failed to get component registry" << std::endl; + goto done; + } + + bresult = registry->register_component("wh", + WHSM::HistoryFactory::get_interface(), + NULL, NULL); + if (!bresult) { + std::cout << "Failed to register WH component" << std::endl; + goto done; + } + + bresult = registry->register_component("rh", + RHSM::HistoryFactory::get_interface(), + NULL, NULL); + if (!bresult) { + printf("Failed to register RH component"); + goto done; + } + + /* Configure UDP transport's allowed interfaces */ + bresult = registry->unregister(NETIO::DEFAULT_UDP_NAME, NULL, NULL); + if (!bresult) { + printf("Failed to unregister default UDP component"); + goto done; + } + + udp_property = new UDP::InterfaceFactoryProperty(); + udp_property->allow_interface.maximum(2); + udp_property->allow_interface.length(2); + + /* loopback interface */ +#if defined(__APPLE__) + *udp_property->allow_interface.get_reference(0) = DDS_String_dup("lo0"); +#elif defined (__linux__) + *udp_property->allow_interface.get_reference(0) = DDS_String_dup("lo"); +#elif defined(_WIN32) + *udp_property->allow_interface.get_reference(0) = DDS_String_dup("Loopback Pseudo-Interface 1"); +#else + #error Unknown operating system, currently only supports OSX/macOS, Linux and Windows +#endif + + if (!interface_name.empty()) { /* use interface supplied as parameter */ + *udp_property->allow_interface.get_reference(1) = + DDS::String_dup(interface_name.c_str()); + } else { /* use hardcoded interface */ +#if defined(__APPLE__) + *udp_property->allow_interface.get_reference(1) = + DDS::String_dup("en1"); +#elif defined (__linux__) + *udp_property->allow_interface.get_reference(1) = + DDS::String_dup("eth0"); +#elif defined(_WIN32) + *udp_property->allow_interface.get_reference(1) = + DDS::String_dup("Local Area Connection"); +#else + #error Unknown operating system, currently only supports OSX/macOS, Linux and Windows +#endif + } + + udp_property->max_receive_buffer_size = 2097152; + udp_property->max_message_size = 65507; + + bresult = registry->register_component(NETIO::DEFAULT_UDP_NAME, + UDP::InterfaceFactory::get_interface(), + &udp_property->_parent._parent, + NULL); + if (!bresult) { + std::cout << "Failed to register UDP component" << std::endl; + goto done; + } + + bresult = registry->register_component( + "dpde", + DPDE::DiscoveryFactory::get_interface(), + &dpde_properties._parent, + NULL); + if (!bresult) { + std::cout << "Failed to register DPDE component" << std::endl; + goto done; + } + + result = DDS::RETCODE_OK; + +done: + return result; +} + +/* Functions that are equivalent to the member functions on ParticipantFactory */ + +DDS::ReturnCode_t +get_participant_qos_from_profile( + DDS::DomainParticipantQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + DDS::ReturnCode_t result = DDS::RETCODE_ERROR; + bool bresult; + + bresult = qos.discovery.discovery.name.set_name("dpde"); + if (!bresult) { + std::cout << "Failed to set discovery plugin name" << std::endl; + goto done; + } + + qos.discovery.initial_peers.maximum(1); + qos.discovery.initial_peers.length(1); + *qos.discovery.initial_peers.get_reference(0) = DDS_String_dup("127.0.0.1"); + + /* if there are more remote or local endpoints, you need to increase these limits */ + qos.resource_limits.max_destination_ports = 32; + qos.resource_limits.max_receive_ports = 32; + qos.resource_limits.local_topic_allocation = 1; + qos.resource_limits.local_type_allocation = 1; + qos.resource_limits.local_reader_allocation = 1; + qos.resource_limits.local_writer_allocation = 1; + qos.resource_limits.remote_participant_allocation = 8; + qos.resource_limits.remote_reader_allocation = 8; + qos.resource_limits.remote_writer_allocation = 8; + + result = DDS::RETCODE_OK; +done: + return result; +} + +DDS::ReturnCode_t +get_subscriber_qos_from_profile( + DDS::SubscriberQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + return DDS::RETCODE_OK; +} + +DDS::ReturnCode_t +get_datareader_qos_from_profile( + DDS::DataReaderQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + /* We assume a single writer of VideoData */ + qos.resource_limits.max_samples = VIDEOSTREAM_HISTORY_DEPTH; + qos.resource_limits.max_instances = 1; + qos.resource_limits.max_samples_per_instance = VIDEOSTREAM_HISTORY_DEPTH; + qos.reader_resource_limits.max_remote_writers = 1; + qos.reader_resource_limits.max_remote_writers_per_instance = 1; + qos.history.depth = VIDEOSTREAM_HISTORY_DEPTH; + + return DDS::RETCODE_OK; +} + +DDS::ReturnCode_t +get_publisher_qos_from_profile( + DDS::PublisherQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + return DDS::RETCODE_OK; +} + +DDS::ReturnCode_t +get_datawriter_qos_from_profile( + DDS::DataWriterQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + qos.resource_limits.max_samples = VIDEOSTREAM_HISTORY_DEPTH; + qos.resource_limits.max_samples_per_instance = VIDEOSTREAM_HISTORY_DEPTH; + qos.resource_limits.max_instances = 1; + qos.history.depth = VIDEOSTREAM_HISTORY_DEPTH; + + return DDS::RETCODE_OK; +} + + +} \ No newline at end of file diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_cpp_common.h b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_cpp_common.h new file mode 100644 index 00000000..9f5f284c --- /dev/null +++ b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_cpp_common.h @@ -0,0 +1,74 @@ +#ifndef CONNEXT_CPP_COMMON_H +#define CONNEXT_CPP_COMMON_H + +/* Micro versions of Connext-specific includes */ + +#include "rti_me_cpp.hxx" +#include "dds_cpp/dds_cpp_namespace.hxx" + +/* DDS generated code headers */ +#include "VideoData.h" +#include "VideoDataSupport.h" + +#define CONNEXT_HAS_BUILTINTOPICS (-1) +#define CONNEXT_HAS_USERDATA (-1) +#define VIDEODATA_MATCH_EMPTY_USERDATA (-1) + +/* Since Connext Micro does not support XML QoS profiles, we need to provide + functions that abstract the functionality */ + +#include +#include + +namespace Connext { + +/* Return type to hide the different return types */ + +const RTI_BOOL TYPESUPPORT_OK = RTI_TRUE; + +/* Encapsulating the sleep utility */ +/* Encapsulating the sleep utility */ +inline void sleep(long seconds, unsigned long nano_seconds) { + OSAPI_Thread_sleep(seconds*1000 + nano_seconds/1000); +} +/* Convenience function for setting profiles files in the ParticipantFactory */ + +DDS::ReturnCode_t +set_url_profile( + std::vector fileNames); + +/* Function encapsulating initialization of libraries, different for Pro and Micro */ + +DDS::ReturnCode_t +initialize_infrastructure(const std::string &interface_name); + +/* Functions that are equivalent to the member functions on ParticipantFactory */ + +DDS::ReturnCode_t +get_participant_qos_from_profile( + DDS::DomainParticipantQos &qos, + const std::string &library_name, const std::string &profile_name); + +DDS::ReturnCode_t +get_subscriber_qos_from_profile( + DDS::SubscriberQos &qos, + const std::string &library_name, const std::string &profile_name); + +DDS::ReturnCode_t +get_datareader_qos_from_profile( + DDS::DataReaderQos &qos, + const std::string &library_name, const std::string &profile_name); + +DDS::ReturnCode_t +get_publisher_qos_from_profile( + DDS::PublisherQos &qos, + const std::string &library_name, const std::string &profile_name); + +DDS::ReturnCode_t +get_datawriter_qos_from_profile( + DDS::DataWriterQos &qos, + const std::string &library_name, const std::string &profile_name); + +} + +#endif /* CONNEXT_CPP_COMMON_H */ diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_ec_log_info.i b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_ec_log_info.i new file mode 100644 index 00000000..adbd4a70 --- /dev/null +++ b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_ec_log_info.i @@ -0,0 +1,649 @@ +/* RTI Connext Micro 2.4.8 error code information file + * Generated: Wed Sep 21 12:10:40 EDT 2016 + */ + +#include "dds_c/dds_c_log.h" +#include "disc_dpde/disc_dpde_log.h" +#include "disc_dpse/disc_dpse_log.h" +#include "netio/netio_log.h" +#include "osapi/osapi_log.h" +#include "reda/reda_log.h" +#include "rh_sm/rh_sm_log.h" +#include "rt/rt_log.h" +#include "rtps/rtps_log.h" +#include "wh_sm/wh_sm_log.h" +#include "cdr/cdr_log.h" +#include "db/db_log.h" + +struct ec_log_info { + unsigned int value; + const char *name; + const char *module_name; + const char *definition; + const char *definition_file; + const char *brief; +}; + +#define EC_LOG_INFO_COUNT (620) +static const struct ec_log_info S_ec_log_infos[EC_LOG_INFO_COUNT] = { + {CDR_LOG_STREAM_ALLOC_EC, "CDR_LOG_STREAM_ALLOC_EC", "CDR", "(CDR_LOG_BASE + 1)", "cdr/cdr_log.h", "Failed to allocate stream or stream buffer"}, + {CDR_LOG_SET_OFFSET_EC, "CDR_LOG_SET_OFFSET_EC", "CDR", "(CDR_LOG_BASE + 2)", "cdr/cdr_log.h", "Failed to set stream's current offset"}, + {CDR_LOG_INCR_OFFSET_EC, "CDR_LOG_INCR_OFFSET_EC", "CDR", "(CDR_LOG_BASE + 3)", "cdr/cdr_log.h", "Failed to increament stream's current offset"}, + {DB_LOG_SORTED_ALLOC_EC, "DB_LOG_SORTED_ALLOC_EC", "DB", "(DB_LOG_BASE + 1)", "db/db_log.h", "Not sufficient memory to allocate sorted list for an index"}, + {DB_LOG_NAME_TOO_LONG_EC, "DB_LOG_NAME_TOO_LONG_EC", "DB", "(DB_LOG_BASE + 2)", "db/db_log.h", "The specified database name is too long"}, + {DB_LOG_ILLEGAL_TABLE_SIZE_EC, "DB_LOG_ILLEGAL_TABLE_SIZE_EC", "DB", "(DB_LOG_BASE + 3)", "db/db_log.h", "Illegal table size specified"}, + {DB_LOG_ILLEGAL_LOCK_MODE_EC, "DB_LOG_ILLEGAL_LOCK_MODE_EC", "DB", "(DB_LOG_BASE + 4)", "db/db_log.h", "Illegal combination of lock mode and mutex given"}, + {DB_LOG_MUTEX_ALLOC_EC, "DB_LOG_MUTEX_ALLOC_EC", "DB", "(DB_LOG_BASE + 5)", "db/db_log.h", "Failed to allocate database mutex"}, + {DB_LOG_ALLOC_TABLE_POOL_EC, "DB_LOG_ALLOC_TABLE_POOL_EC", "DB", "(DB_LOG_BASE + 6)", "db/db_log.h", "Failed to allocate buffer pool"}, + {DB_LOG_TABLES_INUSE_EC, "DB_LOG_TABLES_INUSE_EC", "DB", "(DB_LOG_BASE + 7)", "db/db_log.h", "Table is in use"}, + {DB_LOG_TABLE_NAME_TOO_LONG_EC, "DB_LOG_TABLE_NAME_TOO_LONG_EC", "DB", "(DB_LOG_BASE + 8)", "db/db_log.h", "Specified table name too long"}, + {DB_LOG_ILLEGAL_RECORD_COUNT_EC, "DB_LOG_ILLEGAL_RECORD_COUNT_EC", "DB", "(DB_LOG_BASE + 9)", "db/db_log.h", "Illegal record count specified"}, + {DB_LOG_TABLE_EXISTS_EC, "DB_LOG_TABLE_EXISTS_EC", "DB", "(DB_LOG_BASE + 10)", "db/db_log.h", "Specified table already exists"}, + {DB_LOG_OUT_OF_TABLES_EC, "DB_LOG_OUT_OF_TABLES_EC", "DB", "(DB_LOG_BASE + 11)", "db/db_log.h", "Table resources exceeded"}, + {DB_LOG_OUT_OF_RECORDS_EC, "DB_LOG_OUT_OF_RECORDS_EC", "DB", "(DB_LOG_BASE + 12)", "db/db_log.h", "Table record resources exceeded"}, + {DB_LOG_OUT_OF_INDICES_EC, "DB_LOG_OUT_OF_INDICES_EC", "DB", "(DB_LOG_BASE + 13)", "db/db_log.h", "Table index resources exceeded"}, + {DB_LOG_OUT_OF_CURSORS_EC, "DB_LOG_OUT_OF_CURSORS_EC", "DB", "(DB_LOG_BASE + 14)", "db/db_log.h", "Table cursor resources exceeded"}, + {DB_LOG_RECORDS_INUSE_EC, "DB_LOG_RECORDS_INUSE_EC", "DB", "(DB_LOG_BASE + 15)", "db/db_log.h", "Cannot delete table, records are still in table"}, + {DB_LOG_CURSORS_INUSE_EC, "DB_LOG_CURSORS_INUSE_EC", "DB", "(DB_LOG_BASE + 16)", "db/db_log.h", "Cannot delete table, cursors are still in use"}, + {DB_LOG_INDEX_INUSE_EC, "DB_LOG_INDEX_INUSE_EC", "DB", "(DB_LOG_BASE + 17)", "db/db_log.h", "Cannot delete table, indices are still in use"}, + {DB_LOG_ALLOC_CURSOR_POOL_EC, "DB_LOG_ALLOC_CURSOR_POOL_EC", "DB", "(DB_LOG_BASE + 18)", "db/db_log.h", "Failed to allocate cursor buffer pool"}, + {DB_LOG_ALLOC_INDEX_POOL_EC, "DB_LOG_ALLOC_INDEX_POOL_EC", "DB", "(DB_LOG_BASE + 19)", "db/db_log.h", "Failed to allocate index buffer pool"}, + {DB_LOG_ALLOC_RECORD_POOL_EC, "DB_LOG_ALLOC_RECORD_POOL_EC", "DB", "(DB_LOG_BASE + 20)", "db/db_log.h", "Failed to allocate record buffer pool"}, + {DB_LOG_ALLOC_DATABASE_EC, "DB_LOG_ALLOC_DATABASE_EC", "DB", "(DB_LOG_BASE + 21)", "db/db_log.h", "Failed to allocate database"}, + {DB_LOG_TABLE_NOT_INUSE_EC, "DB_LOG_TABLE_NOT_INUSE_EC", "DB", "(DB_LOG_BASE + 22)", "db/db_log.h", "An attempt was made to delete a table not in use"}, + {DB_LOG_RECORD_ALREADY_EXISTS_EC, "DB_LOG_RECORD_ALREADY_EXISTS_EC", "DB", "(DB_LOG_BASE + 23)", "db/db_log.h", "An attempt was made to insert an already existing record"}, + {DB_LOG_RECORD_DOES_NOT_EXIST_EC, "DB_LOG_RECORD_DOES_NOT_EXIST_EC", "DB", "(DB_LOG_BASE + 24)", "db/db_log.h", "An attempt was made to delete a record that does not exist"}, + {DB_LOG_CURSOR_INVALIDATED_EC, "DB_LOG_CURSOR_INVALIDATED_EC", "DB", "(DB_LOG_BASE + 25)", "db/db_log.h", "An attempt was made to use a cursor that has been invalidated"}, + {DB_LOG_LOCK_FAILURE_EC, "DB_LOG_LOCK_FAILURE_EC", "DB", "(DB_LOG_BASE + 26)", "db/db_log.h", "Failed to lock the database"}, + {DB_LOG_UNLOCK_FAILURE_EC, "DB_LOG_UNLOCK_FAILURE_EC", "DB", "(DB_LOG_BASE + 27)", "db/db_log.h", "Failed to unlock the database"}, + {DDSC_LOG_INVALID_DURATION_EC, "DDSC_LOG_INVALID_DURATION_EC", "DDSC", "(DDSC_LOG_BASE + 1)", "dds_c/dds_c_log.h", "The specified duration is not valid."}, + {DDSC_LOG_INVALID_PARTICIPANT_NAME_EC, "DDSC_LOG_INVALID_PARTICIPANT_NAME_EC", "DDSC", "(DDSC_LOG_BASE + 2)", "dds_c/dds_c_log.h", "An invalid participant name was specified with an unknown GUID."}, + {DDSC_LOG_INVALID_PARTICIPANT_GUID_PREFIX_EC, "DDSC_LOG_INVALID_PARTICIPANT_GUID_PREFIX_EC", "DDSC", "(DDSC_LOG_BASE + 3)", "dds_c/dds_c_log.h", "An invalid participant GUID prefix was specified, typically the"}, + {DDSC_LOG_SYS_GETTIME_EC, "DDSC_LOG_SYS_GETTIME_EC", "DDSC", "(DDSC_LOG_BASE + 4)", "dds_c/dds_c_log.h", "A call to OSAPI_System_get_time failed."}, + {DDSC_LOG_GET_NEXT_OBJECT_ID_EC, "DDSC_LOG_GET_NEXT_OBJECT_ID_EC", "DDSC", "(DDSC_LOG_BASE + 5)", "dds_c/dds_c_log.h", "Failed to get the next automatically generated object ID for an"}, + {DDSC_LOG_SET_ENTITY_NAME_EC, "DDSC_LOG_SET_ENTITY_NAME_EC", "DDSC", "(DDSC_LOG_BASE + 6)", "dds_c/dds_c_log.h", "Failed to set name string for a DDS entity in the DomainParticipantQos"}, + {DDSC_LOG_SYS_GET_HOSTNAME_EC, "DDSC_LOG_SYS_GET_HOSTNAME_EC", "DDSC", "(DDSC_LOG_BASE + 7)", "dds_c/dds_c_log.h", "A call to OSAPI_System_get_hostname failed."}, + {DDSC_LOG_IO_SNPRINTF_FAILED_EC, "DDSC_LOG_IO_SNPRINTF_FAILED_EC", "DDSC", "(DDSC_LOG_BASE + 8)", "dds_c/dds_c_log.h", "A call to OSAPI_Stdio_snprintf failed. Typically this means the"}, + {DDSC_LOG_TOPIC_FIND_EC, "DDSC_LOG_TOPIC_FIND_EC", "DDSC", "(DDSC_LOG_BASE + 9)", "dds_c/dds_c_log.h", "Failed to find a topic created by a DomainParticipant."}, + {DDSC_LOG_UNKNOWN_REMOTE_PARTICIPANT_NAME_EC, "DDSC_LOG_UNKNOWN_REMOTE_PARTICIPANT_NAME_EC", "DDSC", "(DDSC_LOG_BASE + 10)", "dds_c/dds_c_log.h", "Endpoint discovery failed because the name of the remote participant"}, + {DDSC_LOG_UNKNOWN_REMOTE_PARTICIPANT_KEY_EC, "DDSC_LOG_UNKNOWN_REMOTE_PARTICIPANT_KEY_EC", "DDSC", "(DDSC_LOG_BASE + 11)", "dds_c/dds_c_log.h", "Endpoint discovery failed because the key of the remote participant"}, + {DDSC_LOG_REMOTE_PARTICIPANT_KEY_NOT_EQUAL_EC, "DDSC_LOG_REMOTE_PARTICIPANT_KEY_NOT_EQUAL_EC", "DDSC", "(DDSC_LOG_BASE + 12)", "dds_c/dds_c_log.h", "Failed endpoint discovery when key does not match the remote"}, + {DDSC_LOG_INVALID_ENDPOINT_GUID_EC, "DDSC_LOG_INVALID_ENDPOINT_GUID_EC", "DDSC", "(DDSC_LOG_BASE + 13)", "dds_c/dds_c_log.h", "Failed endpoint discovery due to an invalid or unknown endpoint GUID."}, + {DDSC_LOG_ENDPOINT_NOT_CHILD_OF_PARTICIPANT_EC, "DDSC_LOG_ENDPOINT_NOT_CHILD_OF_PARTICIPANT_EC", "DDSC", "(DDSC_LOG_BASE + 14)", "dds_c/dds_c_log.h", "Failed endpoint discovery when an endpoint is determined to belong to"}, + {DDSC_LOG_PARTICIPANT_DOES_NOT_EXIST_EC, "DDSC_LOG_PARTICIPANT_DOES_NOT_EXIST_EC", "DDSC", "(DDSC_LOG_BASE + 15)", "dds_c/dds_c_log.h", "Failed participant discovery because a remote participant that should"}, + {DDSC_LOG_REFRESH_REM_PARTICIPANT_EC, "DDSC_LOG_REFRESH_REM_PARTICIPANT_EC", "DDSC", "(DDSC_LOG_BASE + 16)", "dds_c/dds_c_log.h", "Did not find a remote participant when asserting participant"}, + {DDSC_LOG_REFRESH_REM_PARTICIPANT_TIMEOUT_EC, "DDSC_LOG_REFRESH_REM_PARTICIPANT_TIMEOUT_EC", "DDSC", "(DDSC_LOG_BASE + 17)", "dds_c/dds_c_log.h", "Failed to assert participant liveliness to a remote participant."}, + {DDSC_LOG_PARTICIPANT_LOOKUP_EC, "DDSC_LOG_PARTICIPANT_LOOKUP_EC", "DDSC", "(DDSC_LOG_BASE + 18)", "dds_c/dds_c_log.h", "Failed to find a remote participant as previously discovered."}, + {DDSC_LOG_REMOVE_PUBLICATION_EC, "DDSC_LOG_REMOVE_PUBLICATION_EC", "DDSC", "(DDSC_LOG_BASE + 19)", "dds_c/dds_c_log.h", "Failed to remove resources for a remote publication."}, + {DDSC_LOG_REMOVE_SUBSCRIPTION_EC, "DDSC_LOG_REMOVE_SUBSCRIPTION_EC", "DDSC", "(DDSC_LOG_BASE + 20)", "dds_c/dds_c_log.h", "Failed to remove resources for a remote subscription."}, + {DDSC_LOG_FIND_PUBLICATION_PARENT_EC, "DDSC_LOG_FIND_PUBLICATION_PARENT_EC", "DDSC", "(DDSC_LOG_BASE + 21)", "dds_c/dds_c_log.h", "Cannot determine the participant of a remote publication."}, + {DDSC_LOG_FIND_SUBSCRIPTION_PARENT_EC, "DDSC_LOG_FIND_SUBSCRIPTION_PARENT_EC", "DDSC", "(DDSC_LOG_BASE + 22)", "dds_c/dds_c_log.h", "Cannot determine the participant of a remote subscription."}, + {DDSC_LOG_MAX_PARTICIPANT_ID_REACHED_EC, "DDSC_LOG_MAX_PARTICIPANT_ID_REACHED_EC", "DDSC", "(DDSC_LOG_BASE + 23)", "dds_c/dds_c_log.h", "Failed to create DomainParticipant due to running out of participant"}, + {DDSC_LOG_RESERVE_LOCATORS_EC, "DDSC_LOG_RESERVE_LOCATORS_EC", "DDSC", "(DDSC_LOG_BASE + 24)", "dds_c/dds_c_log.h", "Failed to reserve endpoint locators."}, + {DDSC_LOG_TIMER_CREATE_TIMEOUT_EC, "DDSC_LOG_TIMER_CREATE_TIMEOUT_EC", "DDSC", "(DDSC_LOG_BASE + 25)", "dds_c/dds_c_log.h", "Failed to create a timeout."}, + {DDSC_LOG_ILLEGAL_OBJECTID_EC, "DDSC_LOG_ILLEGAL_OBJECTID_EC", "DDSC", "(DDSC_LOG_BASE + 26)", "dds_c/dds_c_log.h", "Illegal object id specified."}, + {DDSC_LOG_TOPIC_NARROW_EC, "DDSC_LOG_TOPIC_NARROW_EC", "DDSC", "(DDSC_LOG_BASE + 27)", "dds_c/dds_c_log.h", "Failed to narrow a TopicDescription to the named Topic."}, + {DDSC_LOG_FAILED_UPDATE_STATUS_CONDITION_EC, "DDSC_LOG_FAILED_UPDATE_STATUS_CONDITION_EC", "DDSC", "(DDSC_LOG_BASE + 28)", "dds_c/dds_c_log.h", "Failed to update state of StatusCondition."}, + {DDSC_LOG_WS_REMOVE_COND_REFERENCE_EC, "DDSC_LOG_WS_REMOVE_COND_REFERENCE_EC", "DDSC", "(DDSC_LOG_BASE + 29)", "dds_c/dds_c_log.h", "Failed to remove a condition reference from a waitset."}, + {DDSC_LOG_WS_ADD_COND_REFERENCE_EC, "DDSC_LOG_WS_ADD_COND_REFERENCE_EC", "DDSC", "(DDSC_LOG_BASE + 30)", "dds_c/dds_c_log.h", "Failed to add a condition reference to a waitset."}, + {DDSC_LOG_RELEASE_META_MC_EC, "DDSC_LOG_RELEASE_META_MC_EC", "DDSC", "(DDSC_LOG_BASE + 31)", "dds_c/dds_c_log.h", "Failed to release resources for multicast discovery locators."}, + {DDSC_LOG_RELEASE_META_UC_EC, "DDSC_LOG_RELEASE_META_UC_EC", "DDSC", "(DDSC_LOG_BASE + 32)", "dds_c/dds_c_log.h", "Failed to release resources for unicast discovery locators."}, + {DDSC_LOG_RELEASE_USER_MC_EC, "DDSC_LOG_RELEASE_USER_MC_EC", "DDSC", "(DDSC_LOG_BASE + 33)", "dds_c/dds_c_log.h", "Failed to release resources for multicast user locators."}, + {DDSC_LOG_RELEASE_USER_UC_EC, "DDSC_LOG_RELEASE_USER_UC_EC", "DDSC", "(DDSC_LOG_BASE + 34)", "dds_c/dds_c_log.h", "Failed to release resources for unicast user locators."}, + {DDSC_LOG_INVALID_DOMAINID_EC, "DDSC_LOG_INVALID_DOMAINID_EC", "DDSC", "(DDSC_LOG_BASE + 35)", "dds_c/dds_c_log.h", "The domain ID specified exceeds what is allowed based on the"}, + {DDSC_LOG_DATABASE_CREATE_EC, "DDSC_LOG_DATABASE_CREATE_EC", "DDSC", "(DDSC_LOG_BASE + 100)", "dds_c/dds_c_log.h", "Failed to create database."}, + {DDSC_LOG_DATABASE_DELETE_EC, "DDSC_LOG_DATABASE_DELETE_EC", "DDSC", "(DDSC_LOG_BASE + 101)", "dds_c/dds_c_log.h", "Failed to delete database."}, + {DDSC_LOG_TABLE_CREATE_EC, "DDSC_LOG_TABLE_CREATE_EC", "DDSC", "(DDSC_LOG_BASE + 102)", "dds_c/dds_c_log.h", "Failed to create database table of the specified name."}, + {DDSC_LOG_TABLE_INUSE_EC, "DDSC_LOG_TABLE_INUSE_EC", "DDSC", "(DDSC_LOG_BASE + 103)", "dds_c/dds_c_log.h", "Failed to delete a database table because it is not empty."}, + {DDSC_LOG_TABLE_DELETE_EC, "DDSC_LOG_TABLE_DELETE_EC", "DDSC", "(DDSC_LOG_BASE + 104)", "dds_c/dds_c_log.h", "Failed to delete a database table."}, + {DDSC_LOG_TABLE_SELECT_EC, "DDSC_LOG_TABLE_SELECT_EC", "DDSC", "(DDSC_LOG_BASE + 105)", "dds_c/dds_c_log.h", "A selection operation failed on the specified database table."}, + {DDSC_LOG_CREATE_INDEX_EC, "DDSC_LOG_CREATE_INDEX_EC", "DDSC", "(DDSC_LOG_BASE + 106)", "dds_c/dds_c_log.h", "Failed to create an index on a database table."}, + {DDSC_LOG_DELETE_INDEX_EC, "DDSC_LOG_DELETE_INDEX_EC", "DDSC", "(DDSC_LOG_BASE + 107)", "dds_c/dds_c_log.h", "Failed to delete an index on a database table."}, + {DDSC_LOG_DB_CURSOR_INVALIDATED_EC, "DDSC_LOG_DB_CURSOR_INVALIDATED_EC", "DDSC", "(DDSC_LOG_BASE + 108)", "dds_c/dds_c_log.h", "A database table cursor was invalidated while in use."}, + {DDSC_LOG_RECORD_CREATE_EC, "DDSC_LOG_RECORD_CREATE_EC", "DDSC", "(DDSC_LOG_BASE + 109)", "dds_c/dds_c_log.h", "Failed to create route record of the specified kind."}, + {DDSC_LOG_RECORD_DELETE_EC, "DDSC_LOG_RECORD_DELETE_EC", "DDSC", "(DDSC_LOG_BASE + 110)", "dds_c/dds_c_log.h", "Failed to delete a database record of the specified kind."}, + {DDSC_LOG_RECORD_INSERT_EC, "DDSC_LOG_RECORD_INSERT_EC", "DDSC", "(DDSC_LOG_BASE + 111)", "dds_c/dds_c_log.h", "Failed to insert a database record of the specified kind."}, + {DDSC_LOG_RECORD_ERROR_EC, "DDSC_LOG_RECORD_ERROR_EC", "DDSC", "(DDSC_LOG_BASE + 112)", "dds_c/dds_c_log.h", "Unknown error for database record of the specified kind."}, + {DDSC_LOG_RECORD_EXISTS_EC, "DDSC_LOG_RECORD_EXISTS_EC", "DDSC", "(DDSC_LOG_BASE + 113)", "dds_c/dds_c_log.h", "A database record of the specified kind already exists."}, + {DDSC_LOG_RECORD_LOOKUP_EC, "DDSC_LOG_RECORD_LOOKUP_EC", "DDSC", "(DDSC_LOG_BASE + 114)", "dds_c/dds_c_log.h", "A lookup of a database record of the specified kind failed."}, + {DDSC_LOG_RECORD_NOT_EXISTS_EC, "DDSC_LOG_RECORD_NOT_EXISTS_EC", "DDSC", "(DDSC_LOG_BASE + 115)", "dds_c/dds_c_log.h", "A database record of the specified kind does not exist."}, + {DDSC_LOG_RECORD_SELECT_EC, "DDSC_LOG_RECORD_SELECT_EC", "DDSC", "(DDSC_LOG_BASE + 116)", "dds_c/dds_c_log.h", "A database select on the specified record kind failed."}, + {DDSC_LOG_RECORD_REMOVE_EC, "DDSC_LOG_RECORD_REMOVE_EC", "DDSC", "(DDSC_LOG_BASE + 117)", "dds_c/dds_c_log.h", "Removal a database record of the specified kind failed."}, + {DDSC_LOG_RECORD_INITIALIZE_EC, "DDSC_LOG_RECORD_INITIALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 118)", "dds_c/dds_c_log.h", "A database record of the specified kind could not be initialized"}, + {DDSC_LOG_RECORD_FINALIZE_EC, "DDSC_LOG_RECORD_FINALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 119)", "dds_c/dds_c_log.h", "A database record of the specified kind could not be finalized"}, + {DDSC_LOG_OBJECT_INITIALIZE_EC, "DDSC_LOG_OBJECT_INITIALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 200)", "dds_c/dds_c_log.h", "Out of resources to initialize object of the specified kind."}, + {DDSC_LOG_OBJECT_ALLOCATE_EC, "DDSC_LOG_OBJECT_ALLOCATE_EC", "DDSC", "(DDSC_LOG_BASE + 201)", "dds_c/dds_c_log.h", "Out of resources to allocate an object of the specified kind."}, + {DDSC_LOG_OBJECT_FINALIZE_EC, "DDSC_LOG_OBJECT_FINALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 202)", "dds_c/dds_c_log.h", "Failed to finalize object of specified kind."}, + {DDSC_LOG_OBJECT_DELETE_EC, "DDSC_LOG_OBJECT_DELETE_EC", "DDSC", "(DDSC_LOG_BASE + 203)", "dds_c/dds_c_log.h", "Failed to delete object of specified kind."}, + {DDSC_LOG_OBJECT_COPY_EC, "DDSC_LOG_OBJECT_COPY_EC", "DDSC", "(DDSC_LOG_BASE + 204)", "dds_c/dds_c_log.h", "Failed to copy object of specified kind."}, + {DDSC_LOG_OBJECT_REFCOUNT_EC, "DDSC_LOG_OBJECT_REFCOUNT_EC", "DDSC", "(DDSC_LOG_BASE + 205)", "dds_c/dds_c_log.h", "Failed to delete/finalize an object because other objects are"}, + {DDSC_LOG_OBJECT_GET_PROPERTY_EC, "DDSC_LOG_OBJECT_GET_PROPERTY_EC", "DDSC", "(DDSC_LOG_BASE + 206)", "dds_c/dds_c_log.h", "Failed to get the object properties."}, + {DDSC_LOG_OBJECT_SET_PROPERTY_EC, "DDSC_LOG_OBJECT_SET_PROPERTY_EC", "DDSC", "(DDSC_LOG_BASE + 207)", "dds_c/dds_c_log.h", "Failed to set the object properties."}, + {DDSC_LOG_OBJECT_EMPTY_EC, "DDSC_LOG_OBJECT_EMPTY_EC", "DDSC", "(DDSC_LOG_BASE + 208)", "dds_c/dds_c_log.h", "An object is empty, typically applies only to buffer-pool objects"}, + {DDSC_LOG_OBJECT_NOT_EMPTY_EC, "DDSC_LOG_OBJECT_NOT_EMPTY_EC", "DDSC", "(DDSC_LOG_BASE + 208)", "dds_c/dds_c_log.h", "An object is empty, typically applies only to buffer-pool objects"}, + {DDSC_LOG_SEQUENCE_SETMAX_EC, "DDSC_LOG_SEQUENCE_SETMAX_EC", "DDSC", "(DDSC_LOG_BASE + 300)", "dds_c/dds_c_log.h", "Failed to set the maximum length of a sequence of the specified kind."}, + {DDSC_LOG_SEQUENCE_SETLENGTH_EC, "DDSC_LOG_SEQUENCE_SETLENGTH_EC", "DDSC", "(DDSC_LOG_BASE + 301)", "dds_c/dds_c_log.h", "Failed to set the length of a sequence of the specified kind."}, + {DDSC_LOG_SEQUENCE_GETREF_EC, "DDSC_LOG_SEQUENCE_GETREF_EC", "DDSC", "(DDSC_LOG_BASE + 302)", "dds_c/dds_c_log.h", "Failed to get a reference at the specified index for a sequence of"}, + {DDSC_LOG_SEQUENCE_INITIALIZE_EC, "DDSC_LOG_SEQUENCE_INITIALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 303)", "dds_c/dds_c_log.h", "Failed to initialize a sequence of the specified kind."}, + {DDSC_LOG_SEQUENCE_FINALIZE_EC, "DDSC_LOG_SEQUENCE_FINALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 304)", "dds_c/dds_c_log.h", "Failed to finalize a sequence of the specified kind."}, + {DDSC_LOG_SEQUENCE_COPY_EC, "DDSC_LOG_SEQUENCE_COPY_EC", "DDSC", "(DDSC_LOG_BASE + 305)", "dds_c/dds_c_log.h", "Failed to copy a sequence of the specified kind."}, + {DDSC_LOG_SEQUENCE_INVALID_EC, "DDSC_LOG_SEQUENCE_INVALID_EC", "DDSC", "(DDSC_LOG_BASE + 306)", "dds_c/dds_c_log.h", "The sequence of the specified kind was invalid in the context it is"}, + {DDSC_LOG_COMPONENT_LOOKUP_EC, "DDSC_LOG_COMPONENT_LOOKUP_EC", "DDSC", "(DDSC_LOG_BASE + 400)", "dds_c/dds_c_log.h", "Did not find a component factory with the given name in the registry"}, + {DDSC_LOG_COMPONENT_CREATE_EC, "DDSC_LOG_COMPONENT_CREATE_EC", "DDSC", "(DDSC_LOG_BASE + 401)", "dds_c/dds_c_log.h", "Could not create a component of the specified kind using the specified"}, + {DDSC_LOG_COMPONENT_DELETE_EC, "DDSC_LOG_COMPONENT_DELETE_EC", "DDSC", "(DDSC_LOG_BASE + 402)", "dds_c/dds_c_log.h", "Could not delete a component of the specified kind using the specified"}, + {DDSC_LOG_RESOURCE_EXCEEDED_EC, "DDSC_LOG_RESOURCE_EXCEEDED_EC", "DDSC", "(DDSC_LOG_BASE + 500)", "dds_c/dds_c_log.h", "Could not allocate a resource of the specified kind"}, + {DDSC_LOG_QOS_INCONSISTENT_POLICY_EC, "DDSC_LOG_QOS_INCONSISTENT_POLICY_EC", "DDSC", "(DDSC_LOG_BASE + 501)", "dds_c/dds_c_log.h", "An inconsistent Qos policy for the specified Qos kind was found."}, + {DDSC_LOG_QOS_INCONSISTENT_POLICIES_EC, "DDSC_LOG_QOS_INCONSISTENT_POLICIES_EC", "DDSC", "(DDSC_LOG_BASE + 502)", "dds_c/dds_c_log.h", "Inconsistency between two Qos policies for the specified Qos kind was"}, + {DDSC_LOG_QOS_INCONSISTENT_EC, "DDSC_LOG_QOS_INCONSISTENT_EC", "DDSC", "(DDSC_LOG_BASE + 503)", "dds_c/dds_c_log.h", "Failed to create an entity or set a qos due to inconsistent policy"}, + {DDSC_LOG_QOS_COPY_EC, "DDSC_LOG_QOS_COPY_EC", "DDSC", "(DDSC_LOG_BASE + 504)", "dds_c/dds_c_log.h", "Failed to copy a Qos of the specified kind."}, + {DDSC_LOG_QOS_INITIALIZE_EC, "DDSC_LOG_QOS_INITIALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 505)", "dds_c/dds_c_log.h", "Failed to initialize a Qos of the specified kind."}, + {DDSC_LOG_QOS_FINALIZE_EC, "DDSC_LOG_QOS_FINALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 506)", "dds_c/dds_c_log.h", "Failed to finalize a Qos of the specified kind."}, + {DDSC_LOG_QOS_SET_EC, "DDSC_LOG_QOS_SET_EC", "DDSC", "(DDSC_LOG_BASE + 507)", "dds_c/dds_c_log.h", "Failed to set a Qos of the specified kind."}, + {DDSC_LOG_QOS_SET_ON_ENABLED_EC, "DDSC_LOG_QOS_SET_ON_ENABLED_EC", "DDSC", "(DDSC_LOG_BASE + 508)", "dds_c/dds_c_log.h", "Failed to set a Qos of the specified kind because the entity is"}, + {DDSC_LOG_QOS_IMMUTABLE_EC, "DDSC_LOG_QOS_IMMUTABLE_EC", "DDSC", "(DDSC_LOG_BASE + 509)", "dds_c/dds_c_log.h", "Failed to set a Qos of the specified kind the immutable Qos policies"}, + {DDSC_LOG_QOS_CHANGED_EC, "DDSC_LOG_QOS_CHANGED_EC", "DDSC", "(DDSC_LOG_BASE + 510)", "dds_c/dds_c_log.h", "A discovered Qos changed (the entity already existed)"}, + {DDSC_LOG_QOS_GET_EC, "DDSC_LOG_QOS_GET_EC", "DDSC", "(DDSC_LOG_BASE + 511)", "dds_c/dds_c_log.h", "Failed to get a Qos of the specified kind."}, + {DDSC_LOG_LISTENER_INCONSISTENT_EC, "DDSC_LOG_LISTENER_INCONSISTENT_EC", "DDSC", "(DDSC_LOG_BASE + 512)", "dds_c/dds_c_log.h", "Failed to create an entity due to inconsistent listener and"}, + {DDSC_LOG_LISTENER_SET_EC, "DDSC_LOG_LISTENER_SET_EC", "DDSC", "(DDSC_LOG_BASE + 513)", "dds_c/dds_c_log.h", "Failed to set the listener of the specified kind"}, + {DDSC_LOG_LISTENER_GET_EC, "DDSC_LOG_LISTENER_GET_EC", "DDSC", "(DDSC_LOG_BASE + 514)", "dds_c/dds_c_log.h", "Failed to get the listener of the specified kind"}, + {DDSC_LOG_LISTENER_SET_ILLEGAL_NULL_EC, "DDSC_LOG_LISTENER_SET_ILLEGAL_NULL_EC", "DDSC", "(DDSC_LOG_BASE + 515)", "dds_c/dds_c_log.h", "Illegal combination of NULL listener and non-NONE status mask when"}, + {DDSC_LOG_ENTITY_ENABLE_EC, "DDSC_LOG_ENTITY_ENABLE_EC", "DDSC", "(DDSC_LOG_BASE + 600)", "dds_c/dds_c_log.h", "Failed to enable an entity of the specified kind"}, + {DDSC_LOG_ENTITY_NOT_EMPTY_EC, "DDSC_LOG_ENTITY_NOT_EMPTY_EC", "DDSC", "(DDSC_LOG_BASE + 601)", "dds_c/dds_c_log.h", "Failed to an delete/finalize an entity of the specified kind because"}, + {DDSC_LOG_ENTITY_FINALIZE_EC, "DDSC_LOG_ENTITY_FINALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 602)", "dds_c/dds_c_log.h", "Failed to finalize an entity of the specified kind"}, + {DDSC_LOG_ENTITY_INITIALIZE_EC, "DDSC_LOG_ENTITY_INITIALIZE_EC", "DDSC", "(DDSC_LOG_BASE + 603)", "dds_c/dds_c_log.h", "Failed to initialize an entity of the specified kind"}, + {DDSC_LOG_ENTITY_NOT_ENABLED_EC, "DDSC_LOG_ENTITY_NOT_ENABLED_EC", "DDSC", "(DDSC_LOG_BASE + 604)", "dds_c/dds_c_log.h", "An operation was attempted on an entity that is not enabled"}, + {DDSC_LOG_ENTITY_DIFFERENT_FACTORY_EC, "DDSC_LOG_ENTITY_DIFFERENT_FACTORY_EC", "DDSC", "(DDSC_LOG_BASE + 605)", "dds_c/dds_c_log.h", "Entities are in different factories"}, + {DDSC_LOG_CDR_POOL_ALLOC_EC, "DDSC_LOG_CDR_POOL_ALLOC_EC", "DDSC", "(DDSC_LOG_BASE + 700)", "dds_c/dds_c_log.h", "Failed to allocate a pool of the specified kind"}, + {DDSC_LOG_CDR_BUFFER_SET_EC, "DDSC_LOG_CDR_BUFFER_SET_EC", "DDSC", "(DDSC_LOG_BASE + 701)", "dds_c/dds_c_log.h", "Failed to set the CDR buffer for a packet"}, + {DDSC_LOG_CDR_POOL_DELETE_EC, "DDSC_LOG_CDR_POOL_DELETE_EC", "DDSC", "(DDSC_LOG_BASE + 702)", "dds_c/dds_c_log.h", "Failed to delete the CDR pool"}, + {DDSC_LOG_CDR_SERIALIZE_PID_EC, "DDSC_LOG_CDR_SERIALIZE_PID_EC", "DDSC", "(DDSC_LOG_BASE + 703)", "dds_c/dds_c_log.h", "Failed to serialize a parameter ID"}, + {DDSC_LOG_CDR_SERIALIZE_PID_LENGTH_EC, "DDSC_LOG_CDR_SERIALIZE_PID_LENGTH_EC", "DDSC", "(DDSC_LOG_BASE + 704)", "dds_c/dds_c_log.h", "Failed to serialize a parameter length"}, + {DDSC_LOG_CDR_SERIALIZE_KEYHASH_EC, "DDSC_LOG_CDR_SERIALIZE_KEYHASH_EC", "DDSC", "(DDSC_LOG_BASE + 705)", "dds_c/dds_c_log.h", "Failed to serialize a key-hash"}, + {DDSC_LOG_CDR_SERIALIZE_DATA_EC, "DDSC_LOG_CDR_SERIALIZE_DATA_EC", "DDSC", "(DDSC_LOG_BASE + 706)", "dds_c/dds_c_log.h", "Failed to serialize payload data"}, + {DDSC_LOG_DESERIALIZE_BAD_PID_LENGTH_EC, "DDSC_LOG_DESERIALIZE_BAD_PID_LENGTH_EC", "DDSC", "(DDSC_LOG_BASE + 707)", "dds_c/dds_c_log.h", "Deserialized an invalid parameter length for a specific parameter ID"}, + {DDSC_LOG_CDR_DESERIALIZE_PID_EC, "DDSC_LOG_CDR_DESERIALIZE_PID_EC", "DDSC", "(DDSC_LOG_BASE + 708)", "dds_c/dds_c_log.h", "Failed to deserialize the ID of an inline parameter"}, + {DDSC_LOG_CDR_DESERIALIZE_PID_LENGTH_EC, "DDSC_LOG_CDR_DESERIALIZE_PID_LENGTH_EC", "DDSC", "(DDSC_LOG_BASE + 709)", "dds_c/dds_c_log.h", "Failed to deserialize the length of an inline parameter"}, + {DDSC_LOG_CDR_INCREMENT_POS_EC, "DDSC_LOG_CDR_INCREMENT_POS_EC", "DDSC", "(DDSC_LOG_BASE + 710)", "dds_c/dds_c_log.h", "Failed to increment to the position of the next inline parameter"}, + {DDSC_LOG_CDR_SET_POS_EC, "DDSC_LOG_CDR_SET_POS_EC", "DDSC", "(DDSC_LOG_BASE + 711)", "dds_c/dds_c_log.h", "Failed to set the reception stream position"}, + {DDSC_LOG_CDR_DESERIALIZE_HEADER_EC, "DDSC_LOG_CDR_DESERIALIZE_HEADER_EC", "DDSC", "(DDSC_LOG_BASE + 712)", "dds_c/dds_c_log.h", "Failed to deserialize the encapsulation header"}, + {DDSC_LOG_CDR_DESERIALIZE_DATA_EC, "DDSC_LOG_CDR_DESERIALIZE_DATA_EC", "DDSC", "(DDSC_LOG_BASE + 713)", "dds_c/dds_c_log.h", "Failed to deserialize CDR payload data"}, + {DDSC_LOG_CDR_INITIALIZE_SAMPLE_EC, "DDSC_LOG_CDR_INITIALIZE_SAMPLE_EC", "DDSC", "(DDSC_LOG_BASE + 714)", "dds_c/dds_c_log.h", "Failed to initialize CDR sample"}, + {DDSC_LOG_CDR_FINALIZE_SAMPLE_EC, "DDSC_LOG_CDR_FINALIZE_SAMPLE_EC", "DDSC", "(DDSC_LOG_BASE + 715)", "dds_c/dds_c_log.h", "Failed to finalize sample"}, + {DDSC_LOG_CDR_SERIALIZE_STATUS_INFO_EC, "DDSC_LOG_CDR_SERIALIZE_STATUS_INFO_EC", "DDSC", "(DDSC_LOG_BASE + 716)", "dds_c/dds_c_log.h", "Failed to serialize the status info parameter"}, + {DDSC_LOG_CDR_DESERIALIZE_KEYHASH_EC, "DDSC_LOG_CDR_DESERIALIZE_KEYHASH_EC", "DDSC", "(DDSC_LOG_BASE + 717)", "dds_c/dds_c_log.h", "Failed to deserialize a key-hash"}, + {DDSC_LOG_CDR_DESERIALIZE_KEY_EC, "DDSC_LOG_CDR_DESERIALIZE_KEY_EC", "DDSC", "(DDSC_LOG_BASE + 718)", "dds_c/dds_c_log.h", "Failed to deserialize CDR payload key"}, + {DDSC_LOG_NETIO_ADD_ANON_TOPIC_ROUTE_EC, "DDSC_LOG_NETIO_ADD_ANON_TOPIC_ROUTE_EC", "DDSC", "(DDSC_LOG_BASE + 800)", "dds_c/dds_c_log.h", "Failed to add a route to an anonymous participant discovery"}, + {DDSC_LOG_NETIO_ADD_TOPIC_ROUTE_EC, "DDSC_LOG_NETIO_ADD_TOPIC_ROUTE_EC", "DDSC", "(DDSC_LOG_BASE + 801)", "dds_c/dds_c_log.h", "Failed to add a route to a topic from a datawriter"}, + {DDSC_LOG_NETIO_DELETE_TOPIC_ROUTE_EC, "DDSC_LOG_NETIO_DELETE_TOPIC_ROUTE_EC", "DDSC", "(DDSC_LOG_BASE + 802)", "dds_c/dds_c_log.h", "Failed to delete a route to a topic"}, + {DDSC_LOG_NETIO_FORWARD_TOPIC_EC, "DDSC_LOG_NETIO_FORWARD_TOPIC_EC", "DDSC", "(DDSC_LOG_BASE + 803)", "dds_c/dds_c_log.h", "Failed to forward a topic"}, + {DDSC_LOG_NETIO_BIND_EXTERNAL_EC, "DDSC_LOG_NETIO_BIND_EXTERNAL_EC", "DDSC", "(DDSC_LOG_BASE + 804)", "dds_c/dds_c_log.h", "Failed to bind two external interface of the specified kind"}, + {DDSC_LOG_NETIO_UNBIND_EXTERNAL_EC, "DDSC_LOG_NETIO_UNBIND_EXTERNAL_EC", "DDSC", "(DDSC_LOG_BASE + 805)", "dds_c/dds_c_log.h", "Failed to unbind two external interfaces of the specified kind"}, + {DDSC_LOG_NETIO_BIND_EC, "DDSC_LOG_NETIO_BIND_EC", "DDSC", "(DDSC_LOG_BASE + 806)", "dds_c/dds_c_log.h", "Failed to bind an interface to a peer interface"}, + {DDSC_LOG_NETIO_UNBIND_EC, "DDSC_LOG_NETIO_UNBIND_EC", "DDSC", "(DDSC_LOG_BASE + 807)", "dds_c/dds_c_log.h", "Failed to unbind an interface from a peer interface"}, + {DDSC_LOG_NETIO_ADD_ROUTE_EC, "DDSC_LOG_NETIO_ADD_ROUTE_EC", "DDSC", "(DDSC_LOG_BASE + 808)", "dds_c/dds_c_log.h", "Failed to add a route from an interface to a peer interface"}, + {DDSC_LOG_NETIO_DELETE_ROUTE_EC, "DDSC_LOG_NETIO_DELETE_ROUTE_EC", "DDSC", "(DDSC_LOG_BASE + 809)", "dds_c/dds_c_log.h", "Failed to delete a route from an interface to a peer interface"}, + {DDSC_LOG_NETIO_GET_EXTERNAL_INTF_EC, "DDSC_LOG_NETIO_GET_EXTERNAL_INTF_EC", "DDSC", "(DDSC_LOG_BASE + 810)", "dds_c/dds_c_log.h", "Failed to get an external interface for the specified interface kind"}, + {DDSC_LOG_NETIO_NO_ROUTE_EC, "DDSC_LOG_NETIO_NO_ROUTE_EC", "DDSC", "(DDSC_LOG_BASE + 811)", "dds_c/dds_c_log.h", "A DataReader failed a bind due to no existing route"}, + {DDSC_LOG_NETIO_ROUTE_LOOKUP_FAILED_EC, "DDSC_LOG_NETIO_ROUTE_LOOKUP_FAILED_EC", "DDSC", "(DDSC_LOG_BASE + 812)", "dds_c/dds_c_log.h", "Lookup a route to a destination failed"}, + {DDSC_LOG_NETIO_GET_ROUTE_TABLE_FAILED_EC, "DDSC_LOG_NETIO_GET_ROUTE_TABLE_FAILED_EC", "DDSC", "(DDSC_LOG_BASE + 813)", "dds_c/dds_c_log.h", "Failed to get the route table for an interface"}, + {DDSC_LOG_NETIO_SEND_FAILED_EC, "DDSC_LOG_NETIO_SEND_FAILED_EC", "DDSC", "(DDSC_LOG_BASE + 814)", "dds_c/dds_c_log.h", "Failure when sending on an interface"}, + {DDSC_LOG_NETIO_SET_STATE_EC, "DDSC_LOG_NETIO_SET_STATE_EC", "DDSC", "(DDSC_LOG_BASE + 815)", "dds_c/dds_c_log.h", "Failed to set an interface state"}, + {DDSC_LOG_NETIO_PEER_LOOKUP_EC, "DDSC_LOG_NETIO_PEER_LOOKUP_EC", "DDSC", "(DDSC_LOG_BASE + 816)", "dds_c/dds_c_log.h", "Datawriter did not find a peer"}, + {DDSC_LOG_NETIO_FORCED_REMOVE_EC, "DDSC_LOG_NETIO_FORCED_REMOVE_EC", "DDSC", "(DDSC_LOG_BASE + 817)", "dds_c/dds_c_log.h", "Forced removal of sample downstream failed"}, + {DDSC_LOG_PACKET_INIT_EC, "DDSC_LOG_PACKET_INIT_EC", "DDSC", "(DDSC_LOG_BASE + 818)", "dds_c/dds_c_log.h", "Failed to initialize a packet"}, + {DDSC_LOG_PACKET_SET_HEAD_EC, "DDSC_LOG_PACKET_SET_HEAD_EC", "DDSC", "(DDSC_LOG_BASE + 819)", "dds_c/dds_c_log.h", "Failed to set the head of a packet"}, + {DDSC_LOG_PACKET_SET_TAIL_EC, "DDSC_LOG_PACKET_SET_TAIL_EC", "DDSC", "(DDSC_LOG_BASE + 820)", "dds_c/dds_c_log.h", "Failed to set the tail of a packet"}, + {DDSC_LOG_DW_ACKNACK_FAILED_EC, "DDSC_LOG_DW_ACKNACK_FAILED_EC", "DDSC", "(DDSC_LOG_BASE + 900)", "dds_c/dds_c_log.h", "Failed to ACKNACK sample in the writer history"}, + {DDSC_LOG_DW_COMMIT_EC, "DDSC_LOG_DW_COMMIT_EC", "DDSC", "(DDSC_LOG_BASE + 901)", "dds_c/dds_c_log.h", "Failed to commit a sample to the writer queue"}, + {DDSC_LOG_DW_KEYHASH_CREATE_EC, "DDSC_LOG_DW_KEYHASH_CREATE_EC", "DDSC", "(DDSC_LOG_BASE + 902)", "dds_c/dds_c_log.h", "Failed to create keyhash of instance handle"}, + {DDSC_LOG_DW_ILLEGAL_KEY_KIND_EC, "DDSC_LOG_DW_ILLEGAL_KEY_KIND_EC", "DDSC", "(DDSC_LOG_BASE + 903)", "dds_c/dds_c_log.h", "Failed a write due to an invalid key kind for the type being written"}, + {DDSC_LOG_DW_CREATE_TYPED_WRITER_EC, "DDSC_LOG_DW_CREATE_TYPED_WRITER_EC", "DDSC", "(DDSC_LOG_BASE + 904)", "dds_c/dds_c_log.h", "Failed to create a typed writer"}, + {DDSC_LOG_DW_HISTORY_REGISTER_KEY_EC, "DDSC_LOG_DW_HISTORY_REGISTER_KEY_EC", "DDSC", "(DDSC_LOG_BASE + 905)", "dds_c/dds_c_log.h", "Failed to register the key of an instance"}, + {DDSC_LOG_DR_CREATE_TYPED_READER_EC, "DDSC_LOG_DR_CREATE_TYPED_READER_EC", "DDSC", "(DDSC_LOG_BASE + 1000)", "dds_c/dds_c_log.h", "Failed to create a typed datareader"}, + {DDSC_LOG_DR_COPY_DATA_SAMPLE_EC, "DDSC_LOG_DR_COPY_DATA_SAMPLE_EC", "DDSC", "(DDSC_LOG_BASE + 1001)", "dds_c/dds_c_log.h", "Failed to copy a sample upon reception, read, or take"}, + {DDSC_LOG_DR_COMMIT_SAMPLE_EC, "DDSC_LOG_DR_COMMIT_SAMPLE_EC", "DDSC", "(DDSC_LOG_BASE + 1002)", "dds_c/dds_c_log.h", "Failed to commit a sample to be made available to be read or taken"}, + {DDSC_LOG_DR_FILTER_ERROR_EC, "DDSC_LOG_DR_FILTER_ERROR_EC", "DDSC", "(DDSC_LOG_BASE + 1003)", "dds_c/dds_c_log.h", "A datareader filter function failed"}, + {DDSC_LOG_DR_DESERIALIZE_KEYHASH_EC, "DDSC_LOG_DR_DESERIALIZE_KEYHASH_EC", "DDSC", "(DDSC_LOG_BASE + 1004)", "dds_c/dds_c_log.h", "Failed to deserialize a key-hash parameter"}, + {DDSC_LOG_DR_GET_ENTRY_FAILED_EC, "DDSC_LOG_DR_GET_ENTRY_FAILED_EC", "DDSC", "(DDSC_LOG_BASE + 1005)", "dds_c/dds_c_log.h", "Failed to get a Reader History entry for a received sample"}, + {DDSC_LOG_DR_COMMIT_ENTRY_EC, "DDSC_LOG_DR_COMMIT_ENTRY_EC", "DDSC", "(DDSC_LOG_BASE + 1006)", "dds_c/dds_c_log.h", "Failed to commit a receive sample to Reader History to be read or"}, + {DDSC_LOG_DR_UNREGISTER_KEY_EC, "DDSC_LOG_DR_UNREGISTER_KEY_EC", "DDSC", "(DDSC_LOG_BASE + 1007)", "dds_c/dds_c_log.h", "A DataReader failed to unregister an instance"}, + {DDSC_LOG_DR_DISPOSE_KEY_EC, "DDSC_LOG_DR_DISPOSE_KEY_EC", "DDSC", "(DDSC_LOG_BASE + 1008)", "dds_c/dds_c_log.h", "A DataReader failed to dispose an instance"}, + {DDSC_LOG_DR_READ_TAKE_FAILURE_EC, "DDSC_LOG_DR_READ_TAKE_FAILURE_EC", "DDSC", "(DDSC_LOG_BASE + 1009)", "dds_c/dds_c_log.h", "A call to a reader/take function failed"}, + {DDSC_LOG_DR_INSTANCE_TO_KEYHASH_EC, "DDSC_LOG_DR_INSTANCE_TO_KEYHASH_EC", "DDSC", "(DDSC_LOG_BASE + 1010)", "dds_c/dds_c_log.h", "Failed to create keyhash of instance handle"}, + {DDSC_LOG_TYPE_NAME_CMP_EC, "DDSC_LOG_TYPE_NAME_CMP_EC", "DDSC", "(DDSC_LOG_BASE + 1100)", "dds_c/dds_c_log.h", "Two type names are incompatible"}, + {DDSC_LOG_TOPIC_NAME_CMP_EC, "DDSC_LOG_TOPIC_NAME_CMP_EC", "DDSC", "(DDSC_LOG_BASE + 1101)", "dds_c/dds_c_log.h", "Two topic names are incompatible"}, + {DDSC_LOG_TYPE_FUNCTION_NULL_EC, "DDSC_LOG_TYPE_FUNCTION_NULL_EC", "DDSC", "(DDSC_LOG_BASE + 1102)", "dds_c/dds_c_log.h", "Invalid type plugin, The specified function pointer is NULL"}, + {DDSC_LOG_TOPIC_TOO_LONG_EC, "DDSC_LOG_TOPIC_TOO_LONG_EC", "DDSC", "(DDSC_LOG_BASE + 1103)", "dds_c/dds_c_log.h", "Failed to create a topic because the name exceeded the maximum"}, + {DDSC_LOG_TYPE_TOO_LONG_EC, "DDSC_LOG_TYPE_TOO_LONG_EC", "DDSC", "(DDSC_LOG_BASE + 1104)", "dds_c/dds_c_log.h", "Failed to create a type because the name exceeded the maximum"}, + {DDSC_LOG_LOOKUP_TYPE_PLUGIN_EC, "DDSC_LOG_LOOKUP_TYPE_PLUGIN_EC", "DDSC", "(DDSC_LOG_BASE + 1105)", "dds_c/dds_c_log.h", "A type-plugin for the given type could not be found"}, + {DDSC_LOG_DISC_LOCAL_PARTICIPANT_ENABLED_EC, "DDSC_LOG_DISC_LOCAL_PARTICIPANT_ENABLED_EC", "DDSC", "(DDSC_LOG_BASE + 1200)", "dds_c/dds_c_log.h", "Discovery plugin failed its update after a local DomainParticipant"}, + {DDSC_LOG_DISC_BEFORE_LOCAL_PARTICIPANT_CREATED_EC, "DDSC_LOG_DISC_BEFORE_LOCAL_PARTICIPANT_CREATED_EC", "DDSC", "(DDSC_LOG_BASE + 1201)", "dds_c/dds_c_log.h", "Discovery plugin failed its update before a local DomainParticipant"}, + {DDSC_LOG_DISC_AFTER_LOCAL_PARTICIPANT_CREATED_EC, "DDSC_LOG_DISC_AFTER_LOCAL_PARTICIPANT_CREATED_EC", "DDSC", "(DDSC_LOG_BASE + 1202)", "dds_c/dds_c_log.h", "Discovery plugin failed its update after a local DomainParticipant"}, + {DDSC_LOG_DISC_AFTER_LOCAL_DATAREADER_ENABLED_EC, "DDSC_LOG_DISC_AFTER_LOCAL_DATAREADER_ENABLED_EC", "DDSC", "(DDSC_LOG_BASE + 1203)", "dds_c/dds_c_log.h", "Discovery plugin failed its update after a local DataReader"}, + {DDSC_LOG_DISC_AFTER_LOCAL_DATAREADER_DELETED_EC, "DDSC_LOG_DISC_AFTER_LOCAL_DATAREADER_DELETED_EC", "DDSC", "(DDSC_LOG_BASE + 1204)", "dds_c/dds_c_log.h", "Discovery plugin failed its update after a local DataReader"}, + {DDSC_LOG_DISC_AFTER_LOCAL_DATAWRITER_ENABLED_EC, "DDSC_LOG_DISC_AFTER_LOCAL_DATAWRITER_ENABLED_EC", "DDSC", "(DDSC_LOG_BASE + 1205)", "dds_c/dds_c_log.h", "Discovery plugin failed its update after a local DataWriter"}, + {DDSC_LOG_DISC_AFTER_LOCAL_DATAWRITER_DELETED_EC, "DDSC_LOG_DISC_AFTER_LOCAL_DATAWRITER_DELETED_EC", "DDSC", "(DDSC_LOG_BASE + 1206)", "dds_c/dds_c_log.h", "Discovery plugin failed its update after a local DataWriter"}, + {DDSC_LOG_DISC_REMOTE_PARTICIPANT_EXPIRED_EC, "DDSC_LOG_DISC_REMOTE_PARTICIPANT_EXPIRED_EC", "DDSC", "(DDSC_LOG_BASE + 1207)", "dds_c/dds_c_log.h", "Discovery plugin failed its update after a remote DomainParticipant's"}, + {DDSC_LOG_DISC_ADD_PEER_EC, "DDSC_LOG_DISC_ADD_PEER_EC", "DDSC", "(DDSC_LOG_BASE + 1208)", "dds_c/dds_c_log.h", "Failed to add a peer with discovery plugin"}, + {DPDE_LOG_CDR_SET_OFFSET_EC, "DPDE_LOG_CDR_SET_OFFSET_EC", "DPDE", "(DPDE_LOG_BASE + 1)", "disc_dpde/disc_dpde_log.h", "Failed to set current offset of stream"}, + {DPDE_LOG_SERIALIZE_ENTITY_NAME_EC, "DPDE_LOG_SERIALIZE_ENTITY_NAME_EC", "DPDE", "(DPDE_LOG_BASE + 2)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Entity Name parameter"}, + {DPDE_LOG_SERIALIZE_TOPIC_NAME_EC, "DPDE_LOG_SERIALIZE_TOPIC_NAME_EC", "DPDE", "(DPDE_LOG_BASE + 3)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Topic Name parameter"}, + {DPDE_LOG_SERIALIZE_TYPE_NAME_EC, "DPDE_LOG_SERIALIZE_TYPE_NAME_EC", "DPDE", "(DPDE_LOG_BASE + 4)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Type Name parameter"}, + {DPDE_LOG_SERIALIZE_GUID_EC, "DPDE_LOG_SERIALIZE_GUID_EC", "DPDE", "(DPDE_LOG_BASE + 5)", "disc_dpde/disc_dpde_log.h", "Failed to serialize GUID key"}, + {DPDE_LOG_SERIALIZE_DEFAULT_UNICAST_EC, "DPDE_LOG_SERIALIZE_DEFAULT_UNICAST_EC", "DPDE", "(DPDE_LOG_BASE + 6)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Default Unicast Locator parameter"}, + {DPDE_LOG_SERIALIZE_PROTOCOL_VERSION_EC, "DPDE_LOG_SERIALIZE_PROTOCOL_VERSION_EC", "DPDE", "(DPDE_LOG_BASE + 7)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Protocol Version parameter"}, + {DPDE_LOG_DESERIALIZE_PROTOCOL_VERSION_EC, "DPDE_LOG_DESERIALIZE_PROTOCOL_VERSION_EC", "DPDE", "(DPDE_LOG_BASE + 8)", "disc_dpde/disc_dpde_log.h", "Failed to deserialize Protocol Version parameter"}, + {DPDE_LOG_DESERIALIZE_VENDOR_ID_EC, "DPDE_LOG_DESERIALIZE_VENDOR_ID_EC", "DPDE", "(DPDE_LOG_BASE + 9)", "disc_dpde/disc_dpde_log.h", "Failed to deserialize Vendor ID parameter"}, + {DPDE_LOG_SERIALIZE_VENDOR_ID_EC, "DPDE_LOG_SERIALIZE_VENDOR_ID_EC", "DPDE", "(DPDE_LOG_BASE + 10)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Vendor ID parameter"}, + {DPDE_LOG_SERIALIZE_PRODUCT_VERSION_EC, "DPDE_LOG_SERIALIZE_PRODUCT_VERSION_EC", "DPDE", "(DPDE_LOG_BASE + 11)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Product Version parameter"}, + {DPDE_LOG_SERIALIZE_LEASE_DURATION_EC, "DPDE_LOG_SERIALIZE_LEASE_DURATION_EC", "DPDE", "(DPDE_LOG_BASE + 12)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Lease Duration parameter"}, + {DPDE_LOG_CREATE_PUBLISHER_EC, "DPDE_LOG_CREATE_PUBLISHER_EC", "DPDE", "(DPDE_LOG_BASE + 13)", "disc_dpde/disc_dpde_log.h", "Failed to create Publisher for built-in endpoint DataWriters"}, + {DPDE_LOG_CREATE_SUBSCRIBER_EC, "DPDE_LOG_CREATE_SUBSCRIBER_EC", "DPDE", "(DPDE_LOG_BASE + 14)", "disc_dpde/disc_dpde_log.h", "Failed to create Subscriber for built-in endpoint DataReaders"}, + {DPDE_LOG_CREATE_PARTICIPANT_DISCOVERY_EC, "DPDE_LOG_CREATE_PARTICIPANT_DISCOVERY_EC", "DPDE", "(DPDE_LOG_BASE + 15)", "disc_dpde/disc_dpde_log.h", "Failed to create built-in endpoint for participant discovery after"}, + {DPDE_LOG_CREATE_PUBLICATION_DISCOVERY_EC, "DPDE_LOG_CREATE_PUBLICATION_DISCOVERY_EC", "DPDE", "(DPDE_LOG_BASE + 16)", "disc_dpde/disc_dpde_log.h", "Failed to create built-in publication endpoint after creating local"}, + {DPDE_LOG_CREATE_SUBSCRIPTION_DISCOVERY_EC, "DPDE_LOG_CREATE_SUBSCRIPTION_DISCOVERY_EC", "DPDE", "(DPDE_LOG_BASE + 17)", "disc_dpde/disc_dpde_log.h", "Failed to create built-in subscription endpoint after creating local"}, + {DPDE_LOG_DELETE_SUBSCRIPTION_TOPIC_EC, "DPDE_LOG_DELETE_SUBSCRIPTION_TOPIC_EC", "DPDE", "(DPDE_LOG_BASE + 18)", "disc_dpde/disc_dpde_log.h", "Failed to delete subscription built-in topic"}, + {DPDE_LOG_DELETE_PUBLICATION_TOPIC_EC, "DPDE_LOG_DELETE_PUBLICATION_TOPIC_EC", "DPDE", "(DPDE_LOG_BASE + 19)", "disc_dpde/disc_dpde_log.h", "Failed to delete publication built-in topic"}, + {DPDE_LOG_DELETE_PARTICIPANT_TOPIC_EC, "DPDE_LOG_DELETE_PARTICIPANT_TOPIC_EC", "DPDE", "(DPDE_LOG_BASE + 20)", "disc_dpde/disc_dpde_log.h", "Failed to delete participant built-in topic"}, + {DPDE_LOG_DISPOSE_PARTICIPANT_EC, "DPDE_LOG_DISPOSE_PARTICIPANT_EC", "DPDE", "(DPDE_LOG_BASE + 21)", "disc_dpde/disc_dpde_log.h", "Failed to dispose built-in participant when"}, + {DPDE_LOG_ALLOCATE_DPDE_EC, "DPDE_LOG_ALLOCATE_DPDE_EC", "DPDE", "(DPDE_LOG_BASE + 22)", "disc_dpde/disc_dpde_log.h", "Out of memory to allocate discovery plugin"}, + {DPDE_LOG_SERIALIZE_BUILTIN_ENDPOINTS_EC, "DPDE_LOG_SERIALIZE_BUILTIN_ENDPOINTS_EC", "DPDE", "(DPDE_LOG_BASE + 23)", "disc_dpde/disc_dpde_log.h", "Failed to serialize Builtin Endpoint Mask parameter"}, + {DPDE_LOG_DESERIALIZE_BUILTIN_ENDPOINTS_EC, "DPDE_LOG_DESERIALIZE_BUILTIN_ENDPOINTS_EC", "DPDE", "(DPDE_LOG_BASE + 24)", "disc_dpde/disc_dpde_log.h", "Failed to deserialize Builtin Endpoint Mask parameter"}, + {DPDE_LOG_DESERIALIZE_UNKNOWN_PID_EC, "DPDE_LOG_DESERIALIZE_UNKNOWN_PID_EC", "DPDE", "(DPDE_LOG_BASE + 25)", "disc_dpde/disc_dpde_log.h", "Deserialized a parameter of unknown ID"}, + {DPDE_LOG_ANNOUNCEMENT_EC, "DPDE_LOG_ANNOUNCEMENT_EC", "DPDE", "(DPDE_LOG_BASE + 26)", "disc_dpde/disc_dpde_log.h", "Failed to write a dynamic participant discovery message"}, + {DPDE_LOG_UPDATE_PARTICIPANT_ASSERT_PERIOD_EC, "DPDE_LOG_UPDATE_PARTICIPANT_ASSERT_PERIOD_EC", "DPDE", "(DPDE_LOG_BASE + 27)", "disc_dpde/disc_dpde_log.h", "Failed to schedule an event to assert the next participant"}, + {DPDE_LOG_ADVANCE_SN_EC, "DPDE_LOG_ADVANCE_SN_EC", "DPDE", "(DPDE_LOG_BASE + 28)", "disc_dpde/disc_dpde_log.h", "Failed to advance the sequence number of a participant discovery"}, + {DPDE_LOG_ANNOUNCE_WRITE_EC, "DPDE_LOG_ANNOUNCE_WRITE_EC", "DPDE", "(DPDE_LOG_BASE + 29)", "disc_dpde/disc_dpde_log.h", "Failed to write initial participant discovery announcement"}, + {DPDE_LOG_SCHEDULE_FAST_ASSERTION_EC, "DPDE_LOG_SCHEDULE_FAST_ASSERTION_EC", "DPDE", "(DPDE_LOG_BASE + 30)", "disc_dpde/disc_dpde_log.h", "Failed to schedule event for asserting participant discovery"}, + {DPDE_LOG_REGISTER_TYPE_EC, "DPDE_LOG_REGISTER_TYPE_EC", "DPDE", "(DPDE_LOG_BASE + 32)", "disc_dpde/disc_dpde_log.h", "Failed to register a built-in type for discovery"}, + {DPDE_LOG_CREATE_TOPIC_EC, "DPDE_LOG_CREATE_TOPIC_EC", "DPDE", "(DPDE_LOG_BASE + 33)", "disc_dpde/disc_dpde_log.h", "Failed to create a topic for discovery"}, + {DPDE_LOG_CREATE_WRITER_EC, "DPDE_LOG_CREATE_WRITER_EC", "DPDE", "(DPDE_LOG_BASE + 34)", "disc_dpde/disc_dpde_log.h", "Failed to create a built-in DataWriter for discovery"}, + {DPDE_LOG_CREATE_READER_EC, "DPDE_LOG_CREATE_READER_EC", "DPDE", "(DPDE_LOG_BASE + 35)", "disc_dpde/disc_dpde_log.h", "Failed to create a built-in DataReader for discovery"}, + {DPDE_LOG_ASSERT_REMOTE_PARTICIPANT_EC, "DPDE_LOG_ASSERT_REMOTE_PARTICIPANT_EC", "DPDE", "(DPDE_LOG_BASE + 36)", "disc_dpde/disc_dpde_log.h", "Failed to assert and complete discovery of a remote participant"}, + {DPDE_LOG_ENABLE_REMOTE_PARTICIPANT_EC, "DPDE_LOG_ENABLE_REMOTE_PARTICIPANT_EC", "DPDE", "(DPDE_LOG_BASE + 37)", "disc_dpde/disc_dpde_log.h", "Failed to enable and complete discovery of a remote participant"}, + {DPDE_LOG_REFRESH_REMOTE_PARTICIPANT_EC, "DPDE_LOG_REFRESH_REMOTE_PARTICIPANT_EC", "DPDE", "(DPDE_LOG_BASE + 38)", "disc_dpde/disc_dpde_log.h", "Failed to refresh liveliness for a discovered remote participant"}, + {DPDE_LOG_TAKE_PARTICIPANT_SAMPLE_EC, "DPDE_LOG_TAKE_PARTICIPANT_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 39)", "disc_dpde/disc_dpde_log.h", "Failed to take a sample from a participant discovery DataReader"}, + {DPDE_LOG_INVALID_PARTICIPANT_SAMPLE_EC, "DPDE_LOG_INVALID_PARTICIPANT_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 40)", "disc_dpde/disc_dpde_log.h", "Received a participant discovery announcement with invalid state"}, + {DPDE_LOG_RETURN_PARTICIPANT_SAMPLE_EC, "DPDE_LOG_RETURN_PARTICIPANT_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 41)", "disc_dpde/disc_dpde_log.h", "Failed to return a loan on a participant discovery sample"}, + {DPDE_LOG_DISPOSE_PUBLICATION_EC, "DPDE_LOG_DISPOSE_PUBLICATION_EC", "DPDE", "(DPDE_LOG_BASE + 42)", "disc_dpde/disc_dpde_log.h", "Failed to dispose an instance for a publication"}, + {DPDE_LOG_DISPOSE_SUBSCRIPTION_EC, "DPDE_LOG_DISPOSE_SUBSCRIPTION_EC", "DPDE", "(DPDE_LOG_BASE + 43)", "disc_dpde/disc_dpde_log.h", "Failed to dispose an instance of a subscription"}, + {DPDE_LOG_ASSERT_REMOTE_PUBLICATION_EC, "DPDE_LOG_ASSERT_REMOTE_PUBLICATION_EC", "DPDE", "(DPDE_LOG_BASE + 44)", "disc_dpde/disc_dpde_log.h", "Failed to assert and complete discovery of a remote publication"}, + {DPDE_LOG_ASSERT_REMOTE_SUBSCRIPTION_EC, "DPDE_LOG_ASSERT_REMOTE_SUBSCRIPTION_EC", "DPDE", "(DPDE_LOG_BASE + 45)", "disc_dpde/disc_dpde_log.h", "Failed to assert and complete discovery of a remote subscription"}, + {DPDE_LOG_TAKE_PUBLICATION_SAMPLE_EC, "DPDE_LOG_TAKE_PUBLICATION_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 46)", "disc_dpde/disc_dpde_log.h", "Failed to take a sample from a publication discovery DataReader"}, + {DPDE_LOG_REMOVE_REMOTE_PUBLICATION_EC, "DPDE_LOG_REMOVE_REMOTE_PUBLICATION_EC", "DPDE", "(DPDE_LOG_BASE + 47)", "disc_dpde/disc_dpde_log.h", "Failed to dispose or unregister a remote publication instance"}, + {DPDE_LOG_INVALID_PUBLICATION_SAMPLE_EC, "DPDE_LOG_INVALID_PUBLICATION_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 48)", "disc_dpde/disc_dpde_log.h", "Received a publication discovery announcement with invalid state"}, + {DPDE_LOG_RETURN_PUBLICATION_SAMPLE_EC, "DPDE_LOG_RETURN_PUBLICATION_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 49)", "disc_dpde/disc_dpde_log.h", "Failed to return a loan on a publication discovery sample"}, + {DPDE_LOG_TAKE_SUBSCRIPTION_SAMPLE_EC, "DPDE_LOG_TAKE_SUBSCRIPTION_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 51)", "disc_dpde/disc_dpde_log.h", "Failed to take a sample from a subscription discovery DataReader"}, + {DPDE_LOG_INVALID_SUBSCRIPTION_SAMPLE_EC, "DPDE_LOG_INVALID_SUBSCRIPTION_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 52)", "disc_dpde/disc_dpde_log.h", "Received a subscription discovery sample with invalid state"}, + {DPDE_LOG_RETURN_SUBSCRIPTION_SAMPLE_EC, "DPDE_LOG_RETURN_SUBSCRIPTION_SAMPLE_EC", "DPDE", "(DPDE_LOG_BASE + 53)", "disc_dpde/disc_dpde_log.h", "Failed to return a loan on a subscription discovery sample"}, + {DPDE_LOG_REMOVE_REMOTE_SUBSCRIPTION_EC, "DPDE_LOG_REMOVE_REMOTE_SUBSCRIPTION_EC", "DPDE", "(DPDE_LOG_BASE + 54)", "disc_dpde/disc_dpde_log.h", "Failed to dispose or unregister a remote subscription instance"}, + {DPDE_LOG_LOCATORS_FULL_EC, "DPDE_LOG_LOCATORS_FULL_EC", "DPDE", "(DPDE_LOG_BASE + 55)", "disc_dpde/disc_dpde_log.h", "A locator sequence is full, the remaining locators of the specified"}, + {DPDE_LOG_DESERIALIZE_LOCATOR_EC, "DPDE_LOG_DESERIALIZE_LOCATOR_EC", "DPDE", "(DPDE_LOG_BASE + 56)", "disc_dpde/disc_dpde_log.h", "Failed to deserialize a locator of the specified kind"}, + {DPDE_LOG_UNSUPPORTED_LOCATOR_EC, "DPDE_LOG_UNSUPPORTED_LOCATOR_EC", "DPDE", "(DPDE_LOG_BASE + 57)", "disc_dpde/disc_dpde_log.h", "The locator kind is not supported by any transport registered with the"}, + {DPDE_LOG_ADD_PEER_EC, "DPDE_LOG_ADD_PEER_EC", "DPDE", "(DPDE_LOG_BASE + 58)", "disc_dpde/disc_dpde_log.h", "Failed to add the specified entity as a peer"}, + {DPDE_LOG_REMOVE_PEER_EC, "DPDE_LOG_REMOVE_PEER_EC", "DPDE", "(DPDE_LOG_BASE + 59)", "disc_dpde/disc_dpde_log.h", "Failed to add the specified entity as a peer"}, + {DPSE_LOG_INVALID_PEER_ADDRESS_EC, "DPSE_LOG_INVALID_PEER_ADDRESS_EC", "DPSE", "(DPSE_LOG_BASE + 1)", "disc_dpse/disc_dpse_log.h", "A peer address string specifies an invalid address"}, + {DPSE_LOG_CREATE_DISCOVERY_PUBLISHER_EC, "DPSE_LOG_CREATE_DISCOVERY_PUBLISHER_EC", "DPSE", "(DPSE_LOG_BASE + 2)", "disc_dpse/disc_dpse_log.h", "Failed to create the publisher for a participant discovery writer"}, + {DPSE_LOG_CREATE_DISCOVERY_SUBSCRIBER_EC, "DPSE_LOG_CREATE_DISCOVERY_SUBSCRIBER_EC", "DPSE", "(DPSE_LOG_BASE + 3)", "disc_dpse/disc_dpse_log.h", "Failed to create the subscriber for a participant discovery datareader"}, + {DPSE_LOG_REGISTER_TYPE_EC, "DPSE_LOG_REGISTER_TYPE_EC", "DPSE", "(DPSE_LOG_BASE + 4)", "disc_dpse/disc_dpse_log.h", "Failed to register a built-in participant discovery type"}, + {DPSE_LOG_CREATE_TOPIC_EC, "DPSE_LOG_CREATE_TOPIC_EC", "DPSE", "(DPSE_LOG_BASE + 5)", "disc_dpse/disc_dpse_log.h", "Failed to create a topic for the built-in participant discovery topic"}, + {DPSE_LOG_CREATE_WRITER_EC, "DPSE_LOG_CREATE_WRITER_EC", "DPSE", "(DPSE_LOG_BASE + 6)", "disc_dpse/disc_dpse_log.h", "Failed to create a DataWriter for participant discovery"}, + {DPSE_LOG_CREATE_READER_EC, "DPSE_LOG_CREATE_READER_EC", "DPSE", "(DPSE_LOG_BASE + 7)", "disc_dpse/disc_dpse_log.h", "Failed to create a DataReader for participant discovery"}, + {DPSE_LOG_DISPOSE_EC, "DPSE_LOG_DISPOSE_EC", "DPSE", "(DPSE_LOG_BASE + 8)", "disc_dpse/disc_dpse_log.h", "Failed to dispose a participant discovery instance"}, + {DPSE_LOG_ANNOUNCE_LOCAL_PARTICIPANT_DELETION_EC, "DPSE_LOG_ANNOUNCE_LOCAL_PARTICIPANT_DELETION_EC", "DPSE", "(DPSE_LOG_BASE + 9)", "disc_dpse/disc_dpse_log.h", "Failed to dispose a participant discovery instance upon deletion"}, + {DPSE_LOG_DELETE_WRITER_EC, "DPSE_LOG_DELETE_WRITER_EC", "DPSE", "(DPSE_LOG_BASE + 10)", "disc_dpse/disc_dpse_log.h", "Failed to delete a participant discovery DataWriter"}, + {DPSE_LOG_DELETE_PUBLISHER_EC, "DPSE_LOG_DELETE_PUBLISHER_EC", "DPSE", "(DPSE_LOG_BASE + 11)", "disc_dpse/disc_dpse_log.h", "Failed to delete a participant discovery Publisher"}, + {DPSE_LOG_DELETE_READER_EC, "DPSE_LOG_DELETE_READER_EC", "DPSE", "(DPSE_LOG_BASE + 12)", "disc_dpse/disc_dpse_log.h", "Failed to delete a participant discovery DataReader"}, + {DPSE_LOG_DELETE_TOPIC_EC, "DPSE_LOG_DELETE_TOPIC_EC", "DPSE", "(DPSE_LOG_BASE + 13)", "disc_dpse/disc_dpse_log.h", "Failed to delete a participant discovery Topic"}, + {DPSE_LOG_DELETE_SUBSCRIBER_EC, "DPSE_LOG_DELETE_SUBSCRIBER_EC", "DPSE", "(DPSE_LOG_BASE + 14)", "disc_dpse/disc_dpse_log.h", "Failed to delete a participant discovery Subscriber"}, + {DPSE_LOG_OBJECT_ALLOCATE_EC, "DPSE_LOG_OBJECT_ALLOCATE_EC", "DPSE", "(DPSE_LOG_BASE + 15)", "disc_dpse/disc_dpse_log.h", "Failed to allocate an object of the specified kind"}, + {DPSE_LOG_OBJECT_INITIALIZE_EC, "DPSE_LOG_OBJECT_INITIALIZE_EC", "DPSE", "(DPSE_LOG_BASE + 16)", "disc_dpse/disc_dpse_log.h", "Failed to initialize an object of the specified kind"}, + {DPSE_LOG_OBJECT_FINALIZE_EC, "DPSE_LOG_OBJECT_FINALIZE_EC", "DPSE", "(DPSE_LOG_BASE + 17)", "disc_dpse/disc_dpse_log.h", "Failed to finalize an object of the specified kind"}, + {DPSE_LOG_OBJECT_DELETE_EC, "DPSE_LOG_OBJECT_DELETE_EC", "DPSE", "(DPSE_LOG_BASE + 18)", "disc_dpse/disc_dpse_log.h", "Failed to delete an object of the specified kind"}, + {DPSE_LOG_OBJECT_INVALID_EC, "DPSE_LOG_OBJECT_INVALID_EC", "DPSE", "(DPSE_LOG_BASE + 19)", "disc_dpse/disc_dpse_log.h", "The object was invalid in the context it was used"}, + {DPSE_LOG_CDR_SET_POSITION_EC, "DPSE_LOG_CDR_SET_POSITION_EC", "DPSE", "(DPSE_LOG_BASE + 20)", "disc_dpse/disc_dpse_log.h", "Failed to set the CDR stream position"}, + {DPSE_LOG_CDR_SERIALIZE_EC, "DPSE_LOG_CDR_SERIALIZE_EC", "DPSE", "(DPSE_LOG_BASE + 21)", "disc_dpse/disc_dpse_log.h", "Failed to serialize the specified kind"}, + {DPSE_LOG_CDR_DESERIALIZE_EC, "DPSE_LOG_CDR_DESERIALIZE_EC", "DPSE", "(DPSE_LOG_BASE + 22)", "disc_dpse/disc_dpse_log.h", "Failed to deserialize the specified kind"}, + {DPSE_LOG_SERIALIZE_GUID_EC, "DPSE_LOG_SERIALIZE_GUID_EC", "DPSE", "(DPSE_LOG_BASE + 23)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a GUID key parameter"}, + {DPSE_LOG_SERIALIZE_BUILTIN_ENDPOINTS_EC, "DPSE_LOG_SERIALIZE_BUILTIN_ENDPOINTS_EC", "DPSE", "(DPSE_LOG_BASE + 24)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Builtin Endpoint Mask parameter"}, + {DPSE_LOG_SERIALIZE_PROTOCOL_VERSION_EC, "DPSE_LOG_SERIALIZE_PROTOCOL_VERSION_EC", "DPSE", "(DPSE_LOG_BASE + 25)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Protocol Version parameter"}, + {DPSE_LOG_SERIALIZE_VENDOR_ID_EC, "DPSE_LOG_SERIALIZE_VENDOR_ID_EC", "DPSE", "(DPSE_LOG_BASE + 26)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Vendor ID parameter"}, + {DPSE_LOG_SERIALIZE_DEFAULT_UNICAST_EC, "DPSE_LOG_SERIALIZE_DEFAULT_UNICAST_EC", "DPSE", "(DPSE_LOG_BASE + 27)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Default Unicast Locator parameter"}, + {DPSE_LOG_SERIALIZE_META_UNICAST_EC, "DPSE_LOG_SERIALIZE_META_UNICAST_EC", "DPSE", "(DPSE_LOG_BASE + 28)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Meta Unicast Locator parameter"}, + {DPSE_LOG_SERIALIZE_META_MULTICAST_EC, "DPSE_LOG_SERIALIZE_META_MULTICAST_EC", "DPSE", "(DPSE_LOG_BASE + 29)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Meta Multicast Locator parameter"}, + {DPSE_LOG_SERIALIZE_LEASE_DURATION_EC, "DPSE_LOG_SERIALIZE_LEASE_DURATION_EC", "DPSE", "(DPSE_LOG_BASE + 30)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Lease Duration parameter"}, + {DPSE_LOG_SERIALIZE_PRODUCT_VERSION_EC, "DPSE_LOG_SERIALIZE_PRODUCT_VERSION_EC", "DPSE", "(DPSE_LOG_BASE + 31)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Product Version parameter"}, + {DPSE_LOG_DESERIALIZE_PRODUCT_VERSION_EC, "DPSE_LOG_DESERIALIZE_PRODUCT_VERSION_EC", "DPSE", "(DPSE_LOG_BASE + 32)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Product Version parameter"}, + {DPSE_LOG_SERIALIZE_PARTICIPANT_NAME_EC, "DPSE_LOG_SERIALIZE_PARTICIPANT_NAME_EC", "DPSE", "(DPSE_LOG_BASE + 33)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Participant Name parameter"}, + {DPSE_LOG_DESERIALIZE_GUID_EC, "DPSE_LOG_DESERIALIZE_GUID_EC", "DPSE", "(DPSE_LOG_BASE + 34)", "disc_dpse/disc_dpse_log.h", "Failed to deserialize a GUID key parameter"}, + {DPSE_LOG_DESERIALIZE_BUILTIN_ENDPOINTS_EC, "DPSE_LOG_DESERIALIZE_BUILTIN_ENDPOINTS_EC", "DPSE", "(DPSE_LOG_BASE + 35)", "disc_dpse/disc_dpse_log.h", "Failed to deserialize a Builtin Endpoint Mask parameter"}, + {DPSE_LOG_DESERIALIZE_PROTOCOL_VERSION_EC, "DPSE_LOG_DESERIALIZE_PROTOCOL_VERSION_EC", "DPSE", "(DPSE_LOG_BASE + 36)", "disc_dpse/disc_dpse_log.h", "Failed to deserialize a Protocol Version parameter"}, + {DPSE_LOG_DESERIALIZE_VENDOR_ID_EC, "DPSE_LOG_DESERIALIZE_VENDOR_ID_EC", "DPSE", "(DPSE_LOG_BASE + 37)", "disc_dpse/disc_dpse_log.h", "Failed to deserialize a Vendor ID parameter"}, + {DPSE_LOG_DESERIALIZE_TOO_MANY_LOCATORS_EC, "DPSE_LOG_DESERIALIZE_TOO_MANY_LOCATORS_EC", "DPSE", "(DPSE_LOG_BASE + 38)", "disc_dpse/disc_dpse_log.h", "Cannot deserialize another locator parameter, having reached maximum"}, + {DPSE_LOG_DESERIALIZE_PARTICIPANT_NAME_EC, "DPSE_LOG_DESERIALIZE_PARTICIPANT_NAME_EC", "DPSE", "(DPSE_LOG_BASE + 39)", "disc_dpse/disc_dpse_log.h", "Failed to deserialize a Participant Name parameter"}, + {DPSE_LOG_DESERIALIZE_UNKNOWN_PID_EC, "DPSE_LOG_DESERIALIZE_UNKNOWN_PID_EC", "DPSE", "(DPSE_LOG_BASE + 40)", "disc_dpse/disc_dpse_log.h", "Failed to deserialize a parameter with an unknown ID"}, + {DPSE_LOG_ANNOUNCEMENT_EC, "DPSE_LOG_ANNOUNCEMENT_EC", "DPSE", "(DPSE_LOG_BASE + 41)", "disc_dpse/disc_dpse_log.h", "Failed to send a participant discovery announcement"}, + {DPSE_LOG_UPDATE_PARTICIPANT_ASSERT_PERIOD_EC, "DPSE_LOG_UPDATE_PARTICIPANT_ASSERT_PERIOD_EC", "DPSE", "(DPSE_LOG_BASE + 42)", "disc_dpse/disc_dpse_log.h", "Failed to schedule an event to send the next participant discovery"}, + {DPSE_LOG_ADVANCE_SN_EC, "DPSE_LOG_ADVANCE_SN_EC", "DPSE", "(DPSE_LOG_BASE + 43)", "disc_dpse/disc_dpse_log.h", "Failed to advance the sequence number of a participant discovery"}, + {DPSE_LOG_ANNOUNCE_WRITE_EC, "DPSE_LOG_ANNOUNCE_WRITE_EC", "DPSE", "(DPSE_LOG_BASE + 44)", "disc_dpse/disc_dpse_log.h", "Failed to write a participant discovery announcement message"}, + {DPSE_LOG_SCHEDULE_FAST_ASSERTION_EC, "DPSE_LOG_SCHEDULE_FAST_ASSERTION_EC", "DPSE", "(DPSE_LOG_BASE + 45)", "disc_dpse/disc_dpse_log.h", "Failed to schedule an event to send the next participant discovery"}, + {DPSE_LOG_PARTICIPANT_TAKE_EC, "DPSE_LOG_PARTICIPANT_TAKE_EC", "DPSE", "(DPSE_LOG_BASE + 46)", "disc_dpse/disc_dpse_log.h", "Failed to take a sample from a participant discovery DataReader"}, + {DPSE_LOG_ASSERT_REMOTE_PARTICIPANT_EC, "DPSE_LOG_ASSERT_REMOTE_PARTICIPANT_EC", "DPSE", "(DPSE_LOG_BASE + 47)", "disc_dpse/disc_dpse_log.h", "Failed to assert remote participant"}, + {DPSE_LOG_ON_ASSERT_REMOTE_PARTICIPANT_EC, "DPSE_LOG_ON_ASSERT_REMOTE_PARTICIPANT_EC", "DPSE", "(DPSE_LOG_BASE + 48)", "disc_dpse/disc_dpse_log.h", "Failed to assert and complete discovery of a remote participant"}, + {DPSE_LOG_ADD_ANONYMOUS_ROUTE_EC, "DPSE_LOG_ADD_ANONYMOUS_ROUTE_EC", "DPSE", "(DPSE_LOG_BASE + 49)", "disc_dpse/disc_dpse_log.h", "Failed to add an anonymous route"}, + {DPSE_LOG_DELETE_ANONYMOUS_ROUTE_EC, "DPSE_LOG_DELETE_ANONYMOUS_ROUTE_EC", "DPSE", "(DPSE_LOG_BASE + 50)", "disc_dpse/disc_dpse_log.h", "Failed to delete an anonymous route"}, + {DPSE_LOG_MAX_REMOTE_PARTICIPANT_EC, "DPSE_LOG_MAX_REMOTE_PARTICIPANT_EC", "DPSE", "(DPSE_LOG_BASE + 51)", "disc_dpse/disc_dpse_log.h", "Exceeded resource limit, remote_participant_allocation"}, + {DPSE_LOG_REFRESH_REMOTE_PARTICIPANT_EC, "DPSE_LOG_REFRESH_REMOTE_PARTICIPANT_EC", "DPSE", "(DPSE_LOG_BASE + 52)", "disc_dpse/disc_dpse_log.h", "Failed to refresh liveliness for a remote participant"}, + {DPSE_LOG_RESET_REMOTE_PARTICIPANT_EC, "DPSE_LOG_RESET_REMOTE_PARTICIPANT_EC", "DPSE", "(DPSE_LOG_BASE + 53)", "disc_dpse/disc_dpse_log.h", "Failed to reset liveliness for a remote participant"}, + {DPSE_LOG_INVALID_DISCOVERY_SAMPLE_EC, "DPSE_LOG_INVALID_DISCOVERY_SAMPLE_EC", "DPSE", "(DPSE_LOG_BASE + 54)", "disc_dpse/disc_dpse_log.h", "Received a participant discovery announcement with invalid state"}, + {DPSE_LOG_RETURN_DISCOVERY_SAMPLE_EC, "DPSE_LOG_RETURN_DISCOVERY_SAMPLE_EC", "DPSE", "(DPSE_LOG_BASE + 55)", "disc_dpse/disc_dpse_log.h", "Failed to return a loan on a participant discovery announcement"}, + {DPSE_LOG_SERIALIZE_MULTICAST_EC, "DPSE_LOG_SERIALIZE_MULTICAST_EC", "DPSE", "(DPSE_LOG_BASE + 56)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Multicast Locator parameter"}, + {DPSE_LOG_GET_DDS_PROPERTIES_EC, "DPSE_LOG_GET_DDS_PROPERTIES_EC", "DPSE", "(DPSE_LOG_BASE + 57)", "disc_dpse/disc_dpse_log.h", "Failed to serialize a Multicast Locator parameter"}, + {DPSE_LOG_ENTITY_ENABLE_EC, "DPSE_LOG_ENTITY_ENABLE_EC", "DPSE", "(DPSE_LOG_BASE + 58)", "disc_dpse/disc_dpse_log.h", "Failed to enable the specified entity kind"}, + {DPSE_LOG_SEQUENCE_SETMAX_EC, "DPSE_LOG_SEQUENCE_SETMAX_EC", "DPSE", "(DPSE_LOG_BASE + 59)", "disc_dpse/disc_dpse_log.h", "Failed to set the maximum length of a sequence of the specified kind."}, + {DPSE_LOG_SEQUENCE_SETLENGTH_EC, "DPSE_LOG_SEQUENCE_SETLENGTH_EC", "DPSE", "(DPSE_LOG_BASE + 60)", "disc_dpse/disc_dpse_log.h", "Failed to set the length of a sequence of the specified kind."}, + {DPSE_LOG_SEQUENCE_GETREF_EC, "DPSE_LOG_SEQUENCE_GETREF_EC", "DPSE", "(DPSE_LOG_BASE + 61)", "disc_dpse/disc_dpse_log.h", "Failed to get a reference at the specified index for a sequence of"}, + {DPSE_LOG_SEQUENCE_INITIALIZE_EC, "DPSE_LOG_SEQUENCE_INITIALIZE_EC", "DPSE", "(DPSE_LOG_BASE + 62)", "disc_dpse/disc_dpse_log.h", "Failed to initialize a sequence of the specified kind."}, + {DPSE_LOG_SEQUENCE_FINALIZE_EC, "DPSE_LOG_SEQUENCE_FINALIZE_EC", "DPSE", "(DPSE_LOG_BASE + 63)", "disc_dpse/disc_dpse_log.h", "Failed to finalize a sequence of the specified kind."}, + {DPSE_LOG_SEQUENCE_COPY_EC, "DPSE_LOG_SEQUENCE_COPY_EC", "DPSE", "(DDSC_LOG_BASE + 64)", "disc_dpse/disc_dpse_log.h", "Failed to copy a sequence of the specified kind."}, + {DPSE_LOG_GET_TIMER_EC, "DPSE_LOG_GET_TIMER_EC", "DPSE", "(DDSC_LOG_BASE + 65)", "disc_dpse/disc_dpse_log.h", "Failed to copy a sequence of the specified kind."}, + {DPSE_LOG_UNSUPPORTED_LOCATOR_EC, "DPSE_LOG_UNSUPPORTED_LOCATOR_EC", "DPSE", "(DPDE_LOG_BASE + 66)", "disc_dpse/disc_dpse_log.h", "The locator kind is not supported by any transport registered with the"}, + {NETIO_LOG_GETHOST_BYNAME_EC, "NETIO_LOG_GETHOST_BYNAME_EC", "NETIO", "(NETIO_LOG_BASE + 1)", "netio/netio_log.h", "Failed to get host address from a string representation"}, + {NETIO_LOG_BIND_NEW_EC, "NETIO_LOG_BIND_NEW_EC", "NETIO", "(NETIO_LOG_BASE + 2)", "netio/netio_log.h", "Failed to allocate memory for a bind-resolver"}, + {NETIO_LOG_BIND_NEW_RTABLE_EC, "NETIO_LOG_BIND_NEW_RTABLE_EC", "NETIO", "(NETIO_LOG_BASE + 3)", "netio/netio_log.h", "Failed to create a database table for routes of a bind-resolver"}, + {NETIO_LOG_BIND_CREATE_RTABLE_EC, "NETIO_LOG_BIND_CREATE_RTABLE_EC", "NETIO", "(NETIO_LOG_BASE + 4)", "netio/netio_log.h", "Failed to create route record."}, + {NETIO_LOG_BIND_DELETE_RTABLE_EC, "NETIO_LOG_BIND_DELETE_RTABLE_EC", "NETIO", "(NETIO_LOG_BASE + 5)", "netio/netio_log.h", "Failed to delete a database table for routes of a bind_resolver"}, + {NETIO_LOG_BIND_SET_LENGTH_EC, "NETIO_LOG_BIND_SET_LENGTH_EC", "NETIO", "(NETIO_LOG_BASE + 6)", "netio/netio_log.h", "Failed to set the length for a sequence of resolved addresses"}, + {NETIO_LOG_BIND_SET_MAX_EC, "NETIO_LOG_BIND_SET_MAX_EC", "NETIO", "(NETIO_LOG_BASE + 7)", "netio/netio_log.h", "Failed to set the maximum length of an internal sequence of addresses"}, + {NETIO_LOG_BIND_EXTERNAL_FAILED_EC, "NETIO_LOG_BIND_EXTERNAL_FAILED_EC", "NETIO", "(NETIO_LOG_BASE + 8)", "netio/netio_log.h", "An interface failed on bind_external"}, + {NETIO_LOG_UNBIND_EXTERNAL_FAILED_EC, "NETIO_LOG_UNBIND_EXTERNAL_FAILED_EC", "NETIO", "(NETIO_LOG_BASE + 10)", "netio/netio_log.h", "An interface failed on unbind_external"}, + {NETIO_LOG_ROUTE_RTABLE_ALLOC_EC, "NETIO_LOG_ROUTE_RTABLE_ALLOC_EC", "NETIO", "(NETIO_LOG_BASE + 11)", "netio/netio_log.h", "Failed to allocate memory for a route resolver"}, + {NETIO_LOG_ROUTE_RTABLE_CREATE_EC, "NETIO_LOG_ROUTE_RTABLE_CREATE_EC", "NETIO", "(NETIO_LOG_BASE + 12)", "netio/netio_log.h", "Failed to create a database table for routes of a route-resolver"}, + {NETIO_LOG_ROUTE_RTABLE_DELETE_EC, "NETIO_LOG_ROUTE_RTABLE_DELETE_EC", "NETIO", "(NETIO_LOG_BASE + 13)", "netio/netio_log.h", "Failed to delete a database table for routes of a route-resolver"}, + {NETIO_LOG_ROUTE_RTABLE_ADD_EC, "NETIO_LOG_ROUTE_RTABLE_ADD_EC", "NETIO", "(NETIO_LOG_BASE + 14)", "netio/netio_log.h", "Failed to create route resolver record."}, + {NETIO_LOG_ROUTE_RTABLE_UPDATE_EC, "NETIO_LOG_ROUTE_RTABLE_UPDATE_EC", "NETIO", "(NETIO_LOG_BASE + 15)", "netio/netio_log.h", "Failed to find routes to update for a route-resolver"}, + {NETIO_LOG_AR_ALLOC_FAILED_EC, "NETIO_LOG_AR_ALLOC_FAILED_EC", "NETIO", "(NETIO_LOG_BASE + 16)", "netio/netio_log.h", "Failed to allocate memory for address resolver"}, + {NETIO_LOG_AR_ADD_INVALID_INTERFACE_EC, "NETIO_LOG_AR_ADD_INVALID_INTERFACE_EC", "NETIO", "(NETIO_LOG_BASE + 17)", "netio/netio_log.h", "An attempt was made to add an existing interface with a different"}, + {NETIO_LOG_AR_ADDRESS_RESOLVE_FAILED_EC, "NETIO_LOG_AR_ADDRESS_RESOLVE_FAILED_EC", "NETIO", "(NETIO_LOG_BASE + 18)", "netio/netio_log.h", "An interface failed to resolve an address."}, + {NETIO_LOG_AR_PORT_RESOLVE_FAILED_EC, "NETIO_LOG_AR_PORT_RESOLVE_FAILED_EC", "NETIO", "(NETIO_LOG_BASE + 19)", "netio/netio_log.h", "An interface failed to resolve a port."}, + {NETIO_LOG_AR_CONTEXT_UNINITIALIZED_EC, "NETIO_LOG_AR_CONTEXT_UNINITIALIZED_EC", "NETIO", "(NETIO_LOG_BASE + 21)", "netio/netio_log.h", "NETIO_AddressResolver_resolve/get_next was called with an"}, + {NETIO_LOG_AR_INVALID_TOKEN_EC, "NETIO_LOG_AR_INVALID_TOKEN_EC", "NETIO", "(NETIO_LOG_BASE + 22)", "netio/netio_log.h", "An invalid token was encountered in the address string"}, + {NETIO_LOG_AR_ADDRESS_STRING_EXCEEDED_EC, "NETIO_LOG_AR_ADDRESS_STRING_EXCEEDED_EC", "NETIO", "(NETIO_LOG_BASE + 23)", "netio/netio_log.h", "The length of the address exceeded the address buffer passed in"}, + {NETIO_LOG_INVALID_ADDRESS_INDEX_EC, "NETIO_LOG_INVALID_ADDRESS_INDEX_EC", "NETIO", "(NETIO_LOG_BASE + 24)", "netio/netio_log.h", "An address index was not parsed correctly"}, + {NETIO_LOG_ILLEGAL_ROUTE_OPERATION_EC, "NETIO_LOG_ILLEGAL_ROUTE_OPERATION_EC", "NETIO", "(NETIO_LOG_BASE + 25)", "netio/netio_log.h", "Illegal route operation attempted"}, + {NETIO_LOG_SET_NAME_EC, "NETIO_LOG_SET_NAME_EC", "NETIO", "(UDP_LOG_BASE + 26)", "netio/netio_log.h", "Failed to set the name of a runtime component interface"}, + {NETIO_LOG_PACKET_SET_HEAD_EC, "NETIO_LOG_PACKET_SET_HEAD_EC", "NETIO", "(UDP_LOG_BASE + 27)", "netio/netio_log.h", "Failed to set packet's head"}, + {NETIO_LOG_PACKET_SET_TAIL_EC, "NETIO_LOG_PACKET_SET_TAIL_EC", "NETIO", "(UDP_LOG_BASE + 28)", "netio/netio_log.h", "Failed to set packet's tail"}, + {NETIO_LOG_PACKET_INITIALIZE_EC, "NETIO_LOG_PACKET_INITIALIZE_EC", "NETIO", "(UDP_LOG_BASE + 29)", "netio/netio_log.h", "Failed to initialize packet"}, + {NETIO_LOG_LOOP_DELETE_TABLE_EC, "NETIO_LOG_LOOP_DELETE_TABLE_EC", "NETIO", "(NETIO_LOG_BASE + 100)", "netio/netio_log.h", "Failed to delete a database table for a NETIO loopback interface"}, + {NETIO_LOG_LOOP_CREATE_TABLE_EC, "NETIO_LOG_LOOP_CREATE_TABLE_EC", "NETIO", "(NETIO_LOG_BASE + 101)", "netio/netio_log.h", "Failed to create a database table for a NETIO loopback interface"}, + {NETIO_LOG_LOOP_SELECT_TABLE_EC, "NETIO_LOG_LOOP_SELECT_TABLE_EC", "NETIO", "(NETIO_LOG_BASE + 102)", "netio/netio_log.h", "Failed to select a valid record when sending with the NETIO loopback"}, + {NETIO_LOG_LOOP_FWD_EC, "NETIO_LOG_LOOP_FWD_EC", "NETIO", "(NETIO_LOG_BASE + 103)", "netio/netio_log.h", "Failed to send forward with the NETIO loopback interface"}, + {NETIO_LOG_LOOP_BINDX_DB_EC, "NETIO_LOG_LOOP_BINDX_DB_EC", "NETIO", "(NETIO_LOG_BASE + 104)", "netio/netio_log.h", "Failed to bind an external interface with the NETIO loopback interface"}, + {NETIO_LOG_LOOP_UNBINDX_DB_EC, "NETIO_LOG_LOOP_UNBINDX_DB_EC", "NETIO", "(NETIO_LOG_BASE + 105)", "netio/netio_log.h", "Failed to unbind an external interface with the NETIO loopback"}, + {NETIO_LOG_LOOP_SET_LENGTH_EC, "NETIO_LOG_LOOP_SET_LENGTH_EC", "NETIO", "(NETIO_LOG_BASE + 106)", "netio/netio_log.h", "Failed to set the length of an address sequence"}, + {NETIO_LOG_LOOP_INVALID_PROPERTY_EC, "NETIO_LOG_LOOP_INVALID_PROPERTY_EC", "NETIO", "(NETIO_LOG_BASE + 107)", "netio/netio_log.h", "Invalid property passed in when creating a loopback interface"}, + {NETIO_LOG_LOOP_INITIALIZE_FAILED_EC, "NETIO_LOG_LOOP_INITIALIZE_FAILED_EC", "NETIO", "(NETIO_LOG_BASE + 108)", "netio/netio_log.h", "Failed to initialize the loopback interface"}, + {NETIO_LOG_LOOP_CURSOR_ERROR_EC, "NETIO_LOG_LOOP_CURSOR_ERROR_EC", "NETIO", "(NETIO_LOG_BASE + 109)", "netio/netio_log.h", "An error occurred with a cursor while iterating over a table"}, + {NETIO_LOG_LOOP_INVALID_FACTORY_EC, "NETIO_LOG_LOOP_INVALID_FACTORY_EC", "NETIO", "(NETIO_LOG_BASE + 110)", "netio/netio_log.h", "An invalid factory was passed in to create a loopback interface"}, + {NETIO_LOG_LOOP_INVALID_COMPONENT_EC, "NETIO_LOG_LOOP_INVALID_COMPONENT_EC", "NETIO", "(NETIO_LOG_BASE + 111)", "netio/netio_log.h", "An invalid component was passed in to delete a loopback interface"}, + {UDP_LOG_SOCKET_INIT_EC, "UDP_LOG_SOCKET_INIT_EC", "UDP", "(UDP_LOG_BASE + 200)", "netio/netio_log.h", "Failed to initialize use of sockets"}, + {UDP_LOG_GETHOSTNAME_EC, "UDP_LOG_GETHOSTNAME_EC", "UDP", "(UDP_LOG_BASE + 201)", "netio/netio_log.h", "Failed to get the host address given the host name"}, + {UDP_LOG_SOCKET_SET_MCAST_EC, "UDP_LOG_SOCKET_SET_MCAST_EC", "UDP", "(UDP_LOG_BASE + 202)", "netio/netio_log.h", "Failed to set a socket for multicast loopback"}, + {UDP_LOG_SOCKET_SET_MCASTIF_EC, "UDP_LOG_SOCKET_SET_MCASTIF_EC", "UDP", "(UDP_LOG_BASE + 203)", "netio/netio_log.h", "Failed to set a socket for multicast bound to a specific interface"}, + {UDP_LOG_SOCKET_CREATE_EC, "UDP_LOG_SOCKET_CREATE_EC", "UDP", "(UDP_LOG_BASE + 204)", "netio/netio_log.h", "Failed to create a new socket, the sysrc code is the OS return"}, + {UDP_LOG_SOCKET_SETFD_EC, "UDP_LOG_SOCKET_SETFD_EC", "UDP", "(UDP_LOG_BASE + 205)", "netio/netio_log.h", "Failed to set the close-on-exec flag for a socket"}, + {UDP_LOG_SOCKET_SNDBUF_EC, "UDP_LOG_SOCKET_SNDBUF_EC", "UDP", "(UDP_LOG_BASE + 206)", "netio/netio_log.h", "Failed to set the socket send buffer size"}, + {UDP_LOG_SOCKET_TTL_EC, "UDP_LOG_SOCKET_TTL_EC", "UDP", "(UDP_LOG_BASE + 207)", "netio/netio_log.h", "Failed to set multicast TTL for a socket"}, + {UDP_LOG_PACKET_INIT_EC, "UDP_LOG_PACKET_INIT_EC", "UDP", "(UDP_LOG_BASE + 208)", "netio/netio_log.h", "Failed to initialize a receive packet"}, + {UDP_LOG_PACKET_HEAD_EC, "UDP_LOG_PACKET_HEAD_EC", "UDP", "(UDP_LOG_BASE + 209)", "netio/netio_log.h", "Failed to set the head of a receive packet"}, + {UDP_LOG_PACKET_FWD_EC, "UDP_LOG_PACKET_FWD_EC", "UDP", "(UDP_LOG_BASE + 210)", "netio/netio_log.h", "Failed reception upstream for a received packet"}, + {UDP_LOG_NAT_DELETE_EC, "UDP_LOG_NAT_DELETE_EC", "UDP", "(UDP_LOG_BASE + 211)", "netio/netio_log.h", "Failed to delete a database record or index from an internal NAT"}, + {UDP_LOG_FINALIZE_EC, "UDP_LOG_FINALIZE_EC", "UDP", "(UDP_LOG_BASE + 212)", "netio/netio_log.h", "Failed to finalize the parent NETIO interface"}, + {UDP_LOG_SOCKET_REUSE_PORT_EC, "UDP_LOG_SOCKET_REUSE_PORT_EC", "UDP", "(UDP_LOG_BASE + 213)", "netio/netio_log.h", "Failed to set socket to reuse a port or address"}, + {UDP_LOG_SOCKET_BIND_EC, "UDP_LOG_SOCKET_BIND_EC", "UDP", "(UDP_LOG_BASE + 214)", "netio/netio_log.h", "Failed a socket bind"}, + {UDP_LOG_SOCKET_ADDGRP_EC, "UDP_LOG_SOCKET_ADDGRP_EC", "UDP", "(UDP_LOG_BASE + 215)", "netio/netio_log.h", "Failed to add membership to a multicast group for a socket"}, + {UDP_LOG_PORT_ENTRY_EC, "UDP_LOG_PORT_ENTRY_EC", "UDP", "(UDP_LOG_BASE + 216)", "netio/netio_log.h", "Failed to create a bind entry for a receive port"}, + {UDP_LOG_PORT_ALLOC_EC, "UDP_LOG_PORT_ALLOC_EC", "UDP", "(UDP_LOG_BASE + 217)", "netio/netio_log.h", "Failed to allocate memory for a receive buffer of a specific port"}, + {UDP_LOG_SOCKET_RXBUF_EC, "UDP_LOG_SOCKET_RXBUF_EC", "UDP", "(UDP_LOG_BASE + 218)", "netio/netio_log.h", "Failed to set the receive buffer size of a socket"}, + {UDP_LOG_PORT_ADD_EC, "UDP_LOG_PORT_ADD_EC", "UDP", "(UDP_LOG_BASE + 219)", "netio/netio_log.h", "Failed to add a port entry record to a database table"}, + {UDP_LOG_PORT_THREAD_EC, "UDP_LOG_PORT_THREAD_EC", "UDP", "(UDP_LOG_BASE + 220)", "netio/netio_log.h", "Failed to create a receive thread for a receive port"}, + {UDP_LOG_SOCKET_IFLIST_EC, "UDP_LOG_SOCKET_IFLIST_EC", "UDP", "(UDP_LOG_BASE + 221)", "netio/netio_log.h", "Failed to get a list of interface addresses"}, + {UDP_LOG_SOCKET_IFFLAGS_EC, "UDP_LOG_SOCKET_IFFLAGS_EC", "UDP", "(UDP_LOG_BASE + 222)", "netio/netio_log.h", "Failed to get the network interface flags or mask of a socket"}, + {UDP_LOG_SOCKET_CLOSE_EC, "UDP_LOG_SOCKET_CLOSE_EC", "UDP", "(UDP_LOG_BASE + 223)", "netio/netio_log.h", "Failed to close a socket"}, + {UDP_LOG_LOADLIB_EC, "UDP_LOG_LOADLIB_EC", "UDP", "(UDP_LOG_BASE + 224)", "netio/netio_log.h", "Failed to load a dynamic library"}, + {UDP_LOG_GET_BUF_SIZE_EC, "UDP_LOG_GET_BUF_SIZE_EC", "UDP", "(UDP_LOG_BASE + 225)", "netio/netio_log.h", "Failed to get interface buffer size"}, + {UDP_LOG_GET_BUF_ALLOC_EC, "UDP_LOG_GET_BUF_ALLOC_EC", "UDP", "(UDP_LOG_BASE + 226)", "netio/netio_log.h", "Out of memory to allocate interface buffer"}, + {UDP_LOG_GET_IFLIST_EC, "UDP_LOG_GET_IFLIST_EC", "UDP", "(UDP_LOG_BASE + 227)", "netio/netio_log.h", "Failed to get an interface list"}, + {UDP_LOG_GET_NAMEINFO_EC, "UDP_LOG_GET_NAMEINFO_EC", "UDP", "(UDP_LOG_BASE + 228)", "netio/netio_log.h", "Failed getnameinfo()"}, + {UDP_LOG_MULTICAST_ENABLE_EC, "UDP_LOG_MULTICAST_ENABLE_EC", "UDP", "(UDP_LOG_BASE + 229)", "netio/netio_log.h", "Failed to enable multicast loopback"}, + {UDP_LOG_UDP_CREATE_TABLE_EC, "UDP_LOG_UDP_CREATE_TABLE_EC", "UDP", "(UDP_LOG_BASE + 230)", "netio/netio_log.h", "Failed to create a database table for a UDP interface"}, + {UDP_LOG_UDP_CREATE_INDEX_EC, "UDP_LOG_UDP_CREATE_INDEX_EC", "UDP", "(UDP_LOG_BASE + 231)", "netio/netio_log.h", "Failed to create an index for a UDP interface"}, + {UDP_LOG_RECORD_EC, "UDP_LOG_RECORD_EC", "UDP", "(UDP_LOG_BASE + 232)", "netio/netio_log.h", "Failed to create or insert a database record for a UDP interface"}, + {UDP_LOG_PROPERTY_FINALIZE_EC, "UDP_LOG_PROPERTY_FINALIZE_EC", "UDP", "(UDP_LOG_BASE + 233)", "netio/netio_log.h", "Failed to finalize UDP interface factory property"}, + {UDP_LOG_ALLOC_EC, "UDP_LOG_ALLOC_EC", "UDP", "(UDP_LOG_BASE + 234)", "netio/netio_log.h", "Failed to allocate memory for a UDP interface"}, + {UDP_LOG_SEND_PING_EC, "UDP_LOG_SEND_PING_EC", "UDP", "(UDP_LOG_BASE + 235)", "netio/netio_log.h", "Failed sending a ping message, upon adding a route or waking up a"}, + {UDP_LOG_DROPGRP_EC, "UDP_LOG_DROPGRP_EC", "UDP", "(UDP_LOG_BASE + 236)", "netio/netio_log.h", "Failed to drop membership from a multicast group"}, + {UDP_LOG_GET_LENGTH_EC, "UDP_LOG_GET_LENGTH_EC", "UDP", "(UDP_LOG_BASE + 237)", "netio/netio_log.h", "Length of address sequence exceeds its maximum"}, + {UDP_LOG_SET_LENGTH_EC, "UDP_LOG_SET_LENGTH_EC", "UDP", "(UDP_LOG_BASE + 240)", "netio/netio_log.h", "Failed to set the length of an address sequence"}, + {UDP_LOG_WSA_STARTUP_EC, "UDP_LOG_WSA_STARTUP_EC", "UDP", "(UDP_LOG_BASE + 241)", "netio/netio_log.h", "Failed WSAStartup()"}, + {UDP_LOG_WINSOCK_INCOMPATIBLE_EC, "UDP_LOG_WINSOCK_INCOMPATIBLE_EC", "UDP", "(UDP_LOG_BASE + 242)", "netio/netio_log.h", "Incompatible version of Winsock, must not be older than 2.0"}, + {UDP_LOG_INCONSISTENT_MAX_MESSSAGE_SIZE_EC, "UDP_LOG_INCONSISTENT_MAX_MESSSAGE_SIZE_EC", "UDP", "(UDP_LOG_BASE + 243)", "netio/netio_log.h", "Inconsistent max_message_size"}, + {UDP_LOG_INITIALIZE_FAILED_EC, "UDP_LOG_INITIALIZE_FAILED_EC", "UDP", "(UDP_LOG_BASE + 244)", "netio/netio_log.h", "Failed to initialized the loopback interface"}, + {UDP_LOG_PORT_NOT_FOUND_EC, "UDP_LOG_PORT_NOT_FOUND_EC", "UDP", "(UDP_LOG_BASE + 245)", "netio/netio_log.h", "Did not find the specified thread port"}, + {UDP_LOG_CURSOR_ERROR_EC, "UDP_LOG_CURSOR_ERROR_EC", "UDP", "(UDP_LOG_BASE + 246)", "netio/netio_log.h", "An error occurred while iterating over a cursor"}, + {UDP_LOG_SEND_ERROR_EC, "UDP_LOG_SEND_ERROR_EC", "UDP", "(UDP_LOG_BASE + 247)", "netio/netio_log.h", "Failed to send message"}, + {UDP_LOG_MULTICAST_NOT_ENABLED_EC, "UDP_LOG_MULTICAST_NOT_ENABLED_EC", "UDP", "(UDP_LOG_BASE + 248)", "netio/netio_log.h", "Multicast address ignored because multicast supported is not compiled in"}, + {OSAPI_LOG_GET_NEXT_OBJECT_ID_EC, "OSAPI_LOG_GET_NEXT_OBJECT_ID_EC", "OSAPI", "(OSAPI_LOG_BASE + 1)", "osapi/osapi_log.h", "Retrieving the next error code failed"}, + {OSAPI_LOG_SYSTEM_SET_PROPERTY_EC, "OSAPI_LOG_SYSTEM_SET_PROPERTY_EC", "OSAPI", "(OSAPI_LOG_BASE + 2)", "osapi/osapi_log.h", "An error occured while setting the system properties"}, + {OSAPI_LOG_SYSTEM_TIMER_START_EC, "OSAPI_LOG_SYSTEM_TIMER_START_EC", "OSAPI", "(OSAPI_LOG_BASE + 4)", "osapi/osapi_log.h", "An error occured when starting the system timer"}, + {OSAPI_LOG_SYSTEM_TIMER_STOP_EC, "OSAPI_LOG_SYSTEM_TIMER_STOP_EC", "OSAPI", "(OSAPI_LOG_BASE + 5)", "osapi/osapi_log.h", "An error occured when stopping the system timer"}, + {OSAPI_LOG_THREAD_NEW_EC, "OSAPI_LOG_THREAD_NEW_EC", "OSAPI", "(OSAPI_LOG_BASE + 6)", "osapi/osapi_log.h", "An error when allocating the a thread object"}, + {OSAPI_LOG_THREAD_CREATE_EC, "OSAPI_LOG_THREAD_CREATE_EC", "OSAPI", "(OSAPI_LOG_BASE + 7)", "osapi/osapi_log.h", "An error when creating the a thread object"}, + {OSAPI_LOG_THREAD_SEM_EC, "OSAPI_LOG_THREAD_SEM_EC", "OSAPI", "(OSAPI_LOG_BASE + 8)", "osapi/osapi_log.h", "An error when creating thread sync semaphore"}, + {OSAPI_LOG_THREAD_EXEC_CREATE_EC, "OSAPI_LOG_THREAD_EXEC_CREATE_EC", "OSAPI", "(OSAPI_LOG_BASE + 9)", "osapi/osapi_log.h", "Failed to signal that a thread has been created"}, + {OSAPI_LOG_THREAD_EXEC_START_EC, "OSAPI_LOG_THREAD_EXEC_START_EC", "OSAPI", "(OSAPI_LOG_BASE + 10)", "osapi/osapi_log.h", "Failed to signal the start a created thread"}, + {OSAPI_LOG_THREAD_START_EC, "OSAPI_LOG_THREAD_START_EC", "OSAPI", "(OSAPI_LOG_BASE + 11)", "osapi/osapi_log.h", "Failed to start a thread"}, + {OSAPI_LOG_THREAD_DESTROY_EC, "OSAPI_LOG_THREAD_DESTROY_EC", "OSAPI", "(OSAPI_LOG_BASE + 12)", "osapi/osapi_log.h", "Failed to destroy a thread"}, + {OSAPI_LOG_THREAD_DESTROY_NO_START_EC, "OSAPI_LOG_THREAD_DESTROY_NO_START_EC", "OSAPI", "(OSAPI_LOG_BASE + 13)", "osapi/osapi_log.h", "Failed to start an unstarted thread being destroyed"}, + {OSAPI_LOG_THREAD_DESTROY_NO_WAKEUP_EC, "OSAPI_LOG_THREAD_DESTROY_NO_WAKEUP_EC", "OSAPI", "(OSAPI_LOG_BASE + 14)", "osapi/osapi_log.h", "Failed wakeup of a thread being destroyed"}, + {OSAPI_LOG_THREAD_INIT_EC, "OSAPI_LOG_THREAD_INIT_EC", "OSAPI", "(OSAPI_LOG_BASE + 15)", "osapi/osapi_log.h", "Failed initializing a thread"}, + {OSAPI_LOG_THREAD_SCHEDPARAM_EC, "OSAPI_LOG_THREAD_SCHEDPARAM_EC", "OSAPI", "(OSAPI_LOG_BASE + 16)", "osapi/osapi_log.h", "Failed to set scheduling policy of a thread"}, + {OSAPI_LOG_THREAD_GET_POLICY_EC, "OSAPI_LOG_THREAD_GET_POLICY_EC", "OSAPI", "(OSAPI_LOG_BASE + 17)", "osapi/osapi_log.h", "Failed to get the scheduling policy of a thread"}, + {OSAPI_LOG_THREAD_POLICY_DIFFER_EC, "OSAPI_LOG_THREAD_POLICY_DIFFER_EC", "OSAPI", "(OSAPI_LOG_BASE + 18)", "osapi/osapi_log.h", "Mismatch of scheduling policy of a created thread and the application"}, + {OSAPI_LOG_THREAD_PRIORITY_MAP_EC, "OSAPI_LOG_THREAD_PRIORITY_MAP_EC", "OSAPI", "(OSAPI_LOG_BASE + 19)", "osapi/osapi_log.h", "Failed to map to native thread priority values"}, + {OSAPI_LOG_TIMER_DELETE_EC, "OSAPI_LOG_TIMER_DELETE_EC", "OSAPI", "(OSAPI_LOG_BASE + 20)", "osapi/osapi_log.h", "Failed to delete the Timer object"}, + {OSAPI_LOG_TIMER_TICK_EC, "OSAPI_LOG_TIMER_TICK_EC", "OSAPI", "(OSAPI_LOG_BASE + 21)", "osapi/osapi_log.h", ""}, + {OSAPI_LOG_TIMER_TICK_MUTEX_EC, "OSAPI_LOG_TIMER_TICK_MUTEX_EC", "OSAPI", "(OSAPI_LOG_BASE + 22)", "osapi/osapi_log.h", "Failed taking or giving the Timer mutex"}, + {OSAPI_LOG_TIMER_CREATE_TIMEOUT_EC, "OSAPI_LOG_TIMER_CREATE_TIMEOUT_EC", "OSAPI", "(OSAPI_LOG_BASE + 23)", "osapi/osapi_log.h", ""}, + {OSAPI_LOG_TIMER_UPDATE_TIMEOUT_EC, "OSAPI_LOG_TIMER_UPDATE_TIMEOUT_EC", "OSAPI", "(OSAPI_LOG_BASE + 24)", "osapi/osapi_log.h", ""}, + {OSAPI_LOG_TIMER_DELETE_TIMEOUT_EC, "OSAPI_LOG_TIMER_DELETE_TIMEOUT_EC", "OSAPI", "(OSAPI_LOG_BASE + 25)", "osapi/osapi_log.h", ""}, + {OSAPI_LOG_TIMER_GET_USER_DATA_EPOCH_EC, "OSAPI_LOG_TIMER_GET_USER_DATA_EPOCH_EC", "OSAPI", "(OSAPI_LOG_BASE + 27)", "osapi/osapi_log.h", "Failed to return user data for a timeout due to mismatched epochs"}, + {OSAPI_LOG_TIMER_NEW_EC, "OSAPI_LOG_TIMER_NEW_EC", "OSAPI", "(OSAPI_LOG_BASE + 28)", "osapi/osapi_log.h", "Failed to allocate memory for a new Timer"}, + {OSAPI_LOG_TIMER_NEW_ENTRY_EC, "OSAPI_LOG_TIMER_NEW_ENTRY_EC", "OSAPI", "(OSAPI_LOG_BASE + 29)", "osapi/osapi_log.h", "Failed to allocate memory for a new Timer entry"}, + {OSAPI_LOG_TIMER_NEW_WHEEL_EC, "OSAPI_LOG_TIMER_NEW_WHEEL_EC", "OSAPI", "(OSAPI_LOG_BASE + 30)", "osapi/osapi_log.h", "Failed to allocate memory for a new Timer wheel"}, + {OSAPI_LOG_TIMER_NEW_MUTEX_EC, "OSAPI_LOG_TIMER_NEW_MUTEX_EC", "OSAPI", "(OSAPI_LOG_BASE + 31)", "osapi/osapi_log.h", "Failed to create a new Timer mutex"}, + {OSAPI_LOG_TIMER_NEW_START_TIMER_EC, "OSAPI_LOG_TIMER_NEW_START_TIMER_EC", "OSAPI", "(OSAPI_LOG_BASE + 32)", "osapi/osapi_log.h", "Failed to start a new Timer being created"}, + {OSAPI_LOG_TIMER_DELETE_STOP_TIMER_EC, "OSAPI_LOG_TIMER_DELETE_STOP_TIMER_EC", "OSAPI", "(OSAPI_LOG_BASE + 33)", "osapi/osapi_log.h", "Failed to stop a Timer being deleted"}, + {OSAPI_LOG_TIMER_DELETE_MUTEX_EC, "OSAPI_LOG_TIMER_DELETE_MUTEX_EC", "OSAPI", "(OSAPI_LOG_BASE + 34)", "osapi/osapi_log.h", "Failed to delete the Timer mutex"}, + {OSAPI_LOG_TIMER_MUTEX_EC, "OSAPI_LOG_TIMER_MUTEX_EC", "OSAPI", "(OSAPI_LOG_BASE + 35)", "osapi/osapi_log.h", "Failed to take or give a Timer mutex"}, + {OSAPI_LOG_SEMAPHORE_DELETE_EC, "OSAPI_LOG_SEMAPHORE_DELETE_EC", "OSAPI", "(OSAPI_LOG_BASE + 36)", "osapi/osapi_log.h", "Failed to delete a semaphore"}, + {OSAPI_LOG_SEMAPHORE_NEW_EC, "OSAPI_LOG_SEMAPHORE_NEW_EC", "OSAPI", "(OSAPI_LOG_BASE + 37)", "osapi/osapi_log.h", "Failed to create a semaphore"}, + {OSAPI_LOG_SEMAPHORE_NEW_INIT_EC, "OSAPI_LOG_SEMAPHORE_NEW_INIT_EC", "OSAPI", "(OSAPI_LOG_BASE + 38)", "osapi/osapi_log.h", "Failed to initialize a new semaphore"}, + {OSAPI_LOG_SEMAPHORE_GIVE_EC, "OSAPI_LOG_SEMAPHORE_GIVE_EC", "OSAPI", "(OSAPI_LOG_BASE + 39)", "osapi/osapi_log.h", "Failed to give a semaphore"}, + {OSAPI_LOG_SEMAPHORE_TAKE_EC, "OSAPI_LOG_SEMAPHORE_TAKE_EC", "OSAPI", "(OSAPI_LOG_BASE + 40)", "osapi/osapi_log.h", "Failed to take a semaphore"}, + {OSAPI_LOG_MUTEX_DELETE_EC, "OSAPI_LOG_MUTEX_DELETE_EC", "OSAPI", "(OSAPI_LOG_BASE + 41)", "osapi/osapi_log.h", "Failed to delete a mutex"}, + {OSAPI_LOG_MUTEX_NEW_EC, "OSAPI_LOG_MUTEX_NEW_EC", "OSAPI", "(OSAPI_LOG_BASE + 42)", "osapi/osapi_log.h", "Failed to create a mutex"}, + {OSAPI_LOG_MUTEX_TAKE_EC, "OSAPI_LOG_MUTEX_TAKE_EC", "OSAPI", "(OSAPI_LOG_BASE + 43)", "osapi/osapi_log.h", "Failed to take a mutex"}, + {OSAPI_LOG_MUTEX_GIVE_EC, "OSAPI_LOG_MUTEX_GIVE_EC", "OSAPI", "(OSAPI_LOG_BASE + 44)", "osapi/osapi_log.h", "Failed to give a mutex"}, + {OSAPI_LOG_MUTEX_INIT_EC, "OSAPI_LOG_MUTEX_INIT_EC", "OSAPI", "(OSAPI_LOG_BASE + 45)", "osapi/osapi_log.h", "Failed to initialize a mutex"}, + {OSAPI_LOG_HEAP_INTERNAL_ALLOCATE_EC, "OSAPI_LOG_HEAP_INTERNAL_ALLOCATE_EC", "OSAPI", "(OSAPI_LOG_BASE + 46)", "osapi/osapi_log.h", "Failed to allocate a buffer from the heap"}, + {OSAPI_LOG_HEAP_FREE_EC, "OSAPI_LOG_HEAP_FREE_EC", "OSAPI", "(OSAPI_LOG_BASE + 47)", "osapi/osapi_log.h", ""}, + {OSAPI_LOG_SYSTEM_GET_TIME_EC, "OSAPI_LOG_SYSTEM_GET_TIME_EC", "OSAPI", "(OSAPI_LOG_BASE + 48)", "osapi/osapi_log.h", "Failed to get current system time"}, + {OSAPI_LOG_LAST_RECORDED_ERROR_EC, "OSAPI_LOG_LAST_RECORDED_ERROR_EC", "OSAPI", "(OSAPI_LOG_BASE + 49)", "osapi/osapi_log.h", "Return the last recorded error-code for the calling thread"}, + {OSAPI_LOG_SET_THREAD_NAME_EC, "OSAPI_LOG_SET_THREAD_NAME_EC", "OSAPI", "(OSAPI_LOG_BASE + 50)", "osapi/osapi_log.h", "Failed to set the thread name in the OS"}, + {REDA_LOG_BUFFERPOOL_OUT_OF_RESOURCES_EC, "REDA_LOG_BUFFERPOOL_OUT_OF_RESOURCES_EC", "REDA", "(REDA_LOG_BASE + 1)", "reda/reda_log.h", "Not sufficient memory to allocate buffer-pool"}, + {REDA_LOG_BUFFERPOOL_BUFFER_INITIALIZATION_FAILED_EC, "REDA_LOG_BUFFERPOOL_BUFFER_INITIALIZATION_FAILED_EC", "REDA", "(REDA_LOG_BASE + 2)", "reda/reda_log.h", "The buffer initialization method failed"}, + {REDA_LOG_BUFFERPOOL_NOT_EMPTY_EC, "REDA_LOG_BUFFERPOOL_NOT_EMPTY_EC", "REDA", "(REDA_LOG_BASE + 3)", "reda/reda_log.h", "Cannot delete buffer-pool due to buffer(s) not returned to pool"}, + {REDA_LOG_BUFFERPOOL_DOUBLE_FREE_EC, "REDA_LOG_BUFFERPOOL_DOUBLE_FREE_EC", "REDA", "(REDA_LOG_BASE + 4)", "reda/reda_log.h", "A buffer was freed more than once"}, + {REDA_LOG_SEQUENCE_COPY_FAILED_EC, "REDA_LOG_SEQUENCE_COPY_FAILED_EC", "REDA", "(REDA_LOG_BASE + 100)", "reda/reda_log.h", "An error occurred while copying a sequence"}, + {REDA_LOG_SEQUENCE_ALLOC_FAILED_EC, "REDA_LOG_SEQUENCE_ALLOC_FAILED_EC", "REDA", "(REDA_LOG_BASE + 101)", "reda/reda_log.h", "An error occured while allocating space for a sequence"}, + {REDA_LOG_SEQUENCE_SET_MAX_FAILED_EC, "REDA_LOG_SEQUENCE_SET_MAX_FAILED_EC", "REDA", "(REDA_LOG_BASE + 102)", "reda/reda_log.h", "An error occured while setting the maximum sequence size"}, + {REDA_LOG_SEQUENCE_REALLOCATION_EC, "REDA_LOG_SEQUENCE_REALLOCATION_EC", "REDA", "(REDA_LOG_BASE + 103)", "reda/reda_log.h", "An attempt was made to resize an already allocated sequence"}, + {REDA_LOG_SEQUENCE_INVALID_OPERATION_EC, "REDA_LOG_SEQUENCE_INVALID_OPERATION_EC", "REDA", "(REDA_LOG_BASE + 104)", "reda/reda_log.h", "An error occured while operating on two sequences (copy/compare)"}, + {REDA_LOG_SEQUENCE_INVALID_LENGTH_EC, "REDA_LOG_SEQUENCE_INVALID_LENGTH_EC", "REDA", "(REDA_LOG_BASE + 105)", "reda/reda_log.h", "An attempt was made to set an illegal length (length < 0"}, + {REDA_LOG_SEQUENCE_INDEX_OUT_OF_BOUNDS_EC, "REDA_LOG_SEQUENCE_INDEX_OUT_OF_BOUNDS_EC", "REDA", "(REDA_LOG_BASE + 106)", "reda/reda_log.h", "An illegal sequence index was specified (index < 0 or index > length)"}, + {REDA_LOG_STRING_ALLOC_FAILED_EC, "REDA_LOG_STRING_ALLOC_FAILED_EC", "REDA", "(REDA_LOG_BASE + 200)", "reda/reda_log.h", "An error occured while allocating memory for a string"}, + {REDA_LOG_INDEX_FULL_EC, "REDA_LOG_INDEX_FULL_EC", "REDA", "(REDA_LOG_BASE + 300)", "reda/reda_log.h", "An attempt was made to add an element to a full index"}, + {REDA_LOG_INDEX_ENTRY_EXISTS_EC, "REDA_LOG_INDEX_ENTRY_EXISTS_EC", "REDA", "(REDA_LOG_BASE + 301)", "reda/reda_log.h", "An attempt was made to add an existing element to an index"}, + {REDA_LOG_INVALID_LIST_NODE_EC, "REDA_LOG_INVALID_LIST_NODE_EC", "REDA", "(REDA_LOG_BASE + 302)", "reda/reda_log.h", "An attempt was made to add an existing element to an index"}, + {RHSM_LOG_OUTSTANDING_SAMPLE_EC, "RHSM_LOG_OUTSTANDING_SAMPLE_EC", "RHSM", "(RHSM_LOG_BASE + 1)", "rh_sm/rh_sm_log.h", "Failed to delete Reader History due to outstanding, unremoved sample"}, + {RHSM_LOG_NO_PROPERTY_QOS_EC, "RHSM_LOG_NO_PROPERTY_QOS_EC", "RHSM", "(RHSM_LOG_BASE + 2)", "rh_sm/rh_sm_log.h", "Failed to create Reader History due to unspecified property Qos"}, + {RHSM_LOG_KEEP_ALL_HISTORY_NOT_SUPPORTED_EC, "RHSM_LOG_KEEP_ALL_HISTORY_NOT_SUPPORTED_EC", "RHSM", "(RHSM_LOG_BASE + 3)", "rh_sm/rh_sm_log.h", "KEEP_ALL History kind is not supported"}, + {RHSM_LOG_MAX_SAMPLE_TOO_SMALL_EC, "RHSM_LOG_MAX_SAMPLE_TOO_SMALL_EC", "RHSM", "(RHSM_LOG_BASE + 4)", "rh_sm/rh_sm_log.h", "DataReaderQos.resource_limits.max_samples set too small"}, + {RHSM_LOG_TBF_NOT_SUPPORTED_EC, "RHSM_LOG_TBF_NOT_SUPPORTED_EC", "RHSM", "(RHSM_LOG_BASE + 5)", "rh_sm/rh_sm_log.h", "Time-based filtering is not supported"}, + {RHSM_LOG_SAMPLE_INFO_POOL_EC, "RHSM_LOG_SAMPLE_INFO_POOL_EC", "RHSM", "(RHSM_LOG_BASE + 6)", "rh_sm/rh_sm_log.h", "Failed to allocate a buffer pool for sample info"}, + {RHSM_LOG_SAMPLE_POOL_EC, "RHSM_LOG_SAMPLE_POOL_EC", "RHSM", "(RHSM_LOG_BASE + 7)", "rh_sm/rh_sm_log.h", "Failed to allocate a buffer pool for sample pointers"}, + {RHSM_LOG_SAMPLE_PTR_ARRAY_EC, "RHSM_LOG_SAMPLE_PTR_ARRAY_EC", "RHSM", "(RHSM_LOG_BASE + 8)", "rh_sm/rh_sm_log.h", "Failed to get sample buffer."}, + {RHSM_LOG_INFO_ARRAY_EC, "RHSM_LOG_INFO_ARRAY_EC", "RHSM", "(RHSM_LOG_BASE + 9)", "rh_sm/rh_sm_log.h", "Failed to get sample info buffer."}, + {RHSM_LOG_GET_RECEPTION_TIMESTAMP_EC, "RHSM_LOG_GET_RECEPTION_TIMESTAMP_EC", "RHSM", "(RHSM_LOG_BASE + 10)", "rh_sm/rh_sm_log.h", "Failed to get time for reception timestamp."}, + {RHSM_LOG_INVALID_INSTANCE_REPLACEMENT_EC, "RHSM_LOG_INVALID_INSTANCE_REPLACEMENT_EC", "RHSM", "(RHSM_LOG_BASE + 11)", "rh_sm/rh_sm_log.h", "An invalid instance replacement policy was specified."}, + {RHSM_LOG_FAILED_TO_REMOVE_OLDEST_EC, "RHSM_LOG_FAILED_TO_REMOVE_OLDEST_EC", "RHSM", "(RHSM_LOG_BASE + 12)", "rh_sm/rh_sm_log.h", "Failed to remove the oldest sample"}, + {RHSM_LOG_SAMPLE_POOL_EMPTY_EC, "RHSM_LOG_SAMPLE_POOL_EMPTY_EC", "RHSM", "(RHSM_LOG_BASE + 13)", "rh_sm/rh_sm_log.h", "Sample pool empty, may have exceeded"}, + {RHSM_LOG_RW_PRUNE_FAILED_EC, "RHSM_LOG_RW_PRUNE_FAILED_EC", "RHSM", "(RHSM_LOG_BASE + 14)", "rh_sm/rh_sm_log.h", "Failed to prune remote writer entry"}, + {RHSM_LOG_ENTRY_RESERVATION_FAILED_EC, "RHSM_LOG_ENTRY_RESERVATION_FAILED_EC", "RHSM", "(RHSM_LOG_BASE + 15)", "rh_sm/rh_sm_log.h", "Failed to reserve an entry"}, + {RHSM_LOG_RETURN_SAMPLE_EC, "RHSM_LOG_RETURN_SAMPLE_EC", "RHSM", "(RHSM_LOG_BASE + 16)", "rh_sm/rh_sm_log.h", "Failed to return a sample"}, + {RHSM_LOG_HISTORY_UPDATE_EC, "RHSM_LOG_HISTORY_UPDATE_EC", "RHSM", "(RHSM_LOG_BASE + 17)", "rh_sm/rh_sm_log.h", "Failed to update the history queue"}, + {RHSM_LOG_GET_TIME_EC, "RHSM_LOG_GET_TIME_EC", "RHSM", "(RHSM_LOG_BASE + 18)", "rh_sm/rh_sm_log.h", "Failed to get the system time"}, + {RHSM_LOG_OBJECT_ALLOCATE_EC, "RHSM_LOG_OBJECT_ALLOCATE_EC", "RHSM", "(RHSM_LOG_BASE + 19)", "rh_sm/rh_sm_log.h", "Failed to allocate object of the specified kind"}, + {RHSM_LOG_OBJECT_DELETE_EC, "RHSM_LOG_OBJECT_DELETE_EC", "RHSM", "(RHSM_LOG_BASE + 20)", "rh_sm/rh_sm_log.h", "Failed to delete object of the specified kind"}, + {RHSM_LOG_OBJECT_INDEX_EC, "RHSM_LOG_OBJECT_INDEX_EC", "RHSM", "(RHSM_LOG_BASE + 21)", "rh_sm/rh_sm_log.h", "Failed to index an object of the specified kind"}, + {RHSM_LOG_OBJECT_INVALID_EC, "RHSM_LOG_OBJECT_INVALID_EC", "RHSM", "(RHSM_LOG_BASE + 22)", "rh_sm/rh_sm_log.h", "Invalid object specified"}, + {RHSM_LOG_NO_PROPERTY_EC, "RHSM_LOG_NO_PROPERTY_EC", "RHSM", "(RHSM_LOG_BASE + 23)", "rh_sm/rh_sm_log.h", "No property when creating a reader history instance"}, + {RT_LOG_SET_IMMUTABLE_PROPERTY_EC, "RT_LOG_SET_IMMUTABLE_PROPERTY_EC", "RT", "(RT_LOG_BASE + 1)", "rt/rt_log.h", "Failed to set registry property due to registry already being enabled"}, + {RT_LOG_REGISTRY_INIT_FAILURE_EC, "RT_LOG_REGISTRY_INIT_FAILURE_EC", "RT", "(RT_LOG_BASE + 2)", "rt/rt_log.h", "Failed to initialize registry due to failed table creation"}, + {RT_LOG_REGISTRY_FINALIZE_EC, "RT_LOG_REGISTRY_FINALIZE_EC", "RT", "(RT_LOG_BASE + 3)", "rt/rt_log.h", "Failed to finalize registry due to failed table deletion"}, + {RT_LOG_REGISTRY_EXISTS_EC, "RT_LOG_REGISTRY_EXISTS_EC", "RT", "(RT_LOG_BASE + 4)", "rt/rt_log.h", "An attempt was made to register a factory that already existed"}, + {RT_LOG_REGISTRY_REGISTER_EC, "RT_LOG_REGISTRY_REGISTER_EC", "RT", "(RT_LOG_BASE + 5)", "rt/rt_log.h", "Error registering a component factory. May have exceeded"}, + {RT_LOG_REGISTRY_INIT_FACTORY_EC, "RT_LOG_REGISTRY_INIT_FACTORY_EC", "RT", "(RT_LOG_BASE + 7)", "rt/rt_log.h", "A registered factory failed to initialize"}, + {RT_LOG_REGISTRY_NAME_TOO_LONG_EC, "RT_LOG_REGISTRY_NAME_TOO_LONG_EC", "RT", "(RT_LOG_BASE + 8)", "rt/rt_log.h", "Factory name longer than maximum length of 8"}, + {RT_LOG_REGISTRY_INCONSISTENT_CID_EC, "RT_LOG_REGISTRY_INCONSISTENT_CID_EC", "RT", "(RT_LOG_BASE + 9)", "rt/rt_log.h", "Factory name exists, but the class ID is not of the requested type"}, + {RT_LOG_REGISTRY_NOT_INITIALIZED_EC, "RT_LOG_REGISTRY_NOT_INITIALIZED_EC", "RT", "(RT_LOG_BASE + 10)", "rt/rt_log.h", "An attempt was made to operate on an uninitialized registry"}, + {RTPS_LOG_INITIALIZE_INTERFACE_EC, "RTPS_LOG_INITIALIZE_INTERFACE_EC", "RTPS", "(RTPS_LOG_BASE + 1)", "rtps/rtps_log.h", "Failed to initialize an RTPS interface"}, + {RTPS_LOG_ALLOCATE_EC, "RTPS_LOG_ALLOCATE_EC", "RTPS", "(RTPS_LOG_BASE + 2)", "rtps/rtps_log.h", "Failed to allocate heap memory for internal resources"}, + {RTPS_LOG_CREATE_ROUTE_TABLE_EC, "RTPS_LOG_CREATE_ROUTE_TABLE_EC", "RTPS", "(RTPS_LOG_BASE + 3)", "rtps/rtps_log.h", "Failed to create a database table for storing RTPS route info"}, + {RTPS_LOG_DB_CREATE_ROUTE_PEER_INDEX_EC, "RTPS_LOG_DB_CREATE_ROUTE_PEER_INDEX_EC", "RTPS", "(RTPS_LOG_BASE + 4)", "rtps/rtps_log.h", "Failed to create database index for route-peer info"}, + {RTPS_LOG_DB_CREATE_ROUTE_XPORT_INDEX_EC, "RTPS_LOG_DB_CREATE_ROUTE_XPORT_INDEX_EC", "RTPS", "(RTPS_LOG_BASE + 5)", "rtps/rtps_log.h", "Failed to create database index for route-transport info"}, + {RTPS_LOG_DB_CREATE_BIND_PEER_INDEX_EC, "RTPS_LOG_DB_CREATE_BIND_PEER_INDEX_EC", "RTPS", "(RTPS_LOG_BASE + 6)", "rtps/rtps_log.h", "Failed to create database index for bind-peer info"}, + {RTPS_LOG_INDEX_ADD_ENTRY_EC, "RTPS_LOG_INDEX_ADD_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 8)", "rtps/rtps_log.h", "Failed to add an entry to a database index"}, + {RTPS_LOG_DB_SELECT_ALL_EC, "RTPS_LOG_DB_SELECT_ALL_EC", "RTPS", "(RTPS_LOG_BASE + 9)", "rtps/rtps_log.h", "Failed to select all entries of a database table"}, + {RTPS_LOG_DB_SELECT_MATCH_EC, "RTPS_LOG_DB_SELECT_MATCH_EC", "RTPS", "(RTPS_LOG_BASE + 10)", "rtps/rtps_log.h", "Matching entry not found in a database table."}, + {RTPS_LOG_DB_SELECT_RANGE_EC, "RTPS_LOG_DB_SELECT_RANGE_EC", "RTPS", "(RTPS_LOG_BASE + 11)", "rtps/rtps_log.h", "No matching entries found in a database table."}, + {RTPS_LOG_DB_CREATE_ROUTE_ENTRY_EC, "RTPS_LOG_DB_CREATE_ROUTE_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 12)", "rtps/rtps_log.h", "Failed to create database entry for route."}, + {RTPS_LOG_DB_INSERT_ROUTE_ENTRY_EC, "RTPS_LOG_DB_INSERT_ROUTE_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 13)", "rtps/rtps_log.h", "Failed to insert entry into route table"}, + {RTPS_LOG_DB_REMOVE_ROUTE_ENTRY_EC, "RTPS_LOG_DB_REMOVE_ROUTE_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 14)", "rtps/rtps_log.h", "Failed to remove entry from route table"}, + {RTPS_LOG_DB_DELETE_ROUTE_ENTRY_EC, "RTPS_LOG_DB_DELETE_ROUTE_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 15)", "rtps/rtps_log.h", "Failed to delete entry from route table"}, + {RTPS_LOG_DB_CREATE_BIND_ENTRY_EC, "RTPS_LOG_DB_CREATE_BIND_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 16)", "rtps/rtps_log.h", "Failed to create database entry for bind."}, + {RTPS_LOG_DB_INSERT_BIND_ENTRY_EC, "RTPS_LOG_DB_INSERT_BIND_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 17)", "rtps/rtps_log.h", "Failed to insert an entry into the bind table."}, + {RTPS_LOG_DB_REMOVE_BIND_ENTRY_EC, "RTPS_LOG_DB_REMOVE_BIND_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 18)", "rtps/rtps_log.h", "Failed to remove an entry from the bind table."}, + {RTPS_LOG_DB_REMOVE_EXTERNAL_BIND_ENTRY_EC, "RTPS_LOG_DB_REMOVE_EXTERNAL_BIND_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 19)", "rtps/rtps_log.h", "Failed to remove an entry from the external bind table."}, + {RTPS_LOG_DB_DELETE_EXTERNAL_BIND_ENTRY_EC, "RTPS_LOG_DB_DELETE_EXTERNAL_BIND_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 20)", "rtps/rtps_log.h", "Failed to delete entry from external bind table"}, + {RTPS_LOG_SEND_EC, "RTPS_LOG_SEND_EC", "RTPS", "(RTPS_LOG_BASE + 21)", "rtps/rtps_log.h", "Failed to send a packet due to a lower module failing to send the"}, + {RTPS_LOG_RECEIVE_EC, "RTPS_LOG_RECEIVE_EC", "RTPS", "(RTPS_LOG_BASE + 22)", "rtps/rtps_log.h", "Failed to receive a packet due to a higher module failing to receive"}, + {RTPS_LOG_ROUTE_PACKET_EC, "RTPS_LOG_ROUTE_PACKET_EC", "RTPS", "(RTPS_LOG_BASE + 23)", "rtps/rtps_log.h", "Failed to send a packet, when routing to a lower module or peer"}, + {RTPS_LOG_FORWARD_UPSTREAM_EC, "RTPS_LOG_FORWARD_UPSTREAM_EC", "RTPS", "(RTPS_LOG_BASE + 24)", "rtps/rtps_log.h", "Failed to receive a packet, when forwarding to a higher upstream module"}, + {RTPS_LOG_BAD_PARAMETER_EC, "RTPS_LOG_BAD_PARAMETER_EC", "RTPS", "(RTPS_LOG_BASE + 25)", "rtps/rtps_log.h", "Bad parameter to an RTPS interface function"}, + {RTPS_LOG_NOT_ENABLED_EC, "RTPS_LOG_NOT_ENABLED_EC", "RTPS", "(RTPS_LOG_BASE + 26)", "rtps/rtps_log.h", "Failed because interface is not enabled"}, + {RTPS_LOG_READER_UNSUPPORTED_EC, "RTPS_LOG_READER_UNSUPPORTED_EC", "RTPS", "(RTPS_LOG_BASE + 27)", "rtps/rtps_log.h", "RTPS reader does not support send"}, + {RTPS_LOG_INTERFACE_MISMATCH_EC, "RTPS_LOG_INTERFACE_MISMATCH_EC", "RTPS", "(RTPS_LOG_BASE + 28)", "rtps/rtps_log.h", "Upstream interface does not match source or destination of packet"}, + {RTPS_LOG_FULL_SEND_WINDOW_EC, "RTPS_LOG_FULL_SEND_WINDOW_EC", "RTPS", "(RTPS_LOG_BASE + 29)", "rtps/rtps_log.h", "Failed to send due to reaching maximum send window size"}, + {RTPS_LOG_NETIO_PACKET_SET_TAIL_EC, "RTPS_LOG_NETIO_PACKET_SET_TAIL_EC", "RTPS", "(RTPS_LOG_BASE + 31)", "rtps/rtps_log.h", "Failed to set tail of packet to send"}, + {RTPS_LOG_FUNC_UNSUPPORTED_EC, "RTPS_LOG_FUNC_UNSUPPORTED_EC", "RTPS", "(RTPS_LOG_BASE + 32)", "rtps/rtps_log.h", "RTPS interface does not support this function"}, + {RTPS_LOG_EXCEEDED_LIMIT_TRANSPORTS_EC, "RTPS_LOG_EXCEEDED_LIMIT_TRANSPORTS_EC", "RTPS", "(RTPS_LOG_BASE + 33)", "rtps/rtps_log.h", "Out of transport entries."}, + {RTPS_LOG_EXCEEDED_LIMIT_PEERS_EC, "RTPS_LOG_EXCEEDED_LIMIT_PEERS_EC", "RTPS", "(RTPS_LOG_BASE + 34)", "rtps/rtps_log.h", "Out of peer entries."}, + {RTPS_LOG_ASSERT_PEER_EC, "RTPS_LOG_ASSERT_PEER_EC", "RTPS", "(RTPS_LOG_BASE + 35)", "rtps/rtps_log.h", "Failed to assert a remote writer or reader"}, + {RTPS_LOG_ASSERT_TRANSPORT_EC, "RTPS_LOG_ASSERT_TRANSPORT_EC", "RTPS", "(RTPS_LOG_BASE + 36)", "rtps/rtps_log.h", "Failed to assert a downstream transport"}, + {RTPS_LOG_FIND_EXTERNAL_INTERFACE_EC, "RTPS_LOG_FIND_EXTERNAL_INTERFACE_EC", "RTPS", "(RTPS_LOG_BASE + 37)", "rtps/rtps_log.h", "Failed to lookup an external interface"}, + {RTPS_LOG_NONEXISTENT_ROUTE_EC, "RTPS_LOG_NONEXISTENT_ROUTE_EC", "RTPS", "(RTPS_LOG_BASE + 38)", "rtps/rtps_log.h", "Failed to delete a nonexistent route"}, + {RTPS_LOG_NONEXISTENT_BIND_EC, "RTPS_LOG_NONEXISTENT_BIND_EC", "RTPS", "(RTPS_LOG_BASE + 39)", "rtps/rtps_log.h", "Failed to remove a nonexistent bind entry"}, + {RTPS_LOG_NONEXISTENT_EXTERNAL_BIND_EC, "RTPS_LOG_NONEXISTENT_EXTERNAL_BIND_EC", "RTPS", "(RTPS_LOG_BASE + 40)", "rtps/rtps_log.h", "Failed to remove a nonexistent external bind entry"}, + {RTPS_LOG_STALE_ACK_EPOCH__EC, "RTPS_LOG_STALE_ACK_EPOCH__EC", "RTPS", "(RTPS_LOG_BASE + 41)", "rtps/rtps_log.h", "Dropped an ACKNACK submessage with an old epoch"}, + {RTPS_LOG_STALE_HB_EPOCH_EC, "RTPS_LOG_STALE_HB_EPOCH_EC", "RTPS", "(RTPS_LOG_BASE + 42)", "rtps/rtps_log.h", "Dropped a HEARTBEAT submessage with an old epoch"}, + {RTPS_LOG_ACK_EC, "RTPS_LOG_ACK_EC", "RTPS", "(RTPS_LOG_BASE + 43)", "rtps/rtps_log.h", "Failed an acknack() upstream"}, + {RTPS_LOG_REQUEST_EC, "RTPS_LOG_REQUEST_EC", "RTPS", "(RTPS_LOG_BASE + 45)", "rtps/rtps_log.h", "Failed a request() upstream"}, + {RTPS_LOG_RETURN_LOAN_EC, "RTPS_LOG_RETURN_LOAN_EC", "RTPS", "(RTPS_LOG_BASE + 46)", "rtps/rtps_log.h", "Failed a return_loan() upstream"}, + {RTPS_LOG_NETIO_PACKET_SET_HEAD_EC, "RTPS_LOG_NETIO_PACKET_SET_HEAD_EC", "RTPS", "(RTPS_LOG_BASE + 47)", "rtps/rtps_log.h", "Failed to set the head of a packet"}, + {RTPS_LOG_SEND_HEARTBEAT_EC, "RTPS_LOG_SEND_HEARTBEAT_EC", "RTPS", "(RTPS_LOG_BASE + 48)", "rtps/rtps_log.h", "Failed to send a HEARTBEAT submessage"}, + {RTPS_LOG_SHIFT_BITMAP_EC, "RTPS_LOG_SHIFT_BITMAP_EC", "RTPS", "(RTPS_LOG_BASE + 49)", "rtps/rtps_log.h", "Failed to shift a bitmap"}, + {RTPS_LOG_FULLY_ACKED_READER_EC, "RTPS_LOG_FULLY_ACKED_READER_EC", "RTPS", "(RTPS_LOG_BASE + 50)", "rtps/rtps_log.h", "A Reader is fully acknowledged and does not need to respond to a"}, + {RTPS_LOG_DATA_OUT_OF_RANGE_EC, "RTPS_LOG_DATA_OUT_OF_RANGE_EC", "RTPS", "(RTPS_LOG_BASE + 51)", "rtps/rtps_log.h", "Dropping a DATA submessage whose sequence number is outside of"}, + {RTPS_LOG_DATA_ALREADY_RECEIVED_EC, "RTPS_LOG_DATA_ALREADY_RECEIVED_EC", "RTPS", "(RTPS_LOG_BASE + 52)", "rtps/rtps_log.h", "Dropping a DATA submessage whose sequence number was previously"}, + {RTPS_LOG_INTERFACE_NOT_ENABLED_EC, "RTPS_LOG_INTERFACE_NOT_ENABLED_EC", "RTPS", "(RTPS_LOG_BASE + 53)", "rtps/rtps_log.h", "Failed to receive a message because interface is not enabled"}, + {RTPS_LOG_INVALID_PACKET_EC, "RTPS_LOG_INVALID_PACKET_EC", "RTPS", "(RTPS_LOG_BASE + 54)", "rtps/rtps_log.h", "Dropped a message with an invalid packet header"}, + {RTPS_LOG_UNSUPPORTED_INTERFACE_EC, "RTPS_LOG_UNSUPPORTED_INTERFACE_EC", "RTPS", "(RTPS_LOG_BASE + 55)", "rtps/rtps_log.h", "Received a message on an unsupported interface"}, + {RTPS_LOG_UNKNOWN_SUBMESSAGE_EC, "RTPS_LOG_UNKNOWN_SUBMESSAGE_EC", "RTPS", "(RTPS_LOG_BASE + 56)", "rtps/rtps_log.h", "Received a submessage with an unknown ID"}, + {RTPS_LOG_PROCESS_ACKNACK_EC, "RTPS_LOG_PROCESS_ACKNACK_EC", "RTPS", "(RTPS_LOG_BASE + 57)", "rtps/rtps_log.h", "Failed to process received ACKNACK submessage"}, + {RTPS_LOG_PROCESS_DATA_EC, "RTPS_LOG_PROCESS_DATA_EC", "RTPS", "(RTPS_LOG_BASE + 58)", "rtps/rtps_log.h", "Failed to process received DATA submessage"}, + {RTPS_LOG_PROCESS_GAP_EC, "RTPS_LOG_PROCESS_GAP_EC", "RTPS", "(RTPS_LOG_BASE + 59)", "rtps/rtps_log.h", "Failed to process received GAP submessage"}, + {RTPS_LOG_PROCESS_HEARTBEAT_EC, "RTPS_LOG_PROCESS_HEARTBEAT_EC", "RTPS", "(RTPS_LOG_BASE + 60)", "rtps/rtps_log.h", "Failed to process received HEARTBEAT submessage"}, + {RTPS_LOG_CREATE_HB_EVENT_EC, "RTPS_LOG_CREATE_HB_EVENT_EC", "RTPS", "(RTPS_LOG_BASE + 61)", "rtps/rtps_log.h", "Failed to create periodic HEARTBEAT event"}, + {RTPS_LOG_CREATE_EVENT_TIMER_EC, "RTPS_LOG_CREATE_EVENT_TIMER_EC", "RTPS", "(RTPS_LOG_BASE + 62)", "rtps/rtps_log.h", "Failed to create periodic HEARTBEAT event timer"}, + {RTPS_LOG_SEQ_NUM_OUT_OF_RANGE_EC, "RTPS_LOG_SEQ_NUM_OUT_OF_RANGE_EC", "RTPS", "(RTPS_LOG_BASE + 63)", "rtps/rtps_log.h", "Failed to set bitmap bit due to out-of-range sequence number"}, + {RTPS_LOG_FIRST_SN_GREATER_LAST_SN_EC, "RTPS_LOG_FIRST_SN_GREATER_LAST_SN_EC", "RTPS", "(RTPS_LOG_BASE + 65)", "rtps/rtps_log.h", "Invalid range of sequence numbers to fill in bitmap"}, + {RTPS_LOG_BITCOUNT_OUT_OF_BOUNDS_EC, "RTPS_LOG_BITCOUNT_OUT_OF_BOUNDS_EC", "RTPS", "(RTPS_LOG_BASE + 66)", "rtps/rtps_log.h", "Deserialized an invalid out-of-bounds bitcount for a bitmap"}, + {RTPS_LOG_SHIFT_SN_OUT_OF_RANGE_EC, "RTPS_LOG_SHIFT_SN_OUT_OF_RANGE_EC", "RTPS", "(RTPS_LOG_BASE + 67)", "rtps/rtps_log.h", "Failed to shift bitmap due to invalid starting sequence number"}, + {RTPS_LOG_SERIALIZE_HOST_ID_EC, "RTPS_LOG_SERIALIZE_HOST_ID_EC", "RTPS", "(RTPS_LOG_BASE + 68)", "rtps/rtps_log.h", "Failed to serialize host ID of GUID"}, + {RTPS_LOG_SERIALIZE_APP_ID_EC, "RTPS_LOG_SERIALIZE_APP_ID_EC", "RTPS", "(RTPS_LOG_BASE + 69)", "rtps/rtps_log.h", "Failed to serialize app ID of GUID"}, + {RTPS_LOG_SERIALIZE_INSTANCE_ID_EC, "RTPS_LOG_SERIALIZE_INSTANCE_ID_EC", "RTPS", "(RTPS_LOG_BASE + 70)", "rtps/rtps_log.h", "Failed to serialized instance ID of GUID"}, + {RTPS_LOG_SERIALIZE_OBJECT_ID_EC, "RTPS_LOG_SERIALIZE_OBJECT_ID_EC", "RTPS", "(RTPS_LOG_BASE + 71)", "rtps/rtps_log.h", "Failed to serialize object ID of GUID"}, + {RTPS_LOG_DESERIALIZE_HOST_ID_EC, "RTPS_LOG_DESERIALIZE_HOST_ID_EC", "RTPS", "(RTPS_LOG_BASE + 72)", "rtps/rtps_log.h", "Failed to deserialize host ID of GUID"}, + {RTPS_LOG_DESERIALIZE_APP_ID_EC, "RTPS_LOG_DESERIALIZE_APP_ID_EC", "RTPS", "(RTPS_LOG_BASE + 73)", "rtps/rtps_log.h", "Faild to deserialize app ID of GUID"}, + {RTPS_LOG_DESERIALIZE_INSTANCE_ID_EC, "RTPS_LOG_DESERIALIZE_INSTANCE_ID_EC", "RTPS", "(RTPS_LOG_BASE + 74)", "rtps/rtps_log.h", "Failed to deserialize instance ID of GUID"}, + {RTPS_LOG_DESERIALIZE_OBJECT_ID_EC, "RTPS_LOG_DESERIALIZE_OBJECT_ID_EC", "RTPS", "(RTPS_LOG_BASE + 75)", "rtps/rtps_log.h", "Failed to deserialize object ID of GUID"}, + {RTPS_LOG_DB_CREATE_EXT_BIND_ENTRY_EC, "RTPS_LOG_DB_CREATE_EXT_BIND_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 76)", "rtps/rtps_log.h", "Failed to create database entry for external bind table."}, + {RTPS_LOG_BITMAP_SET_BIT_EC, "RTPS_LOG_BITMAP_SET_BIT_EC", "RTPS", "(RTPS_LOG_BASE + 77)", "rtps/rtps_log.h", "Failed to set bit in bitmap"}, + {RTPS_LOG_UNSUPPORTED_INFO_REPLY_EC, "RTPS_LOG_UNSUPPORTED_INFO_REPLY_EC", "RTPS", "(RTPS_LOG_BASE + 78)", "rtps/rtps_log.h", "Received and dropped currently unsupported INFO_REPLY submessage"}, + {RTPS_LOG_UNSUPPORTED_INFO_SRC_EC, "RTPS_LOG_UNSUPPORTED_INFO_SRC_EC", "RTPS", "(RTPS_LOG_BASE + 80)", "rtps/rtps_log.h", "Received and dropped currently unsupported INFO_SRC submessage"}, + {RTPS_LOG_DELETE_INDEX_EC, "RTPS_LOG_DELETE_INDEX_EC", "RTPS", "(RTPS_LOG_BASE + 81)", "rtps/rtps_log.h", "Failed to delete index of a database table"}, + {RTPS_LOG_DELETE_TABLE_EC, "RTPS_LOG_DELETE_TABLE_EC", "RTPS", "(RTPS_LOG_BASE + 82)", "rtps/rtps_log.h", "Failed to delete a database table"}, + {RTPS_LOG_DB_LOCK_EC, "RTPS_LOG_DB_LOCK_EC", "RTPS", "(RTPS_LOG_BASE + 83)", "rtps/rtps_log.h", "Failed to take database lock"}, + {RTPS_LOG_DB_UNLOCK_EC, "RTPS_LOG_DB_UNLOCK_EC", "RTPS", "(RTPS_LOG_BASE + 84)", "rtps/rtps_log.h", "Failed to give database lock"}, + {RTPS_LOG_CREATE_BIND_TABLE_EC, "RTPS_LOG_CREATE_BIND_TABLE_EC", "RTPS", "(RTPS_LOG_BASE + 85)", "rtps/rtps_log.h", "Failed to create a database table for storing RTPS bind info"}, + {RTPS_LOG_STATUS_CHANGE_EC, "RTPS_LOG_STATUS_CHANGE_EC", "RTPS", "(RTPS_LOG_BASE + 86)", "rtps/rtps_log.h", "Failed to update status for reliable reader activity changed."}, + {RTPS_LOG_SET_GAP_EC, "RTPS_LOG_SET_GAP_EC", "RTPS", "(RTPS_LOG_BASE + 87)", "rtps/rtps_log.h", "Failed to update status for reliable reader activity changed."}, + {RTPS_LOG_WINDOW_POOL_ALLOC_EC, "RTPS_LOG_WINDOW_POOL_ALLOC_EC", "RTPS", "(RTPS_LOG_BASE + 88)", "rtps/rtps_log.h", "Out of memory to allocate send window pool"}, + {RTPS_LOG_GET_WINDOW_BUFFER_EC, "RTPS_LOG_GET_WINDOW_BUFFER_EC", "RTPS", "(RTPS_LOG_BASE + 89)", "rtps/rtps_log.h", "Failed to get buffer from send window pool"}, + {RTPS_LOG_INSERT_WINDOW_FULL_EC, "RTPS_LOG_INSERT_WINDOW_FULL_EC", "RTPS", "(RTPS_LOG_BASE + 90)", "rtps/rtps_log.h", "Cannot insert sample into full window"}, + {RTPS_LOG_WINDOW_INSERT_EC, "RTPS_LOG_WINDOW_INSERT_EC", "RTPS", "(RTPS_LOG_BASE + 91)", "rtps/rtps_log.h", "Failed to insert sample into send window"}, + {RTPS_LOG_TIMER_DELETE_TIMEOUT_EC, "RTPS_LOG_TIMER_DELETE_TIMEOUT_EC", "RTPS", "(RTPS_LOG_BASE + 92)", "rtps/rtps_log.h", "Failed to delete a timeout event"}, + {RTPS_LOG_BUFFERPOOL_DELETE_EC, "RTPS_LOG_BUFFERPOOL_DELETE_EC", "RTPS", "(RTPS_LOG_BASE + 93)", "rtps/rtps_log.h", "Failed to delete a buffer pool"}, + {RTPS_LOG_DIRECT_SEND_EC, "RTPS_LOG_DIRECT_SEND_EC", "RTPS", "(RTPS_LOG_BASE + 94)", "rtps/rtps_log.h", "Failed to send a message to a specific peer"}, + {RTPS_LOG_PACKET_INITIALIZE_EC, "RTPS_LOG_PACKET_INITIALIZE_EC", "RTPS", "(RTPS_LOG_BASE + 95)", "rtps/rtps_log.h", "RTPS writer failed to initialize a packet"}, + {RTPS_LOG_WRITER_REQUEST_SENT_HISTORY_EC, "RTPS_LOG_WRITER_REQUEST_SENT_HISTORY_EC", "RTPS", "(RTPS_LOG_BASE + 96)", "rtps/rtps_log.h", "RTPS reliable writer failed to request and resend history"}, + {RTPS_LOG_BITMAP_SHIFT_EC, "RTPS_LOG_BITMAP_SHIFT_EC", "RTPS", "(RTPS_LOG_BASE + 97)", "rtps/rtps_log.h", "Failed to shift bitmap to new lead sequence number"}, + {RTPS_LOG_WINDOW_ADVANCE_EC, "RTPS_LOG_WINDOW_ADVANCE_EC", "RTPS", "(RTPS_LOG_BASE + 98)", "rtps/rtps_log.h", "Send window of a remote reader failed to advance"}, + {RTPS_LOG_WINDOW_ADVANCE_UNACKED_EC, "RTPS_LOG_WINDOW_ADVANCE_UNACKED_EC", "RTPS", "(RTPS_LOG_BASE + 99)", "rtps/rtps_log.h", "Failed when advancing window ahead of unacknowledged sequence number"}, + {RTPS_LOG_LOOKUP_PEER_EC, "RTPS_LOG_LOOKUP_PEER_EC", "RTPS", "(RTPS_LOG_BASE + 100)", "rtps/rtps_log.h", "Failed to find peer that should exist"}, + {RTPS_LOG_READER_SEND_ACKNACK_EC, "RTPS_LOG_READER_SEND_ACKNACK_EC", "RTPS", "(RTPS_LOG_BASE + 101)", "rtps/rtps_log.h", "RTPS reader failed to send an ACKNACK message"}, + {RTPS_LOG_FINALIZE_INTERFACE_EC, "RTPS_LOG_FINALIZE_INTERFACE_EC", "RTPS", "(RTPS_LOG_BASE + 102)", "rtps/rtps_log.h", "Failed to finalize an RTPS interface"}, + {RTPS_LOG_INDEXER_REMOVE_ENTRY_EC, "RTPS_LOG_INDEXER_REMOVE_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 103)", "rtps/rtps_log.h", "Failed to remove index entry for external interface upon deleting"}, + {RTPS_LOG_LOOKUP_EXT_BIND_ENTRY_EC, "RTPS_LOG_LOOKUP_EXT_BIND_ENTRY_EC", "RTPS", "(RTPS_LOG_BASE + 104)", "rtps/rtps_log.h", "Failed when looking up external bind entry from database"}, + {RTPS_LOG_SEQ_INIT_EC, "RTPS_LOG_SEQ_INIT_EC", "RTPS", "(RTPS_LOG_BASE + 105)", "rtps/rtps_log.h", "Failed to initialize a local sequence"}, + {RTPS_LOG_SEQ_MAX_EC, "RTPS_LOG_SEQ_MAX_EC", "RTPS", "(RTPS_LOG_BASE + 106)", "rtps/rtps_log.h", "Failed to set maximum of a local sequence"}, + {RTPS_LOG_SEQ_LEN_EC, "RTPS_LOG_SEQ_LEN_EC", "RTPS", "(RTPS_LOG_BASE + 107)", "rtps/rtps_log.h", "Failed to set length of a local sequence"}, + {RTPS_LOG_INTF_MODE_UNDEF_EC, "RTPS_LOG_INTF_MODE_UNDEF_EC", "RTPS", "(RTPS_LOG_BASE + 108)", "rtps/rtps_log.h", "Initializing an RTPS interface with undefined mode"}, + {RTPS_LOG_DELETE_BUFFER_POOL_EC, "RTPS_LOG_DELETE_BUFFER_POOL_EC", "RTPS", "(RTPS_LOG_BASE + 109)", "rtps/rtps_log.h", "Failed to delete buffer pool"}, + {RTPS_LOG_CREATE_BUFFER_POOL_EC, "RTPS_LOG_CREATE_BUFFER_POOL_EC", "RTPS", "(RTPS_LOG_BASE + 110)", "rtps/rtps_log.h", "Failed to create buffer pool"}, + {RTPS_LOG_CREATE_PEERS_INDEX_EC, "RTPS_LOG_CREATE_PEERS_INDEX_EC", "RTPS", "(RTPS_LOG_BASE + 111)", "rtps/rtps_log.h", "Failed to create index of peers"}, + {RTPS_LOG_DELETE_INDEXER_EC, "RTPS_LOG_DELETE_INDEXER_EC", "RTPS", "(RTPS_LOG_BASE + 112)", "rtps/rtps_log.h", "Failed to delete indexer"}, + {RTPS_LOG_GET_PEER_BUFFER_EC, "RTPS_LOG_GET_PEER_BUFFER_EC", "RTPS", "(RTPS_LOG_BASE + 113)", "rtps/rtps_log.h", "Failed to get buffer from peer buffer pool"}, + {RTPS_LOG_DB_CREATE_DIRECT_INDEX_EC, "RTPS_LOG_DB_CREATE_DIRECT_INDEX_EC", "RTPS", "(RTPS_LOG_BASE + 114)", "rtps/rtps_log.h", "Failed to create database index for direct sends"}, + {RTPS_LOG_DB_CREATE_GROUP_INDEX_EC, "RTPS_LOG_DB_CREATE_GROUP_INDEX_EC", "RTPS", "(RTPS_LOG_BASE + 115)", "rtps/rtps_log.h", "Failed to create database index for group sends"}, + {WHSM_LOG_KEEP_ALL_HISTORY_NOT_SUPPORTED_EC, "WHSM_LOG_KEEP_ALL_HISTORY_NOT_SUPPORTED_EC", "WHSM", "(WHSM_LOG_BASE + 1)", "wh_sm/wh_sm_log.h", "KEEP_ALL History kind is not supported"}, + {WHSM_LOG_UNLIMITED_HISTORY_NOT_SUPPORTED_EC, "WHSM_LOG_UNLIMITED_HISTORY_NOT_SUPPORTED_EC", "WHSM", "(WHSM_LOG_BASE + 2)", "wh_sm/wh_sm_log.h", "Unlimited length resource limits unsupported"}, + {WHSM_LOG_MAX_SAMPLES_TOO_SMALL_EC, "WHSM_LOG_MAX_SAMPLES_TOO_SMALL_EC", "WHSM", "(WHSM_LOG_BASE + 3)", "wh_sm/wh_sm_log.h", "DataWriterQos.resource_limits.max_samples set too small"}, + {WHSM_LOG_OBJECT_ALLOCATE_EC, "WHSM_LOG_OBJECT_ALLOCATE_EC", "WHSM", "(WHSM_LOG_BASE + 4)", "wh_sm/wh_sm_log.h", "Failed to allocate object of the specified kind"}, + {WHSM_LOG_OBJECT_DELETE_EC, "WHSM_LOG_OBJECT_DELETE_EC", "WHSM", "(WHSM_LOG_BASE + 5)", "wh_sm/wh_sm_log.h", "Failed to delete object of the specified kind"}, + {WHSM_LOG_OBJECT_INDEX_EC, "WHSM_LOG_OBJECT_INDEX_EC", "WHSM", "(WHSM_LOG_BASE + 6)", "wh_sm/wh_sm_log.h", "Failed to index an object of the specified kind"}, + {WHSM_LOG_NO_PROPERTY_EC, "WHSM_LOG_NO_PROPERTY_EC", "WHSM", "(WHSM_LOG_BASE + 7)", "wh_sm/wh_sm_log.h", "No property when creating a writer history instance"} +}; \ No newline at end of file diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_log_trace_handlers.cxx b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_log_trace_handlers.cxx new file mode 100644 index 00000000..fa40ed4e --- /dev/null +++ b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_log_trace_handlers.cxx @@ -0,0 +1,440 @@ +/* Note: this file has extensinon .cxx but it actually contains plain C only */ + +/* Interface */ +#include "connext_micro_log_trace_handlers.h" + + +/* Implementation */ +#include "stdlib.h" + +//#define OSAPI_ENABLE_LOG (1) +//#define OSAPI_ENABLE_TRACE (1) + +#include "osapi/osapi_log.h" +#include "osapi/osapi_string.h" +#include "osapi/osapi_process.h" +#include "connext_micro_ec_log_info.i" /* Code generated by awk script */ + +static FILE *G_traceFilePtr = NULL; +static struct OSAPI_Mutex *G_logLock = NULL; + +static const char * +LogTrace_get_log_kind_name(RTI_UINT32 error_code) +{ + const char *result = NULL; +#define CASE_MACRO(kindName) \ + case OSAPI_LOGKIND_ ## kindName: \ + result = #kindName; \ + break + + + switch (OSAPI_LOG_HEADER_GET_TYPE(error_code)) + { + CASE_MACRO(INFO); + CASE_MACRO(WARNING); + CASE_MACRO(ERROR); + CASE_MACRO(PRECONDITION); + default: + result = ""; + } + +#undef CASE_MACRO + + return result; +} + + +static bool +LogTrace_lookup_error_info(RTI_UINT32 error_code, + const char **name, const char **module_name, + const char **definition, const char **definition_file, + const char **brief) +{ + RTI_BOOL result = RTI_FALSE; + int index; + unsigned int lookup_value; + struct ec_log_info found_info; + + lookup_value = error_code & 0x07ff7fff; + for (index = 0; (index < EC_LOG_INFO_COUNT) && !result; index++) { + result = (lookup_value == S_ec_log_infos[index].value); + if (result) { + found_info = S_ec_log_infos[index]; + *name = found_info.name; + *module_name = found_info.module_name; + *definition = found_info.definition; + *definition_file = found_info.definition_file; + *brief = found_info.brief; + } + } + + return result; +} + + +static void +helloworld_display_handler(void *param, OSAPI_LogEntry_T *log_entry) +{ + RTI_BOOL retval; + static int S_log_count = 0; + RTI_UINT32 status = 0; + + /* Basic log values */ + RTI_UINT32 error_code; + const char *log_kind = NULL; + RTI_INT32 sec; + RTI_UINT32 nsec; + RTI_UINT32 error_id; + RTI_UINT32 error_module_id; + RTI_BOOL F_bit; + RTI_BOOL X_bit; + RTI_BOOL E_bit; + RTI_BOOL T_bit; + + /* Extended information about log message */ + const char *error_name = NULL; + const char *error_module_name = NULL; + const char *error_definition = NULL; + const char *error_definition_file = NULL; + const char *error_description = NULL; + + /* Source code location information (if X-bit is set) */ + char *X_data_ptr; + const char *module = ""; + const char *file = ""; + const char *func = ""; + RTI_INT32 lineno = -1; + + /* Additional log values */ + char *value_data_ptr; + OSAPI_LogType_T value_type; + RTI_BOOL is_final = RTI_FALSE; + const char *name; + const void *value; + const char *err_msg; + + UNUSED_ARG(param); + + retval = OSAPI_Mutex_take(G_logLock); + if (!retval) { + printf("Error in helloworld_display_handler: unable to take log lock\n"); + goto done; + } + + S_log_count++; + error_code = log_entry->error_code; + + log_kind = LogTrace_get_log_kind_name(error_code); + OSAPI_NtpTime_to_nanosec(&sec, &nsec, &log_entry->timestamp); + error_module_id = OSAPI_LOG_HEADER_GET_MODULE(error_code); + error_id = OSAPI_LOG_HEADER_GET_EC(error_code); + F_bit = OSAPI_LOG_HEADER_GET_F(error_code); + X_bit = OSAPI_LOG_HEADER_GET_X(error_code); + E_bit = OSAPI_LOG_HEADER_GET_E(error_code); + T_bit = OSAPI_LOG_HEADER_GET_T(error_code); + + retval = LogTrace_lookup_error_info(error_code, + &error_name, &error_module_name, + &error_definition, &error_definition_file, + &error_description); + + fprintf(G_traceFilePtr, "\n"); + fprintf(G_traceFilePtr, "Log message %d received\n", S_log_count); + fprintf(G_traceFilePtr, " Time : [%d.%d]\n", sec, nsec); + fprintf(G_traceFilePtr, " Kind : %s\n", log_kind); + fprintf(G_traceFilePtr, " Error code : 0x%08x (%u)\n", error_code, error_id); + if (retval) { + fprintf(G_traceFilePtr, " Name : %s\n", error_name); + fprintf(G_traceFilePtr, " Module : %s (%d)\n", error_module_name, error_module_id); + fprintf(G_traceFilePtr, " Defined : %s (%s)\n", error_definition, error_definition_file); + fprintf(G_traceFilePtr, " Brief : %s\n", error_description); + } + fprintf(G_traceFilePtr, " F-bit : %s\n", F_bit ? "set" : "not set"); + fprintf(G_traceFilePtr, " X-bit : %s\n", X_bit ? "set" : "not set"); + fprintf(G_traceFilePtr, " E-bit : %s\n", E_bit ? "set" : "not set"); + fprintf(G_traceFilePtr, " T-bit : %s\n", T_bit ? "set" : "not set"); + + if (X_bit) + { + X_data_ptr = (char*)&log_entry[1]; + status = *(RTI_INT32*)X_data_ptr; + X_data_ptr += sizeof(RTI_INT32); + if (status & OSAPI_LOG_STATUS_LN) + { + lineno = *(RTI_INT32*)X_data_ptr; + X_data_ptr += (RTI_INT32)sizeof(RTI_INT32); + } + if (status & OSAPI_LOG_STATUS_MN) + { + module = X_data_ptr; + X_data_ptr += OSAPI_String_length(X_data_ptr) + 1; + } + if (status & OSAPI_LOG_STATUS_SF) + { + file = X_data_ptr; + X_data_ptr += OSAPI_String_length(X_data_ptr) + 1; + } + if (status & OSAPI_LOG_STATUS_FN) + { + func = X_data_ptr; + X_data_ptr += OSAPI_String_length(X_data_ptr) + 1; + } + if (status & OSAPI_LOG_STATUS_F) + { + X_data_ptr += OSAPI_String_length(X_data_ptr) + 1; + } + fprintf(G_traceFilePtr, " Source :\n"); + fprintf(G_traceFilePtr, " Module : %s\n", module); + fprintf(G_traceFilePtr, " File : %s\n", file); + fprintf(G_traceFilePtr, " Line : %d\n", lineno); + fprintf(G_traceFilePtr, " Function : %s\n", func); + } else { + fprintf(G_traceFilePtr, " Source : \n"); + } + + /* Get additional values */ + value_data_ptr = NULL; + is_final = RTI_FALSE; + + while (OSAPI_Log_entry_get_data(log_entry, &value_data_ptr, &value_type, + &name, &value, &is_final)) + { + fprintf(G_traceFilePtr, " Additional value \"%s\" : ", name); + switch (value_type) + { + case OSAPI_LOGTYPE_INTEGER: + fprintf(G_traceFilePtr, "%d | %u | 0x%08X [int]\n", + *(int *)value, *(int *)value, *(int *)value); + /* Special case: sysrc seems to be errno value, so try to print sys err */ + if (!strcmp(name, "sysrc")) { + /* strerror definition actually is const char * */ + err_msg = (const char *)strerror(*(int *)value); + if (NULL != err_msg) { + fprintf(G_traceFilePtr, " System errmsg : \"%s\"\n", err_msg); + } + } + break; + case OSAPI_LOGTYPE_POINTER: + fprintf(G_traceFilePtr, "%p [ptr]\n", value); + break; + case OSAPI_LOGTYPE_STRING: + fprintf(G_traceFilePtr, "\"%s\" [str]\n", (char *)value); + break; + default: + fprintf(G_traceFilePtr, "%p [unknown type]\n", value); + break; + } + if (is_final) { + break; + } + } + fflush(G_traceFilePtr); + + retval = OSAPI_Mutex_give(G_logLock); + IGNORE_RETVAL(retval); + +done: + return; +} + +static void +helloworld_trace_handler(RTI_UINT32 trace_mask,void *param,RTI_INT32 context, + const char *const module,const char *const file, + const char *const function,RTI_INT32 line_no, + OSAPI_TraceType_T type,const void *title, + RTI_INT32 intv,const void *ptrv,const char *strv, + RTI_BOOL is_final) +{ + RTI_BOOL retval; + static int S_trace_count = 0; + + RTI_INT32 sec; + RTI_UINT32 nsec; + struct OSAPI_NtpTime timestamp; + struct OSAPI_NtpTime zero_time = OSAPI_NTP_TIME_ZERO; + RTI_INT32 pid; + RTI_INT32 *intptr; + + retval = OSAPI_Mutex_take(G_logLock); + if (!retval) { + printf("Error in helloworld_trace_handler: unable to take log lock\n"); + goto done; + } + + S_trace_count++; + + if (type == OSAPI_TRACETYPE_HEADER) + { + if (!OSAPI_System_get_time(×tamp)) { + timestamp = zero_time; + } + OSAPI_NtpTime_to_nanosec(&sec, &nsec, ×tamp); + pid = OSAPI_Process_getpid(); + + fprintf(G_traceFilePtr, "\n"); + fprintf(G_traceFilePtr, "Trace message received:\n"); + fprintf(G_traceFilePtr, " Title : %s\n", title ? (const char *)title : ""); + fprintf(G_traceFilePtr, " Count : %d\n", S_trace_count); + fprintf(G_traceFilePtr, " Type : HEADER\n"); + fprintf(G_traceFilePtr, " Time : [%d.%d]\n", sec, nsec); + fprintf(G_traceFilePtr, " Pid : %d\n", pid); + fprintf(G_traceFilePtr, " Context : %d\n", context); + fprintf(G_traceFilePtr, " Module : %s\n", module ? module : ""); + fprintf(G_traceFilePtr, " File : %s\n", file ? file : ""); + fprintf(G_traceFilePtr, " Function : %s\n", function ? function : ""); + fprintf(G_traceFilePtr, " LineNo : %d\n", line_no); + } + else + { + fprintf(G_traceFilePtr, " Title : %s\n", title ? (const char *)title : ""); + fprintf(G_traceFilePtr, " Count : %d\n", S_trace_count); + fprintf(G_traceFilePtr, " Context : %d\n", context); + fprintf(G_traceFilePtr, " LineNo : %d\n", line_no); + switch (type) + { + case OSAPI_TRACETYPE_GUID: + intptr = (RTI_INT32 *)ptrv; + fprintf(G_traceFilePtr, " Type : GUID\n"); + fprintf(G_traceFilePtr, " Value : {%08X-%08X-%08X-%08X}\n", + intptr[0], intptr[1], intptr[2], intptr[3]); + break; + case OSAPI_TRACETYPE_INT32: + fprintf(G_traceFilePtr, " Type : INT32\n"); + fprintf(G_traceFilePtr, " Value : %d | %u | 0x%08X\n", + intv, intv, intv); + break; + case OSAPI_TRACETYPE_STRING: + fprintf(G_traceFilePtr, " Type : STRING\n"); + fprintf(G_traceFilePtr, " Value : \"%s\"\n", strv); + break; + case OSAPI_TRACETYPE_V4_AS_INT32: + intptr = (RTI_INT32 *)ptrv; + fprintf(G_traceFilePtr, " Type : V4_AS_INT32\n"); + fprintf(G_traceFilePtr, " Value : %d\n", intptr[0]); + break; + case OSAPI_TRACETYPE_V12_AS_INT32: + intptr = (RTI_INT32 *)ptrv; + fprintf(G_traceFilePtr, " Type : V12_AS_INT32\n"); + fprintf(G_traceFilePtr, " Value : %d %d %d\n", + intptr[0], intptr[1], intptr[2]); + break; + default: + break; + } + } + fflush(G_traceFilePtr); + + retval = OSAPI_Mutex_give(G_logLock); + IGNORE_RETVAL(retval); + +done: + return; + + +} + + +bool +LogTraceHandlers_Initialize(const char *fileNamePrefix) +{ + bool result = false; + RTI_BOOL retval; + const char *templ = "XXXXXX"; +#define MAX_FILENAME_LEN (50) + char tmpFileName[MAX_FILENAME_LEN]; + int remainder = MAX_FILENAME_LEN; + + /* Instantiate lock */ + G_logLock = OSAPI_Mutex_new(); + if (NULL == G_logLock) { + printf("Failed to create mutex to protect log and trace handlers\n"); + goto done; + } + + retval = OSAPI_Mutex_take(G_logLock); + if (!retval) { + printf("Failed to take mutex\n"); + goto done; + } + /* Open file */ + if (NULL == fileNamePrefix) { + fileNamePrefix = "log"; + } + strncpy(tmpFileName, fileNamePrefix, remainder); + remainder -= strlen(fileNamePrefix); + strncat(tmpFileName, templ, remainder); + mkstemp(tmpFileName); + + if ('\0' != *tmpFileName) { + G_traceFilePtr = fopen(tmpFileName, "w"); + if (NULL == G_traceFilePtr) { + printf("Failed to open file \"%s\" for trace output, using stdout\n", + tmpFileName); + } else { + printf("Opened file \"%s\" for trace output\n", + tmpFileName); + } + } + if (NULL == G_traceFilePtr) { + G_traceFilePtr = stdout; + } + + /* Uncomment to increase verbosity level: */ + OSAPI_Log_set_verbosity(OSAPI_LOG_VERBOSITY_DEBUG); + retval = OSAPI_Log_set_display_handler(helloworld_display_handler, NULL); + if (RTI_TRUE != retval) { + printf("Failed to install display handler\n"); + goto done_locked; + } + +#if 0 + OSAPI_Trace_set_trace_mask(0xffffffff); + retval = OSAPI_Log_set_trace_handler(helloworld_trace_handler, NULL); + if (RTI_TRUE != retval) { + printf("Failed to install display handler\n"); + goto done_locked; + } +#endif + + result = true; + +done_locked: + retval = OSAPI_Mutex_give(G_logLock); + IGNORE_RETVAL(retval); + done: + return result; +} + + +bool +LogTraceHandlers_Finalize(void) +{ + bool result = false; + RTI_BOOL retval; + + /* Finalize logging */ + retval = OSAPI_Log_finalize(); + IGNORE_RETVAL(retval); + + /* Finalize system */ + retval = OSAPI_System_finalize(); + IGNORE_RETVAL(retval); + + /* Destroy mutex */ + if (NULL != G_logLock) { + retval = OSAPI_Mutex_delete(G_logLock); + IGNORE_RETVAL(retval); + G_logLock = NULL; + } + + /* Close file, if needed */ + if (NULL != G_traceFilePtr) { + fclose(G_traceFilePtr); + } + + /* Destroy lock, if needed */ + + result = true; + + return result; +} diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_log_trace_handlers.h b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_log_trace_handlers.h new file mode 100644 index 00000000..5763afe1 --- /dev/null +++ b/VideoData/ExampleCode/src/CommonInfrastructure/connext_micro/connext_micro_log_trace_handlers.h @@ -0,0 +1,9 @@ +#ifndef LogTraceHandlers_h +#define LogTraceHandlers_h + +#include "osapi/osapi_types.h" + +bool LogTraceHandlers_Initialize(const char *fileNamePrefix); +bool LogTraceHandlers_Finalize(void); + +#endif /* LogTraceHandlers_h */ diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/connext_pro/connext_cpp_common.h b/VideoData/ExampleCode/src/CommonInfrastructure/connext_pro/connext_cpp_common.h new file mode 100644 index 00000000..b0255605 --- /dev/null +++ b/VideoData/ExampleCode/src/CommonInfrastructure/connext_pro/connext_cpp_common.h @@ -0,0 +1,142 @@ +#ifndef CONNEXT_CPP_COMMON_H +#define CONNEXT_CPP_COMMON_H + +/* Pro versions of Connext-specific includes */ + +#if defined(_WIN32) + #if !defined(RTI_WIN32) + #define RTI_WIN32 + #endif + #if !defined(NDDS_DLL_VARIABLE) + #define NDDS_DLL_VARIABLE + #endif + #ifdef _DEBUG + #pragma comment( lib, "nddscppd.lib") + #pragma comment( lib, "nddscd.lib") + #pragma comment( lib, "nddscored.lib") + #else + #pragma comment( lib, "nddscpp.lib") + #pragma comment( lib, "nddsc.lib") + #pragma comment( lib, "nddscore.lib") + #endif /* #ifdef _DEBUG */ +#endif /* defined(_WIN32) */ + +/* DDS C++ headers */ +#include "ndds/ndds_cpp.h" +#include "ndds/ndds_namespace_cpp.h" + +/* DDS generated code headers */ +#include "VideoData.h" +#include "VideoDataSupport.h" + +#define CONNEXT_HAS_BUILTINTOPICS (1) +#define CONNEXT_HAS_USERDATA (1) +#define VIDEODATA_MATCH_EMPTY_USERDATA (1) + +/* Since Connext Micro does not support XML QoS profiles, we need to provide + functions that abstract the functionality */ + +#include +#include + +namespace Connext { + +/* Return type to hide the different return types */ +const DDS::ReturnCode_t TYPESUPPORT_OK = DDS::RETCODE_OK; + +/* Encapsulating the sleep utility */ +inline void sleep(long seconds, unsigned long nano_seconds) { +/* macOS (Sierra) behaves differently, NDDSUtility::sleep does not work */ +#ifdef __APPLE__ + struct timespec ts; + ts.tv_sec = seconds; + ts.tv_nsec = nano_seconds; + nanosleep(&ts, NULL); +#else + DDS_Duration_t duration; + duration.sec = seconds; + duration.nanosec = nano_seconds; + NDDSUtility::sleep(duration); +#endif +} + +/* Convenience function for setting profiles files in the ParticipantFactory */ + +inline DDS::ReturnCode_t +set_url_profile( + std::vector fileNames) +{ + DDS::DomainParticipantFactoryQos factoryQos; + TheParticipantFactory->get_qos(factoryQos); + factoryQos.profile.url_profile.ensure_length(fileNames.size(), + fileNames.size()); + + for (unsigned int i = 0; i < fileNames.size(); i++) { + // Note that we copy the file names here, so they cannot go out of + // scope + factoryQos.profile.url_profile[i] = DDS_String_dup( + fileNames[i].c_str()); + } + + return TheParticipantFactory->set_qos(factoryQos); +} + + +/* Convenience function for setting profiles files in the ParticipantFactory */ + +inline DDS::ReturnCode_t +initialize_infrastructure(const std::string &interface_name) +{ + return DDS::RETCODE_OK; +} + +/* Functions that are equivalent to the member functions on ParticipantFactory */ + +inline DDS::ReturnCode_t +get_participant_qos_from_profile( + DDS::DomainParticipantQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + return TheParticipantFactory->get_participant_qos_from_profile( + qos, library_name.c_str(), profile_name.c_str()); +} + +inline DDS::ReturnCode_t +get_subscriber_qos_from_profile( + DDS::SubscriberQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + return TheParticipantFactory->get_subscriber_qos_from_profile( + qos, library_name.c_str(), profile_name.c_str()); +} + +inline DDS::ReturnCode_t +get_datareader_qos_from_profile( + DDS::DataReaderQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + return TheParticipantFactory->get_datareader_qos_from_profile( + qos, library_name.c_str(), profile_name.c_str()); +} + +inline DDS::ReturnCode_t +get_publisher_qos_from_profile( + DDS::PublisherQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + return TheParticipantFactory->get_publisher_qos_from_profile( + qos, library_name.c_str(), profile_name.c_str()); +} + +inline DDS::ReturnCode_t +get_datawriter_qos_from_profile( + DDS::DataWriterQos &qos, + const std::string &library_name, const std::string &profile_name) +{ + return TheParticipantFactory->get_datawriter_qos_from_profile( + qos, library_name.c_str(), profile_name.c_str()); +} + +} + +#endif /* CONNEXT_CPP_COMMON_H */ diff --git a/VideoData/ExampleCode/src/CommonInfrastructure/simclist.h b/VideoData/ExampleCode/src/CommonInfrastructure/simclist.h index a92f606c..84dad587 100644 --- a/VideoData/ExampleCode/src/CommonInfrastructure/simclist.h +++ b/VideoData/ExampleCode/src/CommonInfrastructure/simclist.h @@ -34,7 +34,7 @@ extern "C" { #endif -#ifdef WIN32 +#ifdef _WIN32 #include #else #include @@ -50,16 +50,16 @@ extern "C" { # endif #endif - /* Be friend of both C90 and C99 compilers */ -#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L - /* "inline" and "restrict" are keywords */ -#else -# define inline /* inline */ -# define restrict /* restrict */ +#if (!defined(__STDC_VERSION__) || __STDC_VERSION__ < 199901L) && !defined(restrict) +# if defined(__GNUC__) && __GNUC__ >= 4 +# define restrict __restrict__ +# else +# define restrict +# define inline +# endif #endif - /** * Type representing list hashes. * diff --git a/VideoData/ExampleCode/src/Config/base_profile_multicast.xml b/VideoData/ExampleCode/src/Config/base_profile_multicast.xml index 7e1e738d..4cd347ad 100644 --- a/VideoData/ExampleCode/src/Config/base_profile_multicast.xml +++ b/VideoData/ExampleCode/src/Config/base_profile_multicast.xml @@ -30,20 +30,11 @@ RTI Connext user manual. throughput. --> - - 65507 - + + UDPv4 + - - - - dds.transport.UDPv4.builtin.parent.message_size_max - 65507 - - - - - dds.transport.shmem.builtin.parent.message_size_max - 65507 - - - - - dds.transport.shmem.builtin.receive_buffer_size - 2097152 - - - - - dds.transport.shmem.builtin.received_message_count_max - 2048 - - + diff --git a/VideoData/ExampleCode/src/Config/base_profile_no_multicast.xml b/VideoData/ExampleCode/src/Config/base_profile_no_multicast.xml index b6883a59..06fe8ddb 100644 --- a/VideoData/ExampleCode/src/Config/base_profile_no_multicast.xml +++ b/VideoData/ExampleCode/src/Config/base_profile_no_multicast.xml @@ -29,20 +29,11 @@ RTI Connext user manual. throughput. --> - - - 65507 - - + + UDPv4 + - - - - dds.transport.UDPv4.builtin.parent.message_size_max - 65507 - - - - - dds.transport.shmem.builtin.parent.message_size_max - 65507 - - - - - dds.transport.shmem.builtin.receive_buffer_size - 2097152 - - - - - dds.transport.shmem.builtin.received_message_count_max - 2048 - - + diff --git a/VideoData/ExampleCode/src/Config/video_stream_multicast.xml b/VideoData/ExampleCode/src/Config/video_stream_multicast.xml index 26f40553..cae418da 100644 --- a/VideoData/ExampleCode/src/Config/video_stream_multicast.xml +++ b/VideoData/ExampleCode/src/Config/video_stream_multicast.xml @@ -59,9 +59,9 @@ RTI Connext user manual. - + diff --git a/VideoData/ExampleCode/src/Config/video_stream_no_multicast.xml b/VideoData/ExampleCode/src/Config/video_stream_no_multicast.xml index e843253c..1a775627 100644 --- a/VideoData/ExampleCode/src/Config/video_stream_no_multicast.xml +++ b/VideoData/ExampleCode/src/Config/video_stream_no_multicast.xml @@ -60,9 +60,9 @@ RTI Connext user manual. - + diff --git a/VideoData/ExampleCode/src/Idl/VideoData.idl b/VideoData/ExampleCode/src/Idl/VideoData.idl index 2e671cf2..ab725647 100644 --- a/VideoData/ExampleCode/src/Idl/VideoData.idl +++ b/VideoData/ExampleCode/src/Idl/VideoData.idl @@ -2,7 +2,7 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. @@ -24,7 +24,9 @@ const string QOS_PROFILE_MULTICAST_DATA = "MulticastVideo"; // Data will be allocated at this size, but // only the actual size of the frame will // be sent. -const long MAX_BUFFER_SIZE = 1048576; + +/* const long MAX_BUFFER_SIZE = 1048576; */ +const long MAX_BUFFER_SIZE = 64000; struct VideoStream { diff --git a/VideoData/ExampleCode/src/VideoPublisher/VideoPublisher.cxx b/VideoData/ExampleCode/src/VideoPublisher/VideoPublisher.cxx index 5530ed33..f7ea2535 100644 --- a/VideoData/ExampleCode/src/VideoPublisher/VideoPublisher.cxx +++ b/VideoData/ExampleCode/src/VideoPublisher/VideoPublisher.cxx @@ -2,29 +2,31 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. **********************************************************************************************/ + #include #include #include -#include "../CommonInfrastructure/VideoSource.h" -#include "../Generated/VideoData.h" -#include "../Generated/VideoDataSupport.h" -#include "ndds/ndds_cpp.h" -#include "ndds/ndds_namespace_cpp.h" -#include "../CommonInfrastructure/DDSCommunicator.h" +#include "connext_cpp_common.h" + +#include "CommonInfrastructure/VideoSource.h" +#include "CommonInfrastructure/DDSCommunicator.h" +#include "CommonInfrastructure/OSAPI.h" + #include "VideoPublisherInterface.h" -#ifdef WIN32 +#ifdef _WIN32 #include #include "Shlwapi.h" -#endif +#endif /* _WIN32 */ using namespace std; +using namespace com::rti::media::generated; void PrintHelp(); @@ -132,9 +134,22 @@ class CodecCompatibilityCheck : public CodecCompatibleHandler // Calls the gstreamer framework to see if the subscribing app's codec // is compatible with what we are sending. If not, we return false. + // Note: this looks like a simple function but the implementation has + // a side-effect of setting a private member -- this should be improved virtual bool CodecsCompatible(std::string codecString) { - if (_source->IsMetadataCompatible(codecString)) + bool matches = false; +#if (VIDEODATA_MATCH_EMPTY_USERDATA == 1) + matches = codecString.empty() || _source->IsMetadataCompatible(codecString); + std::cout << "Matching compatibility: code was compiled to match with Subscribers without user_data" << std::endl; +#elif (VIDEODATA_MATCH_EMPTY_USERDATA == -1) + matches = _source->IsMetadataCompatible(codecString); + std::cout << "Matching compatibility: code was compiled to not match Subscribers without user_data" << std::endl; +#else /* VIDEODATA_MATCH_EMPTY_USERDATA */ +#error Incorrect setup: VIDEODATA_MATCH_EMPTY_USERDATA should be defined and have the value -1 or 1 +#endif /* VIDEODATA_MATCH_EMPTY_USERDATA */ + + if (matches) { _discoveredCompatibleReader = true; } @@ -196,23 +211,24 @@ int main (int argc, char *argv[]) { // Adding the XML files that contain profiles used by this application xmlFiles.push_back( - "file://../../../src/Config/base_profile_multicast.xml"); + "file://../../../../src/Config/base_profile_multicast.xml"); xmlFiles.push_back( - "file://../../../src/Config/video_stream_multicast.xml"); + "file://../../../../src/Config/video_stream_multicast.xml"); } else { // Adding the XML files that contain profiles used by this application xmlFiles.push_back( - "file://../../../src/Config/base_profile_no_multicast.xml"); + "file://../../../../src/Config/base_profile_no_multicast.xml"); xmlFiles.push_back( - "file://../../../src/Config/video_stream_no_multicast.xml"); + "file://../../../../src/Config/video_stream_no_multicast.xml"); } -#ifdef WIN32 +#ifdef _WIN32 char fullPath[512]; - std::string relativePath = "..\\..\\..\\resource\\bigbuck.webm"; + //std::string relativePath = "..\\..\\..\\..\\resource\\bigbuck.webm"; + std::string relativePath = "..\\..\\..\\..\\resource\\train.webm"; if (NULL == _fullpath(fullPath, relativePath.c_str(), 512)) { @@ -221,7 +237,8 @@ int main (int argc, char *argv[]) EMDSVideoSource *videoSource = new EMDSVideoSource( fullPath); #else - std::string relativePath = "../../../resource/bigbuck.webm"; + //std::string relativePath = "../../../../resource/bigbuck.webm"; + std::string relativePath = "../../../../resource/train.webm"; char fullPath[PATH_MAX]; if (NULL == realpath(relativePath.c_str(), fullPath)) { @@ -273,13 +290,14 @@ int main (int argc, char *argv[]) (void *)&videoInterface); // Wait for compatible DataReaders to come online +#if 0 while (!compatibilityCheck.DiscoveredCompatibleReader()) { - DDS_Duration_t send_period = {2,0}; cout << "Waiting for a compatible video subscriber to come " << "online" << endl; - NDDSUtility::sleep(send_period); + OSThread::Sleep(2,0); } +#endif // If we have found a compatible Video Subscriber, we start publishing. videoSource->Start(); @@ -287,8 +305,7 @@ int main (int argc, char *argv[]) // Loop forever here while (1) { - DDS_Duration_t send_period = {0,100000000}; - NDDSUtility::sleep(send_period); + OSThread::Sleep(0, 100000000); } } diff --git a/VideoData/ExampleCode/src/VideoPublisher/VideoPublisherInterface.cxx b/VideoData/ExampleCode/src/VideoPublisher/VideoPublisherInterface.cxx index 2a3bafca..a3d965ec 100644 --- a/VideoData/ExampleCode/src/VideoPublisher/VideoPublisherInterface.cxx +++ b/VideoData/ExampleCode/src/VideoPublisher/VideoPublisherInterface.cxx @@ -2,15 +2,15 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. **********************************************************************************************/ #include +#include "connext_cpp_common.h" #include "VideoPublisherInterface.h" - using namespace com::rti::media::generated; // ---------------------------------------------------------------------------- @@ -129,9 +129,11 @@ VideoPublisherInterface::VideoPublisherInterface( // decided by the DataReader, not the DataWriter) // Note that the QoS profile and QoS library names are constants that are // defined in the .idl file. - DDS::DataWriter *writer = pub->create_datawriter_with_profile(topic, - QOS_LIBRARY, QOS_PROFILE_STREAMING_DATA, - NULL, DDS_STATUS_MASK_NONE); + DDS::DataWriterQos writer_qos; + Connext::get_datawriter_qos_from_profile(writer_qos, + QOS_LIBRARY, QOS_PROFILE_STREAMING_DATA); + DDS::DataWriter *writer = pub->create_datawriter(topic, + writer_qos, NULL, DDS_STATUS_MASK_NONE); // Downcast the generic datawriter to a video stream DataWriter _writer = VideoStreamDataWriter::narrow(writer); @@ -175,8 +177,8 @@ bool VideoPublisherInterface::Write(DdsAutoType data) return false; } -/* cout << "Writing sample #" << data.equence_number - << ", length: " << data.frame.length() << endl;*/ + /* std::cout << "Writing sample #" << data.sequence_number + << ", length: " << data.frame.length() << std::endl; */ return true; @@ -224,6 +226,7 @@ void VideoPublisherDiscoveryListener::on_data_available(DDSDataReader *reader) // Cast the DataReader passed into this callback to a // "SubscriptionBuiltinTopicDataDataReader" that gets notifications about // remote DataReaders. +#if (CONNEXT_HAS_BUILTINTOPICS == 1) DDS::SubscriptionBuiltinTopicDataDataReader *builtin_reader = (DDS::SubscriptionBuiltinTopicDataDataReader*) reader; DDS_SubscriptionBuiltinTopicDataSeq data_seq; @@ -286,8 +289,10 @@ void VideoPublisherDiscoveryListener::on_data_available(DDSDataReader *reader) // infrastructure) to find out if the remote codec is compatible // with the codecs this application is publishing. isCompatible = _handler->CodecsCompatible(readerData); - - } + } else { + std::cout << "Found subscriber with no user_data" << std::endl; + isCompatible = _handler->CodecsCompatible(""); + } if (!isCompatible) { @@ -311,6 +316,19 @@ void VideoPublisherDiscoveryListener::on_data_available(DDSDataReader *reader) // empty sequence to the take() call. This is more efficient than // copying the data into a local buffer. builtin_reader->return_loan(data_seq, info_seq); +#elif (CONNEXT_HAS_BUILTINTOPICS == -1) +#if (VIDEODATA_MATCH_EMPTY_USERDATA == 1) + /* Need to invoke compatibility check to make sure internal state of _handler gets updated + (this is due to a side-effect in the method CodecsCompatible()) */ + _handler->CodecsCompatible(std::string("")); +#elif (VIDEODATA_MATCH_EMPTY_USERDATA == -1) +#else /* VIDEODATA_MATCH_EMPTY_USERDATA */ + #error Incorrect setup: VIDEODATA_MATCH_EMPTY_USERDATA should be defined and have the value -1 or 1 +#endif /* VIDEODATA_MATCH_EMPTY_USERDATA */ +#else /* CONNEXT_HAS_BUILTINTOPICS */ + #error Incorrect setup: CONNEXT_HAS_BUILTINTOPIC should be defined and have the value -1 or 1 +#endif /* CONNEXT_HAS_BUILTINTOPICS */ + } diff --git a/VideoData/ExampleCode/src/VideoPublisher/VideoPublisherInterface.h b/VideoData/ExampleCode/src/VideoPublisher/VideoPublisherInterface.h index 59501d2c..062c9021 100644 --- a/VideoData/ExampleCode/src/VideoPublisher/VideoPublisherInterface.h +++ b/VideoData/ExampleCode/src/VideoPublisher/VideoPublisherInterface.h @@ -2,7 +2,7 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. @@ -12,12 +12,9 @@ damages arising out of the use or inability to use the software. #define VIDEO_PUBLISHER_INTERFACE_H #include -#include "../CommonInfrastructure/DDSCommunicator.h" -#include "../CommonInfrastructure/DDSTypeWrapper.h" -#include "../Generated/VideoData.h" -#include "../Generated/VideoDataSupport.h" - -using namespace com::rti::media::generated; +#include "connext_cpp_common.h" +#include "CommonInfrastructure/DDSCommunicator.h" +#include "CommonInfrastructure/DDSTypeWrapper.h" class VideoPublisherDiscoveryListener; class CodecCompatibleHandler; @@ -68,12 +65,12 @@ class VideoPublisherInterface // Uses DDS interface to send a video stream efficiently over the // network or shared memory to interested applications subscribing to // streaming video. - bool Write(DdsAutoType data); + bool Write(DdsAutoType data); // --- Deletes the video stream --- // "Deletes" the video stream from the system - removing the DDS // instance from all applications. - bool Delete(DdsAutoType data); + bool Delete(DdsAutoType data); private: // --- Private members --- @@ -82,7 +79,7 @@ class VideoPublisherInterface DDSCommunicator *_communicator; // Video stream publisher specific to this application - VideoStreamDataWriter *_writer; + com::rti::media::generated::VideoStreamDataWriter *_writer; }; diff --git a/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriber.cxx b/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriber.cxx index 4331a6e1..b1f7f9bf 100644 --- a/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriber.cxx +++ b/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriber.cxx @@ -2,7 +2,7 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. @@ -14,13 +14,11 @@ damages arising out of the use or inability to use the software. #include #include -#include "ndds/ndds_cpp.h" -#include "ndds/ndds_namespace_cpp.h" -#include "../CommonInfrastructure/DDSCommunicator.h" -#include "../Generated/VideoData.h" -#include "../Generated/VideoDataSupport.h" -#include "../CommonInfrastructure/VideoBuffer.h" -#include "../CommonInfrastructure/VideoOutput.h" +#include "connext_cpp_common.h" +#include "CommonInfrastructure/DDSCommunicator.h" +#include "CommonInfrastructure/VideoBuffer.h" +#include "CommonInfrastructure/VideoOutput.h" +#include "CommonInfrastructure/OSAPI.h" #include "VideoSubscriberInterface.h" @@ -147,17 +145,17 @@ int main (int argc, char *argv[]) { // Adding the XML files that contain profiles used by this application xmlFiles.push_back( - "file://../../../src/Config/base_profile_multicast.xml"); + "file://../../../../src/Config/base_profile_multicast.xml"); xmlFiles.push_back( - "file://../../../src/Config/video_stream_multicast.xml"); + "file://../../../../src/Config/video_stream_multicast.xml"); } else { // Adding the XML files that contain profiles used by this application xmlFiles.push_back( - "file://../../../src/Config/base_profile_no_multicast.xml"); + "file://../../../../src/Config/base_profile_no_multicast.xml"); xmlFiles.push_back( - "file://../../../src/Config/video_stream_no_multicast.xml"); + "file://../../../../src/Config/video_stream_no_multicast.xml"); } try @@ -196,8 +194,7 @@ int main (int argc, char *argv[]) // Continue while the video is not finished. while (!isDone) { - DDS_Duration_t send_period = {0,100000000}; - NDDSUtility::sleep(send_period); + OSThread::Sleep(0, 100000000); } } catch (string message) diff --git a/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriberInterface.cxx b/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriberInterface.cxx index 23ad1eeb..9fd7743d 100644 --- a/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriberInterface.cxx +++ b/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriberInterface.cxx @@ -2,7 +2,7 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. @@ -11,10 +11,9 @@ damages arising out of the use or inability to use the software. #include #include #include -#include "../Generated/VideoData.h" -#include "../Generated/VideoDataSupport.h" +#include "connext_cpp_common.h" #include "VideoSubscriberInterface.h" -#include "../CommonInfrastructure/VideoBuffer.h" +#include "CommonInfrastructure/VideoBuffer.h" using namespace DDS; using namespace com::rti::media::generated; @@ -87,8 +86,7 @@ VideoSubscriberInterface::VideoSubscriberInterface( // on what the DomainParticipant is responsible for, and how to configure // it, see the DDSCommunicator class. if (NULL == _communicator->CreateParticipant(0, qosFileNames, - QOS_LIBRARY, - profileName.c_str())) + QOS_LIBRARY, profileName.c_str())) { std::stringstream errss; errss << "Failed to create DomainParticipant object"; @@ -169,7 +167,8 @@ void VideoStreamListener::on_data_available(DataReader *reader) while (retCode != DDS_RETCODE_NO_DATA) { - retCode = videoReader->take(dataSeq, infoSeq); + retCode = videoReader->take(dataSeq, infoSeq, DDS::LENGTH_UNLIMITED, + DDS::ANY_SAMPLE_STATE, DDS::ANY_VIEW_STATE, DDS::ANY_INSTANCE_STATE); if ((retCode != DDS_RETCODE_OK) && (retCode != DDS_RETCODE_NO_DATA)) @@ -182,13 +181,21 @@ void VideoStreamListener::on_data_available(DataReader *reader) { if (infoSeq[i].valid_data == DDS_BOOLEAN_TRUE) { - if ((infoSeq[i].publication_sequence_number.low % 50) == 1) { - std::cout << ". "; + std::cout << ". " << std::flush; } + if (0 != _last_seq_nr) { + if (infoSeq[i].publication_sequence_number.low != _last_seq_nr + 1) { + std::cout << "Missed seqnr(s): previous was " << _last_seq_nr << ", current is " << infoSeq[i].publication_sequence_number.low << std::endl; + } + } + //std::cout << dataSeq[i].sequence_number << ": " << dataSeq[i].frame.length() << " bytes in frame" << std::endl; + + _last_seq_nr = infoSeq[i].publication_sequence_number.low; + double timestamp = infoSeq[i].source_timestamp.sec + (infoSeq[i].source_timestamp.nanosec / NANOSEC_TO_SEC); @@ -263,20 +270,35 @@ VideoStreamReader::VideoStreamReader( // it can provide video that supports the same video codecs that are // supported by the subscribing application. If they share compatible // codecs, it will start publishing video data. - DDS_DataReaderQos readerQoS; - DDS_ReturnCode_t retcode = - TheParticipantFactory->get_datareader_qos_from_profile(readerQoS, - qosLibrary.c_str(), qosProfile.c_str()); - - readerQoS.user_data.value.from_array( + DDS::DataReaderQos reader_qos; + if (!(qosLibrary.empty() && qosProfile.empty())) { + DDS_ReturnCode_t retcode = + Connext::get_datareader_qos_from_profile(reader_qos, + qosLibrary, qosProfile); + if (retcode != DDS::RETCODE_OK) { + std::stringstream errss; + errss << "Failed to get DataReaderQos from profile"; + throw errss.str(); + } + } else { + reader_qos = DDS::DATAREADER_QOS_DEFAULT; + } + +#if (CONNEXT_HAS_USERDATA == 1) + reader_qos.user_data.value.from_array( reinterpret_cast(videoMetadata.c_str()), videoMetadata.length()); +#elif (CONNEXT_HAS_USERDATA == -1) + /* Deliberately empty line */ +#else /*CONNEXT_HAS_USERDATA */ + #error Incorrect setup: macro CONNEXT_HAS_USERDATA should be defined and have value -1 or 1 +#endif /*CONNEXT_HAS_USERDATA */ // Creating a DataReader // This DataReader will receive the video data, and will store it in its // queue, to be retrieved by listener in the on_data_available callback - DataReader *reader = sub->create_datareader(topic, - readerQoS, _listener, DDS_DATA_AVAILABLE_STATUS); + DataReader *reader = sub->create_datareader(topic, + reader_qos, _listener, DDS_DATA_AVAILABLE_STATUS); if (reader == NULL) { std::stringstream errss; @@ -295,7 +317,7 @@ VideoStreamReader::VideoStreamReader( VideoStreamReader::~VideoStreamReader() { - _reader->delete_contained_entities(); + /* _reader->delete_contained_entities(); */ Subscriber *sub = _reader->get_subscriber(); sub->delete_datareader(_reader); diff --git a/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriberInterface.h b/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriberInterface.h index 9ab837a6..1a5a42ea 100644 --- a/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriberInterface.h +++ b/VideoData/ExampleCode/src/VideoSubscriber/VideoSubscriberInterface.h @@ -2,7 +2,7 @@ (c) 2005-2013 Copyright, Real-Time Innovations, Inc. All rights reserved. RTI grants Licensee a license to use, modify, compile, and create derivative works of the Software. Licensee has the right to distribute object form only for use with RTI -products. The Software is provided “as is”, with no warranty of any type, including +products. The Software is provided �as is�, with no warranty of any type, including any warranty for fitness for any purpose. RTI is under no obligation to maintain or support the Software. RTI shall not be liable for any incidental or consequential damages arising out of the use or inability to use the software. @@ -10,14 +10,10 @@ damages arising out of the use or inability to use the software. #ifndef VIDEO_SUBSCRIBER_INTERFACE_H #define VIDEO_SUBSCRIBER_INTERFACE_H - -#include "ndds/ndds_cpp.h" -#include "ndds/ndds_namespace_cpp.h" -#include "../CommonInfrastructure/DDSCommunicator.h" -#include "../Generated/VideoData.h" -#include "../Generated/VideoDataSupport.h" -#include "../CommonInfrastructure/DDSTypeWrapper.h" -#include "../CommonInfrastructure/VideoBuffer.h" +#include "connext_cpp_common.h" +#include "CommonInfrastructure/DDSCommunicator.h" +#include "CommonInfrastructure/DDSTypeWrapper.h" +#include "CommonInfrastructure/VideoBuffer.h" #include @@ -140,7 +136,7 @@ class VideoStreamListener : public DDS::DataReaderListener // --- Constructor --- VideoStreamListener(VideoStreamReader *reader) : - _reader(reader) + _reader(reader), _last_seq_nr(0) { } @@ -153,6 +149,7 @@ class VideoStreamListener : public DDS::DataReaderListener private: VideoStreamReader *_reader; + unsigned int _last_seq_nr; }; // ------------------------------------------------------------------------- // diff --git a/VideoData/README.txt b/VideoData/README.txt index b0e4550d..9af5b1b1 100644 --- a/VideoData/README.txt +++ b/VideoData/README.txt @@ -61,7 +61,7 @@ Linux Systems To build the applications on a Linux system, change directories to the ExampleCode directory and use the command: -gmake –f make/Makefile. +gmake -f make/Makefile. The platform you choose will be the combination of your processor, OS, and compiler version. Right now this example only supports i86Linux2.6gcc4.5.5