LabGuy's World: Tiny TV Board - Mark 2

Project Start - 20141030

Schematic Page 4 of 4. Tiny TV Mark 2 - Block Diagram - 20141030

       PROJECT GOAL: Improve on the lessons learned with Tiny TV 1. A new video amplifier provides a wide range of adjustable video gamma correction to compensate for display grey scale non linearity. Tiny TV 2 incorporates a new horizontal sync recovery circuit to prevent the short lining effect seen on the Tiny TV 1. Make both ramp generators self oscillating. Provide a convenient header with the buffered LM1881 sync signals for external down stream use. Lay out a printed circuit board and define a kit for this project.

Schematic Page 1 of 4. Video processing and sync separator - 20141030

       Allow me to present the vastly improved Tiny TV 2. DC restoration has been added to the video to accommodate the gamma correction amplifier that follows. This is a clever circuit I found on an application note from [Linear Technolgy] published way back in 1992. In general, the video is clamped at zero volts DC and then amplified and passed through two series circuits containing diodes.

       The diodes function as non linear resistors in a voltage divider. In one divider, the diodes form the top resistor. In the other, the diodes are the bottom resistor. Thes two voltage dividers bend the transfer curve in opposite directions. The neat trick is that when you add them together in equal amounts and they cancel each other, the video signal is once again linear. By adjusting VR6, the signal transistions smoothly from negative gamma to positive. When VR6 is centered the transfer function is linear. This is a useful feature for driving CRT control grids and other nonlinear displays. It should make TV pictures look much better on oscilloscope phosphors, like; P1 green, P7 radar UV/yellow, P12 orange, P31 blue/green, etc.

       The video amplifier, U1-B, amplifies the video up to around 5 volts peak to peak. U1-B also drives potentiometer VR2, video output level control. The final video output amplifier is one of the secotions of the Linear Technolgy LT1230CS. This opamp is powered from the +/-12V rails and has far more drive capabilty than the 4395. Both ramp outputs are amplified by the MAX4395 which are adequate for the high impedance inputs of my deflection amplifer. (A project yet to come) .

       Observe the outut connectors, J2 and J3. Note that for each driven signal pin, there is a matching adjacent ground pin. The linear outputs also have 75 ohm series resistors for isolation and impedance matching. If they are terminated at the receiving end, the amplitdes will be half as much as for a very high imedance input. Along with the adjacent ground pins, it provides a convenient connection point should the user decide to drive coax cable. For short distance of a couple or three feet (~1M) coax is not necessary.

Schematic Page 2 of 4. Horizontal ramp generator - 20141103

       This page contains, Horizontal Sync recovery, video presence detection, selection of ramp drive pulse (sync or feedback) and, of course, a ramp generator.

       Horizontal Sync recovery consists of removing the 2H pulses from the composite sync stream and making the new horizontal sync pulses all of the same width. Observe U10-A and U10-B and the timing diagram above. Starting with both timers cleared, both Q outputs are low and the Q not outputs are high. At the falling edge of CS not, U10-A triggers. It's Q output goes high and this triggers U10-B. For all practical purposes, both timers triggered simultaneously.

| CH1: CS not | CH2: HG not | Ch3: HS | CH4: Odd/Even not - 20141103

       Because timer U10-A has a period greater than one half of a TV line, equalizer pulses and serrations will be blocked by the timer's dead time. Once triggered, this one shot can not trigger again until it has fully timed out. It is rendered essentially blind to 2H pulses. Thus, U10-A can only trigger U10-B on pulses that occur more than 47.6 microseconds apart in time. Like horizontal sync, for instance!

       The next function is the detection of video presence on the input jack and using that information to route the appropriate trigger pulse to the ramp generator. Timer U13-A is set to a period of hundreds of microseconds and then driven by composite sync. It triggers and just stays triggered. The Q and Q not outputs are very convenient as we have the control signal in both polarities. We send these two signals to the trigger selector gates in both ramp generators.

       NAND gates U6-A, U6-B and U6-D form a simple two input selector. When video is present, HS input is selected. If video input is lost, then the feedback pulse from U11-A will be selected. U11-A is set to produce the same pulse width as HS, which is 4.5uS. To conclude, as long as video is present, the ramp will be generated in sync with video. If video is removed, the ramp generators will continue to run on their own.

       Why do the ramp generators need to keep running in the absence of video?

       For many CRT displays, and especially TV camera tubes, when running at TV scan rates, the beam current is set very high. If the scan were to stop, the beam will immediately and permanently burn a dead spot in the center of the screen. See: [Cyclops Project].

       To make the ramp generator self oscillating, a feedback mechanism is added. A voltage comparator is added to the circuit. The output is configured as an open collector, active low, TTL drive. This output is pulled up with a 1K resistor to +5V and drives the falling edge input of one shot timer U11-A. U11-A is configured as a pulse stretcher, ensuring that the ramp is fully reset before the next cycle.

       Without a trigger pulse, the ramp generator output voltage will rise to 5.6V and then be clamped there by the action of D1. Instead, the ramp voltage is compared against a threshold voltage set by pot VR5. Let's say 5 volts. When the ramp reaches that voltage, the output of the comparator will go low, triggering timer U11-A. The ramp resets to 0 volts, the comparator output returns to a high state and then the whole cycle repeats. U11-A is set for a time period of 4.5uS to match the width of a horizontal sync pulse and allow enough time for C9 to discharge .

       U11-A is configured as a pulse stretcher. It fixes the following problem. The ramp rises to the threshold voltage and the comparator output trips. The ramp generator starts to reset. But, as soon as the ramp voltage drops below the threshold voltage, the comparator will release and the ramp will start to rise. The cycle will repeat and an oscillation about the threshold voltage will occur. By stretching the reset pulse, the ramp generator will have enough time to discharge completely before the next cycle.

Ramp generator Comp. Sync Drive versus Horizontal Sync Drive - 20141103

       Scope shot 1: | CH1: Vertical ramp | CH2: Horizontal ramp | CH3:Composite Video |
       Scope shot 2: | CH1: Comp Sync | CH2: Horizontal Sync | CH3: Horizontal ramp | CH4: O/E-not |

       If we drive the horizontal ramp generator with composite sync, it will work OK for driving electrostatic CRT displays. But, magentic deflection circuits are typically tuned to one frequency and are not stable or efficient when operating off frequency. So, the H sync recovery is mandatory for this scan generator to be as flexible as possible in the future.

Schematic Page 3 of 4. Vertical ramp generator - 20141030

       The vertical ramp generator is functionally identical to the horizontal ramp generator except for the timing periods. The ramp capacitor C11 is much larger than C9 to generate the longer 16.67mS ramp. This is approximately ~60Hz. If C9 is 22nF and makes a 63.5uS ramp (15.750KHz) then logically the vertical capacitor should be 262.5 times bigger than the horizontal cap. This works out to 22nF times 262.5 (tv lines) equals 5775nF or 5.775uF. Nearest standard value is 5.6uF. A tiny bit low. So, 6.8uF was chosen. It worked first time.

| CH1: Comp. Video | CH2: CS not | CH3: VS not | CH4: See text |- 20141104

       The pulse stretcher time is also adjusted for the vertical rate. In the first photo, vertical ramp is on channel 4. This shows how long it takes Q7 to discharge the 6.8uF capacitor, C11. About 100uS. The vertical sync period of 258uS is more than long enough to get full reset of the ramp. For consistancy, the feedback one shot is also set for 258uS. The second photo shows the field square wave, O/E not, making the transition from the even field to the odd.

       "The point comes when you must shoot the engineer and ship the project!" - Bill Hendershot.

Tiny TV Mark 2, PCB Final Assembly Drawing - 20141106

       Tiny TV Mark 2 fits neatly on a four inch by three inch two layer printed circuit board. This is the final layout. The schematic is complete. The PCB placement and routing is complete. All error checks have been passed. It's pretty. The Gerber Files are generated and zipped. The quote for three pieces was sent and reply received. Three boards in 12 days, about $150. Darn. Gotta check my spare change rainy day jar. I wonder if they take rolled change? Stay tuned.

       Some assembly options include leaving off certain connectors and pots. Wires can be soldered directly to the connectors pads. For J1 and or the potentiometers, it may be desirable to mount them on a front panel for convenient access. VR2, VR3, VR4 and VR6 would be prime candidates for this. VR1, VR5 and VR7 are one time adjustments and don't necessarilly need to be remoted from the PCB.

       A note about the test points. As you can see, I like test points. You can never add too many. OK. You can. But that would be silly. I used a non through hole style pad in order to be able to route back side signals beneath them. The chaotic layout is not random. But, an indication of the moderate complexity of the routing paths. A four layer board makes routing a lot easier. But, the boards then cost almost twice as much to manufacture. The test points, likewise should the user choose, can have wires soldered directly to them and be routed to pin tip jacks on the front or rear panel of an enclosure.

Project Update - 20141108

       An order has been placed for three PCBs from PCBCART in China. In the end, each blank board costs a little over $42 each. It may seem kind of pricey. Here is how I calculate whether to build a project myslef OR spend money on a paricular aspect of the project. I charge myself $100/Hr for projects. If I can build for less cost than I can purchase, then I will build. If purchasing a product or service is cheaper than the time I would spend, then I buy that service. I estimate at least sixteen hours to assemble the prototype on vector board. That's $1,600 of time I will now use elsewhere.

       The order was placed with a 12 day lead time. So, in effect, the PCBs will be here in roughly three weeks. Faster processing was an additional $40 charge, which I chose to save. Time I have a plenty. Money not so much, despite appearences. That savings will go toward purchasing the parts for three complete Tiny TV Mk2 kits. None for sale yet, they are all accounted for in future projects.


       The Tiny TV is destined to drive various displays, including the Cyclops Project. For magnetic deflection, I have a very simple and hideously expensive design on the drawing board. The amplifier chips (LH0101CK and/or PA02A) are available from commercial vendors for as low as $150 each and as high as $425 a piece. Or more! By shopping around, on Ebay for instance, I have located single piece quantities for under $20 each. HOWEVER, if a part is selling in the hundreds of dollars range generally, how does the seller establish that low price? Some suspicion is highly recommended here. One fellow admits his parts are pulls from dead equipment. That's OK with me. I am currently testing two vendors and will report the results here.

       Why would you choose a design that is so darned expensive, Labguy?

       The logic is reasonable. See if you agree. According to the National Semiconductor (now Texas Instruments) data sheet for the LH0101, these parts were specifically designed for magnetic deflection drivers up to 5 amps. This should drive small deflection yokes all day and night, no problem. The goal for this amplifier is a high potential for success, FIRST. Then go on to design (or copy) a discrete solution and compare what they cost. The expensive IC chips could, in the end, be the better bargain.

They're here! - 20141121

       Tiny TV Mark 2 printed circuit boards have arrived. As I write this, assembly of one of the boards is in progress. Needless to say, I have not acquired all of the parts yet. I kinda blew my mad money on three printed circuit boards and rent is due next week. I do have all of the resistors and 99% of the capacitors. I used my hot air gun to remove the gamma amplifier chip from Tiny TV, version 1, may he rest in pieces. Now with my only rasterizer board out of commission, the pressure is on to complete this board. This is not my first circuit board. But, it is the first one made specifically for me. And that is very cool.

Fully assembled prior to testing - 20141122

       Completed assembling the board. Apparently purchased the incorrect potentiometers. Stuck them in temporarily til the right parts can be obtained. This board was assembled with a Weller WPCT soldering station, tweezers and a magnifier headset I have effectionately named, "The Nerd-O-Visor". Almost all of the resistors and capacitors are SMT size 0603. Approximately 60mils by 30mils. The 10uF capacitors are 1206 size, approximately 120mils by 60mils. Huge in comparison to 0603. The SMT FETs and transistors were a little more challenging. But, lots of flux, magnification and squinting and it was done!


       Troubleshooting has revealed that I keep making the same mistakes over and over again. The video presence detect one-shot chip, U13-A 74HC221, is the incorrect type for this function. It is a non-retriggerable timer. That is to say, that once triggered, it will not trigger again until about 95% of its timing period has expired. Consequently, the output of the timer is not the steady state I expected. It is pulsing at very long intervals. But, pulsing nonetheless. In turn, this is toggling the sync selectors that drive the ramp generators and disrupting the scan ramps. It is not supposed to do that.

       The solution is to replace it with a retriggerable timer chip. The 74HC123 is the correct answer and the good news is it is a drop in replacement for the 221. More on that Monday evening after I go purchase a 74HC123. I noticed a 74HC123 on my Goldmark 1 circuit board and could not recall why it was there. I swore I only used the 74HC221s. Turns out, that is also the video presence detector and I had solved this issue once before. Did not get that change noted on the Goldmark schematics, from which I copied the circuit design. Silly me!

       Problem number 2 is that, for whatever reason, the horizontal ramp generator is stuck low. I find nothing wrong with the circuit wiring or the assembly. It is currently a mystery problem. I am worried that the surface mount versions of the 2N7000, the 2N70002, is not the same spec as the larger part? The board was laid out for a FET called the 2N7002KW which fits a slightly smaller footprint than the SC-70 packaged version I obtained at Anchor Electronics. Makes me also wonder if the pin arrangement is different. I will order some of the KW suffix parts tomorrow as well.

Rework required. GRRRRRR! - 20141122

       Problem number 3 discovered. Would you believe that the library definition for the LM319M is incorrect for my copy of PADS PCB? It happens. But, who'd a thunk it for such a mature part? Comparator number two (U8-B) is shown connected to the correct pins. But, in the wrong order. I fixed this by lifting the three pins from their pads on the circuit board. Next, I used tiny jumper wires to connect each pin to the approriate pad. That circuit is now working and the vertical ramp generator is indeed free-running when no video is present. It's also good news that no permanent damage was suffered by U8.

       Horizontal ramp generator still not working. Note in the photo how Q7's pins are spaced wider than the pad beneath them. This also applies to the horizontal ramp transistor, Q4. I am suspecting that the pinout differs between the various part packages. Even though the die within is exactly the same. What a pain!

       The LT1230CS chip appears to have not survived the transplant process. It is running very hot and one amplifier is not working. Video goes in from VR6 and +5V comes out. Will buy a new one of those tomorrow as well.

       It appears that the current sources are not working either. I'll bet the transistor pinout for those are also incorrect. This has been an ongoing bug in PADS cad software since I learned to use it. The answer is, I am currently teaching myself Orcad Capture and Layout. Also downloaded Kicad and am learning that one as well. Every tool box should have more than one hammer.

Rework progress good - Revisions added to PCB - 20141124

       I reworked the board extensively this evening and made good progress. Testing each fix as it is installed.

       Obtained most of the correct potentiometers.

       Replaced U13 with a 74HC123D and the video presence detector is now working as designed.

       Discovered that Q2, in the horizontal ramp generator current source, had shorted. No current, no charge ramp. Working now? Check!

       Verified that the pinouts of all transistors were correct. Check!

       Corrected the LM319AM schematic symbol to PCB footprint pinout error in my PADs library. Check!

       Ordered a new new LT1230CS quad current feedback video opamp? Check!

       There is one interesting observation however. Though both ramp generators are now producing ramps, they are not linear and they are running about three to six times too fast. Both X and Y. There is no difference between this version and the circuit on the first Tiny TV board. In fact, I had to substitute a 10uF cap in place of the 6.8uF cap required in the vertical scan circuit. It should be running slower if anything. Well, that's debugging for you. It seems like the fun goes on and on. But, at some point, it is suddenly done.

       Like I said. Good progress.

Where the magic happens - 20141124

Formula for the ramp generator and the results - 20141204

       The Tiny TV 2B board is now working completely in driven video mode. The free run mode is not reliable. However, the new Linear Technology video opamp arrived and was installed, restoring video output. The gamma circuit works very well as can be seen in the screen shots.

       Be sure to check out reference number 5 at the bottom of this page. It is an excellent educational article about ramp generators and integrators.

       The formual for the capacitor value is very simple. Let's do the horizontal scan calculations first. I used 53.5uS for the active ramp period as this is the 63.5uS full line period minus roughly the horizontal blanking interval. Multiply this time period by .002, the 2mA of the constant current source, then divide 5, which is the 5 volt amplitude we desire for the ramp. So, (.0000535 x .002) / 5 = .0000000214 or a capacitance value of 21.4nF. A 22nF capacitor is the closest standard value and what is installed on the PCB.

       The vertical scan formual is 16.7mS times 2mA the result divided by five volts. (.0167 x .002) / 5 = .0000668 or a capacitance value of 6.68uF. On the PCB, I stacked two standard value capacitors to get as close to 6.68uF as I could. Using a 4.7uf cap in parallel with a 2.2uF cap gave me 6.9uF which is close enough and indeed it did work. An arrow points them out in the photo.

       The last picture more accurately captures the blue hue of the P31 phosphor. It is a very pleasant blue/green hue. I'm just saying.

       The Tiny TV 2B printed circuit board project is completed at this time. There may be future improvements. But, those will be presented in a separate article.

       Comments or Questions? [EMAIL]








Created: October 27, 2014 Last updated: December 4, 2014