Author Archive
T1D Toys
Lets start this with a clear statement – This is not a ham radio post
Introduction
My youngest was diagnosed with Type 1 diabetes a little over 12 months ago. Type 1 is a bit different from Type 2 diabetes in that it is auto immune and there is no insulin available. This means a regular tightrope of carbohydrate intake and insulin being administered. In our case this is through a pump.
In the good old days that meant taking a bit of blood from your finger. measuring it for blood glucose and then acting on the information. This could mean correcting to meet a magic number (6 mmol) or just before a meal.
In the modern connected world there are a few toys that can help you. Freestyle Libre continuous glucose monitoring, Nightscout, XDrip+, Miao Miao, Smart watches…….This is my experience of setting a few of these things up. Hopefully in a non techie way.
Setup prior to new toys
- Omnipod Insulin delivery with the Insulet PDM
- Old android phone
- Freestyle Libre Continuous Glucose Monitor (CGM)
The game goes like this. Offer up your phone to your patch, it reads the sensor and you get a BG reading on your phone. Make any adjustments using the PDM Nothing too exciting there.
The problem
The problem with this is that at night there is still a regime of checking. The CGM is collecting data and it needs a human to wave a phone near an arm (invariably the wrong one, in fact sometimes it takes three goes to get the correct arm!)
There are no alarms or warnings
After a few poor nights of sleep it is easy to miss a check and hence mistakes will happen
A solution
Here’s the basic wish list. Use the CGM to it’s potential without waiting for a commercial integrated solution. This means connecting a few things together and for the information to be displayed on a smartwatch in such way that it provides an adequate indication of the state of BG play. So here are the ingredients
- Freestyle Libre – The CGM
- Miao Miao – A bluetooth device that sits on the Libre patch
- Android Phone – The hardware glue
- Fitbit Verso – A reasonably priced smart watch
- xDrip+ – Software glue
- Glance – A watch face to display the info
The system works by the Libre monitors the BG, The Miao Miao collects the data every 5 minutes, xDrip+ receives the data and manipulates it and lastly the Verso shows you whats going on. All this because there isn’t a straightforward off the shelf solution (yet).
What I want is this….
Steps
First thing to remind yourself is that this is not a medical device or set of devices. This is the equivalent of bleeding edge homebrew, short only of a step that makes the adjustments for you.
You’ll need a bit of time – A good hour or two depending on your skills
Set up the FitBit
This bit should be relatively straightforward. Download the App, sign your life away to megacorp and do the updates it prompts for. This took about 30 minutes and to be honest wasn’t smooth. The software could be a bit better but eventually it works. At the end of all this you should have a working FitBit with the default screen.
Set up the Miao Miao and xDrip+
Luckily for me there is a good guide on the Miao Miao website so as long as you can follow that you should be ok. As this stuff is a bit techie it assumes you understand what repositories are and installing apks from sources other than Google Play for example. It’s not as hard as you might think and if you struggle here’s one of few thousand tutorials.
At the end of this you should have a phone that is collecting data every 5 minutes from the Libre patch and giving you a pretty picture. An optional step would be to add a follower to xDrip+. This might be handy if like me you are a parent and you’ll effectively mirror the data on your phone as well as the kids phone. The developers have done a nice video that will show you what to do.
Next up – displaying the information on your FitBit
Again, all the hard work is done for you. Using the phone you used to install xDrip+ and connect to the FitBit and navigate to this page on a browser. There is a good wiki but there are basically two steps to this.
Change some settings in xDrip+
Changing the settings allows the xDrip+ software to send the information to the watch but it is easy. Go to settings, then InterApp settings, then xDrip Web Service. Change this to on
Add a ‘Watch Face’ to the FitBit
The wiki gives you a warning about making sure you’ve done the first step. Make sure you do this. Follow the link to ‘Latest version of Glance’. This will open up the FitBit app and after some time will install the watch face.
Some problems I found
- You need to make sure the Miao Miao is well and truly stuck to the Libre patch. Even a mm is enough for it to not connect.
- The xDrip+ software is really very capable. A slip with the fingers and a wrong setting will stop it working. For example a FitBit verso is not an Android watch. Take care when setting things up.
- This is a do it yourself system and there are a whole bunch of people that can help, but it moves from plain English to TechSpeak pretty quickly and can look daunting. It need not be like this.
Slimming down
This post builds on the RPi Zero W Cloudlog installation that I did in December with a RPi 3 that was destined to be used in the shack for something. I have long used a laptop to do most of the heavy lifting but have moved most of the clever stuff on to individual machines. The line up is growing but is a bit all over the place. I have….
- A RPi3 as a VHF SatNOGS station that runs nicely but needs a proper home (antenna ia indoors and a lash up)
- A RPi3 as a UHF SatNOGS station that is subject to loads of noise at the moment which needs a cure. It also needs a better home
- A RPi2 as a Flight Radar receiver
A spare RPi3 that was used as a media player in the lounge. Now redundant really as tech has moved on. This needed a new function. So I thought I would bring it into service as a shack server. Trouble is I have no expereince of servers and even the word makes me quiver. I tend to smile, nod politely (It’s a British thing) then retreat carefully to avoid uncomfortable conversation. Anyway it’s time to take the plunge a bit further. I have after all mastered the Cloudlog thing.
What distribution?
Normally I would run straight to Rasbian, but this time I made a detour through to DietPi. It’s a lightweight distribution that supports a few bits of software that are simple to install and configure. Perfect for the lazy, like me. The game is pretty much the same s every Raspberry Pi installation. Find a suitable SD card, burn the image to it and start the machine up. For this the recommendation is to hook up a screen and keyboard for the first bit until it’s all running then you can use SSH or whichever is your preferred method for getting into the machine once it is up and running.
Â
What software?
Well Cloudlog for a start. That needed the webserver reinstalling. Guess what? DietPi had one. check the box and that gets installed. Then it was a simple fact of getting Cloudlog reinstalled. Job done and it took a lot less time this go. (need to find a log for this).
Next up was Pi-hole. I’m ok with a bit of advertising, people have got to make a living I suppose but I feel like I’m swimming in a sea of bollocks (figuratively of course, I couldn’t really visualise this literally and don’t want too). Pi-hole claims to reduce the adverts to a more normal level and stops my browser looking like a version of the $1m dollar website (if you can remember that). Something has got to change. Installation was again more simple that you might imagine. Check the box and let the installer do its thing. As I had no idea what I was doing I used the default installation but made the error of not pointing my DNS server to the installation in my router settings. Don’t forget to do that otherwise it won’t do a thing.
There is a nice dashboard that gets filled with clever stuff. Bottom line is that there are already fewer ads on all my devices. Ace!
So what happens now?
Not much really. If you would like to have a go with a really lightweight distro for your raspberry pi (or other sbc – they support all sorts) then give it a go. The easy installation of software make a big difference for dullards like me and avoids time wasting.
I have thought about plugin in a RTL-SDR as a server but don’t really have a need at the moment. Perhaps something for the PiKon telescope now that I have got the lens. We’ll see how the thing goes. One thing I would like is a really simlpe website that does one thing on a button press, but that is a whole new game and perhaps another post.
I’m going to start planning my SOTA activations now
Cloudlog on a RPi zero w
As many will testify. I’m not that bright when it comes to clever computer stuff. I can follow instructions quite well and normally this gets me by. So I thought for December I would set myself a challenge of setting up Cloudlog (A really nice looking logging application from Peter 2M0SQL). Only I would be putting it on a Raspberry Pi zero w, without a safety net…or any knowledge of sql, php or any other such acronyms. Here’s what happened.
First things first – You need a LAMP server.
A LAMP server (Linux, Apache, MySQL, PHP) is the thing that will run Cloudlog. We’ll have the Linux part because we’re going to use the normal Raspbian Lite image for our RPI zero w. Apache is installed, as is MySQL and PHP. So first things first. This post is like a nice meal, you’ll not be having bread first, just the starter. Just don’t rush it.
Starter
Do you have a RPi zero w? – If you struggle to find one then use a nice search engine that doesn’t follow you round with a notepad checking on what you’re up to. Perhaps buy from an independent retailer or support your local Pi shop, it might cost a couple of quid extra but you can feel smug about it.
- Have you got the latest Raspibian lite image? If not download it here
- Is is burnt to a suitable micro SD card? I use Sandisk class 10 ones as they seem to be quickest and reliable enough. Try your high street. If not try and support you local Pi shop. This will be the OS ready to go.
- Have you connected to the internet using the command line? it’s pretty easy really, just use this guide.
- Have you enabled SSH on your RPI zero w? RPi headquarters can help again.
- Do you know the ip address of your RPi zero w? in the command line just type.
hostname -I.
It will spit out your ip address. For example mine is 192.168.1.113. Make a note of this you’ll need it - Have you logged into your RPi zero w using SSH? Section 4 will help you here
Main Course
So I was really comfortable with the starter. It wasn’t too heavy and just got me feeling a bit peckish for some more. This is where I was a bit uncomfortable and thought that I may have bitten off a bit more than I could chew. But it all worked out nicely in the end.
Installing the server
I followed this guide. I believe that it is de rigueur to caveat this part with some statement that ‘your mileage may vary’ or some such waffle. It might, but if this guide is wrong please shout up and I will correct it. It worked for me but it would be a lot easier if it worked for everyone. You’ll do some straightforward and not so straightforward stuff.
- Make sure everything is up to date
- Install Apache & do a bit of tidying up
- Install PHP
- Install MySQL & do a bit of detective work
- Setup FTP
Everything seems to go well until you hit part 4 where something goes a bit wonky with permissions. I spent quite a bit of time on this and found out that the permissions on the default myphpadmin account weren’t up to scratch and there is a bit of jiggery pokey to do. This should sort it.
Get yourself into MySQL and change the users
From what I could gather the default user does not have enough privileges to do anything, nor does it have access to the users tab in myphpadmin to create a new one. We have to go into MySQL and create
mysqladmin -u root password 'password'
Log in to MySQL
mysql u root
Then do the following. I think I understand, you create a new user using the GRANT command
GRANT ALL to 'username' @ 'localhost' identified by 'password';
where believe it or not the ‘username’ and ‘password’ are exactly that, but for a new user. We’ll use this later
Install Cloudlog
This bit is dead easy. The Cloudlog wiki is exactly what you need. I won’t repeat it here. So for me I downloaded the files from the GitHub page, unzipped them and then uploaded them with an FTP program (Filezilla is popular) to the /var/www folder in the RPi.
Go to your web browser and type in the url you got earlier when you did the hostname -I (Something like 192.168.1.113) only add /install at the end, so for completeness is should be
192.168.1.113/install
Up pops a dialogue. Fill in your details and you are away.
Note: I mucked about a few times when I was sorting out privileges and ended up forgetting the username and password, but the dialogue was good enough to me and I just re-entered everything and it went the second time.
You can now log in as the guest account m0abc which is notes at the bottom of the dialogue.
Dessert
There are a few things to do to get everything ship shape. Firstly delete the demo account and put in your own. Then upload an adif of your existing log (should you have one)
Delete account and create your own
Really easy Admin > Users
Create yourself and give yourself the admin rights
Delete m0abc
Done
Upload adif
So, it turns out that not all adifs are the same. The header in the example below is not to the right format
Whilst this is
Note the ‘#’ at the beginning of every line in the header. If you are going to upload an adif this needs to be checked
Sitting in a comfortable chair and snoozing
I didn’t find this nearly as daunting as it first looks. There is plenty of information on the Cloudlog wiki and to be honest the only hard bit was sorting out the permissions. You don’t need to be an expert in computering. I now have a log I can access on my Linux laptop, Tablet and phone. If I was really down with the kids it wouldn’t be hard to have it web based (I think that can be done for you by MagicBug).
I would say that you’ll probably need a couple of hours to do it but the reward is a good looking, simple to use log that is agnostic to OS.
Give it a go, if any of the instructions are wrong, can be made better or are glaringly stupid because they’ll steal your soul (or sole if you’re not looking) then let me know and we can make this post really handy.
Cheap ‘flight deck’
My LNR Precision MTR5b always comes away with me and for good reason. It’s small, portable and xyl friendly. It does however, suffer from a lot of wires and bits loosely hanging around. Mrs g7kse regularly takes the opportunity to ‘tidy’ stuff up. This means I can no longer find it. This is ok at home because it hasn’t gone far but a pain when I’m not at home.
Ikea has long been a source of cheap stuff and their chopping boards are just the thing to make into a small flight deck. The one I got is approximately 24cm by 15cm and came as a pack of two with a much larger one that is in use in the kitchen.
I thought the first thing to do would be make up a small tray that I can sit the MTR5b into and then still that to the board. Duly designed and 3d printed. Next up was a small notebook like the boys in blue use, after that some magnets for my palm key (it has a magnetic base). Lastly some velcro tape and 4 m4 nuts, bolts and washers. he optional part is a DC buck converter (just be careful to check dimensions as they change shape and size a bit) that I use to regulate the voltage to 12v (I got carried away and made a really bad case for it)
I thought I’d sink the magnets into the board at then epoxy them in. Mainly because its polypropylene and nothing sticks too well to these waxy plastics. All this took was a bit of careful dremelling and you’re done. The notebook is clipped to the board and the velcro strips stuck down onto the back. The ast ting to do was put 6 feet on it so I didn’t scratch any surface I carelessly chucked the thing on. Here’s a few photos and a link to the parts on Thingiverse.
W3EDP Antenna
My QTH isn’t great for antennas. I’ve tried a few types but haven’t managed to find one that works for me, especially on the lower bands like 40m and 80m. About 2 years ago I made up a W3EDP antenna using some left over wire and a 4:1 balun. It was noisy and worse than anything else I had kicking about. So back in the box it went.
I thought I’d give it another go as domestic planning permission has been relaxed a bit. There are a few different configurations of the antenna but they follow a similar path. A long, not particularly resonant, antenna made up of a long element and a counterpoise.
In my case I followed the ‘ladder line method‘ where the antenna and counterpoise are as a single piece of ladder line for 17ft and the remainder antenna wire is just normal wire. So it looks like the original Zepp antennas and a little bit like this
The diagram above gives an additional component to the ‘normal’ W3EDP antenna. that is an additional counterpoise. I thought I’d give this a go based on a bit of background reading I did. NC4FB explains his experiences with the normal design and I have to say I had similar experiences. Namely that the swr was quite high and it was not that easy to get it down to usable levels on any of the bands when the antenna was first played with. A good idea to try my own extra’s.
So, test gear is as follows.
Antenna connected to homemade 4:1 balun with some mini 8 coax (about 7m) hanging outside a downstairs window. Antenna raised in a V shape with the balun box at ground level and the antenna supported about 1/3 of the way down on an aluminum mast approximately 8m off the ground. The end of the antenna is resting on the fence at about 1.8m off the ground. Hardly ideal but good for enough for a lash up.
I used a MR100 Antenna analyser. These are cheap and good for indicative measurements. There is also some good free software available to use with you Linux PC (There are probably windows varieties but I didn’t look).
I did 4 tests. Vanilla, i.e. no extra counterpoise. A 32ft counterpoise, A 16ft counterpoise & lastly an 8ft counterpoise. The outputs are below.
So what does this tell us?
Actually that there is a good argument on the face of it to add in an additional counterpoise. The 32ft one has a greater effect on the lower bands and the short on the higher bands. Nothing too contentious here then. So what happens if you connect them all up together.
It does lower the swr but that is probably not the only effect. I think this might need some extra experimentation or at least a bit more digging to see how to improve the antenna for my qth. But for now I’ll sort the lash up out and give it some on air testing.
All keyers are not equal
iCW is a system of CW using the internet. I’ve mentioned it before so won’t go into the edtail here, but, I like it and I’m sure others won’t, probably because it uses no RF. My counter to that is Morse didn’t always use RF so what’s the deal? Regardless of your feeling it is easy nowadays to pay little attention to tone as modern rigs have a user definable tone and they are generally a well formed sine wave. This, as I found out, isn’t the case when using external keyers.
I bought a K16 keyer kit from Kanga Kits for next to nothing in today’s terms with the anticipation of connecting it to iCW through the internal soundcard. perhaps using the computer as a kind of filter to keep some of the rough edges away. What resulted in iCW was the ‘sound of sanitation’ as we dubbed it. Basically it is a brilliant keyer and I’d recommend it to anyone but sounded like $hit when on its own. It probably isn’t meant to be used like that though so don’t pay too much attention to that.
Next up was a filter using the Sotabeams DSP audio filter, let’s not assume that I am using this as its intended purpose but there could be some mileage in having a play and seeing what happed. There was an improvement but not as much as the audio output from a rig. So to continue the sewage based analogy the attempt at polishing the turd succeeded only in rolling it in glitter.
Last up was the more elegant solution. A handy filter called the Hi-Per Mite. For the lazy it makes the squarish wave that comes out to the K16 a little more sine like. For the intrigued a greater explanation is available at the place where you can buy these, the 4 States QRP Club.
The audio samples and graphs go to show that with a relatively small interaction a filter is all you need to prevent your calls be ignored for any number of reasons except for perfect tone. I would be pleased if the two components could be easily integrated as not only an exceptionally competent keyer but also practice oscillator.
Zoiks!
I wasn’t ure what I was seeing here. Apart from the fact that the tone is enough to make you want to turn it off!
Ah thats better…Just one signal and pleasureable to listen to as well
So, what have I learnt this time?
The K16 Keyer is excellent but needs some help to make it sound nice. The Hi-Per Mite filter is just the companion it needs.
Indication versus measurement
The nature of a technical hobby gives way to the ‘buying of stuff’. Sometimes this is the tool required to carry out the crux of the hobby, in our case I’m referring to the transceiver. Sometimes this is the tool required to check that the main tool is working correctly, in our case this could any number of tools such as an antenna analyser.
There are also many hams that like to buy the box, or series of boxes and do the minimal amount of testing to ensure safe operation and there are those that will only operate what they have built themselves. Most of us fit on that spectrum. I certainly do, it just varies on what I’m doing.
For longer than I care to admit I have used an antenna analyser that belongs to my local club. It is free to be loaned but I’ve used it more than my fair share of times. I also like to build the odd antenna. This means I measure the length and then cut the wire and check it’s various characteristics and generally cut it again until I’m happy that I have a suitable compromise. Its a really useful tool. I assume its quite accurate because it cost a lot. But do I really need it?
Separating needs from wants is not that easy, partly because what starts out as a want can quite easily become a need. I made a decision recently, I was going to buy my own analyser. But which one? Que the usual looking through specs and performance criteria, guess what happened next. I started with a small requirement for a HF analyser and ended up looking long and hard at analyser >£300. Reflecting on this it becomes easy to bump up the needs because I never really noted down what I actually wanted.
So what did I actually need? In this case I wanted to ensure that I wasn’t going to damage a transceiver and transmit spurious rubbish (as opposed to my usual cw rubbish). So I didn’t really need a tool to measure, I needed a tool to indicate. But ah ha, I still needed to cut the antenna to the right length, so I did need something to measure but did it need to be really accurate?
It turns out it didn’t. It’ll be a good idea to get a rough idea but to 3 decimal places? nope, it just isn’t that important. So I duly purchased a cheapo SARK analyser off ebay for around £30 and it’s allowed me to measure and get the right length(s) (I built a multiband end fed antenna this time) and use a cheapo end fed tuner and the analyser to get the correct swr and impedance for safe and fairly optimised operation.
The lesson learned is that if I don’t set out the requirements first then I’m going to end up spending 10 times on a product that I probably don’t need.