2017年2月17日星期五

LDR Camera in week 3



We have finished black-and-white part last week and this time we continued to generate colour pixels based on RGB colour mode, which is an additive colour model where red, green and blue lights are mixed in various ways to produce colours. The circuit was constructed by multiple arrays of colour sensors, each of which was built by 3 LDRs covered with a single colour filter. By utilizing the colour filters, the LDR was able to detect light intensity of specific colours. In theory, zero intensity for every component contributes to the darkest colour (black) while full intensity of all gives a white. We started from one single colour image and used three different colour filters to cover the LDRs. The circuit built is shown in Figure 1. The cardboard here was used for fixing the filters and ensuring that LDRs were covered entirely. 

Figure 1
Some modifications were made to our Arduino and UNITY codes and the resulting primary colour camera was shown below.  It can be seen in Figure 2 that when we covered pixels for blue and green while only permitted light to pass through red filter, the colour displayed on UNITY screen was red. The same testing was conducted for colour blue and green, with the result shown in Figure 3 and 4, respectively. 
Figure 2-Red
Figure 3-Blue
Figure 4-Green
The test for single colour element was successful and we continued to examine mixed colour elements. It is known that addition of red and blue gives purple while red and green products yellow, according to RGB colour mode. Our testing results were within expectation and are shown in Figure 5 and 6.

Figure 5-Purple
Figure 6-Yellow
Furthermore, we decided to generate one more colour image. However, in practical experiment, we found that when the camera was used to detect one colour, the two output image in UNITY was not exactly the same. This can be caused by environment effects since the quality of “white” relies on the nature of primary light sources. Hence, we need to properly calibrate and balance to obtain a neutral white matching the system's white point. After the primary calibration, the results became a step closer to our expectation. However, it seemed that this calibration was still not effective enough since there were still some distinctions of two colour displayed. 

Hence, our plan for next week is to explore the calibration method further, meanwhile, apply the multiplexer CD4051 to expand analogue ports.

没有评论:

发表评论