Skip to Content
Success story · Fortaps production lines
Talk to an engineer

Success story · Fortaps · Tarragona, Spain

Fortaps runs eight lines. Four M-Duino PLCs feed MySQL and the ERP.

Fortaps makes about 30 million plastic parts a year. M-Duino PLCs from Industrial Shields read the machines on its production lines, start and stop them, and write the data to a MySQL database. The ERP reads it for stock and orders.

8production lines in the cabinet photo, two per PLC
4M-Duino PLCs on the production LAN
~30 Mplastic parts made at Fortaps every year
24 ha day, for more than two years, without issue

Every machine already knows how it is doing.

The PLC writes it into a table your ERP can read.

Fortaps is a family owned business, established in 1996, with two generations of expertise in plastic parts. It designs, makes and sells plastic protectors, ferrules, caps and stoppers, mainly in LDPE, and in HDPE when a part needs more hardness. It does not use PVC. It makes about 30 million units a year with its own moulds, in a plant of over 7,000 m² in Tarragona, Spain. Fortaps adopted open source software early in its manufacturing process. Then it brought open source hardware to its production lines: the Arduino based PLCs from Industrial Shields.

From the field

The cabinet, the parts and the plant.

Real material from the original Fortaps success story.

Four M-Duino PLCs on DIN rail in the Fortaps production line cabinet, each labelled for two lines and connected by Ethernet
Inside the cabinet at Fortaps: four M-Duino PLCs, each labelled for two lines (1-2, 3-4, 5-6, 7-8), each with its Ethernet cable.
Plastic parts made by Fortaps on the monitored production lines
Plastic parts made by Fortaps. About 30 million units leave the plant every year.
Fortaps plant in Tarragona: stock holding area with packed parts and production machinery
The Fortaps plant in the original success story: the stock holding area and the production machinery.

The challenge

See every line, from the machine to the ERP.

The Fortaps plant is designed to optimise the whole flow: receiving goods, production, stock holding and shipment. In many plants, the link between the machines and the ERP is a count made by hand. At Fortaps, the data follows one path: from the encoders and sensors on the machines to the MySQL table that the ERP reads.

01

Machine status

Is the machine running, stopped or waiting? Encoders and sensors on each machine already have the answer. The PLC reads them.

02

Real counts

Pieces per hour come from the line itself. Other equipment that reads the production status is connected too.

03

Stock and orders

Production data goes to MySQL. The ERP uses it to control stock and orders.

Tarragona summers, 24 hours a day

Fortaps makes plastic parts, so in summer its production lines work at very high temperatures. The M-Duino PLCs have run 24 hours a day for more than two years without issue.

How it works

Two loops: from the machine to the table, and from the table to the order.

These panels show the general pattern. Change the state of a line, move the cycle time, start an order. They are illustrative simulations: generic lines, scaled times, example values. They do not show the program or the data of Fortaps.

Loop 1 · Machine to table

Each machine becomes a row of data

Encoders and sensors tell the PLC if a machine runs, and how fast. The PLC counts the pieces, works out pieces per hour and sends the result over Ethernet to MySQL. One PLC can watch more than one line. At Fortaps, each M-Duino is labelled for two lines.

  • Inputs: encoders and sensors on each machine
  • State per line: run, micro stop, stop (example states)
  • Count and pieces per hour
  • A row in MySQL at a fixed interval (example)
Line 10Line 20M-Duino 1Lines 1-2MySQL
RUNMICRO STOPSTOP
4.0 s

Rows written to MySQL (example)

    Illustrative simulation. Generic lines, scaled times, example values, no data from Fortaps.

    Loop 2 · Table to order

    The ERP sees the lines. The lines follow the order.

    MySQL keeps the history of every line, so you can check performance and efficiency. The ERP reads the same data for stock and orders. The PLC outputs close the loop: start and stop of machines and the production output, according to the user configuration. Here, an example rule stops a line when its order is complete.

    • Availability per line from the MySQL history (example values)
    • Stock and orders in the ERP
    • Start and stop of machines from the PLC outputs
    • Example rule: stop the line at the end of the order
    Availability per line, from MySQL (example)L1L2L3orderL4L5L6L7L8
    0Order on line 3 (example)
    0Plant availability (example)
    0Stock booked in the ERP (example)

    ERP events (example)

      Illustrative simulation. Generic lines, scaled times, example values, no data from Fortaps.

      See OEE, downtime and alarms in the Machine Monitor simulator

      Related case: packaging line traceability with ESP32 PLC

      System architecture

      How do M-Duino PLCs send line data to MySQL and the ERP?

      Each M-Duino reads the machines of two lines and controls their outputs. All of them are on the production LAN over Ethernet. Their data goes to MySQL, where it is analysed, and MySQL is connected to the ERP for stock and orders. The case does not publish the protocol or the table layout. The diagram shows one possible layout.

      Fortaps: production line monitoring with M-Duino PLCs, MySQL and the ERP8 production linesencoders · sensorsL1L21-2start · stopM-Duino 1Lines 1-2L3L43-4M-Duino 2Lines 3-4L5L65-6M-Duino 3Lines 5-6L7L87-8M-Duino 4Lines 7-8Production LAN · EthernetMySQLperformance · efficiencyERPstock · ordersCounting equipmentpieces/hour · link not publishedOne possible layout. The case does not publish the protocol or the table layout.8 production linesL1L2L3L4L5L6L7L8start · stopM-Duino 1Lines 1-2M-Duino 2Lines 3-4M-Duino 3Lines 5-6M-Duino 4Lines 7-8Production LAN · EthernetCounting equipmentpieces/hourMySQLperformance · efficiencyERPstock · ordersOne possible layout. The case does not publishthe protocol or the table layout.
      Data over the production LAN (Ethernet)PLC outputs to the machines: start, stop, production outputExample elements, not published by the case
      Signals and data
      FlowBetweenTypePurpose
      Machine statusEncoders and sensors → M-DuinoInputsShows if each machine runs, and how fast
      Production statusCounting equipment → M-DuinoConnection not publishedBrings counts such as pieces per hour
      Machine controlM-Duino → machinesOutputsStart and stop of machines and production output, per user configuration
      Production dataM-Duino → MySQLEthernet, production LANStores the data to check performance and efficiency. Protocol not published
      Stock and ordersMySQL ↔ ERPDatabase linkThe ERP controls stock and orders with the production data

      Why Fortaps chose M-Duino

      Reliable, flexible and open.

      Fits the installation

      The signal types of the M-Duino are configurable, so the PLC adapted easily to the existing installation and its data acquisition. The high performance of the controller was another key factor.

      A program Fortaps can change

      Fortaps programmed its application with the Arduino IDE, open source software. The plant upgrades it when its needs change.

      Open source, end to end

      Fortaps already used open source software in its manufacturing process. With open source hardware from Industrial Shields, its production lines follow the same approach, from the PLC to the database.

      Source: the interview with Ramon Boncompte, Sales Director at Industrial Shields, in the original success story (2015).

      Hardware used

      M-Duino PLCs with Ethernet, one for every two lines.

      M-DUINO ETHERNET PLC ARDUINO 58, industrial Arduino PLC with Ethernet for DIN rail

      M-DUINO ETHERNET PLC ARDUINO 58

      An Arduino Mega based PLC for DIN rail with 58 I/O, Ethernet, RS-485 and RS-232. It reads encoders and sensors, drives start and stop outputs and sends the data over the production LAN.

      Inputs
      36, of which 16 analog (0-10 V)
      Outputs
      22, of which 8 analog/PWM
      Communications
      Ethernet, RS-485, RS-232, TTL, I2C, SPI
      Programming
      Arduino IDE over USB or Ethernet
      Inside
      Arduino Mega 2560, RTC, microSD slot
      Power and mounting
      12 to 24 Vdc, DIN rail, IP20

      The case does not publish the exact M-Duino model. The units in the photo are an earlier M-Duino generation. The image shows the M-DUINO ETHERNET PLC ARDUINO 58, a current M-Duino with Ethernet. Count the signals of your machines first, then choose the model of the family.

      Questions about this case

      What does a PLC measure to monitor a production line?

      In this case, the M-Duino PLCs read encoders and sensors on each machine to know its status, and they are connected to other equipment that reads the production status, for example pieces per hour. They also control outputs such as start and stop of machines. For a pulse counting example, see Production pulse counter in the Solution Library.

      How does the PLC send production data to MySQL?

      The M-Duino PLCs are connected over Ethernet to the production LAN, and all the data goes to a MySQL database. The case does not publish the protocol. A common pattern: the PLC publishes its values over Modbus TCP or MQTT, and a small service on a server writes the rows. For a logging example, see MySQL alarm logging with Node-RED. The same MySQL database is connected to the ERP to control stock and orders. The case does not publish how.

      Who is Fortaps?

      Fortaps is a family owned business from Tarragona, Spain, established in 1996. It designs, makes and sells plastic protectors, ferrules, caps and stoppers, about 30 million units a year. The original success story (2015) says it works aligned to the ISO 9001:2008 quality standard. More at fortaps.com.

      Can I monitor machines that are already installed?

      Yes. That was one of the reasons for the choice here: the M-Duino adapts easily to the existing installation and its data acquisition, and its signal types are configurable. List the encoders, sensors and signals of each machine first. For a full plant register map, see Modbus TCP register map.

      Can an Arduino based PLC run 24 hours a day in a hot plant?

      In this plant, the production lines work at very high temperatures in summer, and the M-Duino PLCs have run 24 hours a day for more than two years without issue. For your project, check the operating temperature in the datasheet of the model you choose.

      Which parts of this story are facts, and which are examples?

      Facts from the original success story: Fortaps, its plant in Tarragona and about 30 million units a year, M-Duino PLCs on the production LAN over Ethernet, inputs from encoders and sensors, start and stop outputs, MySQL for performance and efficiency, the link to the ERP for stock and orders, 24 hours a day for more than two years, and the cabinet photo with four PLCs for lines 1 to 8. Examples: the protocol, the table layout, the rates, the availability values, the order rule and the exact M-Duino model.

      Download the success story

      4-page PDF with the challenge, the logic, the architecture and the hardware. No form required.

      Similar project?

      Tell us your lines and your machines. An engineer will answer.

      Tell us how many lines and machines you have, which signals they give and where the data should go: MySQL, an ERP, an MES or a dashboard. We will tell you which controller fits and how to connect it.

      • You get an answer from our technical team
      • Signal count and controller sizing per line
      • Arduino, ESP32 or Raspberry Pi based PLCs