Society of Robots - Robot Forum
Electronics => Electronics => Topic started by: pete2009 on June 24, 2009, 12:20:04 PM
-
I see most board provide a ton of digital and only a few analog inputs. I have a proble there. Collision sensors, photo diodes and similar devices have analog outs.
Why is the digital more popular then?
-
Can't you use digital as analog??
-
Hi,
While I don't know the answer to that question, I stand corrected on my initial assumption. There are a few rangefinders there with a digital connection.
-
Digital input are quite simple; but analog inputs are far more complex and take a lot of space on the chip.
If you need more analog inputs, look at analog multiplexer or external ADC like this one http://cds.linear.com/docs/Datasheet/2309fb.pdf (http://cds.linear.com/docs/Datasheet/2309fb.pdf) or this one http://www.analog.com/static/imported-files/Data_Sheets/AD7992.pdf (http://www.analog.com/static/imported-files/Data_Sheets/AD7992.pdf)
Can't you use digital as analog??
Unless you meant to use them to access external DAC, I don't see how it is possible. Analog inputs can often be configured as regular digital I/O, in this case the analog/digital converter is completely bypassed.
Hi,
While I don't know the answer to that question, I stand corrected on my initial assumption. There are a few rangefinders there with a digital connection.
Digital rangefinders have a digital (!!!) output. They have a predefined range and outputs a 1 (or 0 I don't remember) when they sense an object in this range. You cannot get the actual distance of the object though, as opposed to analog rangefinders.
-
hi,
Digital input are quite simple; but analog inputs are far more complex and take a lot of space on the chip.
i totally agree with chelmi.....
If you need more analog inputs, you can use multiplexers.
But if you are using collision sensors and obstacle detectors, you don't need continuous measurement of the voltage. you just need to know when you are about to hit the obstacle! so generally we use comparators. They give you digital outputs, compatible with the controller boards. so you don't have to worry much!
-
A comparator will give a 'high' or a 'low' output when the input voltage crosses a fixed reference value. there are lots of ready made comparator chips available.
More over, there are lots of microcontrollers with built in comparator modules (Eg: PIC16F877A). this can reduce your hardware........
-
Hi,
Can't you use digital as analog??
Yes, in several ways, but the one I would recommend you for real analog (i.e. not just a comparator or a compare register), is a V/F converter (V/F = Voltage to Frequency) - then you just measure the frequency of the signal and multiply the number with a constant.
-
oh.... thats a good idea. But how do i convert a voltage into a signal with varying frequency? by using a tank circuit or something?
-
most common example..... NE555....
But there are many specialized IC's for that....