Technical Forum

SIMATIC WinCC flexible

Detect user on numerical tag tp177b

Thread Starter: r.suriaga   Started: 6/19/2012 2:16 AM   Replies: 2

« Previous thread Next thread »
Page 1 of 1 (3 items)
  6/19/2012, 2:16 AM
Joined 2/5/2007
Last visit: 4/22/2013
Posts: 28
Rating:
Rated: no ratings [0 out of 5 / rated 0 time(s)]. (0) 
Rated: no ratings [0 out of 5 / rated 0 time(s)]. (0) 
Hi,

I'm doing a program in a TP177B that is communicating with a rtu SCADA PACK 334 by Modbus TCP.

In the application there are two users. I have to send to RTU the number 1 when the first user Log in an the number 2 when the second user Log in and send zero when any user Log out.

How can I do this? Is possible using scripts in a TP177B? Can Somebody send an example?

Thanks for your help.
Top
  6/19/2012, 8:30 AM
Joined 9/28/2005
Last visit: 5/29/2013
Posts: 2912
Rating:
Rated: Excellent [4.02 out of 5 / rated 209 time(s)]. (209) 
Users with special expertise supervising conferences
Rated: no ratings [0 out of 5 / rated 0 time(s)]. (0) 
r.suriaga wrote:
Hi,

I'm doing a program in a TP177B that is communicating with a rtu SCADA PACK 334 by Modbus TCP.

In the application there are two users. I have to send to RTU the number 1 when the first user Log in an the number 2 when the second user Log in and send zero when any user Log out.

How can I do this? Is possible using scripts in a TP177B? Can Somebody send an example?

Thanks for your help.


You cannot use scripts on TP177B. However you have integrated functions of the panel and one of them is called GetUserName which gets currently logged user name into string tag. You can call this function with some button or, what is better, on screen load event. Then you can at least send user name. As long as scripts are not supported on this type of HMI I don't have an idea of how to convert username into digit.

Regards,
--------------------------------
Darius
Automation engineer/programmer
Top
  6/19/2012, 1:53 PM
Joined 5/22/2006
Last visit: 6/6/2013
Posts: 203
Rating:
Rated: Outstanding [3.75 out of 5 / rated 20 time(s)]. (20) 
Rated: no ratings [0 out of 5 / rated 0 time(s)]. (0) 
Hi,

To do this the easy way, you'd need to place "User 1" in Group 1 and place "User 2" in Group 2.
This can be done in: Runtime User Administration > Groups

Now in the Device Settings > Scheduler you will have to add the following:
Create new Scheduled task > Event: Change user > Functions: 1. TraceUserChange, 2. GetGroupNumber (tag out will be the tag linked to your system)

Save, compile, download.


When "User 1" logs in, the "tag out" you configured will contain 1.
When "User 2" logs in, the "tag out" you configured will contain 2.
When Administrator logs in, the "tag out" you configured will contain 9.
When no user is logged in, the "tag out" will contain 0.


Quick and easy.
Top
Page 1 of 1 (3 items)
Actions