Question on interfacing GP2D12 with the BASIC Stamp 1 Project Board
haunteddansion
Posts: 68
Hi there, I am an industrial design college student and am trying to use the sharp GP2D12 IR sensors to give me an analog responce through my serial port in ascii format so I can use some software I am working on to read the ascii and use it to control a function on the computer. So basically I need to know if I can use the BASIC Stamp 1 Project Board, and what would the code look like to give my pc ascii code from the sharp GP2D12 IR sensors. Thanks for all the help for I am new to this and any diagrams and such will help.
Comments
·· You would need an Analog To Digital Converter (ADC).· As for the values, remember that this sensor is non-linear in it's output, and so will be your data.· On the other hand, if you use the BASIC Stamp 2, we have a ready-made program to read this, and all you would need would be the ADC0831 chip.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com
http://www.parallax.com/dl/docs/cols/nv/vol5/col/nv114.pdf
As for a BS1 example, we don't currently have one available.· You'd simply have to work through it.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com