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
a2b86b5e
Commit
a2b86b5e
authored
Mar 22, 2006
by
claes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*** empty log message ***
parent
e46d1c4b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
98 deletions
+0
-98
profibus/lib/wb/src/wb_c_pb_dp_slave.c
profibus/lib/wb/src/wb_c_pb_dp_slave.c
+0
-98
No files found.
profibus/lib/wb/src/wb_c_pb_dp_slave.c
deleted
100644 → 0
View file @
e46d1c4b
/*
* Proview $Id: wb_c_pb_dp_slave.c,v 1.1 2006-01-16 13:56:52 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.
**/
/* wb_c_pb_dp_slave.c -- work bench methods of the Pb_DP_Slave class. */
#include <X11/Intrinsic.h>
#undef Status
#include "wb_pwrs.h"
#include "pwr_baseclasses.h"
#include "wb_ldh_msg.h"
#include "wb_ldh.h"
#include "wb_pwrb_msg.h"
#include "wb_api.h"
/*----------------------------------------------------------------------------*\
Configure the slave from gsd file.
\*----------------------------------------------------------------------------*/
static
pwr_tStatus
Configure
(
ldh_sMenuCall
*
ip
)
{
pwr_tOName
name
;
char
*
gsd
;
int
size
;
int
sts
;
pwr_tCmd
cmd
;
sts
=
ldh_ObjidToName
(
ip
->
PointedSession
,
ip
->
Pointed
.
Objid
,
ldh_eName_Hierarchy
,
name
,
sizeof
(
name
),
&
size
);
if
(
EVEN
(
sts
))
return
sts
;
sts
=
ldh_GetObjectPar
(
ip
->
PointedSession
,
ip
->
Pointed
.
Objid
,
"RtBody"
,
"GSDfile"
,
&
gsd
,
&
size
);
if
(
EVEN
(
sts
))
return
sts
;
if
(
strcmp
(
gsd
,
""
)
==
0
)
{
free
(
gsd
);
return
1
;
}
free
(
gsd
);
sprintf
(
cmd
,
"@$pwr_exe/pb_slave_config %s"
,
name
);
wtt_command
(
ip
->
EditorContext
,
cmd
);
return
1
;
}
static
pwr_tStatus
ConfigureFilter
(
ldh_sMenuCall
*
ip
)
{
char
*
gsd
;
int
size
;
int
sts
;
sts
=
ldh_GetObjectPar
(
ip
->
PointedSession
,
ip
->
Pointed
.
Objid
,
"RtBody"
,
"GSDfile"
,
&
gsd
,
&
size
);
if
(
EVEN
(
sts
))
return
sts
;
if
(
strcmp
(
gsd
,
""
)
==
0
)
{
free
(
gsd
);
return
0
;
}
free
(
gsd
);
return
1
;
}
/*----------------------------------------------------------------------------*\
Every method to be exported to the workbench should be registred here.
\*----------------------------------------------------------------------------*/
pwr_dExport
pwr_BindMethods
(
Pb_DP_Slave
)
=
{
pwr_BindMethod
(
Configure
),
pwr_BindMethod
(
ConfigureFilter
),
pwr_NullMethod
};
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