10/3/2015 12:17 PM | |
Joined: 9/23/2005 Last visit: 4/17/2024 Posts: 4325 Rating: (1424) |
“Simple Samples” are small projects that demonstrate simple features. The target is give a quick overview about the theme and be used as start point for related discussions. Follow there are a short description and the configuration main steps.
Description:
Access restrictions based on Users limits the user to perform buttons commands depending of his authorizations. It could be used for several targets (like to block access to screens). In this example, depending of logged user (John, Steve, Lewes, Bill) it is possible to change tags (by button or IO field).
The principle is: 1 – Actions (e.g. Buttons and IO field) are linked with authorizations levels definitions 2 – User groups defines typical case of users and these respective authorizations levels 3 – User are defined and linked to User groups
User ↔ User Group (set of Authorizations levels) ↔ Authorization Level ↔ object access restriction
Logon dialog is called by button.
The users could be managed online by User Admin Control (the features are limited conform the user authorization settings).
Requirements: WinCC V7.3.
Project with a minimum configuration (stop button, tags, etc.).
Configuration main steps:
#include "apdefap.h" void OnClick(char* lpszPictureName, char* lpszObjectName, char* lpszPropertyName) { // WINCC:TAGNAME_SECTION_START // syntax: #define TagNameInAction "DMTagName" // next TagID : 1 // WINCC:TAGNAME_SECTION_END
// WINCC:PICNAME_SECTION_START // syntax: #define PicNameInAction "PictureName" // next PicID : 1 // WINCC:PICNAME_SECTION_END
#pragma code ("useadmin.dll") #include "PWRT_api.h" #pragma code()
PWRTLogin('c');
}
Optional: manage online User / Password
Note: in this example, just the Administrator user can manage all users
References: Portal SIMATIC WinCC in Online Support https://support.industry.siemens.com/cs/br/pt/view/93906404/en
Manual WinCC V7.3: Working with WinCC https://support.industry.siemens.com/cs/ww/en/view/102754925
WinCC V7.3 Scripting: VBS, ANSI-C, VBA https://support.industry.siemens.com/cs/ww/en/view/102777678
Application and tools Demo projects for SIMATIC WinCC V7.3 https://support.industry.siemens.com/cs/br/pt/view/93148272/en
Example Blocks for WinCC V7 and STEP 7 V5 (for S7-300 with SCL and S7-400 with CFC, SCL) https://support.industry.siemens.com/cs/br/pt/view/68679830/en
Example blocks for WinCC V7 and STEP 7 (TIA Portal) (for S7-1200 and S7-1500 in SCL) https://support.industry.siemens.com/cs/br/pt/view/31624179/en
Thanks
Thanks to Marcelo Butenas and for the Technical Support Brazil for the help to build this simple sample.
Images: Due a size/ format restrictions, the images are first compacted with 7z format (images.z7) and after that attached to a zip archive (data.zip).
Project: Due a size/ format restrictions, the project are first compacted with 7z format (project.z7) and after that attached to a zip archive (data.zip).
AttachmentData.zip (343 Downloads) |
Denilson Pegaia |
|
Follow us on