[Brian Pugh] has shared a cool new project that simultaneously runs on desktop Python and MicroPython – the Belay library. This library lets you control a MicroPython device seamlessly from your Python code – interacting with real-world things like analog/digital trinkets, servos, Neopixels and displays, without having to create your own firmware or APIs.
You need a serial-connected MicroPython board – even an ESP8266 should do. Then, you can intersperse your Python code with MicroPython-written functions, and call them whenever you need your connected device to do something – keeping the entire logic of your project within a single device. [Brian] provides quite a few examples, even for more complex things like displays. No doubt, there are limitations, but this looks to be a powerful tool in a hacker’s arsenal.
Readers might be reminded of an Arduino library called Firmata – an old-time way to do such connectivity. We’ve also previously covered a Pi Pico firmware that does a similar thing, and even features a breakout board for all your experimentation needs!
Continue reading “Your MicroPython Board Can Be Your Tinkering Peripheral”
Pin art is one of those things that simply cannot be left alone if it’s within arms reach, and inevitably end up with a hand or face imprint. [hugs] is also fascinated by them, so he designed the PinThing, a mechanized pin art display.
The PinThing pin diameters are much larger than standard pin art, but this is to fit small geared DC motors. Each pin is a short 3D-printed lead screw mechanism. The motors are driven with a stack of motor driver shields on top of an Arduino Uno, which uses Firmata to receive instructions over serial from a Node.js app using the Johnny-Five library. This may be a simple 3×5 proof of concept, but then it could be used for everything from displays to interactive table surfaces.
One of the challenges with pixelated mechanical displays like this, the inFORM from MIT, or even flip dot displays, are the costs in actuators and driver electronics. A small 10×10 array requires 100 motors and drivers, which quickly adds up as you expand, even if individual components are quite cheap.
If you are willing to sacrifice instantaneous response from each pixel, you can use a mechanical multiplexer. It consists of some sort of moving carriage behind the display with mounted actuators, so you’ll only need an actuator per row, not for every pin. This also means the pins can be closer together since the actuators can be staggered on the carriage.
PinThing project was an entry to the Rethink Displays Challenge of the 2021 Hackaday Prize, for which the finalists were just announced.
Continue reading “PinThing Mechanizes Pin Art”
Inspired by the creative genius of Martin Molin of Wintergatan fame, [iSax] set out to create a robotic MIDI-controlled trombone. It takes years for humans to develop the control and technique required to play the trombone well as the tone produced into the mouthpiece (embouchure) is a tricky combination of air pressure, lip tension, airflow, resonance in the mouth, and other sources of complex pressure.
[iSax] gives a thorough walkthrough of the machine, which is powered by two separate sources of air, one for the position of the slide and the other for producing sound. A potentiometer provides feedback on the position of the slide and a servo controls the flow rate into the silicone resonance chamber. The chamber can be tuned via a stepper motor that applies pressure, slightly altering the chamber’s frequency and pressure. An Arduino with Firmata allows the device to controlled easily from any host computer. A detailed writeup in PDF form is on the Hackday.io project page.
As you can imagine, simulating a human mouth is a daunting task and the number of variables meant that [iSax] ended up with something only vaguely trombone-like. While ultimately it didn’t turn out to be the astounding music machine that [iSax] hoped, it did end up being a fun feat of engineering we can appreciate and admire. Progress towards automatic brass instruments seems to be coming slowly as we saw similar results with this robotic trumpet. Maybe someday we’ll have robot brass sections, but not today.
Continue reading “76-bit Trombones Led By The Big MIDI File”
Microcontrollers are cool, but sometimes the user interface options they can deliver are disappointing. The platform in question may not have the horsepower required to drive a decent screen, and often a web interface is undesirable for security or complexity reasons. Sometimes you just need a good software interface between chip and computer. Firmata is a protocol that’s designed to do just that, and [nanoflite] has brought it to the Commodore 64.
It’s a fun project, which allows one to use the C64’s charming retro graphics to interface with an Arduino-based project. Connection is achieved at 2400bps over the user port, which is plenty fast for most UI applications. [nanoflite] demonstrates the interface with an Arduino Uno and a Grove shield. The C64 is able to display the state of the LED, relay and servo outputs, as well as read the Arduino’s button and potentiometer inputs.
It’s an excellent way to integrate a Commodore 64 into a microcontroller setup without reinventing the wheel. We think it would make an awesome vintage interface to a home automation system or similar build. If you’re interested, but you don’t have a C64 of your own to play with, never fear – you can just build a new one.
[Dave] hosted a one day seminar at the Illinois Institute of Technology which focused on rapid electronics prototyping for those with little prior experience blinking those LEDs. As the defacto standard for novice prototypers it’s no surprise that he gave an Arduino to each team to use as the controller-computer interface. He started the day by getting the Firmata package up and running. Firmata is a set of libraries that make communications between software and a microcontrollers simple. In this case, each team developed a Flash game that used data from the Arduino as a control.
Several rudimentary games resulted from the day. We’ve embedded video of two of them after the break for your enjoyment. Lion Vs. Pig uses potentiometers, a distance sensor, and an arcade button to play a game of cat-and-mouse (well, Lion-and-Pig really). The other is Kick the Cat, a game that uses a flex sensor and force sensor combination as input. This is something of a virtual mini-basketball game that uses a springy material to launch a virtual feline at a target.
These teams already had a background in code, but the hardware was a new endeavor for them. Arduino helps to break down this cross-over barrier and we think this will result in more people to contribute to open source projects, and falling hardware prices due to a larger volume of demand.
Continue reading “Developing Physical Controllers For The Uninitiated”