Pages: [1]   Go Down
Author Topic: analog multiplexing and sensors  (Read 724 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 all,

do you believe there will be latency issues if you combine 8 sensors in a single analog input (using multiplexer) ?

has anyone tried?

I assume latency is not a problem if you use faders or pots with multiplexers...
but what about sensors?

thanks,
warp
Logged

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

What kind of sensors ?

If they put out a voltage you read from an analog input, it is the same as reading a potentiometer.

I have used 16 potentiometers on 2 multiplexed analog inputs and had no problems with latency.
Logged

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

hi MikMo,

it's good to hear you had no problem...

I's just thinking it might be a problem in a real-situation, say an installation, where all the voltages will change rapidly and continuously.

did you use the multiplexers with potentiometers or sensors?

Logged

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

I use 16 slide potentiometers. I haven't done any serious stress testing to see how fast you can change the potentiometers and still get reliable readings. My project is only in the initial phase. The multiplexer is the first submodule i build. I made a small PCB for it. I will post a complete step by step "how to" as soon as i get some time. But it is basically just two CD4051 IC's, and some kode based on the 4051 example in the Playground.

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

thanksMikMo.

I've already order 16 fades to start with (x2 multiplexers) but my main aim is to make it work with other input devicces (mainly sensors).

Anyone ever tried to use sensors with multiplexres??

thanks,
warp

Logged

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

I have now made som more tests.

I have written a small program on my PC and i have setup Arduino to read the 16 potentiometers send their values to the PC program. I read the potentiometers and send the values every 10 ms and it doesen't seem to be a problem.

If the sensors you were thinking about using are the kind that send out a voltage (like my potentiometers do) i can't see why you shouldn't be able to read them just as fast.

One thing to note is that right now i don't do anything with the values on the Arduino, i just send them. In a real life situaton some processing would probably take place in the Arduino program, using a little more time.

MikMo

http://www.mikmo.dk

EDIT: I tried at serial speeds of both 9600, 19200 and 38400. The PC program seemd to be a little less responsive at 9600. 19200 and 38400 worked fine.
« Last Edit: October 30, 2007, 02:01:13 pm by MikMo » Logged

Pages: [1]   Go Up
Jump to: