Blinking An LED With A Single Transistor

Let’s say you want to blink an LED. You might grab an Arduino and run the Blink sketch, or you might lace up a few components to a 555. But you needn’t go so fancy! [The Design Graveyard] explains how this same effect can be achieved with a single transistor.

The circuit in question is rather odd at first blush. The BC547 NPN transistor is hooked up between an LED and a resistor leading to a 12V DC line, with a capacitor across the emitter and collector. Meanwhile, the base is connected to… nothing! It’s just free-floating in the universe of its own accord. You might expect this circuit to do nothing at all, but if you power it up, the LED will actually start to flash.

The mechanism at play is relatively simple. The capacitor charges to 12 volts via the resistor. At this point, the transistor, which is effectively just acting as a poor diode in this case, undergoes avalanche breakdown at about 8.5 to 9 volts, and starts conducting. This causes the capacitor to discharge via the LED, until the voltage gets low enough that the transistor stops conducting once again. Then, the capacitor begins to charge back up, and the cycle begins again.

It’s a weird way to flash an LED, and it’s not really the normal way to use a transistor—you’re very much running it out of spec. Regardless, it does work for a time! We’ve looked at similar circuits before too. Video after the break.

Continue reading “Blinking An LED With A Single Transistor”

Fail Of The Week: Beaker To Benchy More Bothersome Than Believed

Making nylon plastic from raw chemicals used to be a very common demo; depending where and when you grew up, you may well have done it in high school or even earlier. What’s not common is taking that nylon and doing something with it, like, say extruding it into filament to make a benchy. [Startup Chuck] shows us there might be a reason for that. (Video, embedded below.)

It starts out well enough: sebacoyl chloride and hexamethaline diamine mix up and do their polymerizing tango to make some nylon, just like we remember. (Some of us also got to play with mercury bare-handed; safety standards have changed and you’ll want to be very careful if you try this reaction at home). The string of nylon [Chuck] pulls from the beaker even looks a little bit like filament for a second, at least until it breaks and gets tossed into a blobby mess. We wonder if it would be possible to pull nylon directly into 1.75 mm filament with the proper technique, but quality control would be a big issue. Even if you could get a consistent diameter, there’d likely be too much solvent trapped inside to safely print.

Of course, melting the nylon with a blowtorch and trying to manually push the liquid through a die to create filament has its own quality control problems. That’s actually where this ends: no filament, and definitely no benchy. [Chuck] leaves the challenge open to anyone else who wants to take the crown. Perhaps one of you can show him how it’s done. We suspect it would be easiest to dry the homemade nylon and shred it into granules and only then extrude them, like was done with polypropylene in this mask-recycling project. Making filament from granules or pellets is something we’ve seen more than once over the years.

If you really want to make plastic from scratch, ordering monomers from Sigma-Aldrich might not cut it for ultimate bragging rights; other people are starting with pulling CO2 from the atmosphere.

Thanks to [Chaz] for the tip! Remember that the tips line isn’t just for your successes– anything interesting can find its home here.

Continue reading “Fail Of The Week: Beaker To Benchy More Bothersome Than Believed”

Word Processing: Heavy Metal Style

If you want to print, say, a book, you probably will type it into a word processor. Someone else will take your file and produce pages on a printer. Your words will directly turn on a laser beam or something to directly put words on paper. But for a long time, printing meant creating some physical representation of what you wanted to print that could stamp an imprint on a piece of paper.

The process of carving something out of wood or some other material to stamp out printing is very old. But the revolution was when the Chinese and, later, Europeans, realized it would be more flexible to make symbols that you could assemble texts from. Moveable type. The ability to mass-produce books and other written material had a huge influence on society.

But there is one problem. A book might have hundreds of pages, and each page has hundreds of letters. Someone has to find the right letters, put them together in the right order, and bind them together in a printing press’ chase so it can produce the page in question. Then you have to take it apart again to make more pages. Well, if you have enough type, you might not have to take it apart right away, but eventually you will.

Continue reading “Word Processing: Heavy Metal Style”

Classy Desk Simulates Beehive Activity

Beehives are impressive structures, an example of the epic building feats that are achievable by nature’s smaller creatures. [Full Stack Woodworking] was recently building a new work desk, and decided to make this piece of furniture a glowing tribute to the glorious engineering of the bee. (Video, embedded below.)

The piece is a conventional L-shaped desk, but with a honeycomb motif inlaid into the surface itself. [Full Stack Woodworking] started by iterating on various designs with stacked hexagons made out of laser cut plywood and Perspex, filled with epoxy. Producing enough hexagons to populate the entire desk was no mean feat, requiring a great deal of cutting, staining, and gluing—and all this before the electronics even got involved! Naturally, each cell has a custom built PCB covered in addressable LEDs, and they’re linked with smaller linear PCBs which create “paths” for bees to move between cells.

What’s cool about the display is that it’s not just running some random RGB animations. Instead, the desk has a Raspberry Pi 5 dedicated to running a beehive simulation, where algorithmic rules determine the status (and thus color) of each hexagonal cell based on the behavior of virtual bees loading the cells with honey. It creates an organic, changing display in a way that’s rather reminiscent of Conway’s Game of Life.

It was a huge build, but the final result is impressive. We’ve featured some other great custom desks over the years too. Video after the break.

Continue reading “Classy Desk Simulates Beehive Activity”

Ask Hackaday: When Good Lithium Batteries Go Bad

Friends, I’ve gotten myself into a pickle and I need some help.

A few years back, I decided to get into solar power by building a complete PV system inside a mobile trailer. The rationale for this doesn’t matter for the current discussion, but for the curious, I wrote an article outlining the whole design and build process. Briefly, though, the system has two adjustable PV arrays mounted on the roof and side of a small cargo trailer, with an integrated solar inverter-charger and a 10-kWh LiFePO4 battery bank on the inside, along with all the usual switching and circuit protection stuff.

It’s pretty cool, if I do say so myself, and literally every word I’ve written for Hackaday since sometime in 2023 has been on a computer powered by that trailer. I must have built it pretty well, because it’s been largely hands-off since then, requiring very little maintenance. And therein lies the root of my current conundrum.

Continue reading “Ask Hackaday: When Good Lithium Batteries Go Bad”

Nanochat Lets You Build Your Own Hackable LLM

Few people know LLMs (Large Language Models) as thoroughly as [Andrej Karpathy], and luckily for us all he expresses that in useful open-source projects. His latest is nanochat, which he bills as a way to create “the best ChatGPT $100 can buy”.

What is it, exactly? nanochat in a minimal and hackable software project — encapsulated in a single speedrun.sh script — for creating a simple ChatGPT clone from scratch, including web interface. The codebase is about 8,000 lines of clean, readable code with minimal dependencies, making every single part of the process accessible to be tampered with.

An accessible, end-to-end codebase for creating a simple ChatGPT clone makes every part of the process hackable.

The $100 is the cost of doing the computational grunt work of creating the model, which takes about 4 hours on a single NVIDIA 8XH100 GPU node. The result is a 1.9 billion parameter micro-model, trained on some 38 billion tokens from an open dataset. This model is, as [Andrej] describes in his announcement on X, a “little ChatGPT clone you can sort of talk to, and which can write stories/poems, answer simple questions.” A walk-through of what that whole process looks like makes it as easy as possible to get started.

Unsurprisingly, a mere $100 doesn’t create a meaningful competitor to modern commercial offerings. However, significant improvements can be had by scaling up the process. A $1,000 version (detailed here) is far more coherent and capable; able to solve simple math or coding problems and take multiple-choice tests.

[Andrej Karpathy]’s work lends itself well to modification and experimentation, and we’re sure this tool will be no exception. His past work includes a method of training a GPT-2 LLM using only pure C code, and years ago we saw his work on a character-based Recurrent Neural Network (mis)used to generate baroque music by cleverly representing MIDI events as text.

Don’t Believe Planck’s Constant? Measure It Yourself

We aren’t sure if [Looking Glass Universe] didn’t trust the accepted number for Planck’s constant, or just wanted the experience of measuring it herself. Either way, she took some LEDs and worked out the correct figure. Apparently, it hasn’t changed since we first measured it in 1916. But it’s always good to check.

The constant, if you need a refresher, helps explain things like why the color of light changes how the photoelectric effect manifests, and is at the root of quantum physics. LEDs are perfect for this experiment because, of course, they come in different colors. You essentially use a pot to tune down the LED until it just reaches the point where it is dark. Presuming you know the wavelength of the LED, you can estimate Planck’s constant from that and the voltage across the virtually ready-to-light LED. We might have used the potentiometer in a voltage divider configuration, but it should work either way.

The experiment showed that even a disconnected LED emits a few stray photons. But it was still possible to interpret the results. The constant is very tiny, so you’ll want your scientific calculator get do the math or, as she used, Wolfram Alpha.

The first result was off by the alarming amount of 1 x 10-40. No, that’s not alarming at all. That number is amazingly small.

This is a fairly common home physics experiment. You can do it quick, like [Looking Glass] did, or you can build something elaborate.

Continue reading “Don’t Believe Planck’s Constant? Measure It Yourself”