Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
b3651991
Commit
b3651991
authored
Jan 31, 2017
by
Claes Sjofors
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wb script function InLib(), and some doc
parent
3914399c
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
136 additions
and
0 deletions
+136
-0
src/doc/man/en_us/man_dg.dat
src/doc/man/en_us/man_dg.dat
+28
-0
src/doc/man/en_us/man_geref.dat
src/doc/man/en_us/man_geref.dat
+18
-0
src/doc/man/sv_se/man_dg.dat
src/doc/man/sv_se/man_dg.dat
+28
-0
src/doc/man/sv_se/man_geref.dat
src/doc/man/sv_se/man_geref.dat
+16
-0
wb/lib/wb/src/wb_wccm.cpp
wb/lib/wb/src/wb_wccm.cpp
+46
-0
No files found.
src/doc/man/en_us/man_dg.dat
View file @
b3651991
...
...
@@ -10081,6 +10081,7 @@ SetAttribute() <LINK> setattribute()
CreateObject() <LINK> createobject()
RenameObject() <LINK> renameobject()
MoveObject() <LINK> moveobject()
InLib() <LINK> inlib()
OpenPlcPgm() <LINK> openplcpgm()
CreatePlcObject() <LINK> createplcobject()
ClosePlcObject() <LINK> closeplcobject()
...
...
@@ -11084,6 +11085,7 @@ SetAttribute() <t>Set attribute value. <LINK> setattribute()
CreateObject() <t>Create an object. <LINK> createobject()
RenameObject() <t>Change name of an object. <LINK> renameobject()
MoveObject() <t>Move an object. <LINK> moveobject()
InLib() <t>Check if an object is in a $LibHier. <LINK> inlib()
OpenPlcPgm() <t>Open a PlcPgm. <LINK> openplcpgm()
ClosePlcPgm() <t>Close a PlcPgm. <LINK> closeplcpgm()
CreatePlcObject() <t>Create a plc object. <LINK> createplcobject()
...
...
@@ -11550,6 +11552,32 @@ int <t>destcode <t>destination code. 1 first child, 2 last ch
<c> MoveObject( "H1-Zon1-Temp2", "H1-Zon2", 1);
</TOPIC>
<TOPIC> inlib() <style> function
InLib()
int InLib( string name)
<b>Description
Check if an object is in a library hierarchy.
Returns 1 if it is in a library hierarchy, else 0.
<b>Argument
string <t>name <t>object name with path.
<b>Returns
int <t><t>1 if the object is in a library
<t><t>hierarchy, else 0.
<b>Example
<c> if ( !InLib( "H1-Motor"))
<c> ...
<c> endif
</TOPIC>
<TOPIC> openplcpgm() <style> function
OpenPlcPgm()
...
...
src/doc/man/en_us/man_geref.dat
View file @
b3651991
...
...
@@ -2825,6 +2825,12 @@ Trend.MaxValueAttr2 <t>Signal for maximum value curve number 2. Is used when the
<t>max value is dynamic. For static value, Trend.MaxValue1 is used.
Trend.HoldAttr <t>Signal to freeze the curve.
Trend.TimeRangeAttr <t>Signal of type Float32 for the time range of the curve.
Trend.Mark1Attr <t><t>Database attribute for the position of the first horizonal
<t><t>marker line.
Trend.Mark2Attr <t><t>Database attribute for the position of the second horizontal
<t><t>marker line.
Trend.Mark1Color <t><t>Color of the first marker line.
Trend.Mark2Color <t><t>Color of the second marker line.
Trend.NoOfPoints <t><t>Number of points in the curve.
Trend.ScanTime <t><t>Time interval between two points.
Trend.CurveLineWidth <t><t>Linewidth for the curve (1-8)
...
...
@@ -3092,6 +3098,18 @@ XY_Curve.CurveLineWidth <t><t>Line width of curve.
XY_Curve.FillCurve <t><t>If 1 the curve is filled.
XY_Curve.HorizontalLines <t><t>Number of horizontal lines in the diagram.
XY_Curve.VerticalLines <t><t>Number of vertical lines in the diagram.
XY_Curve.HorizontalPadding <t><t>The curve outside the x value range will be drawn with
<t><t>horizonal lines from the first or last point.
XY_Curve.XMark1Attr <t><t>Database attribute for the x position of the first vertical
<t><t>marker line.
XY_Curve.XMark2Attr <t><t>Database attribute for the x position of the second vertical
<t><t>marker line.
XY_Curve.YMark1Attr <t><t>Database attribute for the y position of the first horizonal
<t><t>marker line.
XY_Curve.YMark2Attr <t><t>Database attribute for the y position of the second horizontal
<t><t>marker line.
XY_Curve.Mark1Color <t><t>Color of the first marker lines (vertical and horizontal).
XY_Curve.Mark2Color <t><t>Color of the second marker lines (vertical and horizontal).
</topic>
</headerlevel>
...
...
src/doc/man/sv_se/man_dg.dat
View file @
b3651991
...
...
@@ -9946,6 +9946,7 @@ SetAttribute() <LINK> setattribute()
CreateObject() <LINK> createobject()
RenameObject() <LINK> renameobject()
MoveObject() <LINK> moveobject()
InLib() <LINK> inlib()
OpenPlcPgm() <LINK> openplcpgm()
ClosePlcPgm() <LINK> closeplcpgm()
CreatePlcObject() <LINK> createplcobject()
...
...
@@ -10941,6 +10942,7 @@ SetAttribute() <t>S
CreateObject() <t>Skapa ett objekt. <LINK> createobject()
RenameObject() <t>Ändra namn på ett objekt. <LINK> renameobject()
MoveObject() <t>Flytta ett objekt. <LINK> moveobject()
InLib() <t>Testa om ett object ligger under en $LibHier. <LINK> inlib()
OpenPlcPgm() <t>Öppna ett PlcPgm. <LINK> openplcpgm()
ClosePlcPgm() <t>Stäng ett PlcPgm. <LINK> closeplcpgm()
CreatePlcObject() <t>Skapa ett plc-objekt. <LINK> createplcobject()
...
...
@@ -11409,6 +11411,32 @@ int <t>destcode <t>destinationskod. 1 f
<c> MoveObject( "H1-Zon1-Temp2", "H1-Zon2", 1);
</TOPIC>
<TOPIC> inlib() <style> function
InLib()
int InLib( string name)
<b>Beskrivning
Testa om ett objekt ligger under en $LibHier.
Returnerar 1 om objektet ligger under en $LibHier, annars 0.
<b>Argument
string <t>name <t>objektnamn med path.
<b>Returnerar
int <t><t>1 om objektet ligger under en $LibHier,
<t><t>annars 0.
<b>Exempel
<c> if ( !InLib( "H1-Motor"))
<c> ...
<c> endif
</TOPIC>
<TOPIC> openplcpgm() <style> function
OpenPlcPgm()
...
...
src/doc/man/sv_se/man_geref.dat
View file @
b3651991
...
...
@@ -2807,6 +2807,10 @@ Trend.MaxValueAttr2 <t>Signal f
<t>är dynamiskt. För statisk värde används Trend.MaxValue2.
Trend.HoldAttr <t>Signal för att frysa kurvan.
Trend.TimeRangeAttr <t>Signal av typen Float32 för kurvans tidskala.
Trend.Mark1Attr <t><t>Signal för positionen av markeringslinje nr 1.
Trend.Mark2Attr <t><t>Signal för positionen av markeringslinje nr 2.
Trend.Mark1Color <t><t>Färg på markeringslinje nr 1.
Trend.Mark2Color <t><t>Färg på markeringslinje nr 2.
Trend.NoOfPoints <t><t>Antal punkter på kurvan
Trend.ScanTime <t><t>Tidsintervall mellan två punkter.
Trend.CurveLineWidth <t><t>Linjebredd på kurvan (1-8)
...
...
@@ -3071,6 +3075,18 @@ XY_Curve.CurveLineWidth <t><t>Kurvans linjebredd.
XY_Curve.FillCurve <t><t>Om 1 ritas området mellan kurva och x-axeln med fyllnadsfärg.
XY_Curve.HorizontalLines <t><t>Antal horisontella linjer i diagrammet.
XY_Curve.VerticalLines <t><t>Antal vertikala linjer i diagrammet.
XY_Curve.HorizontalPadding <t><t>Kurvan utanför x-området kommera att ritas med
<t><t>horisontella linjer från första och sista punkt.
XY_Curve.XMark1Attr <t><t>Signal för x positionen för den första vertikala
<t><t>markeringslinjen.
XY_Curve.XMark2Attr <t><t>Signal för x positionen för den andra vertikala
<t><t>markeringslinjen.
XY_Curve.YMark1Attr <t><t>Signal för y positionen för den första horisontella
<t><t>markeringslinjen.
XY_Curve.YMark2Attr <t><t>Signal för y positionen för den andra horisontella
<t><t>markeringslinjen.
XY_Curve.Mark1Color <t><t>Färg för markeringslinje nr 1 (vertikal och horisontell).
XY_Curve.Mark2Color <t><t>Färg för markeringslinje nr 2 (vertikal och horisontell).
</topic>
</headerlevel>
</chapter>
...
...
wb/lib/wb/src/wb_wccm.cpp
View file @
b3651991
...
...
@@ -1988,6 +1988,50 @@ static int wccm_plcconnect_func(
return
1
;
}
static
int
wccm_inlib_func
(
void
*
filectx
,
ccm_sArg
*
arg_list
,
int
arg_count
,
int
*
return_decl
,
ccm_tFloat
*
return_float
,
ccm_tInt
*
return_int
,
char
*
return_string
)
{
int
sts
;
pwr_tObjid
oid
;
pwr_tCid
cid
;
ldh_tSesContext
ldhses
;
int
in_lib
;
sts
=
wccm_get_ldhses
(
&
ldhses
);
if
(
EVEN
(
sts
))
{
strcpy
(
return_string
,
""
);
*
return_decl
=
CCM_DECL_STRING
;
return
CMD__NOVOLATTACHED
;
}
if
(
arg_count
!=
1
)
return
CCM__ARGMISM
;
if
(
arg_list
->
value_decl
!=
CCM_DECL_STRING
)
return
CCM__ARGMISM
;
in_lib
=
0
;
for
(
sts
=
ldh_NameToObjid
(
ldhses
,
&
oid
,
arg_list
->
value_string
);
ODD
(
sts
);
sts
=
ldh_GetParent
(
ldhses
,
oid
,
&
oid
))
{
sts
=
ldh_GetObjectClass
(
ldhses
,
oid
,
&
cid
);
if
(
ODD
(
sts
)
&&
cid
==
pwr_eClass_LibHier
)
{
in_lib
=
1
;
break
;
}
}
*
return_int
=
in_lib
;
*
return_decl
=
CCM_DECL_INT
;
return
1
;
}
/*************************************************************************
*
...
...
@@ -2090,6 +2134,8 @@ int wccm_register(
if
(
EVEN
(
sts
))
return
sts
;
sts
=
ccm_register_function
(
"PlcConnect"
,
wccm_plcconnect_func
);
if
(
EVEN
(
sts
))
return
sts
;
sts
=
ccm_register_function
(
"InLib"
,
wccm_inlib_func
);
if
(
EVEN
(
sts
))
return
sts
;
sts
=
ccm_create_external_var
(
"cmd_status"
,
CCM_DECL_INT
,
0
,
1
,
NULL
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment