A Low-Cost System for Remote Access and Control of Automation Equipment(3)

2021/5/6 21:19:19 人气:

3. Results 

After selecting the components for the design, the GUI layout and programming, micro-controller programming, and hardware layout were prototyped. Sample PLC programs were also developed to test the operation of the hardware. 3.1. GUI Program Layout Figure 11 illustrates the fifinal layout of the GUI program. The key parts of the GUI are explained below: Video Screen—The white rectangular portion under the heading “Webcam” is allocated to show the video of the hardware. This is accomplished via the web camera installed in the lab. The video captured from the web camera inside the lab is made visible in this section with appropriate programming done with windows forms application. Camera Selection—The yellow rectangular block in the bottom left corner of the window with the heading “CAMERA” is used to select the required camera from the list of cameras available. Since the laboratory computer is a laptop computer there is an option to select the built-in HD web camera or the Logitech C920 HD Pro. Experiment Selection—The yellow rectangular block in the bottom centre of the window with the heading “PORT BOX” is used for the selection of the experiment. Before selecting the experiment, the communication port must be selected from the drop-down menu. By default, this is COM3 to establish communication between the computer and the micro-controller. Experiment Power—The remaining two yellow blocks on the right side of the window are used to power on/off each hardware experiment individually.

image.png

Figure 11. Layout of the GUI program.Machines 2021, 9, 138 10 of 18 3.2. Micro-Controller and Hardware Wiring The USB serial port connection between the laboratory computer and the microcontroller was set up with a baud rate of 9600. The micro-controller program preconfifigures the pins and inputs or outputs and assigns a default value to the output pins. Figure 12 shows the sample code for serial communication of data on the Arduino micro-controller. A string of data is read from the GUI program, and the control lines are switched off when an “off” command is received. 

image.png

Figure 12. Arduino micro-controller sample serial communication code. The wiring connections between the TM221CE24T PLC module and the two-experiment hardware is shown in Figure 13. The two 8-channel relay modules multiplex the connections to the PLC. When the relays are switched off, the lines are connected to the forward/reverse conveyor experiment. If the relays are energized via the GUI program, the control lines are switched over to the Festo sorting machine. Table 1 shows the input–output usage of the Centronics cable, and Figure 14 illustrates the physical pin connections. Figure 15 shows the connections between the power supply, Duinotech Mega 2560, and the 8-channel relay modules.Machines 2021, 9, 138 11 of 18 Table 1. Input output usage of the Centronics cable. Pin Number PLC Connection FWD/REV Conveyor Festo Sorting Machine I0 %I0.0 Proximity sensor 1 Gate 1 arm feedback I1 %I0.1 Proximity sensor 2 Gate 2 arm feedback I2 %I0.2 Gate 3 arm feedback I3 %I0.3 Entry PE sensor I4 %I0.4 Gate 1 PE sensor I5 %I0.5 Gate 2 PE sensor I6 %I0.6 Gate 3 PE sensor I7 %I0.7 Gate 4 PE sensor O0 %Q0.0 Reverse on Conveyor motor O1 %Q0.1 Forward on Gate 1 solenoid O2 %Q0.2 Indicator lamp 1 Gate 2 solenoid O3 %Q0.3 Gate 3 solenoid O4 %Q0.4 Indicator lamp 2 Indicator lamp 

image.png

Figure 13. Wiring connections between the TM221CE24T PLC module and the two hardware. 

image.png

Figure 14. Physical pin connections of the Centronics cable.Machines 2021, 9, 138 12 of 18 

image.png

Figure 15. Power supply, Duinotech MEGA 2560, and relay modules connection. 

3.3. Control and Power Box Construction After fifinalizing the wiring connections, the control and power boxes were constructed and the electronics assembled. The boxes were pre-sized ABS plastic cases. Perspex was used at the bottom of the boxes to mount the electrical and electronic components. Appropriate cut outs were made for external switches, lamps, connection ports, and ventilation fans. Following this, the power supply was tested with a multimeter. The physical connections within the control box were also tested for continuity and correct logic with a multimeter. Figure 16 shows the control box after making the required holes and with the panel board fifixed inside. The operation of the micro-controller with the relays were tested with an external power supply while the power supply box was being constructed. The commands to operate the relays via the micro-controller for switching the experiments were provided by the GUI program. The illuminated red lights indicate the successful testing procedure. Pictures of the fully assembled control box are shown in Figures 17 and 18.Machines 2021, 9, 138 13 of 18 

image.png

Figure 16. Testing the GUI program controlling the 8-channel relays via the micro-controller. 

Figure 17. Fully assembled control box. The power supply box layout is shown in Figure 19. Relay control signals from the Control Box switch on/off the 230 V AC supplies to the experiment hardware. There are two AC sockets to connect the power supply for each hardware. The power supply box also provides the 24 V DC required for the PLC logic and experiment hardware.Machines 2021, 9, 138 14 of 18 

image.png

Figure 18. Side views of the fifinal control box. (a) Centronics cable connections and exhaust fan; (b) Indicator lamps for experiment selection and air inlet vent; (c) Power supply connections—USB for micro-controller, and ethernet for relay controls to power supply box. 

Figure 19. Power supply box layout. (a) Sealed box with 230 V AC and 24 V DC outputs; (b) Box with cover removed; (c) Plan view of open box showing relay connections and 24 V DC supply unit.Machines 2021, 9, 138 15 of 18