You are on page 1of 20

MDCS19

1. Table of contents 12. DESIGN ADJUSTMENT SIGNAL 12


1. TABLE OF CONTENTS 1 13. OUTPUT SIGNAL 12
2. ABBREVIATIONS 1 14. TERMINAL (PC) COMMUNICATION 13
3. INTRODUCTION 1 15. VOLUME PARAMETER TRANSFER 16
4. DESIGN CONTROL SYSTEM OVERVIEW 2 16. PARAMETER BIT REGISTER 17
5. TMCC2 CONNECTIONS 3 17. I/P TRANSDUCER SETTING 17
6. BASIC PROGRAM FUNCTIONS 6 18. SETTING CRITERIA 18
7. OTHER PROGRAM FUNCTIONS 7 19. FLAP CYLINDERS CALIBRATION 18
8. TMCC2 FRONT PANEL DISPLAY 8 20. PROGRAM DOWNLOAD 19
9. MENU STRUCTURE 10 21. GREY CODE TABLE 19
10. PHOTOCELLS MANAGEMENT 11
11. ENCODER FUNCTION AND GRAY CODES 12

2. Abbreviations

DCS22 Design Control System for TBA/22 filling machines


DCS21 Design Control System for TBA/21 filling machines
DCU Design Correction Unit (68 457-010V)
EEPROM Electrically Erasable/Programmable Read-Only Memory
LED Light Emitting Diode
MDCS19 Motorized Design Control System for TBA/19 filling machines
PC Personal Computer
PID Proportional, Integral and Derivative control algorithm
PLC Programmable Logic Controller, (like TPMC or GE-Fanuc)
TMCC2 Tetra Pak Multi-Purpose Compact Controller (559810-0101)
TPOP Tetra Pak Operator Panel
Flexbox Industrial Computer Interfacing the TPOP and logging the machine events

3. Introduction
The MDCS19 program is intended for the TBA/19 filling machines, and the program runs on the
TMCC2, Tetra Pak Multi-purpose Compact Controller, hardware. The program reads the register mark
photocells at the paper tube and the machine angle encoder. From these parameters the output is
calculated via a PID-algorithm. The output value sets the new I/P Transducer pressure and the folding
flap position. Package specific parameters are sent from the PLC.

The current software release is intended for photocells provided with remote control function and
integrates an advanced management of the photocells allowing a easy setting, a powerful failure
diagnostic and an improved reading capability.

This program is one version in the family of design control programs running on the TMCC2. The other
versions are used on the TBA/21and TBA/22 filling machines. The basic function of these programs are
the same, the main difference is the output routines. The TBA/19 uses a twenty-six step motorized
cylinder system to control the folding flaps and an I/P Transducer.

This Functional Description is intended for users of the MDCS19 "function", i.e. electrical designers, test
engineers, service engineers and alike. Its purpose is to give a full understanding of the behaviour of
the MDCS19 program together with the TMCC2 as a system.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 1 (20)


MDCS19

4. Design Control System Overview


The design control system can be illustrated as below, where TMCC2 is the central part in the system,
and all other parts in the system are connected to the TMCC2. Inside the TMCC2 symbol is a simple
representation of the functional blocks of the software:

Photocells TMCC2

Read
Photocells
I/P Transducer
α Angle Encoder
Read
Angle Encoder

TPOP
Calculation
(PID)

Output to
Flexbox Fold. Flap Motorized Cylinder
I/P Transducer
And Folding Flap

PLC
Communication Terminal, (PC)
with PLC
and Terminal

Parameter
Settings

The connections and the functions are explained in the following pages. The MDCS19 program flow is
further explained in the "Basic Program Functions" chapter.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 2 (20)


MDCS19

5. TMCC2 connections
The TMCC2 is a general purpose hardware and its inputs and outputs are fully controlled by the
software, in this case the MDCS19 program. The connections below have been chosen for the MDCS19
function (a pin connection diagram is available in the appendices):

1 TMCC2
+24V
2 Power Supply 25
Ground MDCS Right Step Pulse
26
MDCS Left Step Pulse
9 27
Angle Encoder, bit0 HighOut 0-5 MDCS Direction
10 28
29
MDCS Alarm
11
30
Not Used
12
Volume Acknowledge
13 LowIn0-7
14
15
16
Angle Encoder, bit7
7
Register Mark Photocell Q, (3bar) FastIn0-1
8
Register Mark Photocell Q, (4bar) AnalogOut1 6 I/P transducer Out Signal
17 31
Register Mark Photocell ET, (3bar) 18 Register Mark Photocell Pulse
HighIn0-1 HighOut6-7 32 Design OK
Register Mark Photocell ET, (4bar)

AnalogOut0 5 Diagnostic Analogue Output


MDCS Right Sensor Home 19
MDCS Left Sensor Home 20 HighIn2-3
AnalogIn0 3 Design Adjustment Signal
MDCS Enabled 21
22
Volume Enable HighIn4-7
23
Volume Clock
24
Volume Data
4
Not Used AnalogIn1

The functions of these signals are as follows (some functions are further explained in the
following chapters):

+24V +24 Volt power supply. From the Electrical Cabinet +24V supply.
Ground Ground power supply. From the Electrical Cabinet ground connection.

Angle Encoder, bit0 - bit7


24V inputs from the machine angle encoder that has 8 bits and counts from 0 to 255
(decimal). bit7 is the Most Significant Bit (MSB) and bit0 is the LSB.

Register Mark Photocell Q, (4bars)


24V input from the register mark photocell positioned beside the paper tube above the jaw
system. The (4bars) indicates that this photocell reads the 4 bars part of the register mark
(also called clock).

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 3 (20)


MDCS19

Register Mark Photocell Q, (3bars)


24V input from the register mark photocell positioned beside the paper tube above the jaw
system. The (3bars) indicates that this photocell reads the 3 bars part of the register mark
(also called data).

Register Mark Photocell ET, (4bars)


24V output to program the register mark photocell positioned beside the paper tube above
the jaw system. The (4bars) indicates that this photocell reads the 4 bars part of the
register mark (also called clock).

Register Mark Photocell ET, (3bars)


24V output to program the register mark photocell positioned beside the paper tube above
the jaw system. The (3bars) indicates that this photocell reads the 3 bars part of the
register mark (also called data).

Design Adjustment Analog Input


Analog (0-10V) input which is connected to the PLC analog output. A voltage close to 0V
means that the paper tube position (compared with the jaws) will be higher than with a
voltage close to 10V (in other words: an increasing voltage on this input will move the
paper tube downwards in the jaw system).
The total tube adjustment range is ± 5 mm.

MDCS19 Enabled
24V input from the PLC. When this signal is:
• LOW (0V) - the MDCS19 sets the precorrection mode.
• HIGH (24V) - the MDCS19 runs in the regulating mode if possible.
(Refer to next chapters for explanation of the precorrection and regulating modes).

Volume Enable
Volume Clock
Volume Data
These 24V input signals are controlled from the PLC. They are used for transmitting the
Repeat Length, Production Angle and I/P Transducer constant pressure values to the
MDCS19 program. Refer to the chapter below describing this transmission protocol.

I/P Transducer Signal


Analog (0-10V) output signal connected to the I/P Transducer. This signal is converted into
an air pressure from 0 to 3 bar, which is applied to the pendulum dancing roller. In this way
the MDCS program can control the paper web tension for a better design correction
performance and for a better package forming.
The working range for this signal is determined during the setting of the maximum and
minimum pressure (refer to that chapter).

MDCS Right sensor home


24V input from the right sensor home. The sensor has to be put as a reference of the
home position, where the motorized cylinder is in completely backward position.

MDCS Left sensor home


24V input from the left sensor home. The sensor has to be put as a reference of the
home position, where the motorized cylinder is in completely backward position.

MDCS Right step pulse


24V output from the TMCC2. This signal is connected to the stepper motor drive and on
every transition moves the motor by one step.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 4 (20)


MDCS19

MDCS Left step pulse


24V output from the TMCC2. This signal is connected to the stepper motor drive and on
every transition moves the motor by one step.

MDCS direction
24V output from the TMCC2. This signal is connected to the stepper motor drives and
determines the direction of both the motorized cylinders (Right or Left side).

MDCS alarm
24V output to the PLC. This signal is LOW (0V) as long as:
• the sensor is broken in status ON RH or LH cylinder;
• the sensor is broken in status OFF RH or LH cylinder.
The signal is ON when home position is done.

Register Mark Photocell Pulse


24V output to the PLC. This is a 40 ms long pulse sent when the MDCS19 program has
decoded a register mark. The pulse is delayed with the sum of:
• a constant delay corresponding to 32.7 mm tube movement,
• a variable delay depending of the Design Adjustment (± 5 mm).

Design OK
24V output to the PLC. This signal is HIGH (24V) as long as:
• the design error of a package is less than ±1.5 mm, OR
• the mean design error of the two latest packages are less than ±1.5 mm.

Diagnostic Analog Output


An analogue (0-10V) output that sets one of the following signals after each package:
• Design error of current package (∗).
• Mean design error of the lastest two packages (∗).
• Filtered design error ("90% old + 10% new"-algorithm). (∗)
• Output signal to I/P Transducer and motor.cylinder folding flaps. (∗∗)
• Filtered output signal. (∗∗)
• Design Adjustment signal. (∗)

∗ 0…10V on this output equals to -5…+5 mm.


∗∗ 0…10V on this output equals to 0 to 255 range to output signal.

The selection of the parameter to be monitored, is done through the MDCS19 menu
structure.
Refer to the "Menu Structure chapter" to know which commands have to be used to select
the desired parameter which have to be sent to the diagnostic output.
NOTE: that all the values (incl Design Adjustment) change only when the filling machine
is running (the values change for every package).

Volume Acknowledge
This is a 24V output to the PLC. Refer to the chapter below describing the transmission
protocol for volume parameters.

Not Used
These inputs and outputs are not used in the MDCS19 program. They should be left
unconnected.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 5 (20)


MDCS19

6. Basic Program Functions


The MDCS19 program for the TMCC2 is written in the C-language and it is not possible to modify this
without the proper knowledge and development tools (this must be done in a technical development
facility). The compiler use is “FFMC-16 family softune workbench V33L22”.
The parameters that need to be changed (e.g. volume parameters) are controlled from the PLC.

Program flow:
At start-up or reset (the TMCC2 may be reset manually by pressing the DOWN and ENTER pushbuttons,
on the front panel, for a few seconds) the MDCS19 program initiates all its internal variables and reads
the volume parameters sent from the PLC. After this first step the program enters an eternal loop, i.e. it
repeats the program over and over again. This loop has the following basic functions:

• Wait for a valid photocell reading of the register mark. This routine decodes the edges of the
register mark (and of the other part of the design as well) and for every edge (black to white, white
to black) it stores the photocell values in a shift register. The shift register is a 26-bit single register
(compared to the first MultiStep routine that used two separate shift registers with 6 and 7 bits
respectively, which in some cases could cause a false decoding). This shift register is compared
with a special pattern that corresponds to a correct register mark. If they are equal a register mark
has been detected and the program can proceed with its calculations.

• When the register mark has been detected the MDCS19 program reads the machine angle encoder.
To get an acceptable accuracy of the machine angle an interpolation is done by comparing the
remaining time of the current angle (i.e. until the angle encoder changes to a new value) with the time
for a complete angle. This gives a decimal number (for example, 72.95) telling where the register
mark is in relation to the machine jaw system.

• When the register mark has been detected the MDCS19 program also sends the Register Mark
Photocell Pulse signal to the PLC. This signal is delayed a certain time from the actual register mark
detection. The delay time depends of the current machine speed and corresponds to a distance on
the paper tube. This distance is independent of volume settings. The delay is a constant 32.7 mm in
addition to a variable delay depending on the Design Adjustment position (±5 mm).

• The calculated register mark angle is now compared to the preferred design angle, i.e. the
production angle set from the PLC offset by the Design Adjustment value (for example, 74 - 1.25 =
72.75). The comparison gives the angle error and together with the repeat length it is possible to
calculate the design error in millimetres for the current package (the example: 72.95 - 72.75 = 0.20;
0,20 * 245(repeat length) / 128(no of angle degrees per package) = 0.38 mm design error). The
design error is positive if the register mark (the design) is too "high" in relation to the jaw system, and
vice versa.

• The design error is used as an input to the PID control algorithm. Actually, it is the mean design error
of the two latest packages that are used, this giving a more smooth running system in case of
different mechanical adjustments of the left and right side of the machine. The algorithm uses a
quadratic P-part, which means that it has a faster response for larger design errors. Otherwise, it is a
standard PID with integral and output range limitations. The P, I and D factors have been tested on
filling machines to give a well working design control in both normal production and start/stop
sequences.

• When the PID algorithm has calculated a new output value, ranging from 0 (precorrection), 1
(minimal paper pull) to 255 (maximal paper pull), this is converted into an analogue signal for the I/P
Transducer and a digital setting of the driver for the motorized cylinder controlling the folding flaps.
The conversion is illustrated in the chapter "Output Signal".

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 6 (20)


MDCS19

• From the calculated design error the MDCS19 program also decides whether it should accept the
package or not. If the package is accepted the DesignOK signal to the PLC is set. The decision is
based upon the following rules:

Design Error Package Accepted


Design error of last package is less than ±1.5 mm YES
Mean design error of last two packages is less than ±1.5 mm YES
Otherwise NO
Note: The window of ±1.5 mm is the Default value. It is possible to change by terminal or menu
structure (refer to chapter 9 for more details).

• The MDCS19 program then start again to search for a new register mark.

Besides this main program flow the MDCS19 program also checks if anything is sent from a terminal
through the RS-232 serial interface. If so, it returns the appropriate answers to the terminal, refer to the
"Terminal communication" chapter.
The MDCS19 program manages the display and the pushbuttons according to a built in menu structure.
Refer to the "Menu structure chapter" for more details.

7. Other Program Functions


Besides the basic program functions described above the MDCS19 program performs some other
functions and decisions:

Precorrection vs. Regulating mode:


• The motorized cylinders and, consequently, the folding flaps can be set in twenty-six different
positions, one precorrection and twenty-six regulating positions.

• The precorrection mode is used when the paper tube is far out of design, to move it as fast as
possible to the correct position. The precorrection position lets the paper tube "move upwards" in
relation to the jaws, approx. 10 to 20 mm each jaw stroke (depends on volume and filling on/off).

• A normal production start always begins in the precorrection mode. A number of packages are
thrown away before the PLC starts its search for the filling position, i.e. when the Register Mark
Photocell Pulse is found in this position the filling is turned on. The filling position is chosen so that
when the paper tube is fully filled then the design control system has also found the correct design
position.

• The Filling Position is updated by the PLC to get the design time as close as possible to the filling
time. This function has to be selected in the Bit Parameter Register and is useful for reducing the
packages waste at start. The calculation of the filling position is done in this way: the 1st BC detected
closer to the design position is indicated to the PLC through the output Design OK in order to
calculate the time to get in design from start. Then the PLC compares the design time with the filling
time. If the design time is the same as the filling time within a window of ±1s the filling position is not
updated. If it is greater, the filling position is increased of 5 degrees (moved closer to the design
position), if it is lower, the filling position is reduced of 5 degrees. The filling position is also not
updated if the filling time is off the setpoint filling time of ±1s.

• The MDCS19 program continuously calculates the design error, also during precorrection mode.
When, in this mode, the design error becomes less than a certain value (-10mm ÷ 0mm) the
MDCS19 program prepares to switch into regulating mode. I.e. tries to find the correct motorized
cylinder position, one of the twenty-six possible positions and I/P transducer, to minimise the design
error.

• When in regulating mode the MDCS19 program tries to keep as low design error as possible. When:

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 7 (20)


MDCS19

• the design error is less than ±1.5 mm, or


• the mean design error of the two latest packages is less than ±1.5 mm,
then the Design OK signal (and front panel LED) is turned on. The filling machine is "in
production".

• When the MDCS19 program runs in the regulating mode it continues in this mode until:
• more that three consecutive packages have a design error greater than ±20 mm,
• more than four Register Marks should have passed the photocells, i.e. they are missed,
• the PLC resets the MDCS19 Enable signal.
When one, or more, of these condition is true the MDCS19 program switches to precorrection mode.

• When the filling machine is in short stop the design control system remains in regulating mode.
When started again the MDCS19 program tries to keep the design control as good as possible, just
like in normal production mode.

• Every time the filling machine is in stop, the I/P transducer pressure is set to 0,5 bar to maintain the
packaging material tensioned.

Volume Parameters:
• Normally the volume parameters are sent from the PLC, refer to the "Volume Parameter Transfer"
chapter.

8. TMCC2 Front Panel Display


The TMCC2 card is equipped with an alphanumeric display and three pushbuttons, placed on the
front panel. The following picture shows their position:

TMCC2
559810 Display / Led

"UP" Pushbutton S1
S2
S3
"DOWN" Pushbutton S4
S5
S6
"ENTER" Pushbutton S7
S8

The display can be used to send text messages or each character can be used as an Led to signal
program alarms and status.
When the program is in an idle status the display shows the program name and number. When the
program became active the each character is used as a Led with the following meaning:

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 8 (20)


MDCS19

LED Function
S1 MDCS Register mark decoded
S2 Design OK
S3 RH / LH motor step pulse.
S4 RH / LH motor direction ON=CW / OFF=CCW.
S5 Cylinder Position 19-25.
S6 Cylinder Position 12-18.
S7 Cylinder Position 6-11.
S8 Cylinder Position 0-5.

Note: if LEDs S5 and S6 are ON means that the sensor is broken in status ON. If LEDs S7 and S8
are ON means that the sensor is broken in status OFF.

The display can be indicates a malfunction in the program with the following meaning:

Display Meaning
Error in EEPROM This error indicates that there may be a hardware problem with
writing TMCC2.

Note: The card must be reset after an error, see instructions in the chapter 20 item 3 and 10.

At any time by pressing any pushbutton it is possible to enable a menu structure composed by
different levels and sub-menus. By using the "UP" and "DOWN" pushbuttons it is possible to navigate
through the menu items of a certain level and by pressing the "ENTER" pushbutton it is possible to
change the menu level or to execute a function associated to a menu item. The program functionality
is not influenced by accessing to the menu structure; if the menu allows to change some program
parameters then the program behavior can be influenced. Refer to the "Menu structure chapter" to
have more details about the menu structure and the functions that it is possible to activate through it.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 9 (20)


MDCS19

9. Menu structure
The MDCS menu structure is shown by means of the following table:

Menu Level
1 2 3 4 Description
MONITOR Select what data to view on the display
DES ERR Displays the Design Error
MEAN DER Displays the Mean Design Error
OUTPUT Displays the Output to the I/P (0-255)
BACK Back to Level 1
Select what data to send to the analog
DIAG OUT
output on Pin 6 of the TMCC2
DES ERR Outputs the Design Error of every pack.
MEAN2 DE Outputs the Mean Design Error of the
last 2 pack.
MEAN DER Outputs a filter of the Mean Design Error
OUTPUT Outputs the output value to I/P
MEAN OUT Outputs the mean output value to I/P
DES ADJ Outputs the Design Adjustment Value
BACK Back to Level 1
PHOT. Photocells menu
CONF? Y Photocells configuration menu
GREEN Sets the photocells spot color to green
BLUE Sets the photocells spot color to blue
RED Sets the photocells spot color to red
CALIB. Manual calibration menu
USE CAL. Use previous manual calibration
RUN CAL. Start manual calibration
BACK Exit from manual calibration menu
BACK Exit from photocell configuration menu
CONF? N Exit from photocells configuration menu
MAX D OK Max allowed design error menu
DOK=±X.X Set the max allowed design error (∗)
PRESSURE Set the pressure I/P transducer WTC
MIN PRES Minimum pressure menu
MIN= X.X Set the minimum pressure (0-10 V)
MAX PRES Maximum pressure menu
MAX= X.X Set the maximum pressure (0-10 V)
BACK Back to Level 1
BACK Exit from menu structure

∗ See chapter “besic program function”.


For more details about the photocells setting refer to the "Photocells management chapter".
For more details about the I/P tranducer setting refer to the " I/P Tranducer Setting chapter".

NOTE: the values XX=XX in the table can be changed by using the UP and DOWN pushbuttons and
the storage is performed after pressing the ENTER pushbutton.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 10 (20)


MDCS19

10. Photocells Management


Photocells features
• Remote setting from the TMCC2 card (see Photocell setting)
• Manual Teach-In function enabled from TMCC2 card (see Photocell setting)
• Increased lifetime obtained switching off the light spot after 20 minutes of machine stop; the light
spots are switched on again at machine start.
• Advanced diagnostic connecting a terminal to the TMCC2 serial port.
It is possible to know the total number of register marks decoded or missed, the parameters used by
the photocells, the status of the photocells, the number of hours that every light spot LED has been
working.

Photocells setting:
The photocells can be set by using the menu structure of the MDCS19 program.
When register mark decoding errors occur the first thing to check is the photocells alignment and
distance.
Then it is possible to change the spot color of the photocell, keeping the Dynamic Threshold = 30 and
the Teach Button disabled, in order to optimize the contrast between the register mark color and the
white. The following table gives the suggested light spot color, related to the register mark color to obtain
the best detecting performances:

Register mark Photocell spot color.


color
Black GREEN, RED, BLUE
Blue GREEN, RED
Light Blue / Cyan RED
Green RED, BLUE
Yellow BLUE
Red GREEN, BLUE
Magenta GREEN

It is also possible to perform the setting of the photocells through a manual teaching procedure. This
procedure must be used only if the basic settings (GREEN, RED, BLUE) do not solve register mark
decoding problems and a finer adjustment is required:
1. Stop the machine.
2. Go to menu item "RUN CAL." and press the enter pushbutton. This command enables the teach
button of the photocells.
3. Position the packaging material at 12mm from the first photocell in order to have the light spot on
the white background.
4. Push the teach button on the rear of the first photocell.
5. Move the packaging material so that the light spot scans through the register code.
6. Release the teach button.
7. Perform the steps 3-6 for the second photocell.
8. Go to menu item "USE CAL." and press the enter pushbutton. This command sends the taught
values to the photocells.
9. Run the machine.

Note! If false bar-codes are detected is possible to change the sensitivity of the photocells. Use the
command PTH: the value (xx) must be entered as hexadecimal. Type as follows:

PTH= xx<enter> Changes the dynamic threshould of the photocells; higher values of xx means
lower sensibility of the photocells (default setting value is 30).

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 11 (20)


MDCS19

11. Encoder Function and Gray Codes


The angle encoder is connected to the machine main shaft and outputs 128 degrees (values) for each
package. The encoder is 256 degrees version, which means that one package range from 0 to 127
degrees and the following from 128 to 255 degrees and then back to 0 again.
The value sent to the TMCC2 is Gray-coded, which means that only one of the eight signals (bits)
changes for each change in degree (this prevents erroneous angle values on the signal lines.) This also
means that the MDCS19 program must convert the value into a "normal" representation before it can be
used in calculations. A conversion table is given in the “grey code table” chapter.

12. Design Adjustment Signal


The TPOP is used to move (fine-adjust) the design position in relation to the jaw system. The TPOP is
connected via Flexbox to an analog output of the PLC. The MDCS19 program converts the voltage level
into an angle offset that is then added to the constant production angle set by the PLC. The adjustment
range ±500 on TPOP corresponds to a movement of ±5 mm on the design position, this range being the
same for all volumes.
Negative settings will move the design downward in relation to the jaw system, and vice versa.

13. Output Signal


The PID algorithm calculates a new output value for every package. The calculated output value ranges
from 0 to 255. This value is converted into an analogue signal for the I/P Transducer and twenty-six
digital signals to the driver controlling the folding flap motorized cylinders. The I/P Transducer signal
overlaps the motorized cylinder positions (hysteresis) as below:

25
Max.
(2.5 bar)

13
Cylinder I/P transducer
position pressure (bar)

Min.
0 (0.5 bar)

0 1 10 128 255
1 Output value

Output value = 0 sets the precorrection position of the motorized cylinders and sets the maximum
pressure on the I/P Transducer.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 12 (20)


MDCS19

14. Terminal (PC) communication


A terminal, or a PC with a terminal program, is not necessary during normal production, but may be used
for test and service purposes. Through the serial interface it is possible to see the design error, output
values and other MDCS19 status values.

The communication is a standard RS-232 serial interface. Use a cable suitable for the TMCC2 and the
PC (terminal). Necessary pin connections are:

PC 9-pin TMCC2 9-pin


female male
2 3
3 2
5 5

If you are using a PC, a terminal program like HyperTerminal, windows 3.11 terminal etc. may be used.
Configure the program for:

• Baudrate: 9600
• Parity: None
• Bits: 8
• Stopbits: 1
• Flow Control: None

The commands and parameters, if any, to the MDCS19 program is entered on the keyboard, and the
command is executed when the RETURN key is entered. The functions described below are available:

Annn Angle nnn. The Production Angle (=machine angle) may be set with this command. nnn is
the new angle value, ranging from 0 to 255 decimal degrees. Normally the Production
Angle is set from the PLC, but this command overrides the PLC setting. It may be used in
test purpose to find the correct nominal Production Angler, which will later be set from the
PLC. Note that the Design Adjustment setting is added to this value.
For example: A72 sets the Production Angle to 72 degrees (110 octal).

CAL Execute the calibration sequence of the motorized cylinder.

Dddd D-constant: Sets the D parameter in the PID controller algorithm, in 1/100 units. The
original value will be restored after a TMCC2 reset.

E Displays the current Encoder value, first the hexadecimal Gray code, then converted to
octal.

Fooo Force ooo. This command forces the outputs, I/P Transducer pressure and Motorized
Cylinder position, to a certain value which is (ooo-1). F0 resets the forcing:
F0 Reset (disable) output force.
F1 Force to Precorrection output.
F2 Force to output = 1.
...
F255 Force to output = 254.
(This means that output=255 is not possible but since it is a small step in the upper region
of the output range this has no practical meaning.)
NOTE! This function is only available when the machine is running.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 13 (20)


MDCS19

H Help Menu: displays the commands available.

Iiii I-constant: Sets the I parameter in the PID controller algorithm, in 1/100 units. The original
value will be restored after a TMCC2 reset.

L Show the LED function.

Mnn Change the Design OK window and the value is stored into the EEPROM, so kept even
after a shut down or a reset. The value is expressed in 1/10 of mm. (i.e. 20 means ± 2.0
mm).

Pppp P-constant: Sets the P parameter in the PID controller algorithm, in 1/100 units. The original
value will be restored after a TMCC2 reset.

PTH=xx Set photocells dynamic threshould, 00-F2 (hex value). See chapter “Photocell
Management”

Rn Reporting ON/OFF. This command enables and disables the automatic reporting of the
design error and output value for every package.
R0 Disable reporting.
R1 Enable reporting.
Note! When the monitoring is finished, remember to set R0, in order to avoid delays
in the scanning time.

S Status: This command displays a list of parameters that may be of interest for test and
service purposes:

DesignError mean (mm) : A filtered* value.


Output mean (0-255) : A filtered* value.
Machine Speed, (p/h) : In packages per hours.
Repeat Length (mm) : The Repeat Length set from PLC.
Production Angle const (dec.degr.) : The Production Angle set from the
PLC.
Production Angle +pot (dec.degr.) : The Production Angle + the Design
Adjustment Pot offset.
WTC constant pressure (bar*0.1) : The pressure set from the PLC.
MaxDesignOK (mm) : The max allowed design error.
MaxPressure, MinPressure (bar*0.1): The maximum and minimum pressure
set by the TMCC2 front panel buttons.
Design Adjustment (V) : A value 0 -10 Volt depending on the
Design Adjustment position.
Filling Position Calculation: ON.
Pc=, Ic=, Dc=: The constants for the PID controller
algorithm.
Photocell Status: Show if there is a failure of the
photocells.

* = Filter algorithm: 90%(old values) + 10%(new values)

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 14 (20)


MDCS19

Y Displays a detailed status of the photocells for test and service purposes:

Commands OK: Total number of commands executed by the


photocells
Commands failed: Total number of commands failed by the photocells
Barcode decoded: Total number of barcodes decoded by the TMCC2
Barcode errors: Total number of barcodes missed by the TMCC2
Dynamic Threshold: Photocell threshold
Light Spot: Color of the light spot used by the photocells
Output: Logic of the photocell outputs (Light/Dark
switching)
3 bar Phot. Working Hours: Number of hours that every LED of the photocell
has been working
4 bar Phot. Working Hours: Number of hours that every LED of the photocell
has been working
3 bar Phot. Software ver. / S.N.: Software version of the photocell firmware and
serial number
4 bar Phot. Software ver. / S.N.: Software version of the photocell firmware and
serial number
Hidden Command

X <Password> Formats the TMCC2 EEPROM:

- Restore to default values the photocell parameters (the values acquired during last teach
procedure are lost!)
- Reset the values of:
Commands Ok
Command Errors
Barcode decoded
Barcode errors
Note: only for internal used and when machine is stopped.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 15 (20)


MDCS19

15. Volume Parameter Transfer


The Repeat Length, the Production Angle, the I/P Transducer Constant Pressure and the Parameter
Bit Register may be sent from the PLC to the MDCS19 program. This sending uses four digital +24V
signals and the protocol is as follows:

From PLC:
VolumeEnable
VolumeClock
VolumeData

From TMCC2:
VolumeAcknowledge

8. Repeat the message until


1. Set VolumeEnable 5. Output last bit
VolumeAcknowledge is set
2. Output bit 1 6. Toggle VolumeClock
3. Toggle VolumeClock 7. Reset VolumeEnable
4. Shift out all data bits

• The bit time must be at least 5 ms.


• The output bits are shifted with the least significant bit (LSB) first:

<LSB>Repeat Length<MSB><LSB>Production Angle<MSB><LSB>WTCConstantPressure<MSB>


<LSB>Bit Parameters<MSB>

• The Repeat Length is in 1/10 of mm, i.e. a repeat length of 245 mm is sent as 2450.
• The Production Angle is in integer degrees, i.e. an angle of 123 is sent as 123. (Octal or decimal
degrees notation is irrelevant since the number is sent in bit format which is the same for both
alternatives).
• The WTC Constant Pressure is sent as the value air pressure / minute (bar).
• The 16 Bit Parameters register is used to select specified functions in the program.

Other features:
• The signal VolumeAcknowledge in the protocol is useful when, for example, the PLC starts up earlier
than the TMCC2 or if the TMCC2 is replaced or reset during power on. In these cases the
VolumeAcknowledge is reset to low and the PLC should start to send the message again.

• The MDCS19 program must receive at least two complete messages that are exactly the same
before it sets the VolumeAcknowledge signal.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 16 (20)


MDCS19

16. Parameter Bit Register


A 16 bit parameter register is used by the PLC to select particular functions in the TMCC2 Program.
The LSB bit is used to select the Filling Position Calculation. See figure:

MSB LSB

Bit Parameters 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1

Filling Poristionr
Calculation ON

With this function the TMCC2 card sends to the PLC the 1st BC in design within an error of ± 8mm during
precorrection. This lets the PLC to calculate the time to get the 1st BC in design after start so to adjust
the filling position in order to have the design time as close as possible to the filling time.
17. I/P Transducer Setting
The I/P Transducer pressure is set manually with TMCC2 push button, refer to the menu structure and
the following sequence are used (for more detailed instruction see MM book):

A) Basic Setting on TMCC2 card:


The Analog output signal (0-10V) connected to the I/P Transducer must be first set on the TMCC2
card as follows:
1. The connector must be removed on I/P transducer to not damage the manometer.
2. Connect the voltmeter between Pin No 2 and 6 on the back plane of the TMCC2 card.
3. Select “MIN PRES”, check the reading is 0 volts, if not adjust using Pushbotton “UP or DOWN”.
4. Select “MAX PRES”, check the reading is 10 volts, if not adjust using Pushbotton “UP or DOWN”.
5. Reconnect the connector.

B) Basic setting on I/P transducer:


1. Open the rubber cover placed over the setting window as shown in the picture.
2. Set the Gain trimmer (G) fully anti clock wise in order to reduce the gain of the I/P at the minimum
level.
3. Select “MIN PRES” and check the output pressure of the I/P. Turn the Zero trimmer (Z) in order to
have zero bar at the I/P output.
4. Select “MAX PRES” and check the output pressure of the I/P. Turn the Span trimmer (S) in order to
have 3.0 bar at the I/P output.
5. Go back to point 3 and repeat the point 4 until the setting is satisfactory.

Z S G
Setting

Connector

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 17 (20)


MDCS19

C) Final Setting of I/P transducer:

1. Set the I/P Transducer minimum pressure (basic setting 0.5 bar) with “MIN PRES” using
Pushbotton “UP or DOWN” and check the pressure on the manometer.
2. When correct minimum pressure has been reached, set the I/P Transducer maximum pressure
(basic setting 2.5 bar) with “MAX PRES” using Pushbotton “UP or DOWN” and check the pressure
on the manometer.
3. Repeat item 1 and 2 until the pressure is correct.
4. Exit the menu on the TMCC2 see chapter “Menu Structure”.

18. Setting Criteria


The TMCC2 by menu structure can modify the working pressure range for the I/P transducer. For more
detailed instruction please see MM book.
It is necessary to check the package forming during start-up and production in order to decide if it is
worth to decrease the maximum pressure. When using low stiffness to packaging material, it is
recommended to reduce pressure to preserve integrity.

It is also possible, as an alternative function set the WTC to a constant pressure from the PLC (for
example, value 10=1bar), which means the pressure will be fixed. When design OK is enable, the
pressure, in precorrection condition is set according the maximum value.
The motorized cylinder will work with twenty-six positions on both conditions.

19. Flap Cylinders Calibration


The flap cylinders calibration procedure is enabled by using a PC command (refer chapter Terminal
PC communication) see the tables below.

PC command Function
C Calibration: full distance
H Home position
M Maximum forward movement in correction mode.
V View acceleration motor profile
E Exit

Note: View acceleration motor profile is only for internal use. If you press the «V» key, press it
repeatedly until the main menu is displayed.

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 18 (20)


MDCS19

Calibration Procedure:

1. Connect the cable between the PC and the TMCC2 front panel connector and start the
communication.
2. To enable the calibration of the Right Cylinder manually move the machine to 120°-220°
3. Type the command CAL to enter the menu calibration and the currently enabled cylinder will move
to its home position, then the full distance.
4. Press the «H» key to enter the home position. The cylinder will move to find the sensor.
5. Press the «C» key to enter the calibration full distance. The cylinder will move its full distance
42mm.
6. Go back to point 3 and repeat the point 4 and 5 until the setting is satisfactory. The operator can
adjust the sensor position and the cylinder by following the MM instructions.
Note: the cylinder must not touch the mechanical stops on the forward or backward movements.
7. From point 5 press the «M» key to enter the maximum forward movement. The cylinder will move
10mm (correction mode).
8. Press the «E» to exit from calibration.
9. To enable the calibration of the Left Cylinder manually move the machine to 301°-40° and repeat
the point from 4 to 7.
10. When both cylinders are calibrated repeat the point 8.

20. Program Download


The MDCS19 program should be downloaded to the TMCC2 with status in Power ON. The download is
done from a PC with at least one diskette station and one serial RS-232 interface. Refer to the "Terminal
(PC) Communication" chapter for a description of the communication parameters.

Download procedure:
1. Connect the cable between the PC and the TMCC2 RS232 connector.
2. Start the HyperTerminal program on the PC.
3. If there is an application running type STOP<enter> or keep DOWN and ENTER pushbutton
pressed for few seconds to stop it.
4. Insert the program diskette marked "2589438-0002” into the PC diskette station.
5. Type the command E FLASH<enter> to erase the TMCC2 flash memory.
6. When the erasing operation is completed type D<enter> to prepare the application download.
7. Select the menu Transfer and the menu item Send Text File.
8. Select the file 2589438.1002 on the diskette marked "2589438-0002.
9. The downloading starts and the progress of the download is shown with dots on the terminal
screen.
10.When the new program is downloaded without errors type RUN<enter> or ENTER pushbutton
pressed two time to start the application program.
11. Check the I/P transducer setting (refer to that chapter).

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 19 (20)


MDCS19

21. Gray Code Table


Gray Octal Dec Gray Octal Dec Gray Octal Dec Gray Octal Dec
---- ---- 0 0 -••- ---- 100 64 ••-- ---- 200 128 •-•- ---- 300 192
---- ---• 1 1 -••- ---• 101 65 ••-- ---• 201 129 •-•- ---• 301 193
---- --•• 2 2 -••- --•• 102 66 ••-- --•• 202 130 •-•- --•• 302 194
---- --•- 3 3 -••- --•- 103 67 ••-- --•- 203 131 •-•- --•- 303 195
---- -••- 4 4 -••- -••- 104 68 ••-- -••- 204 132 •-•- -••- 304 196
---- -••• 5 5 -••- -••• 105 69 ••-- -••• 205 133 •-•- -••• 305 197
---- -•-• 6 6 -••- -•-• 106 70 ••-- -•-• 206 134 •-•- -•-• 306 198
---- -•-- 7 7 -••- -•-- 107 71 ••-- -•-- 207 135 •-•- -•-- 307 199
---- ••-- 10 8 -••- ••-- 110 72 ••-- ••-- 210 136 •-•- ••-- 310 200
---- ••-• 11 9 -••- ••-• 111 73 ••-- ••-• 211 137 •-•- ••-• 311 201
---- •••• 12 10 -••- •••• 112 74 ••-- •••• 212 138 •-•- •••• 312 202
---- •••- 13 11 -••- •••- 113 75 ••-- •••- 213 139 •-•- •••- 313 203
---- •-•- 14 12 -••- •-•- 114 76 ••-- •-•- 214 140 •-•- •-•- 314 204
---- •-•• 15 13 -••- •-•• 115 77 ••-- •-•• 215 141 •-•- •-•• 315 205
---- •--• 16 14 -••- •--• 116 78 ••-- •--• 216 142 •-•- •--• 316 206
---- •--- 17 15 -••- •--- 117 79 ••-- •--- 217 143 •-•- •--- 317 207
---• •--- 20 16 -••• •--- 120 80 ••-• •--- 220 144 •-•• •--- 320 208
---• •--• 21 17 -••• •--• 121 81 ••-• •--• 221 145 •-•• •--• 321 209
---• •-•• 22 18 -••• •-•• 122 82 ••-• •-•• 222 146 •-•• •-•• 322 210
---• •-•- 23 19 -••• •-•- 123 83 ••-• •-•- 223 147 •-•• •-•- 323 211
---• •••- 24 20 -••• •••- 124 84 ••-• •••- 224 148 •-•• •••- 324 212
---• •••• 25 21 -••• •••• 125 85 ••-• •••• 225 149 •-•• •••• 325 213
---• ••-• 26 22 -••• ••-• 126 86 ••-• ••-• 226 150 •-•• ••-• 326 214
---• ••-- 27 23 -••• ••-- 127 87 ••-• ••-- 227 151 •-•• ••-- 327 215
---• -•-- 30 24 -••• -•-- 130 88 ••-• -•-- 230 152 •-•• -•-- 330 216
---• -•-• 31 25 -••• -•-• 131 89 ••-• -•-• 231 153 •-•• -•-• 331 217
---• -••• 32 26 -••• -••• 132 90 ••-• -••• 232 154 •-•• -••• 332 218
---• -••- 33 27 -••• -••- 133 91 ••-• -••- 233 155 •-•• -••- 333 219
---• --•- 34 28 -••• --•- 134 92 ••-• --•- 234 156 •-•• --•- 334 220
---• --•• 35 29 -••• --•• 135 93 ••-• --•• 235 157 •-•• --•• 335 221
---• ---• 36 30 -••• ---• 136 94 ••-• ---• 236 158 •-•• ---• 336 222
---• ---- 37 31 -••• ---- 137 95 ••-• ---- 237 159 •-•• ---- 337 223
--•• ---- 40 32 -•-• ---- 140 96 •••• ---- 240 160 •--• ---- 340 224
--•• ---• 41 33 -•-• ---• 141 97 •••• ---• 241 161 •--• ---• 341 225
--•• --•• 42 34 -•-• --•• 142 98 •••• --•• 242 162 •--• --•• 342 226
--•• --•- 43 35 -•-• --•- 143 99 •••• --•- 243 163 •--• --•- 343 227
--•• -••- 44 36 -•-• -••- 144 100 •••• -••- 244 164 •--• -••- 344 228
--•• -••• 45 37 -•-• -••• 145 101 •••• -••• 245 165 •--• -••• 345 229
--•• -•-• 46 38 -•-• -•-• 146 102 •••• -•-• 246 166 •--• -•-• 346 230
--•• -•-- 47 39 -•-• -•-- 147 103 •••• -•-- 247 167 •--• -•-- 347 231
--•• ••-- 50 40 -•-• ••-- 150 104 •••• ••-- 250 168 •--• ••-- 350 232
--•• ••-• 51 41 -•-• ••-• 151 105 •••• ••-• 251 169 •--• ••-• 351 233
--•• •••• 52 42 -•-• •••• 152 106 •••• •••• 252 170 •--• •••• 352 234
--•• •••- 53 43 -•-• •••- 153 107 •••• •••- 253 171 •--• •••- 353 235
--•• •-•- 54 44 -•-• •-•- 154 108 •••• •-•- 254 172 •--• •-•- 354 236
--•• •-•• 55 45 -•-• •-•• 155 109 •••• •-•• 255 173 •--• •-•• 355 237
--•• •--• 56 46 -•-• •--• 156 110 •••• •--• 256 174 •--• •--• 356 238
--•• •--- 57 47 -•-• •--- 157 111 •••• •--- 257 175 •--• •--- 357 239
--•- •--- 60 48 -•-- •--- 160 112 •••- •--- 260 176 •--- •--- 360 240
--•- •--• 61 49 -•-- •--• 161 113 •••- •--• 261 177 •--- •--• 361 241
--•- •-•• 62 50 -•-- •-•• 162 114 •••- •-•• 262 178 •--- •-•• 362 242
--•- •-•- 63 51 -•-- •-•- 163 115 •••- •-•- 263 179 •--- •-•- 363 243
--•- •••- 64 52 -•-- •••- 164 116 •••- •••- 264 180 •--- •••- 364 244
--•- •••• 65 53 -•-- •••• 165 117 •••- •••• 265 181 •--- •••• 365 245
--•- ••-• 66 54 -•-- ••-• 166 118 •••- ••-• 266 182 •--- ••-• 366 246
--•- ••-- 67 55 -•-- ••-- 167 119 •••- ••-- 267 183 •--- ••-- 367 247
--•- -•-- 70 56 -•-- -•-- 170 120 •••- -•-- 270 184 •--- -•-- 370 248
--•- -•-• 71 57 -•-- -•-• 171 121 •••- -•-• 271 185 •--- -•-• 371 249
--•- -••• 72 58 -•-- -••• 172 122 •••- -••• 272 186 •--- -••• 372 250
--•- -••- 73 59 -•-- -••- 173 123 •••- -••- 273 187 •--- -••- 373 251
--•- --•- 74 60 -•-- --•- 174 124 •••- --•- 274 188 •--- --•- 374 252
--•- --•• 75 61 -•-- --•• 175 125 •••- --•• 275 189 •--- --•• 375 253
--•- ---• 76 62 -•-- ---• 176 126 •••- ---• 276 190 •--- ---• 376 254
--•- ---- 77 63 -•-- ---- 177 127 •••- ---- 277 191 •--- ---- 377 255

Tetra Pak Carton Ambient S.p.A. Functional Description


Issued by / Date: Approved by / Date:
ECM 140649
Fabio Bassissi / 31-August-2003 Fabio Bassissi / 31-August-2003
Identity Document type Version Page

4-2589439-0000 DSC 02 20 (20)

You might also like