Shop OBEX P1 Docs P2 Docs Learn Events
multiply inputs — Parallax Forums

multiply inputs

FlipperFlipper Posts: 1
edited 2006-06-07 12:37 in BASIC Stamp
Hi everyone,

I have been using Basic stamp's for ever. I need a multiplexer\or similar,·which can·read 16 inputs and convert them to four outputs.· If I can't do this, is there an even·easier way around multi inputing signals from different devices to a stamp or other.··The devices are all ON/OFF I have no need for data or interfacing.. I'm really after bi-directional Multiplexers to finish this development project.

Thanks,

Willy

Comments

  • stamptrolstamptrol Posts: 1,731
    edited 2006-06-07 11:59
    Willy,

    You can use any of the addressable "many-to-one" chips which allow multiple inputs to be selectively switched to one output. Usually available in 4 to 1 , 8 to 1 or 16 to 1 configurations. Sorry I don't have particular part numbers for you, but just look for multiplexers/demultiplexers. For bi-directional capability, look to analog switches, which are also availble in multiples.

    In practice you use perhaps 4 Stamp outputs as the address for the particular input number you want to check. What I usually do is read 4 inputs at a time with another nibble. This gives you the ability to read many inputs easily without using up your whole Stamp.
  • HarborHarbor Posts: 73
    edited 2006-06-07 12:11
    I can't tell if you're looking for analog multiplexers, Flipper. That's the most general answer, and it's certainly bidirectional. They pass logic signals even easier than analog stuff like audio, so you can use them for either purpose. For example, the Maxim 74HCT4051 has 3 address lines that control which of eight analog signals is passed to the output line.

    The 'enable' signal lets you pick which 4051 you enable, so you can use as many chips as you like to multiply the number of lines controlled by eight for each multiplexer. For sixteen lines, you need two 4051 chips. Say we use P5, P6, P7 and P8 to control which line is active. Connect P8 to the enable signal of both chips. Then connect P5,P6 and P7 to the address pins of both 4051s. Now you put the number of the line you want connect onto the nibble representing those four pins and that will turn on the line specified. You can connect it to another pin on the same stamp, to an analog circuit or whatever you like.

    Uh... not whatever. The usual precautions apply. Protect your stamp pins against programming errors. The resistance of one of these mux'ed connection is very low. The enable and address lines are just a logic interface, but you *will* burn out a stamp pin if it's set as output on the controlled line, and you connect it to ground through this mux. The idea of a mux is to switch the controlled lines for you and otherwise get out of the way, so they are designed to minimize their effect on the signal passing through. In other words, if one of the switched ends could ever lead to ground, you definitely want to put a couple of hundred ohms of resistance between that switched pin and the mux.
  • Beau SchwabeBeau Schwabe Posts: 6,559
    edited 2006-06-07 12:37
    The 4067B is the 16-Bit version of the analog multiplexor/demultiplexor

    The "ON" resistance is about 125 Ohms which does vary slightly with temperature,
    so if your application is sensitive to that you will want to compensate. This is true for
    the 4051B mentioned above as well.

    Reference:
    www.vincenzov.net/datasheet/2058.pdf

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
Sign In or Register to comment.