Eric Pietrowicz's Build Log

Hey I’m Eric,
I’m a software developer working in the IoT space focusing mostly on BLE, WiFi, and cellular devices.

I’m starting this thread to practice getting a little more comfortable talking about my projects as I try to transition into consulting full time.

1 Like

The first project I’m going to track is a result of this itch I’ve had for a while when prototyping BLE products.

Working on firmware I always wish I had a polished mobile app, while working on mobile I always wish I had a polished peripheral.

I end up in script-land or sending custom payloads using a BLE dev tool like LightBlue.

So, I’m tinkering with a drag & drop “web builder” style BLE controller.

Support some generic components like a slider, color picker, button, graph, etc.

Assign a custom service / characteristic to each component. Characteristics under the same service will be grouped.

Here’s a short demo of it in its current state. I’ll open source everything once it’s in a good spot.

4 Likes

Useful!

1 Like

Cool! I’ve always wanted a simple config-driven phone UI for BLE devices. I’m aware of but haven’t used https://remotexy.com/ and there is https://play.google.com/store/apps/details?id=cloud.blynk but it doesn’t look free. Neither of these get you the experience of building it yourself however!

1 Like

Project update.

I was able to get most of the scaffolding done for how I will store the components and how they’ll interact with the Bluetooth service.

I have been working on implementing the slider component first. In hindsight I probably could’ve started with something a little easier… But, since the slider is able to interface with any characteristic type (read, write & notify) it was a great opportunity to get all of the interactions framed out.

I’m storing the global “component state” in the browser’s local storage. Your configuration will persist across refreshes. In the future it might be nice to have the option to import / export a file that contains your component configuration.

I had a hard time getting read, write, and notify to work together on the same component, but I think I found a workable solution. It will definitely need more testing.

I was worried that I would need the user to specify the data size (i.e. 8bit, 16bit, 32bit, etc.), but I think I found a way to guess at it on the fly. I would like to limit the necessary configuration upfront.

There’s a couple of really useful Web Bluetooth features that are hidden behind an “experimental features” flag in Chrome. I’m really trying hard to avoid using them. Fingers crossed they are widely released at some point.

Anyway, here’s the latest demo video of the slider working with my nRF52 Feather. In this case the slider is driving the built-in Neopixel LED brightness.

Next steps… more components!

1 Like

Starting to lose focus on this project a bit… but check out the work in progress hosted here!

Let me know if anyone gets the chance to play with it.

The latest development in my shiny project syndrome has me working on something that’s been on my back burner for a while ever since I got my hands on Circuit Dojo’s nRF9160 Feather.

I live in a major US city and prefer to bike most places, but always feel a bit worried when my bike is locked up out of sight.

I am playing around with strapping the 9160 Feather to my bike lock and configuring it to trigger a notification (SMS, email, call, tbd…) when motion is detected on the lock implying that someone is trying to remove it. The hope is the notification would afford enough time to get back to my bike before it’s gone forever.

In the interest of keeping things simple: a screen for displaying state (battery state, signal strength, armed/disarmed state) and a button for waking the screen and toggling between armed and disarmed.

It took a while to get LVGL working for the display, now I’m wrapping up the AWS IoT integration.

More to come! (hopefully)

1 Like

Adapter boards came in - we have a stand alone device!

I’ve also wrapped up the AWS IoT Core integration. It’s a simple protocol:

  • Publish on UNLOCKED → LOCKED state change.
  • Publish if the device detects motion while in the LOCKED state.
  • (WIP) Subscribe to motion sensitivity adjustments from the user.


I’m playing around with the housing design, still to be determined how it will mount to the bike lock.

What’s pending:

  1. Implement the battery level display.
  2. Hook up a Lambda function to send an SMS if motion has been detected.
  3. Wrap up housing design.
  4. Start to consider front end integration, onboarding, sensitivity adjustment, etc…
1 Like

The antenna may be your biggest challenge WRT housing? I don’t know what you mean by attaching this to the lock, but the whole thing looks pretty chunky to do that?
BTW, I find these displays very difficult to read in any sunlight, curious how that comes out for you.
Looks neat overall, just ouch for the price tag on that feather…

I hate to rain on your parade, but anything that looks like a security device or tracker will be yanked off - and the lock cut off - in less time than it took for you to read this unless you make the enclosure out of a titanium, kryptonite, and unobtainium alloy.