Screenshot of AVRpascal

Pascal? On My Arduino? It’s More Likely Than You Think

The Arduino ecosystem is an amazing learning tool, but even those of us who love it admit that even the simplified C Arduino uses isn’t the ideal teaching language. Those of us who remember learning Pascal as our first “real” programming language in schools (first aside from BASIC, at least) might look fondly on the AVRPascal project by [Andrzej Karwowski].

[Andrzej] is using FreePascal’s compiler tools, and AVRdude to pipe compiled code onto the micro-controller. Those tools are built into his AVRPascal code editor to create a Pascal-based alternative to the Arduino IDE for programming AVR-based microcontrollers. The latest version, 3.3, even includes a serial port monitor compatible with the Arduino boards.

This guy, but with Pascal. What’s not to love?

The Arduino comparisons don’t stop there: [Andrzej] also maintains UnoLib, a Pascal library for the Arduino Uno and compatible boards with some of the functionality you’d expect from Arduino libraries: easy access to I/O (digital and analog ports) timers, serial communication, and even extras like i2c, LCD and sensor libraries.

He’s distributing the AVRPascal editor as freeware, but it is not open source. It’s too bad, because Pascal is a great choice for microcontrollers: compiled, it isn’t much slower than C, but it can be as easy to write as Python. Micropython shows there’s a big market for “easy” embedded programming; Pascal could help fill it in a more performant way. Is the one-man license holding this project back, or is it just that people don’t use Pascal much these days?

While AVR programming is mostly done in C, this is hardly the first time we’ve seen alternatives. While some have delved into the frightening mysteries of assembly, others have risen to higher abstraction to run LISP or even good old fashioned BASIC. Pascal seems like a good middle road, if you want to go off the beaten path away from C.

Via reddit.

Hide Capacitive Touch Buttons In Your Next 3D Print

Capacitive touch sensors are entirely in the domain of DIY, requiring little more than a carefully-chosen conductive surface and a microcontroller. This led [John Phillips] to ask why not embed such touch buttons directly into a 3D print?

Button locations and labels can be made as part of the 3D print, which is handy.

The process is not much different from that of embedding hardware like magnets or fasteners into 3D prints: one pauses the print at convenient spot, drops in the necessary hardware, then resumes printing. It’s more or less the same for embedding a touch-sensitive button, but [John] has a few tips to make things easier.

[John] suggests using a strip of copper tape, one per touch pad, and embedding it into the print near the surface. His preference is three layers in, putting the copper tape behind 0.6 mm of plastic when using standard 0.20 mm layer heights.

Copper tape makes a good capacitive touch sensor, and the adhesive on the tape helps ensure it stays in place as the 3D printer seals it in on subsequent passes.

Copper tape is also easy to solder to, so [John] leaves a small hole over the copper — enough to stick in a wire and tack it down with the tip of a soldering iron and a blob of solder after the print is complete. It might not be ideal soldering conditions, but if things get a little melty on the back side it’s not the end of the world.

On the software side capacitive touch sensors can be as simple as using an Arduino library for the purpose but [John] rolled his own code, so give it a peek.

This reminds us a bit of another way to get a capacitive touch sensor right up against some plastic: a simple spring can do the trick.

A black and white device sits on a beige table. A white rotary knob projects out near the base of it's rectangular shape nearest the camera. Near it is a black rectangular section of the enclosure with six white dots protruding through holes to form a braille display. A ribbon cable snakes out of the top of the enclosure and over the furthest edge of the device, presumably connecting to a camera on the other side of the device.

This Polaroid-esque OCR Machine Turns Text To Braille In The Wild

One of the practical upsides of improved computer vision systems and machine learning has been the ability of computers to translate text from one language or format to another. [Jchen] used this to develop Braille Vision which can turn inaccessible text into braille on the go.

Using a headless Raspberry Pi 4 or 5 running Tesseract OCR, the device has a microswitch shutter to take a picture of a poster or other object. The device processes any text it finds and gives the user an audible cue when it is finished. A rotary knob on the back of the device then moves the braille display pad through each character. When the end of the message is reached, it then cycles back to the beginning.

Development involved breadboarding an Arduino hooked up to some MOSFETs to drive the solenoids for the braille display until the system worked well enough to solder together with wires and perfboard. Everything is housed in a 3D printed shell that appears similar in size to an old Polaroid instant camera.

We’ve seen a vibrating braille output prototype for smartphones, how blind makers are using 3D printing, and are wondering what ever happened with “tixel” displays? If you’re new to braille, try 3D printing your own trainer out of TPU.

Continue reading “This Polaroid-esque OCR Machine Turns Text To Braille In The Wild”

Experience Other Planets With The Gravity Simulator

As Earthlings, most of us don’t spend a lot of extra time thinking about the gravity on our home planet. Instead, we go about our days only occasionally dropping things or tripping over furniture but largely attending to other matters of more consequence. When humans visit other worlds, though, there’s a lot more consideration of the gravity and its effects on how humans live and many different ways of training for going to places like the Moon or Mars. This gravity simulator, for example, lets anyone experience what it would be like to balance an object anywhere with different gravity from Earth’s.

The simulator itself largely consists of a row of about 60 NeoPixels, spread out in a line along a length of lightweight PVC pipe. They’re controlled by an Arduino Nano which has a built-in inertial measurement unit, allowing it to sense the angle the pipe is being held at as well as making determinations about its movement. A set of LEDs on the NeoPixel strip is illuminated, which simulates a ball being balanced on this pipe, and motion one way or the other will allow the ball to travel back and forth along its length. With the Earth gravity setting this is fairly intuitive but when the gravity simulation is turned up for heavier planets or turned down for lighter ones the experience changes dramatically. Most of the video explains the math behind determining the effects of a rolling ball in each of these environments, which is worth taking a look at on its own.

While the device obviously can’t change the mass or the force of gravity by pressing a button, it’s a unique way to experience and feel what a small part of existence on another world might be like. With enough budget available there are certainly other ways of providing training for other amounts of gravity like parabolic flights or buoyancy tanks, although one of the other more affordable ways of doing this for laypeople is this low-gravity acrobatic device.

Continue reading “Experience Other Planets With The Gravity Simulator”

Transparent PCBs Trigger 90s Nostalgia

What color do you like your microcontroller boards? Blue? Red? Maybe white or black? Sadly, all of those are about to look old hat. Why? Well, as shared by [JLCPCB], this transparent Arduino looks amazing.

The board house produced this marvel using its transparent flexible printed circuit (FPC) material. Basically, the stuff they use for ribbon cables and flex PCBs, just made slightly differently to be see-through instead of vaguely brown.

The circuit in question is a Flexduino, an Arduino clone specifically designed to work on flexible substrates. It looks particularly good on this transparent material, with the LEDs glowing and the white silkscreen for contrast. If you like what you see, you can order your own circuits using this material directly from JLCPCB’s regular old order form.

Most of all, this project reminds us of the 1990s. Back then, you could get all kinds of games consoles and other electronics with transparent housings. There was the beloved PlayStation Crystal, while Nintendo did something similar with the N64 while adding a whole line of tinted color and charcoal versions too. Somehow seeing a bit of the inside of things is just cool. Even if, in some cases, it’s just to avoid smuggling in prisons.

It took decades before you could get custom PCBs quickly and easily. Now, board houses are competing for the enthusiast (consumer?) market, and competition is spurring development of crazy stuff like transparent and even glow in the dark PCBs. What next? We’re thinking edible, ROHS and WEEE be damned. Drop your thoughts in the comments.

Thanks to [George Graves] for the tip!

Arduino Saves Heat Pump

For home HVAC systems, heat pumps seem to be the way of the future. When compared to electric heating they can be three to four times more efficient, and they don’t directly burn fossil fuels. They also have a leg up over standard air conditioning systems since they can provide both cooling and heating, and they can even be used on water heating systems. Their versatility seems unmatched, but it does come at a slight cost of complexity as [Janne] learned while trying to bring one back to life.

The heat pump here is a Samsung with some physical damage, as well as missing the indoor half of the system. Once the damage to the unit was repaired and refilled with refrigerant, [Janne] used an Optidrive E3 inverter controlled by an Arduino Mega to get the system functional since the original setup wouldn’t run the compressor without the indoor unit attached. The Arduino manages everything else on the system as well including all of the temperature sensors and fan motor control.

With everything up and running [Janne] connected the system to a swimming pool, which was able to heat the pool in about three hours using 60 kWh of energy. The system is surprisingly efficient especially compared to more traditional means of heating water, and repairing an old or damaged unit rather than buying a new one likely saves a significant amount of money as well. Heat pump projects are getting more common around here as well, and if you have one in your home take a look at this project which adds better climate control capabilities. to a wall mount unit.

Projector on left with red arrow pointing towards object, another red arrow points towards a piece of paper and then camera.

Pictures From Paper Reflections And A Single Pixel

Taking a picture with a single photoresistor is a brain-breaking idea. But go deeper and imagine taking that same picture with the same photoresistor, but without even facing the object. [Jon Bumstead] did exactly that with compressed sensing and a projector. Incredibly, the resulting image is from the perspective of the projector, not the “camera”.

This camera setup is very similar to one we’ve seen before, but far more capable. The only required electronics are a small projector and a single photodiode. The secret sauce in this particular design lies in the pattern projected and the algorithm to parse the data.

Continue reading “Pictures From Paper Reflections And A Single Pixel”