• No results found

has a blue frame as long as it is active.

In document CIROS Production Handout_EN (Page 56-111)

2 2 Production Supervision

User 1 has a blue frame as long as it is active.

Hint: Consider that error handling like

for the standard strategies is not working for user-defined process plans.

Even if your process plan has no syntax errors logical errors still may occur. Debugging is not possible in the ProjectStudio and

Festo Didactic GmbH & Co. KG

- 57 -

2. 2. 2 Rebuilding the standard strategy Penholder with macro process tasks

This chapter shows how a standard strategy can be rebuild with macro process tasks easily. The standard strategy Penholder produces a penholder with part number 42104 from raw material.

Manufacturing a penholder with macro process tasks

1. Ensure that Production Supervision ProjectStudio and Production Simulation have been started. 2. Open in both programs the same production

line and ensure that the project contains a CNC mill or turn machine. A transport system and a stock station are also necessary.

3. Click on the window ProjectStudio in Production Supervision on the tab Process

plan to see the columns of the process plan.

4. To produce the penholder raw material has to be transported to the CNC machine. However a carrier is needed for the transport which has to be called by the stock station. Therefore click with the right mouse button on the stock station and select the command REQUIRE in

Process Task.

5. Enter 1 as parameter for the CarrierID in the opened dialog window.

6. Afterwards put the penholder s raw material on the stopped carrier by clicking on Process Task -> MovToTrans in the context menu of the stock. Anschließend laden Sie den Stifthalter auf den

gestoppten Grundträger, in dem Sie im Kontextmenü des Hochregallagers auf Process Task -> MovToTrans klicken. In the dialog window enter 42000 for PartNumber and leave

OrderNumber at the default of 0 .

7. Now the raw material has to be transported to the CNC station therefore use the command to_Mill / to_Turn / to_MillAndTurn in

the context menu of the CNC station under Process Task. The exact name depends on the CNC machine used. The dialog window then asks for a CarrierID enter the 1

since you reserved this ID before.

8. Click with the right mouse button on the CNC machine and select

Process Task -> MovFromTrans and enter the part number

42000 . With the macro process task the raw material is moved from the transport on a buffer position of the CNC station. 9. Before continuing the stopper at the CNC machine should be

released to guarantee a continuous material flow. Use the command RELEASE in the context menu of the CNC machine.

Festo Didactic GmbH & Co. KG

10. Now the raw material can be manufactured in the CNC machine. Click with the right mouse button on the CNC machine and select

Process Task -> ProdPenholder. The function needs the parameter TargetPartNumber so enter 42104 since that penholder is to be

produced.

11. After the penholder is produced it is taken back to stock but for this a carrier is necessary. With Process Task -> REQUIRE in the context menu of the CNC machine a carrier is reserved. Since the previously reserved carrier is freed again you can use 1 as ID again.

12. To place the penholder on the carrier use the macro process task

MovToTrans in the context menu of the CNC machine. For part

number use 42104 because the produced penholder is to be moved.

13. Click with the right mouse button on the stock station and select Process Task -> to_StockSingle. The carrier will then be moved to stock and stops there.

14. Another right click on stock and the command MovFromTrans stores the penholder in the stock. Enter 42104 as part number. 15. At last the stopped carrier at the stock station has to be released

again. Else the material flow stops and other production processes can not be executed. Therefore click on RELEASE which you find in the context menu of the stock station and enter the ID 1 . 16. The process plan in the ProjectStudio window is finished and can

be tested. But first it has to be generated. Activate setup mode in Production Supervision by clicking on Setup in the menu Project or on the button .

17. Click on Generate process plan in the menu Extras -> ProjectStudio to generate the process plan. As name use either Prod_User1, Prod_User2 or Prod_User3 to be able to start the process plan in the visualization window directly. Enter Prod_User1 and confirm that an existing process plan should be replaced.

18. Start production mode of Production Supervision with the command Production in the menu Project or use the button .

19. You can start the created process plan in the visualization window by clicking on the button User 1. If you used Prod_User2 or Prod_User3 as name then click on the appropriate button.

This example shows that standard strategies can be rebuild with macro process tasks. However the macro process tasks and the creation in the ProjectStudio have the advantage that the process now can be expanded or modified in any way.

Festo Didactic GmbH & Co. KG

- 59 -

2. 2. 3 Working with the Tasktool (F3) in Production Supervision

With Production Supervision and Production Simulation you can simulate production lines and start production processes. For that macro process tasks are started which execute complete processes like assembling a deskset.

During a system installation or for testing purposes it would be better to control single stations of the iCIM system directly. For this Production

Supervision offers the Tasktool.

With the tasktool operations of components of an iCIM system can be started directly so that for example a robot program on an assembly station can be executed. But the tasktool only works if Production Supervision is in production mode. In the following example the simulation is stopped and started again with the tasktool. Further a part from storage bin No. 1 is to be moved to storage bin No. 40.

Starting and using the tasktool

1. Ensure that Production Supervision ProjectStudio and Production Simulation have been started. 2. Open in both programs the same production line.

3. Start production mode in Production Supervision by clicking in the menu Project on the command

Production or using the button .

4. Usually then the visualization window opens and is active therefore switch back to the Production Supervision window.

5. Press the F3 key or click on Tasktool in the menu View.

6. The tasktool has a simple design. On the left you see the stations and their components in a checkbox. Depending on the selected component the contents of the list box on the right changes. In the list box all executable process tasks of the selected component are shown. If you click on one entry it is entered in the text box so that necessary parameters can be edited. With a click on Start a process task is executed.

7. If you select in the component selection a station like StockSingle you will see the stock s macro process tasks. However if you select the component StockSinglePLC of the stock then you will see process tasks which control the PLC directly.

Festo Didactic GmbH & Co. KG

8. Select the component TransportPLC. In the list box click on the entry StopSimulation( ). The process task is inserted in the text box above the list box. Since the process task does not need any parameters it can be started directly with the Start button. Switch to th Production Simulation window the transport system should be halted now.

9. To restart the simulation of the transport system select the entry RunSimulation( ) in the list box and execute the process task with a click on Start.

10. Before you can move a part in stock from one storage bin to another one the destined storage bin has to be empty. Therefore start the database window by clicking on Database in the visualization window of Production Supervision.

11. In the database window click on Login and use

User/Festo for login data. Then click on Stock Contents. Select storage bin No. 40 and click

on Reset to delete its content.

12. Switch back to the Production Supervision window with the open tasktool.

13. Select the component StockSinglePLC. This component controls the stock s PLC. The Entry

Mov([Par1, Par2, ...]) in the list box is the

process task for stock handling. The process task awaits 2 parameters. The first parameter is the source position and the second one is the target position. Therefore enter Mov(1,40) in the text box and start the process task with

Start.

14. Switch to the Production Simulation window to watch the movement of the stock handling.

Hint: The process tasks in the tasktool won t

modify the database. That means that the stock contents won t change. This can lead to errors if then standard strategies or macro process tasks are started in the visualization

Festo Didactic GmbH & Co. KG

- 61 -

The most important process tasks of the components can be found on the online assistant of CIROS Production. You can start it in the start menu under Programs -> CIROS Production -> CIROS Production

Assistant.

Click on Contents in the online assistant. There you can see an entry to every station and if you expand the entry by clicking on the + character you will find an entry Process tasks for most stations. There you can find a description of the parameters for the process tasks.

Festo Didactic GmbH & Co. KG

2. 2. 4 Starting robot programs with ExecProg

Executing robot programs in Production Supervision directly is especially interesting for real iCIM systems. This way you can start self programmed robot programs in Production Supervision to test them or to integrate in process plans.

Though the usage of ExecProg in Production Simulation is identical to a real iCIM system but currently it is not possible to implement user-defined robot programs in the models of Production Simulation. Therefore only the available robot programs can be started.

ExecProg can be executed in the tasktool or in a

process plan. The default programs of the robot can be found in the online assistant.

The following example demonstrates the call of

ExecProg in the tasktool. Thereto a thermometer of

the assembly station is moved to the test position of the vision system.

Starting robot programs with the tasktool

1. Ensure that Production Supervision

ProjectStudio and Production Simulation have

been started.

2. Open in both programs the same production line. Ensure that the production line contains an assembly station.

3. Start production mode in Production

Supervision by clicking in the menu Project on the command Production or on the button . 4. Usually then the visualization window opens

and is active therefore switch back to the Production Supervision window.

5. Press the F3 key or click on Tasktool in the menu View.

6. Select as component the robot of the assembly station. The robot is indicated by an additional

Robot to the station s name. In the example

project an assembly station with a RV3SV robot

Festo Didactic GmbH & Co. KG

- 63 - 7. In the list box of the tasktool the different

process tasks of the robot are displayed. Highlight the entry ExecProg([Par1, Par2, ...]), which is then displayed in the text box. ExecProg needs several parameters. The first one should be a string and defines the robot program to be executed while the following parameters are the parameters for the robot program.

8. If you look up the robot programs for the assembly station in the online assistant you will find out that the program MINST is used for moving instruments. Three parameters are necessary for the program. The first one is the source position, the second one the target position and the third one is the rotational angle the robot should execute. Possible values for the parameters are written in the online assistant.

9. The thermometer is in the first feeder that is position 1 in the robot program. The testing position ist position 5 and the rotational angle is not relevant so 0 can be used. Therefore enter in the text box the following process task:

ExecProg("MINST",1,5,0)

Then startthe process by clicking on Start and watch the robot in the Production Simulation window.

10. In the Production Supervision message window a message is displayed that the process task has been started. When the process is finished another message appears as well as a return value.

The usage of ExecProg with a real iCIM system is more flexible since test objects can be easily placed on the

robot station. A possible application of ExecProg with Production Simulation would be to replace a macro process task like the deskset assembly with direct calls of the robot programs.

Festo Didactic GmbH & Co. KG

2. 2. 5 Programming in process plan language

Macro process tasks are saved in a process plan. In a process plan production process can be programmed. For this, the process plan language of CIROS Control is used.

The process plan language is a high level language but differs from other popular programming languages. It is an interpreter language and line oriented. Every line has a definite count of columns.

The

columns in a process plan

The following list explains the names of the columns of a process plan. Furthermore the use is mentioned.

Line: A process plan is line oriented thereby every line has to be labeled explicitly. Usually the

lines are numbered but words are also possible. Particular words can indicate a certain function or can be used as legible jump label. The line label, whether numerical or as text, must not be missing else it is considered a syntax error.

Condition: In this column a number, a text in quotation marks or a numerical range can be entered. For

a numerical range the start and end value is separated by 2 points. With commas you can also enter a separated list of several conditions with different data types.

With a condition an IF-THEN-ELSE construct can be implemented however consider that for strings there is a difference between upper and lower case.

Device: In the device column is either a component from the Production Supervision project

inserted or a function of Production Supervision.

Process task: Process task starts either a process task or a process plan of the selected component.

Parameters can be passed, too. Also mathematical operations or processing of variables and return values respectively is possible if Production Supervision function is defined as component.

Festo Didactic GmbH & Co. KG

- 65 -

Functions in process plan language

The Production Supervision functions that can be use under Component in the process plant always start with a point. You can find information to all functions in the online help of Production Supervision. Thereto click on the question mark ? in the menu and click on Index. Select the tab Contents in the online help and open the directory User manual. There you see the entry Functions in process plans which contains a list of Production Supervision functions.

Variables in process plan language

Variables in process plan are declared with a prefixed % character. A data type is not necessary since Production Supervision uses the Variant Type. This type can take both numerical values and strings. Strings in process plan language are indicated with quotation marks at the beginning and end. For more details about Variables open the Production Supervision online help and navigate in Contents to User manual ->

Introduction -> Process plans -> Variables in process plans. Comments in process plan language

If you enter a semicolon ; in the column Line so Production Supervision will see the line as a comment line and ignores it for the production process. You can enter any text as comment.

The

following example shows how to create and edit a new process plan in Production Supervision. With a process task a part in the stock is moved from storage bin No. 1 to No. 40.

Festo Didactic GmbH & Co. KG

Creating and editing a process plan

1. Ensure that Production Supervision

ProjectStudio and Production Simulation have

been started.

2. Open in both programs the same production line and ensure that the production line et least contains a transport system and a stock station.

3. Activate setup mode in Production Supervision. Thereto click on Setup in the menu Project or on the button . If the button is pressed or there is a tick on the menu entry then setup mode is already active.

4. Now create a new empty process plan by clicking on Process plan in the menu File ->

New.

5. Navigate to the directory Local Project on the tab Project of the Project window.

6. There you should see the entry Processplan1 which is the new process plan.

7. Click on the process plan to highlight it blue. With the key F2 you can change the name of the process plan. Another way to rename the process plan is just another left click on it while it is highlighted.

8. Open the properties of the process plan with a right mouse button click on the process plan and a left click on Properties afterwards.

9. In the properties dialog you set or change different settings for the process plan. You can also change its name here. The other options can be looked up in the online help by clicking on the Help button of the properties dialog.

An important setting is the Process plan class which defines the class of the process plan. The class is then visible as subfolder in the Process plans directory.

Use Processplan_01 as name and User as process plan class to move the new process plan in the directory for user- defined process plans.

Festo Didactic GmbH & Co. KG

- 67 -

11. The process plan is empty and editing is only possible if setup mode is active. If the button is pressed setup mode is active.

12. Now you can fill the first line directly with the Mov command of the stock. 13. Therefore enter 100 as line number and leave the column Condition empty.

14. As for component enter the station name with an additional PLC , for a simple stock it would be

StockSinglePLC.

15. In the column Process task enter the movement command for the stock. The command needs 2 parameters, first the source position and then the target position. The source position is 1 while the target position is 40 . Therefore enter Mov(1,40) as process task.

16. Under Next line insert an END which ends the process plan.

17. If you want to change an existing process plan then often you need to add a blank line. With a right click in the line before you want to add a new line and the option Insert empty line a blank line is added. Alternatively you can use the key combination Ctrl + Enter.

18. Now save the process plan by clicking on Save all in the

In document CIROS Production Handout_EN (Page 56-111)

Related documents