Posts with «lcd» label

Spice Up the Humble 16×2 LCD with Big Digits

The 16×2 LCD display is a classic in the microcontroller world, and for good reason. Add a couple of wires, download a library, mash out a few lines of code, and your project has a user interface. A utilitarian and somewhat boring UI, though, and one that can be hard to read at a distance. So why not spice it up with these large-type custom fonts?

As [Vaclav Krejci] explains, the trick to getting large fonts on a display that’s normally limited to two rows of 16 characters each lies in the eight custom characters the display allows to be added to its preprogrammed character set. These can store carefully crafted patterns that can then be assembled to make reasonable facsimiles of the ten numerals. Each custom pattern forms one-quarter of the finished numeral, which spans what would normally be a two-by-two character matrix on the display. Yes, there’s a one-pixel wide blank space running horizontally and vertically through each big character, but it’s not that distracting.

Composing the custom patterns, and making sure they’re usable across multiple characters, is the real hack here, and [Vaclav] put a lot of work into that. He started out in Illustrator, but quickly switched to a spreadsheet because it allowed him to easily generate the correct binary numbers to pass to the display for each pattern. It seems to have really let his creative juices flow, too — he came up with 24 different fonts! Out favorite is the one he calls “Tron,” which looks a bit like the magnetic character recognition font on the bottom of bank checks. Everyone remembers checks, right?

Hats off to [Vaclav] for a creative and fun way to spice up the humble 16×2 display. We’d love to see someone pick this up and try a complete alphanumeric character set, although that might be a tall order with only eight custom characters to work with. Then again, if Bad Apple on a 16×2 is possible…

Hack a Day 07 Apr 19:30

Pushing the Limits of a 16×2 LCD with Bad Apple!!

While low-contrast, blue-on-slightly-less-blue 16-character by 2-line LCDs are extremely popular, they really are made specifically for alphanumeric use. They do an admirable job of displaying a few characters, but they don’t exactly spring to mind as a display for non-character purposes. But displaying video on a 16×2 LCD is possible, as long as you’re willing to stretch the definition of “video” a bit and use some imagination while watching.

Normally, a 16×2 display can only display a single character in each spot, chosen from a fixed character set. But [arduinocelantano] was able to leverage the eight custom character slots the display allows to build up images from arbitrary 5×8 pixel bitmaps. After using ffmpeg to scale the original video to a viewport of eight characters, a Python program was used to turn every frame of the scaled video into code to generate the custom bitmaps for each chunk of the viewport. Even with the low refresh rate of the display and the shrunken frame size, the result is a recognizable video, helped no doubt by the choice of the shadow-puppet Bad Apple!! video. Check it out after the break to see how it looks.

We saw a similar rendering of the same video on LCD a while back; that effort was amazing in that it was an EEPROM-only implementation, along with a somewhat bigger LCD with better contrast. That project served as inspiration for [arduinocelantano]’s build here, which in some ways we think looks a bit better — perhaps it’s the inverted pixels. Either way, hats off to both builders for pushing past the normal constraints and teaching us something interesting.

The HackadayPrize2022 is Sponsored by:
Hack a Day 14 Jun 12:00

Tiny TV Tells the Temperature Tale

Once upon a time, we would run home from the bus stop to watch Gargoyles and Brady Bunch reruns on the family TV, a late-1970s console Magnavox number that sat on the floor and was about 50% more cabinet than CRT. The old TV, a streamlined white Zenith at least ten years older, had been relegated to the man cave in the basement. It looked so mod compared to the “new” TV, but that’s not the aesthetic my folks were after. They wanted their electronics to double as furniture.

This little TV is a happy medium between the two styles, and for us, it’s all about those feet. But instead of cartoons, it switches between showing the current weather and the top news headlines. Inside that classy oak cabinet is an LCD, an ESP32, and an SD card module. The TV uses OpenWeatherMap and pulls the corresponding weather image from the SD card based on time of day — light images for day, and dark images for night.

We love that it shows the SMPTE color bars, aka the standard American TV test pattern as it switches between weather and news. After showing the top headlines, it automatically switches back to the weather channel. Be sure to check out the short demo video after the break.

Do you like your tiny televisions in strange places? Here’s one you can use to trim your tree this year.

Custom Instrument Cluster for Aging Car

All of the technological improvements to vehicles over the past few decades have led to cars and trucks that would seem borderline magical to anyone driving something like a Ford Pinto in the 1970s. Not only are cars much safer due to things like crumple zones, anti-lock brakes, air bags, and compulsory seat belt use, but there’s a wide array of sensors, user interfaces, and computers that also improve the driving experience. At least, until it starts wearing out. The electronic technology in our modern cars can be tricky to replace, but [Aravind] at least was able to replace part of the instrument cluster on his aging (yet still modern) Skoda and improve upon it in the process.

These cars have a recurring problem with the central part of the cluster that includes an LCD display. If replacement parts can even be found, they tend to cost a significant fraction of the value of the car, making them uneconomical for most. [Aravind] found that a 3.5″ color LCD that was already available fit perfectly in the space once the old screen was removed, so from there the next steps were to interface it to the car. These have a CAN bus separated from the main control CAN bus, and the port was easily accessible, so an Arduino with a RTC was obtained to handle the heavy lifting of interfacing with it.

Now, [Aravind] has a new LCD screen in the console that’s fully programmable and potentially longer-lasting than the factory LCD was. There’s also full documentation of the process on the project page as well, for anyone else with a Volkswagen-adjacent car from this era. Either way, it’s a much more economical approach to replacing the module than shelling out the enormous cost of OEM replacement parts. Of course, CAN bus hacks like these are often gateway projects to doing more involved CAN bus projects like turning an entire vehicle into a video game controller.

Automated Watering Machine Has What Plants Crave: Fertilizer

We’ve seen countless automated plant care systems over the years, but for some reason they almost never involve the secret sauce of gardening — fertilizer. But [xythobuz] knows what’s up. When they moved into their new flat by themselves, it was time to spread out and start growing some plants on the balcony. Before long, the garden was big enough to warrant an automated system for watering and fertilizing.

This clever DIY system is based around a 5L gravity-fed water tank with solenoid control and three [jugs] of liquid fertilizer that is added to the water via peristaltic pump. Don’t worry, the water tank has float switches, and [xythobuz] is there to switch it off manually every time so it doesn’t flood the flat.

On the UI side, an Arduino Nano clone is running the show, providing the LCD output and handling the keypad input. The machine itself is controlled with an ESP32 and a pair of four-channel relay boards that control the inlet valve, the four outlet valves, and the three peristaltic pumps that squirt out the fertilizer. The ESP also serves up a web interface that mimics the control panel and adds in the debug logs. These two boards communicate using I²C over DB-9, because that’s probably what [xythobuz] had lying around. Check out the demo video after the break, and then go check on your own plants. They miss you!

Don’t want to buy just any old peristaltic pumps? Maybe you could print your own.

Classical Poultry Conditioning is a Bird-Brained Scheme

A while back, [Kutluhan Aktar] was trying to hack their chickens, quails, and ducks for higher egg production and faster hatching times by using a bit of classical conditioning. That is, feeding them at the same time every day while simultaneously exposing them to sound and light. Once [Kutluhan] slipped enough times, they hatched a plan to build an automatic feeder.

This fun rooster-shaped bird feeder runs on an Arduino Nano and gets its time, date, and temperature info from a DS3231 RTC. All [Kutluhan] has to do is set the daily feeding time. When it comes, a pair of servos and a pan-tilt kit work together to invert a Pringles can filled with food pellets. A piezo buzzer and a green LED provide the sound and light to help with conditioning. Scratch your way past the break to see it in action.

If [Kutluhan] gets tired of watching the birds eat at the same time every day, perhaps a trash-for-treats training program could be next on the list.

Via r/duino

Greeking out with Arduinos

Learning a new language is hard work, but they say that the best way to learn something is to teach it. [Angeliki Beyko] is learning Greek, and what better way to teach than to build a vocabulary flash-card game from Arduinos, color screens, 1602 text screens, and arcade buttons? After the break, we have a video from the creator talking about how to play, the hardware she chose, and what to expect in the next version.

Pegboard holds most of the hardware except the color screens, which are finicky when it comes to their power source. The project is like someone raided our collective junk drawers and picked out the coolest bits to make a game. Around the perimeter are over one hundred NeoPixels to display the game progress and draw people like a midway game. Once invested, you select a category on the four colored arcade buttons by looking at the adjacent LCD screens’ titles. An onboard MP3 shield reads a pseudo-random Greek word and displays it on the top-right 1602 screen in English phonetics. After that, it is multiple choice with your options displaying in full-color on four TFT monitors. A correct choice awards you a point and moves to the next word, but any excuse to mash on arcade buttons is good enough for us.

[Angeliki] does something we see more often than before, she’s covering what she learned, struggled with, would do differently, and how she wants to improve. We think this is a vital sign that the hacker community is showcasing what we already knew; hackers love to share their knowledge and improve themselves.

Typing Greek with a modern keyboard will have you reaching for an alt-code table unless you make a shortcut keyboard, and if you learn Greek, maybe you can figure out what armor they wore to battle.

Cybercube Makes a Great Computing Companion

Oh, sure, there have been a few cube-shaped PCs over the years, like the G4 and the NeXT cube. But can they really be called cubes when the display and the inputs were all external? We think not.

[ikeji] doesn’t think so either, and has created a cube PC that puts them all to shame. Every input and output is within the cube, including our favorite part — the 48-key ortholinear keyboard, which covers two sides of the cube and must be typed on vertically. (If you’ve ever had wrist pain from typing, you’ll understand why anyone would want to do that.) You can see a gif of [ikeji] typing on it after the break.

Inside the 3D printed cube is a Raspberry Pi 4 and a 5″ LCD. There’s also an Arduino Pro Micro for the keyboard matrix, which is really two 4×6 matrices — one for each half. There’s a 6cm fan to keep things cool, and one panel is devoted to a grille for heat output. Another panel is devoted to vertically mounting the microcontrollers and extending the USB ports.

Don’t type on me or my son ever again.

When we first looked at this project, we thought the tiny cube was a companion macro pad that could be stored inside the main cube. It’s really a test cube for trying everything out, which we think is a great idea and does not preclude its use as a macro pad one of these days. [ikeji] already has plenty of plans for the future, like cassette support, an internal printer, and a battery, among other things. We can’t wait to see the next iteration.

We love a good cyberdeck around here, and it’s interesting to see all the things people are using them for. Here’s a cyberduck that quacks in Python and CircuitPython.

Over-Engineered Single Button Timer

Feature creep is typically something to be avoided, since watching a relatively simple project balloon into a rat’s nest of complexity often leads to ineffective, or even abandoned, projects. On the other hand, if you can maintain a tight focus, it’s not always a bad thing. [cbm80Amiga] shows us how to drill down and add specific features in this single-button timer without losing focus on what the original project was all about.

The timer is based on an Arduino Pro Mini and an HX1230 LCD with a simple piezo speaker for audible alerts. A single button controls operation of the timer, with short presses incrementing each digit and long presses moving on to the next digit. Controlling button presses this finely is a project in its own, but then [cbm80Amiga] moves on to other features such as backlight control, low power modes which allow it to operate for around two years on a single battery charge, preset times for various kitchen uses, and different appearance settings.

Honestly we aren’t sure how you could cram any more features on this timer without fundamentally altering the designed simplicity. It doesn’t fall into the abyss of feature creep while being packed with features, and it’s another example of how keeping things simple is often a recipe for success.

Thanks to [Hari] for the tip!

Score Big Against Boredom with Tabletop Bowling

Bowling has been around since ancient Egypt and continues to entertain people of all ages, especially once they roll out the fog machine and hit the blacklights. But why pay all that money to don used shoes and drink watered-down beer? Just build a tabletop bowling alley in your spare time and you can bowl barefoot if you want.

Those glowing pins aren’t just for looks — the LEDs underneath them are part of the scoring system. Whenever a pin is knocked out of its countersunk hole, the LED underneath is exposed and shines its light on a corresponding light-dependent resistor positioned overhead. An Arduino Uno keeps track of of the frame, ball number, and score, and displays it on an LCD.

The lane is nearly six feet long, so this is more like medium-format bowling or maybe even skee-bowling. There are probably a number of things one could use for balls, but [lainealison] is using large ball bearings. Roll past the break to see it in action, but don’t go over the line!

Can’t keep your balls out of the gutter? Build a magic ball and make all wishful leaning more meaningful as you steer it down the lane with your body.