Color sensing technology is one of the core technologies of modern color measurement instruments, and has developed into a system that integrates optics, mechanics, and electronics. With the development of modern industrial production towards high speed and automation. Strict requirements are put forward for the inspection of product color and the control of color quality. The use of color measurement instruments has also become the main means of objectively evaluating product color.
In the detection and identification of color, there are many parameters that affect its accuracy. For example, lighting source, sensor characteristics, receiving part, signal processing, etc., will directly affect the measurement results. How to handle these parameters to obtain accurate measurement results is one of the main problems at present. At present, the three-primary color (RGB) color sensor is widely used in detection. This article will introduce a method for implementing a handheld color detector based on the RGB three-primary color principle.
1 Measurement system structure and measurement principle
As shown in Figure 1, this system is mainly composed of color sensor, lighting source, signal processing circuit, single chip microcomputer and liquid crystal display.
1.1 Color sensor
RGB tri-color sensor realizes color detection by measuring the reflection ratio of the three primary colors that constitute the color of the object. Due to its extremely high precision, it can accurately distinguish extremely similar colors, or even different tones of the same color. This design uses the MCS series RGB tri-color color sensor.
1.2 Lighting source
The measurement spectrum range required by this design is 380nm~750nm, and white light can basically cover this spectrum range, so white patch light-emitting diode lighting is selected. Using white light illumination instead of multiple monochromatic lights to simulate white light illumination can improve the lighting effect in theory and practice, and simplify the design method. Multiple white light-emitting diodes form a ring 45° (illumination)/0° (measurement) ring lighting system.
1.3 Signal processing circuit
The output signal of the color sensor is generally a tiny current of nanoampere level, which brings inconvenience to the measurement. First, the tiny current signal must be converted into a voltage signal so that the subsequent A/D conversion circuit and single-chip microcomputer can process it, and the amplification process must be completed at the same time. How to complete the conversion and amplification of the photocurrent signal while minimizing distortion is a problem that must be solved in the measurement work.
1.3.1 Principle of microcurrent measurement
The microcurrent signal source can be regarded as a current source IS with a very large internal resistance. The principle of microcurrent measurement with a ground terminal is shown in Figure 2. For an ideal operational amplifier with infinite input impedance and amplification factor, the output voltage V0 = ISRf. In theory, as long as the resistance Rf is large enough, even if the current IS is very small, a large output voltage V0 can be obtained.
In fact, the input impedance of the operational amplifier is not infinite, and the increase of the resistor Rf is limited by the input impedance
of the operational amplifier. Considering the shunt of the bias current IB to the measured current IS, V0=-(IS-IB)Rf. If IB is greater than IS, IS cannot be measured. The primary factor affecting the sensitivity of micro-current measurement is the bias current IB of the operational amplifier, followed by noise voltage and zero drift. To achieve micro-current measurement, the operational amplifier must meet the following requirements: ① bias current IB < measured current IS; ② input impedance RI >> feedback resistor Rf; ③ high gain and common mode rejection ratio; ④ small offset voltage and drift; ⑤ low noise.
1.3.2 Circuit analysis and design
In terms of device selection, the input bias current IB of the operational amplifier is one of the main error sources. This scheme uses the AD8608 chip produced by AD as the main chip for current conversion amplification, as shown in Figure 3. In order to measure nanoampere current, Rf in Figure 2 should be a resistor of the order of 1010. Such a large resistor has low precision, poor stability, and high noise. Therefore, in Figure 3, a T-type network is formed with a small resistor to replace the high-resistance Rf, and an RC filter circuit is connected to the output of the operational amplifier to remove the interference of high-frequency noise signals and chopping spike noise. This is very beneficial to improving the stability of the circuit, but the time constant is generally large and is not suitable for measuring fast-changing signals. C and R form a feedback compensation network to reduce the bandwidth and prevent the T-type network and C1 phase shift from generating self-oscillation. [page]
1.3.3 Measures to improve performance
(1) Do not connect the balancing resistor of the operational amplifier
Experiments have shown that in a micro-current amplifier with a high internal resistance current source, it is not only difficult to balance the input resistance if the operational amplifier is connected to a balancing resistor, but it will increase the circuit noise. Therefore, the AD8608 operational amplifier in Figure 3 does not connect the balancing resistor to the in-phase terminal, but is directly grounded.
(2) Reduce the operating temperature of the operational amplifier
From the temperature characteristics of the operational amplifier, it can be seen that for every 10°C increase in temperature, the bias current of the operational amplifier will increase by 1 times, thereby reducing the sensitivity and accuracy of micro-current measurement. To this end, the power supply voltage should be reduced as much as possible. Increase the load resistance (greater than 10kΩ) to reduce the operating current of the operational amplifier and reduce the operating temperature.
(3) Reduce the leakage current of the PCB
In micro-current measurement, it is very important to improve the insulation strength of the PCB and reduce the leakage current. The leakage current of the nanoampere level, which is equivalent to insulation in the usual sense, will have a serious impact on the measurement results, so measures should be taken to strictly control the leakage current of the PCB board: select a high-insulation circuit board with a leakage current far less than pA level, such as an epoxy glass board; use a polytetrafluoroethylene terminal with good insulation, no static electricity, and low hygroscopicity for the input signal; surround the in-phase and inverting input terminals of the operational amplifier on the circuit board with a grounding shield ring and ground them to make them equipotential and ensure that the leakage current between them is zero; after the circuit is installed, remove residual impurities, and clean, dry and moisture-proof the components and circuit boards.
(4) Improve the signal-to-noise
ratio Resistors should be low-noise gold film resistors with 1% accuracy; capacitors should be low-noise ceramic, mica or tantalum capacitors; two-stage LC filtering of the power supply should be used to reduce noise; the power line should be as far away from the input signal line as possible; the signal input line should use a shielded cable as short as possible; large areas of copper should be applied to the output and input parts of the power supply and the amplifier, and the input part of the amplifier should be grounded to the power supply; the entire micro-current amplifier should be shielded with metal.
1.4 Measurement and control circuit
This system uses the PICl8Fxx8 series microcontroller as the core, and uses its built-in A/D converter to collect the signal after current and voltage conversion, compare it with the reference data, obtain color coding, and send it to the LCD screen for display, as shown in Figure 4.
2 Software Design
This system is programmed in assembly language, which is conducive to improving the program running speed. The system software flow chart is shown in Figure 5.
3 Experimental results and conclusions
The sample used in the experiment is the "China Architectural Color Card". This is a set of standard samples of object colors for use in the construction industry. Its color representation method is designed based on the numbering system of GB/T15608-1995 "China Architectural Color System". The coding of the color card is made according to the requirements of GB/T 18922-2002 "Methods for Representing Architectural Colors". [page]
3.1 Experiment
This system has been used for color detection experiments, and several standard colors were selected from the "China Architectural Color Card" for measurement. Figure 6 is the actual measurement of the green color stimulus value after the color system is converted into the RGB color system.
3.2 Experimental conclusion analysis
It can be seen from the curve in Figure 6 that due to the existence of various interference factors, the situation of distinguishing extremely similar colors in the experiment is not ideal. The main interference factors include:
(1) The influence of the lighting source on the measurement sensitivity
The stability of the lighting source directly affects the accuracy of the output signal of the color sensor. White light does have advantages over single color light simulation, but it also has its own problems, such as relatively unstable color temperature and less than ideal balance.
(2) The influence of feedback resistance on the sensitivity of current-voltage conversion. Feedback resistance with large resistance value has low precision, poor stability and high noise, while feedback resistance with small resistance value can easily drown the measured signal in noise.
(3) Color card calibration problem
Each set of standard color cards has a shelf life. After a period of use, they are prone to color loss and discoloration, and need to be cleaned, maintained or replaced.
Color detection is very useful in industries, production automation and office automation. Effectively, conveniently and reliably measuring the color of the object being measured is one of the key technologies in color detection. The RGB three-primary color sensor ensures the accuracy of the measurement, while the amplification circuit and the control circuit with the single-chip microcomputer as the core ensure the accuracy and speed of data processing. The design of the handheld color detector described in this article is widely used, and it explores the rapid, convenient and accurate acquisition of color information technology, which will surely promote further research on such technologies in China.
Previous article:Design of RS-232/RS-485 Interface Intelligent Transceiver Converter
Next article:Analytical solution of using PIC16F73 single chip microcomputer to generate SPWM wave to control UPS power inverter system
Recommended ReadingLatest update time:2024-11-16 22:41
- Popular Resources
- Popular amplifiers
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- 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
- LED light flickering problem, help
- Invite enthusiastic netizens to build eeWorld together
- Book a live broadcast with prizes: Enjoy purity - ams active noise reduction and proximity sensing bring a new level of headphone design
- Analog Front End AFE
- Is there any special way to route the wiring of this type of seat?
- Free review: GigaDevice GD32F310G-START
- Please advise, is there any impact if this reset detection chip is removed?
- [Silicon Labs BG22-EK4108A Bluetooth Development Evaluation] Evaluation 2 SOC_Blinky Service Configuration
- Programming classes are coming to primary and secondary schools. What do you think?
- Say goodbye to film! Design a smarter car sunroof