# PLC-Controlled Intelligent Conveyor System with AI-Enhanced Vision for Efficient Waste Sorting
## 2 System
### Architecture  
In the previous section, the different elements that constitute the system architecture were outlined. This architecture incorporates several interconnected elements that work together to efficiently detect and sort objects automatically. The system is designed to include a conveyor belt, a camera, a stepper motor, a PLC, an HMI, and a PC. Each component has a unique function within the system, facilitating the exchange of data and control signals to ensure efficient real-time processing and operation. In this prototype, a motor relay controls the conveyor belt, with its direction managed via two input ports. These ports determine whether the motor rotates clockwise or anticlockwise, based on the received signals. This control is essential for the conveyor to function properly in moving items through the detection and sorting process. A comprehensive description of the system components and their connections is illustrated in Figure 6.  
A camera is located at the start of the conveyor belt, where various parts, such as plastic, metal, or paper, are placed. This camera plays a crucial role in taking pictures of items as they enter the system. The captured images are transmitted to the PC for immediate processing and examination. Positioning the camera at the conveyor entry point guarantees  
Figure 5: BMUD60-A2 brushless DC motor driver for precise control and efficient operation of the conveyor system. Figure 6: Schematic of the automated waste sorting system: conveyor belt with a camera, stepper motor, PLC, PC, HMI, and bins for object sorting and categorization. that every item is captured immediately, allowing prompt object recognition. As illustrated in Figure 7, the PC and the PLC are connected by an Ethernet cable, establishing a reliable communication network. This Ethernet connection allows the PC to interact with the PLC using tag addresses to perform data writing and reading operations on the PLC. The PC processes the camera data, identifies the objects, and sends control commands to the PLC. These commands instruct the PLC on how to manage the sorting process. The use of Ethernet provides high-speed communication between the two components, ensuring that real-time control is maintained throughout the process. The PLC is integral to the control architecture of the system. It includes (I/O) ports that facilitate connections to the motor control system, the start and stop buttons, and the HMI. The start and stop buttons provide manual control over the conveyor system, allowing operators to start or stop the process as needed. The motor controller interfaced with the PLC allows the system to regulate the conveyor's movement with precision, ensuring that items are delivered accurately to their specified containers. The HMI serves as a user interface that allows operators to monitor system status, view process data, and make real-time adjustments as needed. The integration of HMI with PLC provides operators with valuable insight into system performance and enables efficient process control. Once the camera captures the object and the computer algorithm recognizes it, the information is sent via the Ethernet connection to the PLC. The PLC then directs the conveyor belt to transport the items to their designated sorting positions. Once the part reaches the end of the belt, the PLC activates a stepper motor, which is responsible for pushing the object into the appropriate bin. The system employs color-coded bins for different materials (e.g., plastic, metal, and paper), allowing for efficient sorting based on the detected object type. The stepper motor provides precise control, ensuring that each object is accurately directed to its designated bin. The PLC facilitates adaptable control and system scalability, and the Ethernet link between the PC and the PLC guarantees swift and stable data transmission, while the HMI improves user interaction with the system, offering real-time feedback and control capabilities.