Compare commits
25 Commits
R3.15.0.1
...
R3.14.12.3
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1f573172b3 | ||
|
|
d6f72900f8 | ||
|
|
5b1d3a7725 | ||
|
|
7d79a83519 | ||
|
|
6fd9fb3066 | ||
|
|
28c7fe12f3 | ||
|
|
36be0aa783 | ||
|
|
69d8be78d3 | ||
|
|
fc61cc34ce | ||
|
|
e889336458 | ||
|
|
7cac267a4b | ||
|
|
71079ede4b | ||
|
|
26173c1e0d | ||
|
|
9c1b8ba952 | ||
|
|
c574722a9b | ||
|
|
4790578953 | ||
|
|
7e6e38060f | ||
|
|
709b6ef2f3 | ||
|
|
169b30081a | ||
|
|
a19e1d21da | ||
|
|
1ac8ff6378 | ||
|
|
5c2ef73c4a | ||
|
|
958aa02320 | ||
|
|
c93c7b5e36 | ||
|
|
b993e29fad |
@@ -1,5 +1,5 @@
|
||||
#*************************************************************************
|
||||
# Copyright (c) 2011 UChicago Argonne LLC, as Operator of Argonne
|
||||
# Copyright (c) 2012 UChicago Argonne LLC, as Operator of Argonne
|
||||
# National Laboratory.
|
||||
# Copyright (c) 2002 The Regents of the University of California, as
|
||||
# Operator of Los Alamos National Laboratory.
|
||||
@@ -30,11 +30,11 @@ EPICS_MODIFICATION = 12
|
||||
|
||||
# EPICS_PATCH_LEVEL must be a number (win32 resource file requirement)
|
||||
# Not included if zero
|
||||
EPICS_PATCH_LEVEL = 2
|
||||
EPICS_PATCH_LEVEL = 3
|
||||
|
||||
# This will end in -DEV between official releases
|
||||
EPICS_DEV_SNAPSHOT=-DEV
|
||||
#EPICS_DEV_SNAPSHOT=-pre1
|
||||
#EPICS_DEV_SNAPSHOT=-DEV
|
||||
EPICS_DEV_SNAPSHOT=-pre1
|
||||
#EPICS_DEV_SNAPSHOT=-pre1-DEV
|
||||
#EPICS_DEV_SNAPSHOT=-pre2
|
||||
#EPICS_DEV_SNAPSHOT=-pre2-DEV
|
||||
|
||||
@@ -322,10 +322,10 @@ $(OBJLIB_MUNCHNAME):%.munch : %_ctdt$(OBJ) %$(OBJ)
|
||||
@$(RM) $@
|
||||
$(MUNCH_CMD)
|
||||
|
||||
runtests: $(TESTSCRIPTS_$(BUILD_CLASS))
|
||||
runtests: $(TESTSCRIPTS)
|
||||
-$(PERL) -MTest::Harness -e 'runtests @ARGV if @ARGV;' $^
|
||||
|
||||
testspec: $(TESTSCRIPTS_$(BUILD_CLASS))
|
||||
testspec: $(TESTSCRIPTS)
|
||||
@$(RM) $@
|
||||
@echo OS-class: $(OS_CLASS) > $@
|
||||
@echo Target-arch: $(T_A) >> $@
|
||||
|
||||
@@ -20,8 +20,8 @@ OBJ = .o
|
||||
LIB_PREFIX = lib
|
||||
LIB_SUFFIX = .a
|
||||
SHRLIB_SUFFIX_BASE = .so
|
||||
SHRLIB_SUFFIX = $(SHRLIB_SUFFIX_BASE).$(SHRLIB_VERSION)
|
||||
LOADABLE_SHRLIB_SUFFIX = $(SHRLIB_SUFFIX_BASE).$(LOADABLE_SHRLIB_VERSION)
|
||||
SHRLIB_SUFFIX = $(SHRLIB_SUFFIX_BASE)$(addprefix .,$(SHRLIB_VERSION))
|
||||
LOADABLE_SHRLIB_SUFFIX = $(SHRLIB_SUFFIX_BASE)$(addprefix .,$(LOADABLE_SHRLIB_VERSION))
|
||||
LOADABLE_SHRLIB_PREFIX = lib
|
||||
|
||||
#-------------------------------------------------------
|
||||
|
||||
@@ -41,6 +41,7 @@ ARCH_DEP_LDFLAGS += $(ARCH_DEP_FLAGS)
|
||||
#--------------------------------------------------
|
||||
# Operating system flags
|
||||
OP_SYS_CFLAGS += -isysroot $(SDK_DIR) -D__IPHONE_OS_VERSION_MIN_REQUIRED=30200
|
||||
OP_SYS_LDFLAGS += -isysroot $(SDK_DIR)
|
||||
|
||||
#--------------------------------------------------
|
||||
# Always compile in debugging symbol table information
|
||||
@@ -53,13 +54,15 @@ OPT_CXXFLAGS_YES += -g
|
||||
|
||||
CC_GNU = gcc
|
||||
CCC_GNU = g++
|
||||
CC_LLVM = llvm-gcc
|
||||
CCC_LLVM = llvm-g++
|
||||
|
||||
CC_LLVM_GNU = llvm-gcc
|
||||
CCC_LLVM_GNU = llvm-g++
|
||||
|
||||
CC_CLANG = clang
|
||||
CCC_CLANG = clang++
|
||||
|
||||
CC = $(firstword $(wildcard $(GNU_BIN)/$(CC_$(COMPILER))) $(CC_$(COMPILER)))
|
||||
CCC = $(firstword $(wildcard $(GNU_BIN)/$(CCC_$(COMPILER))) $(CCC_$(COMPILER)))
|
||||
# Convert the iOS platform to lowercase for passing to xcrun's sdk parameter
|
||||
XCRUN_SDK_BASE = $(shell echo $(IOS_PLATFORM) | tr A-Z a-z)
|
||||
|
||||
#-------------------------------------------------------
|
||||
# Linker flags
|
||||
@@ -70,7 +73,7 @@ OP_SYS_LDFLAGS += -dynamic -Z -L$(SDK_DIR)/usr/lib -L$(SDK_DIR)/usr/lib/system
|
||||
# Shared libraries
|
||||
SHRLIB_VERSION = $(EPICS_VERSION).$(EPICS_REVISION).$(EPICS_MODIFICATION)
|
||||
SHRLIB_LDFLAGS = -dynamiclib -flat_namespace -undefined suppress \
|
||||
-install_name $(shell perl $(TOOLS)/fullPathName.pl $(INSTALL_LIB))/$@ \
|
||||
-install_name $(shell $(PERL) $(TOOLS)/fullPathName.pl $(INSTALL_LIB))/$@ \
|
||||
-compatibility_version $(EPICS_VERSION).$(EPICS_REVISION) \
|
||||
-current_version $(SHRLIB_VERSION)
|
||||
SHRLIB_SUFFIX_BASE = .dylib
|
||||
@@ -93,13 +96,14 @@ vpath %.m $(USR_VPATH) $(ALL_SRC_DIRS)
|
||||
#--------------------------------------------------
|
||||
# Header dependency file generation
|
||||
#
|
||||
# Use compiler when ARCH_CLASS is a single arch value
|
||||
# otherwise use perl script command
|
||||
SINGLE_ARCH=$(filter 1,$(words $(ARCH_CLASS)))
|
||||
HDEPENDS_CFLAGS = $(if $(SINGLE_ARCH),$(HDEPENDS_CFLAGS_$(HDEPENDS)))
|
||||
HDEPENDS_METHOD = $(if $(SINGLE_ARCH),CFLAGS,CMD)
|
||||
HDEPENDS_METHOD = CMD
|
||||
|
||||
#--------------------------------------------------
|
||||
# Allow site overrides
|
||||
-include $(CONFIG)/os/CONFIG_SITE.Common.iosCommon
|
||||
-include $(CONFIG)/os/CONFIG_SITE.$(EPICS_HOST_ARCH).iosCommon
|
||||
|
||||
#--------------------------------------------------
|
||||
# Find the Xcode compilers for the specified SDK just once
|
||||
CC := $(shell xcrun -sdk $(XCRUN_SDK_BASE) -find $(CC_$(COMPILER)))
|
||||
CCC := $(shell xcrun -sdk $(XCRUN_SDK_BASE) -find $(CCC_$(COMPILER)))
|
||||
|
||||
@@ -17,7 +17,7 @@ ifeq ($(BUILD_CLASS),CROSS)
|
||||
|
||||
# prefix of compiler tools
|
||||
CMPLR_SUFFIX =
|
||||
CMPLR_PREFIX = $(GNU_TARGET)-
|
||||
CMPLR_PREFIX = $(addsuffix -,$(GNU_TARGET))
|
||||
|
||||
# Provide a link-time path for shared libraries
|
||||
SHRLIBDIR_RPATH_LDFLAGS_YES += $(SHRLIB_DEPLIB_DIRS:%=-Wl,-rpath-link,%)
|
||||
|
||||
@@ -67,7 +67,7 @@ CCC = $(GNU_BIN)/c++
|
||||
#
|
||||
SHRLIB_VERSION = $(EPICS_VERSION).$(EPICS_REVISION).$(EPICS_MODIFICATION)
|
||||
SHRLIB_LDFLAGS = -dynamiclib -flat_namespace -undefined suppress \
|
||||
-install_name $(shell perl $(TOOLS)/fullPathName.pl $(INSTALL_LIB))/$@ \
|
||||
-install_name $(shell $(PERL) $(TOOLS)/fullPathName.pl $(INSTALL_LIB))/$@ \
|
||||
-compatibility_version $(EPICS_VERSION).$(EPICS_REVISION) \
|
||||
-current_version $(SHRLIB_VERSION)
|
||||
SHRLIB_SUFFIX_BASE = .dylib
|
||||
|
||||
@@ -7,17 +7,31 @@
|
||||
#-------------------------------------------------------
|
||||
|
||||
# Select which CPU architecture(s) to include in your MacOS binaries:
|
||||
# i386
|
||||
# x86_64 - Needs MacOS 10.4 with the Universal SDK, or 10.5 and later
|
||||
# i386, x86_64, or both (fat binaries).
|
||||
|
||||
ARCH_CLASS = i386
|
||||
#ARCH_CLASS = x86_64
|
||||
#ARCH_CLASS = i386
|
||||
ARCH_CLASS = x86_64
|
||||
#ARCH_CLASS = i386 x86_64
|
||||
|
||||
#
|
||||
# Uncomment the followings lines to build with CLANG instead of GCC.
|
||||
# Comment out the following 3 lines to build with Apple's GCC instead of CLANG.
|
||||
#
|
||||
#CC = clang
|
||||
#CCC = clang++
|
||||
#GNU_LDLIBS_YES =
|
||||
CC = clang
|
||||
CCC = clang++
|
||||
GNU = NO
|
||||
|
||||
|
||||
# To use MacPorts GCC, comment out ALL the settings above this line,
|
||||
# then uncomment (and modify if necessary) the following instead:
|
||||
|
||||
#GNU_DIR = /opt/local
|
||||
#CC = $(GNU_BIN)/gcc -m64
|
||||
#CCC = $(GNU_BIN)/g++ -m64
|
||||
|
||||
# If you see this or similar errors while building in the src/cap5 directory
|
||||
# gcc: error: unrecognized option '-no-cpp-precomp'
|
||||
# the problem is due to the ccflags configuration that your version of Perl
|
||||
# was built with. You can replace the Cap5_CFLAGS setting in the Makefile
|
||||
# with a hand-edited set of flags for building that Perl library, or ignore
|
||||
# this problem if you don't need to use Channel Access from Perl.
|
||||
|
||||
|
||||
@@ -1,21 +1,26 @@
|
||||
# CONFIG_SITE.Common.ios-arm
|
||||
#
|
||||
# $Revision-Id$
|
||||
# This file is maintained by the build community.
|
||||
#
|
||||
# Site-specific settings for ios-arm target builds
|
||||
#-------------------------------------------------------
|
||||
|
||||
# Which ARM instruction set(s) to generate code for:
|
||||
# Most iOS devices can run programs compiled for both the
|
||||
# ARMv6 and ARMv7 instruction sets. ARMv7 code is usually
|
||||
# more efficient, but the older devices listed below can only
|
||||
# use the ARMv6 instruction set. Including both architectures
|
||||
# generates a Universal binary, which is larger and takes
|
||||
# longer to compile but runs efficiently on all devices.
|
||||
# Most iOS devices can run programs compiled for older
|
||||
# instruction sets, although the newer instructions are
|
||||
# more efficient.
|
||||
#
|
||||
# ARMv6-only devices: iPhone 1 or 3G, iPod Touch Gen 1 or 2
|
||||
# Apple's compilers can build for multiple architectures,
|
||||
# generating a Universal binary. This is larger and takes
|
||||
# longer to compile, but runs efficiently on all devices.
|
||||
#
|
||||
ARCH_CLASS = armv7
|
||||
# Xcode 4.5 dropped support for the ARMv6.
|
||||
#
|
||||
# ARMv7s devices: iPhone 5
|
||||
# ARMv6 devices: iPhone 1 and 3G, iPod Touch Gen 1 and 2
|
||||
# All other devices are ARMv7
|
||||
|
||||
ARCH_CLASS = armv7 armv7s
|
||||
#ARCH_CLASS = armv7
|
||||
#ARCH_CLASS = armv6 armv7
|
||||
#ARCH_CLASS = armv6
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
# CONFIG_SITE.Common.iosCommon
|
||||
#
|
||||
# $Revision-Id$
|
||||
# This file is maintained by the build community.
|
||||
#
|
||||
# Site-specific settings for Apple iOS builds
|
||||
#-------------------------------------------------------
|
||||
@@ -12,16 +11,18 @@
|
||||
#IOS_VERSION = 4.1
|
||||
#IOS_VERSION = 4.2
|
||||
#IOS_VERSION = 4.3
|
||||
IOS_VERSION = 5.0
|
||||
#IOS_VERSION = 5.0
|
||||
#IOS_VERSION = 5.1
|
||||
IOS_VERSION = 6.0
|
||||
|
||||
|
||||
# Which compiler to use:
|
||||
# CLANG is preferred for recent versions of Xcode
|
||||
# LLVM uses the llvm-gcc and llvm-g++ compilers
|
||||
# LLVM_GNU uses the llvm-gcc and llvm-g++ compilers
|
||||
# GNU is needed for older versions of Xcode
|
||||
|
||||
COMPILER = CLANG
|
||||
#COMPILER = LLVM
|
||||
#COMPILER = LLVM_GNU
|
||||
#COMPILER = GNU
|
||||
|
||||
|
||||
|
||||
@@ -3,16 +3,38 @@
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1">
|
||||
<title>EPICS Base R3.14.12.2-DEV Release Notes</title>
|
||||
<title>EPICS Base R3.14.12.3-pre1 Release Notes</title>
|
||||
</head>
|
||||
|
||||
<body lang="en">
|
||||
<h1 align="center">EPICS Base Release 3.14.12.2-DEV</h1>
|
||||
<h1 align="center">EPICS Base Release 3.14.12.3-pre1</h1>
|
||||
|
||||
<h2 align="center">Changes between 3.14.12.2 and 3.14.12.3</h2>
|
||||
|
||||
<!-- Insert new items immediately below here ... -->
|
||||
|
||||
<h4>Array Subroutine (aSub) record type fixes</h4>
|
||||
|
||||
<ul>
|
||||
<li>Changing the number of valid elements in a VALx field now triggers
|
||||
monitors</li>
|
||||
<li>The NEVx fields now post monitors, following the EFLG setting</li>
|
||||
<li>The artificial limit of 10,000,000 array elements has been removed</li>
|
||||
</ul>
|
||||
|
||||
<h4>Problem with NAN values in MLST/ALST fields</h4>
|
||||
|
||||
<p>The ai, ao, calc, calcout, dfanout, sel and sub record types could stop
|
||||
posting monitors if they got NAN values in their MLST or ALST fields. A change
|
||||
has been included so this should no longer be the case.</p>
|
||||
|
||||
<h4>MacOS build defaults changed</h4>
|
||||
|
||||
<p>The default build settings for darwin-x86 targets have been changed to match
|
||||
the latest version of XCode; see configure/os/CONFIG_SITE.Common.darwin-x86
|
||||
if you need to revert back to building with GCC or to include the i386 CPU
|
||||
architecture.</p>
|
||||
|
||||
<h4>Build problem with db dependencies</h4>
|
||||
|
||||
<p>The dependency output for .db and .acf files created by makeDbDepends.pl did
|
||||
@@ -28,12 +50,32 @@ itself have now been added. Both the Shell and Perl versions of the startup
|
||||
EpicsHostArch scripts now recognize both arm6l and arm7l CPUs and return the
|
||||
generic linux-arm host architecture name for them.</p>
|
||||
|
||||
<h4>New Microblaze Target Architecture</h4>
|
||||
|
||||
<p>A new cross-compiled target architecture is included for the Xilinx
|
||||
Microblaze FPGA soft-core CPU architecture running Linux.</p>
|
||||
|
||||
<h4>Win32 Numeric string to enum/menu/device conversions</h4>
|
||||
|
||||
<p>Microsoft's C run-time library has a bug in the sscanf() function such that
|
||||
the "%n" format specifier does not always work. The string to enum, menu and
|
||||
device conversion functions have been modified to avoid this problem, but a
|
||||
numeric string will no longer be converted properly on any architecture if it
|
||||
has trailing whitespace characters.</p>
|
||||
|
||||
<h4>Launchpad Bugs Resolved</h4>
|
||||
|
||||
<p>The following are links to bugs in the Launchpad bug tracker that have been
|
||||
fixed in this release:</p>
|
||||
|
||||
<ul>
|
||||
<li>999167
|
||||
<a href="https://launchpad.net/bugs/999167">
|
||||
Missing epicsShareFunc for casStatsFetch</a></li>
|
||||
<li>950555
|
||||
<a href="https://launchpad.net/bugs/950555">
|
||||
String substitution removes part of path when linking versioned shared
|
||||
libraries</a></li>
|
||||
<li>907761
|
||||
<a href="https://launchpad.net/bugs/907761">
|
||||
reading only 1st char of link in "long string" ($) syntax fails in read
|
||||
@@ -41,6 +83,7 @@ fixed in this release:</p>
|
||||
<li>903448
|
||||
<a href="https://launchpad.net/bugs/903448">
|
||||
RHEL5 nss ldap update cause stack size related failure</a></li>
|
||||
|
||||
</ul>
|
||||
|
||||
<h4>Calcout and Seq record timestamps</h4>
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
/* share/src/as/asDbLib.c */
|
||||
/*************************************************************************\
|
||||
* Copyright (c) 2002 The University of Chicago, as Operator of Argonne
|
||||
* Copyright (c) 2012 UChicago Argonne LLC, as Operator of Argonne
|
||||
* National Laboratory.
|
||||
* Copyright (c) 2002 The Regents of the University of California, as
|
||||
* Operator of Los Alamos National Laboratory.
|
||||
* EPICS BASE Versions 3.13.7
|
||||
* and higher are distributed subject to a Software License Agreement found
|
||||
* EPICS BASE is distributed subject to a Software License Agreement found
|
||||
* in file LICENSE that is included with this distribution.
|
||||
\*************************************************************************/
|
||||
/* Author: Marty Kraimer Date: 02-11-94*/
|
||||
@@ -69,18 +67,23 @@ static long asDbAddRecords(void)
|
||||
|
||||
int epicsShareAPI asSetFilename(const char *acf)
|
||||
{
|
||||
if(pacf) free ((void *)pacf);
|
||||
if(acf) {
|
||||
pacf = calloc(1,strlen(acf)+1);
|
||||
if(!pacf) {
|
||||
errMessage(0,"asSetFilename calloc failure");
|
||||
} else {
|
||||
strcpy(pacf,acf);
|
||||
}
|
||||
if (pacf)
|
||||
free (pacf);
|
||||
if (acf) {
|
||||
pacf = calloc(1, strlen(acf)+1);
|
||||
if (!pacf) {
|
||||
errMessage(0, "asSetFilename calloc failure");
|
||||
} else {
|
||||
strcpy(pacf, acf);
|
||||
if (*pacf != '/' && !strchr(pacf, ':')) {
|
||||
printf("asSetFilename: Warning - relative paths won't usually "
|
||||
"work\n");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
pacf = NULL;
|
||||
pacf = NULL;
|
||||
}
|
||||
return(0);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int epicsShareAPI asSetSubstitutions(const char *substitutions)
|
||||
|
||||
@@ -492,12 +492,12 @@ int main (int argc, char *argv[])
|
||||
if (charArrAsStr) {
|
||||
count = len;
|
||||
dbrType = DBR_CHAR;
|
||||
ebuf = calloc(strlen(cbuf), sizeof(char));
|
||||
ebuf = calloc(strlen(cbuf)+1, sizeof(char));
|
||||
if(!ebuf) {
|
||||
fprintf(stderr, "Memory allocation failed\n");
|
||||
return 1;
|
||||
}
|
||||
epicsStrnRawFromEscaped(ebuf, strlen(cbuf), cbuf, strlen(cbuf));
|
||||
epicsStrnRawFromEscaped(ebuf, strlen(cbuf)+1, cbuf, strlen(cbuf));
|
||||
} else {
|
||||
for (i = 0; i < count; ++i) {
|
||||
epicsStrnRawFromEscaped(sbuf[i], sizeof(EpicsStr), *(argv+optind+i), sizeof(EpicsStr));
|
||||
|
||||
@@ -445,10 +445,15 @@ char *dbr2str (const void *value, unsigned type)
|
||||
\
|
||||
if (charArrAsStr && dbr_type_is_CHAR(TYPE_ENUM) && (reqElems || pv->nElems > 1)) { \
|
||||
dbr_char_t *s = (dbr_char_t*) dbr_value_ptr(pv->value, pv->dbrType); \
|
||||
int dlen = epicsStrnEscapedFromRawSize((char*)s, strlen((char*)s)); \
|
||||
char *d = calloc(dlen+1, sizeof(char)); \
|
||||
size_t len = strlen((char*)s); \
|
||||
unsigned long elems = reqElems && (reqElems < pv->nElems) ? reqElems : pv->nElems; \
|
||||
int dlen; \
|
||||
char *d; \
|
||||
if (len < elems) elems = len; \
|
||||
dlen = epicsStrnEscapedFromRawSize((char*)s, elems); \
|
||||
d = calloc(dlen+1, sizeof(char)); \
|
||||
if(d) { \
|
||||
epicsStrnEscapedFromRaw(d, dlen+1, (char*)s, strlen((char*)s));\
|
||||
epicsStrnEscapedFromRaw(d, dlen+1, (char*)s, elems); \
|
||||
printf("%c%s", fieldSeparator, d); \
|
||||
free(d); \
|
||||
} else { \
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include "errlog.h"
|
||||
#include "cantProceed.h"
|
||||
#include "cvtFast.h"
|
||||
#include "epicsMath.h"
|
||||
#include "epicsTime.h"
|
||||
#include "alarm.h"
|
||||
#include "ellLib.h"
|
||||
@@ -281,48 +282,41 @@ static void get_control(DBADDR *paddr, char **ppbuffer,
|
||||
}
|
||||
|
||||
static void get_alarm(DBADDR *paddr, char **ppbuffer,
|
||||
struct rset *prset,long *options)
|
||||
struct rset *prset, long *options)
|
||||
{
|
||||
struct dbr_alDouble ald;
|
||||
int got_data=FALSE;
|
||||
char *pbuffer = *ppbuffer;
|
||||
struct dbr_alDouble ald = {epicsNAN, epicsNAN, epicsNAN, epicsNAN};
|
||||
long no_data = TRUE;
|
||||
|
||||
ald.upper_alarm_limit = ald.upper_warning_limit = 0.0;
|
||||
ald.lower_warning_limit = ald.lower_alarm_limit = 0.0;
|
||||
if( prset && prset->get_alarm_double ) {
|
||||
(*prset->get_alarm_double)(paddr,&ald);
|
||||
got_data=TRUE;
|
||||
}
|
||||
if( (*options) & (DBR_AL_LONG) ) {
|
||||
char *pbuffer=*ppbuffer;
|
||||
if (prset && prset->get_alarm_double)
|
||||
no_data = prset->get_alarm_double(paddr, &ald);
|
||||
|
||||
if(got_data) {
|
||||
struct dbr_alLong *pal=(struct dbr_alLong*)pbuffer;
|
||||
pal->upper_alarm_limit = (epicsInt32)ald.upper_alarm_limit;
|
||||
pal->upper_warning_limit = (epicsInt32)ald.upper_warning_limit;
|
||||
pal->lower_warning_limit = (epicsInt32)ald.lower_warning_limit;
|
||||
pal->lower_alarm_limit = (epicsInt32)ald.lower_alarm_limit;
|
||||
} else {
|
||||
memset(pbuffer,'\0',dbr_alLong_size);
|
||||
*options = (*options) ^ DBR_AL_LONG; /*Turn off option*/
|
||||
}
|
||||
*ppbuffer = ((char *)*ppbuffer) + dbr_alLong_size;
|
||||
}
|
||||
if( (*options) & (DBR_AL_DOUBLE) ) {
|
||||
char *pbuffer=*ppbuffer;
|
||||
if (*options & DBR_AL_LONG) {
|
||||
struct dbr_alLong *pal = (struct dbr_alLong*) pbuffer;
|
||||
|
||||
if(got_data) {
|
||||
struct dbr_alDouble *pal=(struct dbr_alDouble*)pbuffer;
|
||||
pal->upper_alarm_limit = ald.upper_alarm_limit;
|
||||
pal->upper_warning_limit = ald.upper_warning_limit;
|
||||
pal->lower_warning_limit = ald.lower_warning_limit;
|
||||
pal->lower_alarm_limit = ald.lower_alarm_limit;
|
||||
} else {
|
||||
memset(pbuffer,'\0',dbr_alDouble_size);
|
||||
*options = (*options) ^ DBR_AL_DOUBLE; /*Turn off option*/
|
||||
}
|
||||
*ppbuffer = ((char *)*ppbuffer) + dbr_alDouble_size;
|
||||
}
|
||||
return;
|
||||
pal->upper_alarm_limit = (epicsInt32) ald.upper_alarm_limit;
|
||||
pal->upper_warning_limit = (epicsInt32) ald.upper_warning_limit;
|
||||
pal->lower_warning_limit = (epicsInt32) ald.lower_warning_limit;
|
||||
pal->lower_alarm_limit = (epicsInt32) ald.lower_alarm_limit;
|
||||
|
||||
if (no_data)
|
||||
*options ^= DBR_AL_LONG; /*Turn off option*/
|
||||
|
||||
*ppbuffer += dbr_alLong_size;
|
||||
}
|
||||
if (*options & DBR_AL_DOUBLE) {
|
||||
struct dbr_alDouble *pal = (struct dbr_alDouble*) pbuffer;
|
||||
|
||||
pal->upper_alarm_limit = ald.upper_alarm_limit;
|
||||
pal->upper_warning_limit = ald.upper_warning_limit;
|
||||
pal->lower_warning_limit = ald.lower_warning_limit;
|
||||
pal->lower_alarm_limit = ald.lower_alarm_limit;
|
||||
|
||||
if (no_data)
|
||||
*options ^= DBR_AL_DOUBLE; /*Turn off option*/
|
||||
|
||||
*ppbuffer += dbr_alDouble_size;
|
||||
}
|
||||
}
|
||||
|
||||
static void getOptions(DBADDR *paddr,char **poriginal,long *options,void *pflin)
|
||||
@@ -1442,8 +1436,9 @@ long epicsShareAPI dbPut(DBADDR *paddr, short dbrType,
|
||||
else
|
||||
offset = 0;
|
||||
if (no_elements < nRequest) nRequest = no_elements;
|
||||
status = dbPutConvertRoutine[dbrType][field_type](paddr, pbuffer,
|
||||
nRequest, no_elements, offset);
|
||||
if (!status)
|
||||
status = dbPutConvertRoutine[dbrType][field_type](paddr, pbuffer,
|
||||
nRequest, no_elements, offset);
|
||||
|
||||
/* update array info */
|
||||
if (!status &&
|
||||
|
||||
140
src/db/recGbl.c
140
src/db/recGbl.c
@@ -21,6 +21,7 @@
|
||||
#include <limits.h>
|
||||
|
||||
#include "dbDefs.h"
|
||||
#include "epicsMath.h"
|
||||
#include "epicsTime.h"
|
||||
#include "epicsPrint.h"
|
||||
#include "dbBase.h"
|
||||
@@ -107,64 +108,56 @@ void epicsShareAPI recGblRecSupError(long status, const struct dbAddr *paddr,
|
||||
return;
|
||||
}
|
||||
|
||||
void epicsShareAPI recGblGetPrec(const struct dbAddr *paddr,long *precision)
|
||||
void epicsShareAPI recGblGetPrec(const struct dbAddr *paddr, long *precision)
|
||||
{
|
||||
dbFldDes *pdbFldDes = paddr->pfldDes;
|
||||
|
||||
switch(pdbFldDes->field_type){
|
||||
case(DBF_SHORT):
|
||||
*precision = 0;
|
||||
break;
|
||||
case(DBF_USHORT):
|
||||
*precision = 0;
|
||||
break;
|
||||
case(DBF_LONG):
|
||||
*precision = 0;
|
||||
break;
|
||||
case(DBF_ULONG):
|
||||
*precision = 0;
|
||||
break;
|
||||
case(DBF_FLOAT):
|
||||
case(DBF_DOUBLE):
|
||||
if(*precision<0 || *precision>15) *precision=15;
|
||||
break;
|
||||
switch (pdbFldDes->field_type) {
|
||||
case DBF_CHAR:
|
||||
case DBF_UCHAR:
|
||||
case DBF_SHORT:
|
||||
case DBF_USHORT:
|
||||
case DBF_LONG:
|
||||
case DBF_ULONG:
|
||||
*precision = 0;
|
||||
break;
|
||||
|
||||
case DBF_FLOAT:
|
||||
case DBF_DOUBLE:
|
||||
if (*precision < 0 || *precision > 15)
|
||||
*precision = 15;
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
void epicsShareAPI recGblGetGraphicDouble(
|
||||
const struct dbAddr *paddr,struct dbr_grDouble *pgd)
|
||||
void epicsShareAPI recGblGetGraphicDouble(const struct dbAddr *paddr,
|
||||
struct dbr_grDouble *pgd)
|
||||
{
|
||||
dbFldDes *pdbFldDes = paddr->pfldDes;
|
||||
|
||||
getMaxRangeValues(pdbFldDes->field_type,&pgd->upper_disp_limit,
|
||||
&pgd->lower_disp_limit);
|
||||
|
||||
return;
|
||||
getMaxRangeValues(pdbFldDes->field_type,
|
||||
&pgd->upper_disp_limit, &pgd->lower_disp_limit);
|
||||
}
|
||||
|
||||
void epicsShareAPI recGblGetAlarmDouble(
|
||||
const struct dbAddr *paddr,struct dbr_alDouble *pad)
|
||||
void epicsShareAPI recGblGetAlarmDouble(const struct dbAddr *paddr,
|
||||
struct dbr_alDouble *pad)
|
||||
{
|
||||
pad->upper_alarm_limit = 0;
|
||||
pad->upper_warning_limit = 0;
|
||||
pad->lower_warning_limit = 0;
|
||||
pad->lower_alarm_limit = 0;
|
||||
|
||||
return;
|
||||
pad->upper_alarm_limit = epicsNAN;
|
||||
pad->upper_warning_limit = epicsNAN;
|
||||
pad->lower_warning_limit = epicsNAN;
|
||||
pad->lower_alarm_limit = epicsNAN;
|
||||
}
|
||||
|
||||
void epicsShareAPI recGblGetControlDouble(
|
||||
const struct dbAddr *paddr,struct dbr_ctrlDouble *pcd)
|
||||
void epicsShareAPI recGblGetControlDouble(const struct dbAddr *paddr,
|
||||
struct dbr_ctrlDouble *pcd)
|
||||
{
|
||||
dbFldDes *pdbFldDes=paddr->pfldDes;
|
||||
dbFldDes *pdbFldDes = paddr->pfldDes;
|
||||
|
||||
getMaxRangeValues(pdbFldDes->field_type,&pcd->upper_ctrl_limit,
|
||||
&pcd->lower_ctrl_limit);
|
||||
|
||||
return;
|
||||
getMaxRangeValues(pdbFldDes->field_type,
|
||||
&pcd->upper_ctrl_limit, &pcd->lower_ctrl_limit);
|
||||
}
|
||||
|
||||
int epicsShareAPI recGblInitConstantLink(
|
||||
@@ -319,40 +312,39 @@ static void getMaxRangeValues(short field_type, double *pupper_limit,
|
||||
double *plower_limit)
|
||||
{
|
||||
switch(field_type){
|
||||
case(DBF_CHAR):
|
||||
*pupper_limit = -128.0;
|
||||
*plower_limit = 127.0;
|
||||
break;
|
||||
case(DBF_UCHAR):
|
||||
*pupper_limit = 255.0;
|
||||
*plower_limit = 0.0;
|
||||
break;
|
||||
case(DBF_SHORT):
|
||||
*pupper_limit = (double)SHRT_MAX;
|
||||
*plower_limit = (double)SHRT_MIN;
|
||||
break;
|
||||
case(DBF_ENUM):
|
||||
case(DBF_USHORT):
|
||||
*pupper_limit = (double)USHRT_MAX;
|
||||
*plower_limit = (double)0;
|
||||
break;
|
||||
case(DBF_LONG):
|
||||
/* long did not work using cast to double */
|
||||
*pupper_limit = 2147483647.;
|
||||
*plower_limit = -2147483648.;
|
||||
break;
|
||||
case(DBF_ULONG):
|
||||
*pupper_limit = (double)ULONG_MAX;
|
||||
*plower_limit = (double)0;
|
||||
break;
|
||||
case(DBF_FLOAT):
|
||||
*pupper_limit = (double)1e+30;
|
||||
*plower_limit = (double)-1e30;
|
||||
break;
|
||||
case(DBF_DOUBLE):
|
||||
*pupper_limit = (double)1e+30;
|
||||
*plower_limit = (double)-1e30;
|
||||
break;
|
||||
case DBF_CHAR:
|
||||
*pupper_limit = -128.0;
|
||||
*plower_limit = 127.0;
|
||||
break;
|
||||
case DBF_UCHAR:
|
||||
*pupper_limit = 255.0;
|
||||
*plower_limit = 0.0;
|
||||
break;
|
||||
case DBF_SHORT:
|
||||
*pupper_limit = (double) SHRT_MAX;
|
||||
*plower_limit = (double) SHRT_MIN;
|
||||
break;
|
||||
case DBF_ENUM:
|
||||
case DBF_USHORT:
|
||||
*pupper_limit = (double) USHRT_MAX;
|
||||
*plower_limit = 0.0;
|
||||
break;
|
||||
case DBF_LONG:
|
||||
*pupper_limit = 2147483647.0;
|
||||
*plower_limit = -2147483648.0;
|
||||
break;
|
||||
case DBF_ULONG:
|
||||
*pupper_limit = (double) 0xffffffffU;
|
||||
*plower_limit = 0.0;
|
||||
break;
|
||||
case DBF_FLOAT:
|
||||
*pupper_limit = 1e30;
|
||||
*plower_limit = -1e30;
|
||||
break;
|
||||
case DBF_DOUBLE:
|
||||
*pupper_limit = 1e300;
|
||||
*plower_limit = -1e300;
|
||||
break;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -51,11 +51,7 @@ public:
|
||||
reference ( epicsSingleton & );
|
||||
reference ( const reference & );
|
||||
~reference ();
|
||||
// this somewhat convoluted reference of the return
|
||||
// type ref through the epicsSingleton template is
|
||||
// required for the archaic Tornado gnu compiler
|
||||
typename epicsSingleton < TYPE > :: reference &
|
||||
operator = ( const reference & );
|
||||
reference & operator = ( const reference & );
|
||||
TYPE * operator -> ();
|
||||
const TYPE * operator -> () const;
|
||||
TYPE & operator * ();
|
||||
@@ -106,7 +102,7 @@ inline epicsSingleton < TYPE > :: reference ::
|
||||
}
|
||||
|
||||
template < class TYPE >
|
||||
typename epicsSingleton < TYPE > :: reference &
|
||||
class epicsSingleton < TYPE > :: reference &
|
||||
epicsSingleton < TYPE > :: reference ::
|
||||
operator = ( const reference & ref )
|
||||
{
|
||||
@@ -199,14 +195,14 @@ void epicsSingleton < TYPE > ::
|
||||
}
|
||||
|
||||
template < class TYPE >
|
||||
inline typename epicsSingleton < TYPE > :: reference
|
||||
inline class epicsSingleton < TYPE > :: reference
|
||||
epicsSingleton < TYPE > :: getReference ()
|
||||
{
|
||||
return reference ( * this );
|
||||
}
|
||||
|
||||
template < class TYPE >
|
||||
inline const typename epicsSingleton < TYPE > :: reference
|
||||
inline const class epicsSingleton < TYPE > :: reference
|
||||
epicsSingleton < TYPE > :: getReference () const
|
||||
{
|
||||
epicsSingleton < TYPE > * pConstCastAway =
|
||||
|
||||
@@ -94,6 +94,7 @@ epicsShareExtern devLibVME *pdevLibVME;
|
||||
|
||||
#ifndef NO_DEVLIB_COMPAT
|
||||
# define pdevLibVirtualOS pdevLibVME
|
||||
typedef devLibVME devLibVirtualOS;
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
@@ -11,6 +11,11 @@
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
#ifndef _MSC_VER
|
||||
/* Older versions of MinGW omitted this prototype from stdio.h */
|
||||
_CRTIMP int __cdecl __MINGW_NOTHROW _vscprintf (const char*, va_list);
|
||||
#endif
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include "epicsStdio.h"
|
||||
|
||||
@@ -18,26 +23,12 @@ int epicsShareAPI epicsVsnprintf(char *str, size_t len,
|
||||
const char *fmt, va_list ap)
|
||||
{
|
||||
int retval = _vsnprintf(str, len, fmt, ap);
|
||||
|
||||
#ifdef _MSC_VER
|
||||
int needed = _vscprintf(fmt, ap);
|
||||
|
||||
if ((int) len < needed + 1) {
|
||||
str[len - 1] = 0;
|
||||
return needed;
|
||||
}
|
||||
#else
|
||||
/* Unfortunately MINGW doesn't provide _vscprintf and their
|
||||
* _vsnprintf follows MS' broken return value semantics.
|
||||
*/
|
||||
if (retval == -1) {
|
||||
if (len)
|
||||
str[len - 1] = 0;
|
||||
return len;
|
||||
} else if (retval == (int) len) {
|
||||
str[--retval] = 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
@@ -189,8 +189,12 @@ epicsReadlineEnd (void *context)
|
||||
#include <ledLib.h>
|
||||
#define LEDLIB_LINESIZE 1000
|
||||
|
||||
#ifndef _WRS_VXWORKS_MAJOR
|
||||
typedef int LED_ID;
|
||||
#endif
|
||||
|
||||
struct readlineContext {
|
||||
int ledId;
|
||||
LED_ID ledId;
|
||||
char line[LEDLIB_LINESIZE];
|
||||
FILE *in;
|
||||
};
|
||||
@@ -205,7 +209,7 @@ epicsReadlineBegin(FILE *in)
|
||||
|
||||
readlineContext = malloc(sizeof *readlineContext);
|
||||
if (readlineContext != NULL) {
|
||||
readlineContext->ledId = ERROR;
|
||||
readlineContext->ledId = (LED_ID) ERROR;
|
||||
readlineContext->in = in;
|
||||
if (in == NULL) {
|
||||
long i = 50;
|
||||
@@ -213,7 +217,7 @@ epicsReadlineBegin(FILE *in)
|
||||
envGetLongConfigParam(&IOCSH_HISTSIZE, &i);
|
||||
if (i < 1) i = 1;
|
||||
readlineContext->ledId = ledOpen(fileno(stdin), fileno(stdout), i);
|
||||
if (readlineContext->ledId == ERROR) {
|
||||
if (readlineContext->ledId == (LED_ID) ERROR) {
|
||||
readlineContext->in = stdin;
|
||||
printf("Warning -- Unabled to allocate space for command-line history.\n");
|
||||
printf("Warning -- Command-line editting disabled.\n");
|
||||
@@ -236,7 +240,7 @@ epicsReadline (const char *prompt, void *context)
|
||||
fputs(prompt, stdout);
|
||||
fflush(stdout);
|
||||
}
|
||||
if (readlineContext->ledId != ERROR) {
|
||||
if (readlineContext->ledId != (LED_ID) ERROR) {
|
||||
i = ledRead(readlineContext->ledId, readlineContext->line, LEDLIB_LINESIZE-1);
|
||||
if (i < 0)
|
||||
return NULL;
|
||||
@@ -262,7 +266,7 @@ epicsReadlineEnd (void *context)
|
||||
struct readlineContext *readlineContext = context;
|
||||
|
||||
if (readlineContext) {
|
||||
if (readlineContext->ledId != ERROR)
|
||||
if (readlineContext->ledId != (LED_ID) ERROR)
|
||||
ledClose(readlineContext->ledId);
|
||||
free(readlineContext);
|
||||
}
|
||||
|
||||
@@ -28,9 +28,9 @@ PYTHON_INCLUDE=/System/Library/Frameworks/Python.framework/Versions/2.3/include/
|
||||
# XDarwin
|
||||
#
|
||||
X11_LIB=/usr/X11R6/lib
|
||||
X11_INC=/usr/X11R6/include/X11
|
||||
X11_INC=/usr/X11R6/include
|
||||
XPM_LIB=/usr/X11R6/lib
|
||||
XPM_INC=/usr/X11R6/include/X11
|
||||
XPM_INC=/usr/X11R6/include
|
||||
|
||||
#
|
||||
# Fink OpenMotif
|
||||
|
||||
@@ -85,13 +85,12 @@ rset aSubRSET = {
|
||||
epicsExportAddress(rset, aSubRSET);
|
||||
|
||||
static long initFields(epicsEnum16 *pft, epicsUInt32 *pno, epicsUInt32 *pne,
|
||||
const char **fldnames, void **pval, void **povl);
|
||||
epicsUInt32 *pon, const char **fldnames, void **pval, void **povl);
|
||||
static long fetch_values(aSubRecord *prec);
|
||||
static void monitor(aSubRecord *);
|
||||
static long do_sub(aSubRecord *);
|
||||
|
||||
#define NUM_ARGS 21
|
||||
#define MAX_ARRAY_SIZE 10000000
|
||||
|
||||
/* These are the names of the Input fields */
|
||||
static const char *Ifldnames[] = {
|
||||
@@ -117,10 +116,10 @@ static long init_record(aSubRecord *prec, int pass)
|
||||
status = 0;
|
||||
if (pass == 0) {
|
||||
/* Allocate memory for arrays */
|
||||
initFields(&prec->fta, &prec->noa, &prec->nea, Ifldnames,
|
||||
&prec->a, NULL);
|
||||
initFields(&prec->ftva, &prec->nova, &prec->neva, Ofldnames,
|
||||
&prec->vala, &prec->ovla);
|
||||
initFields(&prec->fta, &prec->noa, &prec->nea, NULL,
|
||||
Ifldnames, &prec->a, NULL);
|
||||
initFields(&prec->ftva, &prec->nova, &prec->neva, &prec->onva,
|
||||
Ofldnames, &prec->vala, &prec->ovla);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -146,12 +145,8 @@ static long init_record(aSubRecord *prec, int pass)
|
||||
struct link *plink = &(&prec->inpa)[i];
|
||||
switch (plink->type) {
|
||||
case CONSTANT:
|
||||
if ((&prec->noa)[i] < 2) {
|
||||
if (recGblInitConstantLink(plink, (&prec->fta)[i], (&prec->a)[i])) {
|
||||
prec->udf = FALSE;
|
||||
} else
|
||||
prec->udf = TRUE;
|
||||
}
|
||||
if ((&prec->noa)[i] < 2)
|
||||
recGblInitConstantLink(plink, (&prec->fta)[i], (&prec->a)[i]);
|
||||
break;
|
||||
|
||||
case PV_LINK:
|
||||
@@ -218,7 +213,7 @@ static long init_record(aSubRecord *prec, int pass)
|
||||
|
||||
|
||||
static long initFields(epicsEnum16 *pft, epicsUInt32 *pno, epicsUInt32 *pne,
|
||||
const char **fldnames, void **pval, void **povl)
|
||||
epicsUInt32 *pon, const char **fldnames, void **pval, void **povl)
|
||||
{
|
||||
int i;
|
||||
long status = 0;
|
||||
@@ -235,22 +230,16 @@ static long initFields(epicsEnum16 *pft, epicsUInt32 *pno, epicsUInt32 *pne,
|
||||
|
||||
flen = dbValueSize(*pft);
|
||||
num = *pno * flen;
|
||||
|
||||
if (num > MAX_ARRAY_SIZE) {
|
||||
epicsPrintf("Link %s - Array too large! %d Bytes\n", fldnames[i], num);
|
||||
*pno = num = 0;
|
||||
status = S_db_errArg;
|
||||
} else
|
||||
*pval = (char *)callocMustSucceed(*pno, flen,
|
||||
"aSubRecord::init_record");
|
||||
*pval = callocMustSucceed(*pno, flen, "aSubRecord::init_record");
|
||||
|
||||
*pne = *pno;
|
||||
|
||||
if (povl) {
|
||||
if (num)
|
||||
*povl = (char *)callocMustSucceed(*pno, flen,
|
||||
*povl = callocMustSucceed(*pno, flen,
|
||||
"aSubRecord::init_record");
|
||||
povl++;
|
||||
*pon++ = *pne;
|
||||
}
|
||||
}
|
||||
return status;
|
||||
@@ -281,6 +270,7 @@ static long process(aSubRecord *prec)
|
||||
/* Push the output link values */
|
||||
if (!status) {
|
||||
int i;
|
||||
|
||||
for (i = 0; i < NUM_ARGS; i++)
|
||||
dbPutLink(&(&prec->outa)[i], (&prec->ftva)[i], (&prec->vala)[i],
|
||||
(&prec->neva)[i]);
|
||||
@@ -359,18 +349,29 @@ static void monitor(aSubRecord *prec)
|
||||
break;
|
||||
case aSubEFLG_ON_CHANGE:
|
||||
for (i = 0; i < NUM_ARGS; i++) {
|
||||
epicsUInt32 alen = dbValueSize((&prec->ftva)[i]) * (&prec->neva)[i];
|
||||
void *povl = (&prec->ovla)[i];
|
||||
void *pval = (&prec->vala)[i];
|
||||
if (memcmp(povl, pval, alen)) {
|
||||
epicsUInt32 *ponv = &(&prec->onva)[i];
|
||||
epicsUInt32 *pnev = &(&prec->neva)[i];
|
||||
epicsUInt32 onv = *ponv; /* Num Elements in OVLx */
|
||||
epicsUInt32 nev = *pnev; /* Num Elements in VALx */
|
||||
epicsUInt32 alen = dbValueSize((&prec->ftva)[i]) * nev;
|
||||
|
||||
if (nev != onv || memcmp(povl, pval, alen)) {
|
||||
memcpy(povl, pval, alen);
|
||||
db_post_events(prec, pval, monitor_mask);
|
||||
if (nev != onv) {
|
||||
*ponv = nev;
|
||||
db_post_events(prec, pnev, monitor_mask);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case aSubEFLG_ALWAYS:
|
||||
for (i = 0; i < NUM_ARGS; i++)
|
||||
for (i = 0; i < NUM_ARGS; i++) {
|
||||
db_post_events(prec, (&prec->vala)[i], monitor_mask);
|
||||
db_post_events(prec, &(&prec->neva)[i], monitor_mask);
|
||||
}
|
||||
break;
|
||||
}
|
||||
return;
|
||||
|
||||
@@ -1049,127 +1049,148 @@ recordtype(aSub) {
|
||||
prompt("Old Output A")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovla")
|
||||
interest(4)
|
||||
extra("void *ovla")
|
||||
}
|
||||
field(OVLB,DBF_NOACCESS) {
|
||||
prompt("Old Output B")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlb")
|
||||
interest(4)
|
||||
extra("void *ovlb")
|
||||
}
|
||||
field(OVLC,DBF_NOACCESS) {
|
||||
prompt("Old Output C")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlc")
|
||||
interest(4)
|
||||
extra("void *ovlc")
|
||||
}
|
||||
field(OVLD,DBF_NOACCESS) {
|
||||
prompt("Old Output D")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovld")
|
||||
interest(4)
|
||||
extra("void *ovld")
|
||||
}
|
||||
field(OVLE,DBF_NOACCESS) {
|
||||
prompt("Old Output E")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovle")
|
||||
interest(4)
|
||||
extra("void *ovle")
|
||||
}
|
||||
field(OVLF,DBF_NOACCESS) {
|
||||
prompt("Old Output F")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlf")
|
||||
interest(4)
|
||||
extra("void *ovlf")
|
||||
}
|
||||
field(OVLG,DBF_NOACCESS) {
|
||||
prompt("Old Output G")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlg")
|
||||
interest(4)
|
||||
extra("void *ovlg")
|
||||
}
|
||||
field(OVLH,DBF_NOACCESS) {
|
||||
prompt("Old Output H")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlh")
|
||||
interest(4)
|
||||
extra("void *ovlh")
|
||||
}
|
||||
field(OVLI,DBF_NOACCESS) {
|
||||
prompt("Old Output I")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovli")
|
||||
interest(4)
|
||||
extra("void *ovli")
|
||||
}
|
||||
field(OVLJ,DBF_NOACCESS) {
|
||||
prompt("Old Output J")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlj")
|
||||
interest(4)
|
||||
extra("void *ovlj")
|
||||
}
|
||||
field(OVLK,DBF_NOACCESS) {
|
||||
prompt("Old Output K")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlk")
|
||||
interest(4)
|
||||
extra("void *ovlk")
|
||||
}
|
||||
field(OVLL,DBF_NOACCESS) {
|
||||
prompt("Old Output L")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovll")
|
||||
interest(4)
|
||||
extra("void *ovll")
|
||||
}
|
||||
field(OVLM,DBF_NOACCESS) {
|
||||
prompt("Old Output M")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlm")
|
||||
interest(4)
|
||||
extra("void *ovlm")
|
||||
}
|
||||
field(OVLN,DBF_NOACCESS) {
|
||||
prompt("Old Output N")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovln")
|
||||
interest(4)
|
||||
extra("void *ovln")
|
||||
}
|
||||
field(OVLO,DBF_NOACCESS) {
|
||||
prompt("Old Output O")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlo")
|
||||
interest(4)
|
||||
extra("void *ovlo")
|
||||
}
|
||||
field(OVLP,DBF_NOACCESS) {
|
||||
prompt("Old Output P")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlp")
|
||||
interest(4)
|
||||
extra("void *ovlp")
|
||||
}
|
||||
field(OVLQ,DBF_NOACCESS) {
|
||||
prompt("Old Output Q")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlq")
|
||||
interest(4)
|
||||
extra("void *ovlq")
|
||||
}
|
||||
field(OVLR,DBF_NOACCESS) {
|
||||
prompt("Old Output R")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlr")
|
||||
interest(4)
|
||||
extra("void *ovlr")
|
||||
}
|
||||
field(OVLS,DBF_NOACCESS) {
|
||||
prompt("Old Output S")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovls")
|
||||
interest(4)
|
||||
extra("void *ovls")
|
||||
}
|
||||
field(OVLT,DBF_NOACCESS) {
|
||||
prompt("Old Output T")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlt")
|
||||
interest(4)
|
||||
extra("void *ovlt")
|
||||
}
|
||||
field(OVLU,DBF_NOACCESS) {
|
||||
prompt("Old Output U")
|
||||
asl(ASL0)
|
||||
special(SPC_NOMOD)
|
||||
interest(4) extra("void *ovlu")
|
||||
interest(4)
|
||||
extra("void *ovlu")
|
||||
}
|
||||
field(FTVA,DBF_MENU) {
|
||||
prompt("Type of VALA")
|
||||
@@ -1488,149 +1509,254 @@ recordtype(aSub) {
|
||||
}
|
||||
field(NEVA,DBF_ULONG) {
|
||||
prompt("Num. elements in VALA")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVB,DBF_ULONG) {
|
||||
prompt("Num. elements in VALB")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVC,DBF_ULONG) {
|
||||
prompt("Num. elements in VALC")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVD,DBF_ULONG) {
|
||||
prompt("Num. elements in VALD")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVE,DBF_ULONG) {
|
||||
prompt("Num. elements in VALE")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVF,DBF_ULONG) {
|
||||
prompt("Num. elements in VALF")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVG,DBF_ULONG) {
|
||||
prompt("Num. elements in VALG")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVH,DBF_ULONG) {
|
||||
prompt("Num. elements in VAlH")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVI,DBF_ULONG) {
|
||||
prompt("Num. elements in VALI")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVJ,DBF_ULONG) {
|
||||
prompt("Num. elements in VALJ")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVK,DBF_ULONG) {
|
||||
prompt("Num. elements in VALK")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVL,DBF_ULONG) {
|
||||
prompt("Num. elements in VALL")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVM,DBF_ULONG) {
|
||||
prompt("Num. elements in VALM")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVN,DBF_ULONG) {
|
||||
prompt("Num. elements in VALN")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVO,DBF_ULONG) {
|
||||
prompt("Num. elements in VALO")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVP,DBF_ULONG) {
|
||||
prompt("Num. elements in VALP")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVQ,DBF_ULONG) {
|
||||
prompt("Num. elements in VALQ")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVR,DBF_ULONG) {
|
||||
prompt("Num. elements in VALR")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVS,DBF_ULONG) {
|
||||
prompt("Num. elements in VALS")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVT,DBF_ULONG) {
|
||||
prompt("Num. elements in VALT")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(NEVU,DBF_ULONG) {
|
||||
prompt("Num. elements in VALU")
|
||||
promptgroup(GUI_WAVE)
|
||||
special(SPC_NOMOD)
|
||||
interest(3)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVA,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLA")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVB,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLB")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVC,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLC")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVD,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLD")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVE,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLE")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVF,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLF")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVG,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLG")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVH,DBF_ULONG) {
|
||||
prompt("Num. elements in VAlH")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVI,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLI")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVJ,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLJ")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVK,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLK")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVL,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLL")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVM,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLM")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVN,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLN")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVO,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLO")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVP,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLP")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVQ,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLQ")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVR,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLR")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVS,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLS")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVT,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLT")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
field(ONVU,DBF_ULONG) {
|
||||
prompt("Num. elements in OVLU")
|
||||
special(SPC_NOMOD)
|
||||
interest(4)
|
||||
initial("1")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -385,7 +385,7 @@ static void monitor(aiRecord *prec)
|
||||
/* check for value change */
|
||||
delta = prec->mlst - prec->val;
|
||||
if(delta<0.0) delta = -delta;
|
||||
if (delta > prec->mdel) {
|
||||
if (!(delta <= prec->mdel)) { /* Handles MDEL == NAN */
|
||||
/* post events for value change */
|
||||
monitor_mask |= DBE_VALUE;
|
||||
/* update last value monitored */
|
||||
@@ -395,7 +395,7 @@ static void monitor(aiRecord *prec)
|
||||
/* check for archive change */
|
||||
delta = prec->alst - prec->val;
|
||||
if(delta<0.0) delta = -delta;
|
||||
if (delta > prec->adel) {
|
||||
if (!(delta <= prec->adel)) { /* Handles ADEL == NAN */
|
||||
/* post events on value field for archive change */
|
||||
monitor_mask |= DBE_LOG;
|
||||
/* update last archive value monitored */
|
||||
|
||||
@@ -484,7 +484,7 @@ static void monitor(aoRecord *prec)
|
||||
/* check for value change */
|
||||
delta = prec->mlst - prec->val;
|
||||
if(delta<0.0) delta = -delta;
|
||||
if (delta > prec->mdel) {
|
||||
if (!(delta <= prec->mdel)) { /* Handles MDEL == NAN */
|
||||
/* post events for value change */
|
||||
monitor_mask |= DBE_VALUE;
|
||||
/* update last value monitored */
|
||||
@@ -493,7 +493,7 @@ static void monitor(aoRecord *prec)
|
||||
/* check for archive change */
|
||||
delta = prec->alst - prec->val;
|
||||
if(delta<0.0) delta = -delta;
|
||||
if (delta > prec->adel) {
|
||||
if (!(delta <= prec->adel)) { /* Handles ADEL == NAN */
|
||||
/* post events on value field for archive change */
|
||||
monitor_mask |= DBE_LOG;
|
||||
/* update last archive value monitored */
|
||||
|
||||
@@ -310,7 +310,7 @@ static void monitor(calcRecord *prec)
|
||||
/* check for value change */
|
||||
delta = prec->mlst - prec->val;
|
||||
if (delta < 0.0) delta = -delta;
|
||||
if (delta > prec->mdel) {
|
||||
if (!(delta <= prec->mdel)) { /* Handles MDEL == NAN */
|
||||
/* post events for value change */
|
||||
monitor_mask |= DBE_VALUE;
|
||||
/* update last value monitored */
|
||||
@@ -319,7 +319,7 @@ static void monitor(calcRecord *prec)
|
||||
/* check for archive change */
|
||||
delta = prec->alst - prec->val;
|
||||
if (delta < 0.0) delta = -delta;
|
||||
if (delta > prec->adel) {
|
||||
if (!(delta <= prec->adel)) { /* Handles ADEL == NAN */
|
||||
/* post events on value field for archive change */
|
||||
monitor_mask |= DBE_LOG;
|
||||
/* update last archive value monitored */
|
||||
|
||||
@@ -209,7 +209,7 @@ static long init_record(calcoutRecord *prec, int pass)
|
||||
static long process(calcoutRecord *prec)
|
||||
{
|
||||
rpvtStruct *prpvt = prec->rpvt;
|
||||
int doOutput = 0;
|
||||
int doOutput;
|
||||
|
||||
if (!prec->pact) {
|
||||
prec->pact = TRUE;
|
||||
@@ -231,21 +231,22 @@ static long process(calcoutRecord *prec)
|
||||
doOutput = 1;
|
||||
break;
|
||||
case calcoutOOPT_On_Change:
|
||||
if (fabs(prec->pval - prec->val) > prec->mdel) doOutput = 1;
|
||||
doOutput = ! (fabs(prec->pval - prec->val) <= prec->mdel);
|
||||
break;
|
||||
case calcoutOOPT_Transition_To_Zero:
|
||||
if ((prec->pval != 0.0) && (prec->val == 0.0)) doOutput = 1;
|
||||
doOutput = ((prec->pval != 0.0) && (prec->val == 0.0));
|
||||
break;
|
||||
case calcoutOOPT_Transition_To_Non_zero:
|
||||
if ((prec->pval == 0.0) && (prec->val != 0.0)) doOutput = 1;
|
||||
doOutput = ((prec->pval == 0.0) && (prec->val != 0.0));
|
||||
break;
|
||||
case calcoutOOPT_When_Zero:
|
||||
if (prec->val == 0.0) doOutput = 1;
|
||||
doOutput = (prec->val == 0.0);
|
||||
break;
|
||||
case calcoutOOPT_When_Non_zero:
|
||||
if (prec->val != 0.0) doOutput = 1;
|
||||
doOutput = (prec->val != 0.0);
|
||||
break;
|
||||
default:
|
||||
doOutput = 0;
|
||||
break;
|
||||
}
|
||||
prec->pval = prec->val;
|
||||
@@ -584,7 +585,7 @@ static void monitor(calcoutRecord *prec)
|
||||
/* check for value change */
|
||||
delta = prec->mlst - prec->val;
|
||||
if (delta<0.0) delta = -delta;
|
||||
if (delta > prec->mdel) {
|
||||
if (!(delta <= prec->mdel)) { /* Handles MDEL == NAN */
|
||||
/* post events for value change */
|
||||
monitor_mask |= DBE_VALUE;
|
||||
/* update last value monitored */
|
||||
@@ -593,7 +594,7 @@ static void monitor(calcoutRecord *prec)
|
||||
/* check for archive change */
|
||||
delta = prec->alst - prec->val;
|
||||
if (delta<0.0) delta = -delta;
|
||||
if (delta > prec->adel) {
|
||||
if (!(delta <= prec->adel)) { /* Handles ADEL == NAN */
|
||||
/* post events on value field for archive change */
|
||||
monitor_mask |= DBE_LOG;
|
||||
/* update last archive value monitored */
|
||||
|
||||
@@ -267,7 +267,7 @@ static void monitor(dfanoutRecord *prec)
|
||||
/* check for value change */
|
||||
delta = prec->mlst - prec->val;
|
||||
if(delta<0) delta = -delta;
|
||||
if (delta > prec->mdel) {
|
||||
if (!(delta <= prec->mdel)) { /* Handles MDEL == NAN */
|
||||
/* post events for value change */
|
||||
monitor_mask |= DBE_VALUE;
|
||||
/* update last value monitored */
|
||||
@@ -276,7 +276,7 @@ static void monitor(dfanoutRecord *prec)
|
||||
/* check for archive change */
|
||||
delta = prec->alst - prec->val;
|
||||
if(delta<0) delta = -delta;
|
||||
if (delta > prec->adel) {
|
||||
if (!(delta <= prec->adel)) { /* Handles ADEL == NAN */
|
||||
/* post events on value field for archive change */
|
||||
monitor_mask |= DBE_LOG;
|
||||
/* update last archive value monitored */
|
||||
|
||||
@@ -300,7 +300,7 @@ static void monitor(selRecord *prec)
|
||||
/* check for value change */
|
||||
delta = prec->mlst - prec->val;
|
||||
if(delta<0.0) delta = -delta;
|
||||
if (delta > prec->mdel) {
|
||||
if (!(delta <= prec->mdel)) { /* Handles MDEL == NAN */
|
||||
/* post events for value change */
|
||||
monitor_mask |= DBE_VALUE;
|
||||
/* update last value monitored */
|
||||
@@ -309,7 +309,7 @@ static void monitor(selRecord *prec)
|
||||
/* check for archive change */
|
||||
delta = prec->alst - prec->val;
|
||||
if(delta<0.0) delta = -delta;
|
||||
if (delta > prec->adel) {
|
||||
if (!(delta <= prec->adel)) { /* Handles ADEL == NAN */
|
||||
/* post events on value field for archive change */
|
||||
monitor_mask |= DBE_LOG;
|
||||
/* update last archive value monitored */
|
||||
|
||||
@@ -156,20 +156,20 @@ static long process(stringinRecord *prec)
|
||||
|
||||
static void monitor(stringinRecord *prec)
|
||||
{
|
||||
unsigned short monitor_mask;
|
||||
int monitor_mask = recGblResetAlarms(prec);
|
||||
|
||||
monitor_mask = recGblResetAlarms(prec);
|
||||
if(strcmp(prec->oval,prec->val)) {
|
||||
monitor_mask |= DBE_VALUE|DBE_LOG;
|
||||
strcpy(prec->oval,prec->val);
|
||||
if (strncmp(prec->oval, prec->val, sizeof(prec->val))) {
|
||||
monitor_mask |= DBE_VALUE | DBE_LOG;
|
||||
strncpy(prec->oval, prec->val, sizeof(prec->val));
|
||||
}
|
||||
|
||||
if (prec->mpst == stringinPOST_Always)
|
||||
monitor_mask |= DBE_VALUE;
|
||||
monitor_mask |= DBE_VALUE;
|
||||
if (prec->apst == stringinPOST_Always)
|
||||
monitor_mask |= DBE_LOG;
|
||||
if(monitor_mask)
|
||||
db_post_events(prec,&(prec->val[0]),monitor_mask);
|
||||
return;
|
||||
monitor_mask |= DBE_LOG;
|
||||
|
||||
if (monitor_mask)
|
||||
db_post_events(prec, prec->val, monitor_mask);
|
||||
}
|
||||
|
||||
static long readValue(stringinRecord *prec)
|
||||
|
||||
@@ -184,20 +184,20 @@ static long process(stringoutRecord *prec)
|
||||
|
||||
static void monitor(stringoutRecord *prec)
|
||||
{
|
||||
unsigned short monitor_mask;
|
||||
int monitor_mask = recGblResetAlarms(prec);
|
||||
|
||||
monitor_mask = recGblResetAlarms(prec);
|
||||
if(strcmp(prec->oval,prec->val)) {
|
||||
monitor_mask |= DBE_VALUE|DBE_LOG;
|
||||
strcpy(prec->oval,prec->val);
|
||||
if (strncmp(prec->oval, prec->val, sizeof(prec->val))) {
|
||||
monitor_mask |= DBE_VALUE | DBE_LOG;
|
||||
strncpy(prec->oval, prec->val, sizeof(prec->val));
|
||||
}
|
||||
|
||||
if (prec->mpst == stringoutPOST_Always)
|
||||
monitor_mask |= DBE_VALUE;
|
||||
monitor_mask |= DBE_VALUE;
|
||||
if (prec->apst == stringoutPOST_Always)
|
||||
monitor_mask |= DBE_LOG;
|
||||
if(monitor_mask)
|
||||
db_post_events(prec,&(prec->val[0]),monitor_mask);
|
||||
return;
|
||||
monitor_mask |= DBE_LOG;
|
||||
|
||||
if (monitor_mask)
|
||||
db_post_events(prec, prec->val, monitor_mask);
|
||||
}
|
||||
|
||||
static long writeValue(stringoutRecord *prec)
|
||||
|
||||
@@ -353,7 +353,7 @@ static void monitor(subRecord *prec)
|
||||
/* check for value change */
|
||||
delta = prec->val - prec->mlst;
|
||||
if (delta < 0.0) delta = -delta;
|
||||
if (delta > prec->mdel) {
|
||||
if (!(delta <= prec->mdel)) { /* Handles MDEL == NAN */
|
||||
/* post events for value change */
|
||||
monitor_mask |= DBE_VALUE;
|
||||
/* update last value monitored */
|
||||
@@ -362,7 +362,7 @@ static void monitor(subRecord *prec)
|
||||
/* check for archive change */
|
||||
delta = prec->val - prec->alst;
|
||||
if (delta < 0.0) delta = -delta;
|
||||
if (delta > prec->adel) {
|
||||
if (!(delta <= prec->adel)) { /* Handles ADEL == NAN */
|
||||
/* post events on value field for archive change */
|
||||
monitor_mask |= DBE_LOG;
|
||||
/* update last archive value monitored */
|
||||
|
||||
@@ -123,6 +123,7 @@ sub AbsPath {
|
||||
|
||||
# Now calculate the absolute path
|
||||
my $abs = File::Spec->rel2abs($path, abs_path($cwd));
|
||||
$abs = abs_path($abs) if -e $abs;
|
||||
|
||||
return LocalPath($abs);
|
||||
}
|
||||
|
||||
@@ -289,7 +289,7 @@ static int seekLatestLine (struct ioc_log_server *pserver)
|
||||
}
|
||||
}
|
||||
else {
|
||||
char c = fgetc (pserver->poutfile);
|
||||
int c = fgetc (pserver->poutfile);
|
||||
|
||||
/*
|
||||
* bypass the line if it does not match the expected format
|
||||
|
||||
@@ -30,6 +30,7 @@ sub GetEpicsHostArch { # no args
|
||||
} elsif ($arch =~ m/x86_64-linux/) { return "linux-x86_64";
|
||||
} elsif ($arch =~ m/arm-linux/) { return "linux-arm";
|
||||
} elsif ($arch =~ m/MSWin32-x86/) { return "win32-x86";
|
||||
} elsif ($arch =~ m/MSWin32-x64/) { return "windows-x64";
|
||||
} elsif ($arch =~ m/cygwin/) { return "cygwin-x86";
|
||||
} elsif ($arch =~ m/darwin/) {
|
||||
my($kernel, $hostname, $release, $version, $cpu) = POSIX::uname();
|
||||
|
||||
Reference in New Issue
Block a user