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
db105fe4
Commit
db105fe4
authored
May 09, 2006
by
claes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Classes AToDt and CurrentTime added
parent
99fd2831
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
216 additions
and
10 deletions
+216
-10
src/lib/rt/src/rt_plc_macro_time.h
src/lib/rt/src/rt_plc_macro_time.h
+15
-1
src/wbl/pwrb/src/pwrb_c_atodt.wb_load
src/wbl/pwrb/src/pwrb_c_atodt.wb_load
+103
-0
src/wbl/pwrb/src/pwrb_c_currenttime.wb_load
src/wbl/pwrb/src/pwrb_c_currenttime.wb_load
+90
-0
wb/exp/wb/src/pwr_wb_palette.cnf
wb/exp/wb/src/pwr_wb_palette.cnf
+8
-9
No files found.
src/lib/rt/src/rt_plc_macro_time.h
View file @
db105fe4
/*
* Proview $Id: rt_plc_macro_time.h,v 1.
2 2006-05-02 07:06:09
claes Exp $
* Proview $Id: rt_plc_macro_time.h,v 1.
3 2006-05-09 05:39:00
claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
...
...
@@ -129,6 +129,20 @@
#define DtToA_exec(obj,t) \
time_DToFloat( &obj->ActVal, &t);
/*_*
ATODT
@aref atodt AToDt
*/
#define AToDt_exec(obj, val) \
time_FloatToD( &obj->DTime, val);
/*_*
CURRENTTIME
@aref currentime CurrentTime
*/
#define CurrentTime_exec(obj) \
obj->Time = tp->pp->Node->SystemTime;
/*_*
ATGREATERTHAN
@aref atgreaterthan AtGreaterThan
...
...
src/wbl/pwrb/src/pwrb_c_atodt.wb_load
0 → 100644
View file @
db105fe4
!
! Proview $Id: pwrb_c_atodt.wb_load,v 1.1 2006-05-09 05:39:00 claes Exp $
! Copyright (C) 2005 SSAB Oxelsund AB.
!
! 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 the program, if not, write to the Free Software
! Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
!
! pwrb_c_atodt.wb_load -- Defines the class AToDt.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Code rt_plc_macro_time.h
! @Group Plc,PlcTime
! @Summary Convert an analog value to delta time.
! Convert an analog value to delta time.
! @image orm_atodt_fo.gif
!
! AToDt converts an analog value to a delta time.
!*/
Object AToDt $ClassDef 471
Body SysBody
Attr Editor = pwr_eEditor_PlcEd
Attr Method = pwr_eMethod_Connections
Attr PopEditor = 2
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "AToDt"
EndBody
!/**
! Analog input.
!*/
Object In $Input 1
Body SysBody
Attr TypeRef = "pwrs:Type-$Float32"
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_RTVIRTUAL
Attr Flags |= PWR_MASK_NOEDIT
Attr Flags |= PWR_MASK_NOREMOVE
Attr GraphName = "In"
EndBody
EndObject
!/**
! The time converted to a delta time.
!*/
Object DTime $Output 3
Body SysBody
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_NOEDIT
Attr TypeRef = "pwrs:Type-$DeltaTime"
Attr GraphName = "DTim"
EndBody
EndObject
EndObject
Object DevBody $ObjBodyDef 2
Object PlcNode $Buffer 1
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] = 1
Attr parameters[1] = 0
Attr parameters[2] = 1
Attr parameters[3] = 0
Attr subwindows = 0
Attr graphmethod = 1
Attr graphindex = 0
Attr default_mask[0] = 1
Attr default_mask[1] = 1
Attr segname_annotation = 1
Attr compmethod = 5
Attr compindex = 0
Attr tracemethod = 0
Attr traceindex = 0
Attr executeordermethod = 2
Attr objname = "AToDt"
Attr graphname = "AToDt"
EndBody
EndObject
EndObject
EndSObject
src/wbl/pwrb/src/pwrb_c_currenttime.wb_load
0 → 100644
View file @
db105fe4
!
! Proview $Id: pwrb_c_currenttime.wb_load,v 1.1 2006-05-09 05:39:00 claes Exp $
! Copyright (C) 2005 SSAB Oxelsund AB.
!
! 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 the program, if not, write to the Free Software
! Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
!
! pwrb_c_atodt.wb_load -- Defines the class AToDt.
!
SObject pwrb:Class
!/**
! @Version 1.0
! @Code rt_plc_macro_time.h
! @Group Plc,PlcTime
! @Summary Get the current time.
! Get the current time.
! @image orm_currenttime_fo.gif
!
! Current time fetches the current time and returns an absolute time.
!*/
Object CurrentTime $ClassDef 472
Body SysBody
Attr Editor = pwr_eEditor_PlcEd
Attr Method = pwr_eMethod_Connections
Attr PopEditor = 2
EndBody
Object RtBody $ObjBodyDef 1
Body SysBody
Attr StructName = "CurrentTime"
EndBody
!/**
! The current time.
!*/
Object Time $Output 3
Body SysBody
Attr Flags |= PWR_MASK_STATE
Attr Flags |= PWR_MASK_NOEDIT
Attr TypeRef = "pwrs:Type-$Time"
Attr GraphName = "Tim"
EndBody
EndObject
EndObject
Object DevBody $ObjBodyDef 2
Object PlcNode $Buffer 1
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] = 0
Attr parameters[1] = 0
Attr parameters[2] = 1
Attr parameters[3] = 0
Attr subwindows = 0
Attr graphmethod = 7
Attr graphindex = 1
Attr default_mask[0] = 0
Attr default_mask[1] = 1
Attr segname_annotation = 1
Attr compmethod = 55
Attr compindex = 0
Attr tracemethod = 0
Attr traceindex = 0
Attr executeordermethod = 2
Attr objname = "CurrentTime"
Attr graphname = "CurrentTime"
EndBody
EndObject
EndObject
EndSObject
wb/exp/wb/src/pwr_wb_palette.cnf
View file @
db105fe4
...
...
@@ -126,15 +126,6 @@ palette NavigatorPalette
{
class Pb_DP_Slave
}
menu Modules
{
class Pb_Di
class Pb_Do
class Pb_Ai
class Pb_Ao
class Pb_Ii
class Pb_Io
}
}
menu Remote
{
...
...
@@ -656,13 +647,21 @@ palette PlcEditorPalette
menu Time
{
class AtAdd
class AtEqual
class AtGreaterThan
class AtLessThan
class AToDt
class AtSub
class AtDtSub
class CStoATp
class CStoATv
class CStoDTp
class CStoDTv
class CurrentTime
class DtAdd
class DtEqual
class DtGreaterThan
class DtLessThan
class DtSub
class DtToA
class GetATp
...
...
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