1. Introduction
We know that the influx of alien species caused by the movement of ballast water to balance ships with the increase of international trade causes serious problems in the marine ecosystem [
1,
2]. For this reason, in 2004, the International Maritime Organization (IMO) adopted the “Convention on the Control and Management of Ballast Water and Sediment Emissions” [
3]. As a result, the 2019 Convention took effect and, in the future, all ships are required to install a Ballast Water Management System (BWMS) to sterilize the ballast water and meet the emission standards [
4].
The main sterilization processes of BWMS include electrolysis, the input of active substances such as ozone, UV irradiation, and heat treatment [
5,
6,
7]. The electrolysis of water is the most widely used because of its cost and effectiveness [
8]. Electrolysis of ballast water produces Total Residual Oxidant (TRO) capable of sterilizing microorganisms [
9,
10]. The electrolysis method BWMS must control the current to generate an appropriate TRO to prevent sterilization and excessive disinfection by-products in accordance with IMO D-2 regulations. For this reason, it is important to measure the correct TRO concentration.
Depending on the method of measuring TRO, there are DPD (N, N-Diehyl-p-phenylene diamine) colorimetric, ULR-DPD colorimetric, DPD titration, the iodometric method, the amperometric method, and the electrode method [
11,
12]. Among them, the DPD colorimetric method is the most effective method in ballast water treatment equipment, and the DPD reagent reacts with the residual oxidant dissolved in water to form an oxide (Würster Dye) and develops a magenta color. At this time, the color factor of the oxide is absorbed at the wavelength of 510~520 nm, and the absorbance value is derived in proportion to the TRO concentration [
13]. The TRO concentration measurement system must satisfy the accuracy of less than 5% and the precision of less than 2%, which are included in the standards for type approval and quality inspection of environmental measuring devices in seawater conditions [
14].
A high-brightness LED and RGB sensor are used in the TRO concentration measurement system. The high-brightness LED emits white light, and the RGB sensor can measure the intensity of the light source by separating the red, blue, and green light sources [
15,
16,
17]. In this way, if the green and blue wavelengths are used among these types of wavelengths, it is possible to measure the TRO concentration with more than double accuracy even at high concentration (over 10 mg/L) [
18,
19]. However, in these semiconductor devices, an output error of the light source and a sensing error of the RGB sensor were made due to the manufacturing process, durability, and environmental factors [
20]. This error reduces the measurement accuracy of the TRO concentration. Therefore, precise correction of the light source and RGB sensor is required for accurate TRO concentration measurement. In addition, in the LED light, the intensity of the light source decreases in inverse proportion to the turn-on time, which is called LED aging [
21,
22,
23]. The most representative cause of LED aging is the internal LED temperature [
24]. As the internal temperature of the LED increases, the intensity of the light source decreases and reaches a constant output after a long period of time [
25]. Conversely, when the LED light is turned off, the intensity of the light source gradually recovers over time. However, the DPD reagent used to measure the TRO concentration variation color over time causes low measuring accuracy [
26]. For this reason, it is necessary to minimize the turn on/off time of the LED light and to derive the optimal sensing point.
In this paper, we propose a new calibration strategy for LED modules to improve the measurement accuracy of TRO concentration. Through the proposed controller and algorithm, the measurement accuracy for TRO concentration can be greatly improved. We conducted these experiments in various seawater environments with the manufactured TRO concentration measurement system. The conventional TRO concentration measurement method and problems are reviewed in
Section 2. The strategies to improve measurement accuracy for TRO concentration are presented in
Section 3.
Section 4 presents the experimental setup.
Section 5 presents the experimental results and discussion. Finally, the conclusion is given in
Section 6.
2. Conventional TRO Concentration Measurement Method and Problems
The conventional TRO concentration measurement sequence based on the DPD colorimetric method is shown in
Figure 1.
Firstly, the white LED light is primarily turned on in the sample solution while blocking the light coming from the outside. The maximum current applied to the white LED light is 30 mA and at this time it has 7000 mlm. The light source passing through the sample solution can obtain the intensity of light for each red, green, and blue wavelength region through the RGB sensor. The RGB sensor is a semiconductor device that converts light energy into electrical energy. As the intensity of light increases, a higher frequency is generated and it is output in the form of a square wave with a 50% duty rate. To increase the resolution of TRO concentration measurement, the output frequency of the green wavelength region (510–520 nm) and blue wavelength region (460-480 nm) is measured. Thereafter, adding the DPD reagent to the sample solution, the white LED light is lit once again. In the same way, we record the output frequencies of the green and blue wavelength region. The absorbance is calculated by substituting the two types of output frequencies measured in the 1st and 2nd order to the Beer’s Lambert law and is shown in Equation (1). This law states that the negative logarithm of the ratio of the intensity of light incident on a material (
) and the intensity of transmitted light (
) is proportional to the absorbance of the transmission layer.
where
is the absorbance,
is the extinction coefficient,
is the thickness of the transmission layer, and
is the concentration of the solution. The Beer’s Lambert law can be used to determine the absorbance of a sample and compare it with a reference absorbance to derive the concentration. Equation (2) shows the process of calculating the TRO concentration through the absorbance.
where
is the reference of TRO concentration. The TRO concentration for each absorbance is calculated. Even if such TRO concentration measurement is repeatedly performed, a constant value must be calculated, and the outputs of a plurality of LED light and RGB sensors must be constant. However, each LED light and RGB sensor do not all have the same output, but have a slight error. This causes an error in absorbance.
Figure 2 shows the frequency output from a single RGB sensor when a constant current is applied to various LED light.
It can be seen that there is a difference in the output frequency even though the LED light is the same product. One of these can cause a slight error in the output spectrum due to the current bias passing through the inside of the LED light. In addition, the performance change of the LED light due to manufacturing defects, irregular light source output according to the roughness of the surface of the reflector, fine unevenness and irregular shape of the lens surface may change the output of the light source. In order to solve these manufacturing problems, a lot of time and cost are required. Therefore, careful calibration is required for each LED light and RGB sensor to increase the TRO concentration measurement accuracy. The calibration process is often performed only once at the time of shipment from the factory. In this case, LED aging occurs due to the repeated ON and OFF of the LED light, and the output of the LED light is reduced even when the same current is applied. This increases the serious errors for absorbance and TRO concentration.
3. Strategies to Improve Measurement Accuracy for TRO Concentration
In the case of an LED light, if there is a difference in output even when the same current is applied, our unique calibration method is possible by adjusting the intensity of the applied current. Through this, the absorbance and TRO concentration error for the LED light are reduced. In addition, if an LED light that exceeds the error range or outside of the calibration range is identified, it can be selected. In the case of an RGB sensor, the measuring difference which occurred was caused by the frequency values received from a large number of light sensors for the same intensity of light output from a reference LED light. This difference can be calibrated by adding a compensation coefficient for the corresponding frequency. As such, the selection process and calibration process for spectrophotometry are precise processes of repeatedly confirming reference parameters and measured values, and thus we had to do those manually. Due to the disadvantage, it takes a long time to perform the selection and calibration process only by hand, and there are practical difficulties in mass production and mass production.
To compensate for these shortcomings, the quick calibrating algorithm and the selecting LED light are needed. The calibration and selection algorithm are not performed only once in the initial stage, but is performed every TRO concentration measurement. Through this, we can measure and calculate the correct absorbance and TRO concentration.
The conventional measurement method is just measuring the frequency by applying a fixed current. This method is suitable for ideal water environment. However, commonly used solutions often contain impurities. In this case, it is impossible to obtain the accurate frequency value in the case of the conventional method. Therefore, an appropriate calibration algorithm is required. In this paper, we propose the accurate and quick frequency measuring algorithm by performing the proper and precise calibration and selection at the same time.
Figure 3 shows the proposed control algorithm that divides into Mode 1 and Mode 2. In the case of Mode 1, it consists of a PI controller and limiter. The frequency is measured by the RGB sensor. The reference frequency is 30,000 Hz, and it is controlled by the reference frequency and the measured frequency. When the output frequency reaches 30,000 Hz through Mode 1 operation, the aging compensator works. The output of the LED is maintained in a normal state through the aging compensator. Mode 2 operation operates based on the current value when the output frequency is 30,000 Hz. It is composed of a PI controller and limiter and can follow the reference output current.
3.1. LED Module Calibration Algorithm
Figure 4 shows the flow chart of the proposed control algorithm. The flow chart is divided into Mode 1 and Mode 2. When the algorithm starts, it measures the current and frequency. The PI controller operates through the value of the frequency and operates until the value of the reference frequency and the value of the output frequency are the same. If the reference frequency is matched, the output current value is saved as the reference current. If the reference current is determined, Mode 2 operates, and Mode 2 follows the reference current value through the PI controller. The reference current follows the value and, after operation, the output of the LED is maintained in a normal state through aging compensation. It operates until the output current matches the reference current, and when the output current and the reference current are just the same, the algorithm operates.
The correction data derived through the proposed algorithm can increase the accuracy of TRO concentration measurement.
Figure 5 shows the TRO concentration measurement sequence after applying the proposed algorithm. First, select the reference LED module and RGB sensor whose output green frequency of LED light becomes 30,000 Hz for the input current value.
Using this model, we collect TRO concentration data according to absorbance. These data are used as reference values when finally measuring the concentration. For the uncalibrated LED module, the sample solution is irradiated with LED light. If an error occurs in the output green frequency, the optimal output current value is found through the proposed algorithm. This process is carried out in Mode 1. Then, the second LED light is irradiated with the output current value optimized for the sample solution mixed with the DPD reagent. Accordingly, it is possible to calculate the absorbance of the sample solution and derive a precise TRO concentration.
3.2. LED Module Calibration SIMULATION with Simulink
The LED light intensity is based on the reference light source. In order to emit the same light intensity of each light source, a calibration process is performed by adjusting the current value of the LED. The proposed algorithm suggests current calibration through the PI controller. The control process was verified through Simulink.
Figure 6 shows the proposed algorithm and also simulates the control algorithm by using Simulink. The basic configuration consists of a PI controller, limiter, reference frequency, and TRO sensor. In the case of this system for mass production, the Kp and Ki gain values were selected through tuning during the manufacturing process. In the case of the TRO LED sensor, the ratio of brightness is slightly different depending on the current, depending on each sensor. Therefore, in this paper, accurate current can be calculated by applying the PI controller.
Refer to
Figure 6, it shows the Simulink simulation. The main indicators of the graph are composed of error, reference value and output value, and current value (for control).
Figure 7a is the difference between the reference green frequency and the output green frequency, that is, the error. Although an error occurs initially, it can be seen that the error converges to zero by the PI controller.
Figure 7b is the graph comparing the reference green frequency and the output frequency. Refering to the graph, it can be seen that the value of the initial green is different from the standard. It can be confirmed that the correction algorithm converges to the reference value.
Figure 7c is the calibrated current value, and the brightness of the light source can be adjusted by the current value. Therefore, it can be seen that the output varies according to the current value, which is the control value, and converges to approximately 12,500 uA through the graph. In the case of the current value, different values are selected depending on the light source, but the output green frequency converges in the same way.
The current and error value are selected depending on the light source, but the output green frequency converges in the same way.
3.3. The Solution about LED Aging Effect
In the case of an LED light for measuring TRO concentration, a constant light source must be output for absorbance measurement by spectrophotometry. For quick TRO concentration measurement, the intensity of the LED lights should be at a constant value regardless of the time from the first light emission to the end. However, when a constant current is applied to the actual LED light, the intensity output from the LED light decreases with time. This phenomenon is the same for green and blue light. This case is shown in
Figure 8. When light is emitted and heats up, it affects both the life cycle and the luminous flux of the LED. Therefore, the longer the LED is turned on, the more severe the heat. The decreasing intensity of the LED light starts to output a constant value after around 50 s. However, it is not possible to wait until the LED light is stabilized for a long time of several tens of seconds or more when measuring the TRO concentration. The intensity of the light source should sustain the same output when the LED is turned on in the shortest possible time (1~3 s) and then turned on again after an OFF period of emptying and refilling the water. In other words, it is necessary to derive the optimized LED ON/OFF time so that the LED ON time is ON for 1~3 s while the OFF time is short.
When the intensity of the LED light was measured when the LED was turned on for a long time, the value was lower than the reference value. In other words, the longer the LED is turned on, the more the green frequency value decreases. This is caused by a decrease in the LED light output due to an increase in the temperature inside the LED.
Since the intensity of the LED module decreases due to the influence of temperature, it is required to specify a section that can minimize the influence of temperature for accurate green frequency measurement. In addition, it is necessary to identify the time point at which the temperature of the LED module recovers until the next measurement after one measurement, and also consider the period.
As mentioned above, the ON time of the LED should be as short as possible and the OFF time of several seconds should be maintained. Accordingly, the ON time of the LED was set to about 1 to 3 s, and the optimum OFF time minimizes the green frequency error.
4. Experimental Setup
Figure 9 shows the experimental setup of the proposed TRO measurement system. The experimental environment consists of LED, sensor module, and LED driver. An oscilloscope and Code Compose Studio were used to measure the experimental data. The solution used for the experiment is injected through the device to which the sensor module and LED module are attached. Basically, the output of the sensor measures the frequency of the sensor through the light transmitted through the liquid from the LED. The frequency is measured through an oscilloscope and Code Compose Studio.
Figure 10 shows the proposed calibration algorithm controller. The proposed controller consists of DC–DC converter, LED driver and DSP (TMS320F28335). The DC–DC converter is configured to supply power to the LED Driver and DSP. The algorithm operates by measuring the frequency and output current values measured through DSP. The control value of the algorithm is applied to the LED driver, and the light of the desired output can be transmitted through the solution and measured by the sensor.
For the LED module, the OVFSW6C8 model with 4 Pin LED (7.6 mm) from Electronics is selected, and it is designed with a high forward voltage to maximize the brightness and efficiency of the light source together with a low-profile lens. In addition, the response characteristics are good and the power consumption is small. The radiation angle of the light source is 60°, and the beam has a maximum of 7000 mlm when a current of 30 mA flows through the LED module.
The applied RGB sensor is TAOS’s TCS3200 model, which outputs a specific frequency for each RGB light. The four types (colors) of photodiodes are interdigitated to minimize the effect of non-uniformity of incident irradiance. The TCS3200 programmable color light-to-frequency converters that combine configurable silicon photodiodes and a current-to-frequency converter on a single monolithic CMOS integrated circuit. The output is a square wave (50% duty cycle) with a frequency directly proportional to light intensity (irradiance). The nonlinear error is 0.2% at 50 kHz, and the temperature coefficient has a stable value of 200 ppm/°C. The response time of photodiode is normally under 0.1 µs.
Table 1 shows the specifications of the LED module and RGB sensor.
5. Results and Discussion
In order to increase the accuracy of the experiment, the number of LED module samples was set to 30.
Figure 11 shows the variation of green frequency before and after calibration of LED modules and the current flowing through the calibrated LED module. It indicates that the intensity of light output from each LED light is different when the same current is passed. First, an initial set current (12,500 uA) is applied to each LED module. It can be seen that there is a large difference in the intensity of the LED light through the output green frequency.
In order to visually check the calibration algorithm for the LED module, the green frequency output from the RGB sensor was checked with an oscilloscope.
Figure 12a shows the green frequency output of the LED module before calibration. LED module 1 displays a frequency close to the reference, while LED modules 2, 3, and 4 output a frequency lower than the reference frequency.
Figure 12b shows the green frequency output that passed the Mode 1 process of the proposed algorithm. It can be seen that the LED modules, which had a low frequency, output a green frequency similar to the standard. As a result, it is considered that the performance of the proposed algorithm Mode 1 is greatly effective.
In the case of the calibrated LED module, the output green frequency is almost constant, and it can be seen that the applied current is different accordingly. The procedure for calibrating the LED module corresponds to Mode 1. Additionally, the Mode 2 process was performed by adding DPD reagent. TRO concentration was measured at two points (1.4 mg/L, 3.7 mg/L). The green frequency was obtained by irradiating the secondary LED light, and the TRO concentration was derived by calculating the absorbance.
Figure 13 shows the measured TRO concentration and the concentration error with respect to the reference value. It can be seen that the 30 LED modules used in the experiment have high accuracy close to the reference TRO concentration.
The accuracy and precision were significantly improved compared with the conventional TRO concentration measurement through multiple LED module calibration. The results are shown in
Table 2. The average measured green frequency was 29,021 Hz before correction and 30,073 Hz when the proposed algorithm was applied. It is closer to the standard 30,000 Hz. The maximum error of TRO concentration before correction was 31.9%, while the application of the proposed algorithm reduced the error of TRO concentration by 2.2%. The conventional DPD colorimetric method has 4% and 0.3% values for accuracy and precision, respectively. As a result of testing with 30 calibrated LED modules, the accuracy of the average TRO concentration was significantly improved from 6.56% to 0.86%, and the precision from 9.54% to 0.10%. This result satisfies the accuracy of TRO concentration within 5% and precision within 2%. The proposed algorithm has higher accuracy and precision compared to the conventional DPD colorimetric method and no calibration.
The water environment, which is generally measured through the TRO concentration measuring device, does not always have a constant turbidity. Since the water quality environment in which this device will be used continuously should be able to measure from low turbidity to high turbidity, a TRO concentration measurement experiment was conducted in the range of 1~850 NTU turbidity.
Figure 14 shows the experimental results for measuring TRO concentrations of 1 mg/L, 4.2 mg/L, and 8.1 mg/L with turbidity, respectively. When the proposed algorithm is not applied, the higher the turbidity, the lower the TRO concentration compared to the standard occurs. However, when the proposed algorithm is applied, the TRO concentration appears close to the reference value even if the turbidity increases. It was proven by the above experiments that the proposed algorithm can derive the correct TRO concentration without affecting the turbidity. Detailed data collected in the experiment are referenced in
Appendix A. The measured average accuracies at low, medium, and high TRO concentrations according to turbidity are 1.97%, 1.62%, and 1.23%, respectively. We demonstrate and prove that the precise TRO concentration was measured by our proposed algorithm in various turbidity environments and TRO concentration range.
In order to solve the problem of reducing green frequency output due to LED aging, the optimal LED module ON and OFF times were derived. First, turn on the LED for calibration of the LED module, and secondly turn on the LED to measure the TRO concentration. The time to turn on the LED was set for 1, 2, and 3 s, and the time to turn off was set to 0, 3, 5, and 10 s. The obtained results are shown in
Table 3. By comparing with each variation rate, we know that at the LED ON time of 1 s and the OFF time of 10 s, the variation rate is the lowest compared with the initial green frequency value. If this operating time is exceeded, some errors may appear in the TRO concentration measurement process. Therefore, for optimal TRO concentration measurement, it is desirable to maintain the turn on time of the LED module for 1 s and the turn off time for 10 s.
6. Conclusions
In this paper, we propose an LED module calibration strategy to improve the measurement accuracy of TRO concentration. The algorithm for controlling the LED current (Mode 1) is primarily operated to calibrate a number of LED modules, and the LED current is controlled by the algorithm (Mode 2) for measuring the TRO concentration. As a result, the TRO accuracy before performing the algorithm was 6.56% and the precision rate was 9.54%, but after applying the algorithm, it improved to 0.85% and 0.10%, respectively. In addition, the optimal LED turn-on time and turn-off time were determined to improve LED aging. An optimal operation sequence could be designed at the turn-on time of 1 s and the turn-off time of 10 s. As a result of measuring TRO at low, medium, and high concentrations with the proposed algorithm in various turbidity environments, average accuracies of 1.97%, 1.62%, and 1.23% were obtained, respectively.