Current Comparator with Digital Reference: F/V vs DAC cost/parts?

Thread Starter

johnyradio

Joined Oct 26, 2012
615
(Edit: Apologies for revision, but i realized i don't need V/F or ADC, just V/F or DAC)

I need to compare a current to an external reference current. The reference current must be isolated, so i plan to use either a frequency with F/V, or binary data with a DAC.

1725928089448.png

What can be done more cheaply/fewer parts, @ 1,000 volume?

8-bit DAC
vs
F/V converter at equivalent resolution (about 0.39% or 3,906 ppm)

I found some prices online, but i suspect there may be cheaper ways to do it. PLL? Op amps? 555? Single transistor?

The LM2917M F/V is about $0.80 @ 1,000.
https://www.ti.com/product/LM2917-N/part-details/LM2917M/NOPB

TI has several sub-$0.50 DAC's.
https://www.ti.com/data-converters/dac-circuit/products.html#sort=1130;asc&

I think it will be cheaper with binary control than frequency control. Here's my current plan:

1725939111658.png

I'm not opposed to using a uC if it can be done cheaper than a DAC chip, but otherwise would prefer to eliminate programming.
 

Attachments

Last edited:

Ian0

Joined Aug 7, 2020
13,097
What can be done more cheaply/fewer parts, @ 1,000 volume?

8-bit ADC
vs
V/F converter at equivalent resolution (about 0.39% or 3,906 ppm)

and same question in the opposite direction: DAC vs F/V converter (at compatible frequency to the V/F)

I found some prices online, but i suspect there may be much cheaper ways to do it. PLL? Op amps? 555? Single transistor?

The LM2917M F/V is about $0.80 @ 1,000.
https://www.ti.com/product/LM2917-N/part-details/LM2917M/NOPB

555
https://www.electronicdesign.com/ar...onverter-delivers-robust-accurate-performance

V/F
https://www.next.gr/converters/voltage-to-frequency/index2.html

VCO
https://www.digikey.com/short/djzr7trh
It depends on what else is in the project. If it needs a microprocessor than an A/D comes for free these days.
 

panic mode

Joined Oct 10, 2011
4,867
yes... and i did that some 25 years ago. while it worked it was not as simple as one may expect:
need voltage reference of course
each DAC input need to be pulled high (to Vref) or low (0V). cannot be left open so driving with open collector or comparator does not work. so each input need to be buffered, then output also need to be scaled/buffered.
in the end considering parts count, board size, ease of troubleshooting, ease of modifying, linearity, temperature stability, time spent etc. i do not think it was worth it then. and today with MCUs being dirt cheap, i would say this option would be low on my list of options. just the flexibility to modify things in code when needed makes all the difference, but... that is just me.
 

Thread Starter

johnyradio

Joined Oct 26, 2012
615
If you wind up with more than two chips, a micro would likely be cheaper, smaller and simpler, even if it does nothing more than what your several chips do.
I need to compare a current to an external reference current. The reference current must be isolated, so i plan to use either a frequency with F/V, or binary data with a DAC.

This post is about digital to current. My desired functionality is shown here. This post is about the Black Box.

1725927090838.png

To implement, I plan to use a current sensor to convert the internal current to a voltage, and use a voltage comparator, not current comparator.

1725926983225.png

What format is it in? If it is RS232 you will probably need a micro to receive it.
I control the external system, so i can provide any desired format, but must be serial.

What is the desired input frequency range, response time and supply voltage?
Frequency: If the external signal is a frequency, then anything between 100kHz and 400 kHz, to avoid interference with external audio, digital audio, and wireless systems. Frequency isn't relevant if i'm using binary data.
Response time: If you mean Sample Rate, the external binary will change around once per second, in other words, don't care.
Supply voltage: i control the external system, so i can provide any desired voltage.
 

Attachments

Last edited:

sparky 1

Joined Nov 3, 2018
1,218
The needs of the application many times is the output type.
For example, a cheap handheld DSO has sufficient sample rate to display a waveform, sort of.

Arduino internal ADC is slow like buying a drill that turns 10 rpm. ok for learning, outputting a voltage from a simple set of values in various ways.
In contrast a 32 bit micro controller running at 64Mhz will handle the faster sample rates.
A midi library like micro python will produce very detailed sound and effects on wave files.
 
Last edited:

Thread Starter

johnyradio

Joined Oct 26, 2012
615
a 32 bit micro controller running at 64Mhz will handle the faster sample rates.
The midi library for micro python will produce sound and effects on wave files, any good? depends on the programming.
Clarification:
If the external signal is a frequency, then the Black Box will be an F/V, in which case the external freq must be between 100kHz and 400 kHz.

But if the external signal is binary, then disregard that frequency-range, it isn't relevant. For binary, i'll be using a DAC. DAC sample rate can be quite slow, eg. once per second.

I have no need for midi or sound effects. All audio is external to the circuit in question.

At the moment, the cheapest, simplest approach seems to be binary, with a $0.40 DAC.
 
Last edited:

nsaspook

Joined Aug 27, 2009
16,251
Clarification:
If the external signal is a frequency, then the Black Box will be an F/V, in which case the external freq must be between 100kHz and 400 kHz.

But if the external signal is binary, then disregard that frequency-range, it isn't relevant. For binary, i'll be using a DAC. DAC sample rate can be quite slow, eg. once per second.

I have no need for midi or sound effects. All audio is external to the circuit in question.

At the moment, the cheapest, simplest approach seems to be binary, with a $0.40 DAC.
The $0.40 DAC has a i2c interface, so it's designed to interface with a controller if you need something beyond simple alarm tones.
https://www.ti.com/lit/ds/symlink/d...data-converters%2Fdac-circuit%2Fproducts.html

1 Features
• 1 LSB INL and DNL (10-bit and 8-bit)
• Wide operating range
– Power supply: 1.8 V to 5.5 V
– Temperature range: –40°C to +125°C
• General-purpose input (GPI) based function trigger
• PMBus™ compatible I2C interface
– Standard, fast, and fast mode plus
– Four device address options configured using
the broadcast address
 
Top