<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>The Jimmo Articles</title>
	<atom:link href="http://www.jimmo.org/mind/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.jimmo.org/mind</link>
	<description>Cogitations, comments and opinions on things that interest me</description>
	<lastBuildDate>Fri, 29 Jul 2011 14:29:44 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Choosing a PC is not so easy!</title>
		<link>http://www.jimmo.org/mind/?p=503</link>
		<comments>http://www.jimmo.org/mind/?p=503#comments</comments>
		<pubDate>Fri, 29 Jul 2011 14:23:20 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[Stupid Computer]]></category>
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=503</guid>
		<description><![CDATA[It&#8217;s funny how marketing is so effective sometimes! Take shopping for a computer as an example.  Most of us will buy a new computer at some point over the next three years (even though most of us think a computer should last longer than that)....]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s funny how marketing is so effective sometimes!</p>
<p>Take shopping for a computer as an example.  Most of us will buy a new computer at some point over the next three years (even though most of us think a computer should last longer than that).</p>
<p>But how do we go about choosing a new PC in the first place?</p>
<p>Take a look around and you&#8217;ll see plenty of ads for computers, whether online or in magazines etc.. They all read like shopping lists of features&#8230;but what does it all mean?</p>
<p>Do you know which of these features you need?</p>
<p>Are you sure? Crucial, the memory manufacturer, did a market research survey and found that roughly half of all surveyed users weren&#8217;t sure how much memory they had in their current machine &#8211; so how can they know how much the need in a new PC?</p>
<p>There&#8217;s an article over at <a href="https://www.trapstone.co.uk/">Trapstone Technologies</a> that goes into more detail on <a href="https://www.trapstone.co.uk/which_pc_choosing_a_computer/">how to choose a computer</a>.</p>
<p>Check it out!</p>
<p>https://www.trapstone.co.uk/which_pc_choosing_a_computer/</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=503</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Why I voted &#8220;no&#8221; to the alternative vote</title>
		<link>http://www.jimmo.org/mind/?p=493</link>
		<comments>http://www.jimmo.org/mind/?p=493#comments</comments>
		<pubDate>Fri, 06 May 2011 20:29:56 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[Society]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=493</guid>
		<description><![CDATA[I voted &#8220;no&#8221; in the referendum on the alternative vote. Am I a staunch fan of the first past the post system? No. It&#8217;s simply that I had some concerns about the practicalities of the alternative vote system and I found the arguments from the...]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.jimmo.org/mind/wp-content/uploads/2011/05/wivnav.jpg" alt="" /></p>
<p>
I voted &#8220;no&#8221; in the referendum on the alternative vote. Am I a staunch fan of the first past the post system?  No.  It&#8217;s simply that I had some concerns about the practicalities of the alternative vote system and I found the arguments from the &#8220;yes&#8221; campaign fell short of convincing.
</p>
<h3>The &#8220;stack rank&#8221; fallacy</h3>
<p>
I believe there are fundamental problems in trying to stack-rank candidates in order of preference. Election candidates are rarely on a spectrum of preference like, say, choosing from a selection of holiday destinations or which house to buy.
</p>
<p>You see, when you choose a holiday, or a house, or a business strategy &#8211; all the choices are fundamentally aligned with your primary objective &#8211; going on holiday, owning a home or growing your business.  There may be pros and cons to the various choices; differences in challenges and costs&#8230;and these factor in to how you weigh up the options and mentally order them by preference.
</p>
<p>
With political candidates, it&#8217;s just not that simple. Candidates and parties are keen to establish clear blue water between their respective positions. Your desired outcome is to elect the candidate who most aligns with you &#8211; what you think is best for society and the country. Differences in the candidates&#8217; policies and ideological world views mean that I, for one, struggle to align with many of them enough to give them my vote.  Simply put, <b>there is no candidate stack rank</b>.  You either have my vote or you don&#8217;t.
</p>
<h3>The &#8220;make politicians work harder&#8221; fallacy</h3>
<p>
One of the primary arguments from the &#8220;yes&#8221; campaign was that AV would somehow make politicians work harder to be higher up your stack rank of preferences.  Let&#8217;s think about this for a moment.
</p>
<p>Are they really trying to imply that your local politician hasn&#8217;t been pulling their weight and that they&#8217;ve not been working hard enough?  No &#8211; in a nutshell, this means they have to broaden their appeal to as much of the electorate as possible.  This in turn means closing the gaps between themselves and their opposition, so that they can try and pick up some alternative votes from supporters of the opposition.
</p>
<p>
I question the integrity of this. Is a politician sincerely representing what they believe when they court my alternative vote?  Or is it just a cosmetic facade?  How can they seek to maintain such orthogonal positions from opposing candidates prior to AV, yet successfully broaden the appeal of their policies post AV with integrity and credibility?  I&#8217;m not sure.  I&#8217;m not saying they can&#8217;t but the &#8220;yes&#8221; campaign failed to reassure me on this point.
</p>
<h3>AV is vulnerable to the partisan nature of politics</h3>
<p>
People tend to be passionate about their political beliefs and equally passionate in their dislike of opposing political beliefs.  Consider a constituency where there isn&#8217;t an outright majority for any one party and we have the AV system.  All the Conservative voters will vote for the Conservative candidate and will want &#8220;anyone but Labour&#8221; to get in.  All the Labour voters will vote for the Labour candidate and, similarly, will want &#8220;anyone but the Tories&#8221; to get in.  Now where will their alternative votes go?  Who mops up and wins the constituency?
</p>
<p>
I can see that the Liberal Democrats would do extremely well in this hypothetical scenario but, whoever wins out, would it really be an accurate reflection of the will of the people?  Would the winning candidate really be aligned with the majority, or would they only win a war of attrition &#8211; to be the &#8220;anyone but X&#8221; victor?  I&#8217;m not sure I want a system like that.
</p>
<p>
For these reasons and because the &#8220;yes&#8221; campaign failed to address them, I voted &#8220;no&#8221; to the alternative vote.
</p>
<p>
Now, if one day there&#8217;s a referendum for FPTP vs. PR, that&#8217;ll be another story&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=493</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Pope &#8211; A Very Fallible Anachronism</title>
		<link>http://www.jimmo.org/mind/?p=483</link>
		<comments>http://www.jimmo.org/mind/?p=483#comments</comments>
		<pubDate>Fri, 17 Sep 2010 09:30:59 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[Atheism]]></category>
		<category><![CDATA[Reason]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=483</guid>
		<description><![CDATA[Oh the Pope is most definitely fallible! I was disheartened, if not surprised, by his comments on secularism in society and I can only hope they serve to highlight the sheer anachronism that religious dogma has become in the modern world. Overall, I was largely...]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.jimmo.org/mind/wp-content/uploads/2010/09/pope.jpg"><img src="http://www.jimmo.org/mind/wp-content/uploads/2010/09/pope.jpg" alt="Do as I say, not as I do!" title="pope" width="630" height="250" class="aligncenter size-full wp-image-484" /></a><br />
Oh the Pope is most definitely fallible! I was disheartened, if not surprised, by his comments on secularism in society and I can only hope they serve to highlight the sheer anachronism that religious dogma has become in the modern world.</p>
<p>Overall, I was largely indifferent to the visit of the Pope to the United Kingdom this week.  One of his ill-advised &#8220;advisors&#8221;, one Cardinal Walter Kasper, caught my eye when he likened the UK to a <a href="http://www.bbc.co.uk/news/uk-11317441">third world country marked by a new, aggressive atheism</a>.  Well, the former is simply stupid and the latter isn&#8217;t really true either &#8230; at least not in terms of aggression.  I think that religion is becoming less relevant to people generally, I&#8217;d like to think that was because knowledge and understanding is defeating superstition but either way, its fine by me.</p>
<p>The Pope&#8217;s own comments on atheism are deceitfully disingenuous, if not flagrantly misrepresentative.  To whit&#8230;</p>
<blockquote><p>&#8220;Even in our own lifetimes we can recall how Britain and her leaders stood against a Nazi tyranny that wished to eradicate God from society and denied our common humanity to many, especially the Jews, who were thought unfit to live.</p>
<p>&#8220;As we reflect on the sobering lessons of atheist extremism of the 20th century, let us never forget how the exclusion of God, religion and virtue from public life leads ultimately to a truncated vision of man and of society and thus a reductive vision of a person and his destiny.&#8221;</p></blockquote>
<p>Is this <a href="http://en.wikipedia.org/wiki/Godwin%27s_law">Godwin&#8217;s Law</a> in action? The deeds of the Nazis had nothing to do with atheism.  Indeed the relationship between Nazism and religion per se isn&#8217;t entirely clear (nor is the oft quoted yet unsubstantiated claim that Hitler was an atheist&#8230;that&#8217;s far from proven). Besides, history both ancient and modern is replete with bloody conflict under the banner of religion.</p>
<p>He also goes on to call for the re-establishment of christian principles in society and government. I see no reason why the running of the state needs to be influenced or centered around any particular religion, any more than public policy should be ethno-centric.  Furthermore, its hardly true that atheists are trying to coerce people into abandoning their faith.  I don&#8217;t ever recall an atheist knocking on my door asking to talk about the absence of a god.  A lengthy critique of the church and catholicism in general is not necessary to highlight the obvious hypocrisy here!</p>
<p>Its true there are some &#8220;evangelical atheists&#8221; like Professor Richard Dawkins out there, although this is a reaction to evangelical theism.  Personally, I align with Jonathan Miller who I heard say that &#8220;my belief in god is as trivial to me as my belief in witches&#8221; (quote from memory, may not be verbatim).</p>
<p>So in a nutshell&#8230; I don&#8217;t care what you believe and I completely support your right to follow your own faith as a personal and private matter.  But if you try to foist your world-view on me, whether by direct pressure or surreptitiously through the state, I will fight you tooth and nail!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=483</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Spam is not an effective e-marketing strategy!</title>
		<link>http://www.jimmo.org/mind/?p=442</link>
		<comments>http://www.jimmo.org/mind/?p=442#comments</comments>
		<pubDate>Tue, 27 Jul 2010 10:15:28 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=442</guid>
		<description><![CDATA[Thinking of embarking on an electronic mailing campaign? Be very careful which distribution list you use!]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.jimmo.org/mind/wp-content/uploads/2010/07/fhudsonk.jpg" alt="" title="fhudsonk" width="630" height="250" class="aligncenter size-full wp-image-447" /><br />
When a self-titled &#8220;award winning entrepreneur&#8221; sends you unsolicited marketing email (otherwise known as spam), one has to assume that none of those awards were for e-marketing.  If you&#8217;re trying the electronic equivalent of a mail shot, you really need to be sure that the distribution list you use contains well-qualified addresses of people who have actually subscribed, or registered an interest, in these communications&#8230;and those sorts of list cost money!</p>
<p>Today I received one such unsolicited email from someone called <b>Fiona Hudson-Kelly</b>.  In this spam, she describes herself as an &#8220;award winning entrepreneur&#8221; offering to train folks on modern marketing tools, including email campaigns.  Naturally, this spam includes an &#8220;unsubscribe&#8221; link, despite never having subscribed.  I know this because (a) I never subscribe to any such list and (b) the address I received it on wouldn&#8217;t be used for any such purpose.  In other words, it was a spammers list of trawled email addresses.</p>
<p>Here&#8217;s an excerpt&#8230;</p>
<blockquote><p><i>The internet has changed the way in which we reach clients, have you brought your marketing techniques up to date to make the most of these new opportunities? You can now send out an e-mail campaign and watch to see who opens your e-mails and who visits xxx web site, you can then use other marketing methods to reach these people including telemarketing which is very targeted or direct mail to those who have shown an interest.</i></p></blockquote>
<p>Oh, the irony!  An example of how not to conduct an e-mail campaign right there &#8211; for free!  Their website, at the time of writing, was broken and a google for their name pulls up a load of self-referential hits but little from any 3rd party, aside from a couple of other folks pointing out the foot-in-mouth nature of spamming folks while claiming to be in a position to train budding entrepreneurs on e-marketing!  Her twitter and LinkedIn pages are also incongruously light for someone who so blatantly lauds their own status.</p>
<p>The lesson is simple. <b>DO NOT SPAM POTENTIAL CUSTOMERS!</b>  Nothing damages your credibility more.  If you want to drum up a business training junior entrepreneurs or consulting on small businesses, then do it properly with a well-constructed site and appropriate links/materials in electronic and paper press.  (Google Chris Cardell for an example of someone who does a much better job of getting people to opt-in, although getting <b>off</b> his mailing list seems to be nigh on impossible).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=442</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Homosexuals granted right to apply for asylum</title>
		<link>http://www.jimmo.org/mind/?p=439</link>
		<comments>http://www.jimmo.org/mind/?p=439#comments</comments>
		<pubDate>Wed, 07 Jul 2010 13:11:38 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[Society]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=439</guid>
		<description><![CDATA[The Supreme Court in the UK has today ruled that one can apply for asylum on the basis of persecution for having a non-heterosexual orientation. In this specific case, two men had previously been refused asylum on the basis that they could effectively live &#8220;in...]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.jimmo.org/mind/wp-content/uploads/2010/07/asylum.jpg" alt="" title="asylum" width="630" height="250" class="aligncenter size-full wp-image-438" /><br />
The Supreme Court in the UK has today ruled that one can apply for asylum on the basis of persecution for having a non-heterosexual orientation. In this specific case, two men had previously been refused asylum on the basis that they could effectively live &#8220;in the closet&#8221; in their home countries to avoid persecution.  You can read more about it in this <a href="http://news.bbc.co.uk/1/hi/uk/10180564.stm">BBC news article</a>.</p>
<p>Sadly, homophobia is still all too prevalent in the world &#8211; even now, in the 21st century.  Worse still, there are homophobic states that have institutionalized prejudice against non-heterosexuals, which can include prison sentences or even execution!  As a civilized nation, I believe it is absolutely correct that we should protect people from such persecution as a point of principle.</p>
<p>However, there are some other issues here that are beyond that simple point of principle.  Firstly, the individuals in question had to cross a lot of other countries to get to the United Kingdom, some of whom are also signatories to the Refugee Convention and are &#8220;liberal European states&#8221;.  Why is it that one has to come all the way to the UK specifically to file such a claim for asylum, I wonder?</p>
<p>Secondly, I think more diplomatic pressures need to be applied to such homophobic countries (with a zero-tolerance policy at home) because there are a huge number of non-heterosexual folk out there and asylum isn&#8217;t the long term solution!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=439</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Alpha Course poll says there is no god</title>
		<link>http://www.jimmo.org/mind/?p=425</link>
		<comments>http://www.jimmo.org/mind/?p=425#comments</comments>
		<pubDate>Sat, 24 Oct 2009 07:11:00 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[Atheism]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=425</guid>
		<description><![CDATA[A Christianity activist group called the Alpha Course has been running an online poll to determine what proportion of those taking the poll believe in god or not. The poll was rather cynically loaded by having two positive options (&#8220;yes&#8221; and &#8220;probably&#8221;, the latter of...]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.jimmo.org/mind/wp-content/uploads/2009/10/alphapoll.png" alt="" title="alphapoll" width="630" height="250" class="aligncenter size-full wp-image-424" /><br />
A Christianity activist group called the <a href="http://uk.alpha.org/">Alpha Course</a> has been running an online poll to determine what proportion of those taking the poll believe in god or not.  The poll was rather cynically loaded by having two positive options (&#8220;yes&#8221; and &#8220;probably&#8221;, the latter of which is intended to capture as many &#8220;maybe&#8221; votes as possible) and one negative option (&#8220;no&#8221;).  Naturally, if this had worked the way the Alpha Course intended, they would be crowing about how only x-percent did not believe in god, etc..</p>
<p>
Unfortunately for the Alpha Course, their assumption that the majority view aligned with theirs was spectacularly blown out of the water by the poll result which &#8211; at the time of writing &#8211; shows that 97% of respondents think there is no god.</p>
<p>
Naturally, their response to this was that the poll result must have been rigged by a coordinated campaign to skew the results with the Alpha Course spokesman, Mark Elsdon-Dew, going on to say that <i>&#8220;I don&#8217;t think this is indicative of people&#8217;s faith in this country&#8221;</i>.</p>
<p>
Well, yes &#8211; it is possible for any online poll as superficially implemented as this one to be deliberately skewed (let&#8217;s not forget the skewing factor of the loaded poll options, by the way).</p>
<p>
On the other hand, it&#8217;s also possible that the general result is correct &#8211; even if you allow a fat margin of error for deliberate skewing votes, the results are so polarized that one would still end up with a negative majority.</p>
<p>
If nothing else, this is a great example of confirmation bias &#8211; if the result agreed with their own beliefs, it would be lauded as a vindication.  Now that it&#8217;s overwhelmingly contrary to their beliefs, it just <i>has</i> to be a deliberately skewed result that doesn&#8217;t represent the &#8220;true&#8221; sentiment.</p>
<p>
Statistical research and analysis needs to be conducted with exacting discipline. One of the reasons why statistics are so notoriously unreliable is because they are, more often than not, gathered by people who just don&#8217;t know what they&#8217;re doing!  Without truly understanding the science of statistics, it&#8217;s all too easy to bias or misinterpret the outcome (deliberately or inadvertently).</p>
<p>
As for this fatuous poll by the Alpha Course, well&#8230;they only have themselves to blame <img src='http://www.jimmo.org/mind/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=425</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Extortionate immigration fees &amp; gratuitous hurdles</title>
		<link>http://www.jimmo.org/mind/?p=410</link>
		<comments>http://www.jimmo.org/mind/?p=410#comments</comments>
		<pubDate>Wed, 16 Sep 2009 10:32:23 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[Society]]></category>
		<category><![CDATA[citizenship test]]></category>
		<category><![CDATA[ILR]]></category>
		<category><![CDATA[immigration]]></category>
		<category><![CDATA[life in the UK]]></category>
		<category><![CDATA[visa]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=410</guid>
		<description><![CDATA[I&#8217;m extremely annoyed that legitimate immigrants are financially penalized and gratuitously impeded while illegal immigrants can take advantage of free support and representation via legal aid etc.. One of my staff, a hard working professional who pays all her taxes, is married to a United...]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.jimmo.org/mind/wp-content/uploads/2009/09/ukba.png" alt="" title="ukba" width="700" height="300" class="aligncenter size-full wp-image-416" /><br />
I&#8217;m extremely annoyed that legitimate immigrants are financially penalized and gratuitously impeded while illegal immigrants can take advantage of free support and representation via legal aid etc..</p>
<p>One of my staff, a hard working professional who pays all her taxes, is married to a United Kingdom citizen.  In addition to the hundreds of pounds spent getting her marriage visa, they are now forced to pay a whopping <b>&pound;820</b> for an <i>Indefinite Leave to Remain</i>, which allows her to reside indefinitely within the UK.  This seems to be an extortionate fee for what should be mostly a routine bit of paperwork, especially after all the due diligence has already been done for the granting of the original marriage visa <i>and</i> subsequent &#8220;certificate of approval&#8221; that one also needs to apply for before the marriage.</p>
<h4>Gratuitous memory test</h4>
<p>Another prerequisite, in addition to this fee, is that she passes the <a href="http://www.lifeintheuktest.gov.uk/htmlsite/index.html">Life in the UK</a> &#8220;citizenship&#8221; test. This, of course, cost an additional fee which is currently <b>&pound;33.28</b>.</p>
<p>I find it quite reasonable to ensure that people who seek to reside indefinitely in the UK have a sufficient command of the local language to get by, together with a reasonable level of understanding about the country.  However, the test comprises of questions that very, very few native born British citizens can answer &#8211; certainly not to the required 75% pass mark (including myself and every one of the degree educated IT professionals in my office).  For example:</p>
<p><b><i>Why did the Huguenots come to Britain in the 16th and 17th centuries?</p>
<p>In which year did 18 year olds get the right to vote?</p>
<p>When did Britain join the European Economic Community?</i></b></p>
<p>What the hell do these questions have to do with living in the UK as a regular, normal citizen? Perhaps next time I&#8217;m in the bank or supermarket they will refuse to serve me?  I can see ATM&#8217;s flashing questions up like &#8220;Trivial Pursuit&#8221; quiz machines&#8230;</p>
<div align="center"><img src="http://www.jimmo.org/mind/wp-content/uploads/2009/09/atmtest.jpg"></div>
<p>I mean, come on!  Who really needs to know stuff like this to go about their daily business?  I find this entire test to be nothing but a revenue generating obstacle which is both cynical and discriminatory.  For shame!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=410</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Should I use a physical or virtual memory model?</title>
		<link>http://www.jimmo.org/mind/?p=387</link>
		<comments>http://www.jimmo.org/mind/?p=387#comments</comments>
		<pubDate>Wed, 09 Sep 2009 05:26:12 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[OS Development]]></category>
		<category><![CDATA[memory]]></category>
		<category><![CDATA[OS development]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=387</guid>
		<description><![CDATA[One of the most important considerations for your OS kernel is memory management. For all but the very simplest of environments, your kernel is going to need memory allocation and deallocation (free) facilities. This, of course, means carving off a &#8220;chunk&#8221; of memory each time...]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.jimmo.org/mind/wp-content/uploads/2009/09/ddpov.jpg" alt="" title="ddpov" width="700" height="300" class="alignnone size-full wp-image-408" /><br />
One of the most important considerations for your OS kernel is memory management. For all but the very simplest of environments, your kernel is going to need memory allocation and deallocation (free) facilities.  This, of course, means carving off a &#8220;chunk&#8221; of memory each time somebody asks for some and managing it when they give it back.  You also have the small, circular problem of allocating memory to hold the data structures your memory allocator needs to manage the memory it&#8217;s allocating!</p>
<p>Before we even get there, we have a more fundamental consideration.  From whence does this memory come and how do we manage <b>that</b>?  Well, the system has an amount of physical memory and the simplest model is to use it &#8220;as is&#8221; &#8211; which of course means referring to that memory via its physical addresses.</p>
<p>While this makes memory management a little easier, it causes some other complications for our OS.  For starters, if we&#8217;re using physical addresses then we&#8217;re going to be constrained by the amount of physical memory installed in the system at run time. This might not seem like much of a problem at first, as pretty much every machine will have at least 4 MB and that&#8217;s plenty of space for a simple, toy kernel &#8211; and if you use <a href="http://www.gnu.org/software/grub/">GRUB</a> to boot your kernel, you&#8217;ll probably end up loaded on the 1 megabyte boundary (physical address <code>0x100000</code>) in a 32-bit &#8220;flat&#8221; protected mode.</p>
<p>However, having your hand up the skirt of the boot loader and making a load of assumptions about your environment isn&#8217;t wise.  In the case of multiboot compliant boot loaders like GRUB, the <a href="http://www.gnu.org/software/grub/manual/multiboot/html_node/index.html">multiboot specification</a> doesn&#8217;t define your load address, or even a valid stack pointer, as part of the specification which means that these are officially <b>undefined</b> and you should write your code accordingly!</p>
<p>If we can&#8217;t be sure what our addresses will be, we&#8217;ll have to write code that is position independent. This is fine for loadable modules but might be a bit of a hassle if the entire kernel has to be this way.</p>
<p>Moreover, you may want to have more flexibility about how the memory address space appears to your kernel and, if you implement it, user land &#8211; it can be helpful to be able to reference a contiguous address space.  This becomes much more important if you want to take advantage of other &#8220;virtual memory&#8221; features like extending the amount of apparent available memory by paging between memory and disk.</p>
<h3>So virtual memory is the way to go?</h3>
<p>Well, not necessarily. Mainstream operating systems that are &#8220;general purpose&#8221; or intended to be used across platforms of varying configurations typically need to implement virtual memory to provide a consistent, generic environment between systems.  However, operating systems intended for very specific hardware architectures and/or embedded systems don&#8217;t always need this degree of flexibility.</p>
<p>Now let&#8217;s be honest &#8211; whatever lofty goals we have in mind, the reality is that the vast majority of &#8220;hobby operating systems&#8221; will never be that widely used and indeed, most will never make it further than your own eyeballs.  Do you really need a full virtual memory implementation?  You could just muddle on with physical memory only or, if the architecture supports it, use segmentation.</p>
<p>However, both of those approaches also have their disadvantages and besides, writing a toy kernel is as much a <i>learning exercise</i> as anything else &#8211; so for most of the other articles in the <b>OS Development/Memory</b> section, I&#8217;m going to assume you <i>do</i> want to implement a page-based virtual memory management system.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=387</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Atheism and morality</title>
		<link>http://www.jimmo.org/mind/?p=315</link>
		<comments>http://www.jimmo.org/mind/?p=315#comments</comments>
		<pubDate>Sun, 06 Sep 2009 09:08:00 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[Atheism]]></category>
		<category><![CDATA[morality]]></category>
		<category><![CDATA[Reason]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=315</guid>
		<description><![CDATA[Those who are antipathetic to atheism sometimes assert that atheists are inherently immoral, as morality is derived from God via scripture and therefore a rejection of religion denies the atheist from that moral frame of reference. It&#8217;s particularly important to debunk this argument because it...]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.jimmo.org/mind/wp-content/uploads/2009/09/amoral.png" alt="" title="amoral" width="700" height="300" class="alignleft size-full wp-image-325" /><br />
Those who are antipathetic to atheism sometimes assert that atheists are inherently immoral, as morality is derived from God via scripture and therefore a rejection of religion denies the atheist from that moral frame of reference.</p>
<p>It&#8217;s particularly important to debunk this argument because it cynically attempts to impugn the character of atheists as a form of &#8220;straw man&#8221; argument, to distract from the pivotal issue of the existence of God (and, in some militant cases, to try and intimidate others who might be questioning their faith).</p>
<p>There are some fundamental flaws to the argument that atheists must, by definition, be amoral.  The first is the assertion that morality is derived from God via scripture, as this as an objective morality.  The notion of an objective morality is philosophically questionable, as we know that moral viewpoints have shifted and evolved over the years. What society once viewed as morally acceptable is not necessarily so today.  Even then, we can see differences in moral outlooks between countries and cultures in the present day.  Almost every major conflict in the world today is between parties who each believe they have the moral high ground (whether we agree with them or not).  Few consciously take a contrary view out of malice aforethought.</p>
<p>The usual response to this is that the God&#8217;s morality, as described in scripture, is not the same as human morality; it is divine and absolute. This falls immediately foul of another problem, which is that scripture contains some things that most of us (religious or not) would not consider morally acceptable today.  This is unsurprising as human morality changes over time&#8230;but this is conflict with the assertion that it&#8217;s origins are from divine morality.  How does one square that circle?</p>
<p>Ah, well, we&#8217;re told that due to its age, scripture cannot be interpreted literally, it needs to be contextualized for a modern setting.  Once again, we run into a fundamental problem because if our morality is founded on these religious sources, how can we re-interpret these dictates except by drawing on an <i>external</i> moral frame of reference?  We&#8217;re forced to conclude that our morality cannot originate solely from the teachings of scripture and hence the argument crumbles.</p>
<h4>Infamous baby-eating, mass-murdering despots were all atheist</h4>
<p>Let&#8217;s now turn to another facet of the amoral atheist argument, which seeks to substantiate the position by asserting that one or more infamous villains from history was atheist (Hitler, Stalin, Pol Pot, etc.).  This isn&#8217;t even true in most cases. Hitler, for example, <a href="http://en.wikipedia.org/wiki/Adolf_Hitler%27s_religious_beliefs">was not an atheist</a> and most white supremacists, particularly in the US, are most certainly <b>not</b> atheist. Further, many of the cited communist leaders opposed religion not on atheistic grounds but because organized religion was perceived as a threat to the state&#8217;s power monopoly.</p>
<p>Leaving aside the factual uncertainty over the religious beliefs of the specified villain, this is a simple logical fallacy &#8211; correlation does not imply causation.  That&#8217;s like asserting that because cost serial killers are white, most white people are potential serial killers!  Trait based generalizations are almost guaranteed to be flawed.  Besides, even if one of these historical villains were atheist, they were not carrying out their heinous deeds in the name of atheism (unlike, I might point out, some atrocities carried out under the banner of religion).</p>
<h4>Atheism is unrelated to morality</h4>
<p>In conclusion, the argument that atheism engenders immorality is founded on entirely groundless assumptions and a number of logical fallacies.  It really carries no intellectual weight whatsoever.  I propose that this argument is so popular simply because it aligns with the proponents world view and hence confirmation bias prevents them from questioning it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=315</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Identifying installed floppy drives</title>
		<link>http://www.jimmo.org/mind/?p=265</link>
		<comments>http://www.jimmo.org/mind/?p=265#comments</comments>
		<pubDate>Fri, 04 Sep 2009 15:28:55 +0000</pubDate>
		<dc:creator>Jimmo</dc:creator>
				<category><![CDATA[floppy]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[OS development]]></category>

		<guid isPermaLink="false">http://www.jimmo.org/mind/?p=265</guid>
		<description><![CDATA[If you&#8217;re implementing support for floppy drive controllers in your hobby OS kernel, then one of your first tasks is to identify what floppy drives are installed in the system. This is pretty easy to do, as we can interrogate the system configuration to find...]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.jimmo.org/mind/wp-content/uploads/2009/09/fdident.png" alt="" title="fdident" width="700" height="300" class="alignleft size-full wp-image-266" /><br />
If you&#8217;re implementing support for floppy drive controllers in your hobby OS kernel, then one of your first tasks is to identify what floppy drives are installed in the system.  This is pretty easy to do, as we can interrogate the system configuration to find out.</p>
<p>The PC architecture has a little battery-backed memory chip called the CMOS (which stands for &#8220;Complimentary Metal Oxide Semiconductor&#8221; if you really want to know). This old bit of kit was originally only used as a bit of clock/calendar logic but had extra space which subsequently got used for storing system configuration information&#8230;and so it remains today. Part of the information retained in the CMOS are the floppy drive types of the first two drives (if they&#8217;re installed) and this is located at offset <code>0x10</code> of the CMOS memory space.</p>
<div class="codediv" style="font-size:75%"><strong>Digression:</strong></p>
<p><em>In fact, there&#8217;s an &#8220;equipment&#8221; byte at offset <code>0x14</code> which includes a bit field for representing the existence (but not type) of up to 4 floppy drives.  However, the equipment byte wasn&#8217;t universally used the same way by all manufacturers.  Besides, we&#8217;d still need to know what <strong>type</strong> they are, so just knowing they are there is not sufficient.  In reality, particularly these days, it&#8217;s extremely unlikely that there&#8217;ll be more than two so that&#8217;s all I&#8217;m going to bother supporting here.</em></div>
<p>To read the CMOS, we write the CMOS byte address into I/O port <code>0x70</code> and read the result byte back from I/O port <code>0x71</code>.  This means we can get the floppy drive type codes from the CMOS as follows&#8230;</p>
<div class="codediv">uint8_t b;</p>
<p>outportb(0&#215;70, 0&#215;10);<br />
b = inportb(0&#215;71);</p></div>
<p>The resultant byte is encoded in two identical halves.  The upper 4 bits identify the first drive (drive 0) and the lower 4 bits identify the second drive (drive 1).  Here&#8217;s a diagram showing how these two 4-bit fields are encoded:</p>
<div align="center"><img src="/mind/wp-content/uploads/2009/09/cmosfd.png"></div>
<p>We can use the bit-encoding to help us determine important parameters that our floppy driver will use, for example the number of tracks, the time it takes to spin up and spin down the disk, and so on.</p>
<h4>Example code</h4>
<p>In my own kernel, I don&#8217;t even bother trying to support anything except a 3.5&#8243; 1.44 MB floppy as the others are so rare or obsolete that I just don&#8217;t care.  This keeps the identification code in my floppy driver simpler.  Below is the corresponding code extract from my floppy driver.  My kernel&#8217;s initialization routine calls <code>probe_floppy()</code> if the BIOS parameter block says there are one or more floppy drives in the system.  This function then calls <code>fd_identify()</code> for each of the drives it finds in the CMOS. </p>
<div class="codediv">
<pre>
/*
 * fill in this floppy drive instance's specification based
 * on the drive type obtained from CMOS
 */
static int
fd_identify(fdrive_t *fp, uint8_t type)
{
	memset(fp, 0, sizeof (fdrive_t));
	switch (type) {
	case 0:
		/* shouldn't happen - no drive! */
		error(E_WARN, "fd_identify called with type = 0\n");
		return (DEV_FAIL);

	case 1:
		/* 5.25" 360 KB floppy - obsolete */

	case 2:
		/* 5.25" 1.2 MB floppy - obsolete */
	case 3:
		/* 3.5" 720 KB floppy - obsolete */
	case 5:
		/* 3.5" 2.88 MB floppy - obsolete */
		error(E_WARN, "Obsolete %s floppy drive detected\n",
		    fdtypes[type]);
		return (DEV_FAIL);

	default:
		/* unknown type - assume it's the ubiquitous 3.5" 1.44MB */
	case 4:
		fp->ident = "3.5\" 1.44MB";
		fp->data_rate = 500;
		fp->hlt = 8;
		fp->spt = 18;
		fp->srt_hut = 0xcf;
		/*
		 * set the spin_up and spin_down times by clock ticks,
		 * which occur at 100 HZ.
		 */
		fp->spin_up = 40;	/* 0.4 seconds */
		fp->spin_down = 300;	/* 3 seconds */
		fp->tracks = 80;
		fp->heads = 2;
		fp->gap3 = 0x1b;
		fp->gap3fmt = 0x6c;
		break;
	}

	/*
	 * at the moment, we only support 2 floppy drives from a single
	 * (primary) floppy disk controller, so we set the base address
	 * directly here.
	 */
	fp->base = FDC_BASEADDR;
	fp->did = ndrives;

	/* create the floppy device node name */
	sprintf(fp->name, "fd%d", ndrives);

	if ((fp->devp = mem_alloc(sizeof (device_t))) == NULL) {
		error(E_WARN,
		    "cannot allocate memory for floppy device\n");
		return (DEV_FAIL);
	}

	memset(fp->devp, 0, sizeof (device_t));
	fp->devp->ops = &#038;fd_devops;
	fp->devp->name = fp->name;
	fp->devp->data = fp;

	printf("fd%d  : %s floppy drive\n", ndrives, fp->ident);

	return (DEV_OK);
}

/*
 * we "probe" to see what floppy drives exist in the system. At the moment,
 * this is done by reading from the CMOS, which is pretty machine specific!
 * We also assume a maximum of two floppy drives, which is almost certainly
 * a reasonable assumption these days as most 80x86 don't have any!
 */
void
probe_floppy()
{
	uint8_t b, n;
	int attached = 0;

	/* find out what floppy drives exist from the CMOS */
	outportb(0x70, 0x10);
	b = inportb(0x71);

	/* check for drive 0 */
	if ((n = b >> 4) != 0) {
		if (fd_identify(&#038;floppy[0], n) == 0) {
			ndrives = 1;
			attached++;
		}
	}

	if ((n = b &#038; 0xf) != 0) {
		if (fd_identify(&#038;floppy[1], n) == 0) {
			ndrives++;
			attached++;
		}
	}

	/* if we didn't find any drives, there's nothing more to do */
	if (ndrives == 0)
		return;

	if (attached &#038;&#038; (fd_attach() != DEV_OK)) {
		error(E_WARN, "failed to attach floppy driver\n");
		return;
	}

	if (floppy[0].devp) {
		if (device_register(floppy[0].devp) != DEV_OK)
			error(E_WARN, "failed to register floppy "
			    "device 0\n");
		else
		if (sys_mkdev(NULL, "/dev/fd0", floppy[0].devp->id, 0) != 0)
			error(E_WARN, "cannot create /dev/fd0 node\n");
	}

	if (floppy[1].devp) {
		if (device_register(floppy[1].devp) != DEV_OK)
			error(E_WARN, "failed to register floppy "
			    "device 1\n");
		else
		if (sys_mkdev(NULL, "/dev/fd1", floppy[1].devp->id, 1) != 0)
			error(E_WARN, "cannot create /dev/fd1 node\n");
	}

	atom_init(&#038;fdio_atom);
}
</pre>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmo.org/mind/?feed=rss2&amp;p=265</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

