Shop OBEX P1 Docs P2 Docs Learn Events
infrared and ultrasonic sensors with basic stamp 2 — Parallax Forums

infrared and ultrasonic sensors with basic stamp 2

neaorneaor Posts: 4
edited 2005-10-24 18:08 in BASIC Stamp
Hi, im very new to the basic stamp2 and i was wondering if anyone could tell me if it is possible to hook 8 sensors to the stamp module, 4 of them being infrared and 4 being ultrasonic. i am unsure of how many channels that the stamp has to work with because the stamp lists it has 16 to work with but if each sensors uses an input and an output channel, then i am unable to use the stamp to control the motor speed. the infrared sensor i plan on using is a Sharp GP2D12 or something similar and the ultrasonic sensors would be something similar in terms of price and distance measuring capabilities. I would also need this stamp to process the speed for 3 or 4 different motors using pulse width modulation. I am using this stamp for a project for one of my classes. it is to serve as a microcontroller for a remote-controlled tank that has 2 motors for the wheels as well as 1 motor for the turret and 1 motor for the cannon. the sensors i mentioned above are to detect how close it is to an object. I would also appreciate some recommendation on the type of motherboard that i should attatch this stamp2 to keeping in mind that there is limited space inside the tank. Any advice would be greatly appreciated. Thanks.

Comments

  • metron9metron9 Posts: 1,100
    edited 2005-10-22 06:07
    Looks like the GP2D12 is an analog output device with 3 pins, ground, Vcc, and the analog output pin.
    You will need a ADC for each sensor and one pin for each sensor unless you use one ADC and multiplex the sensors
    and use just 1 stamp pin for the input.
    The infarred sensor receiver simply turns on and allows current to flow so one pin each would give on off or additional circuit with ADC for greater resolution.

    What parameters are you looking to monitor with the sensors.
    Distance, light levels, what resolution, per inch, per foot etc...


    Not sure what you have for motors, but servos can be controlled with just 1 pin each so it can be done.
  • don_sdon_s Posts: 35
    edited 2005-10-24 17:47
    "unless you use one ADC and multiplex the sensors and use just 1 stamp pin for the input. "
    Could explain this idea to me?· My electonics experience is severly lacking but this idea could help me with my problem.

    Thanks

    Don "Ho"

    ·
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-10-24 18:08
    As in this thread (http://forums.parallax.com/showthread.php?p=554853) this has been covered several times in the last week.· Quite simply put there are 4 channel and 8 channel version of the ADC0831 which can accomplish this without extra I/O lines.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
Sign In or Register to comment.