Commit f62e469f authored by Claes Sjofors's avatar Claes Sjofors

IO Buffer input and Buffer output signals/channels added

parent ffd49309
......@@ -885,6 +885,23 @@ static pwr_tStatus mb_init_channels( io_tCtx ctx, io_sAgent *ap, io_sRack *rp)
cardp = rp->cardlist;
unsigned int prev_input_area_offset = 0;
unsigned int prev_output_area_offset = 0;
unsigned int input_area_offset = 0;
unsigned int output_area_offset = 0;
unsigned int input_area_chansize = 0;
unsigned int output_area_chansize = 0;
while(cardp) {
local_card = calloc(1, sizeof(*local_card));
cardp->Local = local_card;
local_card->input_area = (void *) &(op->Inputs) + input_area_offset +
input_area_chansize;
local_card->output_area = (void *) &(op->Outputs) + output_area_offset +
output_area_chansize;
#if 0
input_counter = 0;
output_counter = 0;
card_input_counter = 0;
......@@ -892,9 +909,6 @@ static pwr_tStatus mb_init_channels( io_tCtx ctx, io_sAgent *ap, io_sRack *rp)
latent_input_counter = 0;
latent_output_counter = 0;
while(cardp) {
local_card = calloc(1, sizeof(*local_card));
cardp->Local = local_card;
input_counter = input_counter + card_input_counter + latent_input_counter;
output_counter = output_counter + card_output_counter + latent_output_counter;
local_card->input_area = (void *) &(op->Inputs) + input_counter;
......@@ -1039,15 +1053,36 @@ static pwr_tStatus mb_init_channels( io_tCtx ctx, io_sAgent *ap, io_sRack *rp)
break;
} /* End - switch ... */
#endif
io_bus_card_init( ctx, cardp, &input_area_offset, &input_area_chansize,
&output_area_offset, &output_area_chansize,
pwr_eByteOrderingEnum_BigEndian);
local_card->input_size = input_area_offset + input_area_chansize -
prev_input_area_offset;
local_card->output_size = output_area_offset + output_area_chansize -
prev_output_area_offset;
#if 0
local_card->input_size = card_input_counter + latent_input_counter;
local_card->output_size = card_output_counter + latent_output_counter;
#endif
prev_input_area_offset = input_area_offset + input_area_chansize;
prev_output_area_offset = output_area_offset + output_area_chansize;
cardp = cardp->next;
}
local->input_size = input_area_offset + input_area_chansize;
local->output_size = output_area_offset + output_area_chansize;
#if 0
local->input_size = input_counter + card_input_counter + latent_input_counter;
local->output_size = output_counter + card_output_counter + latent_output_counter;
#endif
return IO__SUCCESS;
}
......
......@@ -2279,7 +2279,10 @@ create_active_io ()
pwr_tStatus sts;
pwr_tObjid oid;
pwr_tAttrRef aref;
int ai_cnt, ao_cnt, av_cnt, di_cnt, do_cnt, dv_cnt, ii_cnt, io_cnt, iv_cnt, co_cnt;
int ai_cnt, ao_cnt, av_cnt, di_cnt, do_cnt, dv_cnt, ii_cnt, io_cnt, iv_cnt, co_cnt, bi_cnt, bo_cnt;
int bi_size, bo_size;
pwr_tCid subcid;
pwr_tAttrRef actval_aref;
// Count number of signals
ai_cnt = 0;
......@@ -2346,6 +2349,52 @@ create_active_io ()
sts = gdh_GetNextAttrRef( pwr_cClass_Co, &aref, &aref))
co_cnt++;
bi_cnt = 0;
bi_size = 0;
for ( sts = gdh_GetSubClassList( pwr_cClass_Bi, &subcid);
ODD(sts);
sts = gdh_GetNextSubClass( pwr_cClass_Bi, subcid, &subcid)) {
pwr_tTypeId a_type;
unsigned int a_size, a_offs, a_dim;
for ( sts = gdh_GetClassListAttrRef( subcid, &aref);
ODD(sts);
sts = gdh_GetNextAttrRef( subcid, &aref, &aref)) {
sts = gdh_ArefANameToAref( &aref, "ActualValue", &actval_aref);
if ( EVEN(sts)) continue;
sts = gdh_GetAttributeCharAttrref( &actval_aref, &a_type, &a_size, &a_offs, &a_dim);
if ( EVEN(sts)) continue;
bi_cnt += a_dim;
bi_size = pwr_AlignLW(bi_size);
bi_size += a_size;
}
}
bo_cnt = 0;
bo_size = 0;
for ( sts = gdh_GetSubClassList( pwr_cClass_Bo, &subcid);
ODD(sts);
sts = gdh_GetNextSubClass( pwr_cClass_Bo, subcid, &subcid)) {
pwr_tTypeId a_type;
unsigned int a_size, a_offs, a_dim;
for ( sts = gdh_GetClassListAttrRef( subcid, &aref);
ODD(sts);
sts = gdh_GetNextAttrRef( subcid, &aref, &aref)) {
sts = gdh_ArefANameToAref( &aref, "ActualValue", &actval_aref);
if ( EVEN(sts)) continue;
sts = gdh_GetAttributeCharAttrref( &actval_aref, &a_type, &a_size, &a_offs, &a_dim);
if ( EVEN(sts)) continue;
bo_cnt += a_dim;
bo_size = pwr_AlignLW(bo_size);
bo_size += a_size;
}
}
sts = gdh_CreateObject("pwrNode-active", pwr_eClass_NodeHier, 0,
&oid, pwr_cNObjid, 0, pwr_cNObjid);
sts = gdh_CreateObject("pwrNode-active-io", pwr_eClass_NodeHier, 0,
......@@ -2383,6 +2432,12 @@ create_active_io ()
sts = gdh_CreateObject("pwrNode-active-io-iv", pwr_cClass_IvArea,
iv_cnt * sizeof(((pwr_sClass_IvArea*)0)->Value[0]),
&oid, pwr_cNObjid, 0, pwr_cNObjid);
sts = gdh_CreateObject("pwrNode-active-io-bi", pwr_cClass_BiArea,
bi_size,
&oid, pwr_cNObjid, 0, pwr_cNObjid);
sts = gdh_CreateObject("pwrNode-active-io-bo", pwr_cClass_BoArea,
bo_size,
&oid, pwr_cNObjid, 0, pwr_cNObjid);
sts = gdh_CreateObject("pwrNode-active-io-dv_init", pwr_cClass_InitArea,
dv_cnt * sizeof(((pwr_sClass_InitArea*)0)->Value[0]),
&oid, pwr_cNObjid, 0, pwr_cNObjid);
......@@ -2410,6 +2465,18 @@ create_active_io ()
sts = gdh_CreateObject("pwrNode-active-io-io_init", pwr_cClass_InitArea,
io_cnt * sizeof(((pwr_sClass_InitArea*)0)->Value[0]),
&oid, pwr_cNObjid, 0, pwr_cNObjid);
sts = gdh_CreateObject("pwrNode-active-io-bi_init", pwr_cClass_InitArea,
bi_cnt * sizeof(((pwr_sClass_InitArea*)0)->Value[0]),
&oid, pwr_cNObjid, 0, pwr_cNObjid);
sts = gdh_CreateObject("pwrNode-active-io-bi_initsize", pwr_cClass_InitArea,
bi_cnt * sizeof(((pwr_sClass_InitArea*)0)->Value[0]),
&oid, pwr_cNObjid, 0, pwr_cNObjid);
sts = gdh_CreateObject("pwrNode-active-io-bo_init", pwr_cClass_InitArea,
bo_cnt * sizeof(((pwr_sClass_InitArea*)0)->Value[0]),
&oid, pwr_cNObjid, 0, pwr_cNObjid);
sts = gdh_CreateObject("pwrNode-active-io-bo_initsize", pwr_cClass_InitArea,
bo_cnt * sizeof(((pwr_sClass_InitArea*)0)->Value[0]),
&oid, pwr_cNObjid, 0, pwr_cNObjid);
}
static void
......@@ -2463,6 +2530,10 @@ delete_old_io ()
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-iv", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-bi", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-bo", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-dv_init", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-av_init", &oid);
......@@ -2481,6 +2552,14 @@ delete_old_io ()
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-io_init", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-bi_init", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-bi_initsize", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-bo_init", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io-bo_initsize", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old-io", &oid);
if(ODD(sts)) gdh_DeleteObject(oid);
sts = gdh_NameToObjid("pwrNode-old", &oid);
......
......@@ -509,6 +509,8 @@ link_io_base_areas (
dlink_area((plc_sDlink *)&pp->base.ii_a, "pwrNode-active-io-ii", pp->IOHandler->IiCount * sizeof(pwr_tInt32));
dlink_area((plc_sDlink *)&pp->base.io_a, "pwrNode-active-io-io", pp->IOHandler->IoCount * sizeof(pwr_tInt32));
dlink_area((plc_sDlink *)&pp->base.iv_a, "pwrNode-active-io-iv", pp->IOHandler->IvCount * sizeof(pwr_tInt32));
dlink_area((plc_sDlink *)&pp->base.bi_a, "pwrNode-active-io-bi", pp->IOHandler->BiSize);
dlink_area((plc_sDlink *)&pp->base.bo_a, "pwrNode-active-io-bo", pp->IOHandler->BoSize);
dlink_area((plc_sDlink *)&pp->base.av_i, "pwrNode-active-io-av_init", pp->IOHandler->AvCount * sizeof(pwr_tUInt64));
dlink_area((plc_sDlink *)&pp->base.dv_i, "pwrNode-active-io-dv_init", pp->IOHandler->DvCount * sizeof(pwr_tUInt64));
dlink_area((plc_sDlink *)&pp->base.iv_i, "pwrNode-active-io-iv_init", pp->IOHandler->IvCount * sizeof(pwr_tUInt64));
......@@ -518,6 +520,10 @@ link_io_base_areas (
dlink_area((plc_sDlink *)&pp->base.do_i, "pwrNode-active-io-do_init", pp->IOHandler->DoCount * sizeof(pwr_tUInt64));
dlink_area((plc_sDlink *)&pp->base.ii_i, "pwrNode-active-io-ii_init", pp->IOHandler->IiCount * sizeof(pwr_tUInt64));
dlink_area((plc_sDlink *)&pp->base.io_i, "pwrNode-active-io-io_init", pp->IOHandler->IoCount * sizeof(pwr_tUInt64));
dlink_area((plc_sDlink *)&pp->base.bi_i, "pwrNode-active-io-bi_init", pp->IOHandler->BiCount * sizeof(pwr_tUInt64));
dlink_area((plc_sDlink *)&pp->base.bi_isize, "pwrNode-active-io-bi_initsize", pp->IOHandler->BiCount * sizeof(pwr_tUInt64));
dlink_area((plc_sDlink *)&pp->base.bo_i, "pwrNode-active-io-bo_init", pp->IOHandler->BoCount * sizeof(pwr_tUInt64));
dlink_area((plc_sDlink *)&pp->base.bo_isize, "pwrNode-active-io-bo_initsize", pp->IOHandler->BoCount * sizeof(pwr_tUInt64));
}
/* Link to I/O copy areas.
......@@ -565,6 +571,12 @@ link_io_copy_areas (
tp->copy.iv_a = pp->base.iv_a;
tp->copy.iv_a.p = calloc(1, tp->copy.iv_a.size);
tp->copy.bi_a = pp->base.bi_a;
tp->copy.bi_a.p = calloc(1, tp->copy.bi_a.size);
tp->copy.bo_a = pp->base.bo_a;
tp->copy.bo_a.p = calloc(1, tp->copy.bo_a.size);
}
static void
......@@ -742,6 +754,20 @@ save_values (
if (p != NULL)
*p = pp->base.io_a.p->Value[i];
}
for (i = 0; i < pp->IOHandler->BiCount; i++) {
char *p = gdh_TranslateRtdbPointer(pp->base.bi_i.p->Value[i]);
unsigned int idx = pp->base.bi_isize.p->Value[i] >> 32;
unsigned int size = 0xFFFFFFFF & pp->base.bi_isize.p->Value[i];
if (p != NULL && idx + size <= pp->IOHandler->BiSize)
memcpy( p, &pp->base.bi_a.p->Value[idx], size);
}
for (i = 0; i < pp->IOHandler->BoCount; i++) {
char *p = gdh_TranslateRtdbPointer(pp->base.bo_i.p->Value[i]);
unsigned int idx = pp->base.bo_isize.p->Value[i] >> 32;
unsigned int size = 0xFFFFFFFF & pp->base.bo_isize.p->Value[i];
if (p != NULL && idx + size <= pp->IOHandler->BoSize)
memcpy( p, &pp->base.bo_a.p->Value[idx], size);
}
}
static void
......@@ -796,4 +822,18 @@ set_values (
if (p != NULL)
pp->base.io_a.p->Value[i] = *p;
}
for (i = 0; i < pp->IOHandler->BiCount; i++) {
char *p = gdh_TranslateRtdbPointer(pp->base.bi_i.p->Value[i]);
unsigned int idx = pp->base.bi_isize.p->Value[i] >> 32;
unsigned int size = 0xFFFFFFFF & pp->base.bi_isize.p->Value[i];
if (p != NULL && idx + size <= pp->IOHandler->BiSize)
memcpy( &pp->base.bi_a.p->Value[idx], p, size);
}
for (i = 0; i < pp->IOHandler->BoCount; i++) {
char *p = gdh_TranslateRtdbPointer(pp->base.bo_i.p->Value[i]);
unsigned int idx = pp->base.bo_isize.p->Value[i] >> 32;
unsigned int size = 0xFFFFFFFF & pp->base.bo_isize.p->Value[i];
if (p != NULL && idx + size <= pp->IOHandler->BoSize)
memcpy( &pp->base.bo_a.p->Value[idx], p, size);
}
}
......@@ -2983,6 +2983,28 @@ void cdh_CutNameSegments (
}
//! Get attribute size.
/*!
Get the attribute size from parinfo.
*/
pwr_tUInt32 cdh_AttrSize( pwr_sParInfo *info)
{
if ( info->Flags & PWR_MASK_POINTER && !(info->Flags & PWR_MASK_PRIVATE))
/* Return pointer size, info size contains size of pointed entity */
return sizeof(pwr_tUInt64) * info->Elements;
return info->Size;
}
//! Get attribute array element size.
/*!
Get the array elements size of an array attribut from parinfo.
*/
pwr_tUInt32 cdh_AttrElemSize( pwr_sParInfo *info)
{
return cdh_AttrSize( info) / info->Elements;
}
/*@}*/
......
......@@ -1066,6 +1066,11 @@ pwr_tStatus cdh_NextObjectName( char *t, const char *s);
void cdh_CutNameSegments( char *outname, char *name, int segments);
pwr_tUInt32 cdh_AttrSize( pwr_sParInfo *info);
pwr_tUInt32 cdh_AttrElemSize( pwr_sParInfo *info);
/*@}*/
#ifdef __cplusplus
......
......@@ -5011,3 +5011,38 @@ void gdh_RegisterLogFunction( void (*func)(char *, void *, unsigned int))
{
gdh_log_cb = func;
}
pwr_tStatus gdh_GetSubClassList( pwr_tCid cid, pwr_tCid *subcid)
{
return gdh_GetNextSubClass( cid, 0, subcid);
}
pwr_tStatus gdh_GetNextSubClass( pwr_tCid cid, pwr_tCid psubcid, pwr_tCid *subcid)
{
pwr_tStatus sts;
pwr_tOid oid;
pwr_tCid cd_cid;
pwr_tCid super_cid;
if ( psubcid == 0)
sts = gdh_GetClassList( pwr_eClass_ClassDef, &oid);
else {
oid = cdh_ClassIdToObjid( psubcid);
sts = gdh_GetNextObject( oid, &oid);
}
for ( ; ODD(sts); sts = gdh_GetNextObject( oid, &oid)) {
cd_cid = cdh_ClassObjidToId( oid);
sts = gdh_GetSuperClass( cd_cid, &super_cid, pwr_cNOid);
if ( EVEN(sts))
continue;
if ( super_cid == cid) {
*subcid = cd_cid;
return GDH__SUCCESS;
}
}
return GDH__NOSUCHCLASS;
}
......@@ -825,6 +825,20 @@ gdh_RegisterLogFunction(
void (*func)(char *, void *, unsigned int)
);
pwr_tStatus
gdh_GetSubClassList(
pwr_tCid cid,
pwr_tCid *subcid
);
pwr_tStatus
gdh_GetNextSubClass(
pwr_tCid cid,
pwr_tCid psubcid,
pwr_tCid *subcid
);
/** @} */
#if defined __cplusplus
......
This diff is collapsed.
......@@ -126,6 +126,9 @@ typedef struct {
pwr_tUInt32 size; /* Size of channel in byte */
pwr_tUInt32 offset; /* Offset to channel in card */
pwr_tUInt32 mask; /* Mask for bit oriented channels */
pwr_eType SigType; /* Type of buffer signal */
pwr_tUInt32 SigElem; /* Elements of buffer array signal */
pwr_tUInt32 SigStrSize; /* Size of buffer signal element */
pwr_tUInt32 udata; /* User defined data */
} io_sChannel;
......@@ -264,10 +267,18 @@ pwr_tStatus io_AiRangeToCoef(
io_sChannel *chanp
);
pwr_tStatus io_BiRangeToCoef(
io_sChannel *chanp
);
pwr_tStatus io_AoRangeToCoef(
io_sChannel *chanp
);
pwr_tStatus io_BoRangeToCoef(
io_sChannel *chanp
);
void io_ConvertAi (
pwr_sClass_ChanAi *cop,
pwr_tInt16 rawvalue,
......
This diff is collapsed.
......@@ -355,6 +355,9 @@ mvol_AnameToAttribute (
if (ap->idx > ap->adef->Info.Elements - 1 && !(ap->adef->Info.Flags & PWR_MASK_DYNAMIC))
pwr_Return(NULL, sts, GDH__SUBSCRIPT);
ap->size /= ap->elem;
if ( ap->flags.b.Indirect)
ap->offs += sizeof(pwr_tUInt64) * ap->idx;
else
ap->offs += ap->size * ap->idx;
ap->elem = 1;
}
......@@ -391,6 +394,7 @@ mvol_ArefToAttribute (
int idx = UINT_MAX;
char idxstr[20];
pwr_tBoolean noDot = TRUE;
int parsize;
#if 0
......@@ -449,8 +453,12 @@ mvol_ArefToAttribute (
}
if ( !acp->attr[i].flags.b.isclass) {
if ( acp->attr[i].elem > 1 || acp->attr[i].flags.b.dynamic)
if ( acp->attr[i].elem > 1 || acp->attr[i].flags.b.dynamic) {
if ( acp->attr[i].flags.b.pointer)
idx = (arp->Offset - offset) / sizeof(pwr_tUInt64);
else
idx = (arp->Offset - offset) / (acp->attr[i].size / acp->attr[i].elem);
}
break;
}
if ( arp->Size == 0 && arp->Flags.b.ObjectAttr && offset == arp->Offset &&
......@@ -493,7 +501,12 @@ mvol_ArefToAttribute (
ap->adef = param;
ap->idx = UINT_MAX; /* Guess, no index. */
if (arp->Size > (param->Info.Size / param->Info.Elements) || arp->Size == 0) {
if (param->Info.Flags & PWR_MASK_POINTER)
parsize = sizeof(pwr_tUInt64);
else
parsize = param->Info.Size / param->Info.Elements;
if (arp->Size > parsize || arp->Size == 0) {
/* If this is the first attribute, then match whole object
otherwise say the attribute is ok! */
......@@ -526,6 +539,9 @@ mvol_ArefToAttribute (
if (ap->idx != UINT_MAX) {
ap->size /= ap->elem;
if ( param->Info.Flags & PWR_MASK_POINTER)
ap->offs += sizeof(pwr_tUInt64) * ap->idx;
else
ap->offs += ap->size * ap->idx;
ap->elem = 1;
}
......@@ -717,6 +733,9 @@ mvol_LinkClass (
cp->attr[i].offs = abp->Info.Offset;
cp->attr[i].size = abp->Info.Size;
cp->attr[i].elem = abp->Info.Elements;
if ( abp->Info.Flags & PWR_MASK_POINTER && !(abp->Info.Flags & PWR_MASK_PRIVATE))
cp->attr[i].moffset = abp->Info.Offset + sizeof(pwr_tUInt64) * abp->Info.Elements - 1;
else
cp->attr[i].moffset = abp->Info.Offset + abp->Info.Size - 1;
cp->attr[i].tid = abp->TypeRef;
coid.pwr = aop->g.oid;
......
......@@ -108,6 +108,8 @@ typedef struct {
IO_AREA(pwr_sClass_IiArea) ii_a;
IO_AREA(pwr_sClass_IoArea) io_a;
IO_AREA(pwr_sClass_IvArea) iv_a;
IO_AREA(pwr_sClass_BiArea) bi_a;
IO_AREA(pwr_sClass_BoArea) bo_a;
IO_AREA(pwr_sClass_InitArea) av_i;
IO_AREA(pwr_sClass_InitArea) dv_i;
IO_AREA(pwr_sClass_InitArea) iv_i;
......@@ -117,6 +119,10 @@ typedef struct {
IO_AREA(pwr_sClass_InitArea) ao_i;
IO_AREA(pwr_sClass_InitArea) do_i;
IO_AREA(pwr_sClass_InitArea) io_i;
IO_AREA(pwr_sClass_InitArea) bi_i;
IO_AREA(pwr_sClass_InitArea) bi_isize;
IO_AREA(pwr_sClass_InitArea) bo_i;
IO_AREA(pwr_sClass_InitArea) bo_isize;
} plc_sArea;
#ifndef rt_io_base_h
......
......@@ -219,12 +219,28 @@ plc_rtdbref (
index is stored in the object itself. */
if (local_object) {
switch (la->ObjType) {
case pwr_cClass_Di:
case pwr_cClass_Ai:
case pwr_cClass_Ii:
case pwr_cClass_Do:
case pwr_cClass_Ao:
case pwr_cClass_Io:
case pwr_cClass_Dv:
case pwr_cClass_Av:
case pwr_cClass_Iv:
case pwr_cClass_Co:
sts = plc_GetObjectAttrValue(la->ObjType, la->AttrRef, ".ValueIndex", &Index, sizeof(pwr_tInt32));
if (EVEN(sts)) {
errh_Error("plc_GetObjectAttrValue object %s.ValueIndex\n%m", cdh_ObjidToString(NULL, la->AttrRef.Objid, 0), sts);
GUARD_DL( la->Pointer, la->Size );
continue;
}
break;
default: {
/* Bi or Bo, get value, get valueindex later */
}
}
}
......@@ -298,7 +314,39 @@ plc_rtdbref (
strcpy(aname, ".RawValue" );
}
break;
default: {
pwr_tCid scid;
pwr_tAttrRef oaref;
/* Get ValueIndex that is sibling attribute to the attrref */
sts = gdh_AttrArefToObjectAref( &la->AttrRef, &oaref);
if ( ODD(sts))
sts = plc_GetObjectAttrValue(la->ObjType, oaref, ".ValueIndex", &Index, sizeof(pwr_tInt32));
if ( EVEN(sts)) {
errh_Error("plc_GetObjectAttrValue object %s.ValueIndex\n%m", cdh_ObjidToString(NULL, la->AttrRef.Objid, 0), sts);
GUARD_DL( la->Pointer, la->Size );
continue;
}
/* Bi or Bo subclass */
sts = gdh_GetSuperClass( la->ObjType, &scid, pwr_cNOid);
if ( EVEN(sts)) break;
switch ( scid) {
case pwr_cClass_Bi:
if (la->UseCode == UC_READ && local_object)
*la->Pointer = (char *)&tp->copy.bi_a.p->Value[Index] + la->Offset;
break;
case pwr_cClass_Bo:
if (la->UseCode == UC_READ && local_object)
*la->Pointer = (char *)&tp->copy.bo_a.p->Value[Index] + la->Offset;
break;
}
strcpy(aname, "" );
}
}
if (*la->Pointer != NULL)
continue;
......
......@@ -48,57 +48,89 @@
/* Direct link table */
typedef struct
{
typedef struct {
void **Pointer;
pwr_sAttrRef AttrRef;
pwr_tClassId ObjType;
pwr_tUInt32 Size;
pwr_tUInt32 UseCode;
} plc_t_rtdbref;
pwr_tUInt32 Offset;
} plc_t_rtdbref;
typedef struct {
pwr_tBoolean ActualValue;
} plc_sClass_Di;
} plc_sClass_Di;
typedef struct {
pwr_tBoolean ActualValue;
} plc_sClass_Do;
} plc_sClass_Do;
typedef struct {
pwr_tBoolean ActualValue;
} plc_sClass_Po;
} plc_sClass_Po;
typedef struct {
pwr_tBoolean ActualValue;
} plc_sClass_Dv;
} plc_sClass_Dv;
typedef struct {
pwr_tInt32 RawValue;
} plc_sClass_Co;
} plc_sClass_Co;
typedef struct {
pwr_tFloat32 ActualValue;
} plc_sClass_Ai;
} plc_sClass_Ai;
typedef struct {
pwr_tFloat32 ActualValue;
} plc_sClass_Ao;
} plc_sClass_Ao;
typedef struct {
pwr_tFloat32 ActualValue;
} plc_sClass_Av;
} plc_sClass_Av;
typedef struct {
pwr_tInt32 ActualValue;
} plc_sClass_Ii;
} plc_sClass_Ii;
typedef struct {
pwr_tInt32 ActualValue;
} plc_sClass_Io;
} plc_sClass_Io;
typedef struct {
pwr_tInt32 ActualValue;
} plc_sClass_Iv;
typedef struct {
pwr_tBoolean ActualValue;
} plc_sClass_BBoolean;
typedef struct {
pwr_tInt64 ActualValue;
} plc_sClass_BInt64;
typedef struct {
pwr_tInt32 ActualValue;
} plc_sClass_Iv;
} plc_sClass_BInt32;
typedef struct {
pwr_tInt16 ActualValue;
} plc_sClass_BInt16;
typedef struct {
pwr_tInt8 ActualValue;
} plc_sClass_BInt8;
typedef struct {
pwr_tFloat32 ActualValue;
} plc_sClass_BFloat32;
typedef struct {
pwr_tFloat64 ActualValue;
} plc_sClass_BFloat64;
typedef struct {
char ActualValue[1];
} plc_sClass_BString;
......@@ -309,6 +309,104 @@
#define cstoii_exec(obj,in,cond) \
if ( cond ) obj->ActualValue = in;
/*_*
StoBiInt32
store buffer input (Simulate)
@aref stobiint32 StoBiInt32
*/
#define StoBiInt32_exec(obj,in) \
obj->ActualValue = in;
/*_*
CStoBiInt32
store conditionally into buffer input (Simulate)
@aref cstobiint32 CStoBiInt32
*/
#define CStoBiInt32_exec(obj,in,cond) \
if ( cond ) obj->ActualValue = in;
/*_*
StoBoInt32
store buffer output
@aref stoboint32 StoBoInt32
*/
#define StoBoInt32_exec(obj,in) \
obj->ActualValue = in;
/*_*
CStoBoInt32
store conditionally into buffer output
@aref cstoboint32 CStoBoInt32
*/
#define CStoBoInt32_exec(obj,in,cond) \
if ( cond ) obj->ActualValue = in;
/*_*
StoBiFloat32
store buffer input (Simulate)
@aref stobifloat32 StoBiFloat32
*/
#define StoBiFloat32_exec(obj,in) \
obj->ActualValue = in;
/*_*
CStoBiFloat32
store conditionally into buffer input (Simulate)
@aref cstobifloat32 CStoBiFloat32
*/
#define CStoBiFloat32_exec(obj,in,cond) \
if ( cond ) obj->ActualValue = in;
/*_*
StoBoFloat32
store buffer output
@aref stobofloat32 StoBoFloat32
*/
#define StoBoFloat32_exec(obj,in) \
obj->ActualValue = in;
/*_*
CStoBoFloat32
store conditionally into buffer output
@aref cstobofloat32 CStoBoFloat32
*/
#define CStoBoFloat32_exec(obj,in,cond) \
if ( cond ) obj->ActualValue = in;
/*_*
StoBiString80
store buffer input (Simulate)
@aref stobistring80 StoBiString80
*/
#define StoBiString80_exec(obj,in) \
strncpy( obj->ActualValue, in, 80);
/*_*
CStoBiString80
store conditionally buffer input (Simulate)
@aref cstobistring80 CStoBiString80
*/
#define CStoBiString80_exec(obj,in,cond) \
if ( cond) strncpy( obj->ActualValue, in, 80);
/*_*
StoBoString80
store buffer output
@aref stobostring80 StoBoString80
*/
#define StoBoString80_exec(obj,in) \
strncpy( obj->ActualValue, in, 80);
/*_*
CStoBoString80
store conditionally buffer input
@aref cstobostring80 CStoBoString80
*/
#define CStoBoString80_exec(obj,in,cond) \
if ( cond) strncpy( obj->ActualValue, in, 80);
/*_*
AtoI
@aref atoi AtoI
......
......@@ -183,6 +183,8 @@ plc_thread (
memcpy(tp->copy.ii_a.p, tp->pp->base.ii_a.p, tp->copy.ii_a.size);
memcpy(tp->copy.io_a.p, tp->pp->base.io_a.p, tp->copy.io_a.size);
memcpy(tp->copy.iv_a.p, tp->pp->base.iv_a.p, tp->copy.iv_a.size);
memcpy(tp->copy.bi_a.p, tp->pp->base.bi_a.p, tp->copy.bi_a.size);
memcpy(tp->copy.bo_a.p, tp->pp->base.bo_a.p, tp->copy.bo_a.size);
thread_MutexUnlock(&tp->pp->io_copy_mutex);
......@@ -267,6 +269,8 @@ scan (
memcpy(tp->copy.ii_a.p, pp->base.ii_a.p, tp->copy.ii_a.size);
memcpy(tp->copy.io_a.p, pp->base.io_a.p, tp->copy.io_a.size);
memcpy(tp->copy.iv_a.p, pp->base.iv_a.p, tp->copy.iv_a.size);
memcpy(tp->copy.bi_a.p, pp->base.bi_a.p, tp->copy.bi_a.size);
memcpy(tp->copy.bo_a.p, pp->base.bo_a.p, tp->copy.bo_a.size);
thread_MutexUnlock(&pp->io_copy_mutex);
......
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bi.wb_load -- Defines the class Bi.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Buffer input signal base class
! Buffer input signal base class.
!
! This class is used as a base class for Buffer input signals.
! The buffer signal subclass should contain an ActualValue attribute and
! an InitialValue attribute.
!
! ActualValue can be an array Int32 or Float32, or a String, and should be
! specified as a pointer in the flags word.
! InitalValue shoud be of the same size and type as ActualValue, and should
! be placed after ActualValue.
!
! In the size attribute, the total size in bytes of ActualValue should be
! specified. If for example ActualValue is an Int32 array of 20 elements,
! size is 80.
!*/
Object Bi $ClassDef 558
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "Bi"
EndBody
!/**
! Optional text, for example the name of the signal or
! what it represents.
!*/
Object Description $Attribute 1
Body SysBody
Attr TypeRef = "pwrs:Type-$String80"
EndBody
EndObject
!/**
! Name of the associated channel object.
!*/
Object SigChanCon $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$AttrRef"
EndBody
EndObject
!/**
! Index in the Value array at the BiArea objects
! that are used for base frequency and partial frequency
! samples. Initiated at boot time by rt_ini.
!*/
Object ValueIndex $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt32"
Attr Flags |= PWR_MASK_INVISIBLE
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_PRIVATE
EndBody
EndObject
!/**
! Size of actual value buffer in bytes.
!*/
Object Size $Attribute 4
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt32"
EndBody
EndObject
!/**
! The lower respectively upper limits in the bar graph at
! presentation of ActualValue in the object display.
!*/
Object PresMaxLimit $Attribute 12
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
EndBody
EndObject
Object PresMinLimit $Attribute 13
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
EndBody
EndObject
!/**
! @Summary A XttGraph object that will open a graph for this object.
! A XttGraph object that will open a graph that contains data for
! this object. This graph can be opened from the popup menu for
! this object.
!*/
Object DefGraph $Attribute 5
Body SysBody
Attr TypeRef = "pwrs:Type-$AttrRef"
EndBody
EndObject
!/**
! @Summary A trend object that displays a trend for this object.
! A DsTrend or PlotGroup object that contains a trend for this object.
! The trend can be opened from the popup menu for this object.
!*/
Object DefTrend $Attribute 6
Body SysBody
Attr TypeRef = "pwrs:Type-$AttrRef"
EndBody
EndObject
!/**
! @Summary A help topic for this hierarchy.
! A help topic in the xtt help file that contains help for this hierarchy.
! The help can be displayed from the popup menu for this object.
!*/
Object HelpTopic $Attribute 7
Body SysBody
Attr TypeRef = "pwrs:Type-$String40"
EndBody
EndObject
!/**
! @Summary A URL to the data sheet for the equipment in this hierarchy.
! A URL to the data sheet for the equipment in this hierarchy.
! The data sheet can be displayed from the popup menu for this object.
!*/
Object DataSheet $Attribute 8
Body SysBody
Attr TypeRef = "pwrs:Type-$URL"
EndBody
EndObject
!/**
! @Summary An URL to the circuit diagram for the equipment in this hierarchy.
! An URL to the circuit diagram for the equipment in this hierarchy.
! The circuit diagram can be displayed from the popup menu for this object.
!
! If the attribute is empty, the CircuitDiagram method will look at the
! closest ancestor that has supplied a value in CircuitDiagram and use this
! URL instead. If this behavior is unwanted, put the string 'Disabled' in the
! attribute. This will disable the CircuitDiagram method for this object, and
! for any child with empty CircuitDiagram attribute.
!*/
Object CircuitDiagram $Attribute 9
Body SysBody
Attr TypeRef = "pwrs:Type-$URL"
EndBody
EndObject
!/**
! @Summary A photograph of the plant.
! A photograph of the plant.
! A URL to a photo of the equipment.
! The photo can be displayed from the popup menu for this object.
!*/
Object Photo $Attribute 14
Body SysBody
Attr PgmName = "Photo"
Attr TypeRef = "pwrs:Type-$URL"
EndBody
EndObject
!/**
! @Summary A note of the current status of the object.
! A note of the current status of the object.
! Notes are used to exchange information between operators. It is handled
! by the Note method.
!*/
Object Note $Attribute 11
Body SysBody
Attr TypeRef = "pwrs:Type-$String80"
EndBody
EndObject
EndObject
Object ConfiguratorPoson $Menu
Object Pointed $Menu
Object Connect $MenuButton
Body SysBody
Attr ButtonName = "Connect Channel"
Attr MethodName = "$AttrRef-Connect"
Attr MethodArguments[0] = "SigChanCon"
Attr MethodArguments[1] = "ChanBi"
Attr FilterName = "$AttrRef-IsOkConnect"
Attr FilterArguments[0] = "SigChanCon"
Attr FilterArguments[1] = "ChanBi"
EndBody
EndObject
Object ConnectGraph $MenuButton
Body SysBody
Attr ButtonName = "Connect Graph"
Attr MethodName = "$AttrRef-Connect"
Attr MethodArguments[0] = "DefGraph"
Attr MethodArguments[1] = "XttGraph"
Attr FilterName = "$AttrRef-IsOkConnect"
Attr FilterArguments[0] = "DefGraph"
Attr FilterArguments[1] = "XttGraph"
EndBody
EndObject
Object ConnectTrend $MenuButton
Body SysBody
Attr ButtonName = "Connect Trend"
Attr MethodName = "$AttrRef-Connect"
Attr MethodArguments[0] = "DefTrend"
Attr MethodArguments[1] = "DsTrend,PlotGroup"
Attr FilterName = "$AttrRef-IsOkConnect"
Attr FilterArguments[0] = "DefTrend"
Attr FilterArguments[1] = "DsTrend,PlotGroup"
EndBody
EndObject
EndObject
EndObject
Object RtXtt $RtMenu
Object Channel $MenuRef
Body SysBody
Attr ButtonName = "Channel"
Attr RefAttribute = "SigChanCon"
EndBody
EndObject
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bo.wb_load -- Defines the class Bo.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Buffer output signal base class
! Buffer output signal base class.
!
! This class is used as a base class for Buffer input signals.
! The buffer signal subclass should contain an ActualValue attribute and
! an InitialValue attribute.
!
! ActualValue can be an array Int32 or Float32, or a String, and should be
! specified as a pointer in the flags word.
! InitalValue shoud be of the same size and type as ActualValue, and should
! be placed after ActualValue.
!
! In the size attribute, the total size in bytes of ActualValue should be
! specified. If for example ActualValue is an Int32 array of 20 elements,
! size is 80.
!*/
Object Bo $ClassDef 559
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "Bo"
EndBody
!/**
! Optional text, for example the name of the signal or
! what it represents.
!*/
Object Description $Attribute 1
Body SysBody
Attr TypeRef = "pwrs:Type-$String80"
EndBody
EndObject
!/**
! Name of the associated channel object.
!*/
Object SigChanCon $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$AttrRef"
EndBody
EndObject
!/**
! Index in the Value array at the BoArea objects
! that are used for base frequency and partial frequency
! samples. Initiated at boot time by rt_ini.
!*/
Object ValueIndex $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt32"
Attr Flags |= PWR_MASK_INVISIBLE
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_PRIVATE
EndBody
EndObject
!/**
! Size of actual value buffer in bytes.
!*/
Object Size $Attribute 4
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt32"
EndBody
EndObject
!/**
! The lower respectively upper limits in the bar graph at
! presentation of ActualValue in the object display.
!*/
Object PresMaxLimit $Attribute 12
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
EndBody
EndObject
Object PresMinLimit $Attribute 13
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
EndBody
EndObject
!/**
! @Summary A XttGraph object that will open a graph for this object.
! A XttGraph object that will open a graph that contains data for
! this object. This graph can be opened from the popup menu for
! this object.
!*/
Object DefGraph $Attribute 5
Body SysBody
Attr TypeRef = "pwrs:Type-$AttrRef"
EndBody
EndObject
!/**
! @Summary A trend object that displays a trend for this object.
! A DsTrend or PlotGroup object that contains a trend for this object.
! The trend can be opened from the popup menu for this object.
!*/
Object DefTrend $Attribute 6
Body SysBody
Attr TypeRef = "pwrs:Type-$AttrRef"
EndBody
EndObject
!/**
! @Summary A help topic for this hierarchy.
! A help topic in the xtt help file that contains help for this hierarchy.
! The help can be displayed from the popup menu for this object.
!*/
Object HelpTopic $Attribute 7
Body SysBody
Attr TypeRef = "pwrs:Type-$String40"
EndBody
EndObject
!/**
! @Summary A URL to the data sheet for the equipment in this hierarchy.
! A URL to the data sheet for the equipment in this hierarchy.
! The data sheet can be displayed from the popup menu for this object.
!*/
Object DataSheet $Attribute 8
Body SysBody
Attr TypeRef = "pwrs:Type-$URL"
EndBody
EndObject
!/**
! @Summary An URL to the circuit diagram for the equipment in this hierarchy.
! An URL to the circuit diagram for the equipment in this hierarchy.
! The circuit diagram can be displayed from the popup menu for this object.
!
! If the attribute is empty, the CircuitDiagram method will look at the
! closest ancestor that has supplied a value in CircuitDiagram and use this
! URL instead. If this behavior is unwanted, put the string 'Disabled' in the
! attribute. This will disable the CircuitDiagram method for this object, and
! for any child with empty CircuitDiagram attribute.
!*/
Object CircuitDiagram $Attribute 9
Body SysBody
Attr TypeRef = "pwrs:Type-$URL"
EndBody
EndObject
!/**
! @Summary A photograph of the plant.
! A photograph of the plant.
! A URL to a photo of the equipment.
! The photo can be displayed from the popup menu for this object.
!*/
Object Photo $Attribute 14
Body SysBody
Attr PgmName = "Photo"
Attr TypeRef = "pwrs:Type-$URL"
EndBody
EndObject
!/**
! @Summary A note of the current status of the object.
! A note of the current status of the object.
! Notes are used to exchange information between operators. It is handled
! by the Note method.
!*/
Object Note $Attribute 11
Body SysBody
Attr TypeRef = "pwrs:Type-$String80"
EndBody
EndObject
EndObject
Object ConfiguratorPoson $Menu
Object Pointed $Menu
Object Connect $MenuButton
Body SysBody
Attr ButtonName = "Connect Channel"
Attr MethodName = "$AttrRef-Connect"
Attr MethodArguments[0] = "SigChanCon"
Attr MethodArguments[1] = "ChanBo"
Attr FilterName = "$AttrRef-IsOkConnect"
Attr FilterArguments[0] = "SigChanCon"
Attr FilterArguments[1] = "ChanBo"
EndBody
EndObject
Object ConnectGraph $MenuButton
Body SysBody
Attr ButtonName = "Connect Graph"
Attr MethodName = "$AttrRef-Connect"
Attr MethodArguments[0] = "DefGraph"
Attr MethodArguments[1] = "XttGraph"
Attr FilterName = "$AttrRef-IsOkConnect"
Attr FilterArguments[0] = "DefGraph"
Attr FilterArguments[1] = "XttGraph"
EndBody
EndObject
Object ConnectTrend $MenuButton
Body SysBody
Attr ButtonName = "Connect Trend"
Attr MethodName = "$AttrRef-Connect"
Attr MethodArguments[0] = "DefTrend"
Attr MethodArguments[1] = "DsTrend,PlotGroup"
Attr FilterName = "$AttrRef-IsOkConnect"
Attr FilterArguments[0] = "DefTrend"
Attr FilterArguments[1] = "DsTrend,PlotGroup"
EndBody
EndObject
EndObject
EndObject
Object RtXtt $RtMenu
Object Channel $MenuRef
Body SysBody
Attr ButtonName = "Channel"
Attr RefAttribute = "SigChanCon"
EndBody
EndObject
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_biarea.wb_load -- Defines the class BiArea.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Summary Area object for Bi values
! Area object for Bi values.
!
! The values of Bi-signals is stored in the Value
! attribut. The index is given by ValueIndex in the
! Bi-objects which is assigned at io initiation.
!
! The object is created at runtime in the dynamic system volume pwrNode.
!*/
Object BiArea $ClassDef 556
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BiArea"
EndBody
Object Value $Attribute 1
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt8"
Attr Flags |= PWR_MASK_ARRAY
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_DYNAMIC
Attr Elements = 1
EndBody
EndObject
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bifloatarray20.wb_load -- Defines the class BiFloatArray20.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Float array input signal.
! Float array input signal.
!
! Configures a buffer input signal. The signal is an array of Float32
! with 100 elements.
!
! The BiFloatArray100 object should be connected to a channel object
! of type ChanBi in the node hierarchy.
!*/
Object BiFloatArray100 $ClassDef 580
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BiFloatArray100"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bi"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Pointer to ActualValue. The value is updated
! continuously. ConversionOn in the channel
! object ChanBi specifies if the value shall be
! converted before storage.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 100
Attr Size = 400
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 100
EndBody
EndObject
EndObject
Object Template BiFloatArray100
Body RtBody
Attr Super.Size = 400
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bifloatarray20.wb_load -- Defines the class BiFloatArray20.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Float array input signal.
! Float array input signal.
!
! Configures a buffer input signal. The signal is an array of Float32
! with 20 elements.
!
! The BiFloatArray20 object should be connected to a channel object
! of type ChanBi in the node hierarchy.
!*/
Object BiFloatArray20 $ClassDef 574
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BiFloatArray20"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bi"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Pointer to ActualValue. The value is updated
! continuously. ConversionOn in the channel
! object ChanBi specifies if the value shall be
! converted before storage.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 20
Attr Size = 80
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 20
EndBody
EndObject
EndObject
Object Template BiFloatArray20
Body RtBody
Attr Super.Size = 80
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_biintarray100.wb_load -- Defines the class BiIntArray100.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Integer array input signal.
! Integer array input signal.
!
! Configures a buffer input signal. The signal is an array of Int32
! with 100 elements.
!
! The BiIntArray100 object should be connected to a channel object
! of type ChanBi in the node hierarchy.
!*/
Object BiIntArray100 $ClassDef 581
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BiIntArray100"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bi"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Pointer to ActualValue. The value is updated
! continuously. ConversionOn in the channel
! object ChanBi specifies if the value shall be
! converted before storage.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 100
Attr Size = 400
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 100
EndBody
EndObject
EndObject
Object Template BiIntArray100
Body RtBody
Attr Super.Size = 400
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_biintarray20.wb_load -- Defines the class BiIntArray20.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Integer array input signal.
! Integer array input signal.
!
! Configures a buffer input signal. The signal is an array of Int32
! with 20 elements.
!
! The BiIntArray20 object should be connected to a channel object
! of type ChanBi in the node hierarchy.
!*/
Object BiIntArray20 $ClassDef 560
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BiIntArray20"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bi"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Pointer to ActualValue. The value is updated
! continuously. ConversionOn in the channel
! object ChanBi specifies if the value shall be
! converted before storage.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 20
Attr Size = 80
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 20
EndBody
EndObject
EndObject
Object Template BiIntArray20
Body RtBody
Attr Super.Size = 80
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bistring80.wb_load -- Defines the class BiString80.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Buffer input string signal.
! Buffer input string signal.
!
! Configures a buffer input signal. The signal is string with 80
! characters.
!
! The BiString80 object should be connected to a channel object
! of type ChanBi in the node hierarchy.
!*/
Object BiString80 $ClassDef 565
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BiString80"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bi"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Pointer to ActualValue. The value is updated
! continuously. ConversionOn in the channel
! object ChanBi specifies if the value shall be
! converted before storage.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$String80"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Size = 80
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$String80"
EndBody
EndObject
EndObject
Object Template BiString80
Body RtBody
Attr Super.Size = 80
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_boarea.wb_load -- Defines the class BoArea.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Summary Area object for Bo values
! Area object for Bo values.
!
! The values of Bo-signals (Buffer Output signals) is stored in the Value
! attribut. The index is given by ValueIndex in the Bo-objects which is
! assigned at io initiation.
!
! The object is created at runtime in the dynamic system volume pwrNode.
!*/
Object BoArea $ClassDef 557
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BoArea"
EndBody
Object Value $Attribute 1
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt8"
Attr Flags |= PWR_MASK_ARRAY
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_DYNAMIC
Attr Elements = 1
EndBody
EndObject
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bofloatarray.wb_load -- Defines the class BoFloatArray100.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Float array input signal.
! Float array input signal.
!
! Configures a buffer output signal. The signal is an array of Float32
! with 100 elements.
!
! The BoFloatArray100 object should be connected to a channel object
! of type ChanBo in the node hierarchy.
!*/
Object BoFloatArray100 $ClassDef 583
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BoFloatArray100"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bo"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Array of pointer to ActualValue.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 100
Attr Size = 400
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 100
EndBody
EndObject
EndObject
Object Template BoFloatArray100
Body RtBody
Attr Super.Size = 400
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bofloatarray.wb_load -- Defines the class BoFloatArray20.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Float array input signal.
! Float array input signal.
!
! Configures a buffer output signal. The signal is an array of Float32
! with 20 elements.
!
! The BoFloatArray20 object should be connected to a channel object
! of type ChanBo in the node hierarchy.
!*/
Object BoFloatArray20 $ClassDef 575
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BoFloatArray20"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bo"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Array of pointer to ActualValue.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 20
Attr Size = 80
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 20
EndBody
EndObject
EndObject
Object Template BoFloatArray20
Body RtBody
Attr Super.Size = 80
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bointarray.wb_load -- Defines the class BoIntArray100.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Integer array output signal.
! Integer array output signal.
!
! Configures a buffer output signal. The signal is an array of Int32
! with 100 elements.
!
! The BoIntArray100 object should be connected to a channel object
! of type ChanBo in the node hierarchy.
!*/
Object BoIntArray100 $ClassDef 582
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BoIntArray100"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bo"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Array of pointer to ActualValue.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 100
Attr Size = 400
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 100
EndBody
EndObject
EndObject
Object Template BoIntArray100
Body RtBody
Attr Super.Size = 400
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bointarray.wb_load -- Defines the class BoIntArray20.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Integer array output signal.
! Integer array output signal.
!
! Configures a buffer output signal. The signal is an array of Int32
! with 20 elements.
!
! The BoIntArray20 object should be connected to a channel object
! of type ChanBo in the node hierarchy.
!*/
Object BoIntArray20 $ClassDef 561
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BoIntArray20"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bo"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Array of pointer to ActualValue.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 20
Attr Size = 80
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
Attr Flags |= PWR_MASK_ARRAY
Attr Elements = 20
EndBody
EndObject
EndObject
Object Template BoIntArray20
Body RtBody
Attr Super.Size = 80
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_bostring80.wb_load -- Defines the class BoString80.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group PlantConfiguration,Signals
! @Summary Buffer output string signal.
! Buffer output string signal.
!
! Configures a buffer output signal. The signal is string with 80
! characters.
!
! The BoString80 object should be connected to a channel object
! of type ChanBo in the node hierarchy.
!*/
Object BoString80 $ClassDef 567
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_Standard
Attr PopEditor = 1
Attr Flags |= pwr_mClassDef_IO
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "BoString80"
EndBody
!/**
! Super class.
!*/
Object Super $Attribute 1
Body SysBody
Attr TypeRef = "pwrb:Class-Bo"
Attr Flags |= PWR_MASK_CLASS
Attr Flags |= PWR_MASK_SUPERCLASS
EndBody
EndObject
!/**
! Array of pointer to ActualValue.
!*/
Object ActualValue $Attribute 2
Body SysBody
Attr TypeRef = "pwrs:Type-$String80"
Attr Flags |= PWR_MASK_POINTER
Attr Flags |= PWR_MASK_STATE
Attr Size = 80
EndBody
EndObject
!/**
! InitialValue specifies starting value of the signal at
! so called 'cold start'. Which value that is used as
! starting value at warm restart ( = change of PLC
! program ) depends on whether the signal is new or not.
! If the signal has exist in the last program its last
! value will be used as starting value, otherwise InitialValue
!*/
Object InitialValue $Attribute 3
Body SysBody
Attr TypeRef = "pwrs:Type-$String80"
EndBody
EndObject
EndObject
Object Template BoString80
Body RtBody
Attr Super.Size = 80
EndBody
EndObject
EndObject
EndSObject
This diff is collapsed.
This diff is collapsed.
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_cstobifloat32.wb_load -- Defines the class CStoBiFloat32
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Code rt_plc_macro_io.h
! @Summary Store Bi signal
! Store Buffer input.
! @image orm_cstobi_fo.gif
!
! Stores an integer value on the specified local Bi object.
!
! The complete name of the Bi object and ActualValue has to be supplied.
!
! @b Note!
! This object is used for simulation purposes.
! SimulFlag will be set TRUE and ReadWriteFlag FALSE
! in the IOHandler object, i.e. any physical I/O-hardware may
! not be used on the node in connection to this object.
!*/
Object CStoBiFloat32 $ClassDef 589
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_RtConnectionsAndDevBodies
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "CStoBiFloat32"
EndBody
!/**
! The input is connected to an integer signal or left
! open. In the latter case In is default 0 and not
! adjustable in the run time system. The In attribute
! specifies which value should be assigned to the
! Bi-signal.
!*/
Object In $Input 1
Body SysBody
Attr PgmName = "ActualValue"
Attr Flags |= PWR_MASK_RTVIRTUAL
Attr Flags |= PWR_MASK_DEVBODYREF
Attr TypeRef = "pwrs:Type-$Float32"
Attr GraphName = "VAL"
EndBody
EndObject
!/**
! Specifies whether a storage will be done or not. FALSE
! means no storage and TRUE means storage of an integer
! value.
!*/
Object Cond $Input 2
Body SysBody
Attr PgmName = "Cond"
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_RTVIRTUAL
Attr Flags |= PWR_MASK_DEVBODYREF
Attr Flags |= PWR_MASK_NOEDIT
Attr TypeRef = "pwrs:Type-$Boolean"
Attr GraphName = "con"
EndBody
EndObject
EndObject
Object DevBody $ObjBodyDef 2
!/**
! Used by the PLC Editor. Specifies the complete name of
! the current Bi object.
!*/
Object BiObject $Intern 1
Body SysBody
Attr PgmName = "BiObject"
Attr TypeRef = "pwrs:Type-$AttrRef"
Attr GraphName = "In"
Attr NiNaAnnot = 1
Attr NiNaSegments = 1
EndBody
EndObject
!/**
! Used by the PLC Editor.
!*/
Object SigChanCon $Intern 2
Body SysBody
Attr TypeRef = "pwrs:Type-$AttrRef"
Attr Flags |= PWR_MASK_INVISIBLE
Attr NiNaAnnot = 2
Attr NiNaCond = 1
Attr NiNaSegments = 1
EndBody
EndObject
!/**
! Specifies how many segments of the Bi object name that
! is to be displayed in the symbol of the CStoBi object.
! The segments are counted from behind.
!
! 0 and 1 both result in displaying the last segment of
! the signal object name.
!*/
Object BiObjectSegments $Intern 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
EndBody
EndObject
!/**
! Specifies if the name on the channel object (
! associated with the signal object) is to be displayed
! in the symbol of the CStoBi object or not. FALSE means
! no displaying and TRUE displaying.
! See also SigChanConSegments.
!*/
Object ShowSigChanCon $Intern 4
Body SysBody
Attr TypeRef = "pwrs:Type-$Boolean"
EndBody
EndObject
!/**
! Specifies, when ShowSigChanCon = TRUE, how many
! segments of the channel object name that is to be
! displayed in the symbol of the CStoBi object. The
! segments are counted from behind.
! 0 and 1 both result in displaying the last segment of
! the channel object name.
!*/
Object SigChanConSegments $Intern 5
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
EndBody
EndObject
Object PlcNode $Buffer 6
Body SysBody
Attr Class = pwr_eClass_PlcNode
Attr Flags |= PWR_MASK_INVISIBLE
EndBody
EndObject
EndObject
Object GraphPlcNode $GraphPlcNode
Body SysBody
Attr object_type = 11
Attr parameters[0] = 2
Attr parameters[1] = 0
Attr parameters[2] = 0
Attr parameters[3] = 0
Attr subwindows = 0
Attr graphmethod = 15
Attr graphindex = 1
Attr default_mask[0] = 3
Attr default_mask[1] = 0
Attr segname_annotation = 0
Attr devbody_annotation = 1
Attr compmethod = 38
Attr compindex = 0
Attr tracemethod = 0
Attr traceindex = 0
Attr connectmethod = 32
Attr executeordermethod = 2
Attr objname = "CStoBiFloat32"
Attr graphname = "CStoBiFloat32"
Attr debugpar = ""
EndBody
EndObject
Object Template CStoBiFloat32
Body DevBody
Attr BiObjectSegments = 2
Attr ShowSigChanCon = 1
Attr SigChanConSegments = 2
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_cstobiint32.wb_load -- Defines the class CStoBiInt32
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group Plc,PlcIO
! @Code rt_plc_macro_io.h
! @Summary Store Bi signal
! Store Buffer input.
! @image orm_cstobi_fo.gif
!
! Stores an integer value on the specified local Bi object.
!
! The complete name of the Bi object and ActualValue has to be supplied.
!
! @b Note!
! This object is used for simulation purposes.
! SimulFlag will be set TRUE and ReadWriteFlag FALSE
! in the IOHandler object, i.e. any physical I/O-hardware may
! not be used on the node in connection to this object.
!*/
Object CStoBiInt32 $ClassDef 584
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_RtConnectionsAndDevBodies
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "CStoBiInt32"
EndBody
!/**
! The input is connected to an integer signal or left
! open. In the latter case In is default 0 and not
! adjustable in the run time system. The In attribute
! specifies which value should be assigned to the
! Bi-signal.
!*/
Object In $Input 1
Body SysBody
Attr PgmName = "ActualValue"
Attr Flags |= PWR_MASK_RTVIRTUAL
Attr Flags |= PWR_MASK_DEVBODYREF
Attr TypeRef = "pwrs:Type-$Int32"
Attr GraphName = "VAL"
EndBody
EndObject
!/**
! Specifies whether a storage will be done or not. FALSE
! means no storage and TRUE means storage of an integer
! value.
!*/
Object Cond $Input 2
Body SysBody
Attr PgmName = "Cond"
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_RTVIRTUAL
Attr Flags |= PWR_MASK_DEVBODYREF
Attr Flags |= PWR_MASK_NOEDIT
Attr TypeRef = "pwrs:Type-$Boolean"
Attr GraphName = "con"
EndBody
EndObject
EndObject
Object DevBody $ObjBodyDef 2
!/**
! Used by the PLC Editor. Specifies the complete name of
! the current Bi object.
!*/
Object BiObject $Intern 1
Body SysBody
Attr PgmName = "BiObject"
Attr TypeRef = "pwrs:Type-$AttrRef"
Attr GraphName = "In"
Attr NiNaAnnot = 1
Attr NiNaSegments = 1
EndBody
EndObject
!/**
! Used by the PLC Editor.
!*/
Object SigChanCon $Intern 2
Body SysBody
Attr TypeRef = "pwrs:Type-$AttrRef"
Attr Flags |= PWR_MASK_INVISIBLE
Attr NiNaAnnot = 2
Attr NiNaCond = 1
Attr NiNaSegments = 1
EndBody
EndObject
!/**
! Specifies how many segments of the Bi object name that
! is to be displayed in the symbol of the CStoBi object.
! The segments are counted from behind.
!
! 0 and 1 both result in displaying the last segment of
! the signal object name.
!*/
Object BiObjectSegments $Intern 3
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
EndBody
EndObject
!/**
! Specifies if the name on the channel object (
! associated with the signal object) is to be displayed
! in the symbol of the CStoBi object or not. FALSE means
! no displaying and TRUE displaying.
! See also SigChanConSegments.
!*/
Object ShowSigChanCon $Intern 4
Body SysBody
Attr TypeRef = "pwrs:Type-$Boolean"
EndBody
EndObject
!/**
! Specifies, when ShowSigChanCon = TRUE, how many
! segments of the channel object name that is to be
! displayed in the symbol of the CStoBi object. The
! segments are counted from behind.
! 0 and 1 both result in displaying the last segment of
! the channel object name.
!*/
Object SigChanConSegments $Intern 5
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
EndBody
EndObject
Object PlcNode $Buffer 6
Body SysBody
Attr Class = pwr_eClass_PlcNode
Attr Flags |= PWR_MASK_INVISIBLE
EndBody
EndObject
EndObject
Object GraphPlcNode $GraphPlcNode
Body SysBody
Attr object_type = 11
Attr parameters[0] = 2
Attr parameters[1] = 0
Attr parameters[2] = 0
Attr parameters[3] = 0
Attr subwindows = 0
Attr graphmethod = 15
Attr graphindex = 1
Attr default_mask[0] = 3
Attr default_mask[1] = 0
Attr segname_annotation = 0
Attr devbody_annotation = 1
Attr compmethod = 38
Attr compindex = 0
Attr tracemethod = 0
Attr traceindex = 0
Attr connectmethod = 32
Attr executeordermethod = 2
Attr objname = "CStoBiInt32"
Attr graphname = "CStoBiInt32"
Attr debugpar = ""
EndBody
EndObject
Object Template CStoBiInt32
Body DevBody
Attr BiObjectSegments = 2
Attr ShowSigChanCon = 1
Attr SigChanConSegments = 2
EndBody
EndObject
EndObject
EndSObject
!
! Proview Open Source Process Control.
! Copyright (C) 2005-2011 SSAB Oxelosund AB.
!
! This file is part of Proview.
!
! This program is free software; you can redistribute it and/or
! modify it under the terms of the GNU General Public License as
! published by the Free Software Foundation, either version 2 of
! the License, or (at your option) any later version.
!
! This program is distributed in the hope that it will be useful
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with Proview. If not, see <http://www.gnu.org/licenses/>
!
! Linking Proview statically or dynamically with other modules is
! making a combined work based on Proview. Thus, the terms and
! conditions of the GNU General Public License cover the whole
! combination.
!
! In addition, as a special exception, the copyright holders of
! Proview give you permission to, from the build function in the
! Proview Configurator, combine Proview with modules generated by the
! Proview PLC Editor to a PLC program, regardless of the license
! terms of these modules. You may copy and distribute the resulting
! combined work under the terms of your choice, provided that every
! copy of the combined work is accompanied by a complete copy of
! the source code of Proview (the version used to produce the
! combined work), being distributed under the terms of the GNU
! General Public License plus this exception.
!
! pwrb_c_cstobistring80.wb_load -- Defines the class CStoBiString80.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Group Plc,PlcIO
! @Code rt_plc_macro_io.h
! @Summary Storage of Bi string value
! Storage of Bi string value.
! @image orm_cstobistring80_fo.gif
!
! Storage of a Bi string value.
!*/
Object CStoBiString80 $ClassDef 587
Body SysBody
Attr Editor = pwr_eEditor_AttrEd
Attr Method = pwr_eMethod_RtConnectionsAndDevBodies
Attr Flags = pwr_mClassDef_DevOnly
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "CStoBiString80"
EndBody
!/**
! The input is connected to a string value or left
! open. In the latter case the value of In, is considered
! to be stored.
!*/
Object In $Input 1
Body SysBody
Attr PgmName = "ActualValue"
Attr Flags |= PWR_MASK_RTVIRTUAL
Attr Flags |= PWR_MASK_DEVBODYREF
Attr TypeRef = "pwrs:Type-$String80"
Attr GraphName = "VAL"
EndBody
EndObject
!/**
! Specifies whether a storage will be done or not. FALSE
! means no storage and TRUE means storage of an integer
! value.
!*/
Object Cond $Input 2
Body SysBody
Attr PgmName = "Cond"
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_RTVIRTUAL
Attr Flags |= PWR_MASK_DEVBODYREF
Attr Flags |= PWR_MASK_NOEDIT
Attr TypeRef = "pwrs:Type-$Boolean"
Attr GraphName = "con"
EndBody
EndObject
EndObject
Object DevBody $ObjBodyDef 2
!/**
! Specifies the name of the object where to store the
! value.
!*/
Object BiObject $Intern 1
Body SysBody
Attr PgmName = "SvObject"
Attr TypeRef = "pwrs:Type-$AttrRef"
Attr GraphName = "In"
Attr NiNaAnnot = 1
Attr NiNaSegments = 1
EndBody
EndObject
!/**
! Specifies how many segments of the Bi object name that
! is to be displayed in the symbol of the CStoBi object.
! The segments are counted from behind.
!*/
Object BiObjectSegments $Intern 2
Body SysBody
Attr TypeRef = "pwrs:Type-$Int32"
EndBody
EndObject
Object PlcNode $Buffer 3
Body SysBody
Attr Class = pwr_eClass_PlcNode
Attr Flags |= PWR_MASK_INVISIBLE
EndBody
EndObject
EndObject
Object GraphPlcNode $GraphPlcNode
Body SysBody
Attr object_type = 11
Attr parameters[0] = 2
Attr parameters[1] = 0
Attr parameters[2] = 0
Attr parameters[3] = 0
Attr subwindows = 0
Attr graphmethod = 15
Attr graphindex = 1
Attr default_mask[0] = 3
Attr default_mask[1] = 0
Attr segname_annotation = 0
Attr devbody_annotation = 1
Attr compmethod = 38
Attr compindex = 0
Attr tracemethod = 0
Attr traceindex = 0
Attr connectmethod = 32
Attr executeordermethod = 2
Attr objname = "CStoBiString80"
Attr graphname = "CStoBiString80"
EndBody
EndObject
Object Template CStoBiString80
Body DevBody
Attr BiObjectSegments = 2
EndBody
EndObject
EndObject
EndSObject
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -222,6 +222,46 @@ SObject pwrb:Class
Attr Flags |= PWR_MASK_INVISIBLE
EndBody
EndObject
!/**
! Number of configured Bi objects in the node.
!*/
Object BiCount $Attribute 15
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt32"
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_INVISIBLE
EndBody
EndObject
!/**
! Number of configured Bo objects in the node.
!*/
Object BoCount $Attribute 16
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt32"
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_INVISIBLE
EndBody
EndObject
!/**
! Number of configured Bi buffers.
!*/
Object BiSize $Attribute 17
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt32"
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_INVISIBLE
EndBody
EndObject
!/**
! Total size of Bo buffers.
!*/
Object BoSize $Attribute 18
Body SysBody
Attr TypeRef = "pwrs:Type-$UInt32"
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_INVISIBLE
EndBody
EndObject
EndObject
!
! Template for IOHandler
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -85,6 +85,12 @@ public:
pwr_sAttrRef aref();
size_t size() {return m_size;}
size_t rsize() {
if ( m_flags & PWR_MASK_POINTER)
return m_elements * sizeof(pwr_tUInt64);
else
return m_size;
}
int offset() {return m_offset;}
pwr_eType type() const {return m_type;}
pwr_tTid tid() {return m_tid;}
......
......@@ -117,6 +117,9 @@ wb_attribute::wb_attribute(pwr_tStatus sts, wb_orep* orep, wb_adrep* adrep, int
m_idx = idx;
if (idx != -1) { // element
m_size = m_adrep->size() / m_adrep->nElement();
if ( m_flags & PWR_MASK_POINTER)
m_offset = m_adrep->offset() + m_idx * sizeof(pwr_tUInt64);
else
m_offset = m_adrep->offset() + m_idx * m_size;
m_elements = 1;
}
......
......@@ -151,6 +151,10 @@ wb_adrep *wb_bdrep::adrep( pwr_tStatus *sts, const char *aname)
bool next_attr = false;
wb_name an(n.attribute(i));
wb_orep *orep = bd->m_orep->vrep()->child( sts, bd->m_orep, an);
if ( EVEN(*sts) && i > 0) {
*sts = LDH__ATTRINDEX;
return 0;
}
while ( EVEN(*sts)) {
// Try Super attribute
orep = bd->m_orep->vrep()->first( sts, bd->m_orep);
......
This diff is collapsed.
This diff is collapsed.
......@@ -279,6 +279,12 @@ int goen_create_nodetype_m7(
case pwr_cClass_GetDp:
case pwr_cClass_GetAp:
case pwr_cClass_GetIp:
case pwr_cClass_GetBiInt32:
case pwr_cClass_GetBiFloat32:
case pwr_cClass_GetBiString80:
case pwr_cClass_GetBoInt32:
case pwr_cClass_GetBoFloat32:
case pwr_cClass_GetBoString80:
/* Use objects trace attribute */
strcpy( trace_attr, "$object");
break;
......
This diff is collapsed.
......@@ -409,7 +409,7 @@ wb_attribute wb_volume::attribute(const pwr_sAttrRef* arp) const
while (ODD(sts)) {
bool newBody = false;
while (ODD(sts)) {
if (arp->Offset < (adrep->offset() + adrep->size())){
if (arp->Offset < (adrep->offset() + adrep->rsize())){
if (arp->Size == 0 || adrep->size() == arp->Size) {
// Attribute found
idx = (adrep->nElement() > 1) ? -1 : 0;
......@@ -423,7 +423,7 @@ wb_attribute wb_volume::attribute(const pwr_sAttrRef* arp) const
else if (adrep->flags() & PWR_MASK_ARRAY &&
adrep->size()/adrep->nElement() == arp->Size) {
// Attribute element found
idx = (arp->Offset - adrep->offset()) / (adrep->size() / adrep->nElement());
idx = (arp->Offset - adrep->offset()) / (adrep->rsize() / adrep->nElement());
wb_attribute a(LDH__SUCCESS, orep, adrep, idx);
delete bdrep;
orep->unref();
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment