Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
TCS3200 Color SensorIntroduction | ||||||||
Line: 83 to 83 | ||||||||
time.sleep_ms(10) will wait forever, if the number of cycles to be measured, is never reached. This can happen e.g. if the OUT signal is assigned a wrong GPIO pin. The problem can be solved by starting a timeout counter when the measurement is started. This counter can be used to raise an exception if reaching the _cycles limit takes too long. | ||||||||
Added: | ||||||||
> > | timeout.py is the same program as meas_freq.py with the timeout counter added. The timeout is set to 2s. The number of cycles to be measured is set to 10000 in order to provoke the timeout. | |||||||
Calibration | ||||||||
Added: | ||||||||
> > | The formula for the calculation of rgb values is given by:
component = max * (Fv - Fb) / (Fw - Fb) where the variables have the following meaning:
Detecting colors | |||||||
-- ![]() Comments |