1 System composition and implementation
1.1 System test principle
As shown in Figure 1, the cigarette box adopts a 5x5x2 structure to arrange the cigarettes. A pair of parallel plates are set at both ends of every 5 cigarettes, which constitutes 10 pairs of flat plate capacitors. The capacitance is:
C=ε·s/d (1)
where ε is the dielectric constant of the medium between the plates, s is the relative effective area of the two plates of the flat plate capacitor, and d is the distance between the plates. It can be seen from formula (1) that as long as any value of ε, s, and d is changed, the capacitance value C will change. Since the dielectric constants of cigarettes and air are very different, when there is a missing cigarette in the cigarette box, 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 from 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, 21 most significant bits, linearity is ±0.01%, and 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. The working environment temperature range is from -40 to +125℃.
In Figure 1, the design of the plate uses an insulating ceramic coated on the PCB board to reduce the edge parasitic capacitance of the 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 LabVIEW2009. LabVIEW is a typical representative of graphical programming languages. The characteristics of graphical programming languages are based on standard software and hardware resource platforms such as general-purpose computers to build a test monitoring system with clear hierarchy, powerful functions and friendly human-computer interface. Therefore, it has been increasingly 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 the LabVIEW development platform to design a cigarette box missing strip 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 strip information through the host computer parameter settings.
The upper computer system mainly completes the following tasks:
1) Set parameters for the lower computer device of cigarette box detection 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 bar position pattern for the missing bar cigarette box, alarm and send a rejection control signal to the rejection device;
6) Self-learn the data reflected on 10 sets of capacitor plates for normal cigarette boxes and cigarette boxes with missing bars in different positions, and cooperate with human intervention to improve 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.
1.3 Lower computer system structure
The entire lower computer system is shown in Figure 4. The microcontroller uses the Flash microcontroller with the Philips 51MX core, the master microcontroller uses P89C51RD2, the slave microcontroller uses P89C669, the host and slave use SPI communication, and the slave and microcapacitor 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 whole system workflow, 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 strips and the corresponding capacitance characteristic value when missing strips appear at different positions, and measure them multiple times to obtain the average value to reduce the acquisition 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 strips.
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, and the main microcontroller will notify each slave through the SPI port in turn 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 front half box position detection switch will output a signal to the main microcontroller, and the main microcontroller will output a signal to the stepper motor, and the actuator will block the cigarette box from moving forward, 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 the cigarette box is missing strips. If a missing carton box is detected, a signal is sent to the actuator to reject the carton, and the missing carton position information is uploaded to the host computer. The missing carton judgment and rejection signal output can also be completed by the host computer to provide a more flexible and reliable missing carton judgment algorithm.
1.4 Design of the capacitance data acquisition unit circuit
The circuit design schematic is shown in Figure 5. The plate on one side of the capacitance sensor is connected to the EXCA terminal of AD7746 through the SMA shielded wire, and the plate on the other side is connected to the CINl+ terminal to realize 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+ ends; 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.
2 Measurement results
Figure 6 shows the measurement values of the 10 capacitive sensors in the 5x5 cigarette box when there is no missing cigarette bar and when there is a missing cigarette bar at different positions. ABCDE corresponds to the measurement values of 5 column positions, and 12345 corresponds to the measurement values of 5 row positions. The data with gray shading is the two-dimensional change data when the cigarette bar is missing at the corresponding position. It can be seen from the figure that when there is a missing cigarette bar, 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 bar and determine the missing position.
3 Conclusion
The cigarette box missing carton detection system based on the two-dimensional capacitive sensor array has a simple structure, can determine the missing cigarette carton position, and display the missing carton pattern, which greatly improves the reliability of the detection. At the same time, it is low-cost and does not pose a radiation hazard. It is suitable for fields 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 seriously affecting the reputation of enterprises. It has broad application prospects.
Previous article:Introduction to the application of magnetic components in set-top box power supply
Next article:Research on the Neutral-Ground Voltage Problem in Data Centers
- Popular Resources
- Popular amplifiers
- MathWorks and NXP Collaborate to Launch Model-Based Design Toolbox for Battery Management Systems
- STMicroelectronics' advanced galvanically isolated gate driver STGAP3S provides flexible protection for IGBTs and SiC MOSFETs
- New diaphragm-free solid-state lithium battery technology is launched: the distance between the positive and negative electrodes is less than 0.000001 meters
- [“Source” Observe the Autumn Series] Application and testing of the next generation of semiconductor gallium oxide device photodetectors
- 采用自主设计封装,绝缘电阻显著提高!ROHM开发出更高电压xEV系统的SiC肖特基势垒二极管
- Will GaN replace SiC? PI's disruptive 1700V InnoMux2 is here to demonstrate
- From Isolation to the Third and a Half Generation: Understanding Naxinwei's Gate Driver IC in One Article
- The appeal of 48 V technology: importance, benefits and key factors in system-level applications
- Important breakthrough in recycling of used lithium-ion batteries
- 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!
- Rambus Launches Industry's First HBM 4 Controller IP: What Are the Technical Details Behind It?
- 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
- EEWORLD University Hall----POS Printer/Printer Special
- High-performance C6000 DSP architecture
- How to share the University Hall video to Moments
- Smart Clock
- Five solutions to long branch lines in CAN networks
- [Raspberry Pi Pico Review] C/C++ Development Environment Construction
- If the stmTX and RX pins of stm32 are broken, will stm32 still work?
- Msp430f5438 development board rental, manual deletion
- The TNY277 designed 15V 1A output switching power supply can work normally, but it is very hot. How to solve it?
- Getting Started with MSP430FR6989 LCD Functions