Aiming at the problem of missing cigarette boxes when packing on the tobacco production line, a capacitive sensor composed of micro-capacitor detection chip AD7746 is proposed to perform two-dimensional detection of cigarette boxes. The system is divided into two parts: the upper computer and the lower computer, and RS485 communication is used between the upper computer and the lower computer. The upper computer uses the cigarette box management software written in LabVIEW; the lower computer system adopts a master-slave single-chip microcomputer structure, the host uses a P89C51RD2 single-chip microcomputer, and the slave is composed of ten P89C669 single-chip microcomputers. The measurement results show that the system detection effect is reliable and has a good application prospect.
In cigarette production, when packing cigarettes, the packing and packing machine does not work properly when the production flow of cigarettes is large or the incoming materials are insufficient, and cigarette boxes often have missing cigarettes. In order to effectively identify missing cigarettes, many cigarette factories are equipped with missing cigarette detection devices on the production line. At present, the missing cigarette detection methods include X-ray detection method, weighing method, capacitance detection method, etc. These methods can detect missing cigarettes. But they all have shortcomings. Due to different tobacco moisture content, even the same brand of cigarette boxes have a weight change range of 2% to 3%. There are 50 cigarettes in a box, and the weight reduction caused by missing one is 2%, which is within the normal value range of cigarette box weight change. Therefore, the weighing method cannot obtain reliable detection results. The X-ray detection method has high detection reliability, complex system, and potential threats to human safety. The use and management costs are high. The capacitance detection method has a simple structure and low cost, but the one-dimensional capacitance array is used for detection, which is not reliable and cannot analyze the missing position. The capacitive two-dimensional cigarette box missing strip detection device proposed in this paper can not only reliably detect the missing strips of cigarette box, but also locate the position of the missing strips. It has a simple structure, low cost, energy saving and environmental protection, and is safe and reliable.
1 System composition and implementation
1.1 System Testing Principles
As shown in Figure 1, the cigarette box uses a 5x5x2 structure to arrange cigarette rods. A pair of parallel plates is set at both ends of every 5 cigarettes, forming 10 pairs of flat plate capacitors, whose capacitance is:
C=ε·s/d (1)
Where ε is the dielectric constant of the medium between the plates, s is the effective area of the two plates of the flat capacitor, and d is the distance between the plates. It can be seen from formula (1) that as long as any value of ε, s, or d is changed, the capacitance value C will change. Since the dielectric constants of cigarettes and air are very different, when a cigarette box is missing, the dielectric constant of the corresponding position will change, and the corresponding row capacitance sensor and column capacitance sensor values will change. By calculating and comparing the two-dimensional capacitance value with the standard value, the missing cigarette box can be detected.
In actual measurement, due to the large size of the cigarette box, the effective distance between the plate capacitors is large, and the measured capacitance value is very small, only a few pico-farads. After comparison, the self-designed micro-capacitance detection circuit has large noise, low accuracy, and low resolution, and cannot guarantee the reliability of measurement. The high-precision capacitance/digital conversion chip AD7746 of AD Company is a 24-bit digital output capacitance value measurement chip. AD7746 is a high-resolution ∑-△ type capacitance digital converter (CDC). The measured capacitance can be directly connected to the input end of the device. Its resolution is up to 24-bit distortion-free code, the most significant bit is 21 bits, the linearity is ±0.01%, and the accuracy is up to ±4pF (factory calibration). The sampling frequency/passband is 10Hz to 90Hz, with an I2C-compatible serial interface, and can work under a single power supply of 2.7 to 5.25V, and the working environment temperature range is from -40 to +125℃.
In Figure 1, the plate design uses insulating ceramics coated on the PCB to reduce the edge parasitic capacitance of the flat plate capacitor and ensure mechanical strength. The connection between the plate and AD7746 uses SMA shielded wire to reduce parasitic capacitance and improve anti-interference ability.
1.2 Host computer system structure
The host computer software is programmed using LabVIEW 2009. LabVIEW is a typical representative of graphical programming languages. Graphical programming languages are characterized by building a test monitoring system with clear hierarchy, powerful functions and user-friendly human-computer interface based on standard software and hardware resource platforms such as general-purpose computers. Therefore, it has been widely used in the field of measurement and control. The host computer mainly monitors the received data to ensure the normal operation of the system and saves important data in a timely manner.
The host computer uses LabVIEW development platform to design a cigarette box missing management system. The host computer communicates with the main controller through RS232 to RS485, and notifies the lower computer to collect data and record missing information through the host computer parameter setting.
The host computer system mainly completes the following tasks:
1) Set parameters for the smoke box detection lower computer device and control sampling;
2) Collect real-time data of cigarette boxes on the production line;
3) Automatically generate various real-time and historical production reports;
4) Link to the database to save historical data and query missing information;
5) Display the missing carton position pattern for the missing carton box, alarm and send a rejection control signal to the rejection device;
6) Self-learning is performed on the data on 10 sets of capacitor plates of normal cigarette boxes and cigarette boxes with missing strips in different positions, and human intervention is used to improve the detection accuracy.
As shown in Figure 2, the upper computer cigarette box missing strip management platform system mainly includes 6 modules, including serial communication, parameter setting, system alarm, data storage, report output, and rejection signal output. LabVIEW is used to establish a subVI for serial communication with the lower computer to process the received data and determine whether a strip is missing. When a strip is missing, in addition to generating a rejection control signal and an alarm, the upper computer also stores the missing strip information in the database to facilitate future inquiries by operators. Figure 3 is a front panel diagram of the parameter setting of the cigarette box missing strip management platform.
[page]
1.3 Lower computer system structure
The whole lower computer system is shown in Figure 4. The microcontroller uses the Flash MCU with Philips 51MX core, the master MCU uses P89C51RD2, the slave MCU uses P89C669, the host and slave use SPI communication, and the slave and microcapacitance digital conversion chip AD7746 use I2C communication.
PHILIPS' 51MX core Flash microcontroller adopts the enhanced 80C51 core with a maximum speed of 40 MHz; Flash code memory capacity ranges from 4 to 96 kB; on-chip extended RAM: 256 B to 8 kB; supports 6-Clock mode, doubling the speed at the same clock, or achieving lower power consumption and reduced EMI at the same speed; dual DPTR, effectively speeding up throughput; 4 interrupt priorities to better meet real-time requirements; 3 timers/counters, supporting PWM and PCA functions, timer overflow can automatically trigger I/O flipping, interrupt-free processing; built-in watchdog and software reset functions; support ISP/IAP/ICP download; ALE disabled (to reduce EMI); support power-off wake-up function (low-power application); high-reliability OTP memory, used in various harsh occasions; with CAN, I2C, SPI, ADC and other functional modules.
The working process of the whole system: before using the detection system for the first time, the management personnel need to log in to the upper computer management platform to collect the standard capacitance value of the box of cigarettes without missing cartons and the corresponding capacitance characteristic values when missing cartons appear at different positions, and measure them multiple times to get the average value to reduce the collection error; then send these data to the main microcontroller, and the main microcontroller stores them in the foot ROM memory as parameters for judging whether the box of cigarettes is missing cartons.
When the system is working, when the cigarette box just enters the detection area, the initial position detection switch will output a signal to the main microcontroller to start the system. The main microcontroller will notify each slave through the SPI port to complete the initialization of AD7746 and wait for data collection. When the front half of the cigarette box completely enters the detection area, the position detection switch of the front half box will output a signal to the main microcontroller, and the main microcontroller will output a signal to the stepper motor, blocking the cigarette box from moving forward through the actuator, and the slave will immediately collect data; after the collection is completed, the data will be sent to the main microcontroller in turn. When the second half of the cigarette box enters the detection area, the data of the second half of the box will be collected. After the data collection is completed, the main microcontroller will use the algorithm to calculate and determine whether there is a missing cigarette box. If a missing cigarette box is detected, a signal will be sent to the actuator to remove the cigarette box, and the missing position information will be uploaded to the host computer. The judgment of missing cigarette boxes and the output of the rejection signal can also be completed by the host computer to provide a more flexible and reliable missing judgment algorithm.
1.4 Design of capacitance data acquisition unit circuit
The circuit design schematic is shown in Figure 5. The plate on one side of the capacitive sensor is connected to the EXCA terminal of AD7746 through the SMA shielded line, and the plate on the other side is connected to the CINl+ terminal to achieve the sampling of the capacitance. Due to the different ambient temperatures, the AD7746 needs to be temperature compensated, and RTD is selected to connect to the VIN- and VIN+ terminals; the SCL and SDA of the AD7746 are respectively connected to the P1.6 and P1.7 ports of the slave microcontroller P89C669; the P1.6 and P1.7 ports can be configured as I2C digital interfaces, and the /RDY of the AD7746 is connected to the P3.2 (/INT0) port of the microcontroller. When the data conversion is completed, the microcontroller enters the interrupt service subroutine to process the data, thereby realizing the control of the AD7746.
Figure 6 shows the measurement values of the corresponding 10 capacitive sensors in the 5x5 cigarette box when there is no missing cigarette strip and when there is a missing cigarette strip at different positions, where ABCDE correspond to 5 column position measurement values, and 12345 correspond to 5 row position measurement values. The data with gray shading is the two-dimensional change data when the cigarette strip is missing at the corresponding position. It can be seen from the figure that when a missing cigarette strip appears, the corresponding row data and column data will change significantly. The column data change amplitude (0.15~0.21pF) is much larger than the column measurement error of 0.03pF, and the resolution reaches 23%. The row data change amplitude (0.009~0.013pF) is much larger than the row measurement error of 0.002pF. Therefore, through two-dimensional data detection, the system can reliably identify the missing cigarette strip and determine the missing position.
The cigarette box missing carton detection system based on the two-dimensional capacitive sensor array has a simple structure, can determine the missing position of the cigarette carton, and display the missing carton pattern, which greatly improves the credibility of the detection. At the same time, it is low-cost and does not pose a radiation hazard. It is suitable for areas such as cigarette production quality control or tobacco logistics monitoring. It effectively prevents missing carton cigarette boxes from entering the market, causing unnecessary economic and legal disputes between cigarette manufacturers, distributors and consumers, and even events that seriously affect the reputation of enterprises. It has broad application prospects.
Previous article:Pressure measurement and control system based on MPXM2010 and its precision improvement method
Next article:Circuit Design Scheme for Measuring Resistance Using Ratio Method
- Keysight Technologies Helps Samsung Electronics Successfully Validate FiRa® 2.0 Safe Distance Measurement Test Case
- From probes to power supplies, Tektronix is leading the way in comprehensive innovation in power electronics testing
- Seizing the Opportunities in the Chinese Application Market: NI's Challenges and Answers
- Tektronix Launches Breakthrough Power Measurement Tools to Accelerate Innovation as Global Electrification Accelerates
- Not all oscilloscopes are created equal: Why ADCs and low noise floor matter
- Enable TekHSI high-speed interface function to accelerate the remote transmission of waveform data
- How to measure the quality of soft start thyristor
- How to use a multimeter to judge whether a soft starter is good or bad
- What are the advantages and disadvantages of non-contact temperature sensors?
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- Showing off the i.MX6 development board
- [Xianji HPM6750 Review 10] Drawing a multi-function expansion board and verification
- About the distance of infrared obstacle avoidance circuit
- Repost - Tesla battery violent disassembly video
- Relationship between transformer and inductor
- X-NUCLEO-IKS01A3 sensor driver transplantation based on NUCLEO-L011K4
- Standard EIA RS-198
- TMS320C6678 power-on configuration and FPGA reset DSP
- IEC 61000-4-5 Phases of three-phase power supply systems
- [Chuanglong TLA40i-EVM development board] +04.USB-Camera test-abnormal (zmj)