P0 RCTIME Question
So I just recently wrote a program that makes P0 and P7 touch sensitive on the BASIC Stamp Homework Board (http://aldude999.net/Downloads/Touch.bs2 if you're interested, just plug a wire into P0 and put the other end in the air, and do the same on P7. Also put a speaker on P15. Touch P7 to test and P0 to enter Configuration mode) and I've been playing with it, but I've noticed something odd. If I use P0 I get random readings anywhere from 0-2400, but if I change it to something like P2 it generally stays around 0 and 1. Is this because of noise, or is it possible this pin is messed up?
Thanks in advanced for any help.
Thanks in advanced for any help.
Comments
There's no fundamental difference between P0 and any other I/O pin. If you follow the PCB traces on the Homework Board, you'll see that there's little difference between P0 and any of the other I/O pins in the first group of 8 (P0-P7).
I notice in your program that you "hard coded" I/O pin 0 and I/O pin 7 in various HIGH and LOW statements, yet use a constant PIN name for the RCTIME statements. You really should use the same PIN name in the HIGH and LOW statements. If you change RC without changing the other statements, it won't work.
Oh, nice catch. Fixed.
Alright. I was just wondering if I had possibly messed up the pin with a previous experiment with diodes and reading temperature. Oddly, now Pin 0 reads 0-1 with the rest of the pins, so I guess whatever it was is gone now.
Thanks again.