Hot logic

Ridicule doesn't kill but HV does. I hope to avoid both while using some 1Ж29Б-В and 6Н21Б

Similar projects worth following
My credo has always been : "a circuit that generates heat is a bad circuit".
So I've stayed far from a certain kind of technology which relies on heat to let electrons hop between electrodes.

But I keep hearing about them and get taunted so one day, it had to happen.

I encountered some of these parts on eBay and couldn't keep myself from making a point while also learning how they work, by making a digital circuit out of them. I'd like to look at how ENIAC worked ! (what a terrible idea, in retrospect)

So I've set this simple enough goal : design a simple ALU and small register set with pentodes and triodes. You know, "for educative purposes" and so people stop asking me to use them, as if relays and transistors were not enough ;-)

To quote Rod Elliott (ESP)

  • "Valves (vacuum tubes) ... much as I've tried to ignore them in the (futile) hope that they'd go away, they haven't, and probably won't."
  • "Valves are interesting, not just from the historical perspective, but because they have attained almost cult status despite the fact that they are essentially a dead technology."
  • "There are certainly some good reasons to experiment (especially with preamps), as the cost is relatively low and the experimenter will learn a great deal. Whether this knowledge is ultimately useful is another matter altogether."

Let's see if the analog circuits can help make decent digital circuits...

I all started in March 2017 when I found used tubes in the corridor, certainly replaced by a musician neighbour : ECC83S and EL84 : huh ?

I gathered some documentation and found out the capabilities of these parts. @Ted Wood remarked :

"Thing about valves is that they need loads of support - sockets, high voltage power supplies, high current heater supplies, output transformers etc. etc. Which means that you get very few bangs for your hobbyist buck."

So my idea of doing a simple logic circuit burned almost immediately. Yeah tubes are crap.

I looked on eBay to see how much they cost (as well as the "support" parts") and stumbled upon the younger russian siblings of the EL84... and couldn't resist buying a box of them !

They're smaller, consume and emit less energy, don't need a socket, run faster at a lower voltage...

So what can I do with these ? Not much but we can cover the basics : combinatorial and sequential logic, build an adder with an accumulator for example, just like it all started with #SPDT16: 16-bits arithmetic unit with relays (let's stay safe).

The plan is to

  1. characterize the 6N21 and 1J29
  2. make a few logic gates (maybe I can do AND gates with pentodes ?)
  3. make a flip-flop (the dual triode looks great for this purpose)
  4. make a half-adder and full-adder circuit
  5. chain the full-adders to make a 8-bits adder

That sounds so easy, right ? ;-)

1. The 6Н21Б (6N21B) are cute !
2. 1Ж29Б-В (1J29B-V) arrived too
3. And the PSU
4. valve circuits
5. tube logic
6. Thank you
7. ENIAC and the FlipFlops

  • 100 × 1Ж29Б-В (1J29B-V) miniature low-voltage HF pentode
  • 50 × 6Н21Б (6N21B) miniature double triode

  • ENIAC and the FlipFlops

    Yann Guidon / YGDES04/17/2017 at 08:54 0 comments

    Hahaha it sounds like a Rockabilly rock band :-D

    More seriously I'm gathering my thoughts after (re)finding the sources and (re)interpreting the data.

    I looked at the paper by Burks about the design of the ENIAC and admit it's a really impressive project. Somewhere it says that the flip-flops have two versions : one version with one triode and one with two triodes. The 2T seems easy to grasp but how is it possible to use only one triode ?

    It became clear when I looked at that project (thanks to Tom Anderson) that tries to recreate a single ENIAC flip-flop. A few things became apparent :

    • The distinction between FlipFlop and RS latch is not clear and it seems they use mostly transparent latches, not edge-triggered registers. We engineers of today are pampered and spoiled !
    • The text should have mention "double triodes" or "envelopes" because not only is it not possible to latch with just one triode but the schematic shows that the two circuits are in fact with 2 and 4 triodes.
    • Diodes would have simplified and eased the design of the Flip-Flops (and the programming panels, which use resistors). However, reliable and efficient diodes became available when Silicon took over, and the IBM 604 manual (1958 era) still mentions that diodes are used only when really necessary, as they seemed to be much more expensive znd fragile than tubes. You just can't make a computer using radio receiver's cat whiskers. This confirms what I learned with the #YGREC-РЭС15-bis : without good diodes, computing machines are possible but they can't take off...

    Further looking at the ENIAC schematic, I am shocked:

    Seriously guys, how many power rails do you even need ?

    -555V, -470V, -450V, -390V, -360V, -355V, -285V, -200V, 0V, 20V, 50V, 225V, that's 12 rails just for this circuit !

    I was complaining that I had to provide 2 supply voltages (filament and anode) but this is simply insane.

    OTOH this explains how they do level shifting and AND gates: they shift the tubes, not the signals. This is getting insane...

    The IBM604 is more rationalised and engineered (yet still energy wasteful), with only -100V/0V/150V...

    Speaking of big bad supplies, I remember I hacked one together 20 years ago out of an old guitar amp transformer, as I wanted to use it to create my own LM3886-based bass amp. This is a symmetrical high-current, pretty high voltage supply that could work with this project... Now I have to find it in my archives :-D

  • Thank you

    Yann Guidon / YGDES04/16/2017 at 01:09 2 comments

    Thank you @Benchoff for the feature today on the main Hackaday page :-)

    May I suggest you something ? Don't hesitate to contact me before you publish something about my projects :-)

    There are several benefits:

    • I can provide you with high resolution pictures, not pictures I cropped for the page layout.
    • I can correct little mistakes (for example I found 2 pairs of tubes :-) )
    • exotic technology is great and I'm all for it but this project barely started, while I have much ambitious and advanced projects : the #YGREC-РЭС15-bis goes way beyond the odd useless techno curiosity, I think it's a much more subject-worthy project with a lot of implications (indirectly to #F-CPU). Come one, I haven't even prepared a first power-on of the tubes :-D

    You know how to join me and I'm 200% invested to make HaD gre^Wawesome :-)

  • tube logic

    Yann Guidon / YGDES04/11/2017 at 02:07 4 comments

    I'm still a bit puzzled by how to do logic circuits with tubes.

    Looking at an old report about transistors, I see the following diagram using DCTL (Directly Coupled Transistor Logic, such as used in the CDC6600):

    Doing a XOR is pretty easy, thanks to the ability of transistors to work in parallel (OR) and series (AND).

    At first sight, triodes can only do OR because the voltage differential between anode and cathode is so high !

    The differential is usually overcome with a coupling, DC-blocking capacitor, at least in audio circuits, which makes the tubes work only in pulse/transient mode, which is not desired.

    The pentodes have differentials of 0V-45V-60V so maybe a 15V Zener could work to make AND gates, but am I daydreaming ?

    I should look at the schematics of the ENIAC, when I find the link again.

    Thanks to the many comments on I found and recovered several resources about tube logic.


    For example I found the following circuit in the IBM 604 manual (1958 era):

    What ?

    Resistors ?

    -100V ??

    Maybe I'm too modern and I know "it works" but I think it's just ridiculous...

    Other converging resources about the ENIAC, covered by @Al Williams:

    The data matrices use resistos, not diodes...

  • valve circuits

    Yann Guidon / YGDES04/09/2017 at 22:22 7 comments

    As I try to unlock the last know issue with #Yet Another (Discrete) Clock (namely : amplification without affecting the oscillator or wasting energy), I stumble upon very nice pages about the circuits of yesteryears in the audio range. In particular I find the discussion in 8 - Cathode Follower very refreshing and useful (the kind I'm looking for in this type of WTF project with no direct usefulness). I learn about the existence of internal plate resistance (rP), the degeneration of tetrodes and pentodes when used as cathode followers...

    I just have to quote a useful paragraph, about something else I didn't find elsewhere or that could discourage me :

    One always has to be careful with valve circuits though, as it's easy to exceed the maximum allowable cathode to heater voltage because the heaters are nearly always ground referenced. If the voltage is exceeded the valve may be damaged, but even if it survives it may not function properly.

    [...] Unlike JFETs, there is a definite limit to the upper value of the grid resistor, determined largely by the materials used and the geometry of the valve's internal structure. If the resistor value is too high, the valve will attempt to bias itself as the grid collects stray electrons. This is called 'grid leak' or 'contact' biasing, and generally uses a resistor of around 2.2MΩ to 10MΩ or thereabouts. The tiny current flow (typically less than 1µA) causes a voltage to be developed across the grid resistor (negative at the grid) which biases the valve. In general, grid leak bias is rather unpredictable and is usually a bad idea, and it should be avoided.

    The page describes a simple current amplifying circuit (impendance buffer) with many details that are rarely mentioned otherwise, and precious because, since I won't build an amplifier, I won't follow well-established circuits and I'll be on my own, trying to decypher ENIAC's diagrams...

    So I learn that 1M Ohms is a reasonable grid resistor. It will be fine because I'll remain in the digital domain but even there, the "contact biasing" will bite when several inputs will be connected together. Fan-in seems to be an issue since the grid resistor must be divided by the number of grids, or else "things will turn bad". But lower impedance means higher driving current, larger capacitances, more RC delays and more amplification...

    As I consider a 8-bits circuit, this should not become insurmountable but will be another area to keep in mind during the design.

    Then there is this link to a pretty practical page about the tubes:

    The warning about high voltages is why I chose low-voltage pentodes ;-) but this is a chilling reminder concerning the 200V needed (according to the available informations) by the 6N21B.

    Thanks to Elliott Sound Products for sharing their experience :-) I'll remember this quote :

    'guitar amp' and 'careful engineering' generally do not belong in the same sentence.

  • And the PSU

    Yann Guidon / YGDES04/09/2017 at 03:41 7 comments

      So now I can generate 61V@2.1A though I can't seem to control it via USB. Yet.

      But it's already a game-changer for my lab :-D

      Update 20170417 : the stack entry has been deleted :-(

      I had noted a few things, I'll try to remember them and write them down here.

      Update 2: ah no, it's there :

      But it's good to have a second copy ;-)

      The model is AXIOMET AX6002, a rebranding, as I later found, of KORAD KA6002, but discovery was not obvious.

      I bought this model on eBay because

      1. it reaches 60V (a match for the pentodes)
      2. it's digital, easy to set precisely
      3. it's not much more expensive than other models
      4. it is interfaced with serial and USB ports !

      4th sealed the deal.

      When plugged in the computer, the serial port is immediately found (OK, I first have a dud cableso it wasn't as smooth.

      The documentation is quite terse:

      I have the protocol (9600 8N1) so I can configure the port:

      stty 9600 cs8 raw -echo -echoe -echonl -echoprt -echoctl -echoke -parenb -F $TTY

      but the last paragraph misses a critical information : what query to enter ?

      I went to the Axiomet website too look for information and found the newer model. The documentation mentions:

      Interface:USB interface, SCPI commands provided

      Oh, let's look that up. SCPI is a standard I hadn't spotted yet ! So I embark in the analysis of the specifications.

      I find that the discovery string is "*IDN?" so I try to read it:

      echo -n "*IDN?" > $TTY
      It took a while to get anything, and to understand that contrary to the specification, the commands should not be terminated by CR/LF, so I added the "-n" option to echo.
      # in another term:
      $ od -An -v -w1 -t x1 $TTY

      In ASCII :

      $ cat $TTY 

      After a few hours, I got the device's string, that returned no hit on google...

      So I wrote a .stack page (unfortunately deleted now) and asked for help. I got it (from @Andrew Bolin) with a link that started bring sense to the whole situation because I tried most of the standard commands without finding anything else that would work, with or without the trailing CR/LF.

      On the EEVBlog,I find that the device is not KORADKA but the brand KORAD, model KA6002P !

      I learn about the bug (reproduced here) with the trailing letter, then discover the whole command set.

      (the most important are copy-pasted here)

      Request Example output Remarks
      *IDN? KORADKA3005PV2.0
      Request identification from device.
      VSET1? 12.34 Request the voltage as set by the user.
      VSET1:12.34 (none) Set the maximum output voltage.
      VOUT1? 12.34 Request the actual voltage output.
      ISET1? 0.125 Request the current as set by the user. See notes below for a firmware bug related to this command.
      ISET1:0.125 (none) Set the maximum output current.
      IOUT1? 0.125 Request the actual output current.
      OUT1 (none) Enable the power output.
      OUT0 (none) Disable the power output.
      OVP1 (none) Enable the "Over Voltage Protection", the PS will switch off the output when the voltage rises above the actual level.
      OVP0 (none) Disable the "Over Voltage Protection".
      OCP1 (none) Enable the "Over Current Protection", the PS will switch off the output when the current rises above the actual level.
      OCP0 (none) Disable the "Over Current Protection".

      I see several project that interface to the same line of devices, in Python and Ruby for example, but the thing is now very simple to command, even with bash. Here is a little "vocabulary" :

      echo -n "*IDN?" > $TTY
      echo -n "ISET1?" > $TTY
      echo -n "OCP0"...
    Read more »

  • 1Ж29Б-В (1J29B-V) arrived too

    Yann Guidon / YGDES04/05/2017 at 06:48 2 comments

    received these pentodes from Moldavia and they look lovely !

    This tube is funny because it has a wire on the top:

    The "etiketka" needs some explanations but the characteristics can be found on many web sites. I put these here "for reference":


    OK, sorry, I don't understand Russian, I barely decypher a bit of cyrillic :-P (see the project #Clockwork germanium)

    According to online resources :

    Type : penthode
    Application: HF voltage amplification
    Cathode type: oxide, direct heating
    Envelope: glass, miniature
    Mass: 4,5g
    Filament voltage: 1,2V/2,4V
    Filament current: 56-68mA/31mA
    Anode voltage: 60V
    Grid1 voltage: 0V
    Grid2 voltage: 45V
    Steepness: 1,2mA/V
    Reverse grid current: 0,3µA
    Microphnic noise: 130mV
    Socket type: flexible.


    I'm pretty curious about the anode wire that extends from the other end... why there ? and won't that complicate the physical design ? Considering that the anode will receive the high voltage, it will certainly be tricky and not "kids friendly" like the relay computer...

    The filament current is much lower than the 6N21B: I think it can run at (min.) 50mA@1.2V (60-80mW) instead of the 2W (at least) required by the dual-triode... so at least, this one was a good bet.

  • The 6Н21Б (6N21B) are cute !

    Yann Guidon / YGDES04/05/2017 at 06:00 0 comments

    I received the 6Н21Б from Sotchi and I see the difference with the "classic", AF tubes : they are smaller :-)

    I decided not to play with nuvistors and the miniature tubes are right what I had in mind, the object in itself is pretty good looking.

    From the seller:

    6N21B = 6112 = 6N17B-V ~ 6SL7 Gold Grid Hi-mu Double Triode NOS
    High durable low frequency high-mu dual triode
    Improved version of 6N17B-V / 6N17B-VR , 1W anode power dissipation ( 6N17B-V / 6N17B-VR only 0.9W )
    Very low microphonic noise , 4 times better than 6N17B-V / 6N17B-VR
    Different pinout than 6112 / 6N17B-V / 6N17B-VR / 6SL7, see datasheet !
    Each tube contains 5.05 mg gold and 0.05 mg silver !

    This one didn't come with an etiketka/passport, so I have to rely on other resources. They are easy to find online (which helped me decide on the appropriate reference) and here I copy-paste the data from (I further the long tradition of copy-pasting it from everywhere).

    Name: 6N21B
    Type: Double triode, hi-durable
    Application: LF voltage amplification
    Cathode type: oxide, indirect heating
    Envelope: glass, miniature
    Mass: 4,5g
    Filament voltage: 6,3V
    Filament current: 0,36-0,43A
    Anode voltage: 200V
    Anode current: 0,0035A
    Anode power: 1W
    Steepness: 2,6-4,0mA/V
    Reverse grid current: 0,2µA
    Microphnic noise: 15mV
    Gain: 65-100;
    Socket type: flexible;
    Lifetime: more 2000 hours.

    I have chosen these because they have a better amplification coefficient than the (slightly cheaper) 6N17B-V. I'm not doing audio and I don't care about linearity ;-) This also means I can undervolt the filament to increase their lifetime and save a bit of energy. Though who in their right mind would use these for 2000h ?

    Oh and 200V on the anode ?

    I'm not sure if the below curves (found at various websites) tells us the voltage can be lowered:

    I might have to learn some Russian, one day.

    And it seems I'll have to plot my own curves and find the right operating conditions.

    It seems that the stories I heard about early "tube computers" that reduced the heater voltage (to increase reliability) may have overlooked something. From Rod:

    "The heater voltage is far more critical than some people imagine, and if too low, the result can be cathode poisoning - a condition where the cathode materials are contaminated by trace amounts of gas."

    So in the case of this tube, I'll try to run at the lower end of the range, around 0.35A or so. That's 1/3 of an ampere, or 2W, damnit, and heating 50 of these tubes will draw 100W ! It's ironic since I chose the miniature ones to save power... Yet the insides heat in the 700-800°C ballpark.

    I found approximate equivalences. According to,,

    "The 6N16B can be substituted for U.S.A manufactured 6021 and 6N17B for 6112 subminiature tubes."

    "6021's european designation is Ecc70, and also NJ7P, it only has a gain factor of about 30"

    So once again the russians just copied the design though they kept using it much longer than other countries...

    Knowing the equivalences lets me extend the research of other compatible schematics and circuits...

View all 7 project logs

Enjoy this project?



K.C. Lee wrote 04/18/2017 at 18:49 point

Looks like the IBM circuit is doing passive level shifting ( -100V and resistor dividers) to about +31V or -18V.  You'll need to work out the different values for 60V.  You'll still need a low current negative supply and around -30V depending on the divider values.

Running the filament at slightly lower voltage can probably increase the MTBF.

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/19/2017 at 07:34 point

Well I will just give up on MTBF, since 1) there are less tubes than ENIAC so I'm less affected 2) I don't imagine it running continuously, or even often. Tube should be considered as "expendable" :-/

For the level shifting, I'll see my stock of weird Zeners...

  Are you sure? yes | no

K.C. Lee wrote 04/19/2017 at 11:41 point

Zener voltages are not well defined when the current is well below the publish values in the datasheet.  The resistor divider current is around 200uA, so you can't use it directly in series to the inputs.  If you increase the input current to each tube, then the fan out each "gate" can drive is reduced.

However you can lift the cathode voltage by using zener diodes.  (I don't know enough in the arcane technology to fully understand the implications.)

  Are you sure? yes | no

Tom Anderson wrote 04/17/2017 at 04:17 point

This looks good:

It looks like they are running at full voltage. There should be a lower-voltage version somewhere.

One important step in digital computers overtaking analog was to derate the tubes and accept lower performance in exchange for better reliability. The key to getting an operational circuit at lower voltages was a design centering. Check out US Patent 3120606 by Eckert and Mauchly. The math that Mauchly developed is here:'s_sphericity_test . I think he invented statistical design, which is of course hard to do when you don't have a computer yet!

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/17/2017 at 07:06 point

Thank you once again Tom !

This is another useful resource and a great reminder that I'm not the only crazy geek around :-)

"design centering" ?

  Are you sure? yes | no

Tom Anderson wrote 04/18/2017 at 03:36 point

I'll borrow from to explain design centering. It is a valuable when you need a lot of working copies of a design that doesn't always work perfectly due to imperfections in the parts. In the case of tubes, they last longer at lower voltages, but they don't work as well.

Yield analysis 
This process involves simulating the design over a given number of trials in which the yield variables have values that vary randomly about their nominal values with specified probability distribution functions. The numbers of passing and failing trials are recorded and these numbers are used to compute an estimate of the yield.

Design Centering (also known as Yield Optimization)
This process involves multiple yield analyses with the goal of adjusting the yield variable nominal values to maximize the yield estimate.

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/18/2017 at 17:57 point

wow, that's beyond the scope of my project but good to know :-)

  Are you sure? yes | no

Dylan Brophy wrote 04/11/2017 at 05:15 point

I never lived with the tubes, nor with relay logic, nor processors with DIP like the Z80, 6502, 8086, etc.  So I know nothing about the vacuum tubes.  I have heard though that they make a sound, or at least make sound from huge power draws.  Is this true? Whats it like?  It would be cool for you to post a video so I can see for myself!

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/11/2017 at 05:34 point

Yep, I'll see what I can do with them...

I am surrounded by musicians so the usual question is "can you repair my tube amp ?" and I repeatedly refuse because "an amp that gets warm is a bad amp" and they don't talk to me after :-D

I hope to prove them that tubes are as terrible as what I tell them, even with less horrible models and lower voltages :-P

  Are you sure? yes | no

Dylan Brophy wrote 04/11/2017 at 05:38 point

I guess its what sound you want - does it matter how much energy a oversized amplifier wastes if it sounds good?  I don't know...  I do know that my dad likes the tube amps better, and he thinks the transistor sound isn't as good.  I haven't a clue, to me music is music, as long as its the right genre.

  Are you sure? yes | no

Andrew Starr wrote 04/10/2017 at 09:02 point

God damn you I'm thinking about a ferrite core memory with no semiconductors!!

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/10/2017 at 09:09 point

Don't do this ! It's a miserable trap !

  Are you sure? yes | no

Andrew Starr wrote 04/10/2017 at 09:11 point

But they're _so cute_...

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/10/2017 at 09:13 point

like those adorable colored frogs. Hint: because they are poinsonous...

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/04/2017 at 07:38 point

I received both tubes : they are so cute !

I have taken pictures and will need time to process them.

I'm also waiting for the programmable power supply, it's nice to key the voltage value and focus on the circuit instead of the PSU's drift :-)

  Are you sure? yes | no

agp.cooper wrote 04/03/2017 at 00:42 point

Hi Jann,

Just remember a triode is a FET with a pilot light, after that all good.

Many years ago (~25?) I built a dual triode superregenative radio from a 12AT7A (similar to the ECC83S). I ran it at 45 volts (five 9v batteries), not the 100v or 250v suggested by the datasheet. The circuit was a FET design that I modified to suit the dual triode. Those pentodes etc. are just like dual gate MOSFETs. Generally they are wired up in one standard way so no harder to use than a triode.

Regards AlanX 

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/03/2017 at 00:46 point

Thank you Alan !

I'm just starting and still wait to receive more material such as the 50×6Н21Б and a programmable 60V lab PSU :-)

Funny how I have already considered "dual gate MOSFET" as AND gates, so when I found about pentodes, I immediately considered them as valuable logic gates without the diodes's parasitics :-)

  Are you sure? yes | no

esot.eric wrote 04/02/2017 at 23:39 point

LOL 100 tubes!

I have a (comparatively much smaller) box of 'em from old amps and things I've been meaning to do *something* with... so inspire me!

And don't build just another tube amp, dammit!

Actually, I have a kids' science-projects book from way back when that, if I recall correctly, describes some uber-simple single-tube projects, surely not digital, so probably not up your alley ;p

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/03/2017 at 00:48 point

hey but digital and analog are tightly related and I'm here to learn :-D Thanks for the pointer !

I'll look again, closely, at the ENIAC diagrams for more inspiration :-P

  Are you sure? yes | no

esot.eric wrote 04/17/2017 at 05:34 point

Maybe you should make a Tube Class-D amplifier ;)

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/17/2017 at 07:00 point

puhleeeez dude, you're going to wake Brian up :-D

  Are you sure? yes | no

Tom Anderson wrote 04/11/2017 at 06:06 point

A good tube project would be a Theremin such as this one:

Tubes have a high input impedance, which should not go to waste! Let me plug my blog post about understanding tubes again while I am at it: . The reason I am plugging it again is that it covers triodes and diodes, which is all that is in the Theremin.

  Are you sure? yes | no

Yann Guidon / YGDES wrote 04/16/2017 at 16:57 point

Thank you again Tom.

Hopefully I can find good tutorials for using tubes/valves for logic gates :-)

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates