1 / 85

S7 UNICOS Tutorial Use case: QSDN S7-UNICOS v2.7

S7 UNICOS Tutorial Use case: QSDN S7-UNICOS v2.7 . Unicos Team AB/CO IS Unicos.support@cern.ch. Table of contents. 1 – Spec 2 – Hardware Configuration 3 – Instance Generator 4 – Logic Generator 5 – Import in S7 6 – Write Logic 7 – Compilation of Logic – Load in PLC 8 – Import in PVSS

creda
Télécharger la présentation

S7 UNICOS Tutorial Use case: QSDN S7-UNICOS v2.7

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. S7 UNICOS TutorialUse case: QSDNS7-UNICOS v2.7 Unicos Team AB/CO IS Unicos.support@cern.ch

  2. Table of contents • 1 – Spec • 2 – Hardware Configuration • 3 – Instance Generator • 4 – Logic Generator • 5 – Import in S7 • 6 – Write Logic • 7 – Compilation of Logic – Load in PLC • 8 – Import in PVSS • 9 – Operation UNICOS Team AB/CO IS

  3. 1- Specification Sheets • The 1st step consists in filling in the different spec of the application ( QSDN_8_DB_IO_FI_CERN.XLS ) to define the following objects: • AI / DI / AIC • AO / DO / AOC • Local Objects • OnOff Objects • Analog Objects • Controller Objects • Process Control Objects • Alarm Objects UNICOS Team AB/CO IS

  4. 1 - Spec ANALOG INPUTS 15 AI + 1 SPARE UNICOS Team AB/CO IS

  5. 1 - Spec ANALOG OUTPUTS 4 Ao + 4 SPARE UNICOS Team AB/CO IS

  6. 1 - Spec DIGITAL INPUTS (1ST part) 52 DI + 9 SPARES UNICOS Team AB/CO IS

  7. 1 - Spec DIGITAL INPUTS (2nd part) UNICOS Team AB/CO IS

  8. DIGITAL INPUTS Calculated 2 DIC + 8 SPARES UNICOS Team AB/CO IS

  9. 1 - Spec DIGITAL OUTPUTS 13Do + 3 SPARES UNICOS Team AB/CO IS

  10. DIGITAL Outputs Calculated 2 DOC + 8 SPARES UNICOS Team AB/CO IS

  11. 1 - Spec ANALOG INPUTS CALCULATED 2 AIC + 8 SPARES UNICOS Team AB/CO IS

  12. 1 - Spec ANALOG OUTPUTS CALCULATED 0 AOC + 10 SPARES UNICOS Team AB/CO IS

  13. 1 - Spec LOCAL OBJECTS 0 LOCAL + 10 SPARES UNICOS Team AB/CO IS

  14. 1 - Spec ONOFF OBJECTS 13 ONOFF + 3 SPARES UNICOS Team AB/CO IS

  15. 1 - Spec ANALOG OBJECTS 4 Analog + 8 SPARES UNICOS Team AB/CO IS

  16. 1 - Spec Controller Objects 2 PID + 5 SPARES UNICOS Team AB/CO IS

  17. 1 - Spec Process Control Objects 3 PCO + 5 SPARES UNICOS Team AB/CO IS

  18. 1 - Spec Alarm Objects (1ST Part) 58 ALARM + 50 SPARES UNICOS Team AB/CO IS

  19. 1 - Spec Alarm Objects (2nd Part) UNICOS Team AB/CO IS

  20. 2 – Hardware Configuration 2 – Hardware Configuration • The PLC and the SCADA are linked by the Ethernet Network • Adapt to your own IP addresses. IP : 137.138.194.100 Rack : 0 Slot : 0 Connection Resource : 3 SCADA - PVSS Ethernet ID 1 IP : 137.138.194.104 Rack : 0 Slot : 4 Connection Resource : 10 PLC Siemens S412-2 UNICOS Team AB/CO IS

  21. 2 – Hardware Configuration S7 Configuration • Create a new S7 connection for the PLC : • Open NetPro (click on Liaisons of the CPU) • Select the CPU of the PLC and insert a new connection • Select Unspecified station and a S7 connection type • Click on OK UNICOS Team AB/CO IS

  22. 2 – Hardware Configuration S7 Configuration • Fill in the different fields according to the hardware which has been specified • Note that the “Establish an active connection” must not be activated. UNICOS Team AB/CO IS

  23. 3 – Instance Generator 3 - INSTANCE GENERATOR • Open the Instance Generator for S7 (S7 generator.mdb) • Delete all old values of the database. • from the edit menu click on Clear Tables -> All objects tables Delete all objects tablesy UNICOS Team AB/CO IS

  24. 3 – Instance Generator Procedure • Follow the steps in the check list to generate all your configuration files for the S7 PLC and PVSS. • The 4 steps must be completed before generating the code Check List UNICOS Team AB/CO IS

  25. 3 – Instance Generator Link Data Tables(1st Step in Check List) • Select your database which contains all data tables (/Data/S7 Data.mdb) • Select all tables and click on Refresh link button Tables selected File of your database UNICOS Team AB/CO IS

  26. 3 – Instance Generator Link Instance Template tables(2nd Step in Check List) • Select the database which contains all templates (/Template/S7 Templates.mdb) • Click on Refresh link button File of your templates database UNICOS Team AB/CO IS

  27. 3 – Instance Generator Configuration (3rd Step in Check List) • Fill in this form according to your application and your hardware configuration Parameters of your application Parameters of S7 for communication Parameters of PVSS for communication Organization of the memory in the PLC. These numbers specify in which area the generation has to begin. I/O diagnostics activation UNICOS Team AB/CO IS

  28. 3 – Instance Generator ImportExcel(4th Step in Check List) Now, import all data from spec sheets in the database • Select your XLS file (EXCEL/QSDN_8_DB_IO_FI_CERN_v3_current.XLS) • Click on Check XL file & Populate List of Objects • Clear all previous tables of the application • Select objects to import and click on Import .XLS Spec File Check XL File Objects to import Objects accounting Clear tables Import UNICOS Team AB/CO IS

  29. 3 – Instance Generator Check Tables in Access • Check that all objects have been well imported into the generator. A check can be done by means of the following menu: Select a table to open it. Check all objects which have been imported UNICOS Team AB/CO IS

  30. 3 – Instance Generator Code Generation for S7 PLC(Last Step) • Select S7 as Code Type • Select all objects to generate • Check all check boxes in order to generate all necessary files • Generate Application specifications Object Files to generate Generate S7 Files Activate these check boxes to generate all necessary files for your application Output directory for your generated files Launch generation UNICOS Team AB/CO IS

  31. 3 – Instance Generator Code Generation for PVSS(Last Step) • Select PVSS in the Code Type combo Box • Select all objects to generate for PVSS • Generate Application specifications Objects to generate for PVSS GeneratePVSS Files Launch generation Output directory for your generated files UNICOS Team AB/CO IS

  32. 3 – Instance Generator Files Generated by Instance Generator • After all these Step, you must have the following files in the output folder of the generator • In folder S7 generator/output/PVSS • In folder: S7 generator/output/S7 UNICOS Team AB/CO IS

  33. 4 – Logic Generator 4 – LOGIC GENERATOR • Open the file S7 Logic Generator.mdb to launch the S7 logic Generator • You have to follow tasks to do in the check list step by step Check List of Logic Generator UNICOS Team AB/CO IS

  34. 4 – Logic Generator Link Data Tables(1st Step in Check List) • Select the database ( / Data / S7 Data.mdb). • Select all available tables • Click on Refresh link button Select all Your database UNICOS Team AB/CO IS

  35. 4 – Logic Generator Link Logic Data tables(2nd Step in Check List) • Select the database ( Data / S7 Logic Data.mdb). • Select all available tables • Click on Refresh link button Select all Your database UNICOS Team AB/CO IS

  36. 4 – Logic Generator Link Logic Template tables(3rd Step in Check List) • Select your logic template database ( /Templates/S7 Logic Templates.mdb) Template database UNICOS Team AB/CO IS

  37. 4 – Logic Generator Transfert Data(4th Step in Check List) • Select all Dependent Objects • Clear objects already present in logic database • Import Data in logic Generator All Dependent Objects tables. Select All Clear Application Import all data UNICOS Team AB/CO IS

  38. 4 – Logic Generator Logic Code Generation(5th Step in Check List) • Select the Equipment QSDN and Location 8 • Select just the useful PCO in the box Process Control Objects (DNCT, DN1CT, DN2CT) • Click on Apply filter (verify that all filter all selected except Sequencer) • Select All Dependent Objects • Check the two check boxes Compilation File and PCO Call Order File • Click on Generate Files button Equipment qnd location of PCO Select all Dependent Objects PCO to select Filter PCO functions Check boxes Launch Generation UNICOS Team AB/CO IS

  39. 4 – Logic Generator Files generated by Logic generator • After the generation you must have this files in /output/S7 logic/ : UNICOS Team AB/CO IS

  40. 5 – Import in S7 5 - IMPORT IN S7 • Open the tool Siemens Simatic Manager Step 7 • You must have at least the version V5.3 + SP2 (look in Help->about) • Create a new project named Tutorial-QSDN • Add Simatic 400 Station named S400 - QSDN • Configure your Hardware Configuration according to your PLC hardware (Power supply, CPU and Communications card, IO cards, Profibus, …) UNICOS Team AB/CO IS

  41. 5 – Import in S7 Import S7 Baseline • Open the library Baseline_UNICOS_S7 provided with the package (File->Open->libraries) • Copy the library code to your project: blocks and source files UNICOS Team AB/CO IS

  42. 5 – Import in S7 Import Symbols • Open the symbols editor of your S7 project: S7 Program-> Symbols • Click on Symbol Table -> Import • Select System Data Format as type of Files (*.SDF) • Select the file symbol.sdf. This file has been created by the Instance Generator (Folder: S7 generator/Outputs/S7) • At importation a window appears informing about errors, warning or conflicts • Save your Symbol table and close it Check errors UNICOS Team AB/CO IS

  43. 5 – Import in S7 Compile Baseline • Launch the source file 1_Compilation_BaseLine and compile it. This compile control file will compile all files included in the baseline. • Check if you have errors during the compilation Compilation of Baseline UNICOS Team AB/CO IS

  44. 5 – Import in S7 Import generated Source Files • Go to S7 Program -> Sources • Click on Insert-> external sources • Import all source files generated by the Instance Generator (Folder:S7 Generator/Output/S7) • Import all source files generated by the Logic Generator (Folder: S7 Generator/Output/S7_LOGIC) UNICOS Team AB/CO IS

  45. 5 – Import in S7 Compile Instance File • Compile the Instance files you have generated • Launch the source file2_Compilation_Instanceand compile it. This file will compile all the files related to the instances. • Check if you have errors during the compilation Compilation of Instance files UNICOS Team AB/CO IS

  46. 5 – Import in S7 TSPP communications optimization • The TSPP_UNICOS_Manager communications routine contained in the baseline have several parameters which can be modified to optimize its usage and also to avoid initial errors in sizing the buffers. • The parameter MaxStatusTable is explicitly included as SCL code comment before the TSPP_UNICOS_Manager routine call (file SCL source: Communications). You must copy this value in the TSPP_UNICOS_Manager SCL source code and recompile it as well as its instance DB. UNICOS Team AB/CO IS

  47. 6 – Write Logic 6 – Write Logic • Next step is to complete the specific logic according to the application QSDN (Nitrogen Vessels). • All FC of all PCO have to be completed according spec files • There are 3 PCO to complete. • All the logic is described in the spec files (included in the generator folder): • QSDN_8_Struct&Logic_v1.xls • QSDN_8_v1.doc • There is 1 PCO with 1 grafcet by Vessel (DN1CT et DN2CT) • There is 1 PCO to manage these 2 PCO (DNCT) • You can see the architecture of this system in the Excel File. UNICOS Team AB/CO IS

  48. 6 – Write Logic General Architecture UNICOS Team AB/CO IS

  49. 6 – Write Logic Procedure • Complete PCO functions according to QSDN_8_Struct&Logic_v1.xls : • Grafcet • Transition Logic • Global Logic • Follow all steps of the Logic spec file QSDN_8_v1.doc. Complete for each PCO : • Interlock Logic • Configuration Logic • Dependent Object Logic • Others functions are already filled: • Common Dependent Object Logic • Warning • SPCO • Complete FC_PCO_LOGIC function UNICOS Team AB/CO IS

  50. 6 – Write Logic Grafcet of DN1CT • Create a new FB with GRAPH language. Choose FB30 which is not yet used and choose Graph_DN1CT as Symbol Name. • Create an Instance DB for your FB. Choose DB10 with the symbol DN1CT_Seq Creation of the FB30 Creation of the DB10 UNICOS Team AB/CO IS

More Related