SparkFun Forums 

Where electronics enthusiasts find answers.

General project discussion / help
Did you make a robotic coffee pot which implements HTCPCP and decafs unauthorized users? Show it off here!
By ENCanes
#199412
Long-time Lurker First-Time caller

I'm trying to repurpose this 7 button PCB for my current project, the only issue so far is I have no Idea how to hook it up. As yall can see from the pictures below it consist of 7 momentary switches and a few passive resistors, diodes and a capacitor or two yet only has a two wire hookup.

Is this able to generate a signal other than high/low for the entire board? If so, can I read this data with an UNO(I also have a pro mini on hand)so I can assign functions?

Thanks in advance for any advice you can give.

Charlie

p.s.
If these images are too big please let me know. Some forums have policies against full sized pics but its hard to read a chip number onscreen as is.



Image
Image
By madbodger
#199510
It looks like a resistive divider chain, where the switches shunt the resistors in various patterns. The idea is that if none of the switches are pressed, it presents a certain resistance (possibly infinite), and pressing the switches changes that resistance in various ways (likely making it lower). To read it with an ordinary microcontroller, I'd probably make a voltage divider. Hook the supply voltage to a fixed resistor, hook the other end of that resistor to one lead of the board and an ADC pin, and the other lead of the board to ground. Then reading the ADC will give different values depending on which (if any) button is pressed. The value of the upper resistor would depend on the values of the resistors on the board, a workable first choice would be on the order of twice the lowest resistance on the board. There's a writeup of the technique here: https://electronics.stackexchange.com/q ... stor-value