Compensating CRT Deflection Coils

Projects No Comments

Things look really weird when you use an uncompensated deflection coil with a vector graphics display. This is because the coil looks like an inductive load to the driver amplifier, and the parasitic capacitance makes it ring. Ringing and overshoot create the strange-looking display, basically extending every line past its destination.

One way to compensate for that is to add a series RC snubber in parallel with each deflection coil. You can perform some calculations to figure out the values of the resistor and capacitor but they won’t get you very close to the answer. There are just too many parasitics to model. It’s much faster just to build a RC substitution box and tweak the values until you get the result you want.

CRT Board BOM Updates

Uncategorized No Comments

I have corrected some mistakes in the bills of materials for the CRT driver boards (the files in GitHub have already been updated):

  • ScopePower U2 part number from TS271CN (DIP package) to TS271IDT (SOIC).
  • ScopePower R3 part number from VR37000003305JR500 (33 meg) to VR37000001005JR500 (10 meg).

If you already ordered parts, I apologize. The TS271CN is a great little op amp and the DIP package version will work fine in a breadboard. That’s what I will do with the ones I accidentally ordered. The 33 meg resistor is useful as a bleeder resistor if you build the post deflection acceleration module (to be posted soon).

Mel, Blackjack, and the LGP-30

Cleverness No Comments

A friend passed on the following articles regarding a rather famous hack:

https://news.ycombinator.com/item?id=7869771
http://www.jamtronix.com/blog/2011/03/25/on-the-trail-of-a-real-programmer/

The LGP-30 was an early computer manufactured in 1956 and sold by the Royal McBee division of the Royal Typewriter Company. It had 113 vacuum tubes, 1450 diodes, a magnetic drum memory, and an oscilloscope screen with a template marking the register bits (instead of the more traditional panel with blinking lights). Mel wrote a lot of code for this machine, including a blackjack demo program, entirely in raw machine code, taking advantage of various quirks in the machine to keep the program very compact.

The Jamtronix blog has a link to a purported paper tape dump of Mel’s program.

Foolishly I decided to figure out the paper tape dump. I succeeded, and it looks like it’s in a format that a bootloader was supposed to understand, but not the bootloader documented in the LGP-30 manual. So first I ran the raw file into a popcount routine to see what the most common letters were. It was a subset of the alphabet, but had all the numbers except for the number ’1′.

Wat?

Back then they did a few strange things. One of them was using the lowercase letter ‘L’ as the number 1. Right. Also, since the LGP-30 was hexadecimal, they used extra letters to represent numbers beyond 9, but instead of using a-f, they used fgjkqw.

Then the single quote ‘ is used as a record delimiter, and the letter ‘v’ at the beginning of the block of records identifies the track and sector where the data is to be loaded. Each block has 64 words, 8 per line (which fits perfectly in a single track on the magnetic drum memory). To save space, they omit leading zeros, so incoming characters of 4 bits each are shifted left 4 at a time. At the end of the block is a stray word whose purpose I cannot figure out. I suspect it’s a parity or checksum, but it doesn’t match a simple checksum of all the data.

This machine’s architecture is a clever nightmare. Self modifying code was encouraged and was the standard way to accomplish common tasks. For example, to branch to a subroutine, you do this:

1000: r 3050     <- Set up return address by writing PC+2 to the destination address of the instruction at 3050.
1001: u 3000     <- Unconditional branch to address 3000.
1002: ...        <- Magically we pop up back here!
...
3050  u 0000     <- Looks like a unconditional branch to location 0 right? No, it's just a placeholder address. Yay, we can do without a link register!

And Mel coded this up in machine code. Probably because the “assembly” mnemonics are not particularly helpful, he must have quickly memorized the opcodes themselves. And why did he use instructions as data? The machine doesn’t decode the upper 12 bits of a word, so if you didn’t use it, it was just wasted. Basically the architecture of the machine naturally led Mel down this slippery slope.

So you might think that Librascope/Royal McBee, based on customer feedback for this machine, must have simplified the design for a later machine, the RPC-4000. And you would be wrong–it’s even worse…

Anyway, here’s my disassembled version: blackjack.txt. The track number is listed first, once for every block. In each block, every line has the sector number first, followed by the instruction mnemonic, following by the track and sector numbers of the instruction’s target. After that are the raw bits. The first two instructions are clear instructions followed by an unconditional branch. This goes to track 49 sector 34. You can follow the instruction flow from there.

As for me, I’m going to stop now before I accidentally learn how to program the LGP-30.

 

P10 Dark Trace CRT – The Skiatron

Uncategorized 1 Comment

I have a little story to tell. Years ago, I met someone who had a very large collection of CRTs. He had everything from common 3BP1s all the way to rare little gems like the 1EP1 and some vintage prototype CRTs. He showed me an item in his collection which was a rectangular CRT with a P10 phosphor. Finding a CRT with the P10 phosphor is like finding a unicorn. P10 is not really a phosphor; it designates a screen coated with some sort of alkali-halide (potassium chloride) that darkens when hit with an electron beam–a scotophor. The darkening effect lasts until the coating is heated, and typical P10 CRTs have a built-in heater that erases whatever was recorded on the screen.

Anyway, a few years go by and I lose contact with the guy. Rumors are flying around, and it turns out that he has decided to sell his entire collection. Bits and pieces of it start showing up at auction houses and flea markets. Another friend of mine mentions that he picked up a lot of CRTs at an auction house and asked if I wanted to pick through it. While sorting through it, I recognized the rare beast and bought it on the spot.

P10 Dark Phosphor CRT

So I finally got the time to hook it up and try it out. There doesn’t seem to be any documentation. The part number is 06E024P10, made by Thomas Electronics. It works, but not particularly well. Since the pin connections are nonstandard and the electron gun has some extra elements, I’ve probably got it connected all wrong. Anyway, I was able to put some scribbles on the screen.

P10 Dark Phosphor Screen

Notice the dark purple areas. I am shining a lamp through an aperture in the top of the CRT.

P10 Dark Phosphor Screen

Looking through the aperture, you can see how the CRT has a standard green phosphor section on the top third. This might have been used to verify that the tube’s electron gun was in focus. It could also have been used for status information. Most likely this tube would have been used in an early form of storage oscilloscope for capturing single-shot high speed events, although most examples of P10 tubes were designed for radar displays.

Electrostatic CRT Driver Design

Projects 13 Comments

Update 23-June-2014: Please see the CRT Board BOM Updates page for important changes.

Update 3-June-2014: Added OSH Park links so you can order PCBs easily and quickly!

Well, it’s here! I’ve put together an open source release package for my CRT driver design. See all the glorious details at the GitHub project. It contains the fab data (Gerbers, NC drills, etc) as well as the CSV-formatted bills of materials for three boards. All the parts are available at Mouser Electronics (and the Mouser numbers are listed in the BOM). It’s the same set of boards that I used for my Asteroids and Flappy Bird arcade machines at Maker Faire.

The design can drive most 2″, 3″, and some 5″ electrostatically-deflected cathode ray tubes, such as the popular 3BP1 or the precision 3RP1A. It can be modified to drive some of the oddball 2″ and 3″ CRTs that have a shared heater and cathode connection.

The three boards are:

The 1KV power supply takes +12VDC and uses a Royer oscillator with an off-the-shelf CCFL transformer to create filtered 800-1200VDC. The voltage is tuned by adjusting R1. Use a plastic-handled pot tweaker tool please! The supply can easily source several milliamps, which at 1KV could stop your heart. This is a serious power supply, so please be safe if you decide to build it. Keep one hand in your pocket while using it. Turn the supply off before poking at it, waiting at least a second or two after switching off the DC supply to allow the sense resistor divider to bleed off the output voltage. Don’t work alone.
ps_board
The design is inspired by CCFL circuits designed by Jim Williams–see the very long and wonderful AN65, especially Jim’s hand-drawn notes at the end. While Jim used a switching regulator to drive the Royer circuit, I used a simpler linear FET approach which works well but generates more heat. You will need to screw a metal heat sink to the plated through-hole located above Q1. Use a mica washer and a nylon screw if you want electrical isolation since this node is NOT ground.

If you want to put this in an enclosure, keep a clearance gap of 1cm or more between HV connections and low voltage nodes or a metal chassis. The power supply produces stray magnetic fields that will cause the electron beam in a CRT to deflect in ways you don’t want, so you should keep it far away from the CRT and use a CRT shield made out of high magnetic permeability material, like mu-metal or soft steel.

You can also add a voltage multiplier circuit, tapping in to diode D1, to generate post deflection acceleration (PDA) voltages. A 2-stage multiplier (as shown on the schematic) can generate 3KV which is fine for 3″ and 5″ tubes that require it.

At the heart of the design is the electrostatic CRT deflection and video amplifier circuit, which takes 0-3.3V analog signals for X and Y deflection as well as the video input, and outputs high voltage drive signals to the CRT.
defl_board
There are two deflection amplifiers, one for X and one for Y. The core of the differential amplifier is a matched dual NPN transistor with a bias circuit for setting the gain and offset (width/height and position potentiometers). A cascode stage made out of two high-voltage NPN transistors increases the bandwidth slightly and level shifts the signal up to about 1KV. There are two 220K resistors that form the load for the circuit. Don’t substitute these with plain carbon composition resistors–these parts have to be rated for high voltage use. Bandwidth of the amplifiers is about 10-15KHz, so you could drive ramp signals in to X and Y and generate an NTSC sweep if you wanted.

The video amplifier is a pretty simple class A design with a cascode stage to increase the speed. Bandwidth is about 6MHz, so the circuit can easily handle NTSC video. A simple-minded approach for driving a CRT electron gun is to ground the cathode and drive the grid negative, but the circuit design ends up being tricky. An easier way is to drive the grid to ground (or in my case, to an adjustable brightness voltage from a potentiometer) and connect the cathode to the amplifier output. The end result is the same, although there is a slight impact on the focus electrode. The video amplifier uses a +60V bias voltage which needs to be rather stiff since the drive current is fairly high (required to get 6MHz bandwidth).

A focus potentiometer produces a bias voltage for the focus grid in the CRT. It’s adjustable over a fairly wide range covering most 2″, 3″ and some 5″ CRTs, but if you’ve found some oddball CRT, you could always change some of the other resistor values.

The astigmatism potentiometer changes the final accelerator voltage relative to the average deflection plate voltages. Adjust this potentiometer if the spot on the screen looks oval instead of round.

There is a connector for a 6.3VAC filament supply. You don’t have to use an AC voltage, but be aware that pin 1 is tied to ground. You might want to measure the actual output voltage of the filament transformer (under load of course). I’ve found that most of them tend to run high (7V is not uncommon). Adding a series resistor can help prolong the life of the CRT.

Finally, a video amplifier bias supply generates +60V for the video amplifier. As an “easter egg”, you could modify this circuit to operate as a Nixie tube power supply by changing the value of R1. You’ll also need to increase the voltage rating on C5.
bias_board
If you’ve already looked at the GitHub project, you might have noticed that there are no design files. I use Altium Designer for my schematics and PCB layouts. It’s a fantastic tool, but Altium’s decided that hobbyists are not a target market so this is a very expensive product that not many hobbyists own, so I don’t think there’s much point to posting design files. Maybe if Altium releases a noncommercial free license, but  I doubt that will happen. Altium recently raised their prices by $2K so the direction they are going in is pretty clear.

I’ll be posting updates with additional information, such as a CRT compatibility table, pin connection tables, and so forth.

 

« Previous Entries