... | ... | @@ -67,6 +67,7 @@ The following four graphs show the data collected from using 10ms, 50ms, 100ms a |
|
|
![Alt attribute text Here](images/ex5_lp_grey.png)
|
|
|
|
|
|
From these 4 colors, it becomes apparent that the light percentages calculated using the given formula matches the measured values from exercise 1 very well. However, while the formula is hereby verified, the light percent is not as accurate as possible. The reason for this is that the calculated light percent from the sensor is stored as an integer, which does not take decimal numbers into account. This problem can be alleviated either by using 32-bit floating point numbers, or simply by using the raw values directly.
|
|
|
Note: once again, grey was affected by environmental light, and naturally should not be as high as white.
|
|
|
|
|
|
### Exercise 6
|
|
|
We tried to use text strings directly in the calls to ```LCD.drawString``` instead of the variables right and left. We used ```Runtime.getRuntime().freeMemory()``` to store the amount of free memory on the heap during the execution using the variables and during the execution using strings directly. This gave us the following two graphs.
|
... | ... | |