Tiny ThinkPad Plays Tiny Games

[Paul Klinger] can’t seem to get enough of building tiny, amazing gaming rigs, and we love him for that. They combine two of our favorites: miniatures and portable gaming. His newest creation honors the form of the formidable ThinkPad.

Of course it has the red nipple and lid LED—wouldn’t be a ThinkPad without ’em. ThinkTiny’s nipple is a 5-way joystick that plays Snake, Tetris, Lunar Lander, and more on an OLED screen. Like its predecessor the Tiny PC, [Paul] used an ATtiny1614, which (FYI) has a new one-wire UDPI interface. He can easily reprogram it through pogo pin holes built into the case.

There are some nice stylistic details at play here, too. The lid LED is both delivered and diffused by a 2mm grain of fiber-optic cable. And [Paul] printed the cover with a color change to transparent filament to make the Think logo and the charging LEDs shine through. Maneuver your way past the break to see it in action.

If you haven’t leveled up to AVR programming yet, introduce yourself to Arduboy.

Continue reading “Tiny ThinkPad Plays Tiny Games”

Rock, Paper, Neural Net

You might think the game of Rock Paper Scissors is just the random chance, but that’s not true. There is a strategy for Rock Paper Scissors, multiple ones in fact, and the best human players can consistently beat any Joe Schmoe off the street. But what about computers? [Paul] answered that question with a tiny little keychain dongle that can beat you at Rock Paper Scissors.

This is a neural network, and you need to train a neural network, so where did [Paul] get all that data? roshambo.me offers thousands of paper rock scissor games, and trained the network on more than 85,000 human games, along with about 10,000 simulated games. Rock Paper Scissors isn’t a complicated game at all, and the entire neural network is stored on an ATtiny1614 microcontroller. The calculations are done as floats, even. That’s how non-computationally intensive this project is.

Building a neural network is one thing, but putting it in a handy keychain enclosure is something else. This handsome device fits on a PCB just larger than a 2032 coin cell battery and is enclosed in a 3D printed case. The buttons are 3D printed as well, with some clever application of fiber optic as light pipes for the LEDs. The end result is something that is slightly better than random chance at Rock Paper Scissors and shows off some matrix programming skills. Check out the video below.

Continue reading “Rock, Paper, Neural Net”

Getting To Know Every Bit Of An ATtiny13

We recently heard it said of a hacker who pulled off a particularly nice VGA hack on an 8-bit microcontroller: “He knows all the bits, personally.” High praise, indeed. If you want to get on a first-name basis with a ton of transistors, then have a look at [Heinz D]’s Vacation Course in ATtiny13 Assembler (original in German, translated into English by robots here).

But be warned, this isn’t the easy way to learn AVRs. Not content with simply stripping away every layer of abstraction, this month-long “course” in AVR assembly starts off programming the chip initially with just two pushbuttons in its native machine language of high and low voltages. But still, especially if you can get a few assignments done in one sitting, you’re writing in the relative splendor of assembly language and uploading code with a proper programmer before long, because there’s a real limit to how much code one can toggle in before going mad.

There’s a beautiful minimalism to this entirely ground-up approach, and maybe it’s an appropriate starting point for learning how the machine works at its lowest level. At any rate, you’ll be able to lord it over the Arduino crew that you were able to get blink.ino up and running with just a pair of mechanical contacts and a battery. Real programmers

And once you’ve mastered AVR assembly language, you can recycle those two buttons to learn I2C or SPI. What other protocols are there that don’t have prohibitive timeouts? What’s the craziest code that you’ve ever entered bit by bit?

Keeping Birds At Bay With An Automated Spinning Owl

There’s nothing wrong with building something just to build it, but there’s something especially satisfying about being able to solve a real-world problem with a piece of gear you’ve designed and fabricated. When all the traditional methods to keep birds from roosting on his mother’s property failed, [MNMakerMan] decided to come up with a more persuasive option: a solar powered spinning owl complete with expandable batons.

We imagine the owl isn’t strictly necessary when you’re whacking the birds with a metal bar to begin with, but it does add a nice touch. Perhaps it will even serve to deter some of the less adventurous birds before they get within clobbering distance, which is probably in their best interest. [MNMakerMan] says the rotation speed of the bars seems low enough that he doesn’t think it will do the birds any physical harm, but it’s still got to be fairly unpleasant.

At first glance you might think that this contraption simply spins when the small 10 watt photovoltaic panel next to it catches the sun, but there’s actually a bit more to it than that. Sure he probably could just have it spin constantly whenever the sun is up, but instead [MNMakerMan] is using a ATtiny85 to control the 11 RPM geared DC motor with a IRF540 MOSFET. By adding a DS3231 RTC module into the mix, he’s able to not only accurately control when the spinner begins and ends its bird-busting shift, but implement timed patterns rather than running it the whole time. All of which can of course be fine-tuned by adjusting a couple variables and reflashing the chip.

We’ve seen plenty of automated systems for keeping cats away, and of course squirrels are a common target for such builds as well, but devices to deter birds are considerably less common among these pages. So it would seem that, at least for now, [MNMakerMan] has the market cornered on solar bird smashing gadgets. We’re sure Mom’s very proud.

Continue reading “Keeping Birds At Bay With An Automated Spinning Owl”

Tiny Two-Digit Thermometer Has Long Battery Life

Like most of his work, this tiny two-digit thermometer shows that [David Johnson-Davies] has a knack for projects that make efficient use of hardware. No pin is left unused between the DS18B20 temperature sensor, the surface mount seven-segment LED displays, and the ATtiny84 driving it all. With the temperature flashing every 24 seconds and the unit spending the rest of the time in a deep sleep, a good CR2032 coin cell should power the device for nearly a year. The board itself measures only about an inch square.

You may think that a display that flashes only once every 24 seconds might be difficult to actually read in practice, and you’d be right. [David] found that it was indeed impractical to watch the display, waiting an unknown amount of time to read some briefly-flashed surprise numbers. To solve this problem, the decimal points flash shortly before the temperature appears. This countdown alerts the viewer to an incoming display, at the cost of a virtually negligible increase to the current consumption.

[David]’s project write-up explains how everything functions. He also steps through the different parts of the source code to explain how everything works, including the low power mode. The GitHub repository holds all the source files, and the board can also be ordered direct from OSH Park via their handy shared projects feature.

Low power consumption adds complexity to projects, but the payoffs can easily be worth the time spent implementing them. We covered a detailed look into low power WiFi microcontrollers that is still relevant, and projects like this weather station demonstrate practical low power design work.

DIY Button Matrix Lights Up And Speaks I2C

[David Johnson-Davies] always wanted an illuminated button matrix for projects, but cost was never very friendly. That all changed when he discovered a cheap source of illuminated pushbuttons on Aliexpress, leading to this DIY 4×4 illuminated button matrix design which communicates over I2C. The button states can be read independently of setting the light pattern, and an optional interrupt signal gets pulled low whenever there is a change detected. Not bad for one PCB plus about $10-worth in components!

The device uses every single pin on an ATtiny88, and because each button gets its own pin the keypresses can be detected with pin-change interrupts. The state reporting of buttons over I2C is unambiguous, even when multiple buttons are pressed simultaneously. A simple protocol provides all the needed functionality, and all connections are brought to the board’s edge to allow for easily tiling multiple panels.

The GitHub repository contains the code and PCB files and [David] helpfully shared the board files to OSH Park and PCBWay for easy ordering. In addition, he provides two demos (Tacoyaki and Tacoyaki+) which are games related to the classic Lights Out to show off the matrix.

Jumbo LEDs Make For A Handy ATtiny Beacon

Inspiration can come from anywhere. Sometimes it’s just a matter of seeing an interesting part that you want to fiddle around with badly enough that you end up developing a whole idea, and potentially product, around it. That’s how [Bobricius] found himself creating this very slick little warning beacon, and looking at the end result, we think he made the right decision.

The Kingbright DLC-6SRD “jumbo” LED is actually six individual emitters built into a plastic diffuser. Interfacing with the device is simple enough; each LED has its normal anode and cathode leg, all you need to do is power them up. What [Bobricius] has created is a simple PCB design that the DLC-6SRD can plug right into, complete with a 2032 coin cell holder on the opposite side.

Of course, just lighting up all six elements at the same time wouldn’t be very interesting. [Bobricius] is controlling them individually right off of the digital pins of an ATtiny10 with the help of some Charlieplexing. This makes all kinds of interesting patterns possible, and as demonstrated in the video after the break, the current iteration of the project uses some very simple code to “rotate” the LED as if it was the flasher on an emergency vehicle.

The addition of a few blinking LEDs can make a world of difference in terms of nighttime visibility, so a cheap stick-on module that adds such a distinctive light pattern could be a very important safety device. It could also be useful for UAVs, following the FAA’s new rules which would mandate anti-collision lights for night flying.

Continue reading “Jumbo LEDs Make For A Handy ATtiny Beacon”