Jan,
Im not new to programming but im a noob.
A little background
So im making a color sorter that can sort skittle/M&M etc. by color.
To detect the color i use a TCS230 color sensor. which i setup with this guide. (https://www.electronicshub.org/raspberry-pi-color-sensor-tutorial/)
The Problems
On that page are 2 codes 1 is raw colors and 1 is color detection.
I get the raw color to work but it outputs/print values that are way above the 20000 some even 37000.
and the other code the color detection code keeps giving me errors telling me
"runtimewarning: this channel is allready in use, continuing anyway. Use GPIO.setwarnings(false) to disable warnings.
GPIO.setup(s2,GPIO.out)"
What I tried
So since both codes are bassically the exact same and raw color doesnt give a warning I compared them to see if anything is diffrent or maybe a typo was made. But no they are the same exept for 1 line but i dont think that causes it.
And for the problem that i get to high values. I had no sollution.
I tried to find other sites covering this sensor and a raspi but i couldnt find 1. i also checked for just a color sensor and pi so a bit less specific but no luck.
So I hope i explained it as good as possible. im currently stuck because i dont know how to convert raw values to rgb and i get errors.
i hope anyone can help me get this project done.
Kind regards Gert-Jan
question from:
https://stackoverflow.com/questions/65927884/tcs230-color-sensor-not-working-propperly-on-rpi3-way-to-high-values 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…