Trang 1 FACULTY FOR HIGH QUALITY TRAINING GRADUATION THESIS AUTOMATION AND CONTROL ENGINEERING ADVISOR :STUDENTS:FILLING, CAPPING AND PLACING BOTTLES USING S7-1200 AND MAGICIAN ROBOTIC A
INTRODUCTION
Problem statement
The bottles in this project are glass bottles with rubber caps on them They are usually used in the pharmaceutical industry to hold medicine As shown in Figure 1-
1, the pharmaceutical manufacturing market has overgrown in recent years Its size of it will triple in 2030
Figure 1-1 Global pharmaceutical manufacturing market
As illustrated in Figure 1-2, Vietnam's per capita medicine consumption is on the rise, making the Vietnamese market an attractive and promising sector Despite the current limitations in the country's medicine manufacturing process, the industry is poised for inevitable growth and development Consequently, the demand for advanced filling and capping systems is expected to surge significantly in the next few years, driven by the escalating need for efficient and modern pharmaceutical production.
Figure 1-2 Consumption of medicine per capita in Vietnam
Glass bottles with rubber caps are also crucial for veterinary medicine Moreover, the bottles used in this project are precisely veterinary medicine bottles According to
CHAPTER 1: INTRODUCTION a newspaper in [1] "Thị trường phát triển thuốc thú ý trong những năm tới", the veterinary medicine was 22,973 milion dollars in 2019 and will be 29,698 milion dollars in 2027 The compound annual growth rate is 4.6% Figure 1-3 shows a veterinary medicine production line with rubber caps
Figure 1-3 Veterinary medicine production line
The global robotic arm market is poised for significant growth in the coming years, driven by the inevitable advancement of automation, with projected increases in speed and payload performance As depicted in Figure 1-4, this growth trend is expected to have a profound impact on the industry Furthermore, emerging markets such as Vietnam are likely to experience a surge in demand for robotic arms, fueling the market's expansion and solidifying its position as a key player in the automation sector.
Figure 1-4 Global robotic arm market
Vietnam's robotic market size has experienced significant growth, as illustrated in Figure 1-5 The market is currently dominated by prominent international players, including ABB Ltd., Robot 3T Group, Sony Corporation, Midea Group Co Ltd., Honda Motor Co Ltd, Siemens AG, DENSO Corporation, Rockwell Automation Inc., KION Group AG, and Seiko Epson Corporation, driving the market's expansion However, with the country's economic and technological advancements, the emergence of a domestic market player is anticipated in the near future, potentially altering the market dynamics.
Figure 1-5 Growth of the Vietnam robotics market
In Vietnam, East Asian servos, particularly those from Japan and Korea, dominate the market, with Mitsubishi servos being widely available across the country Conversely, German servos are relatively scarce, making them difficult to purchase Despite the lack of a comprehensive market survey, the popularity of Japanese and Korean servos is evident, with Mitsubishi being a prominent player in the industry.
On the other hand, PLC Siemen is the most popular brand in the world As in Figure 1-7, it takes 44.5% of the market share, while Mitsubishi PLC only takes 13.1%
Siemens PLCs stand out for their exceptional durability, surpassing that of other brands, making them a preferred choice in the industry To cater to the Vietnamese market, this project focuses on bridging the compatibility gap between Siemens PLCs and Mitsubishi servos By utilizing a Siemens PLC to control Mitsubishi Servos, this integration aims to provide a seamless and efficient solution, leveraging the strengths of both technologies.
Figure 1-6 AC servo market in Vietnam
Research objectives
There are several particular objectives for this project:
- The filling accuracy is less than 95%
- Caps are put and pressed on bottles with a success rate of 95%
- Bottles are placed orderly in a square shape in a square box with a success rate of 100%
- Bottles are fed continuously in the input (Other filling and capping systems of other students can only handle one bottle at a time)
- Expected performance: 3 bottles per minute.
Research method
- Mathematical calculations and models are derived through basic Kinematics and Geometric model knowledge
- Observations and experiments are conducted by SolidWorks, MATLAB simulation, and building of the real model.
Constraint
- Kinetics and the controller for each joint are not calculated We set all controllers at default settings and control the robot through kinematics only
Our robotic design eschews advanced mechanical components like helical, bevel, and worm gears, instead relying on belts to facilitate motion However, this approach has its drawbacks, as it fails to prevent dust accumulation and subsequently compromises durability Furthermore, the maximum speed of joints in this design is limited, falling short of the capacity of servo motors, which can hinder overall performance.
- Other fields related to automation, such as image processing, web server, etc., are not used in this project.
Report layout
The reason why this project is conducted is represented The scope, constraint, and research method are also written.
LITERATURE REVIEW
Industrial Manufacturing Line
A manufacturing line, also known as an assembly line, is a systematic series of activities set up in a factory to transform raw materials into a finished consumer product or assemble components into a complete product This process involves the sequential movement of the product through various stations, each performing a specific task or operation, resulting in a highly organized and efficient production system.
Figure 2-1 An electronics Assembly Line
A well-designed manufacturing line is crucial for optimizing productivity, reducing production time, and maintaining consistent quality output By efficiently utilizing resources such as labor, machinery, and materials, manufacturers can streamline their operations and improve overall efficiency Typically, a manufacturing line follows a predetermined sequence of operations, with each workstation specializing in a specific task to ensure a smooth and seamless production process.
Across various sectors, manufacturing lines play a crucial role in producing diverse products, including automobiles, electronics, appliances, food and beverages, and pharmaceuticals These production lines often combine manual labor, automated machinery, and robotics to optimize efficiency, with the specific configuration depending on the product's complexity and production requirements.
2.1.2 History of the Manufacturing Line
The evolution of the manufacturing line in the meat-processing industry dates back to the late 18th and early 19th centuries, originating from the first factories in England and the United States that pioneered task division and product assembly on a line The introduction of mechanization and machine utilization transformed the manufacturing process, laying the groundwork for the development of the assembly line concept This concept, which involves products moving through a sequence of workstations, each performing a specific task, emerged as a significant innovation in the early 20th century, revolutionizing the manufacturing process.
The assembly line system reached its peak during the Industrial Revolution in the late 19th and early 20th centuries, particularly when Henry Ford successfully applied it to automobile manufacturing technology By pioneering the first assembly line system in car production, Ford significantly increased productivity, reduced costs, and decreased production time, revolutionizing the manufacturing process.
Figure 2-2 The first Assembly Line
The assembly line system has undergone significant expansion and evolution since its inception, emerging as a vital component of the manufacturing industry Over time, related technologies and processes have been developed and refined, including the integration of automation, robotics, and information technology, which have collectively transformed the manufacturing landscape.
The assembly line system has undergone significant evolution and is now widely applied across diverse industries, including automotive, electronics, machinery, appliances, food, and pharmaceutical sectors This system has consistently demonstrated its effectiveness in boosting productivity, reducing operational costs, and ensuring the delivery of high-quality products.
Figure 2-3 Modern Assembly Line with Robots
1 Machinery and equipment: They include machines and equipment used in the production process, such as machining tools, packaging machines, welding machines, cutting machines, quality inspection machines, and automated control devices
2 Conveyor systems are used to transport and transfer items from one production stage to another Conveyors can be made of rubber, plastic, or metal and controlled electronically or mechanically (Figure 2-4)
3 Robots and automation: Industrial robots perform automated tasks on the manufacturing line, such as assembly, welding, and product handling Automation also includes automatic control systems and sensors to regulate production ( Figure 2-5)
4 Control systems: Used to monitor and control operations within the manufacturing line Control systems may include computers, control software, sensors, and measuring devices to ensure accurate and efficient production processes
Figure 2-5 Fanuc robots in the industry
5 Transportation and storage systems: Includes transportation systems such as forklifts, cranes, pallet systems, and warehousing solutions to transport and store items during the production process
6 Energy systems: Ensures energy provision to the equipment and machinery in the manufacturing line This system includes electricity, compressed air, cooling systems, and other energy sources
7 Tools and instruments: Includes tools and instruments such as clamps, drills, cutting tools, screws, bolts, and other devices used in the production process
Each production stage in a manufacturing line consists of specific stages and activities to transform raw materials or components into the final product
1 Processing involves transforming and treating raw materials or components to create parts or sub-assemblies Processing methods may include cutting, grinding, turning, milling, welding, pressing, and CNC machining (Figure 2-6)
Figure 2-6 CNC machine of the Wood industry
2 Assembly: The assembly stage involves arranging, attaching, and fitting together parts to create the final product Assembly processes may include machinery, tools, and manual labor skills
3 Quality Inspection: The quality inspection stage ensures that the product meets quality standards and technical requirements Inspection methods may include dimension checking, strength testing, functional testing, and defect rate assessment
4 Packaging: Once the product is completed, the packaging stage is carried out to protect and prepare it for transportation Packaging may involve placing the product in boxes, bags, bubble wraps, or pallets
5 Transportation and Storage: This stage involves transporting the product from the manufacturing line to storage facilities or the end customer It may include using
CHAPTER 2: LITERATURE REVIEW vehicles such as forklifts, lifting equipment, and storage systems such as pallets or warehouses
6 Maintenance and Repair: This stage focuses on maintaining and repairing machinery and equipment in the manufacturing line It includes inspection, maintenance, and repair of components to ensure continuous operation and high performance
In today's industrial landscape, it's rare to find a manufacturing business that doesn't rely on a production line Manufacturing lines are ubiquitous across various industries, playing a crucial role in streamlining and automating tasks through the strategic use of machinery, and in many cases, even replacing human labor entirely in certain production stages, thereby significantly enhancing operational efficiency.
Table 2-1 illustrates the primary industries that benefit from modern manufacturing lines
Table 2-1 Applications of the Manufacturing Line
Vehicle assembly, welding and attaching components, quality testing and finishing products
Vehicle assembly, welding and attaching components, quality testing and electronic circuit fabrication, component placement, soldering and assembly, quality testing and control fishing products
Food production, packaging and bottling, sorting and agricultural packaging products, food processing, and packaging
Medicine production, packaging and bottling, quality testing and secure packaging processes
Mass production and assembly of household products and appliances
Weaving and garment production, fabric cutting and processing, assembly and finishing of garments, quality testing and packaging
Plastic and rubber processing, molding and casting of plastic components, assembly and quality testing of plastic and rubber products
Production of construction materials such as cement, bricks, wood, and steel, assembly and testing of building components, construction and finishing of building projects
Metal processing, welding and attaching components, fabrication and assembly of mechanical products, testing, and quality finishing
General Magician Robotic Arm
Industrial robots have transformed the manufacturing landscape by significantly enhancing efficiency, precision, and productivity across various industries Designed to execute repetitive tasks with high accuracy and reliability, these advanced machines have become a crucial component in modern industrial environments, driving innovation and streamlining processes.
The integration of industrial robots has revolutionized the manufacturing sector, yielding significant improvements in productivity, precision, and workplace safety As technological advancements continue to propel innovation, robots are poised to assume an even more critical role in streamlining production processes and driving the evolution of industrial automation.
Table 2-2 provides an overview of the formation and development of industrial robots from the 1950s to the present
Table 2-2 History of Industrial Robots
The first industrial robot invented by George Devol
Unimate, the first commercially sold industrial robot
Development of SCARA (Selective Compliance Assembly Robot Arm) robots
The emergence of collaborative robots (cobots) capable of working alongside humans
Proliferation of multi- purpose robots widely used in various industries
Mobile and autonomous navigation robots in industrial environments
The increasing popularity of collaborative robots, integrating artificial intelligence and machine learning
2.2.2 General of the 3-DOF Dobot Magician
The Dobot Magician robot arm is a cutting-edge robotic manipulator designed to cater to diverse applications in education, research, and industrial automation Equipped with versatile features and precise movements, this advanced robotic arm offers a wide range of capabilities, making it an ideal solution for various tasks that require accuracy and efficiency.
The Dobot Magician boasts a compact and sleek design, seamlessly integrating into various workspaces, as showcased in Figure 2-7 Its multiple articulated joints replicate human arm movements, enabling the robot to execute intricate tasks with precision and accuracy.
The Dobot Magician stands out for its exceptional programmability, allowing users to control it through various programming languages and software platforms, thereby catering to a wide range of expertise levels This flexibility in programming enables users to automate and customize specific tasks with ease, making it an ideal solution for diverse applications.
The Dobot Magician boasts an extensive range of end effectors and accessories, including grippers, suction cups, and laser engravers, significantly broadening its functional capabilities With its adaptable design, this robot arm can efficiently perform a diverse array of tasks, such as 3D printing, pick and place operations, writing, drawing, and light assembly tasks, making it a versatile tool for various applications.
Figure 2-8 Structure of the Dobot Magician
The Dobot Magician's intuitive interface and extensive documentation make it an ideal platform for educational purposes, allowing students and researchers to delve into the fundamentals of robotics and automation Its versatility also extends to industrial applications, where it boosts productivity and efficiency in diverse manufacturing processes, making it a valuable tool for enhancing operational workflows.
Figure 2-9 Dobot Magician’s application in sorting products
The Dobot Magician robot arm offers a powerful combination of versatility, precision, and programmability, making it a valuable tool for robotics enthusiasts, educators, and professionals in the automation field
2.2.2.1 Factory’s parameters of the Dobot Magician
Based on the user manual and technical specifications of the Dobot Magician, Table 2-3 shows its key parameters
Table 2-3 Parameters of the Dobot Magician
Rotation Range of Joint 1 (Base) 360 (Infinite)
Rotation Range of Joint 2 (Rear Arm) 0 180
Rotation Range of Joint 3 (Forearm) 0 180
Interface USB, Bluetooth, WiFi (optional)
Supported Software DobotStudio, Blockly, Python, C++,
2.2.2.2 Applications and developments of the Dobot Magician
The Dobot Magician is a versatile educational tool, extensively utilized in various learning environments to impart valuable knowledge in robotics, programming, and automation By offering a hands-on learning experience, this innovative device caters to students across all age groups and skill levels, providing a comprehensive and engaging way to grasp complex concepts.
- Research and Development: Researchers and scientists utilize the Dobot Magician to prototype, experiment, and develop robotic applications Its versatility and programmability make it suitable for various research projects
The Dobot Magician can be seamlessly integrated into manufacturing and assembly lines, revolutionizing industrial processes by automating repetitive tasks such as pick-and-place operations, soldering, and 3D printing By leveraging the Dobot Magician, businesses can significantly boost productivity, precision, and efficiency, ultimately streamlining their operations and enhancing overall performance.
The Dobot Magician's programmable interface and versatility in software and hardware compatibility make it an ideal choice for automation and IoT integration, allowing for seamless control and coordination of robotic processes within larger systems, and unlocking a wide range of possibilities for smart automation and IoT applications.
The Dobot Magician has become a go-to choice for hobbyists and makers, offering a versatile and user-friendly platform for small projects, DIY applications, and creative pursuits Its accessibility and ease of use make it an ideal tool for individuals with a passion for robotics and automation, allowing them to bring their innovative ideas to life.
The Dobot Magician robot continues to evolve with ongoing advancements, including regular firmware and software updates, expanded programming options, and enhanced precision and accuracy Additionally, the introduction of new accessories and attachments further extends the robot's functionality, allowing users to explore a wider range of applications and possibilities.
- The Dobot Magician has proven to be a versatile and adaptable robotic platform with diverse applications across education, research, manufacturing, automation, and personal projects.
PLC Siemens SIMATIC S7-1200
The Siemens SIMATIC S7-series is a renowned line of Programmable Logic Controllers (PLC) designed to cater to diverse industrial automation and process control needs As a widely adopted family of PLC, it offers a range of models tailored to specific application requirements, making it a versatile solution for various industries With its extensive portfolio, the SIMATIC S7-series has become a staple in the industrial automation sector, providing users with a reliable and efficient control system.
Table 2-4 History of the SIMATIC S7-series establishment
Compact size, integrated analog inputs/outputs
High-speed processing, modular design
Increased performance, large memory capacity
Integrated Ethernet, expanded communication options
Advanced motion control, enhanced security features
The Siemens SIMATIC S7-1200 is a versatile family of Programmable Logic Controllers (PLCs) designed for small to medium-sized automation projects, offering a compact and modular design ideal for space-constrained installations With a range of models featuring varying specifications and capabilities, the SIMATIC S7-1200 is widely used in industrial automation and control systems, catering to diverse application requirements.
Figure 2-10 CPU S7-1200 with the extended modules
The S7-1200 PLCs boast robust CPUs with rapid processing speeds, facilitating efficient control task execution and real-time data processing Equipped with diverse communication interfaces, including Ethernet, PROFINET, and serial protocols, these PLCs enable seamless integration with other devices and systems This integration capability allows for effortless data exchange and remote monitoring, streamlining control and monitoring operations.
The SIMATIC S7-1200 is a highly reliable and flexible automation solution, widely utilized in diverse industries including manufacturing, process control, and building automation Its compact design and robust performance make it an ideal choice for small to medium-sized automation projects Additionally, its extensive communication capabilities further enhance its versatility, contributing to its popularity in various sectors.
2.3.3 TIA Portal - Supportive software for Siemens SIMATIC S7-1200
Effective programming of the SIMATIC S7-1200 CPUs demands a combination of relevant knowledge and skills, as well as a thorough understanding of the hardware To successfully develop and simulate real-world applications on the PLC, programmers require powerful tools that support programming tasks The TIA Portal is a primary tool that plays a crucial role in this process, offering a user-friendly interface that facilitates efficient programming and simulation of the SIMATIC S7-1200 CPUs.
Figure 2-11 TIA Portal software interface
TIA Portal and SIMATIC STEP 7 are crucial software tools for programming and configuring SIMATIC S7-1200 CPUs, playing a vital role in automation tasks As a comprehensive engineering framework, TIA Portal offers a unified platform that integrates various automation tools and software components into a single environment, streamlining project management and workflows.
Figure 2-12 Insides a program of TIA Portal
The SIMATIC STEP 7 software, integrated within the TIA Portal, is specifically designed for programming SIMATIC S7-1200 CPUs, offering a user-friendly interface that supports multiple programming languages, including ladder diagram, function block diagram, and structured text This versatile tool enables programmers to develop complex control logic and configure PLCs according to their unique application requirements, streamlining the development process for efficient system integration.
TIA Portal and SIMATIC STEP 7 are comprehensive software solutions that offer essential features and tools for programming and simulating applications on SIMATIC S7-1200 CPUs, enabling efficient project execution By utilizing these tools, engineers can streamline the programming, testing, and commissioning of automation projects, thereby reducing development time and increasing productivity Additionally, TIA Portal and SIMATIC STEP 7 provide advanced functionalities, including system diagnostics and project documentation, while also facilitating seamless integration with other automation components, further enhancing overall project efficiency.
Proficiency in utilizing TIA Portal and SIMATIC STEP 7, combined with a deep understanding of hardware, is crucial for programmers to maximize the capabilities of SIMATIC S7-1200 CPUs By leveraging these tools, programmers can effectively design and implement real-world automation applications, thereby ensuring the reliable operation of industrial processes and unlocking their full potential.
AC Servo Motor Mitsubishi MR-J3
2.4.1 Structure of an AC Servo Motor
An AC servo motor is a specialized electric motor designed to deliver precise control over position, speed, and acceleration, making it an ideal choice for applications requiring high-precision motion control Commonly utilized in robotics, industrial automation, and CNC machines, AC servo motors play a crucial role in various motion control systems where accuracy and reliability are paramount.
Figure 2-13 Structure of the AC Servo motor
Based on Figure 2-13, the AC Servo Motor has the following main components:
1 Rotor: The rotor is the rotating part of the motor, connected to the shaft It experiences the force from the magnetic field and generates rotational motion
2 Stator: The stator is the stationary part of the motor, containing the winding coils arranged in a spiral pattern around the rotor When alternating current is controlled through the coils, it creates a magnetic field around the rotor
3 Encoders: The AC Servo Motor typically includes feedback encoders Encoders measure and provide information about the position and speed of the rotor to the controller This information adjusts the current flowing into the motor and ensures accuracy and responsiveness
4 Driver: The controller is the central control unit of the AC Servo Motor It receives control signals from the system and adjusts the current into the motor to meet the position, speed, and force requirements
5 Control System: The AC Servo Motor is typically controlled by control systems such as a PLC or specialized controllers The control system sends signals to the motor's controller to regulate its operation
2.4.2 Benefits of using AC Servo Motor
AC servo motors boast exceptional dynamic performance, rapid acceleration and deceleration, and precise positioning capabilities, making them ideal for applications demanding power and precision With the ability to deliver high torque at low speeds, these motors excel in various industrial and automation applications When paired with servo drives or motion controllers, AC servo motors enable precise motion control, ensuring smooth operation and high accuracy in a range of demanding environments.
If we compare AC versus DC Servo motors, it can be claimed that the AC ones are better in variant parameters, as shown in Table 2-5
Table 2-5 Comparison between AC and DC Servo motor
Features AC Servo Motor DC Servo Motor
Operating Principle Use AC power Use DC power
Flexibility Suitable for a wide range of diverse applications
Suitable for applications requiring high speed
Precision Capable of precise control
Capable of achieving high precision
Responsiveness Faster response time Slower response time
Reliability High reliability High reliability
Structure and Size Complex structure and larger size
Simple structure and smaller size
Cost Often more expensive Often less expensive
Widely used in industrial automation, robotics, CNC machines
Suitable for industrial automation, small to medium-sized machinery
2.4.3 General AC Servo Motor Mitsubishi MR-J3
The Mitsubishi MR-J3 AC Servo Motor is a high-performance motor designed and manufactured by Mitsubishi Electric, a leading company in industrial automation Equipped with advanced features and capabilities, the MR-J3 series is an ideal solution for various industrial applications, offering enhanced performance and reliability.
Figure 2-14 AC Servo motors Mitsubishi MR-J3 and drivers
The Mitsubishi MR-J3 AC Servo system relies on a dedicated driver, known as the MR-J3 amplifier, to efficiently control and operate the servo motor This driver plays a crucial role in providing the necessary power and control signals to the AC servo motor, facilitating precise motion control and positioning By converting input command signals into suitable voltage and current signals, the MR-J3 driver enables the motor to operate with the required torque and speed, ensuring optimal performance.
The AC servo motor driver is equipped with a range of features and capabilities designed to enhance motor performance, including built-in feedback mechanisms such as incremental or absolute encoders that provide precise position feedback to the control system, allowing for accurate control of the motor's position, velocity, and torque.
Table 2-6 shows the MR-J3 AC Servo Motor’s driver
Table 2-6 Basic parameters of the driver of MR-J3
Input Power Voltage AC 200-240V (single-phase or three-phase)
Output Power Voltage AC 200-240V (three-phase)
Feedback Mechanism Encoder (Absolute Encoder)
Communication Interfaces Ethernet, RS-485, Analog I/O
Protection Functions Overload, Overvoltage, Overcurrent,
Control Modes Position Control, Speed Control, Torque
Mounting Options Position Control, Speed Control, ToDIN rail or panel mount
2.4.4 Absolute Encoder of the Servo Motor
An Absolute Encoder is a high-precision position sensor utilized in diverse systems and applications, delivering accurate and absolute position data Unlike incremental encoders that monitor relative position changes, Absolute Encoders assign a distinct digital code to each position within a full revolution, providing unparalleled positional accuracy and reliability.
Figure 2-15 Structure of an Absolute Encoder
Based on Figure 2-15, it consists of a disc or a strip with multiple tracks and a read head The tracks are typically patterned with slots or optical marks corresponding to
CHAPTER 2: LITERATURE REVIEW specific positions The read head contains sensors or detectors that detect the patterns on the tracks and convert them into electrical signals
An absolute encoder provides a unique binary code or digital value that corresponds to its precise position, allowing for accurate tracking and recall of its location Notably, this value remains unchanged even when power is interrupted, and upon restoration, the encoder resumes its exact position, ensuring seamless operation and minimizing errors.
Absolute encoders are widely utilized in high-precision applications, including robotics, CNC machines, and industrial automation, where accurate positioning and feedback are crucial These devices offer exceptional resolution, repeatability, and resistance to power interruptions, making them ideal for demanding environments By providing precise feedback, absolute encoders enable precise control and positioning in servo systems and other applications requiring high accuracy.
Design and simulation software
Figure 2-16 The brand logo of SolidWorks
SolidWorks (with logo as Figure 2-16 shows) is a leading 3D design software in the industrial and engineering sectors It provides a powerful, flexible graphic design environment for accurate and detailed 3D models
SolidWorks empowers users to create comprehensive designs, encompassing technical drawings, intricate 3D models, and complex assemblies, as exemplified in Figure 2-17 By leveraging the software's robust design tools, users can engage in 3D modeling, motion simulation, and mechanical analysis, ultimately facilitating the creation of detailed technical drawings.
Figure 2-18 The brand logo of MATLAB
MATLAB, short for MATrix LABoratory, is a widely-used computational and programming environment in science, engineering, and mathematics, developed by MathWorks As a powerful platform, MATLAB offers a comprehensive programming language and robust tools for numerical computation, data analysis, and application development, making it an essential resource for various fields.
With MATLAB, the way of researching and development becomes more accessible by the simple interface, such as in Figure 2-19, due to its support in:
Simscape is a multidomain physical modeling and simulation tool integrated within MATLAB/Simulink, enabling the modeling and simulation of complex physical systems across various engineering domains By leveraging fundamental physical principles, Simscape allows engineers and scientists to accurately describe the behavior of physical components and systems, spanning mechanical, electrical, thermal, and hydraulic systems.
2.5.3 TIA Portal and SCADA Interface
The TIA Portal, developed by Siemens, is a comprehensive software platform designed for programming and configuring automation products, offering an integrated engineering framework This framework enables users to efficiently design, configure, program, and diagnose automation systems, streamlining the engineering process.
Figure 2-21 The brand logo of Siemens TIA Portal
TIA Portal streamlines engineering workflows by providing a comprehensive software package that houses all necessary tools and functions By supporting a wide range of Siemens automation devices, including PLCs, HMIs, and drives, the platform enables seamless integration and communication between various system components, facilitating efficient automation system design and operation.
In the TIA Portal, SCADA functionality is seamlessly integrated through the WinCC system, a robust visualization and process control software This powerful tool enables users to monitor, control, and optimize industrial processes in real-time, enhancing overall efficiency and productivity A practical example of this functionality is demonstrated in Figure 2-22, where a mixing system is effectively monitored via a SCADA interface, showcasing the software's capabilities in real-world applications.
Former Filling and Capping system projects
2.6.1.1 "THIẾT KẾ MÔ HÌNH GIÁM SÁT VÀ ĐIỀU KHIỂN HỆ THỐNG CHIẾT
RÓT VÀ ĐÓNG NẮP SỬ DỤNG PLC S7-1200" of NGÔ NHỰT HÀO
A filling and capping system project made by K15 students is shown in Figure 2-
23 Their result and conclusion are written in Vietnamese in Figure 2-24
The system boasts an impressive performance rate of 60 bottles per hour, although it is unclear whether it can handle a continuous stream of bottles or process them individually To optimize efficiency, a step motor is utilized to power the rotary disc, allowing it to manage a maximum of three bottles at a time.
Comment: This project has good idea but the hardware they made is not optimizing enough We have built an update in many details of this project ourselves.
Figure 2-23 Hao and Hiep project's model
Figure 2-24 Conclusion of Hao, Hiep's project
2.6.1.2 "MÔ HÌNH CHIẾT RÓT ĐÓNG NẮP CHAI TỰ ĐỘNG PHỤC VỤ CHO
DẠY HỌC" of VÕ THANH PHÚC 11911018 AND NGUYÊN ĐÌNH NHÃ TRIẾT 11911025 [4]
A project from K11 students is represented in Figure 2-25 Their conclusion is written in Figure 2-26 Performance is not calculated However, there is a comment,
Although the bottle execution process is currently separate, resulting in lower speed and accuracy, the mechanical and electrical designs of the system are acceptable, as outlined in sections 7.1.1 and 7.1.2, enabling operational functionality Notably, a PLC S7-200 was utilized in this project, as the S7-1200 PLC model was not widely popular at the time of implementation.
Figure 2-25 Phuc and Triet's project model
Figure 2-26 Conclusion of Phuc and Triet
Notable for its well-designed wiring system, this project showcases a significant hardware upgrade tailored to its innovative concept A key differentiator is the use of an AC Servo motor, which, although more challenging to control than a DC motor, has been successfully integrated into the system.
2.6.2 Real industrial Filling and Capping system
A typical industrial manufacturing line, as depicted in Figure 2-27, incorporates a washing station, illustrated in Figure 2-29, to ensure the thorough cleaning of bottles, particularly those intended for holding medicine or beverages, which enter the line in large quantities, as seen in Figure 2-28.
CHAPTER 2: LITERATURE REVIEW clean Performance is from 1000 to 36000 bottles per hour, depending on the size of bottles and types of liquid.
Figure 2-27 Tofflon 120VPM of Manufacturing Line
Figure 2-29 Washing station of Tofflon
2.6.2.2 Marya Filling and Capping system
Marya is another prominent brand of filling and capping systems, with a manufacturing line fully enclosed in metal for optimal protection As shown in Figure 2-31, the filling mechanism allows for continuous movement of bottles without interruption, ensuring a seamless and efficient process.
The machine boasts significantly higher performance, with a production capacity ranging from 1,000 to 36,000 bottles per minute Notably, it achieves a filling accuracy of less than 1% tailored to specific drug characteristics, ensuring precision and reliability Furthermore, the capping qualified rate exceeds 99.9%, underscoring its exceptional efficiency Additionally, the system maintains a constant temperature throughout the line, guaranteeing optimal operating conditions.
MATHEMATICAL MODEL & HARDWARE STRUCTURE
Kinematics calculations of the Magician Robot
3.1.1 D-H table consideration and Forward Kinematics
Forward kinematics is a fundamental technique in robotics that calculates the position and orientation of an end-effector based on known joint angles and link lengths By determining the transformation matrix or equations, this method describes the movement of the end-effector relative to a fixed reference point or coordinate system, enabling precise control and navigation of robotic arms and mechanisms.
Based on the actual model of Dobot Magician sketched in Figure 3-1, a diagram has been created to summarize the calculated parameters, as the figure bellow shows
Figure 3-1 Magician Robot Arm model
- x, y and z are the axes of the coordinate system
- d1 is the distance from x 0 to x 1
- “a” letters are the link lengths
From the D-H table, five transformation matrices are extracted as follows:
After calculating the five matrices above, we can derive the transformation matrix of the End-effector as follows:
Finally, we got the Forward Kinematics of the Magician Robot
Inverse Kinematics is the opposite of Forward Kinematics It is instrumental in controlling the movement of the Magician Robot arm
Having established the desired position and orientation of the end-effector, the next step is to calculate the joint angles required to achieve the specified pose This involves the system computing the optimal joint angles necessary to reach the desired position By determining these angles, the system can effectively guide the robotic arm to its intended pose.
Figure 3-2 Magician Robot Arm modeling by angles
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Apply the algebraic method to the sketch of joint angles above (Figure 3-2) We start calculating each joint
When 2 + 3 + 4 = 0 the last link CD parallels to the ground The statement bellow shows how we prove it
To establish the coordinate system for the Magician Robot, we assign points A, B, and C to its joints θ2, θ3, and θ4, respectively From the origin point O, a line g is drawn parallel to the ground, serving as a reference Similarly, from point A, lines x, b, and a are drawn parallel to Og, BC, and CD, respectively, creating a comprehensive coordinate system for the robot.
Based on those parallel lines, we obtain two equal angles:
Hence, bAa = eCD and bAB = CBE bAB = bAa + aAx + xAB
Hence, and Ax are the same line
Therefore, when 2 + 3 + 4 = 0 we get CD
(or CD is set horizontally)
In Section 3.1.1, we have calculated the transformation matrix of the End-effector:
This step will figure out the position of the End-effector Take the matrix above consequently:
Og → CD Og at the same line
From (2,4) (row 2, column 4) of the matrix (3.13) and matrix (3.15), we have: p y c 1 − p x s 1 = −a 6 (3.16)
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE p 2 x + p 2 y a 6 p 2 x + p 2 y p 2 x + p 2 y
= atan2( p , p ) + arcsin (Choose this solution) (3.18)
From (1,4) and (3,4) of the matrix (3.13) and matrix (3.15), we have:
In conclusion, we claimed the set of Inverse Kinematics parameters:
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Calculating a robot's velocity is a critical aspect of robot dynamics, involving the determination of the rate of change of its position over time This calculation is essential for understanding and controlling the robot's motion, enabling precise movement and navigation By analyzing the robot's velocity, developers can gain valuable insights into its performance and make necessary adjustments to optimize its functionality.
Figure 3-3 Parameters of a 2-DOF robotic arm
In this application, velocity control along Z-axis is needed in some phases Hence, only z is needed, the calculation is conducted only 2
Link transformations: on and 3 1 is ignored
0 0 0 1 From the matrix T, the matrix R inversed can be calculated as:
Hence, we consider the following:
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
In this project, the end manipulator only moves along the Z-axis in velocity control mode 1 4 x is set to zero
Design in SolidWorks
3.2.1 Overview of the 3D model of the entire system
Designing the entire system requires a tool that is highly reliable and capable of connecting the components Therefore, SolidWorks 2022 is an excellent choice for seamlessly completing and integrating each stage
Our team has developed a cutting-edge hardware system by drawing inspiration from previous models, addressing their limitations, and tailoring the design to meet specific working conditions Key improvements have been made to both the assembly line and the robot, resulting in more flexible control By integrating these enhancements into a unified design, we have created a cohesive system that operates continuously, streamlining processes and boosting efficiency.
Once the drawings are completed, the images below depict an overview of the system used in the project
Figure 3-4 represents the top view of the entire system
Figure 3-4 Top view of the system
Figure 3-5 illustrates the right-side view of the system
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-5 Right-side view of the system
Figure 3-6 shows the front view of the system
Figure 3-6 Front view of the system
3.2.2 SolidWorks design of the mainly used components
3.2.2.1 Design of the AC Servo Mitsubishi MR-J3 motors
Table 3-1 illustrates detailed drawings and real connections of the AC Servo motors used in the system
Table 3-1 3D sketches and real model of AC Servo motors
Joint 3 of the robot Rotary disk
Motor model HF-MP23 HF-KP13 HF-KP13 HF-KP238
3.2.2.2 Framework of the devices and components in the system
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
3.2.3 Design of the Filling and Capping system
This section provides an in-depth examination of the detailed designs for each component, ultimately creating a comprehensive system for filling, sealing, and capping bottles The system's design is a crucial aspect of its functionality, and a key component, the Magician Robotic Arm, will be explored in further detail in Section 3.2.3, offering a closer look at its design specifications and capabilities.
Figure 3-10 presents an overview of the motors’ positions in the system Each component represents a stage in the production line
Figure 3-10 Part of the system and motors position
The rotary disk, as depicted in Figure 3-11, is strategically positioned as indicated by arrow number 1 in Figure 3-10 This crucial component plays a key role in the water bottling process, primarily responsible for transporting water bottles from the input conveyor, located at the position marked by arrow number 3, through the filling and capping stages.
Once the bottles are filled, they proceed to the output conveyor, marked as arrow number 2, where they are collected by the Magician Robot, situated at arrow number 4 The robot then carefully places the filled bottles in a designated storage area, ensuring efficient and organized product handling.
The motors utilized for the two conveyors are DC motors, as depicted in Figure 3-12, whereas the motors for the rotary table and the robot have been previously discussed in earlier sections, providing a comprehensive overview of the system's components.
Figure 3-12 Input conveyor (left-side) and output conveyor (right-side)
Following the filling process, the bottles proceed to the capping station via a rotary table At this stage, a cap is released onto the bottle and secured in place using a roller system positioned next to a custom 3D-printed component, as clearly illustrated in Figure 3-14.
Figure 3-13 Cap of the bottle
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-14 Caps supplier (left-side) and roller system (right-side)
To complete the product, the bottles undergo an additional step where the lids are tightly secured onto the bottle neck This crucial task is accomplished by a pneumatic cylinder-based mechanical module, which ensures the lids are properly sealed before the bottles proceed to the output conveyor The design and construction of the capping mechanism are illustrated in Figure 3-15, showcasing the precision engineering involved in this process.
3.2.3 Design of the Magician Robotic Arm
The design of the Magician Robotic Arm is a critical component of the project, warranting a dedicated approach As such, the kinematics and 3D design of the robot will be explored in separate sections, with the latter focusing on its development using SolidWorks.
A robot's base is a critical component, serving as a stable and sturdy platform that supports the robot's overall functionality To effectively perform its intended tasks, the base must be designed with load-bearing capacity and anti-slip properties in mind, ensuring the robot maintains its position and stability throughout the process Furthermore, the base also facilitates seamless connections and interfaces, enabling the robot to integrate with other devices within the system, thereby enhancing its operational efficiency.
Figure 3-16 Position of the Magician Robotic Arm
The strategic placement of the robot within the overall project system, as illustrated in Figure 3-16, offers enhanced convenience for operators to manipulate and handle products, thanks to the robot base's flexible rotation and wide range of motion.
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
The design showcased in Figure 3-17 enables seamless integration into the system through the strategic connection of aluminum profiles, providing a robust foundation for the robot and minimizing deviations during operation By leveraging the sturdy connection of aluminum profiles, the system achieves enhanced stability, which in turn boosts overall work efficiency and ensures optimal performance.
3.2.3.2 Joint 2 & Joint 3 designs of the Robot
The Magician robot features a distinctive arrangement of Joint 2 and Joint 3, characterized by the symmetrical placement of the two motors controlling these joints This unique configuration forms a parallelogram-based mechanism, as illustrated in Figure 3-18, showcasing an innovative design approach in robotics.
Figure 3-18 Magician Joint 2 & Joint 3 design
This design makes the construction process more flexible Using assembled aluminum profiles allows for easy disassembly and reassembly, unlike 3D-printed methods, which can make motor and pulley assembly challenging
The robot arm's movement is driven by AC servo motors, which rotate pulleys securely attached to the arm sections via belts, enabling precise control and smooth operation This design approach is particularly well-suited for CNC cutting applications, where accuracy and reliability are paramount By utilizing this design, the robot arm achieves a more robust and visually appealing structure compared to 3D printed alternatives, which can be prone to breakage and workflow disruptions.
3.2.3.3 End manipulator design of the Robot
Figure 3-19 End manipulator design of the Robot
The incorporation of a pneumatic gripper mechanism as the gripping device for the robot offers enhanced convenience in grasping the bottle's mouth Utilizing compressed air, this device provides a reliable and efficient method for gripping and releasing objects, ensuring a secure hold and easy operation With its precise control and adjustable gripping force, the pneumatic gripper mechanism seamlessly integrates into the overall system, making it an ideal choice for robotic applications.
General structure of the Magician Robot Arm
3.3.1 Notations about the design of the Magician Robot Arm
Notable for its unique design, the Magician robotic arm boasts a distinctive feature - its end manipulator consistently maintains a horizontal direction, despite being a 3-DOF robotic arm A diagram illustrating this primary characteristic is provided below The Inverse Kinematics calculation reveals that the red line DB is a 3, while the green line EBC is a 4, with both lines forming a single rigid body.
Figure 3-20 Geometric model of Magician Robot Arm
From Figure 3-20, we can see two parallelograms GABH and BFCI From these
Since GA is fixed, the direction of HB is also determined, resulting in a fixed triangular HBF Consequently, the directions of BF and CI are fixed as well Furthermore, with CIK being a fixed triangular, the direction of CK relative to the ground is also fixed, particularly when CK lies horizontally.
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-21 Magician Robot Arm model by SolidWorks
The rigid body ECB is actuated by the motor-controlled body AD, as depicted in SolidWorks images Ideally, the ECB angle is 180°, but this design would cause the body AB to collide with the pulley belt Consequently, the ECB angle is set to 150°, which, although creating another issue, is acceptable within the robotic arm's operating region However, this setup poses a problem when the end manipulator approaches the original point A, causing the parallelogram ADEB to disappear and AD and EB to become co-linear, potentially leading to the body EBC falling.
In the context of Inverse Kinematics, the value of θ2 directly corresponds to the angle of motor 2 or actuator 2 (ac2), providing a straightforward relationship However, θ3 does not solely represent the angle of ac3, as its value is influenced by both ac2 and ac3, indicating a more complex interdependency between these two actuators.
− 3 = bBC = EBC − EBb = 150 − EBb (3.53) Hence,
→ ac 3 = 2 + 3 +150 (3.54) For velocity control mode: ac 3 = 2 + 3 (3.55) function y = fcn(px,py,pz) a2B; d1.1; a31; a41; a50.44; a6; theta1=atan2(py,px)+asin(a6/sqrt(px^2+py^2));
K1=px*cos(theta1)+py*sin(theta1)-a2-a5;
K2=pz-d1; theta3=-acos((K1^2+K2^2-a4^2-a3^2)/(2*a3*a4)); theta2_y=(K2*(a4*cos(theta3)+a3)-a4*sin(theta3)*K1)/((a4*sin(theta3))^2+
The forward kinematics of a robotic arm can be calculated using a set of equations that determine the position of the end effector The equations involve the use of trigonometric functions, such as cosine, sine, and arctangent, to calculate the joint angles and position coordinates Specifically, the equations for calculating the joint angles include theta2_x and theta2_y, which are used to determine the angle theta2 The position coordinates of the end effector, represented by px, py, and pz, are calculated using a combination of the joint angles and the arm's link lengths, denoted by a2, a3, a4, a5, and a6.
MATLAB Simulation
The Simscape-multibody link is utilized to simulate kinematic motion in position control mode, as illustrated in Figure 3-22 This simulation involves a series of conversions, starting with the "DH angles to angles of actuators" block, which translates kinematic angles into actuator angles, as described in Section 3.3 A subsequent conversion is then performed by the "angles of actuators to angles of Simulink" block, which adjusts the actuator angles to match the actual angles used in Simulink, compensating for discrepancies in position and direction that arise during the creation of the Simscape-multibody file.
Code for the Inverse Kinematics:
Code for the Forward Kinematics:
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-22 Inverse Kinematics block diagram
In position control mode, the end manipulator is moved along the z-axis as depicted in Figure 3-23 The function fcn(xdot, zdot, theta2, theta3) calculates the angular velocities theta2dot and theta3dot based on the given inputs This calculation involves the lengths l11 and l21, and utilizes the equations theta2dot=(cos(theta2+theta3)/(l1*sin(theta3)))*xdot+(sin(theta2+theta3), demonstrating the relationship between the end manipulator's movement and the angular velocities of the robotic arm.
/(l1*sin(theta3)))*zdot; theta3dot=-(l2*cos(theta2+theta3)+l1*cos(theta2))/(l1*l2*sin(theta3))*xdot+zdot*(- l2*sin(theta2+theta3)-l1*sin(theta2))/(l1*l2*sin(theta3));
Figure 3-24 The result from the Simscape-multibody link
The robotic arm's movement is demonstrated in Figure 3-23, which displays the result of moving the end manipulator along the z-axis Additionally, Figure 3-24 showcases the Simscape multibody link conversion of the robotic arm from Solidworks, with unnecessary bodies eliminated to optimize processing efficiency.
3.4.2 Simulation of the Velocity Control
The block diagram for Velocity Control using the Jacobian matrix is represented in Figure 3-25 The program of the Jacobian matrix is shown below
Program for the Velocity Control:
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-25 Velocity Control block diagram
Figure 3-26 Moving the end-manipulator along the z-axis in velocity control mode
Figure 3-26 shows the result of moving the end manipulator along the z-axis using the Jacobian matrix Position pz is a straight line.
List of devices
3.5.1 Mechanical parts of the Filling and Capping system
Figure 3-27 Filling and capping system
For the purpose of this project, only essential mechanical components are listed, excluding numerous small materials like tacks, screws, nuts, washers, and corner brackets due to their sheer quantity and minimal significance in the overall scope.
The input conveyor is where the bottles are transported initially before proceeding to the next steps Figure 3-28 shows the actual construction of the input conveyor
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-28 Model of the input conveyor
Additionally, Table 3-4 lists the hardware components of the conveyor
Table 3-4 List of the input conveyor parts
Figure 3-29 Model of the output conveyor
The output conveyor plays a crucial role in the bottling process, serving as the final stage where filled and capped bottles are transported for storage in a warehouse As shown in Figure 3-29, this conveyor system efficiently moves the bottles to their designated storage area, where they are collected by a robot Various types of equipment are utilized in the output conveyor, including those listed in Table 3-5, to ensure seamless and efficient operation.
Table 3-5 List of the output conveyor hardware
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
In addition to the aforementioned devices, the system also comprises other crucial components, including a chain drive system that facilitates the movement of the DC motor-driven conveyor belt, as well as Mica sheets that provide a secure mounting platform for the bottle detection sensors, ensuring seamless functionality and optimal performance.
The rotary disk is an essential part of the system Besides facilitating bottle transportation, it provides convenience for installing and assembling other components
Figure 3-30 shows a model of the rotating platform
Figure 3-30 Model of the rotary disk
Table 3-6 lists the equipment used in the rotary disk
Table 3-6 List of the rotary disk hardware
This system is separated into three parts Figure 3-31 illustrates the arrangement of the water pumping devices into the bottles
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-31 Model of the water supplier
The caps supplier placement is illustrated in Figure 3-32, showcasing the strategic positioning of key components Notably, the slide bar for the cap is situated on the left-hand side, while the fixed roller, responsible for inserting the lid into the bottle's neck, is located on the right-hand side, as meticulously designed in SolidWorks.
Our team may make slight modifications to the mechanical components, deviating from the original design drawings by adding or adjusting aluminum extrusions or utilizing available bars of varying sizes, in order to optimize costs without compromising the structure's sturdiness.
Figure 3-32 Model of caps suppliers
The bottle cap closing mechanism is designed for secure and efficient closure, achieved by integrating a pneumatic cylinder into the aluminum profile A key feature of this mechanism is the inclusion of a red cushion pad, strategically placed underneath to provide an additional layer of security and ensure a tight seal.
Figure 3-33 Model of the cap closing mechanism
Below is Table 3-7, presenting a list of the devices mentioned in Figure 3-32 and Figure 3-33:
Table 3-7 List of the Filling and Capping system hardware
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
3.5.2 Mechanical parts of Magician Robotic Arm
In the past, the team experimented with 3D printing the components for the second and third joints of the Magician Robotic Arm, as shown in Figure 3-34
However, this method proved to be sub-optimal during the construction process, as it posed difficulties in mounting the motors onto the model
Figure 3-34 Joint 2 and Joint 3 were constructed by the 3D printing method
Therefore, it was necessary to redesign that part The image below illustrates the placement and overall configuration of the 3-DOF Magician Robot system, as shown in Figure 3-35
Figure 3-35 The final design of the Magician Robotic Arm
Table 3-8 lists the hardware used to construct the Magician Robotic Arm
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Table 3-8 List of the Magician Robotic Arm hardware
Base of Joint 2 and Joint 3 1 3D printing
Gripper cylinder and its base
- Article number 6ES7214-1AG40-0XB0 (Figure 3-36)
- Description: 14 DI 24 V DC; 10 DO 24 V DC; 2 AI 0-10 V DC
- Power supply: DC 20.4-28.8V DC, Program/data memory 100 KB
- Max output frequency: 4 outputs with 100 kHz, 6 outputs with 20 kHz
Figure 3-36 1214C DC/DC/DC PLC
- Article number: 6ES7 222-1BD30-0XB0 (Figure 3-37)
- Description: digital output SB 1222, 4 DQ, 24 V DC 200 kHz
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
- Article number: 6ES7223-1PH32-0XB0 (Figure 3-38)
Configuration of 2 types of drivers is shown in Table 3-9 Figure 3-39 represents a low-power driver without a fan
Supply Voltage 3-phase or 1-phase 200 to
3-phase or 1-phase 200 to 230VAC, 50/60Hz
Rated voltage output 3-phase 170VAC 3-phase 170VAC
- Article number: E3F-DS30C4 NPN (Figure 3-40)
- Article number: ZS RE81 (Figure 3-41)
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
- The maximum length of pipe: 1m
- Pulse frequency per L/min: 98Hz
- A 24 VDC (Figure 3-44) and a 12 VDC (Figure 3-45) with 2A maximum output current are chosen
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
- Article number MFL-B2DN-18NPA-R1 (Figure 3-48)
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Name Quantity Current consumption per unit (A)
Name Quantity Current consumption per unit (A)
Name Quantity Current consumption per unit (A)
From Table 3-10, Table 3-11, and Table 3-12, we compare the current consumption of devices and max current of source and contactor:
- Max current of 24VDC source = 2 A > 1.5 A
- Max current of 12VDC source = 5 A > 0.6 A
- Max current of 220 VAC contactor = 20A > 5.98 A
From those comparisons, this system is safe from overload.
Wiring diagram
The MR-J3 Ac servo driver is capable of receiving pulse train signals through two distinct methods: open collector and differential line driver systems Notably, open collector systems can accommodate 24 V pulse trains, whereas differential line driver systems are limited to 5 V Typically, PLC outputs are connected to open collector systems, but the MR-J3 servo's LED configuration in Figure 3-51 necessitates compatibility with sinking output, which is not compatible with the sourcing outputs of S7 1200 devices Consequently, differential line driver systems are required, and 2200 Ω resistors are utilized to reduce current and safeguard the LEDs, as illustrated in Figures 3-53 and 3-54.
The connection between drivers and PLC is illustrated in Figures 3-53, 3-54, 3-55, 3-56, and an additional reference Notably, the absolute encoder of the rotary disc is not utilized due to the motor's brake and low accuracy requirements The I/O interface of the driver separates other inputs from the differential line driver system, and a sinking configuration is employed to connect with the sourcing outputs of the PLC Specifically, pins 17, 18, 22, 23, and 25 in Figure 3-54 are designated for reading the absolute encoder and setting the robot's home position, while Figure 5 provides a comprehensive wiring diagram for sensors and other actuators.
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-52 Differential line driver system
Figure 3-53 Wiring diagram for Joint 1 of the robotic arm
Figure 3-54 Wiring diagram for Joint 2 of the robotic arm
Figure 3-55 Wiring diagram for Joint 3 of the robotic arm
CHAPTER 3: MATHEMATICAL MODEL & HARDWARE STRUCTURE
Figure 3-56 Wiring diagram for rotary disk
Figure 3-57 Wiring diagram of other actuators and sensors
SOFTWARE STRUCTURE
Mitsubishi AC Servo MR-J3 parameters setting [6]
In this project, the parameters listed below are different from default values Other parameters which are not listed remain at default values
The control mode parameter plays a crucial role in determining the drive's operation, allowing users to select the desired mode Notably, when utilizing an absolute encoder through digital input (DI) or communication, it is essential to set this parameter to zero to ensure accurate and reliable functionality.
- 1: Position control mode and speed control mode
- 3: Speed control mode and torque control mode
- 5: Torque control mode and position control mode
• PA02 - Regenerative option (Default value: 000h)
In applications where the motor load is not excessively high, internal regenerative resistors can be utilized to dissipate excess energy generated during overloading or braking However, for high-power motors, external regenerative resistors are recommended to safely manage excess energy and prevent potential damage.
- A regenerative resistor is not used for a servo amplifier of 100W
- A built-in regenerative resistor is used for a servo amplifier of 200 to 7kW
- Supplied regenerative resistors or regenerative option is used with the servo amplifier of 11k to 22kW
- For a drive unit of 30kW or more, select a regenerative option by the converter unit
• PA03 - Absolute position detection system
- 1: Used in the absolute position detection system ABS transfer by DI0
- 2: Used in the absolute position detection system ABS transfer by communication
The PA03 parameter is utilized to retrieve data from Absolute Encoders and Counters, necessitating the installation of an external battery behind the driver when set to 1 or 2 In this particular project, PA03 is set to 1, rather than 2, due to the use of a Siemens PLC to control a Mitsubishi AC Servo, as the communication protocols between the two devices are incompatible By leveraging inputs and outputs for data reading, the need for an external communication device is eliminated, resulting in significantly lower costs; however, if a Mitsubishi PLC is employed, an alternative approach is recommended.
CHAPTER 4: SOFTWARE STRUCTURE transferring signals through communication because there are fewer wires in the system
• PA05 - Number of command input pulses
The parameter PA05 specifies the number of input pulses per revolution, as illustrated in Figure 4-1 By default, setting PA05 to "0" enables the electronic gear, which is defined by parameters PA06 and PA07 Conversely, assigning any value other than "0" to PA05 disables the electronic gear, thereby altering the command pulse train processing as depicted in Figure 4-1.
Figure 4-1 The process of executing command pulse train
• PA06 - Electronic gear numerator (CMX)
• PA07 - Electronic gear denominator (CDV)
When the number of pulses per revolution exceeds 50000 or fractional, these parameters are preferred over PA05 In general, the load movement of one pulse follows the equation:
• PA08 - Auto tuning mode (Default value: 0001h)
In this project's scope, we only control the robot through kinematics without designing a controller Therefore, every parameter related to control is set at fully auto-tuning mode 0001h
• PA13 - Selection of command pulse input form
This type of drive is versatile, supporting three forms of pulse-train and both negative and positive logic As outlined in Table 4-1, each form has its distinct characteristics, but the signed pulse train stands out as the most widely used due to its efficiency, requiring only one output to operate at high frequencies.
Table 4-1 Command pulse input form
Setting Pulse train form Description
Forward rotation pulse train Reverse rotation pulse train (Negative logic)
A-phase pulse train B-phase pulse train (Negative logic)
Forward rotation pulse train Reverse rotation pulse train (Positive logic)
A-phase pulse train B-phase pulse train (Positive logic)
The value of the parameters of each drive is set as Table 4-2 Parameters that are not listed remain default
Table 4-2 Setting parameters for each drive
Joint 1 Joint 2 Joint 3 Rotary disk
Motion control by Siemens Simatic S7-1200 V6.0 [7]
Motion control is an advanced technique of S7-1200 PLC Siemens A high seed pulse output cards are used to generate a pulse train for the servo or stepper drive
The drive receives pulses from PLC as the input signal These signals are subsequently used to control the motor
4.2.1 Signal types of the Pulse Train Output
In applications where a motor only needs to rotate in one direction, a single output is sufficient However, for projects that require bidirectional motor rotation, such as this one, two outputs are necessary to control each motor, enabling both clockwise and counterclockwise rotation.
1200 PLC in general, five types of output signals of the PTO (pulse train output) are listed in Table 4-3
Table 4-3 Signal types and number of outputs required
Signal type Number of pulse generator outputs
Pulse A and direction B (direction output disabled) 1
Clock up A and clock down B 2
The most commonly used PTO configuration features two distinct outputs, with one generating pulses to regulate distance and the other controlling direction A brief delay is incorporated after altering the direction to guarantee the drive accurately receives the command, ensuring seamless functionality.
Figure 4-2 PTO – pulse (A) and direction (B)
In this configuration, one output generates the signal for position direction The other is used to generate the signal for the negative direction
• PTO clock up A and clock down B
In this configuration, one output generates the signal for position direction The other is used to generate the signal for the negative direction (Figure 4-3)
Figure 4-3 PTO clock up A and clock down B
• PTO – A/B phase-shifted (as of V4)
The positive edge of one output in each case is evaluated for this type of signal
If signal A leads signal B 90, the motor will rotate positively If signal B leads signal A 90, the motor will rotate in the negative direction
The A/B phase-shifted configuration is elevated to an advanced form, taking into account both the positive and negative edges of the dual outputs, resulting in a total of four edges per period Consequently, this setup leads to a significant reduction in pulse frequency at the output, specifically to a quarter, as illustrated in Figure 4-4.
Figure 4-4 PTO – A/B phase-shifted and (A/B phase-shifted - quadruple)
4.2.2 Assigning the outputs of PLC to PTO
Table 4-4 Maximum frequency of outputs
1214C CPU DC/DC/DC From Q0.0 to Q0.3 100 kHz
6ES7 222-1BD30-0XB0 From 4.0 to Q4.3 200 kHz
The Siemens PLC S7-1200 features two primary output types: transistor output and relay output, each with distinct functionalities Notably, relay outputs are not designed for pulse generation, limiting their application in certain scenarios In contrast, Pulse Train Output (PTO) can be sourced exclusively from the main CPU or signal board, offering a more versatile option Additionally, the maximum frequency parameters for the equipment are outlined in Table 4-4, providing essential reference information for configuration and operation.
Outputs of the SM board cannot be used for PTO even if they are transistor outputs
The PTO configuration, consisting of pulse (A) and direction (B), is uniformly applied to all four motors in this project This setup offers a significant advantage, as it requires only one output to generate high-frequency pulses, while the direction-controlling pin operates at a lower frequency.
Figure 4-5 Create motion control block
Figure 4-6 Setting configuration for motion control
The project's program utilizes all four motion control blocks of the PLC, with assignments outlined in Table 4-5, which evaluates the load movement as discussed in Chapter 3 The process of setting parameters for these motion control blocks is visually represented in Figure 4-5 and Figure 4-6, providing a clear illustration of the configuration steps.
Table 4-5 Configuration of motion control blocks
4.2.3 Motion control instructions (From motion control manual)
Information in this section is taken from the motion control V6.0 manual However, the tables below have been changed to keep the necessary information
The Motion Control instruction "MC_Power" from Table 4-6 turns an axis on or off
Axis INPUT TO_Axis Axis technology object
All current jobs are interrupted by the "StopMode" configured The axis is stopped and disabled
Enable positioning axis position- controlled
If a request to disable the axis is pending, the axis brakes at the configured emergency deceleration
The axis is disabled after reaching a standstill
The "MC_Home" motion control instruction is crucial for aligning axis coordinates with the actual physical drive position, enabling precise absolute positioning This process, known as homing, is essential for accurate axis positioning and can be executed in various types.
Parameter Declarati on Datatype Description
Axis INPUT TO_Axis Axis technology object
Execute INPUT BOOL Start the command with a positive edge
The absolute position of the axis after completion of the homing operation
Direct homing (absolute) The new axis position is the position value of parameter
Done OUTPUT BOOL TRUE Command completed
The "MC_MoveAbsolute" Motion Control instruction starts an axis positioning motion to move it to an absolute position shown in Table 4-8
Axis INPUT TO_Axis Axis technology object
Execute INPUT BOOL Start the command with a positive edge
Absolute target position Limit values:
The velocity of the axis: This velocity is not always reached because of the configured acceleration and deceleration and the target position to be approached
The absolute target position reached
Busy OUTPUT BOOL TRUE The command is being executed
The "MC_MoveRelative" Motion Control instruction starts a positioning motion relative to the start position shown in Table 4-9
Axis INPUT TO_Axis Axis technology object
Execute INPUT BOOL Start the command with a positive edge
Absolute target position Limit values:
The velocity of the axis: This velocity is not always reached because of the configured acceleration and deceleration and the target position to be approached
The absolute target position reached
Busy OUTPUT BOOL TRUE The command is being executed
Motion control instruction "MC_MoveVelocity" moves the axis constantly at the specified velocity shown in Table 4-10
Axis INPUT TO_Axis Axis technology object
Execute INPUT BOOL Start the command with a positive edge
Velocity specification for axis motion Limit values:
≤ maximum velocity (Velocity = 0.0 is permitted)
Absolute Encoder
4.3.1 Absolute position detection system of Mitsubishi AC Servo Motor MR-J3
To read the absolute encoder, it is essential to configure parameters PA01 to 0000h and PA03 to 0001h, and ensure a battery is installed The absolute position-erase (AL25) error occurs when the absolute position is lost due to a faulty encoder cable connection or battery power depletion Notably, AL25 will inevitably occur during initial battery installation or when setting PA03 to 0001h In cases where the issue arises from first-time installation, simply power cycling the device by turning it off and on again can resolve the problem.
Remember to change the battery after two years
4.3.1.2 I/O interfaces for reading the absolute position
In this project, absolute encoder data is directly accessed through the drive and PLC's inputs and outputs, bypassing standard communication protocols The specific pin names and numbers used for this data reading are detailed in Table 4-11 Notably, the function of these pins is subject to change if the drive is not operating in absolute position mode, highlighting the importance of correct configuration.
Signal name Code CN1 Pin
While ABSM is on, the servo amplifier is in the ABS transfer mode and cannot be moved
Turn on ABSR to request the ABS data in the ABS transfer mode
Indicates the lower bit of the ABS data (2 bits) which is sent from the servo to the programmable controller in the ABS transfer mode
Indicates the upper bit of the ABS data (2 bits), which is sent from the servo to the programmable controller in the ABS transfer mode
Indicates that the data to be sent is being prepared in the ABS transfer mode
The communication protocol through the I/O interface, as illustrated in Figure 4-7 of the MR-J3 manual, utilizes a 32-bit data format and a 6-bit checksum Notably, the data received from the Absolute Encoder or ABS counter does not directly represent distance, but rather each bit corresponds to a distance equivalent to one command pulse Consequently, this data is directly related to the PA05, PA06, and PA07 values, providing a crucial link between the ABS data and the command pulses.
1 At power on, the PLC turns on ABSM and SON simultaneously (ABSM can be turned on before SON a little bit)
2 When ABSM is on, the drive is in ABS transfer mode The servo detects and calculates the absolute position When this process is done, ABST (transmission data ready) is turned on to notify the PLC that the servo is ready
3 After acknowledging that ABST has been turned on, the PLC turns ABSR (ABS request) ON
4 In response to ABSR, the drive transmits 2 bits from ABS data, and the ABST is turned OFF
5 After acknowledging that the ABST has been turned OFF, the PLC reads 2 bits of ABS data and then turns ABSR off
6 The drive turns ABST on again to respond to the subsequent request Steps 3 and 6 are repeated until 32-bit data and the 6-bit checksum have been transmitted
7 After receiving the 19th ABS transfer turn, ABSM must be turned off If this procedure is processed incorrectly, alarms related to each particular mistake will occur The ABS data can only be read once when the power is ON The absolute encoder cannot be reread if the base circuit is ON
Figure 4-7 Communication protocol through I/O interface
4.3.2 Program for reading Absolute Encoder
Table 4-12 describes the meaning of variables in the flow chart The main ideas for reading absolute encoder and homing are illustrated in Figure 4-9 and Figure 4-10
Name Describe i encoder This variable indicates the order of the first 32 bits of ABS data j checksum This variable indicates the order of the last 6 bits of ABS data
This variable stores the sum of the first 32 bits of the ABS data The process of calculating the sum from the first 32 bits is illustrated in Figure 4-8
Checksum B This variable stores the sum of the last 6 bits from ABS data to compare with the first 32 bits
Figure 4-9 Flow chart of the homing process
Figure 4-10 Flow chart of reading absolute encoder process
Structure of software
Overall, the program of this system is separated into three parts, as in Figure 4-11 The Homing subprogram is represented in Section 4.3 because it relates to the
CHAPTER 4: SOFTWARE STRUCTURE hardware of MR-J3 Other operations unrelated to the robotic arm are separated into a subprogram called "the rest of the system."
Figure 4-11 Flow chart of the main program
4.4.1 Flow chart of Magician Robotic Arm
Robotic arms' movement is separated into position control and velocity control
The trajectory of the end manipulator is illustrated in Table 4-13, where the coordinates of the points may vary depending on the device's position The robotic arm features a pneumatic gripper from SMC, which operates based on signal input - closing and grabbing when the signal is on, and opening widely when the signal is off The software controlling the robotic arm is outlined in Figure 4-12, providing a comprehensive overview of its functionality.
Table 4-13 The trajectory of the end manipulator
Example of position or velocity along the z-axis
This state is a safe position to start
Here, collision is avoided while the robotic arm starts working
Move to the (x;y) position of the bottle on the conveyor Z is set at 130, which is high to avoid bottle collision
The end manipulator is lower, nearly touching the cap of the bottle
The end manipulator is moved gradually from the top to the bottle's neck
5 Position (61;317;93.5) ON Position of the neck of the bottle
The bottle is moved straightly from the conveyor
Position of the bottle when being removed from the conveyor
To ensure safe and efficient placement, the bottle is positioned on the box at a strategic location, avoiding direct movement into the box to prevent potential collisions The x and y coordinates of the bottle can be adjusted based on its designated order within the box, allowing for precise and organized placement.
9 Position (450; 90; 80) ON The bottle is lowered above the box
The bottle is moved straightly to the box The trajectory must be straight vertically to avoid collision with other bottles
The bottle is put in the right position in the box
12 Velocity 20 OFF Gripper is higher from the box
Gripper is moved higher completely The robotic arm returns to state 1
Figure 4-12 Flow chart of the robotic arm
4.4.2 Flow chart of the rest of the system
The system consists of a robotic arm and three distinct stations, including a water filling station, a pneumatic cylinder-operated lid capping station, and an output station responsible for removing the bottle from the rotary disc Upon completion of tasks at each station, the rotary disc rotates 90 degrees, facilitating a seamless and efficient workflow This process is visually represented in Figure 4-13, providing a clear illustration of the system's operational flow.
RESULT
Overview
- Overview of the panel system (Figure 5-1)
Figure 5-1 The actual wiring system of the panel
- Overview of the panel system with the view buttons (Figure 5-2)
Figure 5-2 Overview of the actual electrical cabinet
- The wiring system of the panel (Figure 5-3):
Figure 5-3 Actual wiring system in detail
- Overview of the whole project hardware (Figure 5-4):
Figure 5-4 Overview of the project
Images of the working process
Initially, empty bottles are placed on the input conveyor and pushed towards the end of the conveyor to fill water into the bottles, as shown in Figure 5-5
Figure 5-5 Bottles in the input conveyor
Figure 5-6 Filling water into a bottle
Following the manufacturing process, the bottles are then conveyed to the capping stage, where a specially designed restraining bar, operated by a sliding edge mechanism, securely holds the cap in place, facilitating a seamless sealing process, as illustrated in Figure 5-7.
The capped bottles have a shape as shown in Figure 5-8
Figure 5-8 Cap before it is capped
In the next step, they are moved to the capping station and tightly sealed by a pneumatic mechanism, as shown in Figure 5-9
Figure 5-9 Pneumatic cylinder is capping the bottle
The final stage of the assembly line involves transferring the filled bottles onto the output conveyor, as depicted in Figure 5-10, where they are then ready for distribution, having been accurately filled with the required amount of water and securely capped.
Figure 5-10 Bottles are delivered to the output conveyor
Despite repeated system runs, errors can still occur, potentially resulting in improper cap application onto the bottle mouth, which may lead to the pneumatic system's failure to achieve a secure seal.
Following transfer to the output conveyor, bottles are directed to a designated waiting area where they are secured by a system of 3D-printed barriers The Magician Robotics Arm then sequentially retrieves the filled and capped bottles from this holding area and carefully places them into storage for further processing.
Figure 5-11 3D printing barrier to stop the bottle
The robot begins to grip the bottles, as shown in Figure 5-12
Figure 5-12 A pneumatic cylinder grips bottle
To alleviate the computational load on the PLC, velocity control mode is employed in various processes, as discussed in Chapter 4 The effectiveness of this algorithm has been successfully demonstrated, with test results presented in Figure 5-13, showcasing its potential in reducing the processing burden.
Figure 5-13 Joint 2 & 3 moving along the Z-axis
The completed bottles then be put into storage, as shown in the black circle in
Figure 5-14 Robotics Arm puts the bottles into the storage
In the final step, the Magician Robotics Arm is moved to the safe position and repeats the gripping process as performed in Figure 5-15
Figure 5-15 Movement after each gripping process of the Magician Robotics Arm
CONCLUSION AND DEVELOPMENT
Conclusion
- Mechanical design is effective Overall, the whole process operates correctly Especially, lids are put successfully on bottles
- The robotic arm operates correctly without any error over a long time
- The PLC reads absolute encoders of ac servos successfully
- A creative wiring diagram has successfully overcome the differences between the two brands, Siemens and Mitsubishi
- Noise has been eliminated by the earthing system
- Filling accuracy is low The error is extremely high at the first time filling when there isn't any water in the pipe
- The durability is low Joints in the pneumatic cylinder and conveyors must be repaired after 1 hour of operating
- The earthing system is not entirely effective Electrocution is still a problem.
Development
There are several ways of development for this project:
- An image processing system can be built to eliminate defective products
- Advanced mechanical devices, such as helical gear, bevel gear, and worm gear, shall be installed to enhance robot performance
- The kinetics of the robotic arm can be calculated to design a controller for each motor
The veterinary pharmaceutical market is expected to experience significant growth in the coming years, driven by increasing demand for animal health products and advancements in technology According to a report by Hanoi University of Veterinary Medicine, the market is poised for expansion, with a growing need for innovative and effective treatments for various animal diseases As the global population continues to urbanize and the demand for animal protein increases, the veterinary pharmaceutical market is likely to see substantial development in the near future.
[2] "TechSci Research," TechSci Research LLC, [Online] Available: https://www.techsciresearch.com/report/vietnam-robotics-market/8078.html
[3] N H Ngô and Q H Trương, "THIẾT KẾ MÔ HÌNH GIÁM SÁT VÀ ĐIỀU KHIỂN
HỆ THỐNG CHIẾT RÓT VÀ ĐÓNG NẮP SỬ DỤNG PLC S7-1200," HCMC University of Technology and Education, Ho Chi Minh, 2019
[4] P T Võ and T Đ N Nguyễn, "MÔ HÌNH CHIẾT RÓT ĐÓNG NẮP CHAI TỰ ĐỘNG," HCMC University of Technology and Education, Ho Chi Minh, 2016
[5] "Vial Liquid Filling Sealing Production Line," Marya, [Online] Available: https://www.techsciresearch.com/report/vietnam-robotics-market/8078.html
[6] Mitsubishi Electric, "MELSERVO-J3 Series SERVO AMPLIFIER INSTRUCTION MANUAL," Tokyo, 2014
[7] Siemens, "STEP 7 S7-1200 Motion Control V6.0 to V7.0 in TIA Portal V16,"
PLC program by TIA Portal
Here, we only show the process of reading the absolute encoder, which is the most creative part of the program