Turning analog inputs into multi-switch digital inputs


Posted on Feb 4, 2014

I am interested in creating an interactive LED gameboard of some kind (or even a sort of `Stargate` DHD-type sci-fi prop!), where each square or tile is lit up from below by either a single white LED or an RGB combo. It always occurred to me that I`d love it if I could have each tile be responsive to touch. Nothing fancy, just a simple on/off switch.


Turning analog inputs into multi-switch digital inputs
Click here to download the full size of the above Circuit.

But the project I have in mind would either be 21 RGB tiles or 64 white or monochromatic ones. and that`s a lot of controllers! If I assemble a set of resistors, each selected to resist a discrete percentage of the total analog input voltage, and connect each resistor to a momentary switch, and put them all in parallel on the same analog input circuit, then each switch would lower the voltage by a different amount, and (with the right code, of course) that could be properly interpreted as the depression of that switch, and (for example) the appropriate LED could be illuminated! In other words, for example, if I have switches labeled A through H, and switch A allows the analog input to receive 0. 5V, and switch B allows the analog input to receive 1. 0V, and so on all the way up to H, which provides 8. 0V to the analog input, then it should be simple to write code that interprets each of these discrete voltage amounts as "representing" the depression of a particular switch, so that the rest of the code can respond appropriately. In fact, theoretically, if I come up with the right combination of resistors for each "column" of switches, I could even arrange it so that you could press more than one switch at the same time, and the code would recognize that unique new aggregate resistance properly as the combination of certain depressed switches! However, even if you *could* only press one button at a time - and that certainly...




Leave Comment

characters left:

Related Circuits

  • New Circuits

    .

     


    Popular Circuits

    High quality FM transmitter
    rs232 to rs485 circuit
    USB IR Toy
    ultrasonic transmitter circuit
    Moisture Sensor Project
    Water Level Sensor Circuit Using LM1830 Single Chip
    trigger
    relay driver board project
    Jammer circuit
    Valves structure operation and use
    Sinusoidal Oscillators



    Top