Category Archives: DietPi

Virtual Pi

Every time I screw up badly, I end up having to go through to the house, swap SDs on the Raspberry Pi and start another backup. AND I’m told by our friend from Raspbian that I should not be doing this as live backups are asking for problems. Now, to be fair I’ve never HAD A problem with the Raspberry Pi SD copy program but that’s not to say I won’t – and of course none of the other Pi-like machines I own have such a simple backup facility (don’t go giving me a lecture on complex Linux backups please).

tmpD42CAnd so it was that one of our readers (MrShark) put me onto a VPS (virtual Private Server) facility this week – for less than £3 a month you can have your own virtual Debian. I took this up for a trial as I’d had immense difficulty in the past with Virtual PC etc. on my computer due to making the mistake of installing Docker.  So I’ve been playing over the weekend with this VPS service called OVH. Now, their service works really, really well - but the customer service is virtually non-existent as far as I can tell.  It was with that in mind that I grabbed some coffee today and sat down to clean up my Windows 10 PC and install VirtualBox.

I followed the instructions and downloaded a virgin Debian – expecting the same kind of experience that I got out of OVH or one of my little SBCs (I should say at this point that my script – which installs the kitchen sink – works absolutely perfectly on OVH).  Up came a fully-laden Debian complete with graphical desktop and all the trimmings… I went into a terminal and the first thing that came to mind was “sudo apt-get update”.  Well, that’s what you do, isn’t it.

Nope. No “sudo” – never heard of it, mate. This came as something of a shock. Anyway turns out it wasn’t installed, I sorted that and did an update. After a file edit to stop it looking for repositories on a DVD that the VM doesn’t have – I was away with a full update and upgrade. Dare I try my script.

tmpE86DWell, that failed at the first hurdle – virtually every one of the general pre-requisites and utilities I normally install failed miserably. So much for Linux not having the version issues Windows (supposedly) does! Debian isn’t even the same as Debian!

It was at that point of utter despair that my pal Jonathan called in on Skype as if sensing I was getting annoyed. No – you don’t want to do it like that, he said,  there’s a ready-built DIETPI image for VirtualBox.

And so there was.

I grabbed the image from the DIETPI website, loaded it in, created a PI user (I’ve a short script for that, too)  and loaded up my script. NOT A SINGLE ERROR – it’s not even this clean on a proper PI !!! Mosquito, Node-Red, my start-up page, MQTT, SQLITE – it’s all there!!

I’ve done a backup of the basic Debian and a backup of Debian plus all my tools and toys – and now I’m ready to take on the world. For those who don’t know, VirtualBox, DietPi and my script are all available on the web and all available for free. What a great way to test stuff out, now I can make changes to the script fearlessly (my ain is to make it a lot “cleaner” – without all the messages you can’t do anything about), safe in the knowledge that if the whole thing explodes, I’m a button-push away from starting again and it’s all a LOT faster than a PI on my Windows 10 machine (which was super fast about 4 years ago).

Can’t QUITE see how to get the USB emulation going so I can mess with SDs, but no doubt someone reading in here will have figured that out. If you do try out my script – make sure you tell it that this is NOT a real Pi – and don’t try adding GPIO….

DietPi on VirtualBox

Facebooktwittergoogle_pluspinterestlinkedin

Another Weekend of Experiments

I’ve just been up to Northern Spain with a friend and our wives looking at some property up there  and when we got to our hotel and got the wine open, Aidan showed me his new toy – Amazon Echo.

The Echo Moment

EchoWell, I was so excited I’ve ordered the new Dot which should turn up next week – after all my failed experiments with Google Now and Microsoft’s  Cortana trying to fire text at Node-Red so I could control things, this might just do the job – but that is something for next week.

FabriqOf course – you could always hang around and wait for the forthcoming  fluffy version called FABRIQ – which appears to be rechargeable – but no mention of microphone arrays so you take pot luck on how good the audio capture is. You could even take the kit route with Seeed’s ReSpeaker – but by the time you add up the cost of ReSpeaker and the microphone array… well, I’m wondering if they’ve lost the plot. They sent me a ReSpeaker to play with minus the microphones – I nearly choked when I saw the additional cost. If you have an Amazon account you can play with Alexa here.

I’ve not had a lot of luck with the Raspberry Pi versions, one only works in the USA, others are out of date and require button presses… anyway I’ve ordered a USA mic any my DOT turns up next week so maybe in a couple of weeks this will start to fly at this end.

We came back to the cave on Friday and yesterday  my friend Jonathan rang me up full of new stuff he’s been playing with.

Glasswire and Divvy

So first things first – for Windows enthusiasts – check out GLASSWIRE. I have it sitting here making pretty graphs of my network – I’m not saying it is any good – I’m saying it is extremely pretty and possibly deserves a corner of your desktop. Something else you might like to play with is DIVVY from MIZAGE. I’ll leave you to look those up. I found them interesting.

Meanwhile as some of you know I’ve been experimenting with Armbian on my little Nanopi NEO. Lovely operating system and I managed to get my script working on it no problem – but for one thing – WIFI  - the NEO doesn’t have WIFI and so you have to stick one of those cheap Chinese WIFI dongles in – and on most of the SBC boards I’ve tried – no problem. However after jumping through some hoops to get the WIFI working on this little Neo board – I was very disappointed – WIFI performance was so poor you could see delays when doing the likes of apt-get update etc. I wrote off to the Armbian forum and the response was along the lines of “you should try an Orange Pi Lite if you want WIFI” – well that’s all very nice but I already have two NEOs.

Well, I was sitting getting depressed  about this when my friend Jonathan rang me up with some new things to try.

WinDiskManager and Etcher

EtcherSo first things first – you know that Win32DiskImager that everyone uses to FLASH Linux SDs – he’s spotted something not only a little faster but a little nicer looking called Etcher – so the first useful takeaway from this blog entry is Etcher. I installed it on my Windows 10 64-bit system no problem – none of your “administrator-only” stuff – and Etcher works  - point it to an image file – and it flashes it to SD!! Mind you that’s ALL it does.  If you need to READ images onto your PC you still need Win32DiskManager.

The DietPi Moment

He then reminded me that before I was playing with Armbian I’d had a go at DietPi for the Raspberry Pi.  It only worked on the Pi itself -  it was a nice, lean installation of Debian – but hey – the normal Pi setup was fine – so I put Diet-Pi to one side.

WELL – take a look at DietPi today – it is no longer for the Pi only – and it can install lots of goodies – kind of complimentary to my script (with a nicer interface).  And in the process of this conversation I noted it has a setup for the NEO and other FriendlyArm boards.

NanoPi NEO using DietPiWell, wouldn’t you know it – there’s a menu driven setup for WIFI – and it WORKS!!! And the funny thing is – the designer credits Armbian – WELL!!  Ok, so there’s a LOT more to this and I’m only at the beginning – I noted that this Diet-Pi on the NEO seems to run even faster than the hardwired version on Armbian – and I’m only at the surface of finding out why – but one reason it seems nippy is you have full control over logging – which by default is running in RAM and at a minimal – a very sensible starting point. 

In the process of setting things up I discovered some sillies in my script (which takes a basic Debian setup and installs a while raft of useful goodies centred around Node-Red) and I’ve fixed those.

I have now run my updated script on DietPi on the NEO and M2 and up to now everything seems to work  – and it’s a small installation for a small board – and nippy… I need to go way more deeply into this –  there is SO much in Diet-Pi now but I’ve no idea how much of it actually works – I DO know that not everything works on all boards but as I’ve only installed this on the FriendlyArm M2 and NEO I’ll keep my mouth shut except to say I’m mildly enthusiastic – my little NEOs are now useful wireless devices – which is a great step forward.

Node-Red on NEO

Experiments above with Node-Red, MQTT and serial – all working.  And below – with a simple mod – a nice colour terminal… all on my NEO soon to be replicated on M2 and T2.

Terminal

Now there DO seem to be some issues with DietPi – I’ve reported them – on a real Pi the serial port needs permissions altering to work (added to script just for belt and braces) – and on all installations, Mosquitto fails to run at power up – MAYBE starting too early I don’t know but taking a line out of the RESTART bit of the start-up script and putting it in /etc/rc.local does the job. 

Up to now everything seems ok and I’m working with MrShark  to looking toward the lightweight LIGHTTPD..  we’ve already improved my script – and you know how it goes – once someone triggers you off…

More of that soon – for now – I have my script (as of today) running (with the caveats above) on a Pi2, M2, NEO and BananaPiM2 – and that’s only due to restricted time… DietPi has the advantage of making a MUCH smaller footprint at under 2GB compared to nearly twice that on, say a standard Pi – as there is only in there what’s needed.

Oh while I think on, here’s the link to my original Neo article.

Expect to hear more about this in the coming week – I’m off now travelling with my wife and 3 cats ALL the way up Spain – 24 hour ferry – ALL the way up England… you won’t hear anything from me in here as I’ve not mastered blogging on a phone Smile

.By now Aidan has his Alexa turning his lights on and off via Node-Red and so that will be the next job – integrating this whole lot together.

Facebooktwittergoogle_pluspinterestlinkedin

DietPi

tmp8CB3Those of you who have been here for a while will recall my rants about the Orange Pi PC, a Rasperry Pi lookalike that costs around £12 if you get it from China (Aliexpress etc).

Indeed some of you have one of these and will no doubt have shared my horrors as I discovered that this neat piece of hardware which IS faster than the Raspberry Pi 2 (not the old B, the version 2).. but which ended up in a drawer as the software and support is ABSOLUTE RUBBISH.

Well, today my pal Jonathan got in touch to tell me about DietPi. I’m not going to say too much more but just give you the link.

The software is available for Raspberry Pi, Orange Pi PC and more.  

Before you go off… I suggest trying this out on a spare as I have yet to put this through rigorous testing -  I’ve not even fitted it up with Node-Red yet… but it’s the most satisfying start I’ve had so far with the Orange Pi – which may yet prove to be a winner.

Here’s the link. http://dietpi.com/

Check out the installation options, the backup options and more – I don’t know how good this is going to be but to be sure – it is POLISHED!

I should point out however that I’ve used this now with the Orange Pi Pc… and i can get no analog sound, no SerialPort for Node-Red – so it may be that there is more style than substance here – time will tell – I’ve put in a support call.

Facebooktwittergoogle_pluspinterestlinkedin