Pages: [1]   Go Down
Author Topic: arduino and multipel analog inputs  (Read 301 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 70
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

hi,

can Arduino accept various analog inputs (sensors, pots, ultrasound sensors, etc) using the same code...?

...or each input should be programmmed differently in order to accept specific inputs?

in other words, can I programm Arduino so as the 1st analog input can accept either a pot or a sensor or an accelerometer
or whatever??

thanks,
warp
Logged

Copenhagen / Denmark
Offline Offline
Edison Member
*
Karma: 5
Posts: 2360
Do it !
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

If i understand your question correct, you want to swap sensors / input devices on the fly ?

It cold be possible, but only if the sensors / input devices act in the same way. Analog input read resistive devices like potentiometers, or devices that send out a voltage between 0 and 5 volts.

Some sensors are read in a different way.

If all your sensors are in the first group, then technically you coild swap the on the fly, but there would probably be issues with sacling amd converting the input.

MikMo
http://www.mikmo.dk
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 70
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi MikMo,

do you any input devices that are read in a different way?

As far as I'm concerned most sensors and potensiometers send a 0-5V voltage?
am I missing something??

thanks,
warp
Logged

Brisbane, Australia
Offline Offline
God Member
*****
Karma: 1
Posts: 593
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

There are plenty of things like temp sensors which run off the I2C bus which uses a digital signal instead of analog.
Logged

Pages: [1]   Go Up
Jump to: