Author Topic: Sine to pulse conversion  (Read 5415 times)

0 Members and 1 Guest are viewing this topic.

Offline NikolaTopic starter

  • Newbie
  • Posts: 7
Sine to pulse conversion
« on: January 23, 2016, 09:10:25 pm »
Hello,

I have a hydraulic flow meter with -26V DC sine output signal with respect to GND. I have already made a frequency to voltage converter part for analog data acquisition but I do not understand which circuit I should use for converting DC sine signal to DC pulse.

I was thinking about using OpAmp but a separate power supply would be needed? 

Any suggestions ?    :-//
 

Offline andre_teprom

  • Regular Contributor
  • *
  • Posts: 71
  • Country: br
    • Aluis-Rcastro
Re: Sine to pulse conversion
« Reply #1 on: January 23, 2016, 09:18:36 pm »
which circuit I should use for converting DC sine signal to DC pulse.
Do you mean converting AC sine signal to DC pulse, right ?
As you mentioned, an OpAmp could do that, although I woud prefer a Comparator.
Anyway, you can easily make a simple IC based inverting circuit to generate a low power negative bus.


"Part of the world that you live in, You are the part that you're giving" ( Renaissance )
 

Online Dave

  • Super Contributor
  • ***
  • Posts: 1352
  • Country: si
  • I like to measure things.
Re: Sine to pulse conversion
« Reply #2 on: January 23, 2016, 09:28:12 pm »
What exactly are you trying to achieve? Give us more information, preferably schematics, datasheets.
What do you mean by -26V DC sine output? A sine wave superimposed on a -26V DC signal?
Why do you need to convert it to DC? Directly measuring the frequency would be much more accurate than any frequency to voltage conversion.
What frequency range are we talking about? Couple of kHz?
<fellbuendel> it's arduino, you're not supposed to know anything about what you're doing
<fellbuendel> if you knew, you wouldn't be using it
 

Offline alsetalokin4017

  • Super Contributor
  • ***
  • Posts: 2055
  • Country: us
Re: Sine to pulse conversion
« Reply #3 on: January 23, 2016, 09:42:57 pm »
Sounds like a perfect application for an Arduino and a voltage divider.

 :-DD
The easiest person to fool is yourself. -- Richard Feynman
 

Offline Psi

  • Super Contributor
  • ***
  • Posts: 9930
  • Country: nz
Re: Sine to pulse conversion
« Reply #4 on: January 23, 2016, 10:05:56 pm »
hehe yeah,

A voltage divider and MCU ADC channel would be my go-to method as well.
Unless there was some special need to do it in hardware.


As others have said, we need more specs,  what is the frequency range of this -26V signal?
« Last Edit: January 23, 2016, 10:12:11 pm by Psi »
Greek letter 'Psi' (not Pounds per Square Inch)
 

Offline TerminalJack505

  • Super Contributor
  • ***
  • Posts: 1310
  • Country: 00
Re: Sine to pulse conversion
« Reply #5 on: January 24, 2016, 12:32:14 am »
If I understand the requirements then an AC-coupled Schmitt trigger might do the job.

In this case I'm using a separate 5V supply for the comparator.  Mostly because I don't know the rest of the details.
 

Offline andre_teprom

  • Regular Contributor
  • *
  • Posts: 71
  • Country: br
    • Aluis-Rcastro
Re: Sine to pulse conversion
« Reply #6 on: January 24, 2016, 12:59:59 am »
The circuit above has the big advantage of eliminating the need of a symmetrical power supply, but considering that the net C1//(R1//R2) yields a time base of ~0,5s, additional care should be taken in regards to the frequency variation in order to prevent unwanted shift on the biasing line base of OpAmp reference.
"Part of the world that you live in, You are the part that you're giving" ( Renaissance )
 

Offline NikolaTopic starter

  • Newbie
  • Posts: 7
Re: Sine to pulse conversion
« Reply #7 on: January 24, 2016, 08:25:11 am »
The flow meter is a turbine with two, 90 degrees out of faze light or induction sensors. In theory it produces square signal but in reality it is more like sine (therefore sine DC  :-DD ). Frequency ranges between 250Hz and 2500Hz. Sorry, I forgot to add that to my first post.   

My f-U converter is 0.1% linear tested (that is excellent) and it is needed for interfacing to TI`s DAQ panel that we use. Only problem is that it does not work with any signal form except square. Problem is that you can set whole DAQ for just frequency or voltage inputs and as we have everything else working with voltage outputs a converter is needed.

I was thinking about Arduino but using one uC for this single operation seems wasteful for me. In my opinion it would be good replacement for IT DAQ as it can connect to matlab but we must use #proffessional equipment |O

Jack505- thank you ! I will test your circuit on breadboard...  :)
 

Offline SL4P

  • Super Contributor
  • ***
  • Posts: 2318
  • Country: au
  • There's more value if you figure it out yourself!
Re: Sine to pulse conversion
« Reply #8 on: January 24, 2016, 08:54:12 am »
You don't need an mcu at the basic level to convert sine to pulse, but if you want to modify the pulse timing withing the sine waveform period (timing, stretch, retriggering etc), it would probably be easier as a starting point.
Don't ask a question if you aren't willing to listen to the answer.
 

Offline Psi

  • Super Contributor
  • ***
  • Posts: 9930
  • Country: nz
Re: Sine to pulse conversion
« Reply #9 on: January 24, 2016, 09:11:10 am »
I was thinking about Arduino but using one uC for this single operation seems wasteful for me.

I always go for the lowest parts count. Which often means MCU, even for simple stuff.
Greek letter 'Psi' (not Pounds per Square Inch)
 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19492
  • Country: gb
  • 0999
Re: Sine to pulse conversion
« Reply #10 on: January 24, 2016, 09:23:33 am »
The circuit above has the big advantage of eliminating the need of a symmetrical power supply, but considering that the net C1//(R1//R2) yields a time base of ~0,5s, additional care should be taken in regards to the frequency variation in order to prevent unwanted shift on the biasing line base of OpAmp reference.
Yes, I'd advise making C1 10nF and some diodes connected from the -input to the supply rails would be a good idea to protect against overvoltage.
 

Offline TerminalJack505

  • Super Contributor
  • ***
  • Posts: 1310
  • Country: 00
Re: Sine to pulse conversion
« Reply #11 on: January 24, 2016, 05:26:24 pm »
Good suggestions, andre_teprom and Hero999.  For the sake of completeness, I've attached the updated schematic.

Note that the input signal's amplitude is still unknown so I used 1V peak-to-peak.
 

Offline NikolaTopic starter

  • Newbie
  • Posts: 7
Re: Sine to pulse conversion
« Reply #12 on: January 24, 2016, 07:55:26 pm »
Stupid me...  :palm:

Signal is offset sine wave (actually it should be a square pulse but it is smooth because of induction sensor) between output and 26V supply. Nothing fancy. Sorry for confusion but I was given some weird data and got confused.

So I have the rest of the circuit at supply voltage (via 7815) +15V and suply to meter is 26V. I hope there is all info for solving the problem. Jack505 can you correct the circuit in SPICE with that in mind for me please ?
« Last Edit: January 24, 2016, 08:58:40 pm by Nikola »
 

Offline TerminalJack505

  • Super Contributor
  • ***
  • Posts: 1310
  • Country: 00
Re: Sine to pulse conversion
« Reply #13 on: January 24, 2016, 08:39:03 pm »
So something like this then? 

Note that the output is inverted with respect to the input signal.  This might be a problem when there's no flow.  (And the input is grounded?)  The output would be held high in that case.

Edit: It looks like R1 and R2 can be eliminated in this circuit since the biasing is no longer necessary.
« Last Edit: January 24, 2016, 08:42:06 pm by TerminalJack505 »
 

Offline NikolaTopic starter

  • Newbie
  • Posts: 7
Re: Sine to pulse conversion
« Reply #14 on: January 24, 2016, 08:57:05 pm »
Signal is negative. It is between output and +26V.
 

Offline TerminalJack505

  • Super Contributor
  • ***
  • Posts: 1310
  • Country: 00
Re: Sine to pulse conversion
« Reply #15 on: January 24, 2016, 09:17:55 pm »
Sorry.  I guess I don't understand.   :-//
 

Offline NikolaTopic starter

  • Newbie
  • Posts: 7
Re: Sine to pulse conversion
« Reply #16 on: January 24, 2016, 09:56:40 pm »
Reference of a signal generator Vin1 in not tied to ground but to +26V  ;)
 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19492
  • Country: gb
  • 0999
Re: Sine to pulse conversion
« Reply #17 on: January 24, 2016, 10:52:34 pm »
Post a schematic.

It shouldn't matter if the sine wave is floating on top of +26V or -26V, if the comparator is AC coupled, it will just see the AC part of the signal, with the DC being rejected.
 

Offline TerminalJack505

  • Super Contributor
  • ***
  • Posts: 1310
  • Country: 00
Re: Sine to pulse conversion
« Reply #18 on: January 24, 2016, 11:39:09 pm »
So we're back to something like this.  (See attached.)

I changed the size of the feedback resistor used for hysteresis.  You get about +/- 100mV of hysteresis with this circuit.  You might want to change this based on the magnitude of the input signal.

Note that this circuit doesn't have a defined output when the signal stops oscillating.  It will be either high or low but there are no guarantees which.
 

Offline NikolaTopic starter

  • Newbie
  • Posts: 7
Re: Sine to pulse conversion
« Reply #19 on: January 25, 2016, 02:40:04 pm »
Thank you very much !  ^-^
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf