A Simple Web Configured BLE To GPIO Bridge

[Daniel Dakhno] kept ending up in a situation where the ability to read the status of, or control a few digital IO pins with minimal effort, would be terribly useful. Not wanting to keep compiling code, for such simple needs, they instead used a nRF51-based module as a physical interface and produced a general purpose firmware that could be configured with a simple web interface. The NRF51-IO-module was born, whose job is to pair with whatever device you have in front of you, provided it supports BLE, and give direct access to those IO pins.

Rather than acting as a rather slow logic analyser, the firmware is intended for mostly static configurations. The web application sends a configuration packet over to the nRF51 board, which then programs it into FLASH and restarts, reading the updated configuration and applying it to the IO pins. These outputs then persist as long as there is power. The read-side of the equation can also be performed via the web page, but we didn’t have a chance to verify that. The code implements the Bluetooth automation IO service as well as the binary sensor service so if you have access to applications that talk these services, then you should be able to fire it up and go with it, although we’ve not personally tested this due to lack of an nRF51 board. We noticed that the Home Assistant automation platform supports the BT binary sensor, which might be a big help for some people with a need for some wireless control and sensing.

If you need a practical example of a use for remote sensing, here’s a physical mailbox status monitor, using the nRF51. Whilst we’re thinking of Bluetooth and sensors, here’s a custom firmware for some super cheap environment sensors that frees them from vendor lock-in.

Header image: Ubahnverleih, CC0.

Blog Title Optimizer Uses AI, But How Well Does It Work?

[Max Woolf] sometimes struggles to create ideal headlines for his blog posts, and decided to apply his experience with machine learning to the problem. He asked: could an AI be trained to optimize his blog titles? It is a fascinating application of natural language processing, and [Max] explains all about what it does and how it works.

The machine learning framework [Max] uses is GPT-3, a language model that works with natural-seeming human language that is capable of being tweaked in different ways. [Max] uses OpenAI’s GPT-3 API (which, by the way, is much easier to experiment with than one might think) and here is the basic workflow for his title optimizer:

  1. The optimizer takes as input a blog post title to optimize.
  2. OpenAI’s pre-trained GPT-3 engine is used to generate six alternate titles.
  3. For each of those alternate titles, a fine-tuned version of GPT-3 is consulted to judge how “good” they are based on custom training data. (“Good” in this context means “similar to titles of successful submissions on Hacker News“, but more on that in a moment.)
  4. Print the results.

Continue reading “Blog Title Optimizer Uses AI, But How Well Does It Work?”

Fusion 360 Logo

Local Simulation Feature To Be Removed From All Autodesk Fusion 360 Versions

The removal of features from Autodesk products would appear to be turning into something of a routine at this point, with the announced removal of local simulations the latest in this series. Previously Autodesk had severely cut down the features available with a Personal Use license, but these latest changes (effective September 6) affect even paying customers, no matter which tier.

While previously executed local simulations on designs will remain accessible, any updates to these simulations, as well as any new simulations will have to use Autodesk’s cloud-based solver. This includes the linear stress, modal frequencies, thermal, and thermal stress simulation types, with each type of simulation study costing a number of Cloud Tokens.

Solving a linear simulation should initially cost 0 tokens, but the other types between 3 – 6 tokens, with the exact cost per token likely to vary per region. This means that instead of solving simulations for free on one’s own hardware, the only option in a matter of weeks will be solely through Autodesk’s cloud-based offerings.

Naturally, we can see this change going over exceedingly well with Fusion 360 users and we’re looking forward to seeing how Autodesk will spin the inevitable backlash.

(Thanks, [Jeremy Herbert] for the tip)

screenshot from the video linked, showing example code that lights up an LED, and in a small window, also shows the LED lit up on a small Pi Pico board connected over USB

Your MicroPython Board Can Be Your Tinkering Peripheral

[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”

Scratching Out Business Intelligence

At Hackaday, we love things both from scratch and in Scratch, Scratch being the blocks building helpful language for teaching kids and the like how to program. However, when you have a large amount of data that needs to be processed, queried, and collated to get meaningful insights, it is a pain to rewrite a SQL query every time a new question arises that needs an answer. So perhaps a more elegant approach would be to give the people asking the questions the tools to answer them, but rather than teach them SQL, Mongo, GraphQL, or any other database, give them the tools to scratch out the answers themselves.

That’s enough scratch puns for one article. [Tommy] ran into this situation in 2011 and recently wrote about it. Scratch came out in 2003 and has inspired several projects, such as Google’s Blockly. [Tommy] used Blockly to create a web app where users could drag and drop different blocks to form queries. These layouts were passed to a PHP-backed (though later HVVM for performance reasons) and executed as SQL.

Eventually, big data came around, and the company hired proper data scientists. Though [Tommy] notes that some of those who used his tool went on to learn proper SQL and do it themselves. Applying concepts from programs designed to teach children programming might sound a little odd in a business sense, but we love seeing projects that help someone become curious enough to peer inside the machine.

30 Free Circuit Simulators Lightly Reviewed

We live in a time where great software is available with the click of a mouse, often for free or — at least — low cost. But there’s a problem: how do you select from so many alternatives? We were interested in [Lee Teschler]’s review earlier this year of 30 free circuit simulators. If you are selecting one or don’t like the one you are currently using, it is well worth the time to review.

There are several on the list that you’ve probably heard of before like GNUCap and LTspice. There are also some lesser-known products. Some of those are just trial or student versions of paid products. Some are branded versions of commercial products (like Tina) or were made free after selling for higher price tags (like MicroCap 12).

Old favorites like Falstad (which is apparently known as Circuit Sims) and TinkerCAD made the list. Many of the trial versions were very limited. For example, DCAClab only provides an NPN bipolar transistor model. Proteus doesn’t let you save or print unless you pay. While the list includes TI’s Tina, it doesn’t seem to mention that TI also provides a free version of PSpice which is a very popular professional product.

While the capsule descriptions are nice, you may want to dig in a little on the ones you are most interested in. For example, Falstad has a great mixed mode that can even include an AVR microprocessor. But there were a few on the list we had not heard of and maybe you’ll find something new there, too.

Never Too Rich Or Thin: Compress Sqlite 80%

We are big fans of using SQLite for anything of even moderate complexity where you might otherwise use a file. The advantages are numerous, but sometimes you want to be lean on file storage. [Phiresky] has a great answer to that: the sqlite-zstd extension offers transparent row-level compression for SQLite.

There are other options, of course, but as the post mentions, each of these have some drawbacks. However, by compressing each row of a table, you can retain random access without some of the drawbacks of other methods.

Continue reading “Never Too Rich Or Thin: Compress Sqlite 80%”