Skip to main content

15 posts tagged with "Application"

View All Tags

A Rough Guide to Private AI: How To Buy, Build, and Use LLMs and RAGs.

· 15 min read
Nik
Site Owner

For a little under $8,000 you can have your own very capable private AI at home that you can feed data to and get answers from.

It's not hard to do, it'll put you out at the cutting edge, and I think this offers significant advantages to those who follow through with it. This guide talks about what the machine consists of, how to put it together, what you might use it for, and what is still fantasy.

This is written for us semi-normal people interested in AI. We aren't going to build our own LLM from scratch and we may not code for a living. We've used ChatGPT or Perplexity and think it's neat, and we can copy/paste commands into a CLI. We may have never built our own PC but that's fine; I hadn't either.

We're willing to read a bit and muck about, but in general we don't have time to develop deep domain expertise; we just want something that mostly works and puts us out at the forefront of the AI revolution.

You can also spend less if you want. My budget was $8k so that's what I used. $3k is probably as low as you can go and get reasonable performance, but I'm sure some wizard out there will let me know in the comments that if I just re-ionize toothpaste and flame-char duct tape to exactly 417.314 fahrenheit then smelt my own iron, I could do the whole thing for $5.

I didn't do that, just spent the money, enjoyed building an excellent thing, and called it "Monstra".

The GPUs are a little too close together to run for long term comfort, but for relatively short tasks the thing is awesome.

Yes, you can run an LLM on your home computer right now; it'll just be a lot slower than a purpose-built monster. "Monster" is relative; for a home setup this is on the "overbuilt" side. Compared to top of the line massive racks of A100s or H100s, this thing is puny.

Ok, so what do you get out of building your own personal AI machine?

  • Privacy in your queries. Maybe you don't want OpenAI to know about the product you're building that you need help coding.
  • Related to this, you get the ability to use an AI trained on data that you might not want to share, like tax records or shipping information for every sale your company has ever made.
  • You get flexibility in setting it up exactly how you want it; how much "horsepower" you use, how creative you want your responses to be, and specific things to focus on.
  • You get to experiment on the cutting edge, and find out how much you can actually do and how much is still you fantasizing about having your own drysine queen.
  • You can also participate in renting out spare capacity.

I'll start with what I've been experimenting with, then we'll get into the details of the build and how to set it all up. This is not (by a long shot) all you could do, these are just some of the problems I'd like to solve for myself.

Training Plans (race prep, overall fitness, etc)

A few years ago, I hired a private high-end coach to help me build a training plan for a hike 'n fly paragliding race I was preparing for. This is a former Olympian who ran strength and conditioning at Red Bull. I'll admit it; it was probably a lot more coaching horsepower than I needed.

He charges $800 a month for what I wanted, which is a customized plan with unlimited calls to an elite coach and alterations to continually make the changes required of any training plan. We spoke every day, it was awesome, and he was worth every penny. Still, $800 is $800.

Now, that's on the expensive side. If you want excellent coaching you could hire the folks over at Evoke Endurance, who charge $350/month for a similar service.

If you had a private AI, you could take PDFs of all the books that Scott Johnston over at Evoke has written, transcribe all the Evoke (and Uphill Athlete) podcasts, add in whatever other content then you want, then feed it to your AI and let it help you develop your own custom training plan.

If you wanted to be a little entrepreneurial, you could open that up as a service for others. It won't be quite as easy as I'm making it sound, as you'll need a RAG and nerdy vectorDB skills, but with AnythingLLM you can probably pull this off for yourself with some elbow grease.

Let me be clear here: As of July 2024, the AI won't be as good as a professional coach. In fact, when you start it may be worse than a bad coach. Still, I'm *guessing* that'll change by December of 2024 (the ol' "6 months in AI is a new century" rule). That's a guess and I'm likely to be wrong.

LiveChat Agent

Since 2009, my wife and I have run Paleo Treats which has both an online store and a brick and mortar shop. Since 2014 we've used LiveChat to chat with folks who visit the website. If you've ever been on the PT site and opened up a chat, you were talking to me or my wife. That's cool, but...we turn off the chat when we sleep, and throughout the day when we have other things to do.

LiveChat offers an AI service called ChatBot that starts at $52/month. With our HomeAI setup, we can replace that with a custom agent and have more control (and learn way more about setting those up) to give super customized chat experiences to folks who want to buy gluten, grain, and dairy free desserts online.

Taxes

Having been in crypto since 2014 or so, it's always a discussion with our tax preparer every year; "What are these token-things? Why are you still doing them? There's not any great guidance on this..."

Because taxes are about money and money is so personal, I'm not sure I want to be uploading all my financial docs to every tax site promising "We do it with AI!" out there.

I'd much rather feed my private AI the US tax code (which you can find here, Title 26), give it my last 10 years of returns, then work through the current year with the overwatch of an AI knowing that eventually, as long as I put in my data correctly, I'll be able to do my taxes far more efficiently with my own personal consultant that knows every aspect of my finances.

Again, this won't be easy or perfect (or maybe even that helpful) right now, but if I start working on this now, I'm guessing by the next time I need to submit taxes it'll be a button push, a few questions, and perhaps the best tax prep experience I've ever had.

Our current tax preparer charges about $6,000 per year to integrate 3 businesses, personal taxes and my various crypto adventures.

Inventory & Operations

Again, as part of the Paleo Treats business, we're always ordering ingredients and consumables, doing production runs, then packing and shipping out items. I've built a series of Python scripts to help keep track of costs, but the ability to start to integrate all of our Operations data into an LLM and ask "How many packages have we been shipping to Sugarland Texas this month, and how does that compare to last year" or "Take a look at this giant csv of every package we've shipped over the last 10 years and tell me which city gets the most packages" etc etc starts to make finding opportunities much more efficient.

Yes, I know you can do that with Excel or Google sheets. I think the ability to talk to a personal and secure AI starts to change the game for small businesses who aren't necessarily data wizards but still have legitimate questions about operations opportunities.

Funzies - Grinding a Vanity Solana Address

I stumbled on a post by Nick Frostbutter on how to "grind" a Solana vanity address using a built-in command in the Solana CLI (Command Line Interface, which is where nerds go to talk to computers.). That particular set of instructions uses your CPU. With the machine I'd built, the CPU was pretty powerful (gear list below), but the whole reason I got into this was I wanted the GPU capability for LLMs, so...why not use the GPUs?

My buddy nosmaster found this Github repo on how to use GPUs to grind, and after a full weekend of fiddling about with various settings, I managed to grind out a gking... Solana address in about 45 minutes. I know, I know, it's good for almost nothing and you don't get a mnemonic phrase (the "twelve words"), just a barely decipherable private key, but it was a fun use of Monstra.

The Build, Part 1: Understand What Everything Does

Before we get to a parts list, I thought it'd be useful to have an overview of what everything does. It was all a mystery to me when I started, and just knowing what each thing does has been helpful in grasping the overall concept.

Every computer we build for AI will have 8 constituent parts:

CPU - Central Processing Unit: This is the "brain" of the thing.

GPU - Graphical Processing Unit: Fundamentally, this is what gives the AI its horsepower.

RAM - Random Access Memory - Think of this as the working memory of the device.

Storage - This is the long term memory. Not as fast as RAM, but way more of it.

Motherboard - The coordinator of all the other parts, and the physical structure they all plug into.

Power Supply - Making sure everything stays on without flickering.

Case - Big enough and airy enough to keep everything proteced and cool.

Cooler - Fans to make sure the CPU specifically is cooled off.

Additional Cooling Fans - Drives air through the whole case to keep all parts cool.

Other nerd tools - Thermal paste, screwdriver, cable management, etc.

The GPUs are critical for making the LLMs actually work (at a reasonable speed). The CPU manages overall workflow, and the RAM supports large datasets. Everything else supports that. Of course, you can scale up (or down) from here.

Ok, so with the basic stuff out of the way, what should you buy and how does it go together?

The Build, Part 2: Buy & Assemble Your HomeAI

I'll start by saying that I'm impatient and Amazon is easy, so I bought everything there. I'm sure if you hunt around and have some patience, you can save yourself some money.

All up it ran just under $8k. Of course, if you want someone to build it for you, Gigabyte is offering similar builds starting at $11k. You can also check out a Google sheet I put together for different "size" builds from $3k - $8k. The "V3" on that list is Monstra.

I ordered everything on a Monday and, being Amazon, it was all there by Thursday including hiccups.

Assembly was more or less straightforward, though I had significant help from Vortal, nosmaster, and Rob who are all part of the mysterious advanced tech exploration group called AppleFuckers over on the GK Discord.

Each part comes with plenty of guides and manuals, and from my limited experience, if you just follow the Motherboard manual it'll walk you through everything you need to do.

Still, if this is your first build, I'd find a computer nerd and have 'em help you with it; many things are not obvious, and having an experienced guide to walk you through updating the BIOS (if that's even needed) is super helpful.

What To Expect The First Week

First off, know that you're an experimenter. Nothing will work out of the box; everything requires the ability to use the CLI to do basic install stuff.

Still, if you can search the internet, copy/paste, and use ChatGPT to get you going, you'll be up and running your own private AI in just a few days.

It won't literally take that long, as installing these things once you know how is about a ten minute job, BUT...learning how to do it, what works and what doesn't, and what you should and shouldn't pay attention to takes time.

Here's what I loaded up and used the first week:

Each of those is its own "flavor" of AI, or in the case of OpenWebUI and AnythingLLM, a way to interact with an LLM.

About that RAG

If you want to add in your own content (like the US Tax Code or your shipping info or the contents of a book), you'll use a RAG, or Retrieval Augmented Generation. I'll start off by saying this: The *concept* of a RAG is easy; add in the customized thing you want your AI to reference when answering your questions. The *application* of getting the thing to work is the sticky bit.

AnythingLLM makes it pretty easy to add in documents, though it's not ultra clear how to assign them to the specific model/thread you're working on. OpenWebUI is good for a few docs, but not so good with a ton of docs, and doesn't really give citations (the way, say, Perplexity does).

The use of RAGs is still well ahead of "easy". The data you feed the AI has to be clean and well structured, and frankly, most of us humans are walking around with such a mess in our heads regarding how we organize and understand our own data it can be a mind-bender to translate that to your machine.

Still, it's been VERY useful for my own thinking to move through the steps of introducing data to any of the LLMs I've worked with.

Next Steps

Rather than giving you a step by step of exactly what to do with each LLM, I'd encourage you to explore this AI jungle on your own. Know that other folks (like me!) are out in the jungle with ya and we're all learning how to interact with our own private AI in our own way.

So far, of all the things I wanted to do, none have come out the way I want. I'd pretty much expected that. Still, I'm getting exactly what I wanted in the form of hands-on experience working with and around a personal AI and seeing both the opportunities and the limitations.

I found the following two YouTube videos helpful when I was starting out:

Host All Your AI Locally

How To Use Your Local AI (TechnoTim vid)

Self Hosted AI That's Actually Useful

If you're experimenting with this as well I'd love to hear about it! If you buy a bunch of parts and need help, jump in the GK Discord server, there's usually someone awake and willing to point you in the right direction.

See ya on the other(AI) side!

Archived Comments

Sheree - 2/5/2025

Love this guide. I’m interested in spinning up a private instance as well. I’m working on the experience side for an enterprise, would be fun to have one at home to experiment with. Thank you for a thoughtful and very entertaining guide


Chris - 10/16/2025

Hiya, thanks for this write up, they are harder than they look- or were ? It has been more than a year, how has the project gone? Do you still use it? Have advancements in the field unlocked significant new utility? Maybe there is a Part 2 please post a link if so.


Nik - 10/16/2025

Hey Chris, I have learned a ton since I built Monstra. I work using Cursor every day, so it's much easier to interact with AI/LLMs in general than it was a year ago. Monstra has made it very easy and convenient to run local LLMs on data I want to keep private, and it's been amazingly useful to have as I FAAFO. Still, building/rolling your own only has utility if you like exploring/learning. If you just want to GSD, running the OpenAI API (or any others) is probably a more efficient use of cash & time unless you're going to run a shitload of jobs. Does that help?


A Rough Guide to the Rabbit r1

· 9 min read
Nik
Site Owner

The Rabbit r1 launched to great fanfare on January 9th, but nobody I knew really understood what to use it for. It was one of those "Holy shit, that thing is rad, but..what does it do again?" moments.

What is the r1? For my regular readers, I'll start with this: It has nothing to do with DePINs or crypto (yet).

For everyone else...let's start with what it looks like. It's a little orange box about a thumb-width thick and maybe as long and wide as your index finger. Basically, a little smaller than your palm (unless you have plumber hands and can rip a phone book in half, in which case it's half the size of your palm.)

photo credit: Rabbit

It's got a scroll wheel and a screen, a camera that can roll its own eye up into a cover (so it can't watch you all the time) and a place for a SIM card so it can connect to the webz.

Now, far more interestingly, what does the r1 do? It uses fancy AI (technically a LAM, or Large Action Model) to watch what people do on their screens, listen to what they say while they do it, and then encode that into repeatable actions.

What the fuck does that mean?

Basically, it's like a very smart 10 year child with perfect recall who does exactly what you tell it to. It can watch and mimic what you do on a computer, sometimes with uncanny accuracy. Whether you're editing videos and could use an "auto mask" assistant, or you're always booking trips online and get tired of the details, you let the Rabbit watch what you do a few times, then, it just...does it for you.

Technically, a Rabbit is an agent, a "software entity capable of performing tasks on its own." Those of us with a love of sci-fi will remember the hotel agent in the book Altered Carbon; we ain't there yet, but we're getting closer.

The key points here are that a Rabbit will:

A) watch and listen to you

and

B) you can tell it what you want to do

No programming necessary. It doesn't have to integrate with an app any more than you do, it just listens, learns, and does. That's it.

Oh, and one more thing. The L in LAM. It doesn't just listen to and learn from you. It does that for everybody.

So if someone who is a movie editing wizard decides to walk their Rabbit through their process, well, not only can they reuse that process, but they can *sell* that process to you.

[Rabbit] is confident it can make business-sustaining money through licensing its platform.

Kyle Wiggers, Tech Crunch

This means the the experience-buying market is about to get even more frictionless. Upwork used to be the hot place to drop a tech gig you wanted done now, but that's still pretty messy. There's sifting through people, hiring one (or a few), testing 'em out, then seeing if you like working with them.

Of course, if what you want is an imaginative engineer to solve a current problem in a novel way, well, Rabbits prolly ain't for you. If, however, you'd like to just buy any kind of online executory experience that might have taken someone years to master and they now do as casually as Stephen Curry makes free throws, well, there may be a Rabbit for that soon.

So, where does that leave you, someone who owns or has ordered a Rabbit and is wondering what you'll do with it?

One thing we'll probably see is an explosion of "Master class" style offerings, except instead of Neil Gaiman teaching story-telling, you'll be be able to buy the story-telling Rabbit who was taught by Neil, then write your own Gaiman-esque stories.

If you were to consider preparing for your Rabbit, you might want a "What to do while you wait" pamphlet.

In broad strokes, it's reasonably safe to start thinking of any Rabbit action or sequence as requiring three things:

  • Intent through spoken word
  • Screen recording
  • Desired outcome

An example of this might be:

Intent: Check across 30 Discords for the general sentiment around DePIN in crypto
Screen recording: Going through the Discord servers I'm in, searching through the latest posts, giving each server a rough "sentiment score" on DePIN in crypto
Desired outcome: Overall sentiment score for the idea of "DePIN in crypto", maybe on a scale of 1 to 10.

That's not by a long shot the best or only or most complex, it's just one idea based on some of the work I already do.

Obviously we'll see Twitter flooded with the "My boss thinks I'm a genius, but I've just got a Rabbit in my pocket" ads. I'm sitting down with my buddies to think up of all the ways we might use ours to help YOU! They may steer crops, make movies, manage social media details, or book that trip for St Cuthbert's walk.

In the meantime, what can you think up that your Rabbit might do for not just you, but all of us?

  • booking a flight
  • pentesting & wardriving (say no more!)
  • growing crops using sensor networks
  • writing new songs
  • setting up complex network rules (firewalls, device tunnels, etc)
  • visualizing all sensors in a space
  • visualizing all DePIN miners in a given location

Batch 1 ships starting March 31st, 2024. To the future!

Curious about the Rabbit? Buy yours here (no, not an affiliate link) --> https://www.rabbit.tech/

Archived Comments

Warren Bowman - 1/12/2024

Nik, I love what you do. I was just wondering what the hell this rabbit thing was. Thanks for explaining it. If I may pick one small nit: editing is a subjective craft. Each piece has it’s own look and feel. As a career film editor, I doubt that this device can compare performances on a subjective level, intuit what the writer intended, realize the director’s vision, and give the producer what they want. Am I missing something?


Nik - 1/12/2024

Right on Warren. As a brand new film editor, I'm on the other side; a ton of stuff that is probably super basic for you is time-consuming for me; drawing a mask around an object, moving that object through frames to simulate motion (think the "superhero landing effect"). That's just a small example, but expanding it out, let's say you had a Rabbit watch you edit, oh, 2 or 3 short films. As you edit, you tell it what you're doing, then you package that up and sell it as a "editing assistant" on the Rabbit marketplace. I buy the WB-Edit-Assist for my RAbbit, and then it's like I've got you in the room with me for when I want to do all the small tech tweaks that are natural to you. Does that make sense?


Fernando Cassia - 1/14/2024

Hardware specs? Is it wifi or LTE enabled or both? How much bandwidth does it use and what degree of control do I have on bandwidth usage?


Nik - 1/14/2024

2.3 GHz MediaTek MT6765 Octa-core (Helio P35) processor 4 GB memory 128 GB storage 8 MP, 3264x2448 photo 24 fps, 1080p video Bluetooth 5.0 / Wi-Fi with 2.4GHz + 5GHz / 4G LTE All specs on their page: https://www.rabbit.tech/


You - 1/14/2024

People need to be realistic about what $200 can get them lol. ChatGPT is $20 a month and is barely agentic, and somehow idiots expect they can get a smart agent for $200 with hardware?


Joe Rizo - 1/15/2024

I am most interested in the rabbit teach, which i'm sure is what is creating the biggest stir in the developer community. i just pre-ordered the rabbit r1, but would like to get started now on creating the action agent i need. when do we get access? i dont see anything for developers on the site.


Oro - 4/29/2024

Thanks for this Nik! Now i have a better understanding of an r1. So an r1 and it’s LAM are like an automated code writer for Selenium WebDriver or Puppeteer/headless Chrome? I used to write test scripts similar to the web example on the Research page https // rabbit tech/research using them. BTW, did you receive an r1 yet? What are your first impressions? Also, what do think about the Ai Pin? Does it have DePIN potential? https // humane com/aipin


Nik - 4/29/2024

Right on! I just got my R1 today. I'd say it's a fun gadget that's not yet delivering on the hopes that got built up. For me that's totally fine; it was $199 and after so much experience with crypto hardware I'm just psyched they delivered on time. :) I don't have any experience with the AI pin. I don't think either of 'em will go the DePIN route, though I heard rumblings at one point they might do a token.


Oro - 5/1/2024

Thanks, Nik! Interesting article on r1: "The Rabbit R1 is probably running Android and is certainly powered by an Android app under the hood." https //www.androidauthority.com/ rabbit-r1-is-an-android-app-3438805/ Hmmm.


Shane - 5/16/2024

Does rabit1 have an affiliate program


Nik - 6/8/2024

I'm not sure. If they do, I'm not on it yet.


Randy - 6/18/2024

Seeing the demo on January 9th I thought cool, and only $200. Let's give it a try. I've been an early adopter (for the most part), for a long time ... My Rabbit R1 arrived yesterday. Not sure what I can do with this yet but its been fun playing with it. Recording a meeting and having it summarized could be useful, but I haven't tried it yet. Visual object identification is cool and hopefully will get better over time.


Nik - 6/18/2024

From what I've seen with mine, you won't be able to do much yet, but it's fun to experience.


How To Use A Helium Integration

· 10 min read
Nik
Site Owner

Let's start with the basics: What the heck is a Helium Integration, and why would you even need one?

An "integration" is what allows the raw data that's coming from your Helium sensors to be actually used. Whether that's showing a dashboard of soil moisture, or temperature, or if you're tracking the number of people who park in a spot, you'll need an integration to actually understand that data.

Let's do a quick review of how information moves through a LoRaWAN:

It starts with the Device sending out a Packet over radio waves. That Packet is received by a Hotspot. The Hotspot sends it on to an LNS (LoRaWAN Network Server), which will typically decode the packet and send it on to an Integration.

Now, an Integration doesn't have to be a display; it could be any use of that data. Let's say you have a Helium sensor monitoring soil moisture under a sprinkler manifold. If that sensor suddenly reports that it's super wet, you may want to have your Integration just shut off any water to the manifold.

Of course, you might want to know if that soil moisture is because of a leaking pipe or just that it rained recently, so you probably want to tie in data from a local weather station, like this:

To see all that data, you need an Integration. In this case, we'll be using the MeteoScientific integration, which also has a Rules Engine that allows you to create rules and workflows around what happens when it rains, or gets too cold, or does any one of a number of things that your sensors can report on. *Full disclosure: I own and run MeteoScientific and invested in the software it runs on, which is called UplinkEngine.

For now, I'll walk you through how to connect your Console to an Integration. We'll get to actually displaying the decoded data in the next post.

The MeteoScientific App is free to sign up for, and the smallest device plan is $.50/month, which is competitive with any other integration option out there.

Integration Options

There are lots of other integration services, like Datacake, Ubidots, Tag.io, and of course, Nova's 1663 option for large commercial users. Each of them offers something slightly different, and depending on what you want, they may be a good match for you. They all will have the same general steps that we'll follow below for MetSci. You'll generate an API key, add it to your LNS, figure out how to read the incoming data, and then (for most of them), automate actions based on that data.

Relax, we won't do ALL of that in this post. :)

I'll make an assumption now in order to save us some time and space, and that's that you already have your sensor up and connected to the Helium network. If you don't, start over here with the MeteoScientific Console.

Chirpstack Device Setup - Example

Once you have a device set up, it'll look something like this weather station, which is an example from the Chirpstack LNS on console.meteoscientific.com:

You can see that the sensor is up and reporting packets consistently, and the signal strength is good enough. Now, this is just the Device. To create an Integration, start by finding your Application in Chirpstack. Click on the Application, then look for the Integration tab, like this:

Click on the Integration tab, and then hit either the "plus" button if you don't currently have one, or the pencil icon if you already do (which is the case in this example.)

Once you're in the integration, we're going to tell Chirpstack where to send the data from our sensor. This sends our data to the "Integration."

To do that, we're going to open another tab and for our Integration account. In this case, that's the MetSci (MeteoScientific) app. There we'll generate an API key, then copy and paste a few things back into the Chirpstack Integration window.

MeteoScientific App

So, over on app.meteoscientific.com, look for your account name, then API Keys, then go to the top right and hit the "Add API Key" blue button, like this:

Once there, you'll see the option to add an API key. API stands for Application Programming Interface, and it's the code that allows two programs to talk to each other.

Add the key and name it something that makes sense, then save. You'll need to add a "verification code" which will be sent to the email you signed up for the App with.

You could name it Super Duper Double Trouble Radical Wizard Key. The name doesn't really matter, it just has to make sense to you. Once you see it in your API KEYS list, we'll move on to the next step: Add the Device you have over on Chirpstack to the MetSci App, then using the API key to connect the two.

Gather your DevEUI, AppEUI, and AppKey from your Chirpstack account for the Device you want to add, then in the MetSci App, go to Core-->Devices and Add Device, like this:

It'll display a screen where you enter in all your various EUIs and keys. Fill those in, then hit Save at the bottom.

For now, don't worry about Heartbeat Interval, Public Viewing, Parameters or Position, we'll fill that in later. Hit Save, and you'll see your Device.

Look for the "How to Receive Uplinks" tab and expand that, then carefully follow the instructions. It'll look like this:

Use the copy/paste buttons to grab your "Endpoint URL" and the HTTP Headers Authorization. We'll paste those in over on the MetSci Console, back in the Integrations tab we left open from before.

Go back to Chirpstack

In Console, on the Integrations --> HTTP edit box, start by choosing JSON, then fill in the Event Endpoint URL.

Now hit the "Add Header" button, and add in a Header with a "key" of Authorization and a "value" pasted in from your app. That will start with "Bearer" and then have your API key in there. I've already done mine, but just for reference, this is what it looks like:

You're done!

That's it! You've connected your Console with an Integration using an API Key. Wait for your sensor to send a packet, and you'll see the packet show up in your MetSci app. I'll save the next step (taking the decoded data from the packet and displaying it in the app) for another post. For now, pat yourself on the back, you've made the last big connection in a long set of geeky rules, well done!

If you're digging this set of instructions, I'd love to have you as a MetSci Console and App customer. However, I'm more psyched to just have you using Helium in general, so whatever combo of LNS and Integration you use is fine with me. If you're having trouble, drop me a note in the comments below and I'll do my best to help you out!

Rock 'n roll!

Archived Comments

E.H. - 8/12/2023

Hello Nik. I am E. H. from Zenica, which is located in Bosnia and Herzegovina. Zenica is a small town with a large ironworks. It is called Željezara Zenica (You can check it on this link - you will have to translate it into English https://bs.wikipedia.org/wiki/Željezara\_Zenica) It used to employ 20,000 people. A big war happened in Bosnia and Herzegovina 30 years ago, which you probably know about. The country never recovered from that war. You can still see ruined buildings, bullet holes and rubble from explosions, unemployment is huge and corruption is flourishing. The country is still divided on national and ethnic lines. Now you are probably wondering what all this has to do with Helium and your blog. Well, I discovered helium 3 years ago. Of course when I discovered helium I also discovered your blog. And I want to tell you that you are the biggest star in the helium world! I wanted to use Helium to monitor the level of air pollution in my city. I wanted to set up measuring stations all over the city that would post real-time data to a website or app so people could check the air quality before going outside. They would also finally have data that would be collected over a period of time so that they would have evidence that the steel plant is poisoning my city. I already wrote to you that corruption is flourishing, the Mittal Steel company that bought the ironworks does not comply with any regulations, it emits huge amounts of dust and smoke into the air at night when it is less visible (I can send you pictures if you want), local corrupt politicians assure us that the pollution does not originate from the steel factory but from people who use coal for heating. Mostly a long and sad story, and in the meantime, people die en masse from cancer. And back to helium, I ordered two hotspots 3 years ago. One sensecap and one bobcat. I installed them, I even installed one sensor similar to what you wrote in this article. You can check it at the following link: https://app.datacake.de/pd/ec69f339-95b6-4279-93e8-04d49ca24a8d One of the hotspots was added to the denylist a year ago for some unknown reason. You can check it at this link: https://www.crowdspot.io/hotspots/112jFvxA6VL3eofEsTMA9f8Ge2KF85VYhXx9zGmWWiFbB2KARGMm?submissionId=5561 Of course, I immediately reported the incorrectly added hotspot on Crowdspot, sent pictures and coordinates of my setup, and since then a year has passed and nothing has happened. It still says status pending. What can I do? The cost of a new hotspot is about the same as my monthly salary. I can't just buy a new hotspot. I haven't even paid off the two hotspots I bought yet. Please help. You can contact me at [redacted] Sincerely, E.H.


Nik - 8/12/2023

Hi EH, Thanks for writing in and sorry to hear about Zenica's issues. It definitely sounds like Helium could help with providing coverage for air quality monitors, love that idea! As far as the Crowdspot issue, I don't have any control over that. It's currently an issue being debated and addressed by the community at large in the Discord server. The most you could probably do is rally your Helium friends to vote it out of the denylist, but that's not a guarantee either. Sorry I don't have better news!


Sunsetting Helium Console - The End of an Era

· 7 min read
Nik
Site Owner

As any project progresses from a good idea to first implementations and moves closer and closer to commercial viability, the nature of access to the project will change. Typically you start off by giving away access for free, just so people can try the thing out. Helium's LoRaWAN (as all DePIN projects do) went a step further, and issued tokens for those who were willing to put up a gateway, in Helium parlance called a "Hotspot".

If you put up ("deployed') a Hotspot and provided LoRaWAN coverage, you earned a token called HNT. In the early days of the network, earning HNT is what drove the explosive growth from zero to about a million Hotspots in the course of around 2 years, as both the amount of HNT earned and the value of that HNT in dollars on the open market made deploying Hotspots a very lucrative endeavor.

If you think of HNT earnings as being like a giant pie, where early adopters got huge slices and many others looked on those slices and made their own lambo plans, you can see where it ends up going. Like any tasty pie, as more and more people claimed their slice, the slices got thinner and thinner, and at this point (June 2023) there isn't a huge financial incentive solely for providing coverage.

So, that leaves the real work of Helium still ahead: Allowing people to use this network that a community of strangers has built, and as part of that, allowing for and encouraging the support of businesses that build on top of the Helium ecosystem. I should say here before going any further that while I believe building a business on Helium is a reasonable bet, if you're considering running a business on Helium you should do your own risk analysis and research.

With that out of the way, let's talk about what will need to happen in order for Helium as a system to build a project with long term sustainability. We should start with a brief review of how the Helium LoRaWAN works, as it's slightly different than other LoRaWANs in two important aspects.

First, the technical aspect of having an additional step in the journey of a packet of data as it makes its way from a sensor to its final destination of being useful information. This step, through the "HPR", or Helium Packet Router, causes additional technical hurdles that are surmountable but must be understood by businesses considering using Helium.

Second, the personnel aspect of many people who would never before have thought about touching a LoRaWAN suddenly gaining access to high technology as a revenue stream. In this case I'm thinking of those businesses that might use a service like MeteoScientific (full disclosure, MetSci is a Gristle King Inc offering) for their own use or to upsell clients on a subscription model.

Here's a quick visual on the flow of data, from left to right, as a "packet" of information leaves a sensor and travels through to its final destination.

Along every step of the way is an associated cost. The sensor is a physical object that costs money to buy, a Gateway costs money to deploy, the Helium Packet Router costs money to operate, as do the LoRaWAN Network Server (LNS) and an Integration, which is where you see and use the data from the sensor.

In this article, we're going to focus on the LNS options, as this is currently hindering the growth of a decentralized system.

Currently, the Helium Foundation, a non-profit organization with the mission to be a steward of ecosystem development, network governance, and public education, runs a free version of an LNS, called "Helium Console". Anyone can sign up for it and run up to 10 devices on it, paying the "base rate" of data credit costs, which is $.00001/DC.

If you wanted to run your own LNS, you'll need to buy an OUI (think of it as a license to run an LNS) which currently costs $900, and you'll need to host your LNS on servers. Yes, you could scrap together hardware and do this on the cheap. However, for any serious business use, servers in the cloud with a reasonable uptime guarantee will cost at minimum a few hundred dollars a month to run. If you were to hire an expert (like I've done) to run servers using the OUI you've bought, you can expect your costs to start around $1,800/month.

Staying in business is straightforward; if you can buy the thing for 1 and sell it for 2, you're in business. Simple in concept, business is deceptively tricky in practice as you face not only the challenge of finding and keeping customers but also the competitive nature of others trying to run their own business. If you enjoy that kind of challenge it's extremely engaging, but you do want to make sure as much of the deck as possible is stacked in your favor.

That includes making sure there is no reasonable competition that can undercut your prices and sustain their operations.

Having a free option run without a profit motive stifles competition. For example, why would you use the MetSci Console, which charges $.0001/DC, when you could use the HF Console, which charges $.00001/DC?

Of course, there are other significant advantages to using the MetSci Console. On MetSci there is no practical limit on devices, we are constantly adding new decoders and support, it integrates with the MetSci app, and while there's currently no SLA, we have kept up with a 24 hour response time to all requests.

There is currently no business support for the HF Console and the Foundation has said that they will eventually sunset this Console, although with no date given.

Still, this is about more than just one LNS, this is about developing a decentralized system that supports businesses trying to build on it. In a system where the central player does not have pressure to turn a profit and offers a free alternative, the incentives to build competition are artificially suppressed.

Now, the argument can be made that no one will think of building a business on a model that only allows 10 devices and has no support, and that's reasonably fair, but the question is: Why offer it all? Why not just get out of the way of the businesses who are trying to build on the network, let them compete on a price/quality basis without unfair competition, and assume that will build a far healthier system?

With that in mind, I've proposed that the Helium Foundation shut down public access to their Console instance along with all current accounts with 10 or less devices in order to open up the playing field for a healthy and spirited competition between vendors willing to invest long term in Helium.

I could be wrong about this, and I'd love to hear how and why a better solution exists, so feel free to drop comments below, or comment on the HIP if it gets accepted, or head over to the GK server and join the discussion there.

Level Up In A Connected World Using 3D Printing

· 9 min read
Nik
Site Owner

One of many extraordinary aspects of being alive in 2023 is access to resources. In this case, it was access both to a 3D printer (a Prusa Mk3S+ I assembled from the kit) and finding design talent to get maximum value of the printer. Before we get there though, let's start at the beginning.

Sometime in December of 2022 I'd ordered a soil moisture sensor from MakerFabs, an outfit out of Shenzen China set up to produce open source hardware.

I thought it'd be a fun project, I knew that many others had already done it, and that while there might be fiddly bits, it was a well trodden path. I was mostly right, and helped by a bunch of tech savvy people in a channel on the GK Discord server, I ended up writing a post on how to get this LoRa sensor onto Helium's LoRaWAN network.

The one thing that bugged me was the enclosure it came with. It had 2 areas for improvement.

First, it didn't really protect from moisture getting in. The case is a 2-piece design with a few vents in the side for airflow.

Dirk (our GK engineer) had put a couple of 'em in the ground a few weeks before me and was seeing moisture inside of the case. The seams aren't watertight, and the vents don't protect at all from water coming in from the side. Now, the board and the parts on it are covered (as I understand it) with a protective film, but the twin AA batteries are open to the world.

Second, it is a royal pain in the ass to open and close. It ships with 2 x M2x8 bolts and nuts. The bolts are just barely long enough to get through both sides of the case, and the way the case is set up makes it really fiddly to actually thread the nut on. It's not impossible, just an unnecessary obstacle. I tried replacing the 8mm versions with 12mm long bolts, and that was slightly easier, but still, not what I wanted.

Obviously once you've got the sensor up and running you don't really care about opening up the case, but there was just something about not having a well designed case that triggered the thought, "I can improve this." So I did.

I started by thinking about what I wanted: A case that I could open up easily with minimal tools, one that protected the batteries from moisture while giving the actual sensor (an AHT10) plenty of airflow, and something I could print at home on the Prusa. The material had to be something that could withstand being outside and exposed to the elements, so I settled on ASA filament. ASA is a UV-resistant form of ABS, a durable plastic.

I thought a mushroom shape would work well, so I sat down and sketched out a first draft.

As you'll see, this isn't what we ended up with, but it's close. The lesson here is to start. Your idea doesn't have to be perfect, you've just got to get it out of your head and into some medium you can share.

Now, while I have a 3D printer, I am not by a long shot a 3D designer. Here's where the rad part of being alive in 2023 comes in: Designers (and experts of all types) are getting easier and easier to find. I turned to Upwork to find mine. I wrote up a creative brief of what I wanted, added in a few parameters, and posted it.

I added in a few "sifting" questions to help me sort through all the applications faster. I've found writing your own questions on Upwork is really helpful to quickly eliminate candidates who are unlikely to be a fit.

Then I sat back and watched a bunch of submissions come in. Some of 'em read the brief and responded cogently, many were just copy/paste bullshit, and one in particular was from a fellow named George Z. We messaged back and forth a few times, he suggested we jump on a Zoom call (done through Upwork, which was pretty slick), and we talked about it for 15 minutes. I decided he was a reasonable bet, we agreed on a price per hour and he started work.

I took some time to silhouette out the sensor and take a bunch of measurements with my digital calipers. I'd really wanted to buy a 3D scanner, but George let me know all we really needed were precise measurements; that tempered my profligate tool buying habits.

With that sent over, it was time to let George do his thing. When I saw his first proposed design I was reassured I'd made the right choice and this would be a super fun contractor to work with. He did what an excellent designer does, which is to take the clients idea and improve it in ways the client hadn't thought to ask.

The soil sensor slides into a protective cover and is secured with one of the provided screws. The cap is screwed on with a quarter turn locking mechanism (the raised dome in the picture on the right). Simple, durable, plenty of airflow, reasonably easy access (still have a screw at the bottom to secure the board to the printed cover.

I printed up the first models in PETG; the color I had on hand was purple. PETG is cheaper than ASA and easier to print with. It was super exciting to see the first print commence!

Now, nothing goes from zero to hero with just one step, and along the way we had a few mishaps; failed prints, fittings that were a bit too loose or tight, and minor modifications. It took us, oh, 8 print attempts (maybe a few more) to get to a spot we were both happy with. Some of those were my fault as a beginner 3D printer, and some of those are a result of the necessary obstacles on the path to improvement.

The noteworthy modifications were shrinking the cap, making a small channel at the bottom for the screw instead of having it be just a hole, moving and slightly the shrinking the main air flow opening opposite the sensor, and closing off the the cap top on the battery side to protect the batteries as much as we could.

Working with George on this ended up being really engaging and fun as we went back and forth with ideas. When we ended up with a design we were both psyched with, I put in a final request for the Meteo Scientific logo (MS is the sensor business arm of GK) to be added to the print, and we did our first run in white ASA.

If you'd like to see these devices actually in use, I shared a video over on YouTube about how they're getting deployed.

So, that's it, from initial problem identification to solution finding, incremental improvements, and a finished product. The whole thing cost about $500 in design work from George, which seems super reasonable to me for the quality and outcome we got. I've made the print file freely available over on Printables, so if you'd like to print this out for your V3 sensor you're welcome to do so.

All the print settings are contained in that file, so if you've got a Prusa or access to one it should be a straighforward job to have your own housing up and running in no time. If you'd like to hire George to do work for you, check him out on Upwork here (you'll need an Upwork account).

Hopefully this inspires you to lean in a little to the next problem you're presented with and see if you can use the power of our connected world to solve your problem and share that solution with others.

Rock on!

Nik @ Gristle King

Archived Comments

Mark Roberts - 10/24/2023

This is an awesome package for the soil moisture sensor. Printed like a dream importing the step file into Prusaslicer and using their generic PETG profile. BTW, referencing your other articles on using this sensor on Helium Console and in Chirpstack... the github pointed to has a new order for the measurements so the decoder in Chirpstack needs to be reworked. -mark.


What devices can you use on Helium?

· 18 min read
Nik
Site Owner

Helium opened the door for a lot of us into the world of LoRaWAN, which stands for Long Range Wide Area Networks. After all the excitement of getting up Hotspots (technically, "gateways") up to earn HNT for providing coverage, we're left asking, "What can you do with Helium?"

One of the best places to start in an industry that already exists is to see what's already on the table. Sure, it's fun to figure out building your own DIY sensors, but for those of you thinking about running a Helium-based business, you just want answers that work. With that in mind, here's a long list of possible options for ya, courtesy of Felix Heins over at The Things Industries.

I've broken these down into categories that make sense to me and may help you find a sensor or solution. Keep in mind that many business models earn their money off providing the user-facing data and not selling the sensor. My prediction (and where I've literally placed my bet by investing in 'em) is that companies like UplinkEngine will start to become aggregators of all the different dashboards as well as offering their own in-house custom options, all available for white-labeling.

With that, let's get into the list. I've tried to describe what each sensor does very briefly, sometimes in my own words, sometimes pulling directly from the company sales page. Please let me know what you find useful, and if you're looking for a sensor you don't see here, drop a description in the comments and I'll see what I can find through my network of IoT contacts. The end goal here is to help everyone grow together by sharing the best information out there.

Medical/Health

eDoctor - Patient Vital Signs Monitoring Solution by Tektelic

Sani-Nudge - Hand Hygiene Tracker - Clinical studies and validations of Sani Nudge show that hospitals can achieve significant improvements in their facilities in any hand hygiene situation.

Backhaul/Connectivity

EM 2050 Evaluation Kit - Satellite connectivity in Europe by Echostar Mobile

Spacetech Denmach - Denmach ONE - Satellite connectivity for devices. "Our ground-breaking technology gives a voice to all things through the LoRaWAN connection into space. "

Air Quality/Weather

Trackpac's Indoor Air Quality Monitoring - For an excellent all-in-one service, check out what Trackpac has to offer.

CO2, Temp, Humidity "Stop Light Sensor" - Teneo Stoplicht - Sensor that shows various air parameter readings and gives you a red or green light for "good" or "bad"

Milesight AM300 Series - Indoor Air Quality Monitoring. The 319 runs off of batteries, the 307 is powered by a USB cable. I've got the 307 and would probably get the 319 for my next install.

Decentlab Indoor Ambiance Monitor - CO2, TVOC, and a motion sensor

Elsys Eco CO2 - Temperature, humidity and CO2 sensor, powered by indoor solar cell.

Browan Indoor Air Quality Monitor Tab - Same form as the original Helium Tracker Tab, but with different sensors inside to monitor Temperature, Relative Humidity and Volatile Organic Compound levels.

Thermokon NOVOS 3 x LoRaWAN - Room Operating Unit - Temp, humidity, CO2.

SenseCAP S2103 CO2, Temp, Humidity - A battery-powered IP66 wireless CO2, air temp and humi sensor, range from 400 to 10000 ppm, -40°C to 85°C, and 0 to 100 %RH, equipped with built-in Bluetooth and APP service for OTA configuration and remote device management.

SenseCAP S2102 8 in 1 Weather Station collects and uploads air temperature, humidity, wind speed/direction, rainfall, light intensity, UV index, and barometric pressure data.

Senzemo - Microclimate sensor SMC30 - collects data for temperature, relative humidity, and air pressure.

Silvanet Wildfire Sensor by Dryad - designed to detect forest fires during the early stages (even during the smoldering phase, within the first 60 minutes) and to monitor the microclimate, measuring temperature, humidity and air pressure. 

MClimate - Vicki - Smart radiator thermostat valve that contains a temperature and humidity sensor allowing for temperature control and monitoring temperature and humidity from distance. Manual target temperature selection is possible by rotating the outer ring of the device. The target temperature is displayed on the device.

General Sensors

Wittra IoT Out of the Box kit - Wittra is an IoT hardware company making both gateways and many sensors.

Wittra C{x}ameleon Tag - Extends hardware life, optimizes inventory costs and reduces waste.

Watteco BoB Assistant - BoB Assistant is a technology for predictive maintenance and operational assistance by permanent monitoring of vibrations and recorded temperatures of isolated systems (pump, air conditioning, cooling unit, fan…)

Watteco - Movee Devices - Tracking, geolocation, movement, vibration, and other monitoring.

Smart Ends - Brighter Bins Smart Sensors - BrighterBins accurately measures the fill level of waste-wells, dustbins, containers, and other bins.

Citilight iLuminate - Smart Light Pole Mount - Light for utility poles that reports when it's broken as well as dims when it's light outside.

SAFT IoT Smart Selector - Batteries built for IoT sensors. Their interactive "solution picker" seems like an excellent way to steer customers to the right thing and save time with directing sales energy.

Kuando Busylight - Light that shows green/red/blue for "status, cues, and notification". Can integrate with you calendar so your office shows a red light when you're on a call and don't want to be disturbed.

Enginko has a wide range of sensors which you can find here.

Thermokon - Window Open/Close sensor (EU only). They make a ton of other LoRaWAN sensors as well, worth checking out their website.

VOCSens - Gas sensing - Not LoRaWAN, but a sensor that could be hooked to a node. Detect/measures ammonia, carbon monoxide, nitrogen dioxide, formaldehyde, acetaldehyde now, and will soon add in detection/measurement of methane, CO2, hydrogen sulfide. Also under development: BTEX, ethylene oxide (EtO), ethylene, hydrogen sulfide (SO2), hydrogen (H2) and acetone.

Meshed nCounter - People counter based on the counting of Wi-Fi enabled devices in a specified zone, nCounter reports the number of Wi-Fi connected devices that entered a zone, left a zone and the average “dwell-time” of all devices present.

TWTG - Neon Vibration Sensor for measuring whether or not that A/C unit is still humming away up on your roof.

Parametric PCR2 - LIDAR People Counters - Support is expert but these stymied me for a long time.

SenseCAP Soil Moisture & Temp measures soil volumetric water content (VWC) and temperature.

Simplio Connected Buttons - Keep track of sentiment or problems in public and private spaces.

Tektelic Meeting Room E-Ink Display - Easily and efficiently track and manage meeting room occupancy status and bookings

Teneo Fill Sensor - Waste Containers - The filling sensor is a dedicated Internet of things solution from Teneo IoT BV that aims to solve the problem of litter, inefficient waste collection, polluted air (CO? emissions) & waste of resources through the filling degree sensor.

Wireless M-Bus Range Extender - Collects wireless M-Bus messages from utility meters and forwards them to a LoRaWAN® network.

Toran'O AtEx Zone 1 - Used to report status changes, pulse count values and analog measurements of equipment in an AtEx 1 sensitive zone such as water, gas, electricity or thermal energy meters, mechanical pressure switches, pressure transducers.

TRIPHAS’O sensor allows the remote reading of the electrical energy consumption of a three-phase installation in a non-intrusive way via the LoRaWAN® network. 

eWattch TyNess Modular - Combines many functionalities: modbus, mbus, PT100 temperature measurement, optical sensor measurement, voltage measurement, current measurement, etc.

eWattch TyNode - Pulse counting, digital input, temperature via PT100 probe, or measurement of analog signal 4-20mA or 0-10V

Sensoterra Multi-Depth Soil Sensor - The sensor comes with 6 soil moisture sensors in one device. Knowing the soil moisture at several depths will allow you to track the health of your plant at its active root zone during the whole crop cycle.

Dev Boards & DIY

STM32 Nucleo-WL55JC - STM32 LoRaWAN board with 3 LEDs, 3 buttons, and a reset button. Yeehaw!

Portenta Vision Shield - This hardware add-on will let you run embedded computer vision applications, connect wirelessly via LoRa® to the Arduino Cloud or your own infrastructure, and activate your system upon the detection of sound events.

SenseCAP Hub S2100 can connect to MODBUS-RTU RS485/Analog/GPIO sensors and transmit data from sensors to the LoRaWAN network.

Steval-Astra1B - Multiconnectivity asset tracking - development kit and reference design that simplifies prototyping, testing and evaluating advanced asset tracking applications such as livestock monitoring, fleet management, and logistics.

Controllers & I/O Magic

Comtac Cluey - The Cluey is designed for monitoring and controlling tasks in electricity, water or other infrastructure networks.

Watteco In'O Sensor - Class A or Class C sensor designed to transform any type of binary I/O sensor into a remote wireless sensor that monitors and controls industrial equipment status.

Enginko MCT-LW13MIO - This device transmits the state of its 16 inputs and controls 8 outputs through the LoRaWAN® network. All these inputs and outputs are galvanically isolated.

Arduino MKR WAN 1310 - Hook it all up for your DIY and one-off projects.

Location/Tracking

ioTracker - Smart tracker with button, buzzer, and LED.

Kerlink Wanesy - Indoor Positioning System - LoRaWAN, Bluetooth, WiFi

Mokosmart LW001-BG Pro - Tracker with 4000 mAh battery, 108.6 x 60 x 33.2mm

TD Synnex Low Power Asset Tracker - Combined LoRa and Wi-Fi passive scanning functionality provides accurate indoor geolocation accuracy, so you can keep track of remote assets around the clock.

SCD - SCD18-LoRa GPS - Integrates other protocols such as Bluetooth and WiFi position.

RhinoEdge Puck 50 - Rhino Horn tracker - 48 × 25 mm

Tektelic SEAL Wearable LoRaWAN GPS Tracker - Belt mounted personnel tracker

Solar powered asset tracker - combined LoRa and Wi-Fi passive scanning functionality provides accurate indoor geolocation accuracy, so you can keep track of remote assets around the clock. The unit also provides reliable, optimized connectivity and coverage for the next generation 4G LTE Cat-M1 and NB-IoT networks—and seamlessly falls back to 2G networks if necessary.

Wild boar ear tag trackers - Due to the light weight of the device and the attachment to the ear, even juvenile animals which exhibit strong future growth can be tagged. With devices' data storage capability, migrating individuals can be tracked all year around without any data loss.

Digital Matter Yabby Edge - Indoor/outdoor tracker featuring up to 12 years battery life in a small rugged housing available in Cellular LTE-M / NB-IoT or LoRaWAN® versions

Power/Energy Sensors

Acrios M-Bus IoT Electrical Meter reader - M-Bus to LoRaWAN or NB-IoT finds its application mainly in the reading of electricity meters and calorimeters.

Eagle 1500 - Single-phase din rail smart meter with a built-in magnetic 80A latching relay and an SMA socket for an external antenna.

Enginko Energy Meter Plug - Compact energy meter for monitoring the power consumption of the load, which can remotely be switched on/off. Equipped with a rechargeable battery for mains outage detection.

Izi-io 4840 - Substation Monitoring

Klax modern electricity meter readers (Europe)

Solar for IoT - Solar packages for many different sensor power requirements.

Netvox 809A Wireless Plug/Power Meter - Wireless plug and play power outlet with consumption monitoring for indoor use. It can remotely control the output switch and detect the output power.

IoT Service Providers

You can learn a fair amount by just cruising around an IoT company's website, seeing what they offer and how they position it. I'm including these in this list to give you a headstart on how you might build & sell an IoT business.

Mainlink - Smart IoT Services

Cital - Soil Moisture Sensors and weather monitoring

Lacuna Space - LS300 Sensor and Relay, interoperability from space with terrestrial LPWANs like Helium

Water Sensors

Aqua-Scope Ball Valve Servo - Need to switch water flow off and on? Check it, yo.

Droople iLink & Flow sensor - Monitoring real-time flow rate analytics for carbon filters, softeners, appliances and sanitary ware such as toilets and sinks.

Alliot Technology Water Flow Meter - Available to suit a variety of pipe sizes, the Robeau LoRaWAN® water flow meter can also integrate with the Strega smart water valve.

Laiier Water Leak Tape - the world's first smart tape that acts as a water leak detector and is LAIIER's first solution using Severn technology.

Control-IX Water Meter reader - For large scale deployments; institutional level. Will Nova work with Control-IX? Maybe...

Gateway Providers

Helium's long term goal is to allow any gateway to join the network. While that's not where we are right now (early 2023), this list of gateway manufacturers is good to keep in your back pocket for future use, OR if you want to leverage the Data Only gateway option you can start to use any gateway right now.

Conduit 300 Series IoT Programmable Gateway

HT Micron LoRa System In A Package - For the geekier among you...HTLRBL32L is a highly compact and low-power wireless communication device featuring LoRa® and Bluetooth® Low Energy capabilities in a tiny 13x13x1.1 mm package.

Milesight UG65 - LoRaWAN Gateway

Miro Edge - LoRaWAN Gateway. The small form factor, integrated interfaces such as Ethernet, WIFI, mini PCI-E and the underlying LinuxOS enable these gateways to be easily integrated into any infrastructure.

Laird Sentrius RG1xx Gateway - Gather data from as far as 10 miles via LoRaWAN and sync to the cloud via Wi-Fi / Ethernet, or add LTE in the US with our optional LTE version. 

RAK Wisgate Connect Base Kit - RAK7391 WisGate Connect is a Raspberry Pi CM4-based gateway product meant to support different radio and WisBlock modules. It has several interfaces to meet the needs of different developers (HDMI, Ethernet, USB, mPCIe, CSI, DSI, M.2, WisBlock, PoE, Raspberry Pi HAT).

El Fin

This is not an exhaustive list, and that alone should be gobsmacking. There is an enormous world of ways to sense the world, dive in, level up your learning and please share with me what you build!

Rock on,

Nik Hawks

How Wet Can Ya Get? Let's Get Muddy!

· 14 min read
Nik
Site Owner

Diving deeper over at Meteo Scientific on this plant nursery project, we wanted to blast out of the gate with something we thought would be incontrovertibly useful. For a nursery in the coastal desert environment of San Diego (albeit with local micrometeorological conditions), keeping track of soil moisture in all the pots seemed like a good start.

With that in mind, Dirk had found a cool soil moisture sensor over on MakerFabs that runs about $20. It's the V3 version, which is All In One (AIO for you cool cats). That means it's a sensor and a LoRa radio, not just a sensor which you'd have to connect to something like a Wisblock. BFGNeil explained that one to me. ;)

Steps

  • Buy sensor. Geek level: N/A
  • Add device (the sensor) to Helium Console. Geek level: Minor
  • Add batteries (2 x AAA). Geek level: N/A
  • Upload Arduino sketch to sensor (significant geekery involved, but I'll walk you through it). Geek level: High
  • Set up Home Assistant. Geek level: High, walk through of that over here.
  • Add Soil Moisture sensor to Home Assistant (HA). Geek level: high
  • Rejoice at success: Geek level: N/A

Ok, so here's the thing in its package. Very fancy looking.

Once you get it out of the package, there are only 4 things in there; the device, 2 pieces of the protective cover, and a small bag of screws. It needs AAA batteries, so make sure you have some on hand!

Oh, while you're prepping, remember to add the device to your Console before you really get started. By the time you're done fiddling with the tiny bits it should have passed through the XOR filter and be ready to roll!

Beep beep: Arduino Time!

Now that you've done the easy stuff, let's get stuck into the shitkicker of the geek world, Arduino. If you've never used Arduino before I'ma give you a heads up: There WILL be hiccups. This is not plug and play stuff. Professional geeks love things that only work when you know what you're doing. I find it both frustrating and enticing, which is why I write these guides. I want to help trigger your inner geek without it being too frustrating.

Let's go over the 30,000' view of what we're doing with Arduino and this sensor, then we'll dive into the details.

In broad strokes, you're loading a program onto this sensor that tells it what to do, what to send, where to send it, and how often to send it. That program uses "libraries" from the Arduino ecosystem. Those libraries are other programs that the program you're going to load refers to. In order for this thing to work, you need every library that the program calls for installed on your computer.

This next part will gobsmack you: It is NOT common practice amongst Arduino programmers to let you know up front the full list of libraries you'll need. The ones who are trying to be helpful will, but usually you'll get a list of the special ones they used, not all libraries necessary. Typically, the way enthusiasts find out what libraries they're missing is to run the code and see what error messages come up.

Once you load a library on your system, it's there, so you don't need to load it again. That feature makes it easy for someone who's been working in Arduino for a while and already has a bunch of libraries loaded. It makes it really difficult when you're first starting; you're constantly finding that you need another library. It's kind of a treasure hunt, which is probably why the geeks like it; it's pure problem solving.

This whole "treasure hunt" style of getting things done is super common in this world. You take a few steps forward, you hit a wall, you look around, you go back and look at the map, in the bottom right corner you see the clue that's upside down and spelled backwards that gets you over the wall, and you repeat that until you get to where you want to go. So, with that as the background, and my promise to you that I've found almost all of those clues and removed as much friction as I can, let's get started!

You'll need to download the Arduino IDE, or Integrated Development Environment.

Let's start with setting up your IDE correctly. We're going to tell it what kind of board you're using. In this case the soil moisture devices uses an Arduino Pro or Pro Mini. You can follow along over on the MakerFabs page for this sensor, which is where some of this info comes from. This is what it may look like if you're on a Mac.

If you don't have that already set up, you'll need to add the "Arduino Pro or Pro Mini" set to your app.

Next, let's add the libraries you'll need. In the Arduino app, go to Tools --> Manage Libraries, then type in the Library name you want to install. In the example, I'm using the MCCI LoRaWAN LMIC Library.

When I took the screenshot, I'd already installed it. If you don't have it, hit the Install button and watch the magic happen. Here are the other ones you'll need:

If you type in a Library and it doesn't show up in the Library manager, you can always manually install it by going to the link above, looking for the green Code button, then using the dropdown to download the zip file.

Once you have the zip file, in Arduino --> Sketch --> Include Library -- Add .ZIP Library and follow the prompts.

With the right libraries installed, go to Dirk's Github repository ("repo" is what the cool kids say) and look for "HeliumMakerfabsSoilMoistureV3". That's the Arduino "sketch" you're going to use.

Open it up, copy the code, then paste it into a code editor. I use Sublime Text for my code editor so I can change the DEVEUI, APPEUI, and APPKEY, and also so I have a working copy on my computer.

In the sketch code, starting at line 74, look for where you'll replace the APPEUI, the DEVUI, and the APPKEY. Those are normally pretty straightforward, but in this case you'll need to make one modification before you copy them from the Helium Console. You'll need to change the format to "lsb". To do that, go to the device in Console and, left to right, hit the boxes outlined in red below. Once you have the 0xDC 0xDE etc format, copy that and paste it into the sketch.

You want "lsb" for the DEVEUI and APPEUI, and "msb" for the APPKEY. Why? Because making shit complicated keeps the fluff off.

With a sketch made that's customized for your device using your DEV/APP/KEY, now you have to load it. This is the least reliable part of the whole process; it takes me 2-20 times to get it right. Now, it's possible that it's much easier with the recommended USB to serial converter, but I used what I had on hand, which requires that you restart the device at exactly the right time while keeping the cables firmly connected.

You'll need to hold down the RST (reset) button, press upload in Arduino IDE, wait until the status shows "uploading", and with exquisite timing, immediately release the RST button. Not easy, but you can do it. Just keep trying.

You'll know your sketch is uploaded when you see the Writing, Reading, and avrdude done print out on the Arduino app, like this:

With your sketch uploaded, watch on Helium Console to make sure you're getting a Join Accept/Request and a downlink. Once you see that, you know you're connected. It may take anywhere from 2 to 50 attempts for that to go through. I found that hitting the reset button the sensor every time it didn't go through sped up the process, but it wasn't very reliable.

Now you'll need to calibrate the device at the wet and dry points. To do this, use Helium Console's debugging tool and the device's reset button. Open up the Debug tool by hitting the little black bug button. With the unit totally dry or totally wet, hit the reset button. This'll force through a reading that you can get a payload for. Reset the Debug tool each time, then hit the Reset button on the device and wait until you see a Decoded Payload, then expand Integration Message and look for ADC.

You want the device wet right up to the line that says "Put this part to soil." You may find if you test that you get different values with saturated soil vs water, but water is way easier and cleaner, and the difference is probably within the accuracy parameters of the device.

I did three cycles of fully wet and fully dry, then averaged 'em out to get a high value (Air Value) and a low value (Water Value) I could enter into the sketch.

Once you have those, update your sketch's Air Value and Water Value and re-upload your updated sketch to the device.

Take a breather, you've come a long way! The last step here can go two ways. If you're the only one using this data, you can push it through from Helium Console to Home Assistant. That might look like this when you finish up. Here are 3 plants (2 at home, 1 at the office):

Adding the data from your sensor to Home Assistant takes 3 (broad) steps. First, send the data from Helium Console to an MQTT integration (details for that setup over on this post).

Second, update your configuration.yaml file in Home Assistant to include the MQTT data now coming from the sensors. I'm going to copy in mine, which starts with the door open/close sensor from my earlier blog post. That one is labeled "binary_sensor" in the yaml. You're going to add in another one below it for the soil moisture device, labeled "sensor". It'll look like this.

mqtt:
binary_sensor:
- name: "Gate Sensor"
device_class: opening
payload_on: "1"
payload_off: "0"
payload_not_available: ""
value_template: "{{ value_json.decoded.payload.DOOR_OPEN_STATUS }}"
state_topic: "helium/xxx-YOUR-HELIUM-DEVICE-CONSOLE-ID-HERE-xxx/rx"
sensor:
- name: 'SM1 ADC'
state_topic: "helium/xxx-YOUR-HELIUM-DEVICE-CONSOLE-ID-HERE-xxx/rx"
state_class: measurement
value_template: '{{ value_json.decoded.payload.data.adc | int }}'
- name: 'SM1 Battery'
state_topic: "helium/helium/xxx-YOUR-HELIUM-DEVICE-CONSOLE-ID-HERE-xxx/rx"
state_class: measurement
device_class: voltage
unit_of_measurement: "V"
value_template: '{{ value_json.decoded.payload.data.battery | float | round(2) }}'
- name: 'SM1 Humidity'
state_topic: "helium/helium/xxx-YOUR-HELIUM-DEVICE-CONSOLE-ID-HERE-xxx/rx"
state_class: measurement
device_class: humidity
unit_of_measurement: "%"
value_template: '{{ value_json.decoded.payload.data.humidity | float | round(1) }}'
- name: 'SM1 Soil Moisture'
state_topic: "helium/helium/xxx-YOUR-HELIUM-DEVICE-CONSOLE-ID-HERE-xxx/rx"
state_class: measurement
device_class: moisture
unit_of_measurement: "%"
value_template: '{{ value_json.decoded.payload.data.soilMoisture | float | round(1) }}'
- name: 'SM1 Temperature'
state_topic: "helium/helium/xxx-YOUR-HELIUM-DEVICE-CONSOLE-ID-HERE-xxx/rx"
state_class: measurement
device_class: temperature
unit_of_measurement: "°F"
value_template: '{{ value_json.decoded.payload.data.temperature | float * 9 / 5 + 32 | round(1) }}'

As you can see, you'll need to enter in a "state_topic". You'll find that in Helium Console in the Device page. It'll look something like this:

With the yaml file updated, go ahead and refresh that in Home Assistant. Developer Tools --> Manually Configured MQTT Entities.

Ok, so now that Console is sending it and HA is receiving it, the third step is to make it visible for ya.

Create "cards" in Home Assistant to show you what's going on. Go to Overview --> 3 dot menu --> Edit Dashboard

Now hit "Add Card" (blue button in bottom right) and search by name, then follow the prompts to show what you want to see. You probably want Entities or Statistic Graph, but it's up to you.

That's it! You're all done if all you want to do is see it yourself.

If you're planning on sharing the data with someone else (a client, or your fellow geeks), consider UplinkEngine, which is a company I invested in back when it was still just HeliumVision.

They're currently doing just bespoke solutions that look like this. I've outlined the sensor in red, and you can display the stats however you want, this is just what we've got going right now.

However you display your data, if you've followed this whole thing through, congratulations! You've added one more sensor to the Helium network, learned a ton, and hopefully will be able to keep your plant in top hydrated condition!

Rock on,

Nik

Notes & References

Working instructions for geeks here: https://github.com/dirkbeer/Helium\_MakerfabsSoilMoistureSensorV3

Original Project here: https://community.home-assistant.io/t/makerfabs-soil-moisture-sensor-v3-lorawan-ttn-v3-and-ha-integration/446021

Denicola V3 decoder: https://gist.github.com/denicola2/79639d7b17bf1b828c7cfeffedee0a13

Useful notes specific to Helium here: https://big-pisces-61a.notion.site/Things-I-had-to-do-to-get-the-MakerFabs-Soil-Moisture-Sensor-V3-working-on-Helium-for-EU868-4775729c5f304c9ab6fd3efc7b99af02

Arduino is written in C++, so if you're looking at it on the Sublime Text app, set the View to be C++.

In Arduino sketch, line 261 is "Air Value". With the sensor bone dry, record the ADC displayed in Home Assistant and enter that as your Air Value. It'll be close to 850.

How To Measure Endangered Vernal Pool Depth Using The Helium Network

· 7 min read
Nik
Site Owner

Over at Meteo Scientific (the business unit I started to run an IoT Sensor as a Service, or iSaaS), I've been working on a few projects, one of them around measuring vernal pools in the mountains.

Vernal pools are "one of California’s most endangered wetland natural communities" according to Dave Hogan, head of the Chaparral Lands Conservancy (CLL). They are seasonal pools usually less than a foot deep found on mesas and down in the valleys throughout my home region of San Diego. The CLL has a partnership with the Center For Biological Diversity to monitor these pools, including measuring their depth throughout the short wet season. Up until now, they were measuring the depth by paying contractors to hike out and manually measure each pool. This seemed like a great use case for the Helium network!

With any iSaaS offering, you've got three major hurdles to completion.

First is finding a customer. In this case, that was long time friend Dave Hogan, who runs the Chaparral Lands Conservancy. Dave and I have known each other for at least a decade now, and since we don't get to spend very much time together I was excited to use Helium as an excuse to spend time with one of the most well versed naturalists I've met in person.

The next question in running an iSaaS is "Do I have connectivity for my sensor?" With Helium, that's usually not a problem. It's got the largest contiguous wireless network in the world, with most places in urban and suburban areas covered. Almost anywhere in San Diego (except deep in remote valleys) has great coverage. Additionally, if we needed coverage in a remote area, I wasn't worried; off grid IoT connectivity through Helium is a specialty of mine.

The third step with iSaaS is knowing what kind of sensor to use. I checked in with Bryan at Parley Labs as well as Simon over at Datacake, and we decided to look at two different types. A Dragino LDDS20 Non Contact Liquid Level Sensor and an LDDS75 Distance Detection Sensor. I had both in my garage, and after taking a look at 'em, the LDDS75 seemed the appropriate one to use. The 20 needs to be on the bottom of a tank, and these meadow pools ain't tanks.

As usual when it comes to sensors, they ain't the easiest things to use and you have to be ready to learn. I jumped on the weekly Hackshare Collective call run by Travis Teague to get help, where Travis, Gray Hat Guy and Nickey walked me through setting up my device.

Step one is adding the device to the Helium Console. I've covered the steps to do that in other posts so will skip it here. The Draginos come with all the identifying keys on a sticker on the box, which is nice: DEVEUI, APPEUI, and APPKEY are all right there. I typed 'em in manually and waited for the XOR filter to let the device show up on Console.

Being a "hands dirty" guy, the next thing I did was open it up.

https://vimeo.com/789169465

With Gray Hat Guy walking me through it, I checked the battery level (both with and without load) because the device had been sitting in the garage for almost a year.

Then I realized you had to remove, rotate, and replace the yellow jumper in order to connect power to the device from the battery. That's one of those things every hardware geek says, "Duh" to, but if you've never seen it before, a lot of this doesn't make sense.

With the device added in Console and powered on, the next step is to set the parameters up so they match what you want. In my case, making sure I had it firing on a time interval that would be useful without wasting battery life.

To do this, you'll need a few simple things that'll open up a whole new world for you. First, a USB to TTL adapter, about $12 on Amazon. Second, a set of breadboard jumper wires, about $7. Finally, if you don't already have them laying around from the million other projects you've done, spend $8 on breakaway pin headers.

Once you have those, you can connect your device to your computer via USB and use a program called CoolTerm to change the settings on the device. Dragino has pretty good documentation on how to set all this up, but holler in the comments if you need help.

You'll need to make a few changes in the Options on Coolterm. In the Serial Port menu, set the baudrate to 9600. Then, in the Terminal menu, change the Mode to Line Mode, use CR+LF Key Emulation, and turn on Local Echo.

For this, the first thing I did was get a readout of what the settings currently were, using AT+CFG. That'll spit out all the current settings. In this case, I was looking for the TDC setting, which is the "transmit time". I wanted to test this device on my fountain at home with a shorter interval just to see how it looked on Datacake, then set it to a longer interval later to preserve battery life. I started with a 5 minute interval, saved it, unplugged the device and fastened the cover back on for testing.

I headed into the garage to knock together a quick PVC frame to attach it to.

These first test rigs don't have to be pretty, they just have to work. With that done, I set it up to monitor the liquid level in my fountain in the backyard.

Here it is with 5 minute intervals:

Once I was confident it was working I took it all down, brought it back in, hooked it back up to my computer and set the time interval to an hour.

The next step is to find out from the client what they're OK with as far as a mounting stand, assess the site, then build something that'll work for his needs. Time for a hike in the mountains with a GLAMOS to check coverage. I'll be back later this month with a follow up!

People Counter Update: Many Obstacles, Much Learning

· 8 min read
Nik
Site Owner

Way back in February of 2022, I wrote a Helium Foundation grant to deploy people counters on a trail here in San Diego. The grant was approved, I used the first tranche to buy the devices, and then ran into a series of obstacles that are common enough in this world of business, IoT, and interaction with various local governments that it's worth sharing them.

If you want to go back in time and read about the initial process, that post on the beginnings of the people counter project is here.

As we wind up the year (2022), let's run through the main issues along with the solutions (or lack thereof). We'll kick it off with "interacting with local governments".

The whole idea for the people counter came from doing a fair amount of hiking on one of San Diego's more famously difficult trails, the El Cajon Mountain trail. If you do the whole thing it's a little under an 11 mile round trip with a few thousand feet of gain. Almost none of it is flat, and almost all of it is out in the sun with no shade protection at all.

From 30,000 feet (thanks Google Earth!) it looks like this:

Here's the elevation view, just to give you an idea of what hikers attempt on this. There's 2,100' elevation different between the trailhead and the peak, and when you get to the top, well, you're only halfway through!

Now, in 2022 I've watched 2 helicopter rescues and assisted in the evacuation of one hiker. I KNOW this trail is a challenge both for hikers and for the county rangers who watch over it. Knowing how many people attempt it, what the traffic load is on the trail, where most rescues happen vs how far most people get all seemed like valuable information to me. When I proposed the project to the local ranger, he agreed. Unfortunately, I didn't get that agreement in writing.

Of the multiple challenges I faced in getting these set up, the first one was what killed it: I only got a verbal confirmation from the rangers that they wanted the project. While they were excited about it, their supervisors weren't. I haven't been able to sort out exactly what the problem was, but it's somewhere between a recent county ban on all "surveillance technology" (which these people counters look like but are specifically not as they use LIDAR, not cameras, so no identifying features are collected) and them already having a plan to deploy people counters. As of late Dec 2022, I've only seen one people counter on that trail, and it's at mile marker 1, pictured below. There may be more that I'm missing.

Either way, not having permission to deploy along the majority of the trail was the first big blow. I've written about surveillance tech and governments more over here but it left me with a bunch of trail counters and only a few miles of trail (the private land part) to deploy.

The trip into the private land adds about 100' of gain and a mile to the round trip. Still, that doesn't appear to stop inquisitive folks from going down the trail clearly marked "No trespassing". I see boot prints on the path there every time I visit. The owners of the land are still on board with deploying people counters, which gives me about a mile to work with to find out how far down the path people are going. Are they 30 second inquisitors, or are they hardier? How often does it happen? Is it something worth developing a strategy for, or just worth it to keep an eye on?

So, that brings us up to speed on the first major obstacle, which is permission.

The second obstacle was, funnily enough, Helium coverage. The places I'd selected for Hotspots have an incredible view of what is probably hundreds of Hotspots across the greater San Diego area, but when I placed the very first people counter in a test run, the signal strength its antenna was picking up was too weak to reliably transmit data!

That seemed odd to me, as I'd tested the location with a GLAMOS using the included 0 dBi antenna and it seemed fine. What I hadn't counted on was how weak the antenna in the device would actually be. While it's rated at 1.2 dBi, the Molex 105262 patch antenna installed in the people counter was showing far worse performance in practice.

So, lesson number two: Make sure you test your location with the same antenna your device will use. Seems obvious in hindsight, right?

This brings us to the last obstacle, which is getting the thing to actually work. In broad strokes, any useful LoRa system includes a device that sends its data somewhere, decodes that data, and then displays that data somewhere in a useful manner. Conceptually it's pretty easy to understand, but the details can be tricky. Every network, from Senet to TTN (The Things Network) to Actility to ones you've never heard of like Ventia or Axatel, all have a way of doing this.

Those methods are all pretty similar, but in the case of the Parametric devices there were two factors making for a challenging obstacle. First, Parametric is based out of Switzerland and focused (as far as I can tell) only on Europe. This means they don't really have support or interest in devices in the US. Second, they seem to only work on TTN devices. This is fine if you're in Europe and using TTN, but... I'm in America. And I'm using Helium. :)

Now, this is not to say that no support has been provided by Parametric. Sascha Jäckle, a managing partner and head of business development, has helped out over email with providing some guidance on how to get these thing working. It looks like they launched the People Counter as a product in late 2019, worked on it through 2020, then more or less forgot about it until I ordered them. Then they did 40% of all firmware updates in the last 9 months of 2022.

It's safe to say Parametric is now aware of Helium and acknowledges that the market for devices that easily work on the Helium network is bigger than they initially thought. Still, it took a group of US based IoT enthusiasts in a channel I host on the GK Discord to actually bang their heads against the thing long enough to get the whole flow to actually work. The final piece on our end, a fully operational decoder, took until late December of 2022 to solve.

Now, it's not like this group was working 40 hours a week on it; this was a volunteer effort at odd hours of the day, when they had time, by folks like @grayhatguy, @tteague, @nickytheblade, @rw4k, @falconpunch, and @.eddie E on Discord.

There are still a last few issues to solve with these things. The new 4.0 version of firmware released by Parametric in September of 2022 has a few bugs yet. All but one of the devices are deleting their own APPEUI and APPKEY, making them unuseable until that's fixed. Still, we've made progress, and I'm looking forward to getting these deployed and testing in the field by the end of the first quarter in 2023.

That should catch you up to speed on the People Counter project. The big takeaways for me were:
-If you're doing anything with a bureaucracy/government, get it in writing.
-running a LoRa based project without an engineering background is still too big of a lift to be practical
-the best of this entire IoT system is yet to come. I think we'll massive gains in 2023 as all of the various development efforts begin to bear fruit, but it might not be until the third or fourth quarter.

In the meantime, I'll keep plugging away at this grant project until I've completed it to the best of my ability. I've sent off 3 people counters to technical experts in my "IoT Support Group". Four will be deployed onto the trail, and 1 remains at my home test site. That leaves me with a few more to place anywhere in the US915 area, so...if you're reading this and want to participate in a People Counter project that helps spread the word about Helium and usefully contributes to solving a people counter problem, let's take everything I've learned so far and put it to work for you!

As always, the goal here is to help as many people as possible learn from our shared experience and continually develop a better understanding of our world.

Rock on!

Using Helium To Automate Your Home

· 24 min read
Nik
Site Owner

This is a project taking you through the basics of how to use the Helium LoRaWAN for projects around the home. Relax, we won't be automating your entire house and accidentally unleashing Terminator. This is just a very simple start into using Helium.

At the end, if you follow all the directions, you'll have a light that turns on when a door or gate opens. Super simple. Here's what it looks like in broad strokes.

Obviously you have a badass iron gate at the entrance to your mansion. You're in crypto, right?

Here's how the flow works in writing, with a little more detail.

The door sensor sends an "open" or "close" packet of data along with and identification of the sensor ("I'm a door sensor named 2r782sdhvwjf, and the door is now open") over LoRa to any nearby Hotspot.

That Hotspot passes the info on to the Helium router via the internet. When the data gets to the router, the router says, "Hey, anyone want to buy this packet from 2r782sdhvwjf?"

Your Console account (which you've set up to watch for packet from 2r782sdhvwjf) says "Hell yes I'll buy that packet!", pays with Helium data credits, and receives the packet data.

The data from the packet goes into your Console, where it's decoded and passed on to an "integration". The integration in this case is to an MQTT (Message Queuing Telemetry Transport) "broker".

A "broker" in this case is an application that receives and forwards MQTT messages. That MQTT message is sent by the broker to an open source program called "Home Assistant". Home Assistant lives on the Raspberry Pi.

The Raspberry Pi receives the data from the MQTT broker, processes it in Home Assistant, and spits out a nice little "open" or "close" message which it then transmits over WiFi to your Kasa (or any smart plug) saying, "Hey dawg, door's open, get that light on stat!"

And that's it, at broad strokes. Ok, let's dive into how to do this thing at home. We'll start with spending money, about $130 total. Relax, most of that is the Raspberry Pi, and once you have one you can use it to do all sorts of other things. Think of the Pi as a Swiss Army knife. This time you're buying it for cutting bread with the knife, but in the future you can use the corkscrew for wine, the screwdriver for opening that wooden shipping box with the Lister engine you'll wonder how you lived without, and the tweezers for removing that SD card. But...let's not get ahead of ourselves.

Purchase List

[ninja_tables id="6052"]

I put in the option for an indoor or an outdoor Kasa plug, which depends on where you have your light plugged in.

Once you've received all the physical things we'll go through the following steps in order:

  • Door Sensor
    • Add the sensor as a Device
    • Add a Decoder function
  • Home Assistant (HA)
    • Install on RPi and confirm it's available on your network
    • Configure Home Assistant
  • MQTT Messaging Broker
  • Connect everything

Aight! Let's get this party started!

Add The Sensor To Helium Console

Step one: Add the door sensor to Helium Console. Now, this is written in December of 2022, about a month (maybe more) before we make the giant switch from Helium running Console for everyone (10 device free limit) over to when you'll need to find another LNS (LoRaWAN Network Server). These specific instructions may not apply forever, but the broad strokes will.

Find the DEVEUI, APPEUI, and APPKEY associated with your sensor. If they're not in the box, you'll have to do some fiddly bits and buy one more thing for about $15. If that's the case, lemme know in the comments and I'll do up a tutorial on that for you. Easy when you know how. Daunting when you don't.

Ok, I'll assume you got the DEVEUI, APPEUI, and APPKEY. Enter them into the appropriate fields in Console (or whatever you end up using.). It should something like this:

Ok, so conceptually, what we've done so far is tell the Helium network that whenever any Hotspot receives data from this sensor (identified by the all the APP/DEV EUI keys) that you'll buy that data. Relax, it won't cost you that much, and if you want you can limit how often you'll buy it or from how many different Hotspots you want to buy it (if multiple Hotspots "hear" it).

To make sure we're getting packets through, go ahead and move the sensor/magnet apart a few times, as if the door was opening and closing. Pro tip: Do NOT install the sensor until the very end, otherwise you may be doing a bunch of walking back and forth to your door.

You should see little dots marching across the screen on the Device page, like this.

Cool, so you've bought the data, now you have to decode it. Semi-confusingly, this data will need several modifications in how its presented along the path sketched out above. Think of it this way: Not all computers speak the same language, and each time the data moves from one system to another, it (usually) needs to be translated. This "decoding" is the first translation.

Add The Decoder

For this (and any) sensor, the manufacturer will usually provide you with the decoder to use. In this case, Helium also maintains a Github repository with a decoder for this device. Confusingly, the decoder for this device in Helium's Github is called an LDS02, even though the device is an LDS01. I'ma use the Helium-suggested LDS02version below. If you use any other decoder you'll have to make some changes to the code further down. If this is your first time doing this, just use Helium's version. Here's how to do that if you've never used Github before.

Go to the page here, and look for "Decoder-v1.5.js" in the list of files.

Click on that and you'll see a box with a bunch of code. Click the little double-square button up in the top right to copy this. You'll be pasting this into the Helium Console next.

Now that you've got the decoder copied onto your clipboard, head over to Console and look for Functions on the left menu.

You're crushing, nice work. Now we're going to add a Function, pasting in the code you just copied. Hit the plus button.

Ok, we're going custom here, 'cause you're worth it. Hit the Custom decoder button.

That'll take you to the function page, where you'll name your function (I called mine LSD 01 Door Sensor) and then you'll paste in the code from the github decoder.

Remember, this isn't the Device you're naming, it's the Function. Once you have this Function decoder in Console, you can add a ton of devices and have all of them use the same Decoder Function. Cool, huh?

Now, if you just wanted to know if the door is open or closed whenever you looked at a dashboard, you could do one more step (add an integration to Datacake) and you'd be done. The flow would look like this in Console:

However, I don't think that's ultra useful. I mean, you'd have to open up a Datacake dashboard just to see if the door's open. That ain't automagic, that's a PITA. Onward!

Set Up Home Assistant On A Raspberry Pi

Let's fire up that Raspberry Pi you bought! I put mine in a very snazzy FLIRC case, but you don't have to.

Now, despite my love for explaining things, the internetz has done a far better job of Pi tutorials than I have, so I'll just leave ya with what the good folks over at Home Assistant (HA) have written as far as setting up HA on your Pi. Come back when you're done!

It should look something like this when you've finished. I mean, it might not be sunny and 57°F, but hey, that's the bitter depths of winter here in San Diego.

Great! For now, we'll leave Home Assistant and make sure we've got a reliable place for our MQTT broker (coming up next) to check in with Home Assistant.

Set Up A Publicly Accessible IP Address

Step 1 of the MQTT flow is to set up an IP address that Helium Console will connect to the broker on. The Helium Console MQTT Integration will need to connect to this broker at a publicly accessible ip address and port. Unless you have a fixed ip address (you probably don’t), you should set it up so that you can refer to this address with a name that does not change.

I used the free service provided by https://www.noip.com/ (check out that link for how to do it all, and heads up...port forwarding is a little tricky for first timers!)

With noip.com, I can get to my home network using an address like “gksupernet.hopto.org”. That'll send it to my current IP address as well as whatever my public IP address changes to next month when my internet service provider rolls it.

Now that we've set it up so you've got a reliable URL to send to (gksupernet.hopto.org, or whatever you set up on noip.com), let's jump back into Home Assistant.

First, let's set your HA profile to Advanced mode. Go to your Profile (down in the bottom left menu, it'll be your name), then scroll down until you see Advanced Mode and turn it on.

Add the Mosquitto Broker to Home Assistant

Next, we'll add the MQTT broker add-on. This is basically a translator and message forwarder for IoT devices. You can dive in here if you want, but for now, thinking of it as a translator/forwarder is probably fine. Instructions on how to add the "Mosquitto Broker" are here if you want 'em direct from the horse's mouth. I'll do the paint-by-numbers next just in case ya need it.

Start in your Home Assistant "front end" (I have mine saved as a bookmark), and look for the Add On Store.

Once you go to Add Ons, look at the bottom right for the Add On store.

In the store, search "Mosquitto Broker" and install the Add On. That should look like this.

Once you've installed Mosquitto broker, next you'll need to set up a user. Go back to the main menu (NOT in the Mosquitto Add On) and look for Settings-->People

Then look for the User tab, and set up a user. I set up "mqtt-user" and used "asd;lfjas;ldkfjasd;lfjkas" for a password. No, that's not really my password. Sheesh.

Saweet!

AIGHT, let's set up a port forward!

For this specific guide, you only need to set up one port forward: 1883. That's the default port for an MQTT broker. Having that port open on your network and forwarding it to the local IP of the RPi running Home Assistant means the MQTT broker can receive messages from Helium Console and pass them on to Home Assistant. Conceptually, that looks like this:

Port forwards poke a very specific hole in your network that is open to the outside world. If you think of your public IP as your home address that will take someone to your "front door on the internet", a port forward is like a tunnel from that door to a specific place in your house. That place could be a room, or a thing. In this case, the port forward is to one part (the MQTT broker) of one thing (the Raspberry Pi) on your network.

So, we're in kind of an odd spot here. "Port forwarding" is one of those things that is custom to your router. The absolute best way to figure it out is to Google [your router model] and "how to port forward", then follow the directions. It may be (has always been for me) a pain in the ass, but eventually I get it. You're welcome to jump into the GK Discord and ask questions, usually there are a few helpful folks in #general.

What you should have when you finish is a publicly accessible address of your broker. It'll look something like this:

mqtt://myusername:mysecurepw@gksupernet.hopto.org:1883

Substitute your user name, password, and the dynamic public IP you set up with noip.com above and everything *should* work.

Now, that URL prolly does nothing for you, but you need to check that your set up is correct! We'll do that next.

Download the MQTT Explorer app, fill in your creds, and test the connection. Once the connection tests out as good (it may take some fiddling, and you may need to restart Home Assistant), open and close the door a few times. You should see something like this in MQTT Explorer (as long as you're seeing "helium" under the $SYS, you're fine).

Now that we've got the port forward set up and tested so that Helium Console can send the data it gets and decodes from your sensor to the MQTT app running on Home Assistant, let's go back to Console and get 'er firing!

Setting up the MQTT Integration on Console

In Helium Console, look for "Integrations" in the left menu, then click the "+" button and select MQTT.

Then fill in the address you set up earlier, like this. It'll be something like this: mqtt://USERNAME:PASSWORD@gksupernet.hopto.org:8123

Once the Integration is set up we'll put together a Flow in Console. This is probably the only place in all of my ultra-limited coding experience where they added a drag 'n drop to make things easy. Start off with the Flows menu item, then look for Nodes and hit the "+" sign.

Now, the next 3 steps are straightforward. You're going to find your Device, your Function, and your Integration, and add them all to the Flow board. I'll show you how to add the Device, after that it's the same thing for Function & Integration. You got this!

When you're done adding those, your Flow board will look like this:

Yes, I still have the Datacake integration in there. Relax, you don't need to. All those dotted lines should be moving like ants crawling; that's how you know information is flowing from left to right. It's no guarantee that the thing on the right is receiving it correctly though. :)

Next up: Setting this up so when the MQTT gets the message it translates it to "open" or "close"

Creating a Door "Binary Sensor" in HA

Kk, back in Home Assistant (HA, remember?) we're going to set up the sensor that's "binary" (one of two things, i.e. Open or Close). Let's go into Home Assistant --> Settings --> Devices & Services --> Integrations.

You should see the MQTT Integration already, just waiting to be configured. Hit that Configure button and let's dive in. It may ask you if you want to configure Home Assistant to connect to the MQTT broker. You do. ;)

Once you've added it via the (confusingly labeled) blue Configure button, you'll have to actually configure it by hitting the blue Configure text.

That will open up the MQTT settings window. At the bottom of that, look for "Listen to a topic", enter the pound sign (#), and hit "Start Listening".

Open and close the door sensor a couple of times and you should see messages start coming in beneath the Stop Listening line. Now, you'll have to copy the Message Topic Name, which is the text after "Message x received on", starting with "helium". In my case, it's
helium/032a7107-7e45-41b7-9a69-ff1955dc5348/rx

I pasted mine into a Sublime Text Editor file, but you can use Notepad or whatever you'd like.

Now we're going to set up a place in Home Assistant to paste that info.

Installing File Editor Addon

In Home Assistant, go to Settings-->Addons-->Addon Store-->File Editor.

Type the first few letters of File to make it easy to find, then hit that sucker.

Once you've got it installed, turn on "Start on boot" and "Show in sidebar".

Once all that's done, hit the blue Start button, then go to File Editor in the sidebar. As my paragliding adventure buddy Robert says, "Now we're cooking with Crisco!" I think he means we're making progress.

Now that you're in File Editor you have to find the "configuration.yaml" file. Sounds complicated, right? It's not. You got this. Go up to the folder at the top left of the screen:

Then look for it in the menu that pops up.

Once you've selected it and opened it up, we're going to add the following at the bottom of that file. Remember to change the last line to YOUR "state_topic" will be the one you copied earlier.

mqtt: binary_sensor: - name: "Gate Sensor" device_class: opening payload_on: "1" payload_off: "0" payload_not_available: "" value_template: "{{ value_json.decoded.payload.DOOR_OPEN_STATUS }}" state_topic: "helium/032a7107-7e45-41b7-9a69-ff1955dc5348/rx"

Hey, two quick things to note. First**, in the obscure world of yaml code, the rules are strict.** The exact indentation shown above is required. Each level is indented two spaces from the previous one. Second, the “value_template” in the yaml code specifies the hierarchy and names in the Helium sensor message (decoded ?payload?DOOR_OPEN_STATUS in this case). If you used a different door sensor or Helium decoder Function than we did, you will probably need to modify this text to match your sensor message.

Once you've pasted in your fancy mqtt code from above, save the file with the red folder icon.

Now, reload the configuration by going to Developer Tools ? YAML configuration reloading ? MANUALLY CONFIGURED MQTT ENTITIES. Hit that, it'll turn green for a second, then back to normal.

Check your work back in Settings-->Devices & Services-->Entities. You should find an entry like this.

Oh. My. G. We're coming into the home stretch here. The next (and pretty much last) thing we'll do is set up a smart switch on Home Assistant and switch it based on the door sensor state changes. I'm going to use a Kasa Smart Wifi switch.

Now, I'm going to skip pictures and hand-holding for the Kasa Switch setup; that should be pretty straightforward. Buy the switch, put the Kasa app on your phone, add the switch to your phone.

Setting Up The Smart Switch in Home Assistant

With the switch installed on your local WiFi network, let's head over to Home Assistant, where we'll add a Kasa Smart integration. Go to Settings-->Devices & Services-->Integrations-->Add Integration. I skipped the picture for Devices & Services. You got this.

Use the Search field to narrow it down, then select TP-Link Kasa Smart. Leave the "host" field empty, it'll find your devices.

If you're running multiple WiFi networks in your home to separate out your personal devices (like phones, computers) from those scum-sucking IoT devices, you'll need to get a little geeky on your own with allowing Home Assistant to access your networks. I had to Google on this, but because it's a router/modem related issue, there's not a great way for my experience to translate to yours. GIYF here. Google Is Your Friend.

When you get it all right, you'll see the Kasa devices you have on your network. Heated mat for the win in the San Diego winter. For now, we're going with the one labeled GK HA Garage Switch Integration. Fun note: I renamed this to just be GK Garage Switch, as the addition of Integration at the end confused me when I was trouble shooting later.

When you're done with adding it in, our final steps will be to add an Automation in HA that turns on the switch when the door sensor fires. Restart Home Automation to lock in your changes (HA Settings-->System-->Restart (top right) and prepare for the final push. We're close now!

In Home Assistant, go to Settings-->Automation & Scenes.

Then look in the bottom right for "Create Automation".

Start with an empty Automation (don't get suckered into the pre-filled ones yet!)

You'll see a window where the "flow" should make sense. We're going to add a Trigger, a Condition, and an Action.

Start by adding ("+") a Trigger, which will be a "State" change.

  • Trigger name: When Gate Sensor changes from off to on.
  • Entity: Gate Sensor
  • From: Off
  • To: On
  • For: 0:00:00

Now we'll set a Condition for the State of the sun so that this only fires when the sun ain't out. You may rush, as I did, into using the Condition of Sun, instead of a State. It probably doesn't matter, but for my Automation, which is tested and works, I used the State, which is indicated by that little triangle of arrows.

Finally, we'll set the Action, which will be a Device action, as indicated by the little Device symbol outlined in red, below.

You done, dawg. Open and close the sensor a few times to make sure the light switches. It should. If it doesn't, go back and carefully check you followed the instructions. One little thing, like the wrong decoder, or choosing the wrong thing from a dropdown, or whatever, will stop the flow of operations needed to make the magic work.

A quick and geeky note: Home Assistant won't know the state of your sensor until the sensor sends a message. That happens the first fimte you open or close the sensor. This is because sensors in the world of IoT typically don't constantly broadcast their state. That would be a waste of energy. The gate sensor only needs to broadcast one message, as it happens. "I opened." Or, "I closed". That's it. It doesn't need to say "I'm open I'm open I'm open I'm open etc" until it runs out of juice. This is why in the Trigger in HA has to be "Gate sensor changes from off to on", not "Gate sensor is on".

With that...

El FIN. Congrats! You are now a stone cold HA MQTT sensor integration killer. Now get out there and dream up some rad new automations for Home Assistant, and please, make sure you share your best one with the rest of us over on the GK Discord.

A GIANT THANK YOU to Dirk Beer (dirkbeer#3592 on Discord) for walking me through this thing soup to nuts and making sure that us non-engineers have access to getting deep in the weeds with Helium. Rock on Dirk! Additionally, the secretive group known only as the "AF" were instrumental in making sure I got through several hurdles in the realm of MQTT and home networking. AFF!

Archived Comments

Jeremy Wesley - 8/21/2023

Thank you SOO much for putting this together.. As a long time Home assistant user and helium user since the Gen1 Hotspots, this has been on my wish list for a very long time. The MQTT section is the GOLD that I was missing. I really appreciate your post and the videos you make for the community.


Nik - 8/21/2023

No prob, happy it was helpful. Crush!


WJ - 9/11/2023

Does this walk through still work with the Solana Change? I've been following Helium a little the last year or so and have been blown away on how awesome a network like this can work for remote areas like where I'm from.


Nik - 9/11/2023

In general, yes. The rub will be in connecting to MQTT, which not every Console offers.