Hyperlinking Comes to GitHub via Extension

If you are browsing GitHub it is very tempting to open up the source code to some project and peek at how it works. The code view is easy to read, but the viewer lacks one important feature: the ability to click on an included file and find it. The Octolinker extension fixes that oversight.

If you want to try it without installing the extension, there is a mock-up demo available. Even though the demo wants you to click on specific things, if you don’t play by the rules it will still do the right thing and take you to either the code on GitHub or an appropriate page. You can even substitute the demo URL for github.com and try it out on any GitHub page without the extension.

The tool supports at least 20 languages although we were bemused to see that C and C++ were not among them. The developer claims that none of your source code is ever sent out of your browser by the extension. If you use Octolinker on a private repository, you also have to supply a GitHub API token and that’s never sent out of your browser, either, according to the web site.

The code (on GitHub, of course) has a plug in architecture, so it ought to be easy to add the language of your choice. If you crave pop up tool tips for source code in GitHub, check out OctoHint.

GitHub seems to have survived being bought by Microsoft without becoming tarnished. If you want to keep an eye on your GitHub properties, there’s always this project.

Posted in browser extension, chrome, github, Software Development, software hacks | Leave a comment

Divide To Conquer Capacitive Touch Problems

Back in the day, all of your music was on a shelf (or in milk crates) and the act of choosing what to listen to was a tangible one. [Michael Teeuw] appreciates the power of having music on demand, but misses that physical aspect when it comes time to “put something on”. His solution is a hardware controller that he calls MusicCubes.

Music cube makes selection using RFID, and touching to the right raises the volume level

This is a multi-part project, but the most recent rework is what catches our eye. The system uses cubes with RFID tags in them for each album. This part of the controller works like a charm, just set the cube in a recessed part of the controller — like Superman’s crystals in his fortress of solitude — and the system knows you’ve made your decision. But the touch controls for volume didn’t work as well. Occasionally they would read a false touch, which ends up muting the system after an hour or so. His investigations led to the discovery that the capacitive touch plates themselves needed to be smaller.

Before resorting to a hardware fix, [Michael] tried to filter out the false positives in software. This was only somewhat successful so his next attempt was to cut the large touch pads into four plates, and only react when two plates register a press at one time.

He’s using an MPR121 capacitive touch sensor which has inputs for up to 12-keys so it was no problem to make this change work with the existing hardware. Surprisingly, once he had four pads for each sensor the false-positives completely stopped. The system is now rock-solid without the need to filter for two of this sub-pads being activated at once. Has anyone else experienced problems with large plates as the touch sensors? Can this be filtered easily or is [Michael’s] solution the common way to proceed? Share your own capacitive touch sensor tips in the comments below!

Want to get a look at the entire project? Start with step one, which includes a table of contents for the other build logs.

Posted in capacitive touch, classic hacks, home entertainment hacks, MPR121, MusiCubes | Leave a comment

A Tetris Clock

We have had no shortage of clock projects over the years, and this one is entertaining because it spells the time out using Tetris-style blocks. The project looks good and is adaptable to different displays. The code is on GitHub and it relies on a Tetris library that has been updated to handle different displays and even ASCII text.

[Brian] wanted to use an ESP8266 development board for the clock, but the library has a bug that prevents it from working, so he used an ESP32 board instead. The board, a TinyPICO, has a breakout board that works well with the display.

There are also some 3D printed widgets for legs. If we’re honest, we’d say the project looks cool but the technology isn’t revolutionary. What we did find interesting though is that this is a good example of how open source builds on itself.

Of course, the library does a lot of the work, but according to [Brian] the it has several authors. [Tobias Bloom] started the code, and others have changed the library to draw ASCII characters and to support any display that uses the AdaFruit GFX-style library.

So while the code is simple, the result is impressive and is a result of [Brian] leveraging a lot of code from others — a great example of Open Source in action.

We looked at Brian’s use of this library for a YouTube subscription counter, but a clock has more universal appeal, we think — not everyone has a lot of YouTube subscribers. If you don’t have a life, you might try to recreate Tetris using the game of life.

Posted in Arduino Hacks, clock, clock hacks, ESP32, tetris | Leave a comment

Let The Cards Fall Where They May, With A Robotic Rain Man

Finally,  a useful application for machine vision! Forget all that self-driving nonsense and facial recognition stuff – we’ve finally got an AI that can count cards at the blackjack table.

The system that [Edje Electronics] has built, dubbed “Rain Man 2.0” in homage to the classic title character created by [Dustin Hoffman] for the 1988 film, aims to tilt the odds at the blackjack table away from the house by counting cards. He explains one such strategy, a hi-low count, in the video below, which Rain Man 2.0 implements with the help of a webcam and YOLO for real-time object detection. Cards are detected in any orientation based on their suit and rank thanks to an extensive training set of card images, which [Edje] generated synthetically via some trickery with OpenCV. A script automated the process and yielded a rich training set of 50,000 images for YOLO. A Python program implements the trained model into a real-time card counting application.

Rain Man 2.0 is an improvement over [Edje]’s earlier Tensor Flow card counter, but it still has limitations. It can’t count into a six-deck shoe as the fictional [Rain Man] could, at least not yet. And even though cheater’s justice probably isn’t all cattle prods and hammers these days, the hardware needed for this hack is not likely to slip past casino security. So [Edje] has wisely limited its use to practicing his card counting skills. Eventually, he wants to turn Rain Man into a complete AI blackjack player, and explore its potential for other games and to help the visually impaired.

Posted in 21, blackjack, card counting, cards, casino, cheats, gambling, Games, webcam, YOLO | Leave a comment

LEDSpicer Is An Open Source Light Controller For Your Arcade Machine

In this day and age of cheap and easy emulation, it’s more tempting than ever to undertake a home arcade cabinet build. If you want to show off, it’s got to have a light show to really pull the crowds in. To make that easier, [Guillermo] put together a software package by the name of LEDSpicer.

The project came about when [Guillermo] was working on his Linux-based MAME cabinet, and realised there were limited software options to control his Ultimarc LED board. As the existing solutions lacked features, it was time to get coding.

LEDSpicer runs on Linux only, and requires compilation, but that’s not a huge hurdle for the average MAME fanatic. It comes with a wide variety of animations, as well as tools for creating attract modes and managing LEDs during gameplay. There are even audio-reactive modes available for your gaming pleasure. It’s open source too, so it’s easy to tinker with if there’s something you’d like to add yourself.

It’s a great package that should help many arcade builders out there. LEDs can be used to great effect on a cabinet build; this marquee is a particularly good example. Video after the break.

Posted in arcade, arcade cabinet, classic hacks, led, mame | Leave a comment

SOICbite: A Program/Debug Connector for an SOIC Test Clip

The problem is well-known: programming and debug headers consume valuable board space and the connectors cost money. Especially troublesome are the ubiquitous 100-mil pin headers, not because they’re expensive, but because they’re huge, especially along the z-axis. If you’re building miniature devices, these things can take up a ridiculous amount of space. With some clever thinking, [Simon Merrett] has found a way to re-use something many of us already have — an SOIC-8 test clip — to connect to a special footprint on the PCB without requiring another connector. He calls the system SOICbite.

The SOIC clip attaches to a footprint consisting of eight pads, four on each side of the PCB, plus five non-plated-through holes, which serve to anchor the clip in place. The idea of mating a PCB footprint directly with a removable connector isn’t entirely new — Tag Connect has been doing this for a while, but the connectors are expensive and single-sourced. On the other hand, SOIC test clips of varying quality are available from a number of vendors, including dirt-cheap deals on your favorite websites. The one disadvantage we can see is that the SOICbite footprint must be at the edge of the PCB to properly mate with the clip. The savings in space and cost may well make up for this, however.

[Simon] has made his KiCAD footprint available in a GitHub repo, and has offered to host footprints for any other CAD package there as well. So, fire up your preferred tool and draw one up for him to get these things widely adopted, because we think this is a great idea.

For the commercial alternative, check out our coverage of Tag Connect back in 2014.

Posted in connector hacks, debugging tools, hardware, SOICbite | Leave a comment

Magic Record Stand Can Play Your Records For You

Vinyl remains a popular format, despite taking a huge hit in popularity for a couple decades while CDs ruled the roost. It has a charm that keeps it relevant, and likely will continue to do so until everyone who grew up with a record player dies out. In the meantime, [sp_cecamp] has come up with a great way to experience your collection, with the magic of modern technology. It goes by the name of Plynth.

Fundamentally, it’s a small record stand with an excellent party trick. The prototype consists of a 3D-printed body, which holds a record sleeve at an attractive angle for display. A camera built into the base then images the artwork. The first image taken is run through the Google Vision API, and further images are then run through OpenCV to identify the record. This data is then passed to the Spotify API to play the track. The whole process takes a couple of seconds, and the music is then pumped out of whatever streaming device is connected to the rig.

It’s a fun way to play your old records, and would be a welcome change to those tired of screaming at Siri to play Weezer (Blue Album), not Weezer (Green Album). For those interested, [sp_cecamp] has thrown up a site to gauge interest in the project, and may make a limited production run in future.

Of course, you could instead just go about building your own turntable. To each their own!

Posted in musical hacks, record, vinyl, Vinyl Record | Leave a comment

He Comes To Bury Sensors, Not To Praise Them

[Adosia] has some interesting videos about their IoT platform controlling self-watering plant pots. However, the video that really caught our eye was the experience in sealing up sensors that are going to be out in the field. Even if you aren’t using the exact sensors, the techniques are useful.

We would have expected to see potting compound, but that’s messy and hard to use so their process is simpler. First, a few coats of clear urethane sealant goes over the electronics. Next, heat shrink goes over the assembly. It isn’t ordinary heat shrink though, instead it’s the kind that has heat-activated adhesive inside.

If you haven’t seen adhesive-lined heat shrink, it is often sold as marine heat shrink — you can even find it under that name at Harbor Freight. You also see this sometimes in tape form as heat shrinkable electrical tape.

Heat shrink seems ubiquitous and commonplace, but it is actually a fairly recent and sophisticated creation. Creating it usually requires radiation and sophisticated polymer chemistry, and it has only been available since 1962. If you do try potting instead of this technique, our advice is to avoid the silicone and stick with a proper two-part epoxy.

Posted in heat shrink, how-to, potting, sealant, waterproofing, weatherproofing | Leave a comment

Mechanical Tremolo Does Things The Old-School Way

The word “tremolo” has a wide variety of meanings in the musical lexicon. A tremolo effect, in the guitar community at least, refers to a periodic variation in amplitude. This is often achieved with solid state electronics, but also recalls the sounds created by Hammond organs of years past with their rotating Leslie speakers. [HackaweekTV] decided to do things the old fashioned way, building a mechanical tremolo effect of his own (Youtube link, embedded below).

Electronically, the signal is simply passed through a linear audio potentiometer. The effect is generated by rapidly cycling this potentiometer up and down. The motion is achieved through a geared motor salvaged from a Roomba, which turns a cam. A sprung follower sits on top of the cam, and is attached to the potentiometer.

There were some challenges in development. Rigidity of the frame was an issue, and the follower had issues with snagging on the cam. However, with some careful iteration they were able to get everything up and running. The final project sounds great, and with the amplifier turned up, there’s no need to worry about the sound of the moving parts.

Naturally, you can always build a tremolo with a 555 instead. Video after the break.

Posted in guitar, guitar effect, musical hacks, tremolo | Leave a comment

IKEA Cloud Lamp Displays The Weather With An ESP8266

The IKEA DRÖMSYN is a wall mounted cloud night light that’s perfect for a kid’s room. For $10 USD, it’s just begging for somebody to cram some electronics in there and make it do something cool. Luckily for us, [Jodgson] decided to take on the challenge and turned this once simple lamp into a clever weather display. It even still works as an LED lamp, if you’re into that sort of thing.

After stripping out the original hardware, [Jodgson] installed a Wemos D1 Mini and a string of fourteen SK6812 RGB LEDs that run down the length of the cloud’s internal structure. Weather data is pulled down with the OpenWeatherMap API, and conditions are displayed through various lighting colors and effects.

Sunny days are represented with a nice yellow glow, and a cloudy forecast looks like…well it’s already a white cloud so that one’s pretty easy. If rain is expected the cloud turns blue and the bottom LEDs flicker a bit to represent raindrops. When there’s a thunderstorm, the cloud will intermittently flash random LEDs on the strip a bit brighter than their peers; a really slick effect that gets the point across immediately.

This isn’t the first time we’ve seen somebody take a cheap light from IKEA and turn it into something much more impressive with the ESP8266. Just like with that previous project, we wouldn’t be surprised to see this particular modification popping up more in the future.

Posted in led hacks, Microcontrollers, openweathermap, RGB LED, sk6812, weather display, wemos d1 mini | Leave a comment