<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-24116572</id><updated>2011-09-25T20:44:24.654+01:00</updated><category term='C++'/><category term='sorting'/><category term='guis'/><title type='text'>Programming</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>37</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-24116572.post-1370074125606981115</id><published>2011-06-11T16:37:00.005+01:00</published><updated>2011-06-11T22:49:38.552+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sorting'/><title type='text'>Human sorting algorithms</title><content type='html'>Whilst tidying the shed, I had to stack around 100 plant pots.  This is a straightforward sorting algorithm.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;So why don't humans use quicksort, like computers would?&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The answer which occurred to me was that the effort to compare two items is not always equal. The other answer is that humans can't keep track of umpteen piles of stuff, and remember which pile needs to be merged into another pile.  Each of these things takes overhead which isn't accounted for in the traditional analysis of sorting algorithms.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;When there are a small number of possible sizes, the correct algorithm should be bin-packing. Just keep n separate piles, and put each item into their pile.  As the number of sizes is small, arranging them is easy.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The algorithm which I used is as follows: spread everything out and pick the biggest and put it onto the pile.  Repeat.  If you make a mistake, do an insertion sort.  This is efficient for humans, because our eyes are great at parallel processing, and is fine for around 100 pots.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Now, how to prove that this!  Another real-life problem where the correct algorithm isn't obvious, is matching socks.  In this case, the problem is finding a decent way of comparing them. I would suggest using a bin-packing algorithm to start with, and going from there.  At each layer in the hierarchy, pick an appropriate discriminator.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;What sorting algorithms don't analyse either is the likelihood of mistakes, and the cost of correcting them!&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-1370074125606981115?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/1370074125606981115/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=1370074125606981115' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/1370074125606981115'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/1370074125606981115'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2011/06/human-sorting-algorithms.html' title='Human sorting algorithms'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-6661485671533385332</id><published>2008-06-03T23:24:00.002+01:00</published><updated>2008-06-03T23:28:33.636+01:00</updated><title type='text'>Why virtualization is pointless</title><content type='html'>Virtualization is a growing trend in running computers in "containers" which emulate (virtualize) actual hardware.  The benefit is that the container becomes portable, and can be run on different hardware, or migrated.  Backups are a lot easier, there are security benefits, and hardware can be utilized more effectively.  Virtualization is a growing trend and Microsoft has realized this and put it at the heart of Windows Server 2008. &lt;br /&gt;&lt;br /&gt;The heart of the web - URLs (uniform resource locations) are a specification of the location of a resource - usually a web page, but can also refer to services (e.g. SOAP) and web applications. &lt;br /&gt;&lt;br /&gt;The real problem is that machine name is being used as a proxy for resource location.  In a URL - e.g. http://bbc.co.uk/news/12345.html - the bbc.co.uk part is specifying something physical - often a machine name - but certainly a physical place such as a router.  In computer networks, machine name is critical in specifying the location of certain resources.  This is the legacy of DNS (domain name system) which assigns names to computers. &lt;br /&gt;&lt;br /&gt;Physical device is often used  as a proxy for resource in the home.  Your photos are stored on a physical disk in a physical computer, and you locate them by specifying where they are stored.  When you are out and about, you usually don't have access to them because you don't have a network access to the physical device. &lt;br /&gt;&lt;br /&gt;This approach of tying resources to hardware is frankly wrong.  Why should I care where my photos are stored - providing I can access them and they are stored securely.  Maybe hard disk or memory should be an intelligent cache and nothing more.  The current approach does not protect users from data loss, and is hard for users to manage. &lt;br /&gt;&lt;br /&gt;Virtualization is a solution to the wrong problem.  Virtualization allows the easy migration of a machine - but why would you need to do that?  It's only because we rely on certain services running on certain machine names that we even need to think of the "machine" as a unit.  Virtualization is incredibly wasteful of machine resources, and is like hitting a walnut with a sledgehammer.  It's far better to migrate the software, and have multiple software running on the same OS - like the good old days.  We already have a perfectly good container, and it's called the "process". &lt;br /&gt;&lt;br /&gt;The solution is to break the link between resource and machine name.  I predict that in the future, data, services, resources and computing resources will exist in a redundant, replicating, self-healing "cloud".  Running processes will be able to migrate between different computers - much like they can migrate to different processors at the moment.  Different computers will form collectives and be given a catchy name like "swarm", "hive" or "cluster".  In future, we will think about services, rather than physical or virtual machines.  Virtualization is merely a stop-gap measure until we fundamentally rethink the way we provision resources.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-6661485671533385332?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/6661485671533385332/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=6661485671533385332' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/6661485671533385332'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/6661485671533385332'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2008/06/why-virtualization-is-pointless.html' title='Why virtualization is pointless'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-3236337640351987745</id><published>2008-04-02T21:15:00.002+01:00</published><updated>2008-04-02T21:30:31.134+01:00</updated><title type='text'>Vista isn't as bad as everyone says it is</title><content type='html'>It's much worse than that.&lt;br /&gt;&lt;br /&gt;I've just been waiting 20 minutes for my 64-bit quad-core RAIDed desktop to boot.  I think I'll just have 30 minutes of work - and almost all of that time is lost to Vista hanging and crashing.  This is about the 10th time my computer has hung up like this.  The only reason I go with Vista is because we use the Microsoft toolchain at work which I quite like, and I foolishly think that I'll save time by using Vista.  I mean, if it's one thing an OS need to be, it's stable.  The kernel seems deadlocked and resource starved.  This is SP1.&lt;br /&gt;&lt;br /&gt;Other niggles are that its safe boot won't recognise my USB keyboard (even though the BIOS does), it hung and didn't work with my Wifi card (so I had to waste money on a new one).  It bugs me about UAC each time my computer boots, and the whole kernel is very unstable coming out of hibernation.  Each time I reach for the reset, I know my computer will be out of action for hours whilst it verifies its RAID.  Really, Linux is looming.&lt;br /&gt;&lt;br /&gt;* Harp music and a mirage *&lt;br /&gt;&lt;br /&gt;Steve Bulmer (no relation to the fat fuck at Microsoft) is sitting on a park bench.  Suddenly a 500kg gorilla grabs him from behind and...&lt;br /&gt;&lt;br /&gt;* More harp music *&lt;br /&gt;&lt;br /&gt;Ah, Vista shows me a logon screen.  All is well.  Next time Vista plays up, I'll start having fantasies about Bill Gates and a pack of hungry wolves.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-3236337640351987745?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/3236337640351987745/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=3236337640351987745' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/3236337640351987745'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/3236337640351987745'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2008/04/vista-isnt-as-bad-as-everyone-says-it.html' title='Vista isn&apos;t as bad as everyone says it is'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-3485372634853814613</id><published>2008-03-23T13:17:00.003Z</published><updated>2008-03-23T13:31:06.611Z</updated><title type='text'>Speeding up builds</title><content type='html'>Here's a really simple tip if you are using GNU make.  You can pass in the -j option to run the build steps in parallel.  The default is -j1, i.e. no parallising.&lt;br /&gt;&lt;br /&gt;The next question is what's the optimum number of jobs to run in parallel?  An experiment on a build reveals:&lt;br /&gt;&lt;br /&gt;&lt;table&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;N&lt;/td&gt;&lt;td&gt;Time&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;1&lt;/td&gt;&lt;td&gt;6m13s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;2&lt;/td&gt;&lt;td&gt;3m28s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;3&lt;/td&gt;&lt;td&gt;2m38s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;4&lt;/td&gt;&lt;td&gt;2m11s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;5&lt;/td&gt;&lt;td&gt;1m59s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;6&lt;/td&gt;&lt;td&gt;1m55s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;7&lt;/td&gt;&lt;td&gt;1m53s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;8&lt;/td&gt;&lt;td&gt;1m49s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;12&lt;/td&gt;&lt;td&gt;1m47s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;16&lt;/td&gt;&lt;td&gt;1m47s&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;/table&gt;&lt;br /&gt;&lt;br /&gt;So there you have it!  On a 4-core CPU (Intel Q6600), it's best with -j4 or above.  It's interesting that -j4 didn't max out the CPUs, and that you can keep getting good improvements up to at least -j8.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-3485372634853814613?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/3485372634853814613/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=3485372634853814613' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/3485372634853814613'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/3485372634853814613'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2008/03/speeding-up-builds.html' title='Speeding up builds'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-2269135640742842538</id><published>2008-01-17T19:49:00.000Z</published><updated>2008-01-17T20:12:01.348Z</updated><title type='text'>Why isn't visual programming popular?</title><content type='html'>Visual programming is the idea that programmers (or even end-users) can program using a graphical notation.  There are a number of reasons why this seems like a good idea:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Programs are structural, not linear/sequential &lt;/li&gt;&lt;li&gt;Textual syntax is difficult, and a barrier&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Graphical notation is richer - allowing new paradigms that would not work with text&lt;/li&gt;&lt;li&gt;Direct manipulation - treating program components as physical things&lt;/li&gt;&lt;li&gt;Programmers use graphical notations widely, both formally and informally&lt;/li&gt;&lt;/ul&gt;Of course visual programming hasn't actually taken off as expected.  A lot of excuses have come up.  Here are some of them:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Yea, but we're stuck in a textual programming rut&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Almost all new programming languages fail; this is to be expected&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Workstations aren't graphical (not true any more)&lt;br /&gt;&lt;/li&gt;&lt;li&gt;All VP systems are toy systems unsuitable for real world problems (true to an extent)&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Graphical notation is less compact (true, but there are solutions)&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Because early VP system sucked, people assume all VP systems suck&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Graphics is obviously better, we just haven't found the right approach yet.&lt;/li&gt;&lt;/ul&gt;Until recently, I would have had a great deal of sympathy with these views.&lt;br /&gt;&lt;br /&gt;I've recently been working with use cases, which are a predominantly textual notation.  The interesting thing is that there is also a graphical notation for use cases.  The problem with the graphical notation is that it loses all precision, including extensions, preconditions, actors, goal level, stakeholders and interests, guarantees etc.  In fact as a notation, UML use cases diagrams are very poor in comparison to text.&lt;br /&gt;&lt;br /&gt;So we need to accept that fundamentally, some information is best presented as text.&lt;br /&gt;&lt;br /&gt;Another problem is that the notation isn't as important as other aspects of software development. The text editor is just a convenient universal editor.  It isn't the syntax which is hard with programming.  It's annoying, sure, but it's not the crux of the problem.  The crux of the problem is the design, the OO model, the functionality, memory allocation (if using C), the algorithms, the usability, the process, and the obsessive (male?) thinking.  These are problems that aren't going to be changed by a graphical notation.  In fact, using the text editor is probably the easiest part in the whole programming process!&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;What are the lessons from Visula?&lt;/span&gt;&lt;br /&gt;In some ways, &lt;a href="http://visula.org"&gt;Visula&lt;/a&gt; is yet another VPL.  A large part of it was written for fun - what would I come up with?  In terms of scalability and practicality, it is orders of magnitude better than many other VPLs.  If the question was: can VPLs be practical, usable and scalable, then the answer is a resounding YES!  I didn't know this before.  Hopefully that blows away some of the old prejudices, if anyone will listen.&lt;br /&gt;&lt;br /&gt;Visula will not become a mainstream language though.  It doesn't offer huge benefits over other scripting languages.  I personally prefer the notation (which is really unique by the way), but that isn't enough on its own to persuade people to switch.  Also the editor only runs on Windows, big mistake.&lt;br /&gt;&lt;br /&gt;In hindsight, I should have based Visula on an existing scripting language, and created a graphical editor for the language.  This would have been simpler to implement, and users would have no barrier to entry for the new notation.  If they decide they don't like the editor, they can switch back to text.  Creating a totally new language that nobody's going to use is fun, but pointless.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Recent trends&lt;/span&gt;&lt;br /&gt;Before discussing new trends, let's review the current trends.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Types: Strong -&gt; Dynamic&lt;/li&gt;&lt;li&gt;Style: Algorithms -&gt; Glue&lt;/li&gt;&lt;li&gt;Data: Bits and bytes -&gt; Objects and patterns&lt;/li&gt;&lt;li&gt;Expertise: High -&gt; Low&lt;/li&gt;&lt;li&gt;Environment: Textual -&gt; IDE -&gt; Tools&lt;br /&gt;&lt;/li&gt;&lt;li&gt;UI: Text -&gt; Desktop -&gt; Web -&gt; Web 2.0 -&gt; Web apps.&lt;/li&gt;&lt;li&gt;Data: Files -&gt; Databases -&gt; Mobility -&gt; Sharing -&gt; Community&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Paradigm: Procedural -&gt; OO&lt;/li&gt;&lt;li&gt;Memory management: Manual -&gt; Automatic&lt;/li&gt;&lt;li&gt;Data binding: Manual processing -&gt; Drag and drop&lt;/li&gt;&lt;li&gt;Databases: File -&gt; Relational -&gt; ORM&lt;/li&gt;&lt;li&gt;Software: Small and buggy -&gt; Big and bloated&lt;/li&gt;&lt;li&gt;Quality: Low -&gt; High&lt;/li&gt;&lt;li&gt;Development process: Waterfall -&gt; RUP -&gt; Agile&lt;/li&gt;&lt;li&gt;Interoperability: None -&gt; Low -&gt; Inherent&lt;/li&gt;&lt;li&gt;Programmers: Generalist nerds -&gt; Specialist communicators&lt;/li&gt;&lt;li&gt;Usability: Terrible -&gt; Low -&gt; Better&lt;/li&gt;&lt;li&gt;Platforms: Single platform -&gt; Run anywhere.  Desktop -&gt; Web -&gt; Mobile&lt;/li&gt;&lt;li&gt;Libraries: Small and fragmented -&gt; Monolithic and comprehensive&lt;/li&gt;&lt;li&gt;Formats: Binary -&gt; Text -&gt; XML&lt;/li&gt;&lt;li&gt;Automation: Low level languages -&gt; Code generators -&gt; High level language&lt;/li&gt;&lt;li&gt;Reuse: None -&gt; Libraries -&gt; Platform&lt;/li&gt;&lt;/ul&gt;&lt;span style="font-weight: bold;"&gt;Future challenges&lt;/span&gt;&lt;br /&gt;We still need to explore new notations - not because they are useful, but because they are interesting.  It seems that all new work in HCI has to have proven immediate benefit backed up by experiments.  This isn't blue-sky research, this is short-termism.  Researchers should avoid making optimistic claims about the usefulness of their approach, but then they shouldn't need to.&lt;br /&gt;&lt;br /&gt;There are a number of upcoming challenges to programming that software tools in general should address.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Scale.  Libraries are now tens of thousands of methods large.  How does one manage such a large amount of data? &lt;/li&gt;&lt;li&gt;Parallelism.  We hear this all the time.&lt;/li&gt;&lt;li&gt;End user programming.  Includes teaching programming to kids.  How does this translate into grown-up programming?&lt;/li&gt;&lt;li&gt;Integrating programming with development process.  Done in CASE tools. But there is a disjoint between CASE tools and programming languages.&lt;/li&gt;&lt;li&gt;Tracking, collaboration. &lt;/li&gt;&lt;li&gt;Web-based programming.&lt;/li&gt;&lt;li&gt;Textual transformations.&lt;/li&gt;&lt;li&gt;Reduce detail.&lt;/li&gt;&lt;li&gt;Navigation.&lt;/li&gt;&lt;li&gt;Searching.&lt;/li&gt;&lt;li&gt;Make it tangible.&lt;/li&gt;&lt;li&gt;Specify less.&lt;/li&gt;&lt;li&gt;Manage detail.&lt;/li&gt;&lt;li&gt;Guide the user.  Often you stare at some code asking "what do I do next?" &lt;/li&gt;&lt;li&gt;Create a top-down workflow where the programmer assists the tool, not the other way around.&lt;/li&gt;&lt;li&gt;New paradigms.  If I knew what they were, they wouldn't be new would they?&lt;/li&gt;&lt;li&gt;Hide complexity.&lt;/li&gt;&lt;li&gt;New abstractions, e.g. for parallelism.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Reduce cognitive load.  (A posh way of saying make it easier).&lt;/li&gt;&lt;li&gt;Focus on the domain and the goal - not the technology.&lt;/li&gt;&lt;li&gt;XSLT or other transformations between notations.&lt;/li&gt;&lt;li&gt;Raising the level: Making programming more human and less nerdy.&lt;/li&gt;&lt;/ul&gt;What's clear is that transforming the textual notation alone isn't going to address these challenges.  It might look pretty and nice, but it's not where the trouble with programming lies.  I'm optimistic that graphics are better, but they are also a bit of a red herring. &lt;br /&gt;&lt;br /&gt;As Fred Brookes said: There is no silver bullet.  There is so much more research to do.  Programming as we know it will change.  I just wish I was clever enough to work out how.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-2269135640742842538?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/2269135640742842538/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=2269135640742842538' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/2269135640742842538'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/2269135640742842538'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2008/01/why-isnt-visual-programming-popular.html' title='Why isn&apos;t visual programming popular?'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-6793216799605288627</id><published>2007-11-18T21:20:00.000Z</published><updated>2007-11-18T21:25:55.796Z</updated><title type='text'>Write more libraries</title><content type='html'>&lt;span style="font-family:sans-serif;font-size:85%;"&gt;We keep hearing that code reuse is a Good Idea,  that we should do more of it, and that it can drastically reduce costs etcetera  etcetera.  It makes common sense in an ideal world.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;The reality is very different.  Code gets build into  applications, dependencies build up, behaviour becomes fragile, code becomes  less maintainable, and eventually after the people who wrote  the code have moved on, decided that the original design was poor, the  maintenance costs rise and becomes a fire-fighting exercise, so the code gets  thrown away and rewritten.  However this can be a cycle: new code eventually  also rots and gets thrown away.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;Refactoring is supposed to rejuvenate your code and keep it current. I'm sure  the theory works fine.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;The problem  is that fundamentally, people don't write code for reuse. They put a good design  in (that is appropriate at the time), and think that's the end of it.  However  that code won't get reused properly.  It might get ripped out and  copied-and-pasted into another application, but that is far from ideal code  reuse.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;Instead I would suggest  putting as much code as possible into reusable libraries.  This means that as  much as possible should work stand-alone, without dependencies.  When coding a  library, imagine its use for the application at hand, but also treat it as an  independent work, with proper documentation, and proper anticipation of the  different ways the code could be used.  It may mean generalising prematurely,  but the code becomes infinitely more useful.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;Now in a typical project, I would organise it as  follows:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;        lib1&lt;/span&gt; &lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;        lib2&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;        test1&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;         test2&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;        applogic1&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;        applogic2&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;        testapplogic1&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;         testapplogic2&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;        app1&lt;/span&gt; &lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;        app2&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;lib1 and lib2 are the main code - as independent  libraries,  They depend on nothing, except perhaps each other (and without  circular dependencies).  Most of the code should go into these libraries, and  follow proper documentation and coding guidelines as appropriate for libraries.   Where specific implementations are mandated, try to provide a strategy pattern  to make the library not specific to the application.  Where code is too  interdependent, break the dependency by providing interfaces.&lt;/span&gt; &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;The test1 and test2 projects are the unit  tests.  These test the functionality in lib1 and lib2 respectively.  Part of the  build process should be to run the unit tests, and fail the build if the unit  tests fail.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;applogic1 and applogic2  are libraries of business or application logic (you could also have bl1 and bl2  if that suits your application better).   There are also unit tests for  applogic1 and applogic2, which should also be run as part of the build.&lt;/span&gt; &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;app1 and app2 are the different  applications.  The point is that app1 and app2 should be as thin as possible.   This is the bit you're going to throw away or port to another platform, whereas  everything else should be cross platform.  app1 and app2 can share common  functionality from lib1 and lib2, and the logic from applogic1 and  applogic2.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;In terms of longevity,  app1 and app2 have the shortest lifespan.  They will be full of  platform-specific GUI-code which will be hard to unit test.  applogic1 and  applogic2 contain logic specific to your application, which can be shared  between applications.  If possible, make the logic extensible without going over  the top.  The application logic will have a longer lifespan because it can be  reused for different applications, but is in general tied to particular  applications.  The libraries should have an indefinite lifespan.&lt;/span&gt; &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;If you are serious about code reuse, you  should push as much code as possible into libraries.  Think: does this unit have  functionality beyond the application?  Can it be generalised?  If the answer is  yes, then move the code into a library.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:sans-serif;font-size:85%;"&gt;In hindsight, I don't see how any code could be reused unless it is in a  library, and I don't see how unit tests can be linked against code embedded in  an application.  Librarifying (!) your code clearly separates out the parts that  you intend to reuse, and the parts you intend to throw away.  Libraries are your  crown jewels.&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-6793216799605288627?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/6793216799605288627/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=6793216799605288627' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/6793216799605288627'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/6793216799605288627'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/11/write-more-libraries.html' title='Write more libraries'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-2726937027235316976</id><published>2007-10-11T11:20:00.000+01:00</published><updated>2007-10-11T16:34:48.429+01:00</updated><title type='text'>Reversing the #include idiom</title><content type='html'>There's an idiom in C and C++ whereby of you include a header file, you write&lt;br /&gt;&lt;blockquote style="font-family: courier new;"&gt;#ifndef FILE_H_INCLUDED&lt;br /&gt;#define FILE_H_INCLUDED&lt;br /&gt;&lt;br /&gt;// stuff&lt;br /&gt;&lt;br /&gt;#endif&lt;/blockquote&gt;It occurs to me that it should actually be&lt;br /&gt;&lt;blockquote style="font-family: courier new;"&gt;#ifndef EXCLUDE_FILE1_H&lt;br /&gt;#define EXCLUDE_FILE1_H&lt;br /&gt;&lt;br /&gt;#endif&lt;/blockquote&gt;This is a minor point, however it means that you can legitimately exclude certain header files if for some reason you don't want to include them:&lt;br /&gt;&lt;blockquote&gt;&lt;/blockquote&gt;&lt;blockquote&gt;&lt;/blockquote&gt;&lt;blockquote style="font-family: courier new;"&gt;gcc foo.c -DEXCLUDE_FILE1_H&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-2726937027235316976?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/2726937027235316976/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=2726937027235316976' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/2726937027235316976'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/2726937027235316976'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/10/reversing-include-idiom.html' title='Reversing the #include idiom'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-963583013714389593</id><published>2007-09-29T21:10:00.000+01:00</published><updated>2007-09-29T21:18:59.560+01:00</updated><title type='text'>New user interface rule</title><content type='html'>Every action on a user interface shall result in a response from the computer in less than 0.25 seconds.&lt;br /&gt;&lt;br /&gt;If the operation would take longer than 0.25 seconds to complete, the computer shall clearly indicate that it is processing, and not block the user from performing other tasks while the initial input is being processed.&lt;br /&gt;&lt;br /&gt;This shall be guaranteed, no matter how busy the computer is, no matter if DNS or some other network service hasn't responded, no matter how much the disk drive is being thrashed, how little memory is available, whether you are compiling, or some other USB peripheral has decided to take a while to spin up a disk or generally hang.&lt;br /&gt;&lt;br /&gt;The reason is because my biggest bug bear is devices not responding.  The worst kind of hang is on a slow network.  It drives me absolutely nuts that developers can't anticipate that maybe, just maybe, DNS or something else might get knocked out for a few minutes.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-963583013714389593?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/963583013714389593/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=963583013714389593' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/963583013714389593'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/963583013714389593'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/09/new-user-interface-rule.html' title='New user interface rule'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-356057471112264438</id><published>2007-09-22T10:17:00.000+01:00</published><updated>2007-09-22T10:38:34.870+01:00</updated><title type='text'>A new filing system</title><content type='html'>I was recently reorganising some files, and getting quite annoyed with how difficult even simple filing system tasks are.  It occurs to me that the current filing systems are really badly designed from a user's perspective.  For example&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Knowing where stuff is is a nightmare&lt;/li&gt;&lt;li&gt;Disks get full&lt;/li&gt;&lt;li&gt;Data is always on the wrong disk, never where you need it&lt;/li&gt;&lt;li&gt;You copy to move it about.  The two copies get out of sync.&lt;/li&gt;&lt;li&gt;It's not backed up&lt;/li&gt;&lt;li&gt;It's not securely stored&lt;/li&gt;&lt;li&gt;You need to delete junk occasionally&lt;/li&gt;&lt;li&gt;Data get duplicated, sometimes a lot.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;Of course there are point solutions to all of these problems, but none I could really explain to my mother.  The problem is that files are still presented to the user as they are stored on disk, not how the user uses them.&lt;br /&gt;&lt;br /&gt;I think every data (or file, if you must) should have a URL, e.g. my photos would have a URL&lt;br /&gt;&lt;br /&gt;file://calumgrant/photos/namibia-2007&lt;br /&gt;&lt;br /&gt;Each file, or possibly each folder needs a simple policy, including&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Lifetime: e.g. 1 week, 1 month, 1 year, permanent&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Confidentiality: e.g. me only, work, friends and family etc&lt;/li&gt;&lt;li&gt;Portability: This machine only, This network, internet, mobile device(s)&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;If I plug a new hard disk into my computer, I want it to be used automatically.  I just want to specify whether it's a permanent hard disk or one I take away (and where).  If I specify data as portable, I want the data synced to the right places automatically.  If I decide to remove a hard disk, I want the data to be moved off it automatically.  If I mark stuff as permanent, I want it backed up silently and automatically, perhaps to an ISP or a backup drive.  I want revision control so I (or a virus) cannot trash my data.&lt;br /&gt;&lt;br /&gt;I think we may be entering a new age of usability.  I really hope that users start getting a better deal soon.  Computers should be much more geared towards the way users use data, not how it works underneath.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-356057471112264438?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/356057471112264438/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=356057471112264438' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/356057471112264438'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/356057471112264438'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/09/new-filing-system.html' title='A new filing system'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-4559417270870891036</id><published>2007-08-22T17:51:00.000+01:00</published><updated>2007-08-23T09:47:49.755+01:00</updated><title type='text'>Savaging Adobe's XMP-SDK</title><content type='html'>This is an official "commercial" API/SDK from a very respected company producing "high quality" software.  So far, it has been adequate quality rather than high quality.&lt;br /&gt;&lt;br /&gt;The first problem I encountered was that it isn't GNU friendly, in that it lacked a configure script.  This means I need to go digging in documentation to see how to build it.  Fortunately there was a Visual Studio solution file, and once I had loaded it into VS (and fortunately I had the right version), it built okay.  The use of third-party libraries went pretty smoothly.  The problem is that the documentation is strewn all over the place in a variety of txt, HTML and PDF formats.  What I really need is a step by step idiots guide, not because I am an idiot (I hope), but because I am busy and do not care to understand a new build layout.&lt;br /&gt;&lt;br /&gt;There was also no example code, and no tutorial.  You just get the methods documented.  Both of these would have helped a lot.&lt;br /&gt;&lt;br /&gt;There was a slightly unconventional inclusion of XMP.incl_cpp - a way to get templates to compile.  Not bad, but this information was buried in the documentation (which I am too busy to read), hence I wasted a lot of time.&lt;br /&gt;&lt;br /&gt;I really like a single XMP.hpp file included, but there is include hackery.  This information is also buried in Doxygen comments, and it is pretty ugly to require two macros.  Instead of saying #include &lt;XMPFiles.hpp&gt;, I need to write #define XML_INCLUDE_XMLFILES 1.  Wrong-headed.  I also need to #define WIN_ENV.  I just shouldn't need to do these things.&lt;br /&gt;&lt;br /&gt;You also need to pre-declare TXMP_STRING_TYPE for some reason - which completely negates the benefit of using templates.  I could just write typedef std::string xml_string_type.&lt;br /&gt;&lt;br /&gt;My next issue (due to lack of tutoral) is a strange assertion which I trace back to me not calling TXMPFiles&lt;&gt;::Initialize().  Argh.  This is to initialize global state (which is evil).  I also notice that all types start with a T.  Not a C, a T.  There is no namespace.  Names are in CamelCaps - fine but not C++ standard.  Finally I notice the opportunity for two-phase initialization (or 3-phase, if you consider TXMPFiles&lt;&gt;::Initialize()).  Errors are indicated with return values, not exceptions.&lt;br /&gt;&lt;br /&gt;In conclusion, this is falling into all of the old C++ traps that I would have imagined that modern libraries (and this library has been revamped fairly recently) should have avoided.  It is clearly a C/C++ hybrid.  Commercial software 0, open-source 1.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-4559417270870891036?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/4559417270870891036/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=4559417270870891036' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/4559417270870891036'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/4559417270870891036'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/08/savaging-adobes-xmp-sdk.html' title='Savaging Adobe&apos;s XMP-SDK'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-8236226702738301272</id><published>2007-07-24T23:32:00.000+01:00</published><updated>2007-07-24T23:37:37.094+01:00</updated><title type='text'></title><content type='html'>&lt;span style="font-weight: bold;"&gt;26 ways to write Hello world!&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;In my latest article, &lt;a href="http://calumgrant.net/patterns"&gt;Demystifying design patterns&lt;/a&gt;, I apply some design patterns to the Hello World program.  For beginners this is a useful tutorial in patterns.  For advanced programmers, it is an amusing new look at Hello World.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-8236226702738301272?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/8236226702738301272/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=8236226702738301272' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/8236226702738301272'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/8236226702738301272'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/07/26-ways-to-write-hello-world-in-my.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-5587026181194878175</id><published>2007-07-04T22:39:00.000+01:00</published><updated>2007-07-04T22:41:34.885+01:00</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;&lt;span style="font-weight: bold;"&gt;The 10 commandments of C++&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;1. Thou shalt use an automated build process with no manual steps&lt;br /&gt;2. Thou shalt run automated tests with every build&lt;br /&gt;3. Thou shalt avoid short or cryptic names&lt;br /&gt;4. Thou shalt avoid avoid embedding constants and data within code&lt;br /&gt;5. Thou shalt see when things get too big, and thou shalt split them&lt;br /&gt;6. Thou shalt document every function&lt;br /&gt;7. Thou shalt analyse defects for their root cause&lt;br /&gt;8. Thou shalt use standard containers liberally, and avoid pointers.&lt;br /&gt;9. Thou shalt write exception-neutral code using RAII&lt;br /&gt;10. Thou shalt write for reuse.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-5587026181194878175?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/5587026181194878175/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=5587026181194878175' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/5587026181194878175'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/5587026181194878175'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/07/10-commandments-of-c-1.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-5260965500856236437</id><published>2007-05-29T20:55:00.000+01:00</published><updated>2007-05-29T20:58:18.604+01:00</updated><title type='text'></title><content type='html'>&lt;span style="font-weight: bold;"&gt;C++ Units library&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;I've spent the past week constructing a units library.  I have always wanted to do this.  I am extremely pleased with the result.  Here it is:&lt;br /&gt;&lt;br /&gt;       &lt;a href="http://calumgrant.net/units"&gt;http://calumgrant.net/units&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-5260965500856236437?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/5260965500856236437/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=5260965500856236437' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/5260965500856236437'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/5260965500856236437'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/05/c-units-library-ive-spent-past-week.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-724374273104961039</id><published>2007-01-10T12:10:00.000Z</published><updated>2007-01-10T13:03:12.583Z</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;&lt;span style="font-weight: bold;"&gt;Never use built in types&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This sounds really daft, but it is not.  A lot of programmer errors are caused by confusion about values.  For example, assigning an address to a name.  Was the value in minutes or seconds?  To make matters worse, C++ actually encourages implicit conversion between types, and the programmer needs to go out of his/her way to make constructors explicit to prevent this conversion.&lt;br /&gt;&lt;br /&gt;Another problem is documentation.  If a function takes an "int", there is little clue about the semantics of the value.  The meaning must be elaborated in the function name, parameter name or documentation.&lt;br /&gt;&lt;br /&gt;A large class of error is caused by programmers passing the wrong kind of value.&lt;br /&gt;&lt;br /&gt;Another problem is the premature commitment and viscosity (to use CD terms) of one particular build-in type.  Suppose you write an application to use char, then realise that you really wanted a wchar_t.  You would need to change every instance.  Not a problem but a hassle.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;The solution&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;/span&gt;&lt;/span&gt;You would think that using a typedef would aleviate some of these problems.  e.g.&lt;br /&gt;&lt;blockquote style="font-family: courier new;"&gt;typedef int seconds;&lt;br /&gt;typedef int minutes;&lt;/blockquote&gt;This helps a lot but does not prevent mistakes when converting between the two.  So you create a class&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    class Seconds&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    public:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;        explicit Seconds(int value);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;        int operator*() const;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    };&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This is fine but is a lot of work to introduce a new type.  Instead I propose to tag each value with a type, as follows&lt;br /&gt;&lt;blockquote style="font-family: courier new;"&gt;template&lt;typename&gt;&lt;br /&gt;class tag_t&lt;br /&gt;{&lt;br /&gt;public:&lt;br /&gt;    explicit tag_t(const Prim value &amp;= Prim() ) : m_value(value) { }&lt;br /&gt;    template&lt;typename&gt;&lt;br /&gt;     tag_t(const tag_t&lt;p,tag&gt; &amp;v) : m_value(*t) { }&lt;br /&gt;    const Primitive &amp;operator*() const { return m_value; }   &lt;br /&gt;private:&lt;br /&gt;    Primitive m_value;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;template&lt;typename&gt; tag_t&lt;prim,&gt; tag(const Prim &amp;p)&lt;br /&gt;{&lt;br /&gt;    return tag_t&lt;prim,tag&gt;(p);&lt;br /&gt;}&lt;/blockquote&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Examples&lt;/span&gt;&lt;br /&gt;&lt;blockquote style="font-family: courier new;"&gt;struct SecondsTag; struct MinutesTag;&lt;br /&gt;&lt;br /&gt;void setTime(tag_t&lt;int,minutestag&gt; mins,&lt;br /&gt;    tag_t&lt;int,secondstag&gt; secs);&lt;br /&gt;&lt;br /&gt;setTime(tag&lt;minutestag&gt;(12), tag&lt;secondstag&gt;(0) );&lt;/blockquote&gt;&lt;span style="font-weight: bold;"&gt;Next&lt;/span&gt;&lt;br /&gt;This is turning into a units library.  We should see how we can extend this basic implementation to deal with multiples and conversions.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-724374273104961039?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/724374273104961039/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=724374273104961039' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/724374273104961039'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/724374273104961039'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2007/01/never-use-built-in-types-this-sounds.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-5784002049194156765</id><published>2006-12-09T14:20:00.000Z</published><updated>2006-12-09T14:24:00.644Z</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;&lt;span style="font-weight: bold;"&gt;Software features&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;I am trying a new experiment.  I am trying to create a list of "features" that one of my libraries has.  So I am labelling each feature something like&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    // features.parser.parse_narrow_cstring&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Roughly, each method, class or usage gets a feature.  Normally, each feature requires one unit test, and if a feature has different behaviours requiring different unit tests, then I will subdivide the feature.&lt;br /&gt;&lt;br /&gt;I must also make sure that somewhere in my unit tests, I include&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    // features.parser.parse_narrow_cstring.test&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Hopefully this will give better unit-test coverage, and allow me to document and structure the library better.  It will also allow features to be cross-referenced to code more quickly.&lt;br /&gt;&lt;br /&gt;Hopefully this will make my code better organised.  I shall report on whether it works.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-5784002049194156765?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/5784002049194156765/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=5784002049194156765' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/5784002049194156765'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/5784002049194156765'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/12/software-features-i-am-trying-new.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-4979504390773713796</id><published>2006-12-01T11:57:00.000Z</published><updated>2006-12-01T12:01:57.943Z</updated><title type='text'></title><content type='html'>Free VMWare server&lt;br /&gt;&lt;br /&gt;I was initially really excited to see that this was a free product.  It would solve a lot of my problems.&lt;br /&gt;&lt;br /&gt;Having used it for almost a day (most of this time was spend waiting at an unreponsive computer) I have completely given up.  My computer is completely unusable.  It has 1GB of memory, and my machines were running on a second hard disk, so it should be able to run at least one other OS without causing too much difficulty.  Not only does the emulated OS run quite slowly, but then my *real* machine ground to a halt as well.&lt;br /&gt;&lt;br /&gt;It takes about half an hour to boot Windows Vista.  Every key click takes about a minute to react.  My mouse cursor (on my real OS) hangs.&lt;br /&gt;&lt;br /&gt;This is totally unacceptable.  What a pity I will never use this product again.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-4979504390773713796?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/4979504390773713796/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=4979504390773713796' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/4979504390773713796'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/4979504390773713796'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/12/free-vmware-server-i-was-initially.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-5284520821417454170</id><published>2006-11-30T15:07:00.000Z</published><updated>2006-11-30T15:09:36.570Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='guis'/><title type='text'></title><content type='html'>Customizing user interfaces&lt;br /&gt;&lt;br /&gt;In the same way that resource files are customised on language, they should also be customised on user.  This is almost like theming, except that it really applies to windows text.  For example you would have advanced users who require a minimum of text, and novices where all the buttons are quite verbose.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-5284520821417454170?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/5284520821417454170/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=5284520821417454170' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/5284520821417454170'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/5284520821417454170'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/11/customizing-user-interfaces-in-same-way.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-8746522162529000751</id><published>2006-11-17T16:35:00.000Z</published><updated>2006-11-17T16:38:35.653Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='C++'/><title type='text'></title><content type='html'>Today I came up with something really clever - or so I thought.  I was trying to determine whether one class was derived from another, but not having much luck.  The following solution struck me at 2am last night:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;template&lt;typename&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;class is_derived_from&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;{ &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    typedef char success;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    struct failure { success x[2]; };&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    static failure f(void*);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    static success f(Base*);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;public:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;   static const bool value = sizeof(f((Derived*)0)) == sizeof(success);&lt;br /&gt;};  &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Unfortunately I googled around a bit and there is one place where this has been invented before, almost verbatim.  Darn.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-8746522162529000751?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/8746522162529000751/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=8746522162529000751' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/8746522162529000751'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/8746522162529000751'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/11/today-i-came-up-with-something-really.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-116354166747461694</id><published>2006-11-14T21:50:00.000Z</published><updated>2006-11-14T22:01:07.490Z</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;&lt;span style="font-weight: bold;"&gt;Home server&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;I have recently bought a Linksys NSLU2 for under £60.  This is a networked storage device where you can plug up to two USB hard disks in, and an ethernet cable.  The box can server files via SMB and FTP.&lt;br /&gt;&lt;br /&gt;The fun starts when you install Linux on it.  Some very keen hackers have written instructions on how to "extend" the system by installing your own software on it.  You can upload different firmware which gives you proper telnet access, and there is a package system where people have pre-built a load of software for you to install on it.  The box runs at 266MHz, and the software runs from your hard disk.&lt;br /&gt;&lt;br /&gt;I have a 250GB disk attached, and am running Apache 2, Subversion, OpenSSH and a very nice iTunes server.  This means that my entire music collection is available to all of my networked devices, e.g. iTunes and my Roku wireless media player.  I also have X11 and gcc, and a load of other GNU software.  Coupled with dyndns.org, I can have a webserver with a fixed address.&lt;br /&gt;&lt;br /&gt;This is a very cheap way to set up a home server, and is much cheaper and more satisfying than leaving your computer permanently on.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-116354166747461694?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/116354166747461694/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=116354166747461694' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/116354166747461694'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/116354166747461694'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/11/home-server-i-have-recently-bought.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-116012560670497263</id><published>2006-10-06T09:47:00.000+01:00</published><updated>2006-10-06T10:06:46.716+01:00</updated><title type='text'></title><content type='html'>Staying on-task&lt;br /&gt;&lt;br /&gt;One of the major faults with Microsoft Windows is that you can get interrupted by lots of little Windows popping up.  E.g. if you start an application, it can take a while for it to display, and in the meantime you are busy typing something else.  Then there was the recent example of an anti-virus subscription notice popping up during a Powerpoint presentation.&lt;br /&gt;&lt;br /&gt;This is clearly wrong.  When you are doing something, nothing short of hell or high water should interrupt you.  You should never ever be typing something, then some other window pops up and steals the input focus, and then midsentence you start typing commands into this dialog box which then closes and you feel uneasy that you may have just done something drastic and irreversible.&lt;br /&gt;&lt;br /&gt;Whilst I like Windowing systems, I can't help feeling that most applications really should run full screen, with a notification area on the bottom in case something drastic happens (like you get a new email).  The problem is that the Windows taskbar is cluttered and poorly configurable.  Everything is so noisy and distracting.  Just looking at my screen, I can see 165 different things I can click on, and a lot more if I opened any of the menus.  I want to see nothing but the task I'm on.&lt;br /&gt;&lt;br /&gt;I see the next big thing as being task-oriented user interfaces.  Everything you do will be focused on performing, and guiding you through a task.  This does go slightly against an exploratory approach, however you won't need to do so much exploration if the tasks are set up right.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-116012560670497263?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/116012560670497263/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=116012560670497263' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/116012560670497263'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/116012560670497263'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/10/staying-on-task-one-of-major-faults.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-115945779435726290</id><published>2006-09-28T16:24:00.000+01:00</published><updated>2006-09-28T16:36:34.476+01:00</updated><title type='text'></title><content type='html'>A new VPL based on AOP&lt;br /&gt;&lt;br /&gt;I've been reading about aspect-oriented programming (AOP), and had it explained to me that concerns "cross cut" methods.  Then John put his fingers together in a mesh.  This was a bit of a kerchink moment.  You could create a visual programming language (VPL) in which aspects are displayed on the y axis and methods or functions are displayed on the x axis.  This would show very clearly which functions had which concerns.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-115945779435726290?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/115945779435726290/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=115945779435726290' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115945779435726290'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115945779435726290'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/09/new-vpl-based-on-aop-ive-been-reading.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-115771536082032566</id><published>2006-09-08T10:43:00.000+01:00</published><updated>2006-09-13T18:51:20.890+01:00</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;HCI Considered Harmful?&lt;a href="http://www.cmis.brighton.ac.uk/vlhcc/"&gt;&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;I've just come back from &lt;span style="font-size:100%;"&gt;&lt;a href="http://www.cmis.brighton.ac.uk/vlhcc/"&gt;VL/HCC 2006&lt;/a&gt;&lt;/span&gt; having presented a short paper on  one of my pet projects: &lt;a href="http://visula.org"&gt;Visula&lt;/a&gt;.    &lt;a href="/files/Grant-Visula.pdf"&gt;Here&lt;/a&gt; is the paper, and &lt;a href="/files/VL06-slides.pdf"&gt;here&lt;/a&gt; are the slides.&lt;br /&gt;&lt;br /&gt;Overall it was a very positive experience.  I find the general area interesting - if the conference was a bit cheaper and always in the UK I would want to attend every year.&lt;br /&gt;&lt;br /&gt;What surprised me a lot was the amount of end-user and novice programming.  The papers were roughly divided into spreadsheets, learning through play, visual support for developers, and a little bit of visual parsing.&lt;br /&gt;&lt;br /&gt;One comment is that it is a very applied subject.  Everything follows the same pattern: here is a problem, here is a tool to solve the problem, we gave it to some users, here are the numbers.  This is actually pretty boring!  The field does not seem to have moved on very far.  I think the mass of papers is because everything is done in finiky little steps.  No fundamentally new ideas were presented in the entire conference, and I had no "aha" moments.  Everything had to be proven to be of real benefit to a group of users, which is certainly not blue-sky research.&lt;br /&gt;&lt;br /&gt;A problem I see is that the word "programming" and "software" isn't used in the conventional sense, and I would much rather see the term end-user development or engineering.  I see this as a ploy to place these subjects into computer science where funding is more plentiful, even though this is strictly speaking interdiscpinary with accountancy, [software] engineering, psychology or education.&lt;br /&gt;&lt;br /&gt;I particularly enjoyed was the "how-to" session: how to do research, how to write a paper, how to transfer technology to industry.  The guidelines they gave were completely idiot-proof.  I definitely learned a lot, and wish my PhD supervisor could have told me some of those things.&lt;br /&gt;&lt;br /&gt;The best paper award, by Christopher Hundhausen et al was very good because it fitted the formula well.  It really brought out the questions and hypothesis clearly, its references were complete and had good coverage, data was collected well, strong statistics, and tackled an interesting question.  The work itself was secondary - it was okay I suppose!&lt;br /&gt;&lt;br /&gt;The keynotes Ron Baeker and Thomas Green were top-notch, and my opinion about Thomas Green improved from irritating pedant, to warm, clever, insightful, interesting and entertaining.  Pioneers have a certain charisma and drive that keeps them going for so long - qualities to aspire to.&lt;br /&gt;&lt;br /&gt;In Thomas's keynote he proposed that we should specify almost nothing, since then we don't have the problems with specification.  At first I thought that this was stupid - that surely just leads to ambiguity, and where computers use their intelligence, they get it wrong.  But less specification does not necessarily lead to ambiguity, and computers can indeed outperform humans in many areas to fill in the gaps for us.  An example: typed languages.  Thomas implies that we shouldn't specify types in our programs, we should leave it up to the compiler.  I couldn't agree more!&lt;br /&gt;&lt;br /&gt;Instead I would say "specify as little as possible, but no less".  Whenever we specify anything, it is because the computer can't fill in a gap.  But all too often we tie our hands unnecessarily.  As computers have gotten better (for example at generating machine code), we are able to leave out that part of the specification and work in high level language.&lt;br /&gt;&lt;br /&gt;Often we imagine we really need that extra bit of complexity, when actually we don't.   This is just "less is more".  The more computers can automate, the less we need to specify things on them, until eventually they'll stop plaguing us.  In fact, the thesis should be "HCI considered harmful", and the less interaction with computers we need, the better.  I digress.&lt;br /&gt;&lt;br /&gt;Both of the keynotes actually supported my work - Thomas by suggesting that a stave notation was truly beautiful, and Ron by suggesting that visual programming was a worthy goal.  I clearly need some pictures of vines and horses around my visual programs, on a parchment backdrop.  I think Ron actually said this because he believed that's what we wanted to hear, even though many researchers have given up on the idea as too problematic.&lt;br /&gt;&lt;br /&gt;It was very difficult to get people really engaged about visual programming.  People were always mildly positive and interested in my work, but I met nobody who was passionate.  Talk went well - I always come across a bit nervous at first which is why it is good to make myself talk since I actually enjoy it.  No tough questions - Erwig asked whether the + operator was overspecified since it is symmetric.  My answer is that this was a problem in text as well, which was completely the wrong answer.  The + operator is not symmetric, e.g. on strings.  People were positive that someone was actually working on VP still, and I think people bought my argument that the benefits of sequence diagrams could be transferred into programming.&lt;br /&gt;&lt;br /&gt;If I really wanted to take Visula forward I would have to round-trip to a language like Java.  The problem is that the languages are quite different and it would be like trying to stick a square peg into a round hole.  We shall see.&lt;br /&gt;&lt;br /&gt;My other motive for going to this conference is that I really want to get into spreadsheet "programming".  A friend of mine currently does business modelling on huge spreadsheets, and wants a better way.  Nothing at the conference came close to solving the problem of managing large spreadsheets, so there is definitely an opportunity to develop something.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-115771536082032566?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/115771536082032566/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=115771536082032566' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115771536082032566'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115771536082032566'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/09/hci-considered-harmful-ive-just-come.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-115729557474597485</id><published>2006-09-03T14:13:00.000+01:00</published><updated>2006-09-09T21:27:23.240+01:00</updated><title type='text'></title><content type='html'>Human-centric computing??&lt;br /&gt;&lt;br /&gt;I am now ready to go to the conference (&lt;a href="http://www.cmis.brighton.ac.uk/vlhcc/"&gt;VL/HCC 2006&lt;/a&gt;) and present.  I have managed to squeeze the talk down into 12 minutes.&lt;br /&gt;&lt;br /&gt;I have come to the conclusion that nobody cares about visual programming.  This is evident from the complete lack of implementations.  It was also clear that only one of my reviewers (of the three) knew anything about visual programming at all.  None of them bothered to look at the website or try to use the software.&lt;br /&gt;&lt;br /&gt;To make matters worse, the next conference (&lt;a href="http://vlhcc07.eecs.wsu.edu/"&gt;VL/HCC 2007&lt;/a&gt;) does not even include visual programming or languages on its list of topics at all!  I can clearly see that they will rename the conference to HCC'08 in the future.&lt;br /&gt;&lt;br /&gt;It has been argued that visual programming is more suitable for end-users and novices.  That is fine, except for the problem that most programming in this world is done by experienced programmers.  It depends on what you mean by "programming".&lt;br /&gt;&lt;br /&gt;The VL-part of VL/HCC hasn't happened because the world has so much invested in textual languages.  After a while, people concluded that VPLs don't work.  This is not true, they just haven't been available.  When I set out to create &lt;a href="http://visula.org/"&gt;Visula&lt;/a&gt;, my starting thesis was that it would suck and wouldn't work.  But guess what - with a bit of experimentation I created a system that worked absolutely fine.&lt;br /&gt;&lt;br /&gt;If you think about it, nobody is actually going to create new VPLs.  Final-year project students aren't going to because the task is much too large.  University research projects aren't because researchers aren't usually that experienced at programming, and nobody could get funding for such a project.  Companies aren't going to create VPLs because there is no money in writing new programming languages.  That leaves the open-source community, who do it for the love of it.&lt;br /&gt;&lt;br /&gt;It will be interesting to see if my opinion about human-centric computing goes up or down after this conference.  I will also see if I can meet anybody who actually gives a damn about visual programming.  It was such a hot-topic 10-15 years ago, now where has it gone?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-115729557474597485?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/115729557474597485/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=115729557474597485' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115729557474597485'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115729557474597485'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/09/human-centric-computing-i-am-now-ready.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-115212265856939806</id><published>2006-07-05T19:01:00.000+01:00</published><updated>2006-07-06T09:55:26.016+01:00</updated><title type='text'></title><content type='html'>Classes should be lazy?&lt;br /&gt;&lt;br /&gt;Today my tech lead announced that classes should be lazy.  WTF I hear you cry!  Google for that and you'll find nothing.  I think what he was trying to say is that classes should have clear, well-defined and limited responsibilities.&lt;br /&gt;&lt;br /&gt;I think he means classes should be selfish.  Which means &lt;span style="font-style: italic;"&gt;encapsulated &lt;/span&gt;in English.  &lt;a href="http://www.laputan.org/pub/foote/selfish.pdf"&gt;Here&lt;/a&gt; is an article describing selfish classes, though it is about the only Google hit.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-115212265856939806?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/115212265856939806/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=115212265856939806' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115212265856939806'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115212265856939806'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/07/classes-should-be-lazy-today-my-tech.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-115134090186610908</id><published>2006-06-26T17:46:00.000+01:00</published><updated>2006-06-26T17:55:01.880+01:00</updated><title type='text'></title><content type='html'>Never, ever ever let Microsoft manage your partitions.  I made a fatal mistake of clicking "upgrade volume to dynamic".  Not knowing what the true horrible implications of this was, I foolishly clicked "yes".  No warnings that this was an irreversible process.  Then suddenly had to reboot.  The machine blue-screened first time, until I went into partition manager to fix it.  It now boots fine. &lt;br /&gt;&lt;br /&gt;However the disk is now borked in a proprietary format that I can't do anything with except wipe it and start again.  I can't find the "dmunroot" utility which wipes all other partitions anyway.&lt;br /&gt;&lt;br /&gt;Luckily it is my spare machine, but it will take ages to set up again.&lt;br /&gt;&lt;br /&gt;Microsoft's attitude is "why would anybody wish to downgrade?"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-115134090186610908?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/115134090186610908/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=115134090186610908' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115134090186610908'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115134090186610908'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/06/never-ever-ever-let-microsoft-manage.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-115132517290807441</id><published>2006-06-26T12:11:00.000+01:00</published><updated>2006-06-26T13:32:52.926+01:00</updated><title type='text'></title><content type='html'>A comparison of programming paradigms&lt;br /&gt;&lt;br /&gt;Why is object-oriented programming (OOP) so popular?&lt;br /&gt;&lt;br /&gt;It is often said that OOP "models the real world".  I would argue that this is not true - OOP models the way we &lt;span style="font-weight: bold; font-style: italic;"&gt;think&lt;/span&gt;.  That sounds radical, however the way we perceive the real world is via the way we think, so there is not such a huge difference after all.&lt;br /&gt;&lt;br /&gt;OOP also models natural language.  There are nouns (objects), verbs (methods/functions), adjectives (properties) and adverbs (parameters).  Natural language is also closely related to the way we think.&lt;br /&gt;&lt;br /&gt;Functional programming is more abstract, because although solutions can be more elegant, it does not lend itself quite so naturally to human thought.  People think in terms of concrete things that they can push around, so stateful languages are therefore easier for our brains to manage.&lt;br /&gt;&lt;br /&gt;Logic programming languages are even harder to write complex algorithms in.  The problem as as soon as you have recursion, your head needs to start abstracting again, and it's difficult to visualise too many things at once.  At least with functional programming you have inputs and outputs, which are concrete things - with logic programming you have partially-filled in inputs and outputs and algorithms can frequently be run in reverse.&lt;br /&gt;&lt;br /&gt;For expressing simple problems, logic programming  can express things very nicely, since effectively the program and the data are combined.  Predicates are data that are executable.  However you still need to understand the execution model and backtracking to achieve non-trivial tasks, and this is where logic programming falls down.  For example, implementing a merge-sort algorithm in Prolog (which I have done) is very satisfying but I can't help thinking that it is out of reach for the average programmer.&lt;br /&gt;&lt;br /&gt;For simple, declarative tasks, I don't really consider that to be programming since there are no algorithms involved.  I would not class data transformation as programming (though it is of course an extremely useful activity).&lt;br /&gt;&lt;br /&gt;Imperative styles, do A, do B, do C, are pretty easy for our brains to manage.  Therefore, scripting languages, and procedural languages are pretty popular.  However OOP takes this one step further by creating objects that react to things, rather that data which is operated on by a procedure.  Objects reacting to things is an easier way to think about things since it models our own perceptions of the world.&lt;br /&gt;&lt;br /&gt;I therefore argue that the relative popularity of programming paradigms comes from the ease at which the paradigms can be used, which in turn comes from how natural we find the language.  If you require an IQ &gt; 130 to master a paradigm, perhaps the paradigm isn't so useful after all.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-115132517290807441?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/115132517290807441/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=115132517290807441' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115132517290807441'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115132517290807441'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/06/comparison-of-programming-paradigms.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-115088828694323324</id><published>2006-06-21T12:03:00.000+01:00</published><updated>2006-06-21T12:11:26.953+01:00</updated><title type='text'></title><content type='html'>About a week ago, I was wanting to assert whether a piece of code was running inside a database transaction.  My suggestion to my tech lead was: why not use the type system to ensure we have a transaction object.&lt;br /&gt;&lt;br /&gt;The response from my ever curt tech lead was: we don't need to know that.  Stupid me.&lt;br /&gt;&lt;br /&gt;Today my wonderful tech lead suggested that we use the type system, and looked very proud of himself.  It's nice to know my emails just get ignored.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-115088828694323324?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/115088828694323324/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=115088828694323324' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115088828694323324'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115088828694323324'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/06/about-week-ago-i-was-wanting-to-assert.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-115044988804051263</id><published>2006-06-16T10:08:00.000+01:00</published><updated>2006-06-16T10:24:48.053+01:00</updated><title type='text'></title><content type='html'>Usability?&lt;br /&gt;&lt;br /&gt;I've recently tried  to submit my paper to &lt;a href="http://www.cmis.brighton.ac.uk/vlhcc/"&gt;VL/HCC 2006&lt;/a&gt;.  The good news is that I got a paper accepted, the bad news is that it's only a short paper, the conference is quite expensive and seems to last all week.  So this is larger dent out of my money/holiday budget than I wanted.  Still I've worked on &lt;a href="http://visula.org/"&gt;Visula&lt;/a&gt; for a while (as a background task) so it makes sense to write it up.  On the brighter side, I don't need to talk for so long :-/&lt;br /&gt;&lt;br /&gt;So today is the deadline.  I've been very quiet recently since I've been trying to condense 8 pages into 4, and now it's ready.&lt;br /&gt;&lt;br /&gt;The instructions to submit the paper are long and infathomable.  The login process is protracted.  The links in the page have broken icons.  A link to submit the paper is missing.  An instruction to fix the link is also infathomable and refers to boxes that don't exist.  The upload process is slow and error-prone.  The PDF verification process has a really shitty UI.  After a few attempts, I get my PDF verified.  The submission link just takes me back to the start.  Then this morning, the entire site has crashed due to lack of disk space on the server.  I still have no fricking clue how to submit the paper, I'll randomly click some more when the server comes up.  I emailed the tech support yesterday with no response.&lt;br /&gt;&lt;br /&gt;My next usability hurdle comes when I need to register for the conference.  This website seems nice and clean.  I enter a few details, hit a button and get a blank screen.  Bam.  Nothing.  Try again, same result.  Apparently I should fax a non-existent registration form to a non-existent fax number.&lt;br /&gt;&lt;br /&gt;Now, the irony of the situation is that this conference is concerned with usability and human-centric computing!  Still it's not too late to withdraw...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-115044988804051263?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/115044988804051263/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=115044988804051263' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115044988804051263'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/115044988804051263'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/06/usability-ive-recently-tried-to-submit.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114900366265035790</id><published>2006-05-30T16:38:00.000+01:00</published><updated>2006-05-30T16:41:02.663+01:00</updated><title type='text'></title><content type='html'>This guy is an ass&lt;br /&gt;&lt;br /&gt;Nobody understands this guy when he talks.  He'll make up words and phrases, and say them with such a straight face that you have to believe him.  His designs are incoherent.  He is a maverick.  Because nobody understands what he says, he thinks he is incredibly gifted.  The actual reason nobody understands what he says is because he is an idiot.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114900366265035790?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114900366265035790/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114900366265035790' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114900366265035790'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114900366265035790'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/05/this-guy-is-ass-nobody-understands.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114794340184860380</id><published>2006-05-18T10:02:00.000+01:00</published><updated>2006-05-18T10:10:01.860+01:00</updated><title type='text'></title><content type='html'>Clippy is the worst piece of junk I have ever encountered.&lt;br /&gt;&lt;br /&gt;I asked a simple question: "How do you update all fields in a document?"&lt;br /&gt;&lt;br /&gt;The answers:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Troubleshoot templates and letters&lt;/li&gt;&lt;li&gt;Field codes: Autotext field&lt;/li&gt;&lt;li&gt;None of the above: search for more on the Web&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;That is the most pathetic attempt at help I have ever seen.  I don't want an animated paperclip, I just want to update my fields (which incidentally should happen automatically anyway).  Clippy remains fun for about 2 seconds.  I think given the quality of the answers, he should be replaced by a cripple in a wheelchair - if you could wheel him around the screen I would probably find that more entertaining.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114794340184860380?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114794340184860380/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114794340184860380' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114794340184860380'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114794340184860380'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/05/clippy-is-worst-piece-of-junk-i-have.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114729864835308856</id><published>2006-05-10T22:42:00.000+01:00</published><updated>2006-05-10T23:04:08.370+01:00</updated><title type='text'></title><content type='html'>Trying to move a computer&lt;br /&gt;&lt;br /&gt;We get a new PC.  Hurray!&lt;br /&gt;&lt;br /&gt;The trauma begins.  Endless cycles of downloading updates, and rebooting every 5 minutes.  Have MS still not solved the problem?  Next, trying to copy data from one PC to another.  There's this piece of junk called "File Transfer Wizard".   For some reason, it requres to be installed on removable media - huh?  I have a network thankyou.  Don't have removable media on desktop.  Eventually find an SD card, and an SD card adaptor for the old laptop.  Guess what, the reason we're upgrading is because it is an old piece of junk with not many ports...  Anyway eventually we coax it to running, and eventually we coax it into copying files onto a network share.  For some reason it decides to back up the entire hard disk, including all of the photos on the SD card.  Takes hours and several attempts.  Run the File transfer wizard on new PC.  It refuses to recognise the contents of the share.&lt;br /&gt;&lt;br /&gt;Next step - try to copy the Application data directly.  Works kind-of, except that the length of a filename is exceeded and Windows 98 truncates it.  Can't copy that way.  Download two different zip software, try to zip up the data.  Both result in corrupt ZIP files.  Attempt to export Outlook express data - fails miserably.  Tries to export the data to Outlook on same computer.  Run Outlook, export data from that.&lt;br /&gt;&lt;br /&gt;Now try to copy Outlook data across network.  Win98 decides it's going suddenly and sponteneously fail to browse the network.  It is teasing me with its smug red little computer icon.&lt;br /&gt;Finally, copy onto SD card, copy to other laptop, copy across network, and import.  Success!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114729864835308856?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114729864835308856/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114729864835308856' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114729864835308856'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114729864835308856'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/05/trying-to-move-computer-we-get-new-pc.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114616973636786741</id><published>2006-04-27T20:54:00.000+01:00</published><updated>2006-04-27T21:56:12.036+01:00</updated><title type='text'></title><content type='html'>I don't normally talk about work, but today I had a two fantastic talks.&lt;br /&gt;&lt;br /&gt;The first talk was by Kevlin Henney on test-driven development.  He is a bit of a guru so we were privileged.  Introduction to software process.  He says that waterfall works only for projects of 4 days, and the process simply doesn't scale up.  In fact, Royce's original 1970 "waterfall" paper was precisely that waterfall doesn't work. Kevlin also says that design is an activity, not a phase, and that design is aways ongoing.  A final example doing TDD using assert, to build up a simple most-recently-used class.  We all love TDD.&lt;br /&gt;&lt;br /&gt;The second talk was by a project (no, correction, a programme) manager.  This is how my company manages projects.  Page 5.  A fricking waterfall.  Except that this was Royce's deliberately wrong version of the waterfall with no feedback loops, and no agility. Design was a phase in the waterfall, not an activity.  Well never mind.   Lots of stuff on how to plan and break down tasks.  What the milestones and deliverables are.  Time to play bingo.&lt;br /&gt;&lt;br /&gt;These are the words and phrases uttered during the project planning talk.  I have added a definition to each word for the uninitiated:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;activity&lt;/span&gt; - what people do when they're not attending meetings.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;actuals &lt;/span&gt;- evidence that your developers aren't telling you porkies.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;approval &lt;/span&gt;- when somebody really important nods their head.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;at risk&lt;/span&gt; - we all know that product managers change their minds at least 10 times before deciding that what they originally said was true.  Proceeding under that assumption.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;allocation&lt;/span&gt; - putting developers on blind-dates with activities.  By the time they realise that their activity is a complete dog, it will be too late to back out.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;assumption&lt;/span&gt; - something that will come and bite you for years to come.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;baseline&lt;/span&gt; - a line in the sand, that you can erase and redraw when you think nobody's looking.  Attempting to change something baselined involves a change-control.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;bring the milestone back&lt;/span&gt; - someone walked off with the milestone.  Catch them, and make them do overtime.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;build-cycle&lt;/span&gt; - Something that takes 20 manual steps, which takes 4 attempts to get right, whilst most companies press a button and 4 hours later out pops a CD.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;buy-in&lt;/span&gt; - getting people to agree under false pretences or a big stick.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;call-out&lt;/span&gt; - what a project manager does when you mention slippage.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;change-control&lt;/span&gt; - a speedbump on the motorway of agility.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;concept-phase&lt;/span&gt; - the phase that lasts 50% of the project, because that's the fun bit.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;commit&lt;/span&gt; - apparently, male developers have a particular problem with this word.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;complexity&lt;/span&gt; - if your diagram has enough lines on it, maybe you'll keep ahead of the developers??&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;code-complete&lt;/span&gt; - when all is done and dusted, apart from those 10000 defects logged against another project to not upset the stats too much.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;complete-dat&lt;/span&gt;&lt;span style="font-weight: bold;"&gt;e&lt;/span&gt; - another fictitious date, in a long line of fictitious dates.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;contingency&lt;/span&gt; - a concession that project plans are mostly fiction anyway.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;critical path&lt;/span&gt; - what project managers fantacise about.  This is the really important bit that project managers colour in with a red crayon.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;dangling task&lt;/span&gt; - nobody likes a droopy task.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;dashboard&lt;/span&gt; - the giant pointer of blame in the sky.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;deliverable&lt;/span&gt; - at some point, you need to pull one of these out of your butt.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;dev-team&lt;/span&gt; - the human livestock.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;descope&lt;/span&gt; - when you realise that your eyes are bigger than your stomach, and you have bitten off more than you can chew.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;drum-beat&lt;/span&gt; - what you hear whilst the project managers practise their voodoo.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;driving&lt;/span&gt; - motivating using a large stick.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;earliest date&lt;/span&gt; - in the starry-eyed concept phase, people romanticise about this date.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;estimates&lt;/span&gt; - holding a gun so someone's head and asking them to make up a number.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;factor it in&lt;/span&gt; - something written on a post-it note on the project-manager's monitor.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;feature-complete&lt;/span&gt; - when it's not ready yet.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;firm-up&lt;/span&gt; - make less imprecise.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;focus &lt;/span&gt;- diverting resources from other peoples projects onto your project.  Then motivating them with a big stick.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;framework&lt;/span&gt; - a comfort-blanket for programme managers.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;functional test&lt;/span&gt; - a game of ping-pong between developers and testers.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Gantt chart&lt;/span&gt; - a project manager's autistic little boxes.  Giving something a name means it must work, right?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;highlight&lt;/span&gt; - like Sauron's eye when something slips.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;issue&lt;/span&gt; - a polite way to say "screw-up".&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;issue-management&lt;/span&gt; - herding cats.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;iteration&lt;/span&gt; - because developers can't be trusted to think more than 4 weeks in advance.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;key milestones&lt;/span&gt; - milestones that are less easy to sweep under the rug, but by the magic of shifting, we can anyway.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;level resources&lt;/span&gt; - working people to the bone.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;life-cycle&lt;/span&gt; - Plateaus 1-6 in the XwaterfallX project plan.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;milestone&lt;/span&gt; - something you hide in the closet, that you take out occasionally and laugh about.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;mitigation&lt;/span&gt; - a carefully constructed NMP field.  (NMP = not my problem)&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;move-in&lt;/span&gt; - something your girlfriend wants.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;multitask&lt;/span&gt; - being able to listen to a talk and play bingo at the same time.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;objective&lt;/span&gt; - produce as much paper and go to as many meetings as possible.  Oh, and deliver on time with quality.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;owner&lt;/span&gt; - the shareholders of the company.  Anybody who thinks they are an asset owner is seriously kidding themselves.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;overall risk&lt;/span&gt; - multiply all of the risks together, and you get a 50% overrun.  Hey the maths works even if the project doesn't.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;phase&lt;/span&gt; - a magical entity that happens sequentially and concurrently all at the same time.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;planning&lt;/span&gt; - what project managers love to do almost as much as attending meetings and printing things out.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;programme&lt;/span&gt; - not to be confused with program.  To a project manager, the programme is the deliverable, and the program is a side-effect.  To a developer, it is vice-versa.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;project-level&lt;/span&gt; - something not as important as programme level.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;project-plan document&lt;/span&gt; - it goes without saying, everything needs a document, and this is the one about the project plan.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;project manager&lt;/span&gt; - a wannabe programme manager.  Someone with a laptop and a PDA, and goes to lots of meetings.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;programme manager&lt;/span&gt; - where the real power lies.  At this point, you get a laptop, a PDA, go to lots of meetings AND you get to boss the project managers around.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;project schedule&lt;/span&gt; - the good intentions at the start of your project.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;quality criteria&lt;/span&gt; - a number conveniently chosen to be whatever the quality is on code-complete date.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;replan&lt;/span&gt; - what happens when fiction meets reality.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;rework&lt;/span&gt; - in the rush to complete features in isolated projects, nobody had time to spot the fatal flaw.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;resource-levelling&lt;/span&gt; - working some people to an early grave, whilst others sit around playing darts all day.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;resource-manager&lt;/span&gt; - someone who makes sure people are looking busy.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;risk&lt;/span&gt; - something that might become an issue (hey, I didn't go to a risk workshop for nothing!)&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;risk-register&lt;/span&gt; - a list of things that will eventually go wrong, due to Murphy's law.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;roll-up&lt;/span&gt; - this happens at the end of a phase.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;sandbag&lt;/span&gt; - I really haven't the foggiest on this one, but it's a verb.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;schedule&lt;/span&gt; - like a plan, but more official sounding.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;shifting&lt;/span&gt; - schedule, what schedule?  Re-baseline and hope nobody notices.  E.g. we shifted Huntsman and it came in on time.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;slippage&lt;/span&gt; - golden words to a project manager.  This will result in a flurry of meetings and paper, which is what project managers love doing the most.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;smoke-test&lt;/span&gt; - a beehive analogy.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;staged development&lt;/span&gt; - a process that is so indistinguishable from a waterfall, that people go to great lengths to state that it is not a waterfall.  The lady doth protest too much!&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;system-test&lt;/span&gt; - not a unit-test or a feature-test.  Monkeys pressing buttons at which point peanuts drop from the feeders.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;task&lt;/span&gt; - segmenting up what the little people actually do.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;team-knowledge&lt;/span&gt; - a foreboding of impending doom.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;timescale&lt;/span&gt; - guess what - Einstein says there is no absolute time.  Presumably the project-plan has been travelling at 0.99 times the speed of light relative to the project.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;tolerance&lt;/span&gt; - what project managers begrudgingly have of developers.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;up-front&lt;/span&gt; - anything up-front will need to change unrecognisibly, so it's best not to bother.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;tracking&lt;/span&gt; - if you slip on a project, your project manager will track you to your house and strangle you.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;utilise&lt;/span&gt; - steal from someone else's project.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;visibility&lt;/span&gt; - poking your head above the turret.  Always a mistake.&lt;br /&gt;&lt;br /&gt;And you think techies are bad?!&lt;br /&gt;&lt;br /&gt;P.S. This page is a tribute to our programme manager Sarah Walden who in spite of the jargon is fab!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114616973636786741?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114616973636786741/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114616973636786741' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114616973636786741'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114616973636786741'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/04/i-dont-normally-talk-about-work-but.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114582339646728104</id><published>2006-04-23T21:13:00.000+01:00</published><updated>2006-04-23T21:16:36.483+01:00</updated><title type='text'></title><content type='html'>Wireless routers are ridiculous&lt;br /&gt;&lt;br /&gt;Why can't they just bloody work, instead of spending hours running between rooms, resetting devices, hooking cables in, changing region and security settings.  Windows XP seems determined to hang whilst acquiring the network address - a known bug in WinXP.  The tosser who introduced that bug should get a good kick.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114582339646728104?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114582339646728104/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114582339646728104' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114582339646728104'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114582339646728104'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/04/wireless-routers-are-ridiculous-why.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114580300046050126</id><published>2006-04-23T14:41:00.000+01:00</published><updated>2006-04-23T15:36:40.476+01:00</updated><title type='text'></title><content type='html'>Opaque library&lt;br /&gt;&lt;br /&gt;I've just created a new C++ library called &lt;a href="http://visula.org/opaque"&gt;Opaque&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;This container can store any C++ datatype in its internal buffer, which can be safely copied and destroyed by code that knows nothing about the type of the stored data.&lt;br /&gt;&lt;blockquote&gt;&lt;pre&gt;&lt;br /&gt;opaque x = std::string("Hello"), y=x;&lt;br /&gt;x = 2;&lt;br /&gt;assert(x.type() == typeid(int));&lt;br /&gt;std::string &amp;s = y.get&amp;lt;std::string&amp;gt;();&lt;br /&gt;// etc&lt;br /&gt;&lt;/pre&gt;&lt;/blockquote&gt;&lt;br /&gt;The container is like Boost.Any, except that it uses an internal buffer to avoid heap allocation.  It is similar to Boost.Optional, or Boost.Variant.  &lt;br /&gt;&lt;br /&gt;Another application is an efficient factory.  opaque_ptr is smart "pointer" that can be used to hold derived types. e.g.&lt;br /&gt;&lt;blockquote&gt;&lt;pre&gt;&lt;br /&gt;class X ...&lt;br /&gt;class Y : public X ...&lt;br /&gt;&lt;br /&gt;void factory(opaque_ptr&amp;lt;X&amp;gt; &amp;x)&lt;br /&gt;{&lt;br /&gt;    x = Y();&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;opaque_ptr&amp;lt;X&amp;gt; x;&lt;br /&gt;factory(x);&lt;br /&gt;&lt;/pre&gt;&lt;/blockquote&gt;&lt;br /&gt;It was inspired by Bronek Kozicki's work on &lt;a href="http://b.kozicki.pl/functor/"&gt;typeless functor&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114580300046050126?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114580300046050126/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114580300046050126' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114580300046050126'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114580300046050126'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/04/opaque-library-ive-just-created-new-c.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114555944397586039</id><published>2006-04-20T19:29:00.000+01:00</published><updated>2006-04-20T20:19:03.593+01:00</updated><title type='text'></title><content type='html'>ACCU Conference 2006&lt;br /&gt;Oxford UK&lt;br /&gt;&lt;br /&gt;Thursday 20th April&lt;br /&gt;&lt;br /&gt;Keynote speech&lt;br /&gt;Helen Sharp (Open) - Software development: a social activity with technical practices&lt;br /&gt;&lt;br /&gt;I was pleasantly surprised by this talk, mainly since it's always so refreshing to hear how other people do programming.  The main crux of the talk was that programming is fundamentally a social activity, and that aspect is often overlooked.  Lots of pictures of programmers working together, and communicating, lots of examples of the different types of interactions that programmers made.  Unless you have been living in a box for the past 20 years, this will be nothing new.&lt;br /&gt;&lt;br /&gt;What I found surprising is the broad acceptance of agile methods.  This is how programmers like to program, unfortunately it is not the way I work at work.  Pair programming seemed a lot more common than I have actually seen in practice.&lt;br /&gt;&lt;br /&gt;A history of object-orientation was given.  A study showed that around 1986, there was a huge explosion of interest and papers in a technology that has been around for 20 years.&lt;br /&gt;&lt;br /&gt;The maverick programmer was a very interesting topic.  Apparently it is very common for teams to have an "expert", who basically controls the entire team, and likes to be treated like a god.  Common traits of these people are to hoard knowledge and rarely document, yet they are still capable of being very productive.  Other people dare not do anything for fear of offending of contradicting the maverick.  While the quality of their individual work is good, the effect on the team can be disasterous.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Scott Meyers - When C++ Hits the Hardware&lt;br /&gt;&lt;br /&gt;I was looking forward to seeing a "Guru" talk, and I was not disappointed.  Scott was told to be afraid of the ACCU crowd, and indeed he got more than his fair share of hecklers who really knew embedded programming, better than Scott did.  But that didn't matter.&lt;br /&gt;&lt;br /&gt;Only two topics were covered - and the bias was definitely towards embedded devices, I was surprised that there was nothing on threading and memory issues, both minefields in the desktop/server.&lt;br /&gt;&lt;br /&gt;The first topic was C++ and ROM.  The problem is that the standard makes no promises about what ends up in ROM ("ROMable"), versus what must be in RAM.  The advantage of ROM is that is is cheaper - there are other advantages too, such as lower initalization costs and being able to share the read-only data segment between processes.  A number of examples were given of things that can end up in ROM.  Const data, PODs, and stuff with inline constructors and const members.  Mutable blows it.  It very much depends on the compiler, for example some will ROM structs but not classes.  A "trick" is to collate the const PODs into in a struct, and declare that as a static member of a class, which can coerce the compiler.  Many compiler-generated data structures can be put in ROM.&lt;br /&gt;&lt;br /&gt;The second topic was memory-mapped IO.  This is basically volatile memory that doesn't obey the normal rules of RAM.  The volatile keyword ensures that the compiler won't optimize away redundand reads or writes.  The main example used an enum to reference individual bits, since this is considered more portable that using bit-fields.  A wrapper object was created to manipulate the data.  Various schemes were presented on how to place the object in memory, including placement-new.  Shadow registers were discussed.&lt;br /&gt;&lt;br /&gt;What was perhaps the most important principle was how to make the interface to the memory-mapped IO class robust.  "Design violations should not compile".  The C++ type system was used to wrap addresses, thereby adding a safety check.  The destructor was made private.  Another important realisation was made, that inline keyword is not about improving efficiency (although it does), but about improving abstraction.  Programmers won't be deterred by a performance penalty of adding abstraction.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;David Burggraff (Microsoft) - Win32/WinFX integration&lt;br /&gt;&lt;br /&gt;This was in part a call for everyone to use Windows Vista and CLR.  I has to sit through a little bit of marketing, and then there was a whistlestop tour of programming in the CLR.  Many C++ extensions where shown, and how to combine native and managed code.  Normal C++ can be compiled under CLR and work every time, and then it can interoperate with managed languages and extensions.  Very nice indeed.&lt;br /&gt;&lt;br /&gt;WinFX is the official name for "Avalon".  It is a new UI library which can be specified either in code or in XML.  The XML is capable of expressing complex behaviours.  Tools are capable of designing rich GUIs without code, and can generate the XML.  Some very nice effects are supported, such as layering and alpha-blending.  GUIs produced in WinFX are likely to be much flashier, and easier to write.  &lt;br /&gt;&lt;br /&gt;WinFX interoperates with Win32.  The main part of the talk was to show how easily and seamlessly it was possible to migrate, and mix Win32 code with WinFX and the CLR.  As an example, they rewrote part of Powerpoint using WinFX, and also the Hearts server and client.  The line-count was lowered significantly for Hearts, while improving the visual appearance.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Bronek Kozicki - Typeless functor&lt;br /&gt;The main objective with this is to create a class that can call a function with data, even though we don't know what the type of the function or argument is.  This sounds pretty useful, however no really good examples were given.  Scopeguard was suggested, though I was thinking that event handling (for example as part of a GUI) would be a more realistic example.  The other goal was cheapness - otherwise why not just use a virtual functor.&lt;br /&gt;&lt;br /&gt;Various examples were built up, and there was a lot of staring at code, perhaps too much.  The main principle is to create a static templated function, which we can then take the address of.  We call the static function with data that was packed into a small block of memory allocated inside the typeless functor object.  The major problem with this approach is that it only works for PODs, which in my opinion is too restrictive.  But unless you expose types, there is only so much you can do.&lt;br /&gt;&lt;br /&gt;The main power with the typeless functors was the ability to copy data about, and to access the argument in a typed way by comparing the address of the function, which is a cheap way of doing RTTI.  The number of arguments can be mixed, currently 0 or 1.&lt;br /&gt;&lt;br /&gt;The main drawback with the approach was that it falls in between tr1::function and boost::any.  It only works for PODs, which is hardly modern C++.  The scopeguard example was particularly uncompelling since normal scopeguard implementations just use a reference and can work with any data types whatsoever with no performance penalty.  However the technique of using a reference only works for local scope - you can't copy opaque data.&lt;br /&gt;&lt;br /&gt;Some good comments came out, for example why not initialise the functor with a "null" function, or a policy-based null.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Agile with Offshoring - Panel with Jutta Eckstein and Nico Josuttis&lt;br /&gt;&lt;br /&gt;This was completely unexpected, since the format was a discussion with 5 people in the middle of the room, and people could sit in the main discussion chairs at any time, with the only rule that if one person enters, another must leave.  This was quite a fun way of doing things.  However since I have no experience of offshoring, I did not enter the discussion.  &lt;br /&gt;&lt;br /&gt;The discussion was to try to establish best practises, and understanding, of the combination of two extremely widespread phenomena (at time of writing) - Agile development and Offshoring.&lt;br /&gt;&lt;br /&gt;The main issue was that offshoring has huge communication overheads.  Thus, although there may be gains in terms of reduced salaries, the teams will work much less effectively due to communication problems.  Other problems cited include hugh staff turnovers in offshore companies, and that key developers in the main company spend a lot of time training people up only for them to leave.&lt;br /&gt;&lt;br /&gt;Such difficulties had lead some companies to abandon offshoring completely, once the math had been done.&lt;br /&gt;&lt;br /&gt;It was questioned whether offshoring is at all compatible with agile development.  Agile relies on enhanced communication, something offshoring cannot deliver.  How can one pair with somebody 6000 miles away?  The main issue is trust, since people tend not to trust people they have never met.  Offshoring is a management decision which developers rarely support, while agile is a development decision that managers often don't support without persuasion.&lt;br /&gt;&lt;br /&gt;Agile also involves developers meeting customers, which clearly is not achieved.  If agile cannot work as such distances, should projects be split such that entire projects are taken offshore?&lt;br /&gt;&lt;br /&gt;A large challenge is cultural differences - in some cultures people always claim to understand something, and say they are able to deliver, even though they cannot.&lt;br /&gt;&lt;br /&gt;A point was made that the audience was very biassed - none of us has been developers in developing counties.  Offshore developers feel very used and resentful of their oppressive employers, and it is not surprising since they clearly are being treated as second class.  Overseas developers do not want to be programmers, they want to quickly progress to management, and into better paid jobs.  As soon as they increase their skills, they are out.  Programming is not seen as a career.&lt;br /&gt;&lt;br /&gt;Working relationships are very important, and very difficult to foster at such distance.  Nevertheless it is important to try to make friends.&lt;br /&gt;&lt;br /&gt;There is a conundrum.  Open source software is extremely effective, extremely global, and extremely agile.  Perhaps the main difference is that open-source programmers treat each other as equals.&lt;br /&gt;&lt;br /&gt;There was no real conclusion, other than that offshoring hinders agility.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114555944397586039?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114555944397586039/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114555944397586039' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114555944397586039'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114555944397586039'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/04/accu-conference-2006-oxford-uk.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114388932342578350</id><published>2006-04-01T11:59:00.000+01:00</published><updated>2006-04-01T12:02:03.436+01:00</updated><title type='text'></title><content type='html'>Gotta get me one of &lt;a href="http://www.thinkgeek.com/stuff/41/wec.shtml"&gt;these&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114388932342578350?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114388932342578350/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114388932342578350' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114388932342578350'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114388932342578350'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/04/gotta-get-me-one-of-these.html' title=''/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24116572.post-114241179539703450</id><published>2006-03-15T08:36:00.000Z</published><updated>2006-03-15T08:36:35.406Z</updated><title type='text'>First post</title><content type='html'>Test&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24116572-114241179539703450?l=calum-tech.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://calum-tech.blogspot.com/feeds/114241179539703450/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24116572&amp;postID=114241179539703450' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114241179539703450'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24116572/posts/default/114241179539703450'/><link rel='alternate' type='text/html' href='http://calum-tech.blogspot.com/2006/03/first-post.html' title='First post'/><author><name>Calum Grant</name><uri>http://www.blogger.com/profile/14018363034115110917</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='25' height='32' src='http://visula.org/calum/calum3.JPG'/></author><thr:total>0</thr:total></entry></feed>
