Process station


The process station consists of a 4-position turntable, a drill module, and a test module (the ‘tester’). The sequence that each product will go through is as follows: entering the system at position one, drilling at position two, testing at position three, leaving the station at position four. The products enter the system at position one, from the conveyer belt of the test station. Products leave the system at position four, which corresponds to the input position of the storage station.

The entry and exit positions are monitored by sensors, to detect the presence/absence of a product. The turntable moves counter clockwise. The turntable movement is controlled by an electromotor and a proximity sensor that indicates the current (one of the four) discrete position. This sensor is located underneath the plateau of the turntable.

Before drilling may commence, the product must be clamped by the clamping cylinder. Afterward, it must be released again. The feed rate of the drill is set by a flow control valve, which in turn influences the downward movement of the pneumatic cylinder. To test the drilled hole for the minimum required depth, the probe attached to the test cylinder is moved downwards. If the hole is not deep enough, the appropriate limit sensor will not be activated and the current product should be rejected. This can also indicate wear or even breakage of the drill tool.

In our case, drilling will not actually be performed, as the test products already have a drilled hole in them. That is, the actual drilling is virtualized, as the drill bit is removed. This allows us to use the same products over and over again. Products with a hole that is not deep enough are ‘simulated’ by flipping them over, whereby their holeless bottom becomes the top of the product.

Sensors and actuators

This following table lists all the sensors of the workstation:

Index Label Type Initial state Event names Remark
0 SenProdGone Digital off OutputSensor.u_on, OutputSensor.u_off  
2 PushButton1 Digital off (released) Button1.u_pushed, Button1.u_released  
3 PushButton2 Digital off (released) Button2.u_pushed, Button2.u_released  
4 Switch Digital off Switch.u_on, Switch.u_off Bi-stable
6 EmergencyStop Digital on n/a NC contact
7 PushButton3 Digital off (released) Button3.u_pushed, Button3.u_released  
8 SenProdAvail Digital off InputSensor.u_on, InputSensor.u_off  
9 SenDrillUp Digital on DrillSensors.u_up_on, DrillSensors.u_up_off  
10 SenDrillDown Digital off DrillSensors.u_down_on, DrillSensors.u_down_off  
11 SenTesterUp Digital on TesterSensors.u_up_on, TesterSensors.u_up_off  
12 SenClampIn Digital on ClampSensors.u_in_on, ClampSensors.u_in_off  
13 SenClampOut Digital off ClampSensors.u_out_on, ClampSensors.u_out_off  
14 SenTurntable Digital on TurnTableSensor.u_on, TurnTableSensor.u_off  
15 SenTesterDown Digital off TesterSensors.u_down_on, TesterSensors.u_down_off  

This following table lists all the actuators of the workstation:

Index Label Type Initial state Event names
0 Clamp Digital off Clamp.c_on, Clamp.c_off
1 DrillDown Digital off Drill.c_down_on, Drill.c_down_off
2 DrillUp Digital on Drill.c_up_on, Drill.c_up_off
3 TesterDown Digital off Tester.c_on, Tester.c_off
4 Lamp2 Digital off Lamp2.c_on, Lamp2.c_off
5 Lamp3 Digital off Lamp3.c_on, Lamp3.c_off
7 Lamp1 Digital off Lamp1.c_on, Lamp1.c_off
8 Turntable Digital off TurnTable.c_on, TurnTable.c_off
9 DrillMotor Digital off DrillMotor.c_on, DrillMotor.c_off

Furthermore, multiple timers are available, as software implementations (virtual hardware):

Name Event names (mandatory) Event names (optional)
Timer1 Timer1.c_start, Timer1.u_timeout Timer1.c_cancel, Timer1.c_pause, Timer1.c_resume
Timer2 Timer2.c_start, Timer2.u_timeout Timer2.c_cancel, Timer2.c_pause, Timer2.c_resume
Timer3 Timer3.c_start, Timer3.u_timeout Timer3.c_cancel, Timer3.c_pause, Timer3.c_resume

For more information on timers, their mandatory and optional events, and how to model them, see the Timers page.

Simulation and visualization

The following is a screenshot of the visualization provided for this workstation, as part of the 4K420 course files:


The current simulation time is shown in the upper left corner. On the right, you’ll find the user interface. The buttons, lamps, and switch are all present. The buttons and switch can be turned on or off by clicking on them. Clicking once pushes the button or turns on the switch. Clicking once more releases the button or turns off the switch.

The main part of the visualization shows the actual system. There are three views: a top view at the top, and frontal view of the tester at the bottom left, and a frontal view of the drill at the bottom right. Various sensors are visualized, as are the actuators (visualized as arrows).

Three timers are provided. There status is shown using rectangles. For more information on the visualization of timers, see the Timers page.

Clicking on a product holder at the input position, while the turn table is standing still, you can add/remove a product to/from the input position. Similarly, by clicking on a product holder at one of the other three positions, while the turn table is standing still, you can add/remove a product to/from that position.

The depth of the holes drilled by the drill can be configured by clicking on the Drill depth text at the right side of the image. By default, the drill drills 8 mm holes. This can be changed to 4 mm, after which it can be changed back to 8 mm, etc. Since properly drilled holes are 8 mm deep, setting the drill to drill 4 mm deep holes essentially means you (temporarily) break the drill. The tester can then be used to detect such shallow holes.

Similar to changing the drill depth, the initial depth of the holes of newly added products (for one of the four positions) can be changed. By default, newly added products have no hole (0 mm). By clicking on the Initial depth text, at the right of the image, you can switch between 0 mm (no hole) and 8 mm (fully drilled hole). By switching between the two initial depths, and then adding products directly at the test position, you can for instance validate a controller for the tester without the need for a controller for the turntable.


The durations of the three timers that are provided, can be configured. That is, you can decide the durations of the each of the timers. To change the durations, open the config.cif file, and change the values of the appropriate constants. Make sure the read the comments that explain the allowed values. For more information on timers, see the Timers page.

If you change the configuration, the changes will automatically be applied to subsequent simulations, as well as for the next PLC code generation.