Compare commits
9 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 3a08da445b | |||
| 61682f72fe | |||
| 4cb3d4d696 | |||
| 0af5e972f3 | |||
| 2a53ea7e47 | |||
| 3b9990e365 | |||
| db5af06e07 | |||
| 5c75fd7bfc | |||
| 1c7846fa4b |
@@ -38,7 +38,7 @@ PROJECT_NAME = pva2pva
|
||||
# could be handy for archiving the generated documentation or if some version
|
||||
# control system is used.
|
||||
|
||||
PROJECT_NUMBER = 1.4.0
|
||||
PROJECT_NUMBER = 1.4.1
|
||||
|
||||
# Using the PROJECT_BRIEF tag one can provide an optional one line description
|
||||
# for a project that appears at the top of each page and should give viewer a
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Module (source) version
|
||||
EPICS_QSRV_MAJOR_VERSION = 1
|
||||
EPICS_QSRV_MINOR_VERSION = 4
|
||||
EPICS_QSRV_MAINTENANCE_VERSION = 0
|
||||
EPICS_QSRV_MAINTENANCE_VERSION = 1
|
||||
|
||||
# ABI version
|
||||
EPICS_QSRV_ABI_MAJOR_VERSION = 1
|
||||
|
||||
@@ -38,7 +38,7 @@ PROJECT_NAME = pva2pva
|
||||
# could be handy for archiving the generated documentation or if some version
|
||||
# control system is used.
|
||||
|
||||
PROJECT_NUMBER = 1.4.0
|
||||
PROJECT_NUMBER = 1.4.1
|
||||
|
||||
# Using the PROJECT_BRIEF tag one can provide an optional one line description
|
||||
# for a project that appears at the top of each page and should give viewer a
|
||||
|
||||
@@ -2,6 +2,14 @@
|
||||
|
||||
@page release_notes Release Notes
|
||||
|
||||
Release 1.4.1 (December 2023)
|
||||
==========================
|
||||
|
||||
- Bug Fixes
|
||||
- dbLoadGroup was fixed
|
||||
- Additions
|
||||
- Support for "meta" member at top of array of structs
|
||||
|
||||
Release 1.4.0 (September 2022)
|
||||
==============================
|
||||
|
||||
|
||||
@@ -74,3 +74,17 @@ record(mbbi, "$(N):ColorMode") {
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
record(bo, "$(N):extra") {
|
||||
field(ZNAM, "foo")
|
||||
field(ONAM, "bar")
|
||||
info(Q:group, {
|
||||
"$(N):Array":{
|
||||
"attribute[1].value":{+type:"any",
|
||||
+channel:"VAL",
|
||||
+putorder:0,
|
||||
+trigger:"attribute[1].value"},
|
||||
"attribute[1]":{+type:"meta", +channel:"SEVR"}
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
/* demonstrate a definition equivalent to the info(Q:group, ...) tags in image.dbd */
|
||||
{
|
||||
"TST:image1:Array2":{
|
||||
"+id":"epics:nt/NTNDArray:1.0",
|
||||
"value":{"+type":"any",
|
||||
"+channel":"TST:image1:ArrayData.VAL",
|
||||
"+trigger":"*"},
|
||||
"":{"+type":"meta", "+channel":"TST:image1:ArrayData.SEVR"},
|
||||
"dimension[0].size":{"+channel":"TST:image1:ArraySize0_RBV.VAL", "+type":"plain", "+putorder":0},
|
||||
"dimension[1].size":{"+channel":"TST:image1:ArraySize1_RBV.VAL", "+type":"plain", "+putorder":0},
|
||||
"attribute[0].name":{"+type":"plain", "+channel":"TST:image1:ColorMode_.VAL"},
|
||||
"attribute[0].value":{"+type":"any", "+channel":"TST:image1:ColorMode.VAL"},
|
||||
"attribute[1].value":{"+type":"any",
|
||||
"+channel":"TST:image1:extra.VAL",
|
||||
"+putorder":0,
|
||||
"+trigger":"attribute[1].value"},
|
||||
"attribute[1]":{"+type":"meta", "+channel":"TST:image1:extra.SEVR"}
|
||||
}
|
||||
}
|
||||
@@ -4,4 +4,6 @@ dbLoadRecords("image.db","N=TST:image1")
|
||||
dbLoadRecords("table.db","N=TST:table1")
|
||||
dbLoadRecords("ntenum.db","P=TST:enum1")
|
||||
|
||||
dbLoadGroup("image.json")
|
||||
|
||||
iocInit()
|
||||
|
||||
@@ -57,6 +57,30 @@ long process_spin(waveformRecord *prec)
|
||||
return 0;
|
||||
}
|
||||
|
||||
long process_repeat(waveformRecord *prec)
|
||||
{
|
||||
long ret;
|
||||
if(prec->ftvl!=menuFtypeULONG) {
|
||||
recGblSetSevr(prec, READ_ALARM, INVALID_ALARM);
|
||||
return S_db_badDbrtype;
|
||||
}
|
||||
|
||||
epicsUInt32 iv=0;
|
||||
if(!!(ret = dbGetLink(&prec->inp, DBF_ULONG, &iv, NULL, NULL))) {
|
||||
recGblSetSevr(prec, READ_ALARM, INVALID_ALARM);
|
||||
return ret;
|
||||
}
|
||||
|
||||
epicsUInt32 *val = (epicsUInt32*)prec->bptr;
|
||||
for(size_t i=0, N=prec->nelm; i<N; i++) {
|
||||
val[i] = iv;
|
||||
}
|
||||
|
||||
prec->nord = iv;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
long process_utag(longinRecord *prec)
|
||||
{
|
||||
long status = dbGetLink(&prec->inp, DBR_LONG, &prec->val, 0, 0);
|
||||
@@ -80,11 +104,13 @@ struct dset5
|
||||
};
|
||||
|
||||
dset5<waveformRecord> devWfPDBDemo = {5,0,0,&init_spin,0,&process_spin};
|
||||
dset5<waveformRecord> devWfPDBDemoRepeat = {5,0,0,0,0,&process_repeat};
|
||||
dset5<longinRecord> devLoPDBUTag = {5,0,0,0,0,&process_utag};
|
||||
|
||||
} // namespace
|
||||
|
||||
extern "C" {
|
||||
epicsExportAddress(dset, devWfPDBDemo);
|
||||
epicsExportAddress(dset, devWfPDBDemoRepeat);
|
||||
epicsExportAddress(dset, devLoPDBUTag);
|
||||
}
|
||||
|
||||
+7
-4
@@ -239,7 +239,7 @@ struct PDBProcessor
|
||||
|
||||
#ifdef USE_MULTILOCK
|
||||
try {
|
||||
GroupConfig::parse(json, "", conf);
|
||||
GroupConfig::parse(json, NULL, conf);
|
||||
if(!conf.warning.empty())
|
||||
fprintf(stderr, "warning(s) from dbGroup file \"%s\"\n%s", it->c_str(), conf.warning.c_str());
|
||||
}catch(std::exception& e){
|
||||
@@ -438,6 +438,9 @@ PDBProvider::PDBProvider(const epics::pvAccess::Configuration::const_shared_poin
|
||||
else
|
||||
builder = builder->addNestedStructure(parts[j].name);
|
||||
}
|
||||
if(parts.back().isArray()) {
|
||||
builder = builder->addNestedStructureArray(parts.back().name);
|
||||
}
|
||||
}
|
||||
|
||||
if(!mem.structID.empty())
|
||||
@@ -457,7 +460,7 @@ PDBProvider::PDBProvider(const epics::pvAccess::Configuration::const_shared_poin
|
||||
|
||||
std::tr1::shared_ptr<PVIFBuilder> pvifbuilder(PVIFBuilder::create(mem.type, chan.chan));
|
||||
|
||||
if(!parts.empty())
|
||||
if(!parts.empty() && !parts.back().isArray())
|
||||
builder = pvifbuilder->dtype(builder, parts.back().name);
|
||||
else
|
||||
builder = pvifbuilder->dtype(builder, "");
|
||||
@@ -465,6 +468,8 @@ PDBProvider::PDBProvider(const epics::pvAccess::Configuration::const_shared_poin
|
||||
if(!parts.empty()) {
|
||||
for(size_t j=0; j<parts.size()-1; j++)
|
||||
builder = builder->endNested();
|
||||
if(parts.back().isArray())
|
||||
builder = builder->endNested();
|
||||
}
|
||||
|
||||
if(!mem.pvname.empty()) {
|
||||
@@ -744,8 +749,6 @@ FieldName::FieldName(const std::string& pv)
|
||||
}
|
||||
if(parts.empty())
|
||||
throw std::runtime_error("Empty field name");
|
||||
if(parts.back().isArray())
|
||||
throw std::runtime_error("leaf field may not have sub-script : "+pv);
|
||||
}
|
||||
|
||||
epics::pvData::PVFieldPtr
|
||||
|
||||
+5
-1
@@ -40,19 +40,23 @@ namespace pva = epics::pvAccess;
|
||||
|
||||
DBCH::DBCH(dbChannel *ch) :chan(ch)
|
||||
{
|
||||
if(!chan)
|
||||
throw std::invalid_argument("NULL channel");
|
||||
prepare();
|
||||
}
|
||||
|
||||
DBCH::DBCH(const std::string& name)
|
||||
:chan(dbChannelCreate(name.c_str()))
|
||||
{
|
||||
if(!chan)
|
||||
throw std::invalid_argument(SB()<<"invalid channel: "<<name);
|
||||
prepare();
|
||||
}
|
||||
|
||||
void DBCH::prepare()
|
||||
{
|
||||
if(!chan)
|
||||
throw std::invalid_argument("NULL channel");
|
||||
throw std::invalid_argument(SB()<<"NULL channel");
|
||||
if(dbChannelOpen(chan)) {
|
||||
dbChannelDelete(chan);
|
||||
throw std::invalid_argument(SB()<<"Failed to open channel "<<dbChannelName(chan));
|
||||
|
||||
+1
-1
@@ -255,7 +255,7 @@ struct LocalFL
|
||||
:pfl(pfl)
|
||||
,ours(false)
|
||||
{
|
||||
if(!pfl && (ellCount(&pchan->pre_chain)!=0 || ellCount(&pchan->pre_chain)==0)) {
|
||||
if(!pfl && (ellCount(&pchan->pre_chain)!=0 || ellCount(&pchan->post_chain)!=0)) {
|
||||
pfl = db_create_read_log(pchan);
|
||||
if(pfl) {
|
||||
ours = true;
|
||||
|
||||
@@ -7,6 +7,7 @@ link("pva", "lsetPVA")
|
||||
|
||||
# from demo.cpp
|
||||
device(waveform, CONSTANT, devWfPDBDemo, "QSRV Demo")
|
||||
device(waveform, CONSTANT, devWfPDBDemoRepeat, "QSRV Demo Replicate")
|
||||
device(longin, CONSTANT, devLoPDBUTag, "QSRV Set UTag")
|
||||
# from imagedemo.c
|
||||
function(QSRV_image_demo)
|
||||
|
||||
@@ -6,6 +6,7 @@ registrar(installPVAAddLinkHook)
|
||||
|
||||
# from demo.cpp
|
||||
device(waveform, CONSTANT, devWfPDBDemo, "QSRV Demo")
|
||||
device(waveform, CONSTANT, devWfPDBDemoRepeat, "QSRV Demo Replicate")
|
||||
device(longin, CONSTANT, devLoPDBUTag, "QSRV Set UTag")
|
||||
# from imagedemo.c
|
||||
function(QSRV_image_demo)
|
||||
|
||||
+2
-1
@@ -52,7 +52,8 @@ TESTPROD_HOST += testpvalink
|
||||
testpvalink_SRCS += testpvalink.cpp
|
||||
testpvalink_SRCS += pvaLinkTestIoc_registerRecordDeviceDriver.cpp
|
||||
testpvalink_LIBS += qsrv
|
||||
TESTS += testpvalink
|
||||
# too many false positive failure
|
||||
#TESTS += testpvalink
|
||||
|
||||
TESTPROD_HOST += testgroupconfig
|
||||
testgroupconfig_SRCS += testgroupconfig
|
||||
|
||||
Reference in New Issue
Block a user