20140615

Do you see too?

Here's another gripe about the 'C' programming language or at least Microchip's C18 implementation of it. Oh, and by the way, here's another programmer's take on the subject.

Here a quote from the C18 user guide:

2.7.1 Integer Promotions
ISO mandates that all arithmetic be performed at int precision or greater. By default, MPLAB C18 will perform arithmetic at the size of the largest operand, even if both operands are smaller than an int. The ISO mandated behavior can be instated via the -Oi command-line option.

When coding for an 8-bit microprocessor one tends to use 8-bit (byte) variables wherever possible as these are native to the processor.  If you are coding in C18 you are likely to be using one of the PIC18 range of processors and these, we know, have a hardware 8-bit by 8-bit multiplier giving a 16-bit result in one machine cycle.

unsigned char a, b;
unsigned short int c;
a = 100;
b = 200;
c = a * b;

How crazy is it, then, that the above code in C18 will yield 'c' = 32!  the last line will of course use the hardware multiplier and then will throw away the upper byte of the result before expanding the answer to 16-bits by adding a zero upper byte and placing it in variable 'c'.

Worse still is

#define factor 31
unsigned char a;
a = ((factor * 60) / 100);

Here the intention is to give variable 'a' the value 60% of that of constant 'factor'. The constant expression to the right of the equals sign is, of course, evaluated at compilation time so that the run-time code sees simply 'a' being set to a constant.  In assembler I am used such expressions being evaluated without loss of precision until the answer is placed into 'a' and raising a warning if it is too big. But in C18 the expression is evaluated in byte precision and yielding 'a' = 0. To stop this happening one can use:

a = ((factor * 60ul) / 100ul);
to force the evaluation to use unsigned long (32-bit) precision, but this is hardly intuitive.  I would not have so much minded had C18 deigned to raise a warning but, no, it blithely continues in its legalistic, archaic and ridiculous way...

The reason for using 'C' for embedded processors is to increase productivity and yet produce tight, efficient code. The above example shows how 'C' fails to do this as, I think, the only way to force the compiler to do the obvious is to insert assembler code.

20140609

Oldtown Naas

Today I discovered Oldtown for the first time in almost 30 years of living here - I had a few minutes to myself in Naas so went to my favourite haunt along the canal. I found a wee path and went exploring and found myself standing at a gate looking into the gardens of Oldtown House. Such beauty so close to the centre of the town!

The wee path to the gates

Oldtown gardens from the gates
I regret the only camera I had with me was a smart phone with a scratched lens, so my pictures are rather fuzzy. So I did a bit of research and found a comprehensive video:


This link gives some history from which I quote:

"In 1696 Thomas Burgh acquired a property outside Naas called Oldtown. The site lay near a holy well where St Patrick reputedly baptised Oillill and Illann, the sons of King Dunlang of Leinster. In 1709, he designed and oversaw the construction of a new house at Oldtown, one of Ireland's first Palladian winged houses. The building comprised of a two storey central block flanked by two storey wings. The centre block was adorned with pairs of Ionic pilasters, rising to just beneath the windows of the first floor. The wings were likewise adorned with Ionic pilasters, all of which carried substantial entablatures. Thomas's masterpiece was to remain the pride of his descendants until the centre block was destroyed by fire in the 1950s and the family moved into one of the wings."

North-east perimeter


Google-maps - I was at top left

20140608

Clive Drive


Clive Sinclair's ZX Spectrum home computer

Many years ago I started Microlite by designing an external disk drive interface for the ZX Spectrum. The Spectrum was one of the first home gaming computers in the UK. The firm I was working for had a bunch of Quick-Disk drives gathering dust so hired me to design the interface.

Quick-Disk

The Quick-Disk comprises a 2.8" floppy platter with a single spiral track rather like a record. To access data the drive traverses the whole track (48K-bytes) and this takes 8 seconds. You can turn the disk over to avail of a second 48K-bytes worth. The drive included a read/write head amplifier but no other processing.

The interface hardware was novel in that it used simple logic (TTL gates and registers) and the processing power of the Spectrum's Z80 microprocessor to decode or encode the drive data on the fly.

And then there was the necessary software. It was necessary to reverse engineer the Spectrum's operating system in order to integrate the disk drive and provide the necessary new commands to operate it.  All this was done on a 80286 desktop running MSDOS - long before Windows or the internet. My best companion during this period of sheer hard graft was Dickens' Spectrum Advanced User Guide.

My best companion

Thus I wrote a disk operating system or DOS. Others have made millions by so doing - I can't remember what I charged but it certainly did not make me rich, but it did kick-start my business and so I am eternally grateful to Clive, and to John my client, for the opportunity they gave me.

The final Clive Drive was technically a success.  A mere 8 seconds to load a game was much better than many minutes with a cassette recorder and the interface supported hacking via the "Keymaster" button. But regrettably the product was not well advertised and was launched towards the end of the Spectrum's lifetime, so I doubt if my client ever recouped his costs.

Surprisingly the world still remembers the Clive Drive - so it wasn't all a dream after all!  I found this picture and a couple of links here and here on the internet. The red button is the "Keymaster" button.

The Clive Drive interface and disk drive

For those interested here are some photographs of circuit schematics and operating instructions which, I regret, I no longer have in digital format. Click on a picture to enlarge it.

First page of Clive Drive operating instructions

Schematic page 1
Schematic page 2 -
the disk drive connector is at the bottom
with RDDT being the raw serial data
from the read head, and WRDT the
serial data to the write head.

"Peek-Poker" used the Keymaster button
to freeze a game and offer various
debugging / hacking commands.

Do you see?

In addition to assembler I use the ANSI-C under the MPLAB programming environment for writing code for embedded microprocessors in my work. Whilst 'C' enables me to write code more quickly and is more maintainable than assembler, I contend that the claim that 'C' makes code that is almost as tight and efficient as assembler false. I contend that the 'C' language is unnecessarily convoluted and far from elegant.

For example in an recent project I used the PIC18F67K22, a 8-bitter with a massive 128K of code memory, for a reasonably simple task. In assembler I would have expected my code to fit into less than 32K of memory, but for this project I used 'C' and it filled up about 80K of code.

'C' header files can be hard to find because their path is often implicit, hidden in the compiler configuration. I say that the that MPLAB ought to provide a more intuitive way to find header files.

The 'C' "#define" and user type definition statements are very powerful but lends themselves to hopelessly nested definitions, and an attempt to find out what a label actually means can lead to a long rabbit trail through multiple source and header files that can end in the compiler's own source files. There ought to be a way to display this rabbit trail as a list rather than have to follow it.

I contend that variables in 'C' are too "strongly typed". This often results in the need to prefix a variable passed to an inbuilt function with a non-intuitive cast to stop the compiler generating an error. Which detracts from the whole point of casting and implies another contention - casting is a way to change a variable from one type to another but it is not always clear what information is lost is so doing.  Here is an example from my code: to simplify the main code I have defined a new type "PGMCHAR" and used this rather than the original "const rom char far" to cast a literal string in order to satisfy the use of the inbuilt function "strcpypgm2ram":

typedef const rom char far  PGMCHAR;
strcpypgm2ram(wbuffer, (PGMCHAR*) "Hello world");

Which in any decent sort of language this would read:
wbuffer = "Hello worldd";

I contend that a language like 'C' which claims to give low-level access ought to allow the programmer to do anything that is safe. And yet 'C' does nothing to stop you corrupting memory outside your remit, but does many things to restrict your freedom such as insisting that strings are signed and have to be terminated by a zero. Thus making it impossible to have a string with zero in it, and difficult to use the upper 128 character codes.

IMHO a programming language ought to be intuitive, as close to assembler as is reasonable and with a plethora of simply styled functions and constructs. I have often mused about writing such a language. But it would never be adopted because there is a professional pride thing that makes programmers adhere to 'C' and its many derivatives.

20140606

70 years since

D-day landing

It is 70 years since the Allied invasion of Normandy in WWII, otherwise known as D-day. I was born in the aftermath of WWII and my only memories were reverence for and shortage of food - bread scraped with butter with the faintest suggestion of fish paste, reverence for tinned "fruit salad" in having to "dilute" it by eating it with bread and butter, special orange juice provided for infants to boost vitamin intake. My father had been based somewhere in North Africa, but he never spoke to us children about the war. I find the subject immensely emotional and it makes me proud to have been "on the right side" even though I now know more about the atrocities that Britain has committed in other departments. Talk to the Irish...

On this anniversary the news is full of the subject but this one particularly took my attention. I honour and applaud the courage in those soldiers and their readiness to die so that I might be free.

20140604

56K


A 56K-ohm 5% resistor

Wire ended resistors, as used in electronics, are generally colour-coded with their resistance value. The value shown has always been my favourite with its green, blue, orange and gold bands.  You figure the resistance value using the table below in which the colours are arranged in rainbow order with a little license either end.


I have never understood folk that need a mnemonic to remember the rainbow colour - Richard of York, etc. Anyone who has messed with mixing colour will surely know the order.

Why give a lesson in colour codes? Because it is another example of my love for colour. I seriously think that the fact that resistors have colour bands was majorly contributory to my earliest interest in electronics.  That together with "small is beautiful" - hence the name I trade under "MICROLITE".

Whilst on the subject what other trade is there that deals in such a range of material sizes?  Resistors are commonly available and commonly used in values from 0.001 to 10,000,000 Ohms. Capacitors are commonly available and used in values covering an even wider range from 0.000,000,000,0005 to 100 Farad. I maintain a stock of thousands of values within these ranges, not to mention inductors and semiconductors.

Whereas in my son-in-law's wood shop his smallest timber dimension might be say 0.001m (1mm) and the largest dimension might be 10m, a range that is hardly comparable!


20140602

Song of Albion 2

My title is from Stephen Lawhead's trilogy - chosen because his concept echoes some of my own thoughts. I started this study on music following negative comments I have heard in our church about certain genres of music. I wanted a better understanding concerning music. I quickly realised how little I know about the subject and therefore how unqualified I am to judge. But the study was fun and I use these posts to summarise some of my findings. But first, here are my conclusions:

  • Music has hidden power that can touch not only your emotions but also your spirit / innermost being - see here
  • Nothing is unclean of itself - it is your involvement with it that may or may not be good, see Act 11:7-9 and Rom 14:14
  • Whilst I do well to check out how music affects me, I have no right to be judgmental regarding your views, see Rom 14:4-5
  • My duty not to offend others should affect what I do with music, see Rom 14:3 and Mat 22:36-40
If you do not like my conclusions maybe you should read no further - but I would be interested to hear what you think so do please consider leaving a comment.


What is music?

You'll find plenty of and disparate definitions but here is mine: "music is an ordered sequence of sounds that generally include notes. A note is one of an ordered set of tones (a 'scale'). A tone is a sound having musical pitch." A bit convoluted but then I am an engineer.

Music thus is ordered in both in time sequence and in choice of sounds. This order is what distinguishes it from noise. As a reaction against this status quo some exploratory avant garde musicians have tried to remove all semblance of order from their music, like John Cage in his 4'33" - three movements of silence...


and his Imaginary Landscape no.4. which uses random noise from transistor radios...


One has to try a bit harder to define music in such as way as to include these examples!

If you were able to travel back in time to the middle ages or before you would find very different music. Likewise the music of the orient with its quarter-tones might sound alien to western ears. Even in my lifetime church music has changed radically. And then there are all those musical genres to suit different tastes. I would be wary indeed to pounce of one such flavour and pronounce it diabolic without very good cause.

Notwithstanding there is "music" that I personally find objectionable, music that I find very appealing but something within me warns me not to allow myself to become immersed in it - maybe this is my upbringing, maybe not. Anyway I do not see why I or anyone else should not have personal choice in music any less than in colour or food.

Go to previous page
Go to next page

20140601

My favourite colour is yellow

I may have mentioned before that my "official" favourite colour is yellow. I say "official" because yellow is the colour I chose to be my favourite when I was at that tender age at which grown ups insist that a child must have one. In fact I love all colours, especially intense or spectral colours.

A computer screen's attempt at a spectrum
A computer screen, digital or conventional camera cannot do justice to spectral colours because they are outside the colour triangle that encloses those colours that can be obtained by mixing red, green and blue. The following diagram from Wikipedia suggests that there are rather a lot of colours that our attempts to reproduce colour cannot display. Sad, because theses missing ones are amongst my favourites.

The RGB color triangle shown as a subset of x,y space based on CIE 1931 colorimetry

Mind you, the human eye is also subject to a similar limitation because it, too, has only a limited repertoire of colour receptors (called "cones"). It is generally thought that there are three types of receptors and they are sensitive to, of course, red, green and blue, with a second peak towards the UV end for the red receptors so that we can perceive violet in the spectrum. So I am not sure what this does to my missing colours argument. Just that if you look back into a prism splitting a collimated (focused) beam of white light, and move your eye along the spectrum so caused, the colours are so, so good, so much more intense that that on a screen or photograph.

Why all this theory? - because I am intrigued with colour.  Indeed when I left the beeb the only material I took away with me was their introductory course notes on colour - which I still have - somewhere.

Anyway - back to the subject of "my favourite colour is yellow".  There is, of course, yellow and yellow.  As a general rule I find that man made things that are yellow (e.g. cars, home decor, clothes) are not the right kind, indeed they often make me want to puke.

You can also see "good" and "bad" instances of colours in creation. A friend of mine, Steve Fouse, wrote a song about this:

In the beginning God said,
"Let there be light"
And in that light
He made many colours,
Each one was separate
And called by a name,
Given a nature in Him
The same.

We are colours
From the inside out.
It's God's nature within us
And it's working its way out.
We are colours
From the inside out.
It's God's nature 
Working its way out.

God, He saw that it was good.
Satan, he never understood.
And those under his spell,
They don't see so well,
They don't see the colours
As they should.

Green can be envy 
Or God's new life.
Blue can be self-pity
Or His authority.
Yellow is a coward
Or God's nature perfect and true.
Red is anger 
Or His blood cleansing you.

If you check out "yellow" in the Bible (KJV) you will find references only to it being a telltale sign of plague (leprosy?) in the law of Moses. But there are plenty of references to gold, the "good" yellow of the Bible, and gold represents the nature of God himself.  You could hardly imagine more opposite extremes. Gold - both the metal and that glorious glow we sometimes see in sunsets, although not a spectral yellow, will qualify as an OK favourite colour for me. Contrariwise the sort of drab and dirty yellow that one imagines is the telltale for plague, or the various yellows used to paint cars and or home decor, are as different as chalk from cheese.

Today I cycled 42.5 miles (max. speed 38.8mph, average 12.0mph and lots of hills in case you wanted to know) along country lanes here in County Wicklow. It was sunny and the hedgerows are full of wild flowers, with red campion and buttercups prevailing. And there is so much May blossom this year - it always reminds me of my father whose birthday was in May. But the buttercups in the sunlight along the way - little flashes of bright, intense colour against the darker green background - an extravagant riot of colour.

Buttercup yellow, I have decided, is my favourite colour.

20140531

Song of Albion

"Before the sun and moon and stars were set in their unchanging courses, before living creatures drew breath, from before the beginning of all that is or will be, the Song of Albion was sung. The Song upholds this worlds-realm, and by it all that exists is sustained."

This concept, that music is somehow at the heart of, is somehow responsible for all that exists, is the subject of many articles. For example Rubino, reminding me of Douglas Adams' 42, claims that:


Ray Tomes asserts that "The universe, believe it or not, is nothing other than a giant musical instrument with a very special but predictable pattern of harmonically related oscillations which determine the structure of everything from galactic clusters to subatomic particles...The universe consists of a wave which develops harmonics and each of these waves does the same."

The concept is also suggested, though perhaps not explicitly, in the Bible in passages like:

Where were you, Job, when I laid the foundations of the earth? Tell if you have understanding! Who has set its measurements, for you know? Or who has stretched the line on it? On what are its bases sunk, or who cast its cornerstone, when the morning stars sang together and all the sons of God shouted for joy? (Job 38:4-7)

Long ago, at many times and in many ways, God spoke to our fathers by the prophets, but in these last days he has spoken to us by his Son, whom he appointed the heir of all things, through whom also he created the world. He is the radiance of the glory of God and the exact imprint of his nature, and he upholds the universe by the word of his power. (Heb 1:1-3)

The ability to appreciate and to make music seems to be core in human experience through the ages. The fact that it serves no obvious Darwinian advantage suggests that it might have a higher source. Passages in Ezekiel and Isaiah suggest that Lucifer, otherwise Satan or the devil, was once the angel presiding over music in the heavens so it is hardly surprising that "the devil has all the best tunes".

Thus sets the scene for music (in its broadest sense) as the or at least a language of God, as inextricably entwined in His creation, but perverted by the fallen angel Lucifer.

I intend that this will be the first of a series of posts on the 'Song of Albion' aka "the extraordinary spiritual power of music".

20140527

Dyslexia

Perhaps I have a twinge of numerical dyslexia. In my work I order stuff online from Farnell who use six or seven digit order codes. I can think I have committed such a code to short-term memory then type it into my order and find I have the digits in the wrong order. Often I know I am writing it wrong, but cannot be sure what the right way is. This happens so frequently that generally I have resorted to writing down even the simplest of codes. It is the same with telephone numbers.


SOT23-5 semiconductor package
Microchip make amplifier chips and specialise in lower power rail-to-rail input and output types, and these I find useful in my work. Recently I chose the MCP6401 in SOT23-5 package from the many to choose from.  So I ended up ordering the MCP6041 by mistake, and after re-ordering got mixed up between the MCP6401 and MCP6041R.



Whilst similar there are enough differences between MCP6401 and MCP6041 to matter, and you can see that MCP6401R has a different pin-out. So I decided to purge my stocks and only keep the MCP6041R for which I have a symbol in my PCB-CAD software. In the design I am currently working on I used this symbol only to find I had mixed up the two pins VIN+ and VIN-.  Duhhh...

My next catastrophe was with LED's. I needed a high-brightness red indicator LED and chose one by Cree in a PLCC-4 package. You'll see from my picture that three of the legs all connect to the cathode of the LED, and one to the anode. And there is a diagonal line "cathode marking".

PLCC-4 LED package
In a subsequent project I wanted high-brightness LED's in different colours so manfully chose a bunch from the Farnell online store only to find, after designing my PCB and soldering them in, that they didn't work because they use the four pins differently. I had naively assumed all PLCC-4 LED's would use the same pin-out - indeed, why-ever not?

There's a moral somewhere...

20140525

Double wammy

There are muscles just above my knee that I didn't realise I had until I was labouring uphill in the forest this afternoon, barefoot, with the dog. Interspersed with having to stop because of cramp. No doubt because directly before the run (which I did solely for the dog's sake) I had cycled to the top of the Wicklow Gap and been caught in fairly hard rain so was drenched through and therefore cycling back for dear life with visions of hot baths and cups of tea forefront in my mind. And as this was my first cycle ride this year (not counting the one I did with K some while back) no doubt my cycle muscles have gone soft. Which muscles do remarkably quickly.


20140503

Barefoot Pinot Grigio




OK, I know, I haven't posted for ages, and this one is hardly worth much...  I guess the muse comes and goes, or more stuff that needs to be done.  Anyways, tonight we dined with some guests who brought this bottle of wine which seemed very appropriate - not only the "Barefoot" label but also the yellow cap!  It tasted good too - Pinot Grigio is my favourite grape variety at the moment.

20140420

Synergy or Kedgeree?

Synergy is when the result is greater than the sum of the parts. Applied to food it is what cooking is about. You take plums, flour, sugar and butter and mix them together and get plum crumble, with the caramalised juice oozing out at the edges - synergy. Mix oil and parsnips and add some heat and you get something quite different - synergy.

Plum crumble

Mix hard boiled eggs (possibly the worst way of cooking an egg IMHO) with boiled rice and bits of smoked fish and you get kedgeree. In this case the result is somewhat less than the sum of the parts, IMHO. I would frankly prefer the fish on its own, with a little rice to the side, and give the hard boiled eggs to my wife.

Or am I missing something? Jamie Oliver manages to make Kedgeree look and sound quite tempting.  But then he has some additional ingredients and he is Jamie Oliver...

Kedgeree a la Jamie Oliver

20140408

Extreme Programming



Apparently that's what 'XP' stands for. And this 8th April 2014 is the day it all comes to an end. Here's what Microsoft told me I would gain by switching to 8.1:


Good - so Windows 8.1 will do the things XP does for me and, good gracious! - it will do even more - but hang on, I don't actually want any of the extra things it will do for me...

The amazing thing is that, for all the wonder of 8.1, not many people are actually using it.  This is the lie of the land according to Wikipedia - a whopping 27% of desktops are still running XP, almost 3 times that running Windows 8! 


There's a good deal of scare tactics abroad - reminds me of Y2000 - for example the Irish Independent has: A NEW wave of computer viruses will target the computers of 300,000 Irish people tomorrow, as the country's third most popular computer system is cut off from security support by Microsoft.  That sudden, really?

Of course, I know I will be forced to migrate to 8.1 (or at least to 7) eventually. But I am hoping to defer this to when I upgrade my computer, rather than experience the misery and expense of upgrading just the operating system.

Finally a bit of nostalgia - you may never see this panorama again...


20140318

I can hardly believe it 2

I can hardly believe it - my baby daughter is engaged!

20140314

A prayer for Owen Meany




Here's another book I enjoyed reading - A prayer for Owen Meany by John Irving. I guess I enjoyed it because I could identify with the the characters and with the plot, bizarre though it is. I suppose I appreciate his daring treatment of issues I face. For those who like a analysis try here.

20140309

I can hardly believe it

I can hardly believe it - my baby daughter is coming home - all the way from the land of Oz!

20140223

Turboburn Monitor Plus

Suggested local user-interface for Turboburn Monitor Plus

With hindsight and a bit of experience behind us, here's my proposed specification for "Turboburn Monitor Plus".  This device does away with all electro-mechanical controls apart from, perhaps, an on-off switch.

Turboburn Monitor Plus specification

The device essentially controls the turbo-fan in any solid-fuel boiler of this type. It does so by monitoring the water-bath temperature, but can also monitor other temperatures. It has a local user-interface for example as shown above, and a remote, web-based interface.

The default local display shows the water-bath temperature in large numerals and the temperature trend in smaller numerals. In the example the water is at 93 degC and is rising at the rate of 3 degC per hour.  A lamp in the large button (or the display) indicates when the fan is running.

Press the small button marked "Display" to cycle though other parameters - after a few seconds the display will revert to the default.

Press the large green button to turn the fan on or off. When the fan is first turned on a period of say 15 minutes grace is allowed before the fan control algorithm cuts in. This is to give a newly lit fire time to get going. The algorithm detects when the water is no longer rising in temperature and turns the fan off and raises an "alert". The algorithm will also turn the fan off when the temperature gets too close to boiling, and raises an "alert".

An "alert" is also raised if the water-bath temperature falls below, say, 50 degC.

The device monitors the water-bath temperature and controls the turbo-fan. It can also monitor up to about six additional temperature sensors and a similar number of electrical circuits (e.g. pump on/off).

The web-interface will be similar to the existing Turboburn Monitor. Thus it also displays the water-bath temperature and its trend, and will also show the last 8 hours of this data in graphical form. The state of the fan and the temperature of other sensors is displayed (e.g. outside temperature), and the fan can be turned or or off remotely. All this data is logged in a file for optional analysis.

The device raises "alerts" to attract the attention of the person responsible for stoking. An alert appears as a banner across the web-interface page. It closes a volt-free relay contact which could be used to activate a siren or high-intensity beacon lamp. It could even send an email or a text.

The device is battery backed so that settings are not lost in the event of a power cut.

I am considering making this technology available in "kit" form. The kit would comprise a partially populated PCB (all the hard bits done for you) including an OLED graphical display and control button, a separate industry-style fan button, a heavy duty enclosure to mount it all in, and full instructions for customising to your own particular boiler set-up.

To register your interest without any commitment please send an email to tb4monitor at gmail dot com (replacing the ' at ' with @ and ' dot ' with . unless you are a robot!)



20140219

Turboburn Monitor part 3

Oh - and I forgot say - it is undesirable for the water to boil because the steam causes condensation which wets the insulation, and excessive boiling will discharge water through the overflow pipe, loosing with it the precious inhibitor additive.

Since even the best stoker may misestimate, we have added a feature whereby, when the 95 degC thermostat trips, a one-hour timer is started during which both main-house heating circuits are energised regardless of the room-thermostat. Thus excess heat is dumped to the house to bring the water temperature down.

If I redesign TB4 Monitor then it would be very simple to built this feature in, rather than having to use a separate 95 degC thermostat and one-hour timer with its relays to energise the heating circuits.

Turboburn Monitor part 1
Turboburn Monitor part 2
Turboburn Monitor Plus

20140216

Turboburn Monitor part 2


Our TB4 snug inside its shed "in the bleak mid-winter"

This picture was taken just after stoking. Once the fire has got up to temperature the amount of visible smoke emanating from the chimney drops dramatically.

The beauty of the Turboburn boiler is its simplicity. Apart from the amount of fuel, the only boiler user-variable is its fire-box fan. At the simplest level this could simply be left on 24/7, but having the fan on with no fire blows heat out of the chimney. Also, turning the fan off before a fire has burnt out may damp the fire sufficiently to avoid unnecessary boiling.

In Part 1 of this series I mentioned that Frank supplied a 2-hour mechanical timer and a 95 degC thermal cut-out. The idea of the 2-hour timer is to ensure the fan turns off if the boiler is left unattended, 2 hours being a typical time for a fire-box full of logs to burn out.  The cut-out is a fail-safe should the water get to boiling point. So I mounted these two controls in a box, outlined in red in the photograph below, this position being in front of two available thermometer pockets Frank had inserted into the boiler water-bath.

The house heating system has its own controls of course: the circulating pumps and zone diverting valves are controlled by a room-stat and programmer (timer). The hot water is controlled by a cylinder-stat and the programmer.

Our boiler is located a good 50m walk from the house and that's far enough to make one think twice about checking the boiler especially when the weather is inclement. So my first enhancement was to echo the boiler fan circuit to an indicator lamp and to install at the boiler a thermostat-switch set to about 50 degC which lights a second indicator lamp, these lamps being located by the heating controls in the house. Thus we can see without leaving the house whether the fan is running and if the boiler temperature gets very low.

My next enhancement was to add a relay to automatically switch over to the oil-fired boiler and immersion heaters when the Turboburn temperature falls below the 50 degC. This switch-over only occurs if a switch is set. So far we have used this feature only once - it was in the early days before we had figured out how much wood to stoke and whilst we had a bunch of American visitors (these Americans were allergic to our Irish weather).

With a little experience one can gauge how long the boiler will run on a given amount of timber and about how many degree it will increase the water-bath temperature, all other things being equal. But all other things are seldom equal: during the night when the heating is off the temperature hardly drops at all, but when all heating circuits are demanding the temperature plummets. Even when the programmer has timed the heating to be "on" it is difficult to predict when the room-stat will be demanding. If you have stoked the boiler expecting the heating to stay on, and then the room-stat turns if off, the water-bath temperature might soar. Or conversely you might think there was enough heat to last and then someone hits the "boost" button on the programmer.

Enter "Turboburn Monitor". This is a box of electronics which I created from a dormant work project, mounted on the side of the boiler.  This box is outlined in yellow in the photograph below - double-click the photo to enlarge it. The box is connected to seven temperature sensors around the boiler and two relays in the main control box (outlined in red).

Our TB4 boiler with conventional control box and TurboBurn Monitor

Inside the box a PIC32MX microprocessor acts as a web-server and is connected by CAT5 cable to our local area network (LAN). We were able to pull the CAT5 cable through the 4" duct Frank had thankfully insisted we bury with the pipes for such a time as this.

Any web-browser (e.g. a smart-phone) connected to the LAN can surf this embedded web-site to display the boiler status and optionally over-ride the 2-hour timer.


Turboburn Monitor main screen in the morning

The first screen-shot was taken shortly after 09:00.  The boiler was not fired during the entire period shown. You can see how well the boiler retains its heat during the night when there is no demand, and how the temperature starts to drop as soon as the heating comes on at 06:30.

We have the seven temperature sensors fitted as follows:

  •  one in each of two boiler thermometer pockets: the software takes the highest reading
  •  one 'outside' in a plastic box mounted on the outside wall of the boiler-house
  •  the remainder affixed to the copper flow-pipe about a metre from the boiler on each circuit: main house heating, main house hot-water, courtyard heating (not yet working) and courtyard hot-water, thus a sensor reads high when that circuit is demanding heat.


An hour or so after lighting the fire

The second screen-shot shows a steady decline during the day (today - Sunday - so the heating was on most of the time) until the boiler was stoked at 14:33.  We usually leave stoking until about 4pm - I guess Joe decided to light the fire earlier today because he had noticed, from this software app, that the temperature had dropped as low as 60 degC.


Turboburn Monitor "Settings" page

The web-site has a second page accessed by clicking the 'Settings' button. Here you can turn the fan off if it is on, or on if it is off, and synchronise the web-site's clock which isn't battery backed in this version.

Turboburn Monitor has proven to be most useful and the various people here who stoke the boiler like it. But most of the time it is used only to remotely gauge the boiler temperature.

Clearly it could do more.  It was built "upon" Frank's existing 2 hour timer control but, if I were starting from scratch, I would replace the mechanical timer.  Thus the new Turboburn Monitor would do all that the existing version offers PLUS:

  • local display of boiler temperature and trend
  • local control buttons to activate / deactivate fan
  • software algorithm to detect when fire goes out, kill fan and send prompt to designated stoker-person
  • software algorithm, taking as inputs the flow-pipe temperatures and outside temperature, to estimate
  • send prompt when boiler temperature drops below say 55 degC
  • automatic kill fan when temperature exceeds say 95 degC and send prompt
  • provide battery backup at least of the real-time-clock

The prompts could be by text or email as well on a banner (that has to be dismissed) across the web-site main page.

I imagine the same concept would apply equally to any solid-fuel boiler that needs monitoring from a distance. We have it in mind to further develop the idea as outlined above and to make it available in "kit" form (since inevitably every installation will have differing requirements). To register your interest without any commitment please send an email to tb4monitor at gmail dot com (replacing the ' at ' with @ and ' dot ' with . unless you are a robot!).

Turboburn Monitor part 3
Turboburn Monitor part 1