Gerrit Niezen

Maker of open-source software and hardware.

Feature image

I've been looking for a LoRa module since I helped to install the first Things Network gateway in Swansea:

Today we installed the first @thethingsntwrk gateway for our region. We are actively contributing to the 100% open source #IoT network 😎 #ThingsConnected #Swansea #LoRaWAN #geeks pic.twitter.com/duQKy0WwWb

— TechHub Swansea (@TechHubSwansea) May 29, 2018

The Things Network is an open, community-built network using LoRaWAN technology, which allows for long-range (up to 10km) low-power wireless communication without needing a special license or monthly subscription.

This morning I saw a tweet from Tod Kurt (maintainer of the excellent node-hid Node.js library):

Cool ESP32-based LoRa module w/display for $26! as described by @VinduinoReinier at @hackaday meetup @SupplyframeDL https://t.co/CZ9vz2uPZP

— Tod E. Kurt (@todbot) June 29, 2018

The ESP32 is the successor to the ESP8266 microcontroller and contains a 32-bit microcontroller with both WiFi and Bluetooth LE. Add LoRa and an OLED screen and this is a very impressive package for less than £20. Compare this to The Thing Network's own Arduino-compatible Things Uno that only has LoRa and costs more than double the price.

I had a quick look at The Things Network forums and it looks like a lot of people are already using these, as they were released towards the end of last year. There seems to be some antenna issues, but that these can probably be fixed if you do need longer range.

#Electronics

Comment on this post

Feature image

In a previous post I started playing around with Bluetooth LE on blood glucose meters. This post is a quick look at Bluetooth LE's diabetes device profiles.

Bluetooth LE is an open specification, meaning anyone can download it from the website and read it, compared to most ISO standards where you have to pay and arm and a leg just to read the spec[1]. So I started by looking through the list of Bluetooth profiles to see which ones are specific to diabetes.

There is a Glucose Profile (GLP) for blood glucose meters and a Continuous Glucose Monitoring Profile (CGMP) for continuous glucose monitors. However, it looks like the Insulin Delivery Profile (IDP) is still under development, as the only public mention I can find on it is in their list of acronyms. I did however, find a medication field in the Glucose Profile, so if you want to record the insulin dose as part of a blood glucose measurement, that should work without having to wait for the Insulin Delivery Profile to be released.

I tried to see if I could find out what the progress of the Insulin Delivery Profile was. However, to do that it looks like you have to join the Medical Devices working group, and to do that you need to be an “Associate or Promoter” member. That costs $7.5k/year if your annual revenue is less than $100 million. Probably worth it if you want to influence what the standard looks like, but not worth it if you're just looking for some info. Hey, if you know the current status of the Insulin Delivery Profile, please get in touch! ;)


  1. or proprietary specs, where you usually have to set up a partnership and sign an NDA to read it ↩︎

#Tidepool

Comment on this post

Feature image

A week ago I wrote about building a USB host to Bluetooth LE bridge. I then ordered a Sparkfun USB Host Shield from one of the UK distributors, CPC Farnell.

The shield doesn't come without any headers, which prompted me to start organising the electronic components I have at the Swansea Hackspace, as I knew I had a spare set of headers there. I managed to find the headers last week, and soldered them on at the hackspace last night.

This morning I wanted to see if it works, so I plugged it into my old Arduino Duemilanove, released in 2009 and still going. I installed the USB Host Shield Arduino library[1] and loaded up the board_qc self-test sketch. The Arduino sketch uploaded without any problems. On the shield, I first had to connect the D7 pin to the RESET pin[2]. Also, note that there is a little power switch on the shield that you have to turn on ;)

The self-test ran without any issues. Note that to skip the GPIO test, you have to enter any character into the serial monitor and press Send. You also need to have a USB device (like a keyboard) connected during the self-test. As part of the self-test it connects to the device and displays the USB descriptor in the serial monitor. Very cool!

I then loaded up a HID keyboard sketch, and it worked flawlessly! I was able to type letters on the keyboard connected to the shield and see them appear in the serial monitor. It's pretty impressive that I could just plug a shield into a piece of hardware almost a decade old, load some code on it and it just works. Open-source hardware FTW!

usbShield2

If you'd like even more details on getting started with the USB host shield, see this great tutorial.


  1. See the README file for how to install the library ↩︎

  2. Why? I have no idea, but it was mentioned in the comments on the Sparkfun website ↩︎

#Electronics

Comment on this post

Feature image

I was listening to my “Discover Weekly” playlist on Spotify this morning, when the song Open Door Policy by Beans on Toast started playing. I've never heard of him before, but I feel like the song summarises this moment in time pretty well.

The world is dying
Shit is getting serious
Everybody's lying
It's impossible to tell the truth
It's worry, worry
Worry, worry
Worry, worry
Worry, worry
All the time
That don't solve anything
I never used to be the worrying type
But I'm not exactly sure
What I'm supposed to say
When it feels like Armageddon
Is a stone's throw away
And everybody voted for the greedy in charge
Well if this is a fight
Then maybe we lost
But, me I'm a pacifist
Eternal optimist
I'll keep on singing
Stating the obvious

Simple subject matter
Over-analysing a cup of tea
Where did the milk come from?
I bet it was a tragedy
There's Fluoride in the water
It's blurring the vision of my third eye
But still I put the kettle on
What a time to be alive

And I'm not even sure
If the facts are true
Cause I'm constantly bombarded by so many points of view
And, I am my own propaganda machine
I believe what I believe I am supposed to believe
And I'll believe in anything
So show me everything
I'm dancing like a puppet
Not knowing who is pulling the strings

Dark money and big data
And the mass manipulation of the human race
Advertising's Frankenstein
Knows me better than I know myself
Every website that I visit
Every bit of porn I watch
And every shred of news I read
They analyse, hypothesise
Then use it as a weapon
To brainwash me

And now I'm almost convinced
That all the news is fake
But I've been staring at the screen so much
That I fucked up my neck
And, I am my own propaganda machine
I believe what my computer
Wants me to believe
Oh, I sit and stare at it
Think I'm above that shit
Hook, line and sinker
Fell for the internet

It was always gonna happen
The robots are coming now to take our jobs
3D printers printing 3D printers
3D printers printing jails and guns
Well this car needs a driver
And these brains need reality
Not just a phone strapped to your face
While immersing yourself
In a world of make-believe

But I've kind of come accustomed
To the, 360 view
Because it's almost realistic
And kind of believable
And, I am content as long as I am entertained
And walking off a cliff is one hell of a game
So, I'll put my headset on
Say “See you later folks”
I can't even hear you while you're
Stating the obvious

But what is life if not
A brilliant barricade of obstacles
I'll carry a stranger's bag down the stairs
But I can't carry the weight of the world
And so I watch the flowers grow
And I listen for the beauty
As it shines from in-between the gaps
There's a light at the end of the tunnel my love
So don't you ever give up

And they've discovered seven planets
Orbiting a distant sun
They are light years away
But they remind us of home
They remind us to hope
They remind us to dream
And all the wonderful things
Human-beings can achieve
So, quit your worrying
Start your partying
One door is closing
And another one is opening

#Music

Comment on this post

Feature image

This blog runs on the open-source Ghost platform, on my own Digital Ocean instance. There are no pop-up banners warning you about cookies. And no privacy policies or terms and conditions. Why? Because it doesn't track you.

Google provides a free tracking script you can add to your website that allows you to see an almost inconceivable amount of information about people who visit your website. Why does Google give it away for free? Because they get access to this information as well. And for one ad company to have so much information cannot be a good ting.

I've set up my own instance of open-source tracking software Matomo (formerly known as Piwik) in the past, but started to wonder why I'm doing it at all in the first place. It makes the page slower to load, and knowing how many people visit the website is not that useful.

Indeed, for my tiny blog, knowing the exact number of website visitors can be counter-productive. Now that I don't know how many people read this, I can focus on the writing instead of how to make people come to the blog. But even for much larger sites, there must be better ways to measure your impact.

Comment on this post

Feature image

I can't quite remember how I came across this comic series called Incredible Doom, but it's brilliant. It's about a group of '90s kids getting up to things on the early internet. I feel I can relate ;)

It's created by Matthew Bogart, and the best way to get them is by supporting him on Patreon. I only joined his Patreon recently, but was able to get the back issues in his web shop[1].

You can read all the issues online for free, but I would seriously suggest you join his Patreon as the print issues are so cool! The printed format reminds me a lot of Field Notes, and is similar in quality. Each issue has a “feely”, an artifact from the comic brought into the real world.

incredibleDoom2

He also gives regular updates on his Patreon with work-in-progress videos, and you get access to a bunch of e-books with some of his older work. I was very surprised to even get a personalised video message when I joined. If you were a '90s kid on the early internet, do yourself a favour and read the first issue online.


  1. currently 50% off ↩︎

#Reading

Comment on this post

Feature image

If you want to build anything, you probably need to go down to the hardware store to pick up some materials, or order something from an online store. But what if you could create the materials you want to use from scratch?

An advantage of open-source design is that we can distribute the designs online so that the product can be made locally, reducing transport costs and environmental impact. Opendesk is a great example of this, where you can find a local maker with a CNC router to build furniture out of plywood based on an OpenDesk open-source design.

But we still have to ship the materials used to build the product, like the plywood in the Opendesk example. Current supply chains are optimised for centralised factories, not decentralised makers. What if we can use local materials instead? Imagine we can make it easy enough for a local woodland or forest owners to sell individual trees, and we can share mobile sawmills for on-demand wood production?

I've been wondering how this would work for other materials like plastics, and then this tweet popped up in my feed this morning:

Creating plastics made from algae, starch and proteins with @AGarmulewicz & @_ECorbin from @Materiom_ - a materials recipe book using locally abundant nutrients. A teaching materials session from today’s Higher Education Workshop. #circulareconomy pic.twitter.com/4fntjBdib9

— Ellen MacArthur Fdn. (@circulareconomy) June 20, 2018

Materiom is a brand new open materials database with recipes for biopolymers and composite materials you can make using locally abundant sources. For example, using mussel shells and sugar you can make a calcium carbonate composite that can be used in 3D-printing with a syringe pump extruder:

musselComposite[1]

I remember experimenting with creating artificial leather from kombucha as part of the first BioHack Academy back in 2015, so it was nice to see they've included a kombucha fabric recipe as well.


  1. Image licensed under CC-BY 4.0 : Marita Sauerwein, cover image by Margarita Talep Follert ↩︎

#Making

Comment on this post

Feature image

Over the years I've built up a collection of random electronic parts, from Arduinos to loose resistors. I've been storing them in various boxes, containers and a locker at the Swansea Hackspace, but I really can't remember what's in there anymore.

A while ago I came across a blog post on how to organise electronic parts using Partsbox.io, and since they have a free account for home users I've decided to give it a try.

I got hold of 100 small (2.25” x 3”) clear resealable bags on eBay[1], to be able to sort and label the smaller components. I wish I could justify buying a label printer[2] as they look super fun to play with, but for now I think I will just use a sharpie and blank address labels.

This is going to take some time, so I hope to give an update on my progress with a future blog post, in terms of how long it took and whether it was actually worth it.


  1. for £1.80 including P&P ↩︎

  2. like the Brother QL-700 ↩︎

#Electronics

Comment on this post

Feature image

A shower thought I had this morning was to see if there's an Arduino shield that could act as a USB host, also known as USB OTG (On-The-Go), that I can plug that into the Espruino Pixl.js.

Why would I want to do that? Well, that would allow me to read data from USB devices, like the insulin pumps and blood glucose meters I develop drivers for in the Tidepool Uploader, display some of the data on the Pixl.js display, and then forward it onto a smart phone or computer via BLE.

Turns out there are at least two Arduino USB host shields, the official Arduino USB host shield and one made by Sparkfun. If I understand correctly, the official one connects through the Arduino's ICSP header, which is not available on the Pixl.js, leaving me with the Sparkfun option.

Both use the MAX3421E USB peripheral/host controller chip, so I'm wondering if I could eventually design a little dongle that consists of the MDBT42Q BLE module inside the Pixl.js and the USB controller chip. The BLE module is £6 in volume, and the USB controller chip between £4.50 and £6.50 depending on quantity. This makes it more expensive than a Raspberry Pi Zero W, even before you add the PCB and discrete component costs, but it should be much less power hungry.

#Electronics

Comment on this post

Bluetooth Low Energy (LE), also known as Bluetooth 4 and formerly known as Bluetooth Smart, is supported by most mobile and desktop operating system and can be found in many wireless devices. It was developed by Nokia in the early 2000s and first marketed as Wibree, a competitor to the Zigbee low-power wireless standard.

While Zigbee is used in many smart home devices, like smart meters and light bulbs, the rebranding of Wibree as Bluetooth LE helped it to take over the smart phone market, with around 90% of new mobile devices now supporting Bluetooth LE.

Bluetooth LE has open specifications (called profiles) for various types of devices, including blood glucose meters (BGMs) and continuous glucose monitors (CGMs). At Tidepool we've had to work very hard to get communication specifications from device manufacturers in order to communicate with their devices over USB. These are all proprietary protocols which have to be developed for and supported separately, and apart from Ascensia (previously Bayer), not a single company have published their protocols in the open. Now with Bluetooth LE, having a common standard specifying how these devices should communicate that is supported by device manufacturers is great!

I downloaded an app from the App Store called nRF Toolbox by one of the Bluetooth LE chip manufacturers, Nordic Semiconductor. It has support for various BLE profiles, including the BGM and CGM profiles. I was able to successfully connect to and read data from a Bluetooth LE-enabled BGM called the True Metrix Air, after entering the device serial number to pair:

#Tidepool

Comment on this post

Enter your email to subscribe to updates.