MyAir Android Tablet App Temperature Bug

2017/11/23 Leave a comment

There is a strange bug in the current version of the app. If I set the MyZone temperature, it suddenly changes the setting with a value 3 degrees cooler!

No wonder my power bill is high



Categories: Uncategorized

Have you unit tested that aileron servo?

2016/05/25 Leave a comment

Unit testing has become a religion. The more a system is replaced with impostors just for the sake of testing convenience and timeliness, the lower the level of usefulness such results have when reporting to stake-holders.

Testing with a database is integration testing and one does not mock-out an airplane aileron when testing a flight management computer just because the aileron’s servos are slow!

Categories: Development

Developer De-skilling and the Fast Food of Software Development

2015/08/01 Leave a comment

In the beginning, anyone who wanted to be around a computer generally wore a white coat and had several letters after his surname.  Over time and with each generation the need for programmers to be part of a secular order; to punch peculiar tiny holes onto small flat pieces of cardboard has no longer been as important and has freed people up so that they may instead fixate over purchasing small electronic devices for the purpose of making phone calls, only to buy a new model the following year.  Which is odd when you think about it since no one really buys these small device for making phone calls but I digress.

In the early years, at least from my experience, you really had to know your stuff as a c/c++ developer.  There was no Internet (at least we had access to);  no Google to find things at a touch of a button;  no open source library let alone open-source system or sub-system that you could plonk willy-nilly into your project.  What we did have were books?  Ah books.  Lovely smelling finger-loving hard-bound tomes of awesomeness.  Didn’t know something?  Look it up.  I fondly remember the wonderful set of Windows 3.0 API and Microsoft MFC volumes.  I read the reference manual from beginning to end.  I could not wait to try out something I had learnt.

As I mentioned, we didn’t use open source – such a concept did not arise in the Windows world at least in my travels until everyone had pretty much committed to c#.  I’d say everyone in our team were equally skilled and we had great team-work. Prior to that – need a database? Hire a DBA.  Need to learn DCOM?  Buy that Wrox book.  Embedded system?  R&D.

Today I find it’s all rather changed where the need for creating a software sub-system is replaced with an order to source a pre-fabricated; unknown; un-tested; potentially toxic foreign body and plug it into our developing system.

  • No sooner as a need arisen for hosting multiple .NET services into a single system as someone says “get a open-source project”
  • Need a reliable messaging system?  Better down-load that open-source bus project that has been stagnant for the past 24 months
  • Need a plug-in system?  Well you better use MEF then
  • Don’t have time for a nutritious home-cooked meal with ingredients your purchased?  Better buy that burger at the drive-thru then

Now, I can understand that time spent rolling our own equivalent to the above may be better suited to fulfilling the immediate demand as put by the project requirements.  That’s a valid point so long as measure the time spent rolling your own relative to the time spent developing the entire project.  If you’re going to incorporate someone else’s system, you should ideally quarantine the foreign system and subject it to the same level of software testing your company does.  I suspect you don’t and you would not be alone.

I only this week threw the c++ DICOM open source testing project DVTk into the bin.  It had more memory leaks than atoms in my Miss Piggy coffee cup.  It’s rather embarrassing really when you consider the API is meant for a testing software.  Ooops!

Plus and more importantly, pre-fab software sets a dangerous precedent where if left unchecked, developers would be largely nothing more than systems integrators with little knowledge how the disparate foreign sub-systems operate nor of the overall quality of said sub-systems; where all the substantial; complex and low-level development has been done by someone else.

One has only to look at some of the questions on StackOverflow.

Only this week someone was asking:

“how do I make a progress bar for my UI”.

Nothing wrong with that until you learn the author is wanting to make a game in Unity 3D no less.  I’m pretty sure making a game has a high requirement that a developer be skilled graphics-wise.  If you can’t make a progress bar then you should not be making a game.  To not to be able to do so when you’re using a 3rd party game engine – something that is responsible for a measurable and significant amount of foundation is just the more embarrassing.

This is what the world of pre-fabbing has come to.  What is even more amazing is that even in this world of instant-satisfaction Googling, some people are have trouble clicking that search button on their web browser because they are too busy looking at their shiny phone or new age digital watch.  Unable to spend time with Google or AskJeeves to perform any form of research or let alone pick up a book.

The other danger of course failure in backward-compatibility or failure as a result of a combination of 3rd party system interaction of a 3rd party system or systems or platform in the future.

  • Making a control for Google Chrome using their proprietary control technology?  Let’s hope they don’t remove it as a feature. Oh wait they just did
  • Not too long ago, many firms were utilising Flash in their web sites but iOS; and the continual desktop security issues eventually saw to the demise of the once popular juggernaut
  • Using AnglularJS?  Can you bet your guinea pig’s life that AJS won’t be incompatible with browsers in 5 years time?
  • Can you say for 100% certainty that HTML5 won’t be replaced with something else?
  • Can you say with confidence that the contributors to say AJS won’t ditch it for something new

But wait I hear you say – it’s open source, we can just download the source code and maintain it.  Perhaps, assuming of course that the skill set of the developers are up to the task and more importantly management will allow you to spend considerable resources in an attempt to first comprehend the 3rd party system; then make the necessary changes.

In some ways, even using a web browser is essentially a 3rd party open source ever changing, widely-unpredictable development platform.  Is it really necessary for your next project to be browser-based?  Particularly if its for an intranet.

Think twice before you use that open-source project.

Categories: Development Tags: ,

n-Body Galaxy Simulation using Compute Shaders on GPGPU via Unity 3D

2014/02/01 12 comments


Following on from my prior article about GPGPU, I thought I try my hand at n-Body simulation.

Here’s my first attempt at n-Body simulation of a galaxy where n equals 10,000 stars with the algorithm running as a compute shader on the GPU.  Compute shaders are small HLSL-syntax-like kernels but can run in massive parallel compared to a regular CPU equivalent.

It’s important to remember that conventional graphics including those in games, do not use GPGPU for star fields.  Generally this is accomplished by either manipulating the star coordinates CPU-side and uploading to the GPU every frame or so; or utilise a small shader that renders a pre-uploaded buffer of stars that may or may not move over time.  In any event, it would be unlikely to perform n-Body simulation using conventional non-GPGPU means due to the slow performance.

My simulation entails n2 gravity calculations per frame or 10,0002 = 100,000,000 calculations per frame at 60 frames per second – something that is quite impossible if I attempted to do it from the CPU-side even if the GPU was still rendering the stars.

Here’s the compute kernel (note I’m hosting the Gist on GitHub as a “c” file in order to display syntax hi-lighting.  Readers should be aware the correct file extension is .compute):

Here’s my Unity MonoBehaviour controller that initialises and manages the simulation:

Censorship on Planetary Annihilation Steam Forums?

2014/01/25 Leave a comment

Planetary Annihilation (PA) from Uber Entertainment (UE) is an Early Access title on Steam currently available for purchase for $59.99 USD.  Early Access means that one can buy the game now even though it is not finished with the notion that one is supporting the devs in their endeavours.   In other words the title is pre-alpha.  This can be a good or bad thing and for the complete run-down I recommend listening to TotalBiscuit’s discussion on Early Access.

I’ve been looking over the PA forums hosted on Steam trying to become a little more informed about this interesting title; a title which was tempting me to open my wallet and let the moths fly free. Sadly I was only to discover a disturbing pattern of arguably fascist censorship by the powers that be of anything negative that people have said or even requesting features that are not aligned with the current agenda[4]. Most authors are expressing their concerns over the price of the title [1] [2] [3].

Now I’ve not encountered anything like this since perusing Bohemia Interactive forums – specifically ARMA xx or Carrier Command Gaia Mission where many a poor chap would be banned; or a thread locked should one sneeze or forget to pay homage to the sacrificial guinea pig.

One thread on Steam got locked for asking for a OS compatibility feature. Did I mention there were only five (5) posts in the thread. [4] So much for an open discussion.

Steam Green Light clearly states:


Uber Entertainment states on the Steam Early Access Game notice:


It seems the benefits of an Uber Entertainment (UE) Early Access relationship are clearly one-way and quite arrogant at that; at least that is the perception established by the UE Steam moderators. The suppression of any negative discussions only serves to raise suspicion. It is quite possible that the UE moderators on Steam are not on the same level of professionalism as UE proper; if so UE could perhaps consider reiterating company policy with all those that represent it.

I for one shall take no part in the Early Access. I think I shall wait patiently for the game’s release where upon I hope to buy should the title prove worthy.

I wish them the best of success until then.

[1] “Came back to check on this old game. Lmao @ the price again.”,

[2] “to much money”,

[3] “I just bought PA and I feel cheated”,

[4] “I will buy it if developers add Windows XP compatability”,

[5] “The Minecraft Beta was $5….”,

Categories: Games Tags: ,

GPU General Purpose Computing with Unity Compute Shaders

2014/01/16 3 comments

Compute Shaders in Unity3D are a way to perform general purpose computing on a GPU card.  This is known as General Purpose computing on Graphics Processing Units or GPGPU.  This means you can use the GPU to perform operations that may not necessarily have anything to do with graphics.  e.g. protein folding simulations (ya I don’t know what that is either).  Not everything is suitable, only those operations that can run concurrently and make use of the ridiculous amount of parallelism on a GPU.

Unity’s Compute Shaders are currently limited to supporting DirectX 11 only but I suspect this will change in the future when you consider that Unity’s aim is to be cross-platform.  DX11 compute shaders is also known as DirectCompute.

Compute shaders syntax is just as per HLSL so you should feel right at home.

Compute shaders are great.  Normally from what I understand, if you had a ton of stuff to manipulate well you had to do it CPU side then upload it to the GPU – a very expensive operation not to be done frequently.

With compute shaders you merely allocate the data CPU side and send it once to the GPU.  From then on a little program (or kernel) updates the data for you and the output is passed to a shader for rendering.  All without being touched by the CPU.

Here’s my first attempt at making a GPGPU galaxy modelled with 1,000,000 stars where the stars are moved on the GPU side of things.  It’s looks more like a pizza at the moment, oh well.  I can manage 60 FPS on 1920×1080.




I’ll follow up with a non-pizza looking galaxy soon and some source code as documentation on anything GPGPU is quite rare.

Maybe if we get enough of these GPUs we can find out what “42” means?

Categories: Development Tags: , ,

(Solved) Battlefield 4 or Forza Install Problems for Xbox One

2013/11/23 2 comments

Stuck at the annoying “Installing 0%” progress on the Xbox One (XBO) when trying to play these games for the first time due to a game-specific 6GB game patch (I’m not referring to the XBO Day One Patch)?  This message appears as soon as you insert the disc but before it bothers to install from it.

Here’s a little trick:

  1. In XBO Settings either disconnect your WiFi or unplug your Ethernet lead to the box
  2. Sign-out of the XBO
  3. Now return to the home screen
  4. Hi-light your game/disk icon (BF4 or Forza)
  5. Press Start (or whatever its called now) on the controller
  6. Select Cancel Install
  7. Highlight the disk icon
  8. Click to start the install again

The game will now install from the DVD.  When its ready to play, reconnect your network and sign-in.  You’ll still need to patch but it won’t be as big nor get stuck.

Categories: Games Tags: , ,