A little friendly chat is never a bad idea. After all it was me who asked for a description, remember?
Re "Cool idea": Well I don't know what you mean, maybe because I am not the youngest. Please explain.
I just added the ldr and unfortunately the +5V->LDR->IO-Pin-idea does not work. The voltage levels are not within the specified High/Low-Levels of the PIC. I found that Light means 1kOhms and None means from 8-16kOhms.
So I added a resistor of 4.7kOhms:
+5V->LDR->IO-Pin->4.7kOhms->Mass. Now there are voltage levels of about 3.2 and 2.3 Volts, which is still not within the specification.
Now I am planning to use the integrated Comparator but I do not know how, yet. What are the fuses?
On a 16f628 I guess it is CMCON=%11001010 for the PIN on RA2 but what about VREF. How to activate that in the high range?
Bookmarks