Forum 2005-2010 (read only)
Syntax & Programs
Topic: Shift Register
(Read 363 times)
May 30, 2006, 03:35 pm
I'm trying to build a carpet of 50 pressure pads sensors using and Arduino and Processing.
In order to do that I'm using a shift register (TEXAS INSTRUMENTS model CD4021BE), but I dont know how to write the Arduino code to read the data from the register.
Untill now, I found and example in "Physical Computing" book, using the same shift register but with an example code for basic stamp or pic basic and BX-Basic.
I'm stucking with a way of doing the Shift in....
Can anyone help? please!!!!!!!!!!!!!!!!!!!!
Re: Shift Register
Dec 17, 2007, 11:58 am
It sounds like you need to be using quite a few analog mux IC's. You'd scan through them looking for a change. You'd be hard pressed to get enough pins on the arduino to run that many without expanding the digital IO as well.
This will run 8 of the pads and eat three digital pins for the address.
PulseIn flat out sucks as a command. Try and avoid it.
If it was designed by man it can be repaired by man.