Ifor Darby-Hoskin.

About me, what I do and what I am interested in.

Server monitor using a Raspberry PI and Python.

My simple solution to monitor servers.

A friend of mine (yes I do have some) is the admin for a company that have a server room with lots of servers :-

  • Windows file servers.
  • Windows mail server running exchange.
  • Linux server running their web sites.
  • The list goes on………..

My solution to monitor these and report any problems was to use a Raspberry PI and a SMS module bought from Ebay, the PI also has a temperature and humidity sensor and runs a small internal web site.

A python script runs every minute and performs the following :

  • Pings each servers network card.
  • Attempts to connect to any special ports (SMTP, HTTP, HTTPS).
  • Web scrapes several sites to check that they are up.
  • Records the Temperature and humidity.

If there are any errors the PI attempts to email all the admins and me it will also send a SMS message to the admin users with a brief message.

Every day the PI Emails the admins with a basic report and a link the the data log.

Its has been running for 3 weeks now without any problems and has already detected several errors that normally would have gone unnoticed.

python-logo Raspberrypi

Microsoft C# Audio Project

I have just started a project using C# to record audio from USB sound dongles on a Windows 7 OS. This project needs to be Coded in C#. Lately most of my projects have been coded using VB.NET and it is a a nice change to return to a familiar syntax ( { } ; )

C# has a lot more native support for audio recording and playback so I don’t need to use any third party libs.

The point of the code is to record in 1 minute segments the audio output from several marine VHF radios these will be stored in a separate folder for playback. The date, time and description (Audio source) will be appended to the file name, when the recordings are played back via the playback software (That I still have to code) the user will be able to playback the audio by selecting a date and time range. The system will look after its own disk space so that it will not fill up the hard disk.

This software will be used mainly by clients who need to monitor and record audio from multiple VHF receivers that are monitoring marine traffic.

AMI Marine VHF recorder

The VHF recorder that I developed and tested is ready for the market.

The VR973 VHF recorder has been designed to operate on vessels not fitted with an (S) VDR system. It provides a cost effective means of recording VHF communications and position at any given time. The recorded audio can be played back on any that supports AVIfile format without the need for special software. Connection to the GPS allows location, date and time to be recorded and displayed.

The VR973 Recorder is connected directly to the VHF – if a suitable output is available. A KW973 VHF interface may be used to combine separate transmitted and received audio signals through the VHF recorder.

With ease of use in mind the VR973 is simple to operate, with very little user interaction.

The audio and data can be saved onto the supplied 16GB SD card which can be accessed by any devices that supports AVI files and a fitted with a suitable card reader. Standard AVI format files are created in one minute segments, which make finding the required time period very simple.

During audio playback the GPS information is displayed on screen, along with the system’s unique serial number, to easily identify the vessel.

VHF Recorder VR973







VR973 VHF recorder



Replay Software for Ami Marine Voyage Data Recorder

I have just finished the first version of the replay software for the new AMI Marine Ltd voyage data recorder (VDR). This is needed to allow the clients to view the data recorded on board the vessel.

The replay software allows the client to replay all the recorded data back in real time this includes up to 10 audio recordings, 6 RADAR image captures, 2 ECDIS image captures and NMEA data from various devices located on the ship.

The software will have to past type approval next week and more than likely will need some features added in the future.

Anyway onto the next project.

Windows Terminal Services API

I stumbled across cassia .NET library for Windows Terminal Services. It works with C# and VB.NET, with it you can :

  • Enumerating terminal sessions and reporting session information including connection state, user name, client name, client display details, client-reported IP address, and client build number (WTSEnumerateSessions, WTSQuerySessionInformation, and friends)
  • Logging off a session (WTSLogoffSession)
  • Disconnecting a session (WTSDisconnectSession)
  • Displaying a message box in a session and getting a response from the user (WTSSendMessage)
  • Enumerating all processes (WTSEnumerateProcesses)
  • Killing a process (WTSTerminateProcess)
  • Shutting down or rebooting the server (WTSShutdownSystem)


BBC News – A skin printer and bee health-checker win Dyson awards

A sun-powered cooker, a printer that 3D prints “skin”, a wheelchair that lets disabled people stand upright and a bee prober are among the latest winners of the James Dyson Awards.

The inventions are among those picked to represent various nations in the engineering prize.

Their makers were challenged to “design something that solves a problem”.

BBC News – A skin printer and bee health-checker win Dyson awards.

‘zombie’ spacecraft

It’s alive! 36-year-old ‘zombie’ spacecraft rescued from the abyss fires thrusters for the first time in 20 years.

Virginia-based amateur group successfully fired thrusters on ‘dead’ probe.
The spacecraft will now be moved to fly past the moon on 10 August.
In May the crowd-funded ISEE-3 Reboot Project ‘talked’ with the spacecraft.
But it has now also proved the thrusters work so it can be used for science.
This is the first time Nasa has given control of one of its craft to the public.
ISEE-3 first launched in 1978 but has not been heard from since 1999.
Reviving the mission could help scientists better understand solar winds which can affect satellites and the climate on Earth.

Read more: http://www.dailymail.co.uk/sciencetech/article-2684345/Zombie-spacecraft-rescued-abyss-fires-thrusters-time-20-years.html#ixzz36scD3vWM

Its Only Software :(

You have got to love it when a customer asks for a big change to a project and after you tell them how long its going to take they comment that you have already been working on the project for months and you should know what you are doing by now !!!!

I do know what I am doing but you don’t and the fact is you didn’t even complete a spec of the job before you employed a programmer and also why now you need to completely change the way it works because you didn’t understand the problem in the first place!!!!!!!!!!!!!!!!

But after all, its only software…………………..