Author Topic: Level shifting  (Read 6113 times)

0 Members and 1 Guest are viewing this topic.

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #25 on: January 01, 2019, 09:35:35 pm »
OK, look forward to your schematic.
But honestly a lot of your problems relate to the breadboard. Those things are not usable for anything over 60 Hz, and certainly not for CVBS. Get a stripboard or something like that instead.
2.76 Vpp CVBS is high, but once it's loaded with 75 ohms it will drop to half. With the color burst on top, it's ballpark.

« Last Edit: January 01, 2019, 09:39:12 pm by Benta »
 

Offline syntax333Topic starter

  • Regular Contributor
  • *
  • Posts: 158
  • Country: 00
Re: Level shifting
« Reply #26 on: January 01, 2019, 10:52:34 pm »
I will try to build it to a stripboard as you said. Until then, I uploaded the schematics. Please inform me about the problems that you see on it.
 

Online BrianHG

  • Super Contributor
  • ***
  • Posts: 7660
  • Country: ca
Re: Level shifting
« Reply #27 on: January 01, 2019, 11:12:40 pm »
I will try to build it to a stripboard as you said. Until then, I uploaded the schematics. Please inform me about the problems that you see on it.
In a circuit I once done, instead of your mosfet (Q1), I used a 4066 cmos analog switch, the enable control input tied to the sync separator, and a trim-pot at 1 input, adjusting the voltage from 0-5v, and the other side tied to the video source after a 1uf cap, or 0.1uf cap, not 100uf (C3).  (Not if you want a true black level adjuster, tie the 4066's enable to the 'burst' output on the sync separator)
At that video point, I used a 2n7000 mosfet in a source-follower configured amp.  (video after 1uf cap tied directly to Gate of mosfet, 1k pulldown on Source which was video out)  (No Q2/Q3/R3)  I was then able to adjust the voltage output of the video to any level using the trimpot.
« Last Edit: January 01, 2019, 11:14:37 pm by BrianHG »
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #28 on: January 02, 2019, 10:46:33 am »
Several points stand out:
C3 is in the wrong direction.
CSOUT is active low, so your switch logic is wrong.
The MOSFET is HUGE! No wonder you get spikes when the puny LM1881 output has to drive all that gate capacitance. I strongly recommend a DG417 or DG419.
Your decoupling is somewhat lacking. At least you'll need 100 nF directly at the LM1881. 12V should also be decoupled.

Then let's see.
 

Online BrianHG

  • Super Contributor
  • ***
  • Posts: 7660
  • Country: ca
Re: Level shifting
« Reply #29 on: January 02, 2019, 11:38:10 am »
CSOUT is active low, so your switch logic is wrong.
Ooops, It's been so long.  In the case of my example circuit, you would need to invert the CSOUT before feeding the 4066's analog switch enable.
 

Offline syntax333Topic starter

  • Regular Contributor
  • *
  • Posts: 158
  • Country: 00
Re: Level shifting
« Reply #30 on: January 02, 2019, 12:11:46 pm »
I couldn't find any information about CSOUT being active low (at http://www.ti.com/lit/ds/symlink/lm1881.pdf section 7.3.1) are you sure about that?
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #31 on: January 02, 2019, 12:31:54 pm »
Page 3. Look at the timing graph.
 

Offline syntax333Topic starter

  • Regular Contributor
  • *
  • Posts: 158
  • Country: 00
Re: Level shifting
« Reply #32 on: January 06, 2019, 10:49:02 pm »
Finally I found time to build the circuit according to your recommendations. The problem was probably due to wrong switch logic and MOSFET as you stated.

After I changed the two of them, most of my problems are solved.

You can see the final circuit in attachments.

I have couple of problems.

1) As you can see from DS1Z_QuickPrint2 and DS1Z_QuickPrint3 signal is degraded. Shouldn't yellow signal and blue signal be the same? Is this due to low resistor value at follower circuit?

2) I get weird random spikes at output of the follower circuits (as seen in DS1Z_QuickPrint1 ) are those little spikes acceptable to an video display device? or should it be as clean as the input signal to follower circuits (blue signal)?

(I couldn't find any supplier that sells DG417 in my country however, according to BrianHG's suggestion, I tried to build the circuit with 4066.)

Also do you see any other problem at the circuit schematic?
 

Offline syntax333Topic starter

  • Regular Contributor
  • *
  • Posts: 158
  • Country: 00
Re: Level shifting
« Reply #33 on: January 07, 2019, 09:13:22 pm »
I have been able to solve the problem by changing 10kohm at input of the emitter follower with 1k and changing npn emitter follower resistor with 10k instead of 1k.

(Yellow signal is AV input signal and blue is output of the buffer)
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #34 on: January 07, 2019, 09:35:21 pm »
Congratulations, very impressive results!
After your getting the switch logic fixed, I also see that the LM1881 is now triggering reliably, probably due to better decoupling.
The sync/black/blanking levels are just as they should be, great!

The attenuation of the color carrier puzzles me. The emitter followers would normally not be able to cause this, they should be fast enough.

I'll put my thinking hat on. But thanks for coming back with your results.
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #35 on: January 07, 2019, 09:44:15 pm »
Scratch my reply above, you've solved it :)

The only thing that might be necessary is a capacitor to ground from the 74HC4066 lower switch end. Try 1 uF.
The spikes will probably go away with a better analog switch. But if you can't find DG417/419, oh well. What you've achieved here is good enough.

« Last Edit: January 07, 2019, 09:49:55 pm by Benta »
 

Offline syntax333Topic starter

  • Regular Contributor
  • *
  • Posts: 158
  • Country: 00
Re: Level shifting
« Reply #36 on: January 07, 2019, 09:51:16 pm »
Thank you very much for your answers and guidance along this journey of mine.  :)

There are still to much to learn about electronics for me so without the proper guidance I wouldn't be able to achieve this results.

OK I will place 1uF across "R6".

Also is the 10k enough for "Re" value of emitter follower (npn) or should I increase it more? What is the limit here? Why can't I just put 10M?

I will probably order some DG417 from foreign companies while waiting I just wanted to do some experiment with this circuit.
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #37 on: January 07, 2019, 10:03:28 pm »
You're welcome.
There's no reason to increase Re further, in fact it's already a bit high. 4.7k might be closer to the mark.
You're not at the end of the journey yet. The next point is to see how the circuit works when a load is connected.
But the basic function is there, and it works excellently.
 

Offline syntax333Topic starter

  • Regular Contributor
  • *
  • Posts: 158
  • Country: 00
Re: Level shifting
« Reply #38 on: January 08, 2019, 12:37:01 pm »
I will load the circuit and share the results as soon as possible.

Besides that I have couple of questions.

What is downside of large Re? You said that it is bit high, how did you decide that? I am familiar with regular emitter follower circuit however I have never used them in this configuration.
While I was researching I found that this configuration is used mainly to get rid of the dc offset, however I couldn't find any source that shows design procedure.
Can you explain or give reference for this circuit so I can learn more about this configuration?
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #39 on: January 08, 2019, 03:51:08 pm »
What is downside of large Re? You said that it is bit high, how did you decide that? I am familiar with regular emitter follower circuit however I have never used them in this configuration.
While I was researching I found that this configuration is used mainly to get rid of the dc offset, however I couldn't find any source that shows design procedure.
Can you explain or give reference for this circuit so I can learn more about this configuration?

The first Re supplies base current to the PNP emitter follower. If you make it 1 Mohm you'll starve the transistor completely of base current.

The complementary emitter follower quite correctly conserves the DC level of the signal. A simple emitter follower shifts the signal by Vbe (~0.65 V). By having and NPN and a PNP stage, this is eliminated.

It's not my invention :)  I first noticed the circuit many years ago while repairing VCRs and shamelessly copied it for my own designs.

 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19344
  • Country: gb
  • 0999
Re: Level shifting
« Reply #40 on: January 08, 2019, 04:29:23 pm »
What is downside of large Re? You said that it is bit high, how did you decide that? I am familiar with regular emitter follower circuit however I have never used them in this configuration.
While I was researching I found that this configuration is used mainly to get rid of the dc offset, however I couldn't find any source that shows design procedure.
Can you explain or give reference for this circuit so I can learn more about this configuration?

The first Re supplies base current to the PNP emitter follower. If you make it 1 Mohm you'll starve the transistor completely of base current.

The complementary emitter follower quite correctly conserves the DC level of the signal. A simple emitter follower shifts the signal by Vbe (~0.65 V). By having and NPN and a PNP stage, this is eliminated.

It's not my invention :)  I first noticed the circuit many years ago while repairing VCRs and shamelessly copied it for my own designs.
It's a fairly common circuit. A push-pull variant is often used for audio amplifier output stages, which will probably work well. It can be improved by adding current sources/sinks.

Refer to (b)

https://www.researchgate.net/figure/Different-kinds-of-class-AB-output-stages-a-Push-pull-network-and-b-improved_fig1_3139443
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #41 on: January 08, 2019, 05:06:04 pm »
Zero999, my apologies. I used an incorrect term for the buffer stage.
It's not a "complementary emitter follower" which your pictures correctly show, but an "NPN - PNP emitter follower cascade".

Very often found in CVBS applications where no voltage gain, but DC-level conservation and current gain is needed.

 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19344
  • Country: gb
  • 0999
Re: Level shifting
« Reply #42 on: January 08, 2019, 05:13:48 pm »
Zero999, my apologies. I used an incorrect term for the buffer stage.
It's not a "complementary emitter follower" which your pictures correctly show, but an "NPN - PNP emitter follower cascade".

Very often found in CVBS applications where no voltage gain, but DC-level conservation and current gain is needed.
Yes, but it works on the same principle. Remove Q1, Q4 and IQ1 and replace IQ2 with a resistor and it's the same circuit as yours.

The complementary version will be better, but it's more complex.
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #43 on: January 08, 2019, 05:40:59 pm »
The complementary version will be better, but it's more complex.

I'm not certain about that. A video buffer should have a GBW of at least 100 MHz to avoid colour carrier phase shift. The simple emitter followers will do this, but with the more complex types you posted I have my doubts (parasitics).
 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19344
  • Country: gb
  • 0999
Re: Level shifting
« Reply #44 on: January 08, 2019, 08:17:48 pm »
The complementary version will be better, but it's more complex.

I'm not certain about that. A video buffer should have a GBW of at least 100 MHz to avoid colour carrier phase shift. The simple emitter followers will do this, but with the more complex types you posted I have my doubts (parasitics).
Why do you believe the complementary version will have a lower bandwidth, than the single ended one? It should have a lower output impedance. The main issue I see is crossover distortion.

The input impedance goes down of both circuits, with increasing frequency, so the bandwidth will be limited by the source and load impedances. The 10k resistor will limit the bandwidth in your circuit. What does it do? If it's removed, the bandwidth will increase.
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #45 on: January 08, 2019, 09:06:30 pm »
I will not go into a nitty-gritty discussion on this. Your complementary circuits are excellent for audio, but CVBS is extremely sensitive to phase distortion.
The simple emitter followers work well in CVBS applications, there is probably a reason that professional video equipment use them.

My 10k resistor was ill chosen, but for a first design suggestion on a paper napkin not too bad. :)

Note my comment in brackets: "parasitics". The more transistors you throw at an application, the more problems you can expect.

 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19344
  • Country: gb
  • 0999
Re: Level shifting
« Reply #46 on: January 09, 2019, 09:07:01 am »
I will not go into a nitty-gritty discussion on this. Your complementary circuits are excellent for audio, but CVBS is extremely sensitive to phase distortion.
The simple emitter followers work well in CVBS applications, there is probably a reason that professional video equipment use them.

My 10k resistor was ill chosen, but for a first design suggestion on a paper napkin not too bad. :)

Note my comment in brackets: "parasitics". The more transistors you throw at an application, the more problems you can expect.
I'm sure you know it's not as simple as more components, more parasitics, more phase shift and less bandwidth. Using that logic know might thing the push-pull circuit I posted will use more power, but it doesn't. Indeed it will use less power, than the single ended class A two transistor amplifier.

I suspect the main reason for choosing the two transistor circuit is simplicity and I wasn't seriously suggesting the complementary circuit for this application. In fact I wouldn't recommend the discrete complimentary circuit for any video application. I'd opt for a video amplifier IC or high speed op-amp instead.
 

Offline syntax333Topic starter

  • Regular Contributor
  • *
  • Posts: 158
  • Country: 00
Re: Level shifting
« Reply #47 on: January 11, 2019, 06:41:10 pm »
I connected my load to circuit which worked fine there is no change in signal shape however as I showed my circuit schematics I connected 300ohm resistor as a PNP follower resistor.

Problem is that the load only draws approximately 10mA but I want it to be able to draw more current (100mA). If I lower the resistor value I get higher current but there is heating problem.

Is there a way to solve that problem with additional circuitry or do I need to use higher W resistors and heat-sink on transistor?
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 5839
  • Country: de
Re: Level shifting
« Reply #48 on: January 11, 2019, 11:03:10 pm »
Do you really need to deliver 100 mW video power, or do you need to deliver 100 mA DC current? I'm confused...
 

Offline syntax333Topic starter

  • Regular Contributor
  • *
  • Posts: 158
  • Country: 00
Re: Level shifting
« Reply #49 on: January 12, 2019, 08:44:21 am »
I need to deliver 100 mA DC current to my load.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf