<?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-20636280</id><updated>2012-01-20T18:19:48.464Z</updated><category term='linux'/><category term='bluetooth'/><category term='events'/><category term='visualiser'/><category term='research'/><category term='sensing hardware'/><category term='python tips'/><category term='gumstix'/><category term='other sites'/><category term='random'/><category term='coding'/><title type='text'>The Kemp Project</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>94</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-20636280.post-1856204759136341670</id><published>2011-11-11T13:25:00.001Z</published><updated>2011-11-11T13:37:20.056Z</updated><title type='text'>xfig cannot import eps files</title><content type='html'>It seems that under Natty and Oneiric, xfig is unable to import eps files. When importing an eps you will get an error message along the lines of the following:&lt;br /&gt;&lt;pre&gt;ERROR from ghostscript:&lt;br /&gt;Error: /invalidfileaccess in --run--&lt;br /&gt;Operand stack:&lt;br /&gt;   3 --nostringval-- (filename.eps) (r)&lt;/pre&gt;and then several more lines of information.&lt;br /&gt;&lt;br /&gt;The Ubuntu team is almost making it too easy to find faults with their work, given that the same issue was identified and fixed in &lt;a href="https://bugzilla.novell.com/show_bug.cgi?id=629462"&gt;SUSE&lt;/a&gt; and &lt;a href="https://bugzilla.redhat.com/show_bug.cgi?id=657290"&gt;Fedora&lt;/a&gt; around a year ago (taking 11 days and 9 days respectively to push out the patch). The problem was &lt;a href="https://bugs.launchpad.net/ubuntu/+source/xfig/+bug/777230"&gt;reported&lt;/a&gt; to the Ubuntu team 6 months ago and still has no resolution.&lt;br /&gt;&lt;br /&gt;Anyway, bitterness aside, the way I'm working around this is to convert the eps to a fig first and then import that. First you have to install pstoedit:&lt;br /&gt;&lt;pre&gt;sudo apt-get install pstoedit&lt;/pre&gt;Now you can perform the conversion in this way:&lt;br /&gt;&lt;pre&gt;pstoedit -f fig filename.eps &gt; filename.fig&lt;/pre&gt;&lt;br /&gt;(Command found &lt;a href="http://linux4research.blogspot.com/2006/05/change-eps-file-to-fig-file.html"&gt;here&lt;/a&gt;.)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-1856204759136341670?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/1856204759136341670/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/11/xfig-cannot-import-eps-files.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1856204759136341670'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1856204759136341670'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/11/xfig-cannot-import-eps-files.html' title='xfig cannot import eps files'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2512057373854237328</id><published>2011-10-29T15:25:00.000Z</published><updated>2011-11-25T11:01:24.079Z</updated><title type='text'>Installing Google Chrome on Ubuntu 11.10</title><content type='html'>When attempting to install Google Chrome on Oneiric, you may encounter an error such as the following in the Ubuntu Software Centre:&lt;br /&gt;&lt;blockquote&gt;&lt;b&gt;Internal Error&lt;/b&gt;&lt;br /&gt;The file "google-chrome-stable_current_i386.deb" could not be opened.&lt;/blockquote&gt;Though depending on which installer you're using, the filename may be different of course. To work around this you can install it manually by running the following commands:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo apt-get install libxss1 libcurl3&lt;br /&gt;sudo dpkg -i google-chrome-stable_current_i386.deb&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Again, adjust the filename depending on the installer you have.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2512057373854237328?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2512057373854237328/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/10/installing-google-chrome-on-ubuntu-1110.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2512057373854237328'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2512057373854237328'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/10/installing-google-chrome-on-ubuntu-1110.html' title='Installing Google Chrome on Ubuntu 11.10'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-4801073532049685989</id><published>2011-10-10T12:08:00.000Z</published><updated>2011-10-10T12:08:17.606Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Ubuntu 11.10 - Brave or Disappointing?</title><content type='html'>I find myself hesitant to consider upgrading to the next version of Ubuntu, and no it's not because of the silly name (Oneiric Ocelot). It's because I've just seen the list of changes and realised that Ubuntu simply isn't a distribution that will give me what I need anymore. We are being presented with a complete removal of Ubuntu Classic (&lt;a href="http://kempproject.blogspot.com/2011/05/removing-ubuntu-1104-launcher-bar.html"&gt;I called that one&lt;/a&gt; without needing to check the roadmap), forcing us into a corner with GNOME 3.2, Unity, and Compiz. As readers may have noticed, I have objections to using two out of those three technologies. I haven't used the third yet (GNOME 3.2), but based on the screenshots I've seen it's not promising.&lt;br /&gt;&lt;br /&gt;This is an interesting moment for me, because it used to be that I'd be all over these upgrades. However, it seems that I've come to the age where the only important thing about an OS is that it lets me get things done quickly and without ceremony. Windows doesn't fit this bill at work and unfortunately it's becoming apparent that Ubuntu is determined not to as well. The big problem I have is that I'm not comfortable switching to a different distribution. Plus, the other members of the group use Ubuntu, and that opens me up to a whole world of subtle incompatibilities in the things we do. As things go, I'll probably remain on Natty until forced to make a choice one way or the other. Who knows - maybe I'll see someone on Oneiric and it'll inspire me. I'm skeptical, but still hopeful.&lt;br /&gt;&lt;br /&gt;But then there's the silly name...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-4801073532049685989?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/4801073532049685989/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/10/ubuntu-1110-brave-or-disappointing.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/4801073532049685989'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/4801073532049685989'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/10/ubuntu-1110-brave-or-disappointing.html' title='Ubuntu 11.10 - Brave or Disappointing?'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-7515071475262296738</id><published>2011-09-26T13:06:00.001Z</published><updated>2011-09-26T13:06:50.088Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='python tips'/><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>Python tips - List iteration and item removal</title><content type='html'>It's not a common task for me, but occasionally my code is required to work through a list and delete items that are not wanted. Take, for example, the case of appending the data from two CSV files to create a new file with both sets of data in. It may be that they don't have exactly the same columns in, but the common columns are the only ones you are interested in anyway. This is slightly more complex than simply 'cat'ing the source files into the target file, so let's assume you want to knock together a quick Python script to do it. I will first present the easy but wrong way to do it and then show how to adjust it to be correct.&lt;br /&gt;&lt;br /&gt;&lt;h3&gt;The incorrect way&lt;/h3&gt;&lt;br /&gt;The first step is to compare the header rows from each source file to figure out which columns are common (this will also form the basis of the new header row to write to the target file). This would imply code such as the following:&lt;br /&gt;&lt;pre&gt;if combined_header == []:&lt;br /&gt;    combined_header = this_header[:]&lt;br /&gt;else:&lt;br /&gt;    for col in combined_header:&lt;br /&gt;        if not(col in this_header):&lt;br /&gt;            combined_header.remove(col)&lt;/pre&gt;&lt;br /&gt;This could of course be achieved using intersections of sets. However, that wouldn't preserve the ordering of the columns, which I'm going to assume here is important or at least useful in some way.&lt;br /&gt;&lt;br /&gt;Ok, so let's test this. Assume the code has already looked at one file, giving&lt;br /&gt;&lt;tt&gt;combined_header = ['a', 'b', 'c', 'd', 'e']&lt;/tt&gt;&lt;br /&gt;and the next file gives&lt;br /&gt;&lt;tt&gt;this_header = ['a', 'b', 'd', 'e']&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Set these values up, run the code and voila:&lt;br /&gt;&lt;tt&gt;&gt;&gt;&gt; print combined_header&lt;br /&gt;['a', 'b', 'd', 'e']&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Ok, so far so good. How about another test case?&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;&gt;&gt;&gt; combined_header = ['a', 'b', 'c', 'd', 'e']&lt;br /&gt;&gt;&gt;&gt; this_header = ['a', 'b', 'e']&lt;br /&gt;&gt;&gt;&gt; # code runs here&lt;br /&gt;&gt;&gt;&gt; print combined_header&lt;br /&gt;['a', 'b', 'd', 'e']&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Wait a minute, wasn't it supposed to remove &lt;tt&gt;'d'&lt;/tt&gt; from the list? If we add a &lt;tt&gt;print col&lt;/tt&gt; after the start of the &lt;tt&gt;for&lt;/tt&gt; loop then we can see why:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;a&lt;br /&gt;b&lt;br /&gt;c&lt;br /&gt;e&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;It never even looks at the &lt;tt&gt;'d'&lt;/tt&gt; to check if it should be there. The reason for this is that the iterator you are using to scan along the list doesn't see the change occur when the &lt;tt&gt;'c'&lt;/tt&gt; is removed. As far as it's concerned, the next item to look at is still index 3, which is now the &lt;tt&gt;'e'&lt;/tt&gt;.&lt;br /&gt;&lt;br /&gt;&lt;h3&gt;The fix&lt;/h3&gt;&lt;br /&gt;The fix, as it turns out, is easy. After all, this is Python we're talking about. Simply scan the list in reverse order instead:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;if combined_header == []:&lt;br /&gt;    combined_header = this_header[:]&lt;br /&gt;else:&lt;br /&gt;    for col in &lt;b&gt;reversed(&lt;/b&gt;combined_header&lt;b&gt;)&lt;/b&gt;:&lt;br /&gt;        print col&lt;br /&gt;        if not(col in this_header):&lt;br /&gt;            combined_header.remove(col)&lt;/pre&gt;&lt;br /&gt;This results in:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;&gt;&gt;&gt; combined_header = ['a', 'b', 'c', 'd', 'e']&lt;br /&gt;&gt;&gt;&gt; this_header = ['a', 'b', 'e']&lt;br /&gt;&gt;&gt;&gt; # code runs here&lt;br /&gt;e&lt;br /&gt;d&lt;br /&gt;c&lt;br /&gt;b&lt;br /&gt;a&lt;br /&gt;&gt;&gt;&gt; print combined_header&lt;br /&gt;['a', 'b', 'e']&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Job done, one less annoying bug to track down later.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-7515071475262296738?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/7515071475262296738/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/09/python-tips-list-iteration-and-item.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7515071475262296738'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7515071475262296738'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/09/python-tips-list-iteration-and-item.html' title='Python tips - List iteration and item removal'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2857539708950041924</id><published>2011-09-19T16:20:00.001Z</published><updated>2011-09-19T16:20:39.485Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='research'/><category scheme='http://www.blogger.com/atom/ns#' term='events'/><title type='text'>Upcoming LCVTP Event</title><content type='html'>&lt;font size="4"&gt;&lt;b&gt;Cool ideas for a hot topic: Thermal Efficiency in Low Carbon Vehicles&lt;/b&gt;&lt;/font&gt;&lt;br /&gt;&lt;br /&gt;&lt;font size="3"&gt;A Low Carbon Vehicle Technology Project Conference on High Efficiency Heating, Ventilation &amp; Air Conditioning (HVAC) and System Cooling&lt;/font&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Tuesday 4 October 2011 (8:30am – 4:30pm)&lt;br /&gt;The TechnoCentre, Puma Way, Coventry&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Thermal management systems are crucial to the durability and comfort of today’s vehicles. They keep our cars’ engines cool, our windscreens demisted during winter and they ensure the interior is a comfortable temperature at all times, whether it’s hot or cold outside. &lt;br /&gt;&lt;br /&gt;With the dawn of zero-emission transport, however, a new challenge faces vehicle manufacturers. While the internal combustion engine could itself generate the heat required to warm a car’s cabin or power its air conditioning system, in EVs it is the battery – the same power source that drives the car – which must provide the energy for the thermal demands of the user and the powertrain. This can have a major effect on the range capability of the vehicle.&lt;br /&gt;&lt;br /&gt;Cool Ideas for a Hot Topic: Thermal Efficiency in Low Carbon Vehicles brings together key industry figures and leading academics to review the latest findings in the thermal efficiency work stream of the £29 million Low Carbon Vehicle Technology Project, and discuss how they can influence the development of zero-emission transport in the 21st century through:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;The advancement of electronics cooling methodology (circuit design, test and control)&lt;/li&gt;&lt;li&gt;The implementation of electric powered air conditioning&lt;/li&gt;&lt;li&gt;Using air conditioning for battery cooling&lt;/li&gt;&lt;li&gt;Efficient methods of heating&lt;/li&gt;&lt;li&gt;Improving cabin thermal efficiency&lt;/li&gt;&lt;li&gt;Passenger comfort and HVAC control&lt;/li&gt;&lt;li&gt;HVAC sensors location research&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;For automotive industry professionals, including and especially suppliers, the conference presents an opportunity not only to network with the LCVTP partners and other delegates, but also to provide feedback to the project from your area of expertise.&lt;br /&gt;&lt;br /&gt;Disseminating Partners: WMG (University of Warwick); Coventry University; MIRA; Jaguar Land Rover; Tata Motors European Technical Centre; Ricardo.&lt;br /&gt;&lt;br /&gt;Registration and more details: &lt;a href="http://wwwm.coventry.ac.uk/cuevents/moreinfo/Pages/CoolIdeasforaHotTopicThermalEfficiencyinLowCarbonVehicles.aspx"&gt;Coventry University event website&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2857539708950041924?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2857539708950041924/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/09/upcoming-lcvtp-event.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2857539708950041924'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2857539708950041924'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/09/upcoming-lcvtp-event.html' title='Upcoming LCVTP Event'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-6599287751360949976</id><published>2011-09-13T12:13:00.001Z</published><updated>2011-09-13T14:06:35.885Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Slow Alt+Tab in Ubuntu</title><content type='html'>For long time now I've experienced slow task switching if done by any other method than mouse clicks on the taskbar, particularly when using Alt+Tab. I finally got around to doing a search for a solution and came across a very helpful &lt;a href="http://ubuntuforums.org/showthread.php?t=890426"&gt;forum thread&lt;/a&gt;. As it turns out, compiz is the source of the problems (as it has often been in the past).&lt;br /&gt;&lt;br /&gt;One thing to try first is the change detailed &lt;a href="http://www.only10types.com/2011/06/ubuntu-1104-natty-slow-alttab-window.html"&gt;here&lt;/a&gt;. I haven't tried this myself, but it leaves the rest of the system intact at least.&lt;br /&gt;&lt;br /&gt;The alternative (which I tried) is the step detailed in the original thread I found.&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;gconftool-2 -s '/apps/metacity/general/compositing_manager' --type bool false&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Note that this will turn off a few fancy effects, though nothing that was at all important for me. I honestly can't see any difference except that switching is much &lt;i&gt;much&lt;/i&gt; faster.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Edit:&lt;br /&gt;Looks like I spoke too soon. Despite being faster for a while, it was soon back to the sloooow behaviour. I have now followed the instructions in the other blog post and it seems to have fixed it properly. The package you want there is compizconfig-settings-manager btw, he doesn't mention the name in his post.&lt;br /&gt;&lt;br /&gt;Edit2:&lt;br /&gt;Again, the cycle of being fast for a while and then back to the old behaviour. The changes I made are still intact. Guess I'll have to chalk this one up to "Ubuntu isn't ready for real use yet" (again).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-6599287751360949976?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/6599287751360949976/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/09/slow-alttab-in-ubuntu.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6599287751360949976'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6599287751360949976'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/09/slow-alttab-in-ubuntu.html' title='Slow Alt+Tab in Ubuntu'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-7812687691877435155</id><published>2011-06-07T11:34:00.002Z</published><updated>2011-10-15T10:35:42.218Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Traditional scrollbars in Ubuntu Natty</title><content type='html'>Mike Beach has a &lt;a href="http://mikebeach.org/2011/05/disable-the-overlay-scrollbars-in-ubuntu-natty/"&gt;post&lt;/a&gt; on removing the overlay scrollbars in Ubuntu Natty and getting back the traditional (usable) ones. I approve of this.&lt;br /&gt;&lt;br /&gt;The command he provides is: &lt;tt&gt;sudo apt-get remove overlay-scrollbar liboverlay-scrollbar-0.1-0&lt;/tt&gt;.&lt;br /&gt;&lt;br /&gt;In Oneiric the command is: &lt;tt&gt;sudo apt-get remove overlay-scrollbar liboverlay-scrollbar3-0.2-0 liboverlay-scrollbar-0.2-0&lt;/tt&gt; (thanks to &lt;a href="http://www.webupd8.org/2011/10/things-to-tweak-after-installing-ubuntu.html"&gt;WEB UPD8&lt;/a&gt;).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-7812687691877435155?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/7812687691877435155/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/06/traditional-scrollbars-in-ubuntu-natty.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7812687691877435155'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7812687691877435155'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/06/traditional-scrollbars-in-ubuntu-natty.html' title='Traditional scrollbars in Ubuntu Natty'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-5331116484946050631</id><published>2011-05-10T09:49:00.006Z</published><updated>2011-05-10T10:02:28.866Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>LyX spellcheck in Ubuntu Natty</title><content type='html'>Among &lt;a href="http://kempproject.blogspot.com/2011/05/removing-ubuntu-1104-launcher-bar.html"&gt;other annoying things&lt;/a&gt; in the new Ubuntu Natty release, it seems that spellchecking may become disabled in LyX. The fix is rather simple, but annoying to find if you don't know what you're looking for. The secret is that LyX relies on external libraries to provide its spellcheck capability, so if they're not installed correctly or not configured correctly in LyX then it breaks. And it doesn't tell you why.&lt;br /&gt;&lt;br /&gt;The solution after a Natty upgrade (I haven't checked on a clean install) is:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Open up LyX&lt;/li&gt;&lt;li&gt;Go to Tools &gt; Preferences &gt; Language Settings &gt; Spellchecker&lt;/li&gt;&lt;li&gt;Chances are good that the "Spellchecker executable" option is not set to anything. Change it to your preferred library, which by default should be Enchant.&lt;/li&gt;&lt;li&gt;While you're there, turn on the new "Spellcheck continuously" option. This is the new inline spellchecker.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;Job done. Now you can continue using a function that was already working with exactly the same library before the upgrade happened.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-5331116484946050631?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/5331116484946050631/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/05/lyx-spellcheck-in-ubuntu-natty.html#comment-form' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/5331116484946050631'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/5331116484946050631'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/05/lyx-spellcheck-in-ubuntu-natty.html' title='LyX spellcheck in Ubuntu Natty'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-179311831081620590</id><published>2011-05-02T18:09:00.011Z</published><updated>2011-05-03T11:18:13.653Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='research'/><title type='text'>Careful data handling</title><content type='html'>While processing some experimental data recently I was comparing two data streams and saw:&lt;br /&gt;&lt;table border="1" cellpadding="4"&gt;&lt;tr&gt;&lt;td&gt;&lt;b&gt;RMSE&lt;/b&gt;&lt;/td&gt;&lt;td&gt;&lt;b&gt;Corr&lt;/b&gt;&lt;/td&gt;&lt;td&gt;&lt;b&gt;n&lt;/b&gt;&lt;/td&gt;&lt;td&gt;&lt;b&gt;p-value&lt;/b&gt;&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;3.26&lt;/td&gt;&lt;td&gt;0.19&lt;/td&gt;&lt;td&gt;39&lt;/td&gt;&lt;td&gt;0.25&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br /&gt;In this case, "Corr" is Pearson's correlation and the quoted p-value is for the significance of the correlation. Given a scale of -4 to 4, it looks like it's fairly safe to say that the two data streams don't have very much in common. The lack of samples is unfortunate but couldn't be helped in this case.&lt;br /&gt;&lt;br /&gt;It wasn't such a simple case however, as I noticed that two of the samples shouldn't have been included in the comparison (for very well-defined experimental reasons). Two points out of 39 shouldn't make a big difference right? ;-) Having removed these points from the comparison I got the following results:&lt;br /&gt;&lt;table border="1" cellpadding="4"&gt;&lt;tr&gt;&lt;td&gt;&lt;b&gt;RMSE&lt;/b&gt;&lt;/td&gt;&lt;td&gt;&lt;b&gt;Corr&lt;/b&gt;&lt;/td&gt;&lt;td&gt;&lt;b&gt;n&lt;/b&gt;&lt;/td&gt;&lt;td&gt;&lt;b&gt;p-value&lt;/b&gt;&lt;/td&gt;&lt;/tr&gt;&lt;br /&gt;&lt;tr&gt;&lt;td&gt;2.05&lt;/td&gt;&lt;td&gt;0.69&lt;/td&gt;&lt;td&gt;37&lt;/td&gt;&lt;td&gt;2.14e-06&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br /&gt;As you can see, this made a significant difference (literally). Making a scatterplot of these results earlier on would have pointed me to this mistake much quicker.&lt;br /&gt;&lt;br /&gt;Remember kids, 1) you need to know your data (why is each of those points included in the analysis?), and 2) scatterplots are your friend when looking at any type of correlation.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-179311831081620590?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/179311831081620590/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/05/careful-data-handling.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/179311831081620590'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/179311831081620590'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/05/careful-data-handling.html' title='Careful data handling'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-8607883070139983614</id><published>2011-05-02T18:08:00.003Z</published><updated>2011-06-07T11:38:12.478Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Removing the Ubuntu Natty launcher bar</title><content type='html'>In Ubuntu 11.04 (Natty Narwhal):&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Click the far top-left button to bring up the search dialog.&lt;/li&gt;&lt;li&gt;Type "login" without the quotes and click on "Login Screen".&lt;/li&gt;&lt;li&gt;Change "Select Ubuntu as default session" to "Select Ubuntu Classic as default session".&lt;/li&gt;&lt;li&gt;Log out and back in.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;Congratulation, you have removed the abomination. Prepare for 11.10 where they will no doubt remove Ubuntu Classic as an option.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-8607883070139983614?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/8607883070139983614/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/05/removing-ubuntu-1104-launcher-bar.html#comment-form' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/8607883070139983614'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/8607883070139983614'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/05/removing-ubuntu-1104-launcher-bar.html' title='Removing the Ubuntu Natty launcher bar'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2311206845622941226</id><published>2011-04-21T15:37:00.009Z</published><updated>2011-04-21T18:26:32.003Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><title type='text'>SQ2040 datalogger and HIH-5031 humidity sensors</title><content type='html'>This post will show you how to connect &lt;a href="http://sensing.honeywell.com/index.cfm?ci_id=140301&amp;amp;la_id=1&amp;amp;pr_id=156098"&gt;HIH-5031 humidity sensors&lt;/a&gt; to a &lt;a href="http://www.grant.co.uk/Data+Acquisition/Products/High+precision+universal+data+loggers/Squirrel+2040/"&gt;Squirrel SQ2040 datalogger&lt;/a&gt;. The advice will also be applicable to many other sensors with three connections for power, signal (voltage), and ground.&lt;br /&gt;&lt;br /&gt;First, you need to make the actual physical connections. For these particular sensors the connections should be as follows (assuming the signal is being taken to the first input of block C):&lt;br /&gt;&lt;br /&gt;&lt;a href="http://1.bp.blogspot.com/-2t8UKWzrWkc/TbBQ6LIashI/AAAAAAAAAJY/7rf20TxNgjA/s1600/hih-5031_conn.png" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 283px; height: 400px;" src="http://1.bp.blogspot.com/-2t8UKWzrWkc/TbBQ6LIashI/AAAAAAAAAJY/7rf20TxNgjA/s400/hih-5031_conn.png" border="0" alt="" id="BLOGGER_PHOTO_ID_5598063297172255250" /&gt;&lt;/a&gt;&lt;br /&gt;Additional sensors may be connected to the other logger inputs and use the same power connections. Note that pin 5 on the input block is connected to ground. This is because the signal is measured relative to this. If it is floating then you will get bad readings (for example, I saw very a small negative input).&lt;br /&gt;&lt;br /&gt;The following picture shows my logger connected to eight humidity sensors using this connection method. The terminal block in the centre is to make the positive power connection easier.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://2.bp.blogspot.com/-wWoihzxyE7s/TbBmcEoDyZI/AAAAAAAAAJg/u90qw9CdFAo/s1600/wiring.jpg" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 381px; height: 400px;" src="http://2.bp.blogspot.com/-wWoihzxyE7s/TbBmcEoDyZI/AAAAAAAAAJg/u90qw9CdFAo/s400/wiring.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5598086969285659026" /&gt;&lt;/a&gt;&lt;br /&gt;Now for the logger configuration. For this I will assume that you are using SquirrelView. Click on Logger Setup and enter sensor details as shown below (you'll have to click through to the full-size image, it's quite wide):&lt;br /&gt;&lt;br /&gt;&lt;a href="http://3.bp.blogspot.com/-_OLfIAwPeIY/TbBncmgWEKI/AAAAAAAAAJo/_IfaTl2wfVk/s1600/sensor_conf.png" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 14px;" src="http://3.bp.blogspot.com/-_OLfIAwPeIY/TbBncmgWEKI/AAAAAAAAAJo/_IfaTl2wfVk/s400/sensor_conf.png" border="0" alt="" id="BLOGGER_PHOTO_ID_5598088077891735714" /&gt;&lt;/a&gt;&lt;br /&gt;Note that the sensor power option isn't present in the usual sensor setup dialog and will have to be set afterward. If this isn't set then power won't be supplied even if you enable the power output option. This caught me out at first. Sensor power may be enabled via the following setting at the bottom of the window:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/-4ZQv380vv9c/TbBoIwk1E7I/AAAAAAAAAJw/zXLokPV_5bk/s1600/power_conf.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 196px; height: 35px;" src="http://3.bp.blogspot.com/-4ZQv380vv9c/TbBoIwk1E7I/AAAAAAAAAJw/zXLokPV_5bk/s400/power_conf.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5598088836509143986" /&gt;&lt;/a&gt;&lt;br /&gt;Now upload the configuration to the logger and try it out. If everything has been set up correctly you should be able to see the voltage being output by the sensor.&lt;br /&gt;&lt;br /&gt;It is possible to have the logger perform the conversion from a voltage to a humidity reading. However, it must (theoretically) be compensated for temperature, so I decided to perform the entire conversion as a post-processing step.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2311206845622941226?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2311206845622941226/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/04/sq2040-datalogger-and-hih-5031-humidity.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2311206845622941226'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2311206845622941226'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/04/sq2040-datalogger-and-hih-5031-humidity.html' title='SQ2040 datalogger and HIH-5031 humidity sensors'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/-2t8UKWzrWkc/TbBQ6LIashI/AAAAAAAAAJY/7rf20TxNgjA/s72-c/hih-5031_conn.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-4384520487082394822</id><published>2011-04-19T14:56:00.004Z</published><updated>2011-04-19T15:14:50.894Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Using ssconvert remotely</title><content type='html'>If you've ever used &lt;a href="http://linuxcommand.org/man_pages/ssconvert1.html"&gt;ssconvert&lt;/a&gt; (part of the &lt;a href="http://projects.gnome.org/gnumeric/index.shtml"&gt;gnumeric&lt;/a&gt; package) via an SSH session then you're likely to have seen the horde of warnings that are displayed:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;GConf Error: Failed to contact configuration server; the most common cause is a missing or misconfigured D-Bus session bus daemon. See http://projects.gnome.org/gconf/ for information. (Details -  1: Not running within active session)&lt;br /&gt;&lt;br /&gt;... [repeated many times] ...&lt;br /&gt;&lt;br /&gt;(ssconvert:11925): GConf-WARNING **: Directory `/apps/gnumeric' was not being monitored by GConfClient 0x87cf220&lt;/blockquote&gt;&lt;br /&gt;There is a simple workaround for this that may be helpful if you are calling ssconvert multiple times within a makefile or similar and don't want to add additional huge amounts of useless output. Simply prepend &lt;tt&gt;DISPLAY=:0&lt;/tt&gt; onto the command and it will be happy (i.e. &lt;tt&gt;DISPLAY=:0 ssconvert [args]&lt;/tt&gt;).&lt;br /&gt;&lt;br /&gt;As a bonus, here's a simple command line to turn an Excel worksheet into a csv file, something I have to do fairly often when setting up processing of data from other people:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;ssconvert --export-type=Gnumeric_stf:stf_assistant -O 'sheet="sheet_name" separator=, quoting-mode="auto" eol="unix"' input_file output_file&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Replace &lt;tt&gt;sheet_name&lt;/tt&gt;, &lt;tt&gt;input_file&lt;/tt&gt;, and &lt;tt&gt;output_file&lt;/tt&gt; with your own values.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-4384520487082394822?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/4384520487082394822/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2011/04/using-ssconvert-remotely.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/4384520487082394822'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/4384520487082394822'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2011/04/using-ssconvert-remotely.html' title='Using ssconvert remotely'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-1495710873827251501</id><published>2010-11-23T14:17:00.003Z</published><updated>2010-11-23T14:30:38.201Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><title type='text'>OpenPicus FlyPort</title><content type='html'>I recently obtained an OpenPicus FlyPort module and StarterKit Nest. I have a use in mind for the devices, but for now they are quite fun to play around with.&lt;br /&gt;&lt;br /&gt;For information see:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="http://www.openpicus.com/index.htm" target="_blank"&gt;OpenPicus website&lt;/a&gt;&lt;/li&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="http://www.openpicus.com/flyport.htm" target="_blank"&gt;FlyPort module page&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.openpicus.com/nests.htm" target="_blank"&gt;StarterKit nest page&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;li&gt;&lt;a href="http://openpicus.blogspot.com/" target="_blank"&gt;OpenPicus blog&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;The main attraction with these devices (for me) was that you aren't buying the individual parts (which, let's face it, are much cheaper), nor are you even buying them mounted on a fancy PCB. You are buying a complete product. The currently available software includes the full TCP/IP and Wifi stacks and a web server application that allows both displaying of input values and control of output values from a web browser anywhere on your network. Upcoming software includes an IDE targeted at the capabilities of the devices, with a wizard that looks like it will be capable of generating a lot of the code needed for a variety of uses (see &lt;a href="http://www.openpicus.com/idegrande.jpg" target="_blank"&gt;this screenshot&lt;/a&gt;). A Bluetooth based module is also scheduled for release towards the end of 2010.&lt;br /&gt;&lt;br /&gt;I'm always on the lookout for fun new development kits, and this fit the bill quite nicely.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-1495710873827251501?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/1495710873827251501/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2010/11/openpicus-flyport.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1495710873827251501'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1495710873827251501'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2010/11/openpicus-flyport.html' title='OpenPicus FlyPort'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-7026266954026672554</id><published>2010-10-15T13:06:00.013Z</published><updated>2010-10-16T13:27:26.223Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='research'/><title type='text'>An example of academic plagarism</title><content type='html'>This post is going to describe a case of academic plagarism that I found while investigating the use of fuzzy logic in modelling PMV for HVAC control. I will walk through the various sections of text and diagrams that have been lifted from the victims, as well as showing several obvious mistakes made by the perpetrators due to lack of attention. To simplify referencing in the text, I have assigned each paper a one or two character name: &lt;span style="font-style:italic;"&gt;P&lt;/span&gt;, &lt;span style="font-style:italic;"&gt;V1&lt;/span&gt;, and &lt;span style="font-style:italic;"&gt;V2&lt;/span&gt;. These are noted below.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Perpetrator&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;font size="1"&gt;(P)&lt;/font&gt; Elizabeth Amudhini Stephen, Mercy Shnathi, P. Rajalakshmy, and M. Melbern Parthido. Application of fuzzy logic in control of thermal comfort. &lt;span style="font-style:italic;"&gt;International Journal of Computational and Applied Mathematics&lt;/span&gt;, 5(3):289–300, 2010.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Victims&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;font size="1"&gt;(V1)&lt;/font&gt; Maher Hamdi, Gérard Lachiver, and François Michaud. A new predictive thermal sensation index of human response. &lt;span style="font-style:italic;"&gt;Energy and Buildings&lt;/span&gt;, 29(2):167–178, 1999.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;&lt;font size="1"&gt;(V2)&lt;/font&gt; Yadollah Farzaneh and Ali A. Tootoonchi. Controlling automobile thermal comfort using optimized fuzzy controller. &lt;span style="font-style:italic;"&gt;Applied Thermal Engineering&lt;/span&gt;, 28(14–15):1906–1917, October 2008.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Original content&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The full sum of original content (that I can determine) in &lt;span style="font-style:italic;"&gt;P&lt;/span&gt; is the sentence "Fuzzy PMV is used instead of Fanger's PMV" on page 290 and the word "(fuzzy)" on page 298. That is a total of nine words in a 12 page paper. There are also two figures and a table on pages 294 and 295 which I cannot find elsewhere, but these are not mentioned in the text and do not appear to add anything content-wise. Everything else in the paper is directly lifted from either &lt;span style="font-style:italic;"&gt;V1&lt;/span&gt; or &lt;span style="font-style:italic;"&gt;V2&lt;/span&gt; with only a couple of minor edits (and sometimes obvious edits are not made, but more on this later).&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Origin of plagarised content&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This section lists which of the two victim papers each part of &lt;span style="font-style:italic;"&gt;P&lt;/span&gt; came from.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;V1&lt;ul&gt;&lt;li&gt;Section 2 (parts B, C, D, and E).&lt;/li&gt;&lt;li&gt;Figures a and 4.&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;br /&gt;&lt;li&gt;V2&lt;ul&gt;&lt;li&gt;Abstract.&lt;/li&gt;&lt;li&gt;Sections 1, 2 (part A), 3, 4 (parts A and B), and 5.&lt;/li&gt;&lt;li&gt;Figures 2, 3, 5, 7, 10, 11, and 12.&lt;/li&gt;&lt;li&gt;References list.&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Obvious mistakes&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Due to the direct copying of content from two other papers and the lack of attention paid to the result, there are many obvious mistakes in the paper. A summary of these is given below.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;The PMV equation and all figures are pixelised (some quite badly) due to lack of access to the original markup or vector-based images.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The first figure is lettered as 'a', the remaining figures are numbered.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The figures are out of order (Figure 4 comes before Figure 3) and some numbers are skipped (Figures 1, 6, 8, and 9).&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The text references non-existent Figures b, 6, and 8.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The text references a non-existent Table 4 (no numbered tables exist in the paper).&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The references list is (incompletely) taken from &lt;span style="font-style:italic;"&gt;V2&lt;/span&gt;. This means that a citation in the text from &lt;span style="font-style:italic;"&gt;V1&lt;/span&gt; points to a paper that doesn't exist in the references list.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Of the 28 references copied from &lt;span style="font-style:italic;"&gt;V2&lt;/span&gt;, only four are actually cited in the text.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The copied text has mistakes arising from incorrect text extraction (presumably from the original PDFs) or later attempts to fix such errors.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Inconsistent notation and notation that appears unexplained.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Mentioning of experimentation on page 295, with no description of the experiments or results discussion. Figures 2 and 3 were originally part of the results discussion, but are not referenced in the text here.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Amusing aside&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;While plagarism is not a funny topic, I can't help being amused at this: &lt;span style="font-style:italic;"&gt;V2&lt;/span&gt; cites &lt;span style="font-style:italic;"&gt;V1&lt;/span&gt;, meaning that &lt;span style="font-style:italic;"&gt;P&lt;/span&gt; accidentally cites one of the papers it was plagarised from (though for a very minor point and without mentioning the author names).&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Summary&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Absolutely no effort was made to hide the plagarism of other work, leading to a paper that is inconsistent and largely meaningless.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-7026266954026672554?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/7026266954026672554/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2010/10/example-of-academic-plagarism.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7026266954026672554'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7026266954026672554'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2010/10/example-of-academic-plagarism.html' title='An example of academic plagarism'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-6109051601598246183</id><published>2010-05-13T11:38:00.003Z</published><updated>2010-05-13T11:40:46.277Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><title type='text'>GSS CO2 Sensor Tech Docs</title><content type='html'>GSS have released a whole load of new technical documents related to using their C20 CO2 sensor. I was a bit worried when I noticed that the original user guide had disappeared a while ago, but now it's back, it's revised, and it has some friends. &lt;a href="http://www.gassensing.co.uk/technical-downloads.asp"&gt;Enjoy&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-6109051601598246183?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/6109051601598246183/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2010/05/gss-co2-sensor-tech-docs.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6109051601598246183'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6109051601598246183'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2010/05/gss-co2-sensor-tech-docs.html' title='GSS CO2 Sensor Tech Docs'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-777664716091067261</id><published>2010-05-10T11:54:00.010Z</published><updated>2011-08-18T10:52:34.611Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='python tips'/><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>Python tips - Simple sensor data handling 2</title><content type='html'>&lt;a href="http://kempproject.blogspot.com/2010/04/python-tips-simple-sensor-data-handling.html"&gt;Last time&lt;/a&gt;, I described a simple way to take a series of data samples grouped by timestamp and reorganise them to group by the sensor from which they came. This time I will describe a simple way to read the data in from a file. Note that I will leave out error checking for the purpose of clarity, but this is always something which should be considered.&lt;br /&gt;&lt;br /&gt;For this purpose, assume that you have data stored in a file, presumably logged to the file on a prior occasion. The file might look like this:&lt;br /&gt;&lt;pre&gt;"time","s1","s2","s3"&lt;br /&gt;0,4,8,3&lt;br /&gt;1,4,9,2&lt;br /&gt;2,5,8,2&lt;br /&gt;3,5,8,1&lt;br /&gt;4,6,9,2&lt;/pre&gt;In years past I would have jumped straight in and performed my own parsing:&lt;br /&gt;&lt;pre&gt;infile = open('data.csv', 'r')&lt;br /&gt;header = infile.next().rstrip().split(',')&lt;br /&gt;for line in infile:&lt;br /&gt;    ls = line.rstrip().split(',')&lt;br /&gt;    # processing code&lt;/pre&gt;This, however, only works for the simple case (such as given in the example file) and I seemed over time to gradually have more and more files with exceptions that such code didn't gracefully handle. Thankfully, the &lt;tt&gt;csv&lt;/tt&gt; module is available in Python and makes life much easier:&lt;br /&gt;&lt;pre&gt;import csv&lt;br /&gt;&lt;br /&gt;infile = csv.reader(open('data.csv', 'r'))&lt;br /&gt;header = infile.next()&lt;br /&gt;for row in infile:&lt;br /&gt;    # processing code&lt;/pre&gt;This is a bit shorter and gives correct handling of the format. The next step is likely to be converting the values on each line to the correct data type:&lt;br /&gt;&lt;pre&gt;timestamp = int(line[0])&lt;br /&gt;values = map(float, line[1:])&lt;/pre&gt;This call to &lt;tt&gt;map&lt;/tt&gt; will return a list composed of items created by passing each item in turn from &lt;tt&gt;line[1:]&lt;/tt&gt; to the &lt;tt&gt;float&lt;/tt&gt; function. Even though the values I populated the file with are integers, I prefer to convert to floats before processing as this avoids any accidental use of integer math. It, of course, makes complete sense if your original values were floats.&lt;br /&gt;&lt;br /&gt;It this point you'll want to store the values somewhere. For now we'll append them to a list as a tuple containing the timestamp and values:&lt;br /&gt;&lt;pre&gt;data.append((timestamp, values))&lt;/pre&gt;This will give us a list that looks like&lt;br /&gt;&lt;pre&gt;[&lt;br /&gt;(0, (4, 8, 3)),&lt;br /&gt;(1, (4, 9, 2)),&lt;br /&gt;(2, (5, 8, 2)),&lt;br /&gt;(3, (5, 8, 1)),&lt;br /&gt;(4, (6, 9, 2))&lt;br /&gt;]&lt;/pre&gt;In part 3 I will cover some of the summary statistics you may want to generate, and how to achieve it from data stored in this way.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-777664716091067261?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/777664716091067261/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2010/05/python-tips-simple-sensor-data-handling.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/777664716091067261'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/777664716091067261'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2010/05/python-tips-simple-sensor-data-handling.html' title='Python tips - Simple sensor data handling 2'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-4114751010780667148</id><published>2010-04-15T10:02:00.007Z</published><updated>2011-05-10T13:16:55.637Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='python tips'/><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>Python tips - Simple sensor data handling</title><content type='html'>Say you have a system which collects data from a group of sensors. Let's have three sensors giving integer values for the sake of argument, but this doesn't affect what I'm about to show you. The easiest way to store this data (assuming you want some history) is as a list of tuples, so if the data you get from the sensors is &lt;tt&gt;(1, 5, 3)&lt;/tt&gt; at t=0, &lt;tt&gt;(2, 5, 3)&lt;/tt&gt; at t=1, &lt;tt&gt;(2, 4, 4)&lt;/tt&gt; at t=2, and &lt;tt&gt;(2, 5, 2)&lt;/tt&gt; at t=3 then you would be storing&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;[(1, 5, 3), (2, 5, 3), (2, 4, 4), (2, 5, 2)]&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;As a side-note, this lets you do a window fairly easily:&lt;br /&gt;&lt;pre&gt;values = get_sample()&lt;br /&gt;data.append(values)&lt;br /&gt;if len(data) &gt; WINDOW_SIZE:&lt;br /&gt;    data.pop(0)&lt;/pre&gt;Now, say you want to process the data from each sensor separately, that is to end up with&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;[(1, 2, 2, 2), (5, 5, 4, 5), (3, 3, 4, 2)]&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;One way to do this would be to use:&lt;br /&gt;&lt;pre&gt;result = []&lt;br /&gt;for sensor in data[0]:&lt;br /&gt;    result.append([])&lt;br /&gt;for sample in data:&lt;br /&gt;    for sensor_id in range(len(sample)):&lt;br /&gt;        value = sample[sensor_id]&lt;br /&gt;        result[sensor_id].append(value)&lt;/pre&gt;That, however, is not very neat and nor does it tell you at a glance what it's aiming to achieve. There is, however, another way to reach the same goal, and it uses only a single function call:&lt;br /&gt;&lt;pre&gt;result = zip(*data)&lt;/pre&gt;Simple, no? Possibly some explanation is required here though. The idea behind &lt;tt&gt;zip&lt;/tt&gt; is that it provides a way to iterate over two (or more) sequences, obtaining the first item from each, the second item from each, and so on. This means that&lt;br /&gt;&lt;pre&gt;a = [1, 2, 3, 4]&lt;br /&gt;b = [6, 7, 8, 9]&lt;br /&gt;for x in zip(a, b):&lt;br /&gt;    print x&lt;/pre&gt;should print out&lt;br /&gt;&lt;pre&gt;(1, 6)&lt;br /&gt;(2, 7)&lt;br /&gt;(3, 8)&lt;br /&gt;(4, 9)&lt;/pre&gt;So how does my sensor data magic work? Prepending an asterisk (&lt;tt&gt;*&lt;/tt&gt;) to a list used as a function argument has the effect of passing each item in the list as a separate argument, so&lt;br /&gt;&lt;pre&gt;def x(v1, v2, v3):&lt;br /&gt;    return v1 + v2 + v3&lt;br /&gt;&lt;br /&gt;a = [1, 2, 3]&lt;br /&gt;print x(*a)&lt;/pre&gt;will print out &lt;tt&gt;6&lt;/tt&gt; as the result. Each element of &lt;tt&gt;a&lt;/tt&gt; was passed as a separate argument to &lt;tt&gt;x&lt;/tt&gt;. I'm sure you can see where this is going now. &lt;tt&gt;zip&lt;/tt&gt; will accept any number of sequences as arguments, so &lt;tt&gt;zip(*data)&lt;/tt&gt; will pass each sample to &lt;tt&gt;zip&lt;/tt&gt; separately, and then &lt;tt&gt;zip&lt;/tt&gt; will happily do its job giving you the first item from each, the second item from each, and so on. In this case that gives you all the data from sensor 1, followed by all the data from sensor 2, and then all the data from sensor 3.&lt;br /&gt;&lt;br /&gt;In &lt;a href="http://kempproject.blogspot.com/2010/05/python-tips-simple-sensor-data-handling.html"&gt;part 2&lt;/a&gt;, I cover easily reading logged data in from a file.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-4114751010780667148?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/4114751010780667148/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2010/04/python-tips-simple-sensor-data-handling.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/4114751010780667148'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/4114751010780667148'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2010/04/python-tips-simple-sensor-data-handling.html' title='Python tips - Simple sensor data handling'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-3574132274556872729</id><published>2009-12-05T23:21:00.010Z</published><updated>2011-08-25T08:48:29.486Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><title type='text'>GSS C20 CO2 Sensor</title><content type='html'>This post discusses the C20 CO2 sensor from &lt;a href="http://www.gassensing.co.uk/"&gt;GSS&lt;/a&gt; (Gas Sensing Solutions). It appears to be distributed by &lt;a href="http://www.airmonitors.co.uk/gases"&gt;Air Monitors&lt;/a&gt; and &lt;a href="http://europaenvironmental.com/co2_monitor"&gt;Europa Environmental&lt;/a&gt; as the "Miniature CO2 sensor". Specifically, I will discuss the differences between the datasheet and the actual implementation on the device.&lt;br /&gt;&lt;br /&gt;Note that I am not considering the carrier/interface board to be a separate entity to the sensor itself as they are purchased as a single unit and treated the same way in the datasheet. Also note that I am not an authoritive source on this and the implementation details could change at any time. I am simply recounting my own experiences with the specific units I worked with.&lt;br /&gt;&lt;br /&gt;&lt;i&gt;Edit since original publication:&lt;br /&gt;The datasheet for the device has been updated and expanded into several documents available &lt;a href="http://www.gassensing.co.uk/technical-downloads.asp"&gt;here&lt;/a&gt;. It appears that the device itself has also been updated in several ways, so confirm that my advice is applicable before using it. My own copy of the original datasheet is mirrored &lt;a href="http://files.iualdii.net/articles/C20%20-%20CO2%20sensor%20module.pdf"&gt;here&lt;/a&gt; for those of you interested.&lt;/i&gt;&lt;br /&gt;&lt;br /&gt;Before I go any further, I should also mention that their tech support were &lt;span style="font-style:italic;"&gt;very&lt;/span&gt; helpful in ironing out any issues I had interfacing to and using the sensor.&lt;br /&gt;&lt;br /&gt;The differences I encountered were during interfacing this sensor (on separate occasions) to a Gumstix Verdex device and to a PIC18F microcontroller. They are not differences which affect the usefulness of the device, but they may catch you unexpectedly. There are two main differences I have observed. I also have some additional notes related to usage of the device.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Connector pin-out&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;To my knowledge, all of the alternate connection points are as stated in the datasheet. I have confirmed this for the alternate points for power and serial to each side of the main connector (standard pin headers fit here quite nicely), but not for the alternate ground points as I've never had to use those. The functional difference observed is pin 2 of the connector, which is stated in the datasheet to be a 0v (GND) connection. This is not the case, it is not connected to the GND rail on the board (nor used for any purpose as far as I can tell), and pin 10 should be used instead. This has been confirmed by their tech support, but it's good practice not to rely on this behaviour as it could be changed at any time (possibly to bring it in line with the datasheet, or to use the pin for a different purpose).&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Communication data format&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;This difference is related to the format used for sending data to the host device. This is stated in the datasheet as&lt;br /&gt;&lt;tt&gt;Z_#####_z_#####\r\n&lt;/tt&gt;&lt;br /&gt;When in fact it appears to be&lt;br /&gt;&lt;tt&gt;_Z_#####_z_#####_\r\n&lt;/tt&gt;&lt;br /&gt;(with underscores representing spaces). Not a problem if you read a full line at a time and search for the value identifiers, but potentially a problem if you are reading samples in fixed size blocks, or if you are trying to save processing time by simply extracting a specific range of characters from the sample.&lt;br /&gt;&lt;br /&gt;As a minor aside, I have also had problems obtaining the LED signal strength value (code "O"). The two temperature values are given as described. Admittedly the LED signal strength and the temperatures are not very useful due to being the raw ADC output, not converted or calibrated in any way. However, it is a discrepancy between the datasheet and the device and thus is included here.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Calibration&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;The sensor will need calibrating before use. Their tech support says that zeroing should be enough and the span value shouldn't need adjustment from the default. I've found this to be 50/50 though, best to always check both. My procedure for calibration is as follows:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Turn the sensor on, set the filter response to 16, the span to 8192, and allow to warm up for 3 minutes.&lt;/li&gt;&lt;li&gt;Expose to 100% nitrogen flow for 1 minute.&lt;/li&gt;&lt;li&gt;Send "Zero in nitrogen" command or apply signal to relevant pin.&lt;/li&gt;&lt;li&gt;Expose to high CO2 concentration flow (around the upper end of your intended sensing range) for 1 minute or until value has stabilised.&lt;/li&gt;&lt;li&gt;Calculate correct span value and send to device.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;b&gt;Other notes&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Apparently the concentration in the sensing head should diffuse to 90% of the final value within 4 seconds. I assume this is without any sort of pumping or direct flow.&lt;br /&gt;&lt;br /&gt;External physical pressure on the sensing head (i.e. if it is clamped or pressed against something) will affect the readings gathered. If it is calibrated in the same condition it will be used then this will be ok. If calibrated and then put under pressure, it will return to calibration once the pressure is removed.&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-3574132274556872729?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/3574132274556872729/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/10/gss-c20-co2-sensor.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/3574132274556872729'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/3574132274556872729'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/10/gss-c20-co2-sensor.html' title='GSS C20 CO2 Sensor'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-3283341414607150841</id><published>2009-12-03T16:22:00.008Z</published><updated>2012-01-20T17:55:24.915Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>Gumstix Verdex and USB flash</title><content type='html'>This article details the (simple) process of connecting and using a USB flash drive with a &lt;a href="http://www.blogger.com/articles/gumstix-devices"&gt;Gumstix&lt;/a&gt; Verdex device. The Verdex already supports being a USB host, so the main work is in making the physical connection itself.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Hardware&lt;/strong&gt;&lt;br /&gt;The connection can be made by the use of a standard "A" to "mini-B" connector of the type which are often supplied with phones, cameras and many other small gadgets for data transfer or charging. The mini-B end of the connector is to be plugged into the Verdex via the expansion board, while the A end (the larger end that would normally plug into a PC or charger block) is plugged into a gender changer and then the USB flash drive into that. This is shown below. Power will be supplied to the flash drive (on most expansion boards) directly from the main supply via a regulator, not under the direct control of the Verdex itself.&lt;br /&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-BKWfP0cxLcs/TxmpIvX8YbI/AAAAAAAAAM0/XxR0mQRc_MQ/s1600/gumstix_USB_flash.jpg" imageanchor="1" style="margin-left:1em; margin-right:1em"&gt;&lt;img border="0" height="348" width="400" src="http://2.bp.blogspot.com/-BKWfP0cxLcs/TxmpIvX8YbI/AAAAAAAAAM0/XxR0mQRc_MQ/s400/gumstix_USB_flash.jpg" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;strong&gt;Drive recognition and mounting&lt;/strong&gt;&lt;br /&gt;Once the physical connection has been made, the Verdex should automatically detect and mount the flash drive into the filesystem. This is assuming you are using a relatively modern build of OpenEmbedded, otherwise you may have to enable or modprobe some additional modules. See the troubleshooting section to get some ideas on which ones. The device (on our build of OpenEmbedded at least) gets mounted at &lt;code&gt;/media/hdd&lt;/code&gt; automatically and can then be used as you would any other mass-storage device.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Usage tips&lt;/strong&gt;&lt;br /&gt;When writing to files on the flash drive on a battery-powered node (especially if there are environmental factors potentially causing additional reliability issues), it is important to ensure that data has actually been written to the drive. There is a level of buffering involved which may mean that in the case of the node losing power or crashing, the last &lt;em&gt;x&lt;/em&gt; bytes of data may not yet have been written. To work around this, you should flush your output buffers after writing anything. Note though that this may cause higher battery drain and/or more frequent writes to the flash drive (reducing its potential lifespan). In Python this can be done as&lt;br /&gt;&lt;br /&gt;&lt;code&gt;outfile.write(data)&lt;br /&gt;outfile.flush()&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;A reasonable trade-off may be to do this after a group of writes rather than each individual write.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Troubleshooting&lt;/strong&gt;&lt;br /&gt;While working on allowing automated logging of much larger amounts of data in my system, I had a problem getting a Gumstix Verdex board running OpenEmbedded to mount a USB flash drive. The Verdex boards have USB host capability (made available via an Audiostix2 board), and the one I was using was recognising the flash drive when it was plugged. It was in fact doing everything needed up to the point of actually mounting the drive into the filesystem. My &lt;code&gt;dmesg&lt;/code&gt; output was:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;code&gt;&amp;lt;6&amp;gt;usb 1-2: new full speed USB device using pxa27x-ohci and address 2&lt;br /&gt;&amp;lt;6&amp;gt;usb 1-2: configuration #1 chosen from 1 choice&lt;br /&gt;&amp;lt;5&amp;gt;SCSI subsystem initialized&lt;br /&gt;&amp;lt;6&amp;gt;Initializing USB Mass Storage driver...&lt;br /&gt;&amp;lt;6&amp;gt;scsi0 : SCSI emulation for USB Mass Storage devices&lt;br /&gt;&amp;lt;6&amp;gt;usbcore: registered new interface driver usb-storage&lt;br /&gt;&amp;lt;6&amp;gt;USB Mass Storage support registered.&lt;br /&gt;&amp;lt;7&amp;gt;usb-storage: device found at 2&lt;br /&gt;&amp;lt;7&amp;gt;usb-storage: waiting for device to settle before scanning&lt;br /&gt;&amp;lt;5&amp;gt;scsi 0:0:0:0: Direct-Access CBM Flash Disk 5.00 PQ: 0 ANSI: 2&lt;br /&gt;&amp;lt;7&amp;gt;usb-storage: device scan complete&lt;/code&gt;&lt;/blockquote&gt;&lt;br /&gt;And that was all that happened. Web knowledge said "it just works" (as long as you tweak your kernel build, depending on the OpenEmbedded revision in use), which obviously it didn't. The relevant modules being loaded were &lt;code&gt;usb_storage&lt;/code&gt;, &lt;code&gt;scsi_mod&lt;/code&gt;, &lt;code&gt;ohci_hcd&lt;/code&gt;, and &lt;code&gt;usbcore&lt;/code&gt;.&lt;br /&gt;&lt;br /&gt;Eventually I did the magic correct search and came across &lt;a href="http://markmail.org/message/r3i2aat4mg2pki55"&gt;this&lt;/a&gt;, which points out that the &lt;code&gt;sd_mod&lt;/code&gt; module also needs to be loaded. I duly probed my mod and voila:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;code&gt;&amp;lt;5&amp;gt;SCSI device sda: 2068992 512-byte hdwr sectors (1059 MB)&lt;br /&gt;&amp;lt;5&amp;gt;sda: Write Protect is off&lt;br /&gt;&amp;lt;7&amp;gt;sda: Mode Sense: 0b 00 00 08&lt;br /&gt;&amp;lt;3&amp;gt;sda: assuming drive cache: write through&lt;br /&gt;&amp;lt;5&amp;gt;SCSI device sda: 2068992 512-byte hdwr sectors (1059 MB)&lt;br /&gt;&amp;lt;5&amp;gt;sda: Write Protect is off&lt;br /&gt;&amp;lt;7&amp;gt;sda: Mode Sense: 0b 00 00 08&lt;br /&gt;&amp;lt;3&amp;gt;sda: assuming drive cache: write through&lt;br /&gt;&amp;lt;6&amp;gt; sda: sda1&lt;br /&gt;&amp;lt;5&amp;gt;sd 0:0:0:0: Attached scsi removable disk sda&lt;/code&gt;&lt;/blockquote&gt;&lt;br /&gt;I also got some errors reading the filesystem:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;code&gt;&amp;lt;3&amp;gt;FAT: invalid media value (0x06)&lt;br /&gt;&amp;lt;6&amp;gt;VFS: Can't find a valid FAT filesystem on dev sda.&lt;/code&gt;&lt;/blockquote&gt;&lt;br /&gt;But on mounting, it was perfectly valid.&lt;br /&gt;&lt;br /&gt;I was intended to detail how to get this all to happen automatically, but on a new out-of-the-box Verdex (or as new as they got before being discontinued), it seems it works as it should. It is possibly a problem with the images we have created, and this post is then not useful for 99% of you in that case. However it has happened to me and at least one other person (and the solution provider knew what to do, so possibly more people also). In summary: YMMV.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-3283341414607150841?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/3283341414607150841/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/12/gumstix-and-usb-flash.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/3283341414607150841'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/3283341414607150841'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/12/gumstix-and-usb-flash.html' title='Gumstix Verdex and USB flash'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-BKWfP0cxLcs/TxmpIvX8YbI/AAAAAAAAAM0/XxR0mQRc_MQ/s72-c/gumstix_USB_flash.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-7785241828807104821</id><published>2009-10-25T21:32:00.006Z</published><updated>2009-10-26T12:38:03.256Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='python tips'/><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>Python tips - Reverse iteration</title><content type='html'>&lt;span style="font-style:italic;"&gt;My apologies to those subscribing to this feed, as I'm not sure how your reader will handle a heavily modified post. You'll either get an effective duplicate or just not see this.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This post, the first in what will be a sporadic series, relates to a mistake I saw recently when looking at through some Python code. The author had used the following method to iterate backwards through a list:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;for i in range(len(foo)):&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;print foo[-i]&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;It wasn't a &lt;tt&gt;print&lt;/tt&gt; in the original, it was something else which would have been far harder to spot had it introduced subtle errors into the results of the code. Given Python's ability to index from the end of a list using negative indices, this seems to be a suitable solution. The problem here is that &lt;tt&gt;foo[-0]&lt;/tt&gt; isn't the last item in the list, &lt;tt&gt;foo[-1]&lt;/tt&gt; is. The correct code the author was looking for was:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;for i in reversed(range(len(foo))):&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;print foo[i]&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Even better, if you don't need to know the index you're currently looking at:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;for item in reversed(foo):&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;print item&lt;/tt&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-7785241828807104821?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/7785241828807104821/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/10/python-mistakes-reverse-iteration.html#comment-form' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7785241828807104821'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7785241828807104821'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/10/python-mistakes-reverse-iteration.html' title='Python tips - Reverse iteration'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-907135443298677941</id><published>2009-10-10T18:52:00.005Z</published><updated>2009-12-05T23:23:54.350Z</updated><title type='text'>Upcoming posts</title><content type='html'>In the absence of a real post recently, here's a quick list of planned topics which will be upcoming soon. In no particular order:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Bluetooth configuration with BlueZ 3.x (specifically with regard to Gumstix devices)&lt;/li&gt;&lt;li&gt;Differences between the GSS C20 CO2 sensor datasheet and the actual implementation - &lt;span style="font-style:italic;"&gt;now up &lt;a href="http://kempproject.blogspot.com/2009/10/gss-c20-co2-sensor.html"&gt;here&lt;/a&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Using PICs as I2C slaves to a Gumstix device (probably a multi-part with input from a couple of other people)&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;If you have a particular desire for any of these (or indeed, a suggestion for another) then feel free to leave a comment.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-907135443298677941?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/907135443298677941/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/10/upcoming-posts.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/907135443298677941'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/907135443298677941'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/10/upcoming-posts.html' title='Upcoming posts'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2101510887759565639</id><published>2009-08-25T15:48:00.004Z</published><updated>2009-08-25T15:52:48.658Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='events'/><title type='text'>IeMRC 4th Annual Conference</title><content type='html'>If you are on &lt;a href="http://www.linkedin.com"&gt;LinkedIn&lt;/a&gt; and are attending the IeMRC 4th Annual Conference then pop your name on the &lt;a href="http://events.linkedin.com/IeMRC-4th-Annual-Conference/pub/113892"&gt;list&lt;/a&gt; and see who else is coming :-) I am likely to be &lt;a href="http://twitter.com/kemp"&gt;twittering&lt;/a&gt; the event as &lt;a href="http://kempproject.blogspot.com/2008/03/twittering-iemrc.html"&gt;before&lt;/a&gt;, so watch out for updates on the day. I will post a compilation of the twitters here.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2101510887759565639?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2101510887759565639/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/08/iemrc-4th-annual-conference.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2101510887759565639'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2101510887759565639'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/08/iemrc-4th-annual-conference.html' title='IeMRC 4th Annual Conference'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2558484448626378962</id><published>2009-08-24T14:03:00.011Z</published><updated>2009-08-24T15:03:26.471Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Simple DHCP Server Setup</title><content type='html'>In this post I will discuss a simple way to set up a DHCP server for a small network. By "small network" in this case I mean examples such as a home network with a few machines on, or a group of &lt;a href="http://www.gumstix.com"&gt;Gumstix&lt;/a&gt; devices communicating with a PC over BNEP PAN connections. If you've read my previous posts then you'll know that the latter is my main interest, and that anything I say here is based on my use of &lt;a href="http://www.ubuntu.com"&gt;Ubuntu&lt;/a&gt;. Originally, I was going to talk about the use of gadmin-dhcpd from the &lt;a href="http://gadmintools.flippedweb.com/"&gt;Gadmin&lt;/a&gt; set of tools, but in the end I decided that manual configuration isn't actually hard enough to warrant a graphical tool (for my purposes at least).&lt;br /&gt;&lt;br /&gt;So with the niceties over with, let's get going. First you need to install dhcp3-server if you haven't already:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo apt-get install dhcp3-server&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;This should create files at &lt;tt&gt;/etc/default/dhcp3-server&lt;/tt&gt; and &lt;tt&gt;/etc/dhcp3/dhcpd.conf&lt;/tt&gt;. We will look at each of these in turn.&lt;br /&gt;&lt;br /&gt;Open this up &lt;tt&gt;/etc/default/dhcp3-server&lt;/tt&gt; your favourite editor (in this case Emacs):&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo emacs /etc/dhcp3/dhcpd.conf&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;This file controls the interfaces on which the server will listen for requests. The final line will currently read something like &lt;tt&gt;INTERFACES=""&lt;/tt&gt;. Your list of interfaces should be space-separated identifiers. In the case here of a small Gumstix network (assuming you have set up bridging previously, either manually or via &lt;a href="http://kempproject.blogspot.com/2009/08/bnep-pan-connections-with-bluez-4x.html"&gt;Blueman&lt;/a&gt;), you want to change the line to read &lt;tt&gt;INTERFACES="pan0"&lt;/tt&gt;. Your bridge may be &lt;tt&gt;pan1&lt;/tt&gt; or some other number, use the &lt;tt&gt;ifconfig&lt;/tt&gt; command to find it. That is all the configuration needed in that file, so close it now.&lt;br /&gt;&lt;br /&gt;The next file to edit is &lt;tt&gt;/etc/dhcp3/dhcpd.conf&lt;/tt&gt;, which controls the configuration of what addresses are assigned, what range they are assigned from, etc. Open this file as above:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo emacs /etc/dhcp3/dhcpd.conf&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;This file is likely to have more content than the previous, but don't worry about that for now. Any options you specify in a moment will override existing global options. Let's consider again the case of the Gumstix network. In my case the subnet in use is &lt;tt&gt;192.168.2.0/24&lt;/tt&gt;, and a PC is acting as the DHCP server at &lt;tt&gt;192.168.2.1&lt;/tt&gt;. There is only one more thing you need to decide for the simplest case - what range of addresses to use. In this example we will use &lt;tt&gt;192.168.2.100&lt;/tt&gt; to &lt;tt&gt;192.168.2.200&lt;/tt&gt;. To allow this, the following should be added to the end of the configuration file:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;subnet 192.168.2.0 netmask 255.255.255.0 {&lt;br /&gt;    interface pan0;&lt;br /&gt;    range 192.168.2.100 192.168.2.200;&lt;br /&gt;    option subnet-mask 255.255.255.0;&lt;br /&gt;    option broadcast-address 192.168.1.255;&lt;br /&gt;    option routers 192.168.2.1;&lt;br /&gt;}&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;You may also add lines between the braces to control the lease time, address of DNS servers, etc. These aren't necessary for our example, but maybe you have a more complex system:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;default-lease-time 600;&lt;br /&gt;max-lease-time 7200;&lt;br /&gt;option domain-name-servers 192.168.2.10, 192.168.2.11;&lt;br /&gt;option domain-name "somedomain.example";&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;In addition to assigning a block of IP addresses on request, you may also specify that certain devices should always be assigned a particular address. For instance, maybe one Gumstix device is used to resolve DNS requests:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;host dns-stix {&lt;br /&gt;    hardware ethernet AB:CD:EF:12:34:56:78;&lt;br /&gt;    fixed-address 192.168.2.10;&lt;br /&gt;}&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Again, this my only be useful in more complex systems, but the capability is there.&lt;br /&gt;&lt;br /&gt;Once all your configuration is complete, restart the DHCP server software and relax in the glow of auto-assigned IP addresses:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo /etc/init.d/dhcp3-server restart&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;I hope this has given you what you need to explore the options in more detail. The following pages may be useful for more information:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="https://help.ubuntu.com/community/dhcp3-server"&gt;Ubuntu Community documentation&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://knowledge76.com/index.php/DHCP_Server"&gt;Knowledge76.com wiki article&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://freebsd.active-venture.com/handbook/network-dhcp.html"&gt;FreeBSD documentation&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;I noticed on &lt;a href="http://oei.yungchin.nl/2008/03/02/notes-on-dhcp3-server/"&gt;another blog&lt;/a&gt; that suspend/hibernate requires the DHCP server to be restarted on resume, this probably won't be a problem for most of you and I don't know if this occurs in current versions, just a heads up in case you need to know.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2558484448626378962?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2558484448626378962/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/08/simple-dhcp-server-setup.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2558484448626378962'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2558484448626378962'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/08/simple-dhcp-server-setup.html' title='Simple DHCP Server Setup'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-7752250236734963138</id><published>2009-08-06T13:32:00.012Z</published><updated>2012-01-20T18:19:48.472Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>Linux Ethernet Bridging</title><content type='html'>Ethernet bridging allows automated routing between multiple interfaces on your computer. They don't necessarily have to be of the same type, as long as they carry IP protocol traffic. For instance, two Bluetooth BNEP PAN connections and a normal 100BASE-T Ethernet interface can be bridged together. This allows a host on one of the PAN connections to communicate with a host somewhere on the Ethernet network without any extra effort from you, as long as they share a common subnet.&lt;br /&gt;&lt;br /&gt;My own use of this type of bridging is entirely with BNEP PAN connections to allow &lt;a href="http://www.gumstix.com"&gt;Gumstix&lt;/a&gt; devices to talk to each other via the emulated Ethernet network without regard to which devices are master or slave or how the packets are being routed in the underlying PAN. In this scheme, I have one Gumstix device running Ethernet bridging as the master of the PAN, with a PC and several other Gumstix devices as slaves. It doesn't matter that all traffic is routed via the network master as this is hidden several layers below my view.&lt;br /&gt;&lt;br /&gt;To get started you first have to install the bridge-utils package on the device performing the bridging. This provides the &lt;a href="http://linuxcommand.org/man_pages/brctl8.html"&gt;&lt;tt&gt;brctl&lt;/tt&gt;&lt;/a&gt; program.&lt;br /&gt;&lt;br /&gt;On an Ubuntu PC:&lt;br /&gt;&lt;tt&gt;sudo apt-get install bridge-utils&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;On a correctly configured OE Gumstix device:&lt;br /&gt;&lt;tt&gt;ipkg install bridge-utils&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;(From here I will only give the commands for the PC case, the Gumstix device will be identical except that you don't need to use sudo.) Next you create a bridge, which in turn creates a virtual interface.&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo brctl addbr bridge0&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;In this case, the bridge is called (unimaginatively) bridge0. Note that if you followed my &lt;a href="http://kempproject.blogspot.com/2009/08/bnep-pan-connections-with-bluez-4x.html"&gt;previous instructions&lt;/a&gt; for setting up BNEP PAN networks under BlueZ 4.x, Blueman actually forms a bridge behind the scenes called pan0. Next you configure the bridge. Remember that all bridged connections should be on the same subnet. The interfaces for each connection are not given IP addresses. Instead the bridge is given an address.&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo ifconfig bridge0 xxx.xxx.xxx.xxx&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Replace &lt;tt&gt;xxx.xxx.xxx.xxx&lt;/tt&gt; with the appropriate network address, for instance &lt;tt&gt;192.168.2.1&lt;/tt&gt;. Next, select an interface to add to the bridge, make sure it is not configured with its own IP address, and add it to the bridge.&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo ifconfig xxx 0.0.0.0&lt;br /&gt;&lt;br /&gt;sudo brctl addif bridge0 xxx&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Replace &lt;tt&gt;xxx&lt;/tt&gt; with the name of the interface (&lt;tt&gt;eth0&lt;/tt&gt;, &lt;tt&gt;eth1&lt;/tt&gt;, &lt;tt&gt;bnep0&lt;/tt&gt;, etc). That's it, once you've added the interfaces you need the bridge will take care of the rest.&lt;br /&gt;&lt;br /&gt;As an idea of how I achieve bridging over a PAN on a Gumstix device, I generally place a boot script on the device with the following:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;#!/bin/sh&lt;br /&gt;brctl addbr pan0&lt;br /&gt;ifconfig pan0 192.168.2.`cat /etc/id`&lt;br /&gt;brctl stp pan0 off&lt;br /&gt;brctl setfd pan0 0&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Those final two lines turn off STP and set the forwarding delay to 0 in order to prevent additional delay in setting up the network when interfaces are added/removed from the bridge. This should &lt;span style="font-weight:bold;"&gt;only&lt;/span&gt; be done if there is no chance of routing loops in the network (which should be true if the only participants in the bridged network are members of the PAN, though be careful if using a Scatternet).&lt;br /&gt;&lt;br /&gt;Next, I place the following script in &lt;tt&gt;/etc/bluetooth/pan/dev-up&lt;/tt&gt; to be called whenever a new incoming Bluetooth connection is created:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;#!/bin/sh&lt;br /&gt;ifconfig $1 0.0.0.0&lt;br /&gt;brctl addif pan0 $1&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;That's the lot. Hope this helps.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-7752250236734963138?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/7752250236734963138/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/08/linux-ethernet-bridging.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7752250236734963138'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7752250236734963138'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/08/linux-ethernet-bridging.html' title='Linux Ethernet Bridging'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2670830351796794385</id><published>2009-08-05T13:57:00.014Z</published><updated>2011-08-25T09:24:20.703Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>Gumstix Boot Scripts</title><content type='html'>This post covers the basics of setting up a script to run at boot on a &lt;a href="http://www.gumstix.com"&gt;Gumstix&lt;/a&gt; device (with Buildroot or OE). As the Gumstix devices use Linux as their OS of choice, this method will apply to any Linux machine running similar versions of things, though your particular distribution may have a preferred method (for instance Ubuntu now uses &lt;a href="http://upstart.ubuntu.com/"&gt;upstart&lt;/a&gt;). I'm considering this article to be Gumstix specific as most System V based distributions will have a series of scripts enabling you to manage startup scripts more easily. This article is still applicable if you want to perform the task manually though.&lt;br /&gt;&lt;br /&gt;The way that things work with the System V init daemon (and compatible systems) is generally:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;At boot, the daemon iterates over a series of symlinks in &lt;tt&gt;/etc/rc&lt;i&gt;x&lt;/i&gt;.d/&lt;/tt&gt;, where &lt;tt&gt;&lt;i&gt;x&lt;/i&gt;&lt;/tt&gt; is the runlevel that is being entered at the time.&lt;/li&gt;&lt;li&gt;These symlinks point to scripts within &lt;tt&gt;/etc/init.d/&lt;/tt&gt; which perform the actual tasks required.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;Assume you have a program at &lt;tt&gt;/home/root/myApp&lt;/tt&gt; that you wish to run automatically on boot. The first thing to do is add a script into &lt;tt&gt;/etc/init.d/&lt;/tt&gt; which does exactly that. We will call it myApp.sh to indicate which program it is going to run, but the name isn't significant as long as it's meaningful to you. You should change to the correct directory:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;cd /etc/init.d/&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;You can then use your favourite editor to create the script with the following content:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;#!/bin/sh&lt;br /&gt;/home/root/myApp &amp;&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;The &lt;tt&gt;&amp;&lt;/tt&gt; is important here if your program is expected to continue running for a while (or forever) as it runs the program as a background task (meaning that the startup process will continue as soon as your script has begun executing). If you forget the &lt;tt&gt;&amp;&lt;/tt&gt; then the boot process will wait for your program to exit and you won't be able to (for instance) log in using SSH until this happens, if it ever does. This script should be marked as executable:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;chmod +x myApp.sh&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Your next step is to add a symlink to this script from &lt;tt&gt;/etc/rc5.d/&lt;/tt&gt;. This is where the boot process actually picks up the script from. There are other places you can link from if your program does something deep down in the system and needs to run really early in the boot process, but in general for user apps you want &lt;tt&gt;rc5.d&lt;/tt&gt;. The symlinks in this directory all follow a standard naming scheme:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;Syyxxxxxxx&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Where &lt;tt&gt;yy&lt;/tt&gt; is a number which provides the ordering for when the scripts are run and &lt;tt&gt;xxxxxxx&lt;/tt&gt; is a name given by you for your own reference (i.e. the system doesn't care about it). For those of you of an inquisitive nature, the "&lt;tt&gt;S&lt;/tt&gt;" (uppercase) means to run this script when the system is starting up, as opposed to shutting down.&lt;br /&gt;&lt;br /&gt;The highest number script which is generally pre-installed on a basic Gumstix Buildroot or OE system is &lt;tt&gt;S90&lt;/tt&gt; so I usually pick numbering starting at &lt;tt&gt;S95&lt;/tt&gt;. Change to the /etc/rc5.d/ directory and then create the symlink:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;cd /etc/rc5.d/&lt;br /&gt;ln -s ../init.d/myApp.sh S96myApp&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;The reason for choosing &lt;tt&gt;S96&lt;/tt&gt; here is that in general I have another script at &lt;tt&gt;S95&lt;/tt&gt; which sets up some extra things such as &lt;a href="http://kempproject.blogspot.com/2009/08/linux-ethernet-bridging.html"&gt;ethernet bridging&lt;/a&gt;. You can check the symlink was created correctly by running &lt;tt&gt;ls -la&lt;/tt&gt; in the &lt;tt&gt;/etc/rc5.d/&lt;/tt&gt; directory. You should see a line similar to the following among the output of this command:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;lrwxrwxrwx 1 root root 18 2009-08-21 15:28 S96myApp -&gt; ../init.d/myApp.sh&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;The next time the Gumstix device boots the script should run and start your program in the background. If you want to test it beforehand, simply run&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;/etc/rc5.d/S96myApp&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Though remember that your target script will be started as a background task, so you can't exit via &lt;tt&gt;Ctrl+C&lt;/tt&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2670830351796794385?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2670830351796794385/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/08/gumstix-boot-scripts.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2670830351796794385'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2670830351796794385'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/08/gumstix-boot-scripts.html' title='Gumstix Boot Scripts'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-1074578106083687699</id><published>2009-08-03T16:50:00.026Z</published><updated>2009-09-21T12:26:05.424Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='bluetooth'/><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>BNEP PAN Connections with BlueZ 4.x</title><content type='html'>When &lt;a href="http://www.ubuntu.com"&gt;Ubuntu&lt;/a&gt; adopted &lt;a href="http://www.bluez.org"&gt;BlueZ&lt;/a&gt; 4.x as its Bluetooth suite of choice a lot of things broke, especially if you were doing more than just connecting to your phone. Unfortunately for us, we were doing a lot more than that. This mean that under Intrepid we had to force a downgrade to the Hardy version of BlueZ (3.26/3.29), an option which vanished with Jaunty as the package installation threw errors.&lt;br /&gt;&lt;br /&gt;Despite a lot of discussion of this issue, it seems to be quite hard to find a real solution where someone has said "install this, tweak this, that'll fix it for you". However, today I successfully created a PAN network between my desktop and a Gumstix device using BlueZ 4.x, and here's how I did it.&lt;br /&gt;&lt;br /&gt;&lt;i&gt;Note that there is some configuration needed on the Gumstix side which is not covered here and will be the subject of a future post.&lt;/i&gt;&lt;br /&gt;&lt;br /&gt;First, you need to add the &lt;a href="https://launchpad.net/~blueman"&gt;Blueman&lt;/a&gt; &lt;a href="https://launchpad.net/~blueman/+archive/ppa"&gt;PPA repository&lt;/a&gt; and GPG key to your software sources list. You can do this the graphical way as described on the website, or run the following commands:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 951DC1E2&lt;br /&gt;&lt;br /&gt;echo 'deb http://ppa.launchpad.net/blueman/ppa/ubuntu jaunty main' | sudo tee -a /etc/apt/sources.list&lt;br /&gt;&lt;br /&gt;echo 'deb-src http://ppa.launchpad.net/blueman/ppa/ubuntu jaunty main' | sudo tee -a /etc/apt/sources.list&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Then you update your package list and install Blueman:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo apt-get update&lt;br /&gt;&lt;br /&gt;sudo apt-get install blueman dhcp3-server&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;We install dhcp3-server so that the option is there to hand out IP addresses to clients on the PAN (the subject of &lt;a href="http://kempproject.blogspot.com/2009/08/simple-dhcp-server-setup.html"&gt;another post&lt;/a&gt;). There is another method presented by Blueman, but I know nothing about that one, so I can't advise.&lt;br /&gt;&lt;br /&gt;At this point you'll want to log out and back in to make sure you have the Blueman applet running. Right-click on the Bluetooth icon (near the clock towards the right-hand side of the top panel with the default GNOME configuration, but usually only if you have Bluetooth hardware available). Click on Local Services, select Network, enable Network Access Point (NAP), select dhcpd3 as the DHCP server type, and enter the IP address you want to use for this machine. It should look like the screenshot below:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_VomNIoC7I3k/Sncgqze1RRI/AAAAAAAAAGo/pWDcpzmZ_9U/s1600-h/Blueman-network.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 271px;" src="http://2.bp.blogspot.com/_VomNIoC7I3k/Sncgqze1RRI/AAAAAAAAAGo/pWDcpzmZ_9U/s320/Blueman-network.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5365793400781358354" /&gt;&lt;/a&gt;&lt;br /&gt;I have selected to let Blueman handle my connection because I don't trust NetworkManager, you should be able to use whatever you're happy with.&lt;br /&gt;&lt;br /&gt;Now you just need to pair the Gumstix and your PC. As BlueZ 4.x enforces the use of PINs much more than 3.x did, you'll need to add a &lt;a href="http://kempproject.blogspot.com/2009/08/gumstix-boot-scripts.html"&gt;boot script&lt;/a&gt; to your Gumstix (a symlink in &lt;tt&gt;/etc/rc5.d/&lt;/tt&gt; to a script in &lt;tt&gt;/etc/init.d/&lt;/tt&gt;) with following contents:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;#!/bin/sh&lt;br /&gt;passkey-agent --default 0000 &amp;&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;Replace &lt;tt&gt;0000&lt;/tt&gt; with your desired PIN. Additionally, you'll want to edit &lt;tt&gt;/etc/bluetooth/hcid.conf&lt;/tt&gt; (also on the Gumstix device) to use the same PIN and set &lt;tt&gt;security&lt;/tt&gt; to &lt;tt&gt;auto&lt;/tt&gt;. One of these is used for incoming connections and one for outgoing. At this point you can either restart Bluetooth and run &lt;tt&gt;passkey-agent&lt;/tt&gt; (or the startup script) manually, or you can just reboot the Gumstix device. I'd suggest the latter.&lt;br /&gt;&lt;br /&gt;Next, left-click the Bluetooth icon on your PC to open the devices list. Click the search button and then right-click your Gumstix, click Add Device, then right-click again and select Bond. It should ask for the PIN at this stage, use the one you selected earlier. Now you can use pand on the Gumstix to connect to the PC and you should be asked for the PIN one last time, followed by a popup asking if you want to allow a BNEP connection. Test the connection by pinging the Gumstix device, but remember that STP is active on the bridge that Blueman creates, so there will be a delay before the ping attempts start to succeed.&lt;br /&gt;&lt;br /&gt;As if by magic, a working PAN connection using BlueZ 4.x. Related future topics for posts will be:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="http://kempproject.blogspot.com/2009/08/gumstix-boot-scripts.html"&gt;Gumstix boot scripts&lt;/a&gt;&lt;/li&gt;&lt;li&gt;Gumstix Bluetooth configuration and use (BlueZ 3.x)&lt;/li&gt;&lt;li&gt;&lt;a href="http://kempproject.blogspot.com/2009/08/linux-ethernet-bridging.html"&gt;Linux network bridging&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://kempproject.blogspot.com/2009/08/simple-dhcp-server-setup.html"&gt;Simple DHCP server configuration&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;i&gt;Edit:&lt;br /&gt;For those of you wanting to use your phone with Ubuntu and BlueZ 4.x, check out &lt;a href="http://bigbrovar.wordpress.com/2009/02/14/blueman-an-awesome-bluetooth-manager-for-ubuntu/"&gt;this&lt;/a&gt;.&lt;/i&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-1074578106083687699?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/1074578106083687699/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/08/bnep-pan-connections-with-bluez-4x.html#comment-form' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1074578106083687699'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1074578106083687699'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/08/bnep-pan-connections-with-bluez-4x.html' title='BNEP PAN Connections with BlueZ 4.x'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_VomNIoC7I3k/Sncgqze1RRI/AAAAAAAAAGo/pWDcpzmZ_9U/s72-c/Blueman-network.png' height='72' width='72'/><thr:total>5</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-6597641022120715382</id><published>2009-02-09T16:46:00.026Z</published><updated>2012-01-20T18:05:39.770Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>Interfacing: B530 CO2 sensor and Gumstix</title><content type='html'>The group obtained some &lt;a href="http://www.elti.co.kr/new/eng/co2-sensor-module-b530.htm"&gt;B530&lt;/a&gt; CO&lt;sub&gt;2&lt;/sub&gt; sensors (produced by &lt;a href="http://www.elti.co.kr/new/board/emain.html"&gt;ELT, Inc.&lt;/a&gt;) to interface to some Arch Rock nodes as part of another project. The datasheet is located &lt;a href="http://www.elti.co.kr/new/board/bbs/download.php?bo_table=e_data&amp;wr_id=1&amp;no=0"&gt;here&lt;/a&gt;. As a first iteration of my own CO&lt;sub&gt;2&lt;/sub&gt; sensing setup I borrowed one of the devices to connect to a Verdex Gumstix device. This article gives an overview of how I achieved this, along with some hints and gotchas related to using the sensor.&lt;br /&gt;&lt;br /&gt;For the physical connection I used a serial port, which is in itself a bit of a minefield on the Gumstix platform. I will cover the Verdex but this should apply to the Connex as well. Bear in mind that they changed the meaning/use of some UARTs between revisions, so be careful. On our in-house expansion boards we are able to attach a MaxStream XBee radio module and fortunately this uses a serial port, so the data lines are already broken out for me on the connector and the choice of which UART to use has already been made (in this case STUART/IR[TX|RX]/ttyS2 to my knowledge). From here it was a simple matter to connect the serial lines on the B530 to the appropriate place on the expansion board. I fashioned a 9-10v power supply out of 8 rechargable AAA/LR03/AM4 cells and the hardware aspect was done for now. Making a robust connection and power supply was a task for a separate session. A picture of the final connected sensor is below. Note that it is hooked up to Medusa2's upper body node, which is attached to part of one of the node box lids. This half-packaged state makes it really easy to handle without having to worry so much about ESD issues.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_VomNIoC7I3k/SZivWQSaotI/AAAAAAAAAGg/MD0MqXOleNg/s1600-h/co2-proto.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 224px;" src="http://2.bp.blogspot.com/_VomNIoC7I3k/SZivWQSaotI/AAAAAAAAAGg/MD0MqXOleNg/s320/co2-proto.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5303181358092952274" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Next the software. As usual, everything is done in Python. The node needed the &lt;tt&gt;pySerial&lt;/tt&gt; package installed, which in turn relies on the &lt;tt&gt;stringold&lt;/tt&gt; package (and possibly other things that I already had installed). To open the sensor for reading, simply perform&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;dev = serial.Serial("/dev/ttyS2", 38400, timeout=6)&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;To open at the correct speed and with a timeout twice the amount of time between samples to ensure timing issues don't cause a false timeout. Reading is then performed via&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;data = dev.read(11)&lt;br /&gt;value = int(data[:4])&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;And there you go, simplicity itself thanks to the power of Python. As noted previously, the timeout is set to six seconds in order to allow for delayed readings. However, the sensor seems to provide samples on the specified three second interval to within about 0.01 seconds. A read is performed as often as possible and allowed to block until the next value is available.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Gotchas&lt;/span&gt;&lt;br /&gt;There are a few things to look out for in you code when you are using the B530:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;I have on occasion missed a byte or two, resulting in the data I retrieve not being quite what I expect (for instance getting the last 9 bytes of one sample and the first 2 of the next). This may be a sensor fault, or it may be my physical connection being less reliable than expected. Either way I wrote a function to detect the start of a sample and realign the reads when needed. Of course, the problems seemed to immediately stop then (not because of the code), so the routine hasn't been tested (and your mileage may vary).&lt;/li&gt;&lt;li&gt;Yes, the sample size is 11 bytes. Even though the datasheet quotes 10 bytes and tells you what they should be, all of our B530 units give 11 byte samples. There is an extra &lt;tt&gt;0x0A&lt;/tt&gt; on the end.&lt;/li&gt;&lt;li&gt;If the CO&lt;sub&gt;2&lt;/sub&gt; concentration goes above 10,000 ppm the sample you retrieve will have the characters &lt;code&gt;OVER&lt;/code&gt; in place of the value, you need to check for this or the &lt;code&gt;int()&lt;/code&gt; call will fail. This isn't documented in the datasheet.&lt;/li&gt;&lt;li&gt;It is, of course, much better to use &lt;code&gt;dev.readline()&lt;/code&gt; rather than &lt;code&gt;dev.read(11)&lt;/code&gt; with a fixed read size. This way you automatically get compensated if your devices suddenly start obeying the datasheet, and you know that even if you miss bytes then the next read should still be aligned with the start of the message correctly.&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-6597641022120715382?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/6597641022120715382/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2009/02/interfacing-b530-co2-sensor-and-gumstix.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6597641022120715382'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6597641022120715382'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2009/02/interfacing-b530-co2-sensor-and-gumstix.html' title='Interfacing: B530 CO2 sensor and Gumstix'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_VomNIoC7I3k/SZivWQSaotI/AAAAAAAAAGg/MD0MqXOleNg/s72-c/co2-proto.jpg' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2992154374658488830</id><published>2008-03-06T17:51:00.002Z</published><updated>2009-08-25T15:53:05.586Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='events'/><title type='text'>Twittering the IeMRC</title><content type='html'>In preparation for a real post, here's a compilation of my twitter updates from the IeMRC Annual Renewal Review yesterday.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;In l'boro for the IeMRC Annual Renewal Review. Presenting later, weather is freezing. Apparently Buffy wasn't available on the train (buffet).&lt;br /&gt;09:36 AM March 05, 2008 from txt&lt;br /&gt;&lt;br /&gt;If I have to listen to background music, I can think of much worse than Pachelbel's Canon ^^&lt;br /&gt;10:25 AM March 05, 2008 from txt&lt;br /&gt;&lt;br /&gt;Tea break. Last pres: high-k capacitor techology. Posters get presented about 1pm&lt;br /&gt;11:03 AM March 05, 2008 from txt&lt;br /&gt;&lt;br /&gt;High *temperature* caps, my mistake. No klingonberry here :-o&lt;br /&gt;11:08 AM March 05, 2008 from txt&lt;br /&gt;&lt;br /&gt;Distance functions &gt; nurbs? ATM mechatronics, serious business. NISA looks interesting, Chan + Pont. Next presenter AWOL&lt;br /&gt;11:38 AM March 05, 2008 from txt&lt;br /&gt;&lt;br /&gt;There's food afoot :-D Also, poster session :-s 5 presentations until mine. Food though...&lt;br /&gt;12:21 PM March 05, 2008 from txt&lt;br /&gt;&lt;br /&gt;Glass PCBs? It's more likely than you think. Optical interconnects and similar thermal expansion to Si&lt;br /&gt;02:28 PM March 05, 2008 from txt&lt;br /&gt;&lt;br /&gt;It's all over, on my way to the train station. Presentation was ok&lt;br /&gt;04:36 PM March 05, 2008  from txt&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2992154374658488830?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2992154374658488830/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2008/03/twittering-iemrc.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2992154374658488830'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2992154374658488830'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2008/03/twittering-iemrc.html' title='Twittering the IeMRC'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-5641850432282050484</id><published>2008-01-30T17:20:00.000Z</published><updated>2008-01-30T18:01:05.837Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='bluetooth'/><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><title type='text'>Gumstix RFCOMM</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_VomNIoC7I3k/R6C3w3KbbKI/AAAAAAAAADk/Qdwf4FYFJCg/s1600-h/SBW001.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://1.bp.blogspot.com/_VomNIoC7I3k/R6C3w3KbbKI/AAAAAAAAADk/Qdwf4FYFJCg/s200/SBW001.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5161327223035882658" /&gt;&lt;/a&gt;&lt;br /&gt;Before I start the main post, I finally have a decent pic of one of the sensor boards I created. There are a couple more chips on the bottom as well, not shown.&lt;br /&gt;&lt;br /&gt;Click the thumbnail for a bigger image.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Now, onto the post proper. I recently had to set up &lt;a href="http://www.gumstix.com/"&gt;Gumstix&lt;/a&gt; device (in this case an old &lt;a href="http://gumstix.com/store/catalog/product_info.php?products_id=137"&gt;Connex 400xm-bt&lt;/a&gt; with an &lt;a href="http://www.gumstix.com/store/catalog/product_info.php?cPath=31&amp;products_id=158"&gt;Audiostix2&lt;/a&gt; expansion) to grab readings from a sensor. The sensor used a serial connection over Bluetooth's rfcomm. I wrote my application to open and read from &lt;tt&gt;/dev/rfcomm0&lt;/tt&gt; and tested it on the PC, everything worked fine (almost) first time. The only setup that had to be done was&lt;br /&gt;&lt;tt&gt;rfcomm bind 0 &amp;lt;device address&amp;gt; 1&lt;/tt&gt;&lt;br /&gt;though the trailing &lt;tt&gt;1&lt;/tt&gt; is optional for the most part. I cross-compiled the code and moved it onto the Connex, whereupon I got a load of errors. The channel being in use/busy, and permission denied opening the serial device were the more common ones that popped up. It is certainly an odd experience getting permission denied when you're root... Anyway, after googling on the matter I discovered something that should really have been obvious: rfcomm0 is reserved for creating a serial connection &lt;span style="font-style:italic;"&gt;to&lt;/span&gt; the Connex for the purpose of a remote shell. I quickly switched over to rfcomm1 and everything was happy.&lt;br /&gt;&lt;br /&gt;There you go, a simple but very annoying problem with a quick but not initially obvious fix. Hope this saves someone half an hour of their life :-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-5641850432282050484?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/5641850432282050484/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2008/01/gumstix-rfcomm.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/5641850432282050484'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/5641850432282050484'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2008/01/gumstix-rfcomm.html' title='Gumstix RFCOMM'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_VomNIoC7I3k/R6C3w3KbbKI/AAAAAAAAADk/Qdwf4FYFJCg/s72-c/SBW001.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-4520136316524076329</id><published>2007-09-18T22:58:00.000Z</published><updated>2007-09-18T23:11:38.586Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><title type='text'>My First PCBs</title><content type='html'>Today (actually yesterday when I post this, it's 11:59 as I type) I took delivery of the first professionally fabricated PCBs designed by me :-) No problems at all during the process, which is rather good considering it was my first real experience of the schematic -&gt; layout flow, including having to make custom schematic symbols and component footprints. They are slightly larger than I was hoping for, but they are the first revision and I was a bit worried how close the tolerances were for &lt;a href="http://pcbtrain.co.uk/"&gt;PCBTrain&lt;/a&gt;'s prototyping service. Things looked closer on the screen than they do in real life or I would have shaved a few millimeters off here and there. Anyway, pictures as soon as I get them :-)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Edit:&lt;br /&gt;It occurs to me that there was a whole new prototype between the last one I showed you and this one. It used our fancy new Gumstix expansion boards (designed in-house) and was a LOT more stable than my "home-made" versions. Pic below, it's a lot neater is it not?&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_VomNIoC7I3k/RvBbB4chDcI/AAAAAAAAAC0/tKYrQkI604A/s1600-h/new_prototype.jpg"&gt;&lt;img style="cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_VomNIoC7I3k/RvBbB4chDcI/AAAAAAAAAC0/tKYrQkI604A/s320/new_prototype.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5111685664955502018" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-4520136316524076329?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/4520136316524076329/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/09/my-first-pcbs.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/4520136316524076329'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/4520136316524076329'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/09/my-first-pcbs.html' title='My First PCBs'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_VomNIoC7I3k/RvBbB4chDcI/AAAAAAAAAC0/tKYrQkI604A/s72-c/new_prototype.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-1540042777338904383</id><published>2007-08-01T21:45:00.002Z</published><updated>2009-08-05T15:27:51.185Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='bluetooth'/><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>Linux -&gt; Linux Bluetooth PicoNets</title><content type='html'>&lt;b&gt;Important note:&lt;/b&gt;&lt;br /&gt;This post will soon be superseded by a new one due to several flaws with the configuration given below. For now, the setup of a BNEP PAN is detailed &lt;a href="http://kempproject.blogspot.com/2009/08/bnep-pan-connections-with-bluez-4x.html"&gt;here&lt;/a&gt;, dealing with configuration on the PC side, as well as some configuration on the Gumstix side.&lt;br /&gt;&lt;br /&gt;&lt;hr&gt;&lt;br /&gt;This is the first of my (hopefully) useful posts, which covers setting up a simple Bluetooth connection between two Linux machines. This is taken from my notes on connecting a Gumstix device to a PC, but should be applicable to most Linux -&gt; Linux connections. The assumption here is that you will be using the BlueZ stack and wish to set up a PicoNet (a basic Bluetooth network with one master and up to 7 slaves).&lt;br /&gt;&lt;br /&gt;Your first task is to decide which device will be the master and which will be the slaves. The configuration for each is discussed below.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Master Configuration&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Bluetooth configuration on the master is simple. The first file to edit is &lt;tt&gt;/etc/default/bluetooth&lt;/tt&gt; *, where the following lines must be modified:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;PAND_ENABLED=1 &lt;br /&gt;PAND_OPTIONS="--listen --role GN -u /etc/default/bluetooth/pan/dev-up"&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;The first line simply enables the pand functionality, while the second line specifies the following:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;The device should listen for connection attempts&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The device should act as a &lt;acronym title="Group Network controller"&gt;GN&lt;/acronym&gt; &lt;/li&gt;&lt;br /&gt;&lt;li&gt;The specified script should be executed whenever a connection is established&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;The next file to modify is &lt;tt&gt;/etc/bluetooth/hcid.conf&lt;/tt&gt;. Here there is only one line to set:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;lm accept,master; &lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;This tells the device to assert itself as master of the network. If this is not done then the device may negotiate to become a slave, which brings you into the realm of ScatterNets rather than PicoNets and is A Bad Thing (tm) in this case.&lt;br /&gt;&lt;br /&gt;If you are setting up a live system then you must also execute&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo /etc/init.d/bluetooth restart &lt;/tt&gt; **&lt;br /&gt;&lt;br /&gt;If you are going to be rebooting the device then you can ignore this step.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Slave Configuration&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The first file to edit is &lt;tt&gt;/etc/default/bluetooth&lt;/tt&gt; *, where the following lines must be modified:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;PAND_ENABLED=1 &lt;br /&gt;PAND_OPTIONS="--role PANU --service PANU --connect [master address] --persist"&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;The first line simply enables the pand functionality, while the second line specifies the following:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;The device should act as a PANU (&lt;acronym title="Personal Area Network"&gt;PAN&lt;/acronym&gt; User)&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The device should connect to the specified Bluetooth address&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The connection should be sustained even if not directly being used&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;You can determine the Bluetooth address of the master by running &lt;tt&gt;hciconfig&lt;/tt&gt; on it.&lt;br /&gt;&lt;br /&gt;The next file to modify is &lt;tt&gt;/etc/bluetooth/hcid.conf&lt;/tt&gt;. If you are working on a virgin system then this will likely be unnecessary, but it's always good to check. Here there is only one line to set:&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;lm accept;&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;This allows the device to accept another device as the network master rather than trying to become one itself.&lt;br /&gt;&lt;br /&gt;If you are setting up a live system then you must also execute&lt;br /&gt;&lt;br /&gt;&lt;tt&gt;sudo /etc/init.d/bluetooth restart &lt;/tt&gt; **&lt;br /&gt;&lt;br /&gt;If you are going to be rebooting the device then you can ignore this step.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;And there you have it, a quick guide to getting a network up and running between two Linux machines. You may notice a couple of the steps above aren't strictly necessary in the context given (such as the &lt;tt&gt;/etc/bluetooth/pan/dev-up&lt;/tt&gt; script being specified in &lt;tt&gt;/etc/default/bluetooth&lt;/tt&gt; on the master), this will be needed later for the ethernet emulation which makes these connections so much more useful.&lt;br /&gt;&lt;br /&gt;&lt;hr&gt;&lt;br /&gt;* Or &lt;tt&gt;/etc/default/bluez-utils&lt;/tt&gt; depending on your version of BlueZ&lt;br /&gt;&lt;br /&gt;** On some systems this will instead be&lt;br /&gt;&lt;tt&gt;sudo /etc/init.d/bluez-utils restart&lt;/tt&gt;&lt;br /&gt;depending on your BlueZ version, while a Gumstix device will instead require&lt;br /&gt;&lt;tt&gt;/etc/init.d/S30bluetooth stop &lt;br /&gt;/etc/init.d/S30bluetooth start&lt;/tt&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-1540042777338904383?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/1540042777338904383/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/08/linux-linux-bluetooth-connections.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1540042777338904383'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1540042777338904383'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/08/linux-linux-bluetooth-connections.html' title='Linux -&gt; Linux Bluetooth PicoNets'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-6357371257624806669</id><published>2007-07-17T00:53:00.001Z</published><updated>2007-09-18T23:04:54.054Z</updated><title type='text'>ToDo</title><content type='html'>I know, I know. I said I'd make this blog useful and have yet to deliver. So here is a quick list of things I plan to blog about.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Setting up &lt;a href="http://kempproject.blogspot.com/2007/08/linux-linux-bluetooth-connections.html"&gt;Bluetooth connections&lt;/a&gt; between a Gumstix device and a PC, including ethernet emulation&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Solving problems with the above&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Overview of building a system around a Gumstix device (from the hardware POV), mainly focusing on serial and I2C interfaces&lt;/li&gt;&lt;br /&gt;&lt;li&gt;On a more humorous theme : Mistakes to avoid while doing any of the above (ie, things me or someone I know have done)&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;I'll expand this list as and when I think of things, and link the list items to the relevant post as I get round to each one.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-6357371257624806669?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/6357371257624806669/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/07/todo.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6357371257624806669'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6357371257624806669'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/07/todo.html' title='ToDo'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-149652749901111846</id><published>2007-06-08T17:23:00.000Z</published><updated>2007-06-08T17:38:04.901Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><title type='text'>Expanding Requirements</title><content type='html'>This is always something to watch out for. Requirements in a software project have a habit of expanding out of control. Someone thinks "feature x would be nice here", someone else thinks "feature y would make my life easier" and before you know it they're both coming back with "why does this run so slowly? And why are there all these extra confusing features? I only wanted a couple of those!". Take this quote (modified for clarity) from &lt;a href="http://blogs.msdn.com/oldnewthing/archive/2004/05/25/141253.aspx#141370"&gt;here&lt;/a&gt;:&lt;br /&gt;&lt;blockquote&gt;So, I'll say notepad is good but there is a lot more they could add to make it more useful, such as:&lt;br /&gt;- Option to replace tab with x spaces&lt;br /&gt;- 'Open in new window' command&lt;br /&gt;- Auto-indent option&lt;br /&gt;- Make file loading much quicker&lt;br /&gt;&lt;br /&gt;Would be _very_ nice to also see support for regexp. in search and search&amp;replace.&lt;/blockquote&gt;&lt;br /&gt;Ok, fair enough, a lot of other editors have those features, but notepad is meant to be the most basic editor for when you just absolutely need to open a file without wasting resources on fancy features. Inevitably these feature requests were followed up with&lt;br /&gt;&lt;blockquote&gt;IMO it should still be lightweight&lt;/blockquote&gt;&lt;br /&gt;Ok, so lets take these feature requests, add the syntax highlighting, support for different line ending types, and god knows what else people want in an editor and suddenly it's not the same program anymore, the resource use has grown by a substantial amount and people are moaning that the extra features get in the way.&lt;br /&gt;&lt;br /&gt;Besides, anyone who wants to use notepad for anything that requires these features is probably doing that most famous of mistakes: Deciding on their (inappropriate) solution and then asking for help on fixing the solution to allow it to solve the problem, rather than asking for the best way to solve the problem. Download &lt;a href="http://www.flos-freeware.ch/notepad2.html"&gt;notepad2&lt;/a&gt; ;-) (Yes, it's freeware)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-149652749901111846?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/149652749901111846/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/06/expanding-requirements.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/149652749901111846'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/149652749901111846'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/06/expanding-requirements.html' title='Expanding Requirements'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-8984341190096978634</id><published>2007-05-05T17:08:00.000Z</published><updated>2007-05-05T17:26:41.968Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>Changing Buildroot Revision</title><content type='html'>As promised, the first in a line of (hopefully) useful posts. Today we cover three of the main effects of switching from one revision of the Gumstix buildroot to another. This can happen if you upgrade deliberately, or if you order a new batch and they happen to ship with a different revision.&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;b&gt;Binary Incompatibility&lt;/b&gt; - I'm not sure as to the minimum set of changes required to make binaries incompatible with the system, but if you change Buildroot revision it is something to look out for. For example, I am developing on both r773 and r1161 and you can guarantee binaries compiled for one won't work on the other. You may get messages such as "unrecognised character : ]" or just an outright "you fool, what are you doing?" (both paraphrased).&lt;br /&gt;&lt;br /&gt;&lt;li&gt;&lt;b&gt;Module Renaming&lt;/b&gt; - If I use the revisions mentioned above again, I can draw on the example of the sound modules. The sound driver in r773 was pxa-ac97, whereas in r1161 you use snd-pxa2xx-ac97, snd-pcm-oss, and snd-mixer-oss. If you're not expecting it then that sort of change can really throw you.&lt;br /&gt;&lt;br /&gt;&lt;li&gt;&lt;b&gt;Different Default Applications&lt;/b&gt; - Sometimes applications are added to or removed from the Buildroot default build. For example, in r773 you had brec and bplay (the basis of various of our demos due to their ease of use), whereas these are not included by default in r1161. Applications may also be compiled to a different place within the Buildroot, Python is an example of this between r773 and r1161.&lt;/ul&gt;&lt;br /&gt;Those are the three main effects that I have come across, feel free to mention other ones in the comments section (or to correct my paraphrased error messages if you so wish =P ).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-8984341190096978634?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/8984341190096978634/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/05/changing-buildroot-revision.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/8984341190096978634'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/8984341190096978634'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/05/changing-buildroot-revision.html' title='Changing Buildroot Revision'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-5320232894033955687</id><published>2007-05-03T19:43:00.000Z</published><updated>2007-05-21T12:39:21.711Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><title type='text'>Still Alive</title><content type='html'>It turns out that this blog is the second and third result if you Google "audiostix2 python" (minus the quote marks), which annoyed &lt;a href="http://dgoldsmith.blogspot.com/"&gt;Dan&lt;/a&gt; no end when he was searching for that, particularly as it has no actual relevant info. Thus I've told Dan I'll start making this blog useful so if it turns up in his future searches he'll have something to work with. Look out for new posts soon, maybe *gasp* some code samples and suchlike :o&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-5320232894033955687?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/5320232894033955687/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/05/still-alive.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/5320232894033955687'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/5320232894033955687'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/05/still-alive.html' title='Still Alive'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2614268040577057300</id><published>2007-02-09T18:45:00.000Z</published><updated>2007-01-23T23:19:48.144Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><title type='text'>New Prototype</title><content type='html'>Here's some pics of prototype 2, freshly made today.&lt;br /&gt;&lt;br /&gt;These first two are of the interface board stuck on the back of our favourite expansion, the Audiostix2 (with the Connex board attached obviously).&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_VomNIoC7I3k/RczBw3vVPiI/AAAAAAAAABw/g9mzCJ6hH4k/s1600-h/board1.png"&gt;&lt;img style="cursor: pointer;" src="http://3.bp.blogspot.com/_VomNIoC7I3k/RczBw3vVPiI/AAAAAAAAABw/g9mzCJ6hH4k/s320/board1.png" alt="" id="BLOGGER_PHOTO_ID_5029607929206357538" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_VomNIoC7I3k/RczB3nvVPjI/AAAAAAAAAB4/wMQq0hqWKEE/s1600-h/board2.png"&gt;&lt;img style="cursor: pointer;" src="http://2.bp.blogspot.com/_VomNIoC7I3k/RczB3nvVPjI/AAAAAAAAAB4/wMQq0hqWKEE/s320/board2.png" alt="" id="BLOGGER_PHOTO_ID_5029608045170474546" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;And here's a pic with the sensors attached. That's eight of the ones you saw last time.&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_VomNIoC7I3k/RczCIXvVPkI/AAAAAAAAACA/iyfZaVBbziY/s1600-h/sensors.png"&gt;&lt;img style="cursor: pointer;" src="http://1.bp.blogspot.com/_VomNIoC7I3k/RczCIXvVPkI/AAAAAAAAACA/iyfZaVBbziY/s320/sensors.png" alt="" id="BLOGGER_PHOTO_ID_5029608332933283394" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Sorry about the pngs, I'll convert them into jpeg when I'm home for about half the filesize. Posting this from the lab =P&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2614268040577057300?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2614268040577057300/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/02/new-prototype.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2614268040577057300'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2614268040577057300'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/02/new-prototype.html' title='New Prototype'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_VomNIoC7I3k/RczBw3vVPiI/AAAAAAAAABw/g9mzCJ6hH4k/s72-c/board1.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-2368175121646530863</id><published>2007-01-23T21:43:00.000Z</published><updated>2007-01-23T22:09:59.735Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='visualiser'/><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>Changing Times</title><content type='html'>I'm going to start off by retracting something I said &lt;a href="http://kempproject.blogspot.com/2006/04/c-and-new-operator.html"&gt;here&lt;/a&gt;. I now see how exceptions can be very nice, fun and neat compared to using return values to signal an error. Of course, that still doesn't mean you should use them constantly, they still have overhead, and as the name implies they are for &lt;span style="font-style:italic;"&gt;exceptional&lt;/span&gt; events that are out of your control or occured because the user forgot to read the manual before messing with the app's internals.&lt;br /&gt;&lt;br /&gt;In another change to my views related to coding, I've adopted &lt;a href="http://www.lua.org/"&gt;Lua&lt;/a&gt; as a plugin coding language for my visualiser. The first method I picked up was DLLs (on a Windows platform obviously), but they are decidedly non-portable and some people just hate DLLs on principle. I was thinking about &lt;a href="http://www.python.org/"&gt;Python&lt;/a&gt; (despite bad experiences interfacing to it from C++ in the past) but then &lt;a href="http://varspool.blogspot.com/"&gt;Sarah&lt;/a&gt; mentioned the possibility of Lua and after a quick read through the C API docs I was convinced. Now I just need to sort out letting the scripts make calls into methods that are part of objects in my C++ code ;-)&lt;br /&gt;&lt;br /&gt;In my final part of this post, a bit more progress on the hardware side. Recently I took the prototype-of-a-prototype that I showed a picture of &lt;a href="http://kempproject.blogspot.com/2006/12/ooo-hardware.html"&gt;previously&lt;/a&gt; and gave it the full complement of 8 sensors. Apparently the I2C bus didn't like driving them as-is and the whole thing kinda failed. With some handy help from an oscilloscope and James' guidance (the new James) we identified a quick fix that'll hold until the next revision which is already in the "planned and about to be executed" stage. So yeah, with the exception of sensor number 7 (grrr) it all works for now :-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-2368175121646530863?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/2368175121646530863/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/01/changing-times.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2368175121646530863'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/2368175121646530863'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/01/changing-times.html' title='Changing Times'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-5006702229734194810</id><published>2007-01-05T14:38:00.000Z</published><updated>2007-01-05T15:02:26.426Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='visualiser'/><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>The Importance Of Planning</title><content type='html'>So I'm working on the next version of my Visualiser, and by version I mean Uber Rewrite Of Ultimate Doom. The weaknesses of the original are becoming rapidly apparent and there comes a point where you just have to cut your losses and use your experience to start over. So I have a set of goals in terms of how I go about coding this new one so I don't repeat history. I know most of these are common sense taught to us early on, but how many pay attention seriously unless made to by company policy? Turns out having things bite you on the ass is quite a motivation.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Create the interface (class definitions etc) &lt;i&gt;before&lt;/i&gt; writing any implementation. Having the interface driven by your need to fix things you've already done isn't a good solution.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;In addition to the above, comment/document &lt;i&gt;everything&lt;/i&gt; before writing the implementation. Having a contract to stick to helps a lot.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Don't assume the running environment has 32-bit integers and single-byte characters. This isn't an issue right now, but being able to compile for unicode or run reliably on other architectures (most notably 64-bit systems) is pretty much a requirement for any serious application that wants to stay alive in the future.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Don't don't &lt;i&gt;don't&lt;/i&gt; use C coding style in C++. Seriously, never. Just don't. You have the STL and shiny new language features for a reason, use them.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;In addition to the above, drink lots of caffeine and play U2, Aerosmith or other such music loud while coding. Metallica, Muse or anything off Guitar Hero is far too distracting and makes you want to pick up your own guitar.&lt;br /&gt;&lt;br /&gt;Come to think of it, that last note might just apply to me, though I think it should be a requirement for all coders to be addicted to caffeine. Certainly beats other drugs in terms of not killing you off (except the inevitable bone weakening and teeth destruction inherent in cola).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-5006702229734194810?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/5006702229734194810/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2007/01/importance-of-planning.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/5006702229734194810'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/5006702229734194810'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2007/01/importance-of-planning.html' title='The Importance Of Planning'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-6563420772618449880</id><published>2006-12-21T19:19:00.000Z</published><updated>2007-01-05T15:23:03.240Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Needs More Packages</title><content type='html'>Now that my Linux distro is self-hosted and running nicely I feel the need to ask if anyone can suggest any packages that may come in useful (or that are just cool in general). I'm still using bash at the moment, no X for me as the whole point of doing this was learning more about Linux (mainly through asking Sarah annoying questions I guess) and slapping a GUI over it isn't really going to help that, so keep it command-line plzkthx. On the other hand, I am tempted to grab that manager that lets you split your screen up into seperate shells, I forget the name offhand.&lt;br /&gt;&lt;br /&gt;Also, I am starting to actually learn the emacs command bindings, which is scary in itself.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-6563420772618449880?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/6563420772618449880/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/12/needs-more-packages.html#comment-form' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6563420772618449880'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/6563420772618449880'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/12/needs-more-packages.html' title='Needs More Packages'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-1458517622054064224</id><published>2006-12-12T20:45:00.000Z</published><updated>2007-01-05T15:24:24.125Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='sensing hardware'/><title type='text'>Ooo... Hardware...</title><content type='html'>So my last post was related to software, let's go the opposite end this time. The pictures below are essentially a prototype of a prototype, a single data gathering chip hooked up to the ever popular Audiostix2 board (with a big green "1" stuck on it =P ), hopefully soon there will be much much more :-)&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_VomNIoC7I3k/RX8WwDd5wNI/AAAAAAAAAA8/fNzxoavAFRs/s1600-h/All.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_VomNIoC7I3k/RX8WwDd5wNI/AAAAAAAAAA8/fNzxoavAFRs/s320/All.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5007746325479538898" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_VomNIoC7I3k/RX8W0zd5wOI/AAAAAAAAABE/A22H3rPER5s/s1600-h/Chip.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_VomNIoC7I3k/RX8W0zd5wOI/AAAAAAAAABE/A22H3rPER5s/s320/Chip.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5007746407083917538" /&gt;&lt;/a&gt;&lt;br /&gt;If you feel like wanting more info then... tough I guess =P Note how the pictures are conveniently low res enough to not reveal any part numbers or suchlike, that's entirely coincedence I assure you.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-1458517622054064224?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/1458517622054064224/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/12/ooo-hardware.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1458517622054064224'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/1458517622054064224'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/12/ooo-hardware.html' title='Ooo... Hardware...'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_VomNIoC7I3k/RX8WwDd5wNI/AAAAAAAAAA8/fNzxoavAFRs/s72-c/All.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-7509704345337881193</id><published>2006-12-10T02:03:00.000Z</published><updated>2006-12-10T02:09:06.118Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='visualiser'/><title type='text'>Alive!</title><content type='html'>This is my first post here in a very long time :-O I finally bothered to take a screenshot of my WSN Visualiser with its latest feature: actual lighting so you're not relying on colouring surfaces to make them look 3D (that's blown out of the water when you're using colour for something else like in the screenie).&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_VomNIoC7I3k/RXtr1LPFTVI/AAAAAAAAAAU/ZGStw4Emer4/s1600-h/vis.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_VomNIoC7I3k/RXtr1LPFTVI/AAAAAAAAAAU/ZGStw4Emer4/s320/vis.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5006713972045729106" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Obviously it's not perfect yet, and I won't even get started on manually generating normals, but it works and it looks much cooler than it used to :-) And yes, that black blob is a single lonely node marker, poor little guy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-7509704345337881193?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/7509704345337881193/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/12/alive.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7509704345337881193'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/7509704345337881193'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/12/alive.html' title='Alive!'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_VomNIoC7I3k/RXtr1LPFTVI/AAAAAAAAAAU/ZGStw4Emer4/s72-c/vis.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-116318189690759864</id><published>2006-11-10T18:03:00.000Z</published><updated>2007-01-05T15:24:02.495Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='other sites'/><title type='text'>Mobile Computing</title><content type='html'>The guys over &lt;a href="http://www.proxflyer.com/"&gt;here&lt;/a&gt; have taken the concept of mobile computing to a whole new level. A 3 gram flying computer... I have images of one being flown up to sit on someone's roof while it hacks their wifi connection. *evil grin*&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-116318189690759864?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/116318189690759864/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/11/mobile-computing.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/116318189690759864'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/116318189690759864'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/11/mobile-computing.html' title='Mobile Computing'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-116272440566749810</id><published>2006-11-05T11:00:00.000Z</published><updated>2007-01-05T15:24:08.393Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='other sites'/><title type='text'>Stackless Python</title><content type='html'>&lt;a href="http://holdenweb.blogspot.com/2006/11/stackless-python-continues-to-amaze.html"&gt;... for Some Value of "Magic": Stackless Python Continues to Amaze&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Just thought I'd link over to this post for anyone who likes doing cool things with Python :-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-116272440566749810?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/116272440566749810/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/11/stackless-python.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/116272440566749810'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/116272440566749810'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/11/stackless-python.html' title='Stackless Python'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-116100691659058256</id><published>2006-10-16T13:52:00.000Z</published><updated>2007-01-23T23:15:21.888Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>Wireless Fun</title><content type='html'>Apparently transferring hordes of small files (14MB total) to an embedded device via ethernet emulated over Bluetooth (up to 300ms ping) is a slow process. Who would have thought? Next time I need to bother using the USB connection, ethernet emulated over USB is so much faster.&lt;br /&gt;&lt;br /&gt;On a side note, is there anything that ethernet &lt;span style="font-style:italic;"&gt;isn't&lt;/span&gt; emulated over?&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Update:&lt;br /&gt;I'm doing my third ethernet-over-Blutooth transfer now, why do I punish myself like this? Is doing it remotely from another room really that much of a bonus?&lt;br /&gt;&lt;br /&gt;Remotely = ssh session to the machine in the other lab that the Gumstix have their Bluetooth connection to. It's quite fun to ssh into that machine and then use that to ssh into the 'stix, though the latency starts getting very noticable.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-116100691659058256?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/116100691659058256/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/10/wireless-fun.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/116100691659058256'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/116100691659058256'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/10/wireless-fun.html' title='Wireless Fun'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-116005669179432721</id><published>2006-10-05T13:47:00.000Z</published><updated>2007-01-23T23:09:50.395Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><title type='text'>Diversion from hardware</title><content type='html'>So today I'm looking through a load of journals and doing web searches in the hopes of finding some info I need. I took a moment to think about what tabs I have open and noticed that Google is increasingly penetrating my work setup. The tabs I pretty much always have open are &lt;a href="http://www.google.com/calendar/"&gt;Google Calendar&lt;/a&gt;, &lt;a href="http://mail.google.com/"&gt;Google Mail&lt;/a&gt;, &lt;a href="http://www.google.com/notebook/"&gt;Google Notebook&lt;/a&gt;, and the web interface for the Uni mail system. That's three-quarters of my permanent tabs open on some Google service. The other one that is open increasingly more often is &lt;a href="http://www.citeulike.org/"&gt;CiteULike&lt;/a&gt; which isn't a Google service, so I guess that brings it down to 60% of my tabs, but that's still an impressive figure really, especially as I didn't use &lt;span style="font-style:italic;"&gt;any&lt;/span&gt; of these services a mere few months ago.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-116005669179432721?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/116005669179432721/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/10/diversion-from-hardware.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/116005669179432721'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/116005669179432721'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/10/diversion-from-hardware.html' title='Diversion from hardware'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115997979594595211</id><published>2006-10-04T16:26:00.000Z</published><updated>2007-01-23T23:15:28.382Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>Talking 'Stix</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/2249/2076/1600/commdir.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://photos1.blogger.com/blogger/2249/2076/320/commdir.png" border="0" alt="" /&gt;&lt;/a&gt;To your left (in compliant browsers), you are looking at the direction of connection establishment (does that phrase make sense?) in my test network for the Gumstix and their Bluetooth adapters. After many failed attempts to have the Master connect to the Listener and have the Slaves connect to it (host down/device busy/etc), I gave in and let the Master initiate all the connections, which worked first time and was completely repeatable for once. This also gives me more centralised control over things, as only the Master needs any config files telling it the addresses of the Slaves, rather than each Slave needing to know the address of the Master. Below is the output (slightly edited for clarity) I was very happy to see.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;PC (00:0A:94:13:CE:8D) &lt;br /&gt;&lt;br /&gt;$ ./listener&lt;br /&gt;Waiting for connections on port 1&lt;br /&gt;Master connected: 00:80:37:27:03:8C&lt;br /&gt;Slave announced: 00:80:37:27:03:86&lt;br /&gt;&lt;br /&gt;Master (00:80:37:27:03:8C)&lt;br /&gt;&lt;br /&gt;# ./master&lt;br /&gt;Connected to listener at 00:0A:94:13:CE:8D&lt;br /&gt;Connected to slave 0 at 00:80:37:27:03:86&lt;br /&gt;Relaying slave address&lt;br /&gt;&lt;br /&gt;Slave (00:80:37:27:03:86)&lt;br /&gt;&lt;br /&gt;# ./slave&lt;br /&gt;Waiting for connections&lt;br /&gt;Accepted connection from 00:80:37:27:03:8C&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115997979594595211?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115997979594595211/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/10/talking-stix.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115997979594595211'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115997979594595211'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/10/talking-stix.html' title='Talking &apos;Stix'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115935511069590730</id><published>2006-09-27T10:50:00.000Z</published><updated>2006-09-27T11:37:39.740Z</updated><title type='text'>Extreme Python</title><content type='html'>So if you ever want a function in Python that can generate all the prime numbers up to &lt;span style="font-style:italic;"&gt;n&lt;/span&gt; and for some reason you want to do it in one line of code you need not look any further than this. Of course, once you've used this code sample you may feel dirty, and documenting it in a nice way is a challenge left for the reader.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;def primes(n): return filter(lambda num : not bool(filter(lambda x : num % x==0, range(2, num / 2))), range(2, n))&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;I have Sarah to blame for the inspiration for this one (section 10.2.3 of her 112CR notes =P), though she at least used a couple more lines to split it into two functions and some more lines for documentation since it was possible with her example. Completely self-contained functional programming for the win, and as a bonus due to my version being a single line it's easily turned into another lambda function and embedded into something else, I'm sure there's probably a competition out there for getting things done in a single line of code.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Edit:&lt;br /&gt;As an aside, I quite like random.Random().random(), it has something of a feeling of deja vu about it.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115935511069590730?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115935511069590730/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/09/extreme-python.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115935511069590730'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115935511069590730'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/09/extreme-python.html' title='Extreme Python'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115866909316494859</id><published>2006-09-19T12:26:00.000Z</published><updated>2007-01-23T23:15:34.395Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>Linux + Python + USB = win</title><content type='html'>My first in-lab update :-) Last (academic) year I spent an annoying amount of time attempting to get a mote and a PC to talk to each other with absolutely no luck. Well, no coherent luck, I was getting random bits of data but never useful bits. That was using C++, a serial port, and NesC for the mote software (written by someone else). Using our cool new Gumstix means I switched to using Python (on both ends) and a USB port, a much more up-to-date and friendly combination indeed. It took approximately 5 mins to get the PC talking to the stick. That's right, 5 minutes. Now I can concentrate on making it do useful things rather than making it work. Win.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Edit:&lt;br /&gt;And now they can communicate via Bluetooth as well as USBNet. Yay for developer-friendly things.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115866909316494859?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115866909316494859/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/09/linux-python-usb-win.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115866909316494859'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115866909316494859'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/09/linux-python-usb-win.html' title='Linux + Python + USB = win'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115842782677623600</id><published>2006-09-16T17:05:00.000Z</published><updated>2007-01-23T23:16:07.700Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='gumstix'/><title type='text'>New Toys</title><content type='html'>Well I'm back at Uni so I guess it's time to get back to this blog and talk about things I'm doing =P The thing I'm liking most right now is playing with the new &lt;a href="http://www.gumstix.com/"&gt;Gumstix&lt;/a&gt; devices. I haven't done too much with them yet but they show a lot of promise. Who can argue with a computer roughly the size of a stick of gum (guess where the name comes from) that runs Linux and has little expansion boards to give it USB, Ethernet, audio, Bluetooth and other such abilities :-D Because it runs Linux, which is nice and handy, you can run most programs you've written straight on it (using a very helpful remote shell), obviously you have to use a cross-compiler when compiling them but that's no problem with the handy GCC toolchain they supply. Even nicer is sticking the Python interpreter on there and doing something a little more high-level. Working on a little something for them this weekend, whether it's possible or not I don't yet know, more info if it works :-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115842782677623600?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115842782677623600/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/09/new-toys.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115842782677623600'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115842782677623600'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/09/new-toys.html' title='New Toys'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115499694417605535</id><published>2006-08-08T00:26:00.000Z</published><updated>2007-01-23T23:16:14.590Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><title type='text'>Wireless Fun</title><content type='html'>&lt;span style="font-weight:bold;"&gt;Andy:&lt;/span&gt;&lt;br /&gt;two boxes done, upgraded the firmware, just need to get the final aerial and test the link out&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Kemp:&lt;/span&gt;&lt;br /&gt;:D&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Andy:&lt;/span&gt;&lt;br /&gt;Should be able to get 5km link non-lineofsight working&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Kemp:&lt;/span&gt;&lt;br /&gt;:o 5km without LOS&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Andy:&lt;/span&gt;&lt;br /&gt;Yep, 3Mbps 5Km&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Kemp:&lt;/span&gt;&lt;br /&gt;that's crazy. you're crazy. you'll fry pigeons. people will explode. chaos will reign. the world will be plunged into anarchy. REPENT FOR THE END IS NEIGH&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115499694417605535?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115499694417605535/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/08/wireless-fun.html#comment-form' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115499694417605535'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115499694417605535'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/08/wireless-fun.html' title='Wireless Fun'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115435817602447806</id><published>2006-07-31T14:44:00.000Z</published><updated>2006-07-31T15:02:56.120Z</updated><title type='text'>Back At Last</title><content type='html'>Ah, coding with a purpose, how I missed it. I'm working on some mangling together of CSS, DHTML and Javascript to make a nice little image gallery widget for &lt;a href="http://baletempest.livejournal.com/"&gt;Baletempest&lt;/a&gt;'s site. Admittedly I wouldn't normally call this coding (scripting being more like it), but it's the first real thing I've done in a while, so I'm cutting it some slack =P Note that it isn't for his blog, it's for an actual site he owns, though I don't have the URL readily at hand to link to. If I get something decent knocked together I'll let you guys know :-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115435817602447806?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115435817602447806/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/07/back-at-last.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115435817602447806'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115435817602447806'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/07/back-at-last.html' title='Back At Last'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115263563350535118</id><published>2006-07-11T15:44:00.000Z</published><updated>2006-07-11T16:33:53.616Z</updated><title type='text'>Eek...</title><content type='html'>Ok, I think I need a bit of help from you all. Someone I know's net connection has fallen over and refuses to pick itself back up again (nothing to do with me *whistles innocently*) and we have basically tried everything we can think of at this point. Bear in mind through this description that at no point was anything connection related touched before this happened, in fact the only change was removing a couple of browser hijacks (which should have no way of affecting the connection at the system level afaik). In terms of background, the OS is Win98, the ISP is NTL, and the broadband modem (I hate calling it a modem, but it's an easy word =P) is connected via USB. I know, I know, Win98 and a USB connection are both not recommended but it's a relatively old machine and it was all working perfectly fine til now. Ok, on to what happened...&lt;br /&gt;&lt;br /&gt;Removed a few browser hijacks, restarted, no net connection anymore. Ok I think, check the browser settings and make sure they didn't cripple anything while being removed, everything looks fine. Next step, check the adapter and TCP/IP settings, everything looks fine in there with the exception of the adapter being listed twice and there being an adapter called simply "AOL". Having previously removed some AOL software from the machine due AOL having not been used at all for internet on that machine at any point in the past, I deleted the adapter. This AOL mini-story should be unrelated, but I've heard stories about AOL software crippling a system if it is removed as a form of vendor lock-in, though I heard that they took this out a lot of versions ago after they got their ass kicked for it. Anyway, the other settings in here are also fine. I know, I think, let's check it's actually seeing the modem. So I dutifully go into device mangler and check the USB devices listing, at which point my "bad feeling about this" grows a bit larger. There is no modem listed, there is however a disabled USB device (all the others being accounted for, that must be the modem). I enable the device and pray that something that simple could fix it. Evidently not. With the reboot over there's still no connection. I go back into device mangler and notice that the previously disabled device is now an unknown device. Bad feeling continues to grow. Ok, so it has somehow forgot how to find the drivers for something that was working earlier that same day. I grab the NTL install CD and run through the setup, which includes copying the drivers over and attempting to set the network settings up automatically. This proceeds to fail, saying it can't set the adapter to use DHCP (which is bull really because it's already set to use that). Ok, I think, how about we remove all the adapter settings and its bindings and let the installer start from scratch, hopefully it's just conflicting with the existing ones somehow. So I do that, run the installer again, exactly the same error but this time there wasn't an adapter to start with and it hasn't added one either, yet it somehow gets far enough to want to be setting it up. Also at this point, despite the drivers being copied over every time the installer is run the modem is still apparently an unknown device. So I run the Broadband Medic program as a desperate last resort (considering it has never given me useful advice on any problem, despite the length of time it spends analysing the connection) and this time it tells me something other than to clear out my internet cache. This time it tells me the connection is fine, but the adapter is set up wrong. o rly? THEN THE CONNECTION ISN'T FINE.&lt;br /&gt;&lt;br /&gt;Anywho, I think that's a quick ("quick"? O_o) guided tour of what has happened so far, minus the additional hours of trying to manually force it into submission by giving it known good settings with no luck at all.&lt;br /&gt;&lt;br /&gt;Help and thoughts would be VERY much appreciated as I'm currently lost.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115263563350535118?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115263563350535118/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/07/eek.html#comment-form' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115263563350535118'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115263563350535118'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/07/eek.html' title='Eek...'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115205656276086705</id><published>2006-07-04T23:31:00.000Z</published><updated>2007-01-23T23:19:01.020Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><title type='text'>Interesting...</title><content type='html'>Ok, first rule of Kemp's blog is we don't ask what crazy chain of links bring me to other blogs. With that in mind, I had to try &lt;a href="http://dontletrealityspoilyourdreams.blogspot.com/2006/06/new-meme.html"&gt;this&lt;/a&gt;, if only because I haven't done it before. Basically put your name followed by "needs" into google and take the first ten sentences that make sense. So with the query "Kemp needs" entered I recieved:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;Kemp needs to stay out of foul trouble&lt;br /&gt;Kemp needs a real job&lt;br /&gt;Kemp needs opportunities to demonstrate those threshold qualities&lt;br /&gt;Kemp needs to expand&lt;br /&gt;Kemp needs to hire Francouer's PR firm&lt;br /&gt;Kemp needs to make at least 5 changes&lt;br /&gt;Kemp Needs Your Help&lt;br /&gt;Kemp needs a Trainee Visa, H-3&lt;br /&gt;Kemp needs to chuck most of that out the window for a while and just look at the game in its simplest form&lt;br /&gt;Kemp needs to be sacked&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Hmmm....I need to stay out of trouble and get a job, those are pretty much a given. As to what threshold qualities I need an opportunity to demonstrate I have no idea. Expand in which direction? O_o I hope it means mentally... I have no idea who Francouer is or why I need a PR firm, I have no public relations anyway so I doubt I need a whole company to handle it for me. 5 changes... that's a bit vague, but I guess changes are pretty much a given like the first two. If you can give me help I'll gladly take it =P I don't think I do need a Trainee Visa, whatever one of those is. This one sounds good, chuck it out the window and look at the simple picture :-) And last but hopefully very much least, I hope I don't need to be sacked :-|&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115205656276086705?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115205656276086705/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/07/interesting.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115205656276086705'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115205656276086705'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/07/interesting.html' title='Interesting...'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115204367271891867</id><published>2006-07-04T19:59:00.000Z</published><updated>2007-01-23T23:19:26.340Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><title type='text'>STS-121 Up At Last</title><content type='html'>Well the Shuttle's finally in space and everything went fine, no problems that anyone noticed at least =P The first (American) Independence Day launch ever, so I guess the huge jets of flame were kinda fitting for the day. For the "where were you during the launch?" effect, MSN logs:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;Kemp: 90 seconds on the feed&lt;br /&gt;Overlord: 1 min&lt;br /&gt;Overlord: 30 secs&lt;br /&gt;Kemp: engine start&lt;br /&gt;Overlord: LET'S ROCK AND ROLL&lt;br /&gt;* Overlord is currently listening to: Magic Carpet Ride - Steppenwolf (Star Trek - First Contact).mp3&lt;br /&gt;Kemp: :D&lt;/blockquote&gt;&lt;br /&gt;For those that don't get the reference, watch First Contact =P&lt;br /&gt;&lt;br /&gt;On a random note, did you know:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;In Rhode Island it's legal to be a prostitute but &lt;span style="font-style:italic;"&gt;illegal&lt;/span&gt; to find clients or operate a brothel. I guess you have to kinda find them accidentally or something.&lt;br /&gt;&lt;li&gt;In Sweden it's legal to be a prostitute but not a client of one. I don't see how that works, but I guess it does somehow.&lt;/ul&gt;&lt;br /&gt;The things Wikipedia teaches you *rolls eyes*&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115204367271891867?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115204367271891867/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/07/sts-121-up-at-last.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115204367271891867'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115204367271891867'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/07/sts-121-up-at-last.html' title='STS-121 Up At Last'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115187177625200222</id><published>2006-07-02T20:16:00.000Z</published><updated>2006-07-02T20:22:56.263Z</updated><title type='text'>STS-121 Delays</title><content type='html'>So it goes that the launch has been put back &lt;b&gt;another&lt;/b&gt; two days, weather's still the no-go and forcasts don't look too good. I hear there was an issue with one of the engines on the Shuttle, but apparently it wasn't anything too bad as they gave a go on that one. Back to the live feed in two days then, I've never seen a Shuttle launch live, would be nice to see this one.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115187177625200222?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115187177625200222/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/07/sts-121-delays.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115187177625200222'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115187177625200222'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/07/sts-121-delays.html' title='STS-121 Delays'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115176035581697337</id><published>2006-07-01T13:11:00.000Z</published><updated>2006-07-01T13:25:55.826Z</updated><title type='text'>STS-121</title><content type='html'>So as I speak there's about 3 hours left on the countdown timer to the launch of mission STS-121 (about 6.5 hours real time if you count built-in holds). This will either work and get NASA some of the good publicity they need or they'll have problems involving large fireballs again in which case space travel from the US will likely be put on indefinate hold. I'm sure a lot of people will be praying for a safe return for the brave guys (and girls of course) on board the orbiter Discovery, so here's to a successful mission.&lt;br /&gt;&lt;br /&gt;Mission facts from NASA website:&lt;br /&gt;STS-121 Discovery/ 18th International Space Station Flight ULF1.1 &lt;br /&gt;Launch Pad: 39B &lt;br /&gt;Launch Date: July 1, 2006 &lt;br /&gt;Launch Time: 3:49 p.m. EDT &lt;br /&gt;Landing: July 13, 2006 &lt;br /&gt;Duration: 12 days&lt;br /&gt;Orbital Insertion Altitude: 122 nautical miles &lt;br /&gt;Orbit Inclination: 51.60°&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115176035581697337?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115176035581697337/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/07/sts-121.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115176035581697337'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115176035581697337'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/07/sts-121.html' title='STS-121'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115158334125592168</id><published>2006-06-29T12:08:00.000Z</published><updated>2006-06-29T12:15:41.270Z</updated><title type='text'>Results :D</title><content type='html'>Just a quick update today to say that my results are up and I am now the owner of a First with Honours (or as the results list calls it : Bachelor of Science with Honours First Class in Network Computing) :D I'd like to thank all the usual uni staff, family and friends, plus any selection of deities of your choice. Say no to drugs =P&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115158334125592168?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115158334125592168/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/06/results-d.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115158334125592168'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115158334125592168'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/06/results-d.html' title='Results :D'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115152149520994978</id><published>2006-06-28T18:50:00.000Z</published><updated>2006-06-28T19:31:43.833Z</updated><title type='text'>Brand Loyalty</title><content type='html'>A while ago I read an article about unthinking brand loyalty when buying computer parts, and how people stick with what they know rather than going for the brand that is actually better in a particular instance. After reading it I told myself that I don't fall into that category, and I would take all items on their individual merits. After pricing a new machine up this week I suddenly realised I am exactly the person the article discussed. AMD processor, nVidia GPU on a board by XFX, Hiper PSU, the exact four manufacturers that made those parts for my last machine. Half the problem here is that I feel safer having dealt with these products before and I mainly kept up with news about them, so I feel I know their quirks and suchlike. The other part of the problem is that these are actually good manufacturers and I don't want to risk getting shoddy parts just to show some fairness to the other companies. I prefer AMD to Intel because AMD's processors have a history of running cooler and more efficiently (and I agree with the shorter pipelines) plus the dual-core CPUs don't have to be down-clocked just to stop them melting. I prefer nVidia to ATI mainly because of the company image and the more polished and friendly appearance of their drivers, and they have less of an assortment of letters and numbers in the part names. I prefer XFX boards because they come pre-overclocked and the packaging is just so damn cool =P Plus they get good reviews. I prefer Hiper PSUs simply because I've used them before and in my experience they're about as reliable as you can get, plus the modular connectors idea (in the one I'm getting this time round) is a big bonus. Overall, as you see, it is a combination of how well the products have worked in the past along with the overall company image and a hint of personal prejudice that keeps me coming back.&lt;br /&gt;&lt;br /&gt;For those interested, the parts I'm looking at currently for my machine are:&lt;br /&gt;DFI LanParty UT NF4 SLI-DR Expert, XFX GeForce 7900GT 256MB XT Edition, Hiper HPU-4K580-MK Type R 580W Modular, AMD Athlon 64 X2 Dual Core 4400+ (Socket 939) and an Arctic Cooling Freezer 64 Pro. My current case selection is the Jeantech Phong II and I'm still looking for the right RAM.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115152149520994978?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115152149520994978/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/06/brand-loyalty.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115152149520994978'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115152149520994978'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/06/brand-loyalty.html' title='Brand Loyalty'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115124933971649613</id><published>2006-06-25T15:19:00.000Z</published><updated>2006-06-25T15:28:59.726Z</updated><title type='text'>MS Python?</title><content type='html'>Microsoft are working on a product called IronPython, which in more common language is Python.NET. Presumably they realised that the name .NET these days strikes fear into the hearts of men (or at least a bored dismissal). Anyway, who could resist a version of Python that "supports an interactive interpreter with fully dynamic compilation". Hmmm.... welcome to vanilla Python's initial release Microsoft, nice to know you're in this decade at least. So what makes this release better than just getting normal everyday Python? Well, if you like the idea of replacing the huge variety of libraries Python has available with the libraries normally available to .NET apps then I guess you'll like it. Myself, I think I'll steer well clear.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115124933971649613?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115124933971649613/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/06/ms-python.html#comment-form' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115124933971649613'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115124933971649613'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/06/ms-python.html' title='MS Python?'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115083271013589293</id><published>2006-06-20T19:40:00.000Z</published><updated>2007-01-23T23:19:48.188Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><title type='text'>Randomness</title><content type='html'>You just know some people should be politicians...&lt;br /&gt;&lt;blockquote&gt;This base 2 thing is just so incredibly difficult, I doubt someone can come up with a base 2 computer. I mean, base 10 is the natural base, hex is 1.6 times better than base 10, but base 2 is five times worse than base 10. Five times worse means at least five times more complex. One-fifth of the population already has calculation problems with base ten, so 100% of the population has problems with base 2.&lt;/blockquote&gt;&lt;br /&gt;The above entirely in jest obviously, sourced from comments &lt;a href="http://thedailywtf.com/forums/thread/41518.aspx"&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;In other news, ignoring any potential moderation and whatnot that goes on before we get actual numbers, I appear to have passed 7 modules this year, bringing my total to 23 out of 24. Not bad if I do say so myself. Now I just have to worry about what my actual grades were.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115083271013589293?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115083271013589293/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/06/randomness.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115083271013589293'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115083271013589293'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/06/randomness.html' title='Randomness'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115063341124550055</id><published>2006-06-18T12:08:00.000Z</published><updated>2006-06-18T12:23:31.276Z</updated><title type='text'>NASA and Death</title><content type='html'>I have just lost any respect I may have accidently been left with for the people who run NASA. You'd have thought they would have learned their lesson by now, given that they've killed several crews (is it three or four at last count? I remember Challenger and Columbia and if I recall there was a test one that set on fire on the lauch pad). These deaths were caused by problems with the shuttle that were known ahead of time and that the engineers warned were potentially very dangerous, but administration essentially said "shut up, our arbitrary deadline is more important". And guess what, after making some minimal changes that both the top safety official and lead engineer at NASA have warned are not enough, the administration is forcing a launch at the earliest opportunity in the next launch window. Their reason? If something goes wrong the crew can take refuge in the International Space Station... Well done guys, way to never learn from history.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://news.bbc.co.uk/1/hi/world/americas/5091308.stm"&gt;Story on the launch&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115063341124550055?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115063341124550055/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/06/nasa-and-death.html#comment-form' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115063341124550055'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115063341124550055'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/06/nasa-and-death.html' title='NASA and Death'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>5</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-115022298226132773</id><published>2006-06-13T18:11:00.000Z</published><updated>2006-06-13T18:23:02.296Z</updated><title type='text'>Windows and focus</title><content type='html'>I'd like all the UI coders at Microsoft to repeat after me, ok?&lt;br /&gt;&lt;br /&gt;"Forcibly taking focus away from whatever the user is doing is bad, very very bad, we should be punished for even considering making it a 'feature'."&lt;br /&gt;&lt;br /&gt;I have lost count of the number of times I have been typing away and some background app throws up a message box/dialog/prompt/anything and it is automatically given focus. I may have used computers a lot but there is no humanly possible way for me to stop typing fast enough to not change a few settings or "press" a button on the dialog. This has resulted in a lot of dialogs being dismissed that really, really, shouldn't have been. There are two types of popup that could occur:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Ones I don't care about, in which case they shouldn't be interrupting my workflow&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Ones that are important, in which case they shouldn't be risking accidental dismissal&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;In both cases the answer is simple, stay in the background and flash on the taskbar, or (as done by at least a couple of firewalls in their allow/deny prompts) don't give any control on the dialog focus until the user specifically clicks on it, including not responding to "enter" keypresses, and just make that annoying beep until then whenever they try typing. Both these solutions are very acceptable to me, the first can easily be ignored until I want to find out what it was, the second has no way of anything being done accidentally and you realise it's there much quicker because of the beep on each keystroke (usually at most two is enough for most people to catch up).&lt;br /&gt;&lt;br /&gt;Usability within apps is covered quite a lot, how about usability issues when you're not using the app?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-115022298226132773?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/115022298226132773/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/06/windows-and-focus.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115022298226132773'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/115022298226132773'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/06/windows-and-focus.html' title='Windows and focus'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114998251313148166</id><published>2006-06-10T23:21:00.000Z</published><updated>2006-06-10T23:35:13.713Z</updated><title type='text'>Chaos and WTFs</title><content type='html'>I picked up a book from the local Oxfam shop yesterday (they have a surprisingly good and large selection) called Complexification by one John L. Casti. It's basically about chaos theory and the surrounding science and psuedo-science, and me being me I'm finding it quite interesting. It covers things well and in an easy to read way and the combination of those two things is a rare thing in my experience. Books in this sort of area tend towards highly detailed with no regard to readability, or skipping over things you actually want to know, so it was quite nice to find one that actually made me keep reading.&lt;br /&gt;&lt;br /&gt;Also, a site that I've forgotten for too long has finally been added to my links list, &lt;a href="http://thedailywtf.com"&gt;TheDailyWTF&lt;/a&gt;. It's a blog/forum that is updated daily with examples of bad programming practice (practise?), crazy design decisions, and other things that make you think "WTF?!". They (as per any site with a large consistent userbase) have built up a range of memes on the forum section which is used for comments on the posts, see how many you can spot :-P&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114998251313148166?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114998251313148166/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/06/chaos-and-wtfs.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114998251313148166'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114998251313148166'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/06/chaos-and-wtfs.html' title='Chaos and WTFs'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114815634235922678</id><published>2006-05-20T20:12:00.000Z</published><updated>2006-05-20T20:19:02.380Z</updated><title type='text'>Securing your code</title><content type='html'>&lt;a href="http://www.xbox-linux.org/wiki/17_Mistakes_Microsoft_Made_in_the_Xbox_Security_System"&gt;This&lt;/a&gt; article on the Xbox-Linux site provides a background of all the exploits found for the Xbox to run non-Microsoft code, but more interestingly it finishes off by giving some *very* good guidelines for implementing security in any system. Well worth reading in my opinion, especially if you are working on making secure software/hardware.&lt;br /&gt;&lt;br /&gt;As a related note, the article reveals that Microsoft's "don't talk to anyone outside, don't compromise" policy played a very large part in the downfall of the Xbox security.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;But the Xbox Linux Project did not blindly release this hack. The first savegame proof of concept exploit had been finished in January 2003. After that, a lot of energy was invested in finding out a way to free the Xbox for homebrew development and Linux, but not allowing game copies. Microsoft was contacted, but without any success. They just ignored the problem.&lt;br /&gt;&lt;br /&gt;Finally in July, the hack was released, with heavy obfuscation, and lockout code for non-Linux use. It was obvious that this would only slow down the "hacking of the hack", so eventually, people would be able to use this vulnerability for copied games, but since Microsoft showed no interest in finding a solution, there was no other option than full disclosure. The suggestion of the Xbox Linux Project would have been to work together with Microsoft to silently close the security holes and, in return, work on a method to let homebrew and Linux run on the Xbox.&lt;br /&gt;&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;Microsoft refused to talk about the savegame and font vulnerabilities. If we had been bad hackers, we could have released both of them as-is, immediately making it possible to run copies on Xboxes without the use of a modchip. Instead, we sought contact to Microsoft: We would have preferred to see a backdoor for Linux in the Xbox security system, instead of a solution based on our findings that would allow running copies. But as they refused to talk, we were forced to release the exploits, and they were lucky we heavily obfuscated our solutions so in order to slow down people interested in using it for copies.&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114815634235922678?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114815634235922678/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/05/securing-your-code.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114815634235922678'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114815634235922678'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/05/securing-your-code.html' title='Securing your code'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114798505541770472</id><published>2006-05-18T20:32:00.000Z</published><updated>2006-05-18T20:49:40.623Z</updated><title type='text'>Those who can't, teach anyway</title><content type='html'>I have an exam tomorrow for a certain module that shall rename unnamed to protect the pathetic. There has been a serious amount of confusion while doing revision for it as we weren't actually taught in any real coherent way or with any serious effort. I'll give this place credit where it's due (even if we do like moaning about it :P ) and admit that overall the modules are quite well taught with a few exceptions that do actually have valid reasons and are sometimes simply down to lazy students, but this particular module was dire. Even Computer Graphics &amp; Visualisation with its crazily hard theory and slightly boring topic matter at times was taught coherently and by someone who knew what they were talking about, which counts for a lot. The lectures for this unnamed module seemed rushed and missed a lot of points, the lab sessions were useless at best and the notes we have available pretty much follow form with the lectures with the added bonus of incorrect examples and typos galore. Luckily there are a small group of students willing to patch together the information we *were* given to provide the rest of us with the documents we should have been given in the first place, for which I am eternally grateful. They know who they are and should be very proud of themselves. Oh, but the best part of this is the module review forms we get given at the end of the year... or not. For this module it seems the negative feedback was so obviously coming that the lecturer decided that it would be best not to hand them out, after all it would require actual effort to teach people next year if the higher-ups found out.&lt;br /&gt;&lt;br /&gt;Anyway, long story short, this may very well be taken up with said higher-ups by a very angry mob of students.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;In other, much lighter news, the Nintendo Wii (Wee) just became that bit funnier. It is being distributed by none other than Koch Media ^_^&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114798505541770472?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114798505541770472/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/05/those-who-cant-teach-anyway.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114798505541770472'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114798505541770472'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/05/those-who-cant-teach-anyway.html' title='Those who can&apos;t, teach anyway'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114738240208693198</id><published>2006-05-11T21:12:00.000Z</published><updated>2007-01-23T23:11:43.966Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='random'/><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>open() a bad name?</title><content type='html'>I was having a quick browse through the Python-Dev mailing list archives today and came across a debate on the relevance of the name open(). While the name is a long-held tradition, I do agree with some of the points raised (and tradition in general seems to be bad in compsci, for reference see almost any aspect of the PC architecture).&lt;br /&gt;&lt;br /&gt;&lt;hr&gt;&lt;br /&gt;&gt;&gt;&gt; perceived the introduction of `file()' as a nice cleanup in Python.&lt;br /&gt;&lt;br /&gt;&gt;&gt; As a user, so did I.  I like the cosistency of using file along with int,&lt;br /&gt;&gt;&gt; tuple, list, dict, type, (and did I leave out something), and all user&lt;br /&gt;&gt;&gt; classes as constructors of instances of themselves.&lt;br /&gt;&lt;br /&gt;[top post moved down before responding to give better context]&lt;br /&gt;&lt;br /&gt;&gt;I considered more as the action being performed.  I'm opening something,&lt;br /&gt;&lt;br /&gt;Are you, really?  I understand opening a door, gate, hinged lid, file folder, gun stock,  clam, fist, or book.  All of these involve a hinge motion, usually reversible. [...] Opening a can, walnut, or geode involves an irreversible cut or smash.  I do not see much analogy of any of these motions with the action of open/type().&lt;br /&gt;&lt;br /&gt;If you say that they all give access, I could just as well say that you are unlocking, leasing, or learning something or acquiring a permission.&lt;br /&gt;&lt;br /&gt;In my view, file/open() (in read mode) asks the interpreter to construct a Python object that corresponds to and connects and gives access to the external non-PyObject data (byte) stream indicated by the name/locator string so that I may bring part or all of that data into the Python dataspace as one or more Python objects (initially strings).  The host-system specifics of the access mechanism is beyond the purview of Python itself.&lt;br /&gt;&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;Should socket.socket() have been socket.open because it 'opens' a communication channel (in the process of creating a socket object)?  For me, this analogy works at least as well as 'opening' a document (see below).&lt;br /&gt;&lt;br /&gt;&lt;hr&gt;&lt;br /&gt;I personally agree with his points, if everything else has a constructor named after itself then why should files be a special case just because an ancient OS decided that "opening" them sounded nice?&lt;br /&gt;&lt;br /&gt;[Sourced from &lt;a href="http://mail.python.org/pipermail/python-dev/2004-July/046032.html"&gt;here&lt;/a&gt;]&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;In other unrelated news, I've been trying to assemble some kind of idea of my overall coursework marks and it's not looking too bad :-) I've always been better at exams than coursework, so getting marks like 82% in some of the pieces was pretty damn sweet. The ones I have gathered so far are : 310IS - 80.4%, 320CS - 60%, 326IS - 64%, 330CS - 59% (ouch), 336CS - 71%, 355CS - 79%. One module below 60% and three above 70% isn't too bad, though I guess it could be better. Just my dissertation to get back (be nice Sarah *pleading eyes*) and my exams to get through and I'm free for a while.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114738240208693198?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114738240208693198/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/05/open-bad-name.html#comment-form' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114738240208693198'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114738240208693198'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/05/open-bad-name.html' title='open() a bad name?'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114616582109930723</id><published>2006-04-27T18:30:00.000Z</published><updated>2006-04-27T19:23:41.183Z</updated><title type='text'>Revolution? Not Quite...</title><content type='html'>So Nintendo finally got round ot telling us the final name for the Revolution (that being the development codename, and a pretty good name really). After the controller, I didn't think I could lose any more respect for the console, after all it is only a simple name change. Unfortunately, Nintendo appear to have ordered the bottomless cup of stupid, and they just got a refill. The Nintendo Revolution will now be known as... *fanfare* The Nintendo Wii *silence* That's pronounced "Wee" not "Why" by the way. I think Overlord put it best when he suggested a new tagline for it: "Excuse me, I need a Wii". I can so imagine someone saying that in a store.&lt;br /&gt;&lt;br /&gt;Sourced from &lt;a href="http://pspupdates.qj.net/Nintendo-Revolution-Renamed-Nintendo-Wii/pg/49/aid/30384"&gt;PSPUpdates&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114616582109930723?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114616582109930723/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/04/revolution-not-quite.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114616582109930723'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114616582109930723'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/04/revolution-not-quite.html' title='Revolution? Not Quite...'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114580615828908400</id><published>2006-04-23T15:01:00.000Z</published><updated>2006-04-23T15:29:18.323Z</updated><title type='text'>Almost There</title><content type='html'>Well that's my dissertation in and only one more piece of coursework to do and that's my rushing around done until the second week of May. What does that mean? Well for the first time in a long while I'll have actual time for my own projects, which specifically will probably end up being the GBA coding and possibly my Vampire : Bloodlines modding toolkit, plus anything else that grabs my attention for a moment. Time to see if I can set up a stable (and useful) GBA dev environment in Visual Studio 2003 I guess, the main part of that will be getting the rest of the toolchain running nicely using Cygwin as just like any other console the toolchain is based off of GCC and only available for Linux and co. Onwards to more coding...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114580615828908400?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114580615828908400/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/04/almost-there.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114580615828908400'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114580615828908400'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/04/almost-there.html' title='Almost There'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114450186819053911</id><published>2006-04-08T12:52:00.000Z</published><updated>2007-01-23T22:04:26.586Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='coding'/><title type='text'>C++ and the 'new' operator</title><content type='html'>Just a little one for you people out there that use C++ and are either used to the C alloc functions or have just never quite got round to reading the documentation properly ;-)&lt;br /&gt;&lt;br /&gt;The 'new' operator in C++ isn't actually spec'd to return a NULL pointer if the memory allocation fails, which is unlike the C alloc functions, it instead is meant to throw a  std::bad_alloc exception. Now that's all well and good except in two situations: 1) You don't like using exceptions (I'm afraid I fall into the "return value should tell you what you need to know" camp) or 2) Further to not liking exceptions you have in fact turned them off. In this second case you have a bit of a serious problem if you don't know about this particular aspect of the operator as if you've turned exceptions off then the compiler will still generate the same code, which will happily use the invalid pointer returned by the operator when it calls the constructor, and the OS should kill your app if it's doing its job.&lt;br /&gt;&lt;br /&gt;You have two options at this point if you don't wish to use exceptions. First, you can declare the operator differently and pass an extra parameter in order to force it to return NULL on a failed allocation rather than throw the exception. Alternately, you can pass GCC the -fcheck-new parameter (assuming you're using GCC of course, though other compilers may have similar flags) and it will insert checks on the pointer before it calls the constructor (this is automatic if you use the alternate version of new, which is how it can return NULL and not kill itself).&lt;br /&gt;&lt;br /&gt;Of course, if I wish to follow this advice myself I need to edit my code a bit, but until then my app doesn't officially support machines that are running low on memory :-P&lt;br /&gt;&lt;br /&gt;[Info sourced from &lt;a href="http://www.mega-tokyo.com/forum/index.php?board=1;action=display;threadid=9305"&gt;here&lt;/a&gt;]&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114450186819053911?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114450186819053911/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/04/c-and-new-operator.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114450186819053911'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114450186819053911'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/04/c-and-new-operator.html' title='C++ and the &apos;new&apos; operator'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114407894649554029</id><published>2006-04-03T15:34:00.000Z</published><updated>2006-04-03T15:42:26.520Z</updated><title type='text'>Oblivion Mods</title><content type='html'>Oblivion hasn't been out for long, but already the mods are coming in. I personally don't tend to apply many of the fan-made mods to my Elder Scrolls games as I am one for having an extensively tested and balanced game (in theory at least), and a lot of the mods are purely to make people's lives easier. The ones I do go for tend to be cosmetic ones that make things look better. With that in mind, here are the three mods I have applied to my game:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;li&gt;&lt;a href="http://www.oblivionsource.com/?page=modforge&amp;op=viewproject&amp;project_id=191"&gt;Oblivion Topless Mod&lt;/a&gt;&lt;br /&gt;This only applies to the female characters (the guys are already topless if you remove the clothes). It appears the Bethesda guys made the models naked to start with and then sculpted the fixed underwear on, but left the original models/textures in the data files unused. I chose to apply this mod not because I want to look at my character naked, but because the underwear they gave the characters is not nice at all, my character would certainly not wear it.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;PA Eye Colors &lt;a href="http://www.elricm.com/nuke/html/modules.php?op=modload&amp;name=Downloads&amp;file=index&amp;req=viewdownloaddetails&amp;lid=2427"&gt;1&lt;/a&gt; + &lt;a href="http://www.elricm.com/nuke/html/modules.php?op=modload&amp;name=Downloads&amp;file=index&amp;req=viewdownloaddetails&amp;lid=2434"&gt;2&lt;/a&gt;&lt;br /&gt;These add a much wider variety of eye colours to select for your character. The range given as shipped is rather limited, my character could have done with these to start with.&lt;/li&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;That's all for now, until I find any more worthy ones. Ciao.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114407894649554029?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114407894649554029/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/04/oblivion-mods.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114407894649554029'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114407894649554029'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/04/oblivion-mods.html' title='Oblivion Mods'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114376419175882500</id><published>2006-03-31T00:10:00.000Z</published><updated>2006-03-31T00:16:31.773Z</updated><title type='text'>Birthday :D</title><content type='html'>It's just over an hour into my 21st birthday now, not magically any more mature so I guess I'll just have to still be the same person I already was :-P Got to wait til morning for presents still, but it is currently after the actual time I was born, so I really am now just over 21 years old. Keeping my mum up til like 20 past midnight 21 years ago, evil even before I left the womb, lol.&lt;br /&gt;&lt;br /&gt;Anyway, busy busy busy. PhD application complete and just needs to be scanned and sent in, CV to go along with it almost done, coursework submitted, Rolos consumed.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114376419175882500?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114376419175882500/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/birthday-d.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114376419175882500'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114376419175882500'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/birthday-d.html' title='Birthday :D'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114367659017146568</id><published>2006-03-29T23:54:00.000Z</published><updated>2006-03-29T23:56:30.186Z</updated><title type='text'>Warning : Productivity Hazard</title><content type='html'>A quick post today, just a link for you. But only click it if you have countless hours of your day to waste. Read that again, make sure you understand how addictive this could be.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.ebaumsworld.com/squares.html"&gt;Squares Game&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114367659017146568?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114367659017146568/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/warning-productivity-hazard.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114367659017146568'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114367659017146568'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/warning-productivity-hazard.html' title='Warning : Productivity Hazard'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114358784663156403</id><published>2006-03-28T23:09:00.000Z</published><updated>2006-03-28T23:17:26.643Z</updated><title type='text'>Coding continued...</title><content type='html'>A second post within minutes of the last? That's how fast things are changing here :-) Switched to the second method I mentioned (generic class name that can just stay the same). Always remember: the simple way that doesn't require things that only just made it into the language is always the right way.&lt;br /&gt;&lt;br /&gt;One thing I would like to highlight as a great feature is Visual Studio's essentially infinite undo buffer. A few seconds of holding Ctrl-Z in each source file and I have my original code back :-D&lt;br /&gt;&lt;br /&gt;I have a craving to do something in Python, been doing very little coding at all recently for various reasons (a few that made it here and a few that didn't), and C++ gets a bit oppressive eventually. Why is Python so nice to use? Do they bundle it with virtual crack? Either way, I'm not quite addicted yet, but I may get there one day.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114358784663156403?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114358784663156403/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/coding-continued.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114358784663156403'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114358784663156403'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/coding-continued.html' title='Coding continued...'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114358666296974747</id><published>2006-03-28T22:43:00.000Z</published><updated>2006-03-28T22:57:42.990Z</updated><title type='text'>C++ and Templates</title><content type='html'>I'm currently at the stage of making people lives easier when they adapt my sensor visualiser. The first step was to use templates for a couple of vector-esque classes so that they don't need any editing to reuse. That would be where things started going wrong. A few things about templates with classes caught me off-guard:&lt;br /&gt;&lt;br /&gt;&lt;li&gt;The function definitions must be in the header (or source) file with the declarations so no more handy splitting of headers and code. I liked that ability :-(&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Any functions that have an instance of a templated class passed to them as a parameter must either know ahead of time what the template class was given to play with or be made a template class themselves to accept anything as that parameter. Trust me, that can become very annoying/messy.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;The compiler likes to make up mulitple definitions of functions out of nowhere just to make me hunt around in my source files for little apparent reason.&lt;/li&gt;&lt;br /&gt;&lt;br /&gt;Overall I'm starting to wonder if it was worthwhile. Then I remember that every time they adapt the program to work with a different experiment the user would have to manually edit source that they're not even doing anything to. That's quite unacceptable as far as I'm concerned, though I may have to find inventive ways out if templates annoy me too much.&lt;br /&gt;&lt;br /&gt;I'm thinking possibly name the classes that will be swapped out (that you are creating a vector/list-thing of) to something generic so the name can be kept and it won't affect a non-template list class. Afterall, I suppose I am trying to bend the template concept to something it wasn't quite meant to do...&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;In other news, I'm currently trying not to spend too much time playing Elder Scrolls IV : Oblivion. For me, it has been to RPGs what FEAR was to FPSs, though I would like a bit more variation based on what class/race you choose. Guess that's what going back to Uni early is for, solid lab time where I can't be distracted by such things even if I want to.&lt;br /&gt;&lt;br /&gt;Also, check out &lt;a href="http://blog.dis-dot-dat.net/"&gt;James&lt;/a&gt;'s &lt;a href="http://blog.dis-dot-dat.net/2006/03/dont-go-outside.html"&gt;recent post&lt;/a&gt; on mind-controlling fungus. Paranoid yet?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114358666296974747?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114358666296974747/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/c-and-templates.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114358666296974747'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114358666296974747'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/c-and-templates.html' title='C++ and Templates'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114341549492679294</id><published>2006-03-26T23:04:00.000Z</published><updated>2006-03-26T23:24:54.936Z</updated><title type='text'>pwned by technology</title><content type='html'>I think I can safely say that pushing PC parts a bit to see which way they fall (extra speed or death) is never boring. Tonight I went into the BIOS with the idea of seeing how far I could tweak my RAM, it turns out that it doesn't like a 1T command rate (which I could have guessed easily enough anyway really). After the first failed attempt at booting windows my machine failed to POST, as in nothing coming up at all, so I grabbed my manual looking for the CMOS reset jumper... there isn't one. Cue precious minutes of my life levering out the backup battery, whereafter I proceeded to flip it out of its holder, landing straight back on the motherboard elsewhere (my case being on its side). Suppressing the standard expletive (what with my parents being in bed), I grabbed it and sat there for a moment hoping I didn't shove a voltage into a sensitive and unsuspecting component. Giving it 1 minute rather than the advised 30 seconds (partly because I didn't quite want to see any after-effects of my actions), I reinserted the battery, flicked the switch and... it works, first time :-D Anyway, I reloaded the BIOS's default settings, told it to switch to the higher performance settings and booted windows, and here I am (apparently with nicer RAM timings than before, entirely chosen by the BIOS, I think it may be feeling sorry for me). CPU-Z still reports the old timings though, I will have to investigate (tomorrow, definately not tonight).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114341549492679294?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114341549492679294/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/pwned-by-technology.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114341549492679294'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114341549492679294'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/pwned-by-technology.html' title='pwned by technology'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114338184131982085</id><published>2006-03-26T13:56:00.000Z</published><updated>2006-03-26T14:04:01.333Z</updated><title type='text'>Intel Almost Inside</title><content type='html'>It looks like Intel may be worming their way back into my favour with the new Conroe processors, which have a shorter pipeline than the Netburst based ones as well as supposedly lower power consumption. The main reason I have stayed with AMD for my machines has been for these very two reasons so I may have to possibly reconsider when it comes to putting together my next machine. One the other hand, this is still the same game of catch-up that Intel have been playing for a long time now. AMD makes all the decisions that work out and Intel hastily try to do the same, even to the extent of ditching an entire line of processors (after sinking a fortune into the usual R&amp;D) to embrace a technology they said would amount to nothing. AMD still have my favour, but they stopped being the underdog a long time ago and if history should repeat itself (as it always does), then the time may be coming for some foul-ups on their part.&lt;br /&gt;&lt;br /&gt;In other news, I'm not in the mood to rant about keyboard laptops today, maybe after I've used one next time ;-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114338184131982085?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114338184131982085/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/intel-almost-inside.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114338184131982085'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114338184131982085'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/intel-almost-inside.html' title='Intel Almost Inside'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114321404320987384</id><published>2006-03-24T14:14:00.000Z</published><updated>2006-03-24T15:27:23.253Z</updated><title type='text'>Bad Design</title><content type='html'>I was doing some work in Microsoft Word today and it occured to me that there is one element of bad UI design in it that towers over the others as it is subtle yet incredibly annoying (I'll talk about laptop keyboards next post if I'm still on this subject), and that's the way the Word handles the backspace key. Not too much room to screw up there you might think, but of course this is Microsoft who love finding ways to do exactly that*. They have managed to make me fear using one of the most basic keys on the keyboard. The thing is, pressing backspace to delete a character or two or to change indentation levels (don't even get me started on their tabs/indentation mess) also implicitly deletes any formatting tags it happens to be holding there. This results in your text suddenly changing formatting, your indentation going haywire and the user getting quite annoyed. Add to that all the formatting changes that Word does anyway in an attempt to help you (I've lost count of the amount of times I've had to hit Ctrl-Z to undo something I didn't even do) and I've become quite scared to really try anything, especially that damn backspace key. Overall it's still the word processor I use for pretty much everything that needs formatting (Notepad 2 elsewhere) but I just wish it would play nice with me sometimes.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;* While I love having a go at Microsoft as much as the next guy (or girl), statements like this are very rarely completely serious. I really do appreciate that some of the things they do are quite simply amazing feats of programming. Now if only they'd focus on making programs we like to use rather than just making them look shiny ;-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114321404320987384?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114321404320987384/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/bad-design.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114321404320987384'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114321404320987384'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/bad-design.html' title='Bad Design'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114228245765303433</id><published>2006-03-13T20:35:00.000Z</published><updated>2006-03-13T20:40:57.673Z</updated><title type='text'>Drive Letters Continued</title><content type='html'>Something I forgot to mention in my last post in relation to the drive letter re-ordering. You may be wondering why I didn't use the Disk Management part of the Computer Management tool (under Administrative Tools on your start menu under XP), after all its restriction to not re-lettering the boot drive doesn't apply in this scenario. Short answer is I did and that upgraded my ability to boot from "No programs can start" to "Not even XP can start" for some obscure reason. Maybe I should have tried the registry hack instead...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114228245765303433?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114228245765303433/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/drive-letters-continued.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114228245765303433'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114228245765303433'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/drive-letters-continued.html' title='Drive Letters Continued'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114219380156592714</id><published>2006-03-12T19:43:00.000Z</published><updated>2006-03-12T20:03:21.580Z</updated><title type='text'>Downtime and last minute rush (related possibly?)</title><content type='html'>So this last week has not been a good time for me and my PC. Just over a week ago Windows decided to re-letter my hard drives, this is quite a stupid thing to do but fortunately it makes sure the boot drive keeps its familiar C: designation, unfortunately this doesn't help when the definition of "boot drive" is the traditional definition of "the drive that the BIOS uses to boot the system" rather than the much more useful "the drive that windows is actually installed on". Long story short, windows renamed the drive it and all my apps load from, cue everything falling over and bursting into virtual flames. Luckily I have a backup install of Windows so I skipped on over back to that one and used it while I made my backups (a mere 4.5 DVDs of data) and then did a full format/reinstall. This was all well and good... until a day later when a system file broke and started toppling the system anywhere between 1 minute and 1 hour after boot (and I'm talking the type of BSOD that involves a core memory dump, I'd forgotten Windows even did those). So back to my backup install I went and spent another couple of days there. I was about to start my main install from scratch for the second time in a week when I gave it one last chance... and it worked perfectly fine. Since then it has been playing nicely with my system so it looks to have fixed itself, but it has left me with a week of lost productivity. Grrrrrr. This means that I now have two pieces of coursework which I am having to do in the space of one night. Don't you just love deadlines?&lt;br /&gt;&lt;br /&gt;Some random articles that might be of interest to you (all on the same site).&lt;br /&gt;&lt;a href="http://www.joelonsoftware.com/articles/LeakyAbstractions.html"&gt;The Law of Leaky Abstractions&lt;/a&gt; - Why non-trivial abstractions never quite work as they should&lt;br /&gt;&lt;a href="http://www.joelonsoftware.com/articles/fog0000000319.html"&gt;Back to Basics&lt;/a&gt; - Why programming at a high-level before you understand the low-level is a bad idea&lt;br /&gt;&lt;a href="http://www.joelonsoftware.com/articles/fog0000000041.html"&gt;Three Wrong Ideas From Computer Science&lt;/a&gt; - A few things to think about&lt;br /&gt;&lt;br /&gt;Anyway, back to work I guess, as soon as it's done I'm going to be a very happy person.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114219380156592714?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114219380156592714/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/03/downtime-and-last-minute-rush-related.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114219380156592714'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114219380156592714'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/03/downtime-and-last-minute-rush-related.html' title='Downtime and last minute rush (related possibly?)'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114087878096534810</id><published>2006-02-25T14:33:00.000Z</published><updated>2006-02-25T14:46:20.980Z</updated><title type='text'>More Links</title><content type='html'>Don't worry, I'm not becoming one of those blogs that exists entirely on giving you links to interesting places ;-)&lt;br /&gt;&lt;br /&gt;Today we have something for you HCI types out there, a example (in Flash) of an interface that doesn't require clicking, complete with functionality for forms and suchlike. Personally I like it, &lt;a href="http://www.dontclick.it/"&gt;check it out&lt;/a&gt;. Then there's something you may find slightly odd, a webserver hosted in a dead &lt;a href="http://conceptlab.com/fly/"&gt;fly&lt;/a&gt;, not the nicest looking system but certainly interesting from a miniaturisation and general wierdness perspective. Of course there's &lt;a href="http://cognews.com/"&gt;CogNews&lt;/a&gt; for those of you interested in how the brain works, and finally we have apparently discovered a miniature solar system that is in the process of forming, see &lt;a href="http://www.msnbc.msn.com/id/10256954/"&gt;here&lt;/a&gt;. In the pic the main thing is a solar system of about the size we normally expect (though the planets appear to be bunched around the sun a lot more than I expect), while the extra planet sized thing is in fact the entire new solar system, which orbits a brown dwarf.&lt;br /&gt;&lt;br /&gt;Think that's enough for my mini linkathon, have fun people.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114087878096534810?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114087878096534810/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/02/more-links.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114087878096534810'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114087878096534810'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/02/more-links.html' title='More Links'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114082281345769643</id><published>2006-02-24T23:02:00.000Z</published><updated>2006-02-24T23:13:33.466Z</updated><title type='text'>Links and life</title><content type='html'>Just some random links for you today. First up is &lt;a href="http://www.gamedev.net/community/forums/topic.asp?topic_id=376177"&gt;this&lt;/a&gt; which looks mighty impressive (decent waves and clouds, high resolution textures and soft shadows all running over the 60fps mark). For those of you looking for something to read (lucky you, having some spare time to do anything) we have &lt;a href="http://www.hermetics.org/ebooks.html"&gt;this&lt;/a&gt; nice little library of "Magical and Mystical" ebooks, if it has a chance of being banned by "the church" (offer only valid in Christian countries) then it must be good :-P. Then there's my new news reader (Tristana Reader really sucks tbh) called &lt;a href="http://www.ziecom.com/"&gt;Newzie&lt;/a&gt;, it takes a while to get used to and has a couple of annoying bugs/"features" but it is really quite good (especially for a program pre-v1.0), just don't tell it to minimise when you click the close button, it really doesn't like that.&lt;br /&gt;&lt;br /&gt;On a news front, there isn't too much. Been kinda ill/feeling wierd this week so not much interaction with the real world. Probably didn't do me too much good playing chess outside in the freezing cold for like 2.5 hours with Dan on Wednesday but that giant set in the Jaguar (correct building?) courtyard is just so inviting...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114082281345769643?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114082281345769643/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/02/links-and-life.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114082281345769643'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114082281345769643'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/02/links-and-life.html' title='Links and life'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-114002633747093551</id><published>2006-02-15T17:38:00.000Z</published><updated>2006-02-15T17:58:57.696Z</updated><title type='text'>Love thy geek</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/2249/2076/1600/caffeine.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://photos1.blogger.com/blogger/2249/2076/200/caffeine.jpg" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;So this valentine's day my gf bought me one of those &lt;a href="http://www.geomagsa.com/cp_gioco.php"&gt;Geomag&lt;/a&gt; sets, a truely great toy for a geek needing distraction from work (all usual distractions aside). The first thing I made? Well it had to be one of the few things I'm addicted to of course... Caffeine :-) Check it out to the left. Of course now I need to obtain a couple more parts to finish off two of the CH3 parts and possibly different colour sticks for the double bonds...&lt;br /&gt;&lt;br /&gt;Sensor Visualiser is coming along. Reorganisation of everything is basically done, sensors can now move around and have the display reflect that and the code for grabbing readings in real-time can pretty much be dropped in and work and then I can resign the "legacy" parts to be optional and not currently implemented. One minor problem still exists in that I appear to have broken something in the rendering code so that everything displays perfectly other than the sensor markers :-S At least they don't produce any errors, which means it's a simple logic mistake somewhere rather than something seriously wrong, probably some left-over old code taking data and doing nothing with it or something.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-114002633747093551?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/114002633747093551/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/02/love-thy-geek.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114002633747093551'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/114002633747093551'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/02/love-thy-geek.html' title='Love thy geek'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113934077028867933</id><published>2006-02-07T19:19:00.000Z</published><updated>2006-02-07T19:32:50.300Z</updated><title type='text'>Haven't I been here before?</title><content type='html'>So it looks like tonight (unless I get distracted) will be the night for a major overhaul of my visualiser code, and after this one it will be ready for anything we need to throw at it *crosses fingers* Seriously though, it'll be a lot more expandable and so on and so forth after this, literally a case of a functionality change being a matter of deriving a new class and using that or changing a couple of lines in an existing one (and if I can warp templates to my will one of the things will be even easier than that).&lt;br /&gt;&lt;br /&gt;Think after I've done the overhaul I'll reward myself with some time to do... more coding =P My serverless IM client is on hold atm, as are most of the other bits, so it'll probably the Python neural net library, either moving from layered (normal and sensible) to a mesh (pretty much insane) or making it capable of learning, but which learning method to choose?&lt;br /&gt;&lt;br /&gt;Now... GBA programming. That's an exercise and a half. The coding itself is fine, that's all well and good. Problem is I'm stuck with compiling it with either VC++ 2003 which can't output ELFs to run through the rest of the toolchain or with VisualHAM which doesn't like me having half the files in other places (ie, my library of helper functions that I wrote to not have the HAM logo bouncing around at GBA boot). Any thoughts would be appreciated. It's nice that VisualHAM will go through all the apps in the toolchain automatically plus launch the emulator if wanted, it is written specifically for this after all, very very handy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113934077028867933?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113934077028867933/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/02/havent-i-been-here-before.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113934077028867933'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113934077028867933'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/02/havent-i-been-here-before.html' title='Haven&apos;t I been here before?'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113896177799940138</id><published>2006-02-03T01:37:00.000Z</published><updated>2006-02-03T20:18:15.423Z</updated><title type='text'>FEAR</title><content type='html'>Dan let me borrow the game F.E.A.R. to try out and I have to say I am impressed. It is one of those rare games that make you glad you upgraded your graphics card (though in my case it was a while ago and my 6600GT can just about keep up with it, I would love to see it at full detail settings). It combines a lot of elements I've seen in other games, but never at the same time...&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;The Music&lt;/span&gt;&lt;br /&gt;The music is almost perfect. The samples merge together flawlessly and nearly always reflect exactly what's going on, you'll be walking down a corridoor with a haunting (and slightly addictive) track playing in the background and suddenly you'll hear snatches of conversation from further up ahead and the music will ramp up in tempo. Then there's the areas with no music at all, a lot of games forget how incredibly atmospheric it can be for the music to drop out and leave you in complete silence just praying for something, anything, to happen to break the tension that mounts up.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;The Levels&lt;/span&gt;&lt;br /&gt;Some of the nicest level designs I've seen, especially when combined with all the things going on around you, from the corpses laying in pools of their own blood to strip lights that suddenly break free and swing from the power cord on one end (and the lighting effects coming off of them are spot on). Speaking of corpses, that's another thing, finally a game not scared of showing us a litle gore. Shoot someone in the neck and blood spurts out, throw a grenade into an eclosed space containing someone and it pretty much redefines red mist. And just to go off topic even more, grenades... well, explosives in general, I just love the effect they produce. Think the ripple effect when the helicopter hits the side of the building in The Matrix except in mid-air rather than across the windows and you're pretty much there.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;The Storyline&lt;/span&gt;&lt;br /&gt;Admittedly I haven't played through too many of the levels yet, but already it has me thinking and wondering exactly what's really going on. Plus anything with a scary devil girl is a winner for me. It slowly reveals the story in flashes, though where the flashes are from you aren't told, that's for you to work out =P&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;The AI&lt;/span&gt;&lt;br /&gt;A game where the bad guys act vaguely intelligently? At long last. If you shoot at them they will warn their mates and... wait for it... take cover *shock* A game where they will take cover when shot at rather than running at you like idiots, something that is long overdue (yes I know it's been done before, but it is honestly few and far between). Not only that but the other guys will try to circle round to flank you, they will vault over obstacles to get to you or away from you, they will basically try to work as a team while preserving themselves. Scripted or not, it's quite impressive to watch.&lt;br /&gt;&lt;br /&gt;Think that's enough rambling for now, just trust me that the game is worth it if you're into FPSs and you have a relatively beefy system. The 3GHz processor and 1GB or RAM recommended configuration is more of a minimum for it to look good, my setup is currently mainly suffering on the cpu side rather than the gpu side from what I can tell.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Edit:&lt;br /&gt;A quick list of other things that don't seem to make it into most games but are in F.E.A.R., small things that really make the game:&lt;br /&gt;Guys limping after being shot in the leg, guys being knocked over if they're at the edge of a blast, guys being caught in the open and running away from you while firing blindly behind them to make you duck out of the way and keep you from getting a clear shot at their back.&lt;br /&gt;&lt;br /&gt;My prediction is that as the graphics in games gets as close to reality as possible, the only place to put the extra hardware abilities is into the physics engines and making everything that's not graphics as realistic as possible. Also, some optimising wouldn't go amiss, considering the current philosophy of not bothering because the systems should be able to handle it, games really don't need 4GB of data to look how they do.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113896177799940138?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113896177799940138/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/02/fear.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113896177799940138'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113896177799940138'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/02/fear.html' title='FEAR'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113855886269412442</id><published>2006-01-29T17:30:00.000Z</published><updated>2006-01-29T18:21:06.036Z</updated><title type='text'>Sensor Visualiser progress</title><content type='html'>At last progress :D Today (and probably the next couple of days) is my time for major revamping of the application. Custom surfaces being made on demand, no ties to particular incoming data, actually being able to do the things it's meant to be able to, it's all going in. I've found it's incredibly useful to create a list in Word of everything you need to do. That way you can either use strikethrough when it's done or turn the text light grey if it doesn't need to be done or can't be done. It's quite an incentive watching the points disappear :-) Another great feature is the comments, highlight some text and go Insert -&gt; Comment and it will add a comment into the righthand margin linked to the text, looks quite nice.&lt;br /&gt;&lt;br /&gt;When this list is done it's on to interfacing with real sensors, that's gonna be fun...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113855886269412442?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113855886269412442/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/sensor-visualiser-progress.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113855886269412442'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113855886269412442'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/sensor-visualiser-progress.html' title='Sensor Visualiser progress'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113837027948737349</id><published>2006-01-27T13:24:00.000Z</published><updated>2006-01-30T13:34:13.663Z</updated><title type='text'>Do actual work? Me?</title><content type='html'>This weekend is going to be (hopefully) a big step for my Sensor Visualiser project, I have assembled a list of features and fixes that it needs and I'm going to hammer in as many as possible when I've done with the Open Day on Saturday.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://blog.dis-dot-dat.net/"&gt;James&lt;/a&gt; &lt;a href="http://blog.dis-dot-dat.net/2006/01/flock-and-world-of-crap.html"&gt;posted&lt;/a&gt; a link on his blog that might keep you interested for a while : &lt;a href="http://homepage.mac.com/pockyrevolution/Personal25.html"&gt;The Best of Google Videos&lt;/a&gt;. Also, &lt;a href="http://varspool.blogspot.com/"&gt;Sarah&lt;/a&gt; has been playing around with her &lt;a href="http://www.symbian.com/"&gt;Symbian60&lt;/a&gt; phone and has &lt;a href="http://www.python.org/"&gt;Python&lt;/a&gt; running on it along with a couple of things she's put together. Go check them out.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113837027948737349?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113837027948737349/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/do-actual-work-me.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113837027948737349'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113837027948737349'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/do-actual-work-me.html' title='Do actual work? Me?'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113811858711823870</id><published>2006-01-24T15:34:00.000Z</published><updated>2006-01-30T13:32:45.606Z</updated><title type='text'>Cogent, DVDs and Neural Nets</title><content type='html'>Three quick topics today. First up is the Cogent Centre launch you may have heard mentioned on Sarah or James' blogs. As far as I know it went well, though my knowledge of what's going on behind the scenes is rather limited ;-)&lt;br /&gt;&lt;br /&gt;Next up, DVD regions. A common problem, an American mate lends you a DVD and it's region 1, while your drive is set to region 2. Do you waste two of your precious five allowed changes on switching to region 1 and back just to watch this one DVD? Of course not, that would be silly. Instead, use &lt;a href="http://www.videolan.org/vlc/"&gt;VLC&lt;/a&gt; to watch it. VLC is a truely amazing client, it can play almost literally anything. All the usual video formats (mpeg, avi, etc), audio formats (ogg, mp3, etc) plus about half of the movs out there, DVDs (including incorrect region ones), VCDs, a metric ass-load of streaming formats, and can also act as a server for streaming audio and video across a network. And the features that I originally got it for? Built-in codecs in case you're missing them and the ability to make a good guess at reconstructing broken videos. Overall, it is the best thing to happen to my PC's media abilities.&lt;br /&gt;&lt;br /&gt;And the alst topic today, neural nets. I'm building a neural net library in Python (probably a million out there already, but a learning experience you know...). I'm basically making it as simple to use as possible, at the moment if you have a file describing it in a format it expects you can do simply:&lt;br /&gt;&lt;pre&gt;import NeuralNet.importers as nnimporters&lt;br /&gt;NewNet = nnimporters.LoadFromText(filename)&lt;/pre&gt;&lt;br /&gt;The importers module currently also imports the actual worky bitz in order to construct a working net for you, you could also do this with&lt;br /&gt;&lt;pre&gt;import NeuralNet.base&lt;/pre&gt;&lt;br /&gt;Then to actually use it, it's simple a case of&lt;br /&gt;&lt;pre&gt;outputs = NewNet.Solve(valueList)&lt;/pre&gt;&lt;br /&gt;Supplying a list of inputs in valueList and receiving a list of outputs as the return value. What could be easier?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113811858711823870?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113811858711823870/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/cogent-dvds-and-neural-nets.html#comment-form' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113811858711823870'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113811858711823870'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/cogent-dvds-and-neural-nets.html' title='Cogent, DVDs and Neural Nets'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113728016567468950</id><published>2006-01-14T23:04:00.000Z</published><updated>2006-01-14T23:09:25.683Z</updated><title type='text'>Gentlemen, we have a window</title><content type='html'>So w00t, I have the app running in a window. Turns out that to show the window you have to call... wait for it... &lt;span style="font-weight:bold;"&gt;ShowWindow&lt;/span&gt;. Bet that was a surprise ;-) Anyway, capture will proceed as planned and all is good I guess. One problem that may be slightly obvious though is that using mouse navigation doesn't really work as you'd expect it to normally in a window. Oh well, you loose some, you gain some. I can make it look good as far as the video is concerned and that's what matters I guess.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113728016567468950?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113728016567468950/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/gentlemen-we-have-window.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113728016567468950'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113728016567468950'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/gentlemen-we-have-window.html' title='Gentlemen, we have a window'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113718350164520541</id><published>2006-01-13T20:13:00.000Z</published><updated>2006-01-13T20:18:21.650Z</updated><title type='text'>Yay for screen capture   -_-</title><content type='html'>So I need to make a video of my sensor visualisation program running, and of course you can't capture full-screen apps (well... you can but it looks like you're on acid when you watch it). That means I need to coerce the thing to run in a window, predictably I haven't written my graphics core to account for windowed apps (who writes a game in windowed mode?) so I've had to retrofit that. It all compiles nicely and runs without errors, with just one problem: nothing appears. So now I have to find out what single API call I haven't made that is stopping the window from displaying itself, fun...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113718350164520541?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113718350164520541/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/yay-for-screen-capture.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113718350164520541'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113718350164520541'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/yay-for-screen-capture.html' title='Yay for screen capture   -_-'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113697998758928208</id><published>2006-01-11T11:34:00.001Z</published><updated>2006-01-11T11:46:27.590Z</updated><title type='text'>FAT Patent</title><content type='html'>So Microsoft finally got their way and the patents on the FAT filesystem have been accepted. I have to ask wtf? The filesystem was declared "novel and non-obvious" as is required by patent law in America (I dunno how this will hold up in other countries) despite apparent prior-art on it and despite the fact that a person developing their own OS can implement full support for it within a day. If they're busy. It has been widely used in things like digital cameras and flash drives, on the basis that it is so damn simple and easy to use. It doesn't include any sort of security (access permissions for files, etc) nor any other such features, but yet apparently it's complicated enough to warrant a patent. I mean seriously, a map of where the files are on the drive, isn't that the most obvious way of organising them imaginable (short of having fixed locations)?&lt;br /&gt;&lt;br /&gt;Plus, I fail to see Microsoft's motives here, the only reason to fight to have the patent recognised is if they were going to sue people who use the things covered by it, and that would be almost every company that makes devices with removable storage along with any other OSes out there (most obviously Linux, but almost every OS made includes FAT support purely because it's so widespread). Well... maybe I do see their motives...&lt;br /&gt;&lt;br /&gt;Linkage : &lt;a href="http://news.com.com/Microsofts+file+system+patent+upheld/2100-1012_3-6025447.html?part=rss&amp;tag=6025447&amp;subj=news"&gt;CNET News&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113697998758928208?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113697998758928208/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/fat-patent_11.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113697998758928208'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113697998758928208'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/fat-patent_11.html' title='FAT Patent'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113686129797221763</id><published>2006-01-10T02:39:00.000Z</published><updated>2006-01-10T16:29:49.973Z</updated><title type='text'>Cortana and the future of Halo</title><content type='html'>Ok, this is very old news for those on the scene, but I haven't been following very fanatically :P This is related to one of my current projects, but not one you've seen yet.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;I have walked the edge of the Abyss.&lt;br /&gt;I have governed the unwilling.&lt;br /&gt;I have witnessed countless empires break before me.&lt;br /&gt;I have seen the most courageous soldiers fall away in fear.&lt;br /&gt;[I was there with the Angel at the tomb]&lt;br /&gt;I have seen your future.&lt;br /&gt;And I have learned.&lt;br /&gt;There will be no more Sadness. No more Anger. No more Envy.&lt;br /&gt;I HAVE WON.&lt;br /&gt;&lt;br /&gt;Oh, and your poet Eliot had it all wrong:&lt;br /&gt;THIS is the way the world ends.&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;That's a message (apparently sent back in time) from Cortana who appears to be either in one of her deep and slightly over-dramatic moods or going a bit insane, with both being very possible given her personality and experiences. Now, this is the first of a series of messages and they are very interesting. They appear to be sent back in time, as noted above, presumably using Forerunner tech, from a time after Halo 3 when Cortanan is near the end of her life.&lt;br /&gt;&lt;br /&gt;The last line is the one I find most intersting currently, apparently TS Eliot's "it ends not with a bang, but a whimper" is wrong. And what's the biggest "bang" available in the Halo universe? The Halos themselves...&lt;br /&gt;&lt;br /&gt;Of course, this isn't official cannon as they decided that the Marathon universe should be kept seperate, but nonetheless I like big explosions and suchlike and it still sounds like the Cortana (and Master Chief, the Covenant and the Flood when she refers to them in the other messages) that I know and love.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113686129797221763?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113686129797221763/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/cortana-and-future-of-halo.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113686129797221763'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113686129797221763'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/cortana-and-future-of-halo.html' title='Cortana and the future of Halo'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113683543922333615</id><published>2006-01-09T19:27:00.000Z</published><updated>2006-01-09T19:41:49.363Z</updated><title type='text'>SenSOR + 3D Trilateration</title><content type='html'>3D trilateration in SenSOR (I think I'm using the right capitalisation at last)... In theory very simple given that I'm just porting the code from Java to Python and I have a library that has very nicely named functions. In reality it was indeed very simple, though there were a couple of annoying bits.&lt;br /&gt;&lt;br /&gt;Tip 1 : Always remember what your own code does, if your function is designed to add some text to a textbox on a GUI it isn't going to send it to the console window, no matter how hard it tries.&lt;br /&gt;&lt;br /&gt;Tip 2 : Always remember any sort-comings of the code you're using, nothing beats spending half a night tracking down a bug that isn't even a bug in the first place and is in fact a weakness (that you memorised months ago) in an algorithm that you've been using for said amount of months.&lt;br /&gt;&lt;br /&gt;So yeah, the algorithm I'm using can't trilaterate if the reference points are on the same plane, serves the sensors right for being boring I guess.&lt;br /&gt;&lt;br /&gt;In other news, this damn posting page is making firefox hit 90-ish% CPU usage, time to rethink it a bit maybe?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113683543922333615?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113683543922333615/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/sensor-3d-trilateration.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113683543922333615'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113683543922333615'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/sensor-3d-trilateration.html' title='SenSOR + 3D Trilateration'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113664833972830236</id><published>2006-01-07T15:17:00.000Z</published><updated>2006-01-10T00:11:27.043Z</updated><title type='text'>Game Engine bits</title><content type='html'>Just some random notes on standard stuff in my engine, so I remember for the documentation.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;All classes (except those that can be used "out of the box") will have a method called Init that will set it up to be used, this must be called before any other method and cannot be called more than once unless Free is called first, ignoring these rules will cause methods to return an error code instead of carrying out their function.&lt;br /&gt;&lt;br /&gt;All classes that have an Init method will also have a method called Free that will put them into a state where Init can be called again safely. The one class this is not guaranteed for is cgGraphics, though it should be fine ;-)&lt;br /&gt;&lt;br /&gt;All constants will have a prefix followed by an underscore. This prefix will denote what the constant in relevant for. For instance, constants starting with CG_ are error codes defined within the graphics core. In general, C_ refers to general error codes that can be used anywhere, while Cx_ refers to error codes and constants defined for a particular core (CG_ = graphics core and CI_ = input core currently).&lt;br /&gt;&lt;br /&gt;All methods, except where inappropriate, will return a standard error code. Where possible this will be one from the pool defined in the global list in order to cut down on repetition or confusion.&lt;br /&gt;&lt;br /&gt;All variables will start with a lowercase letter and use the "humpback" style of seperating words (eg screenWidth). Variables contained within a class will start with c_ and the first letter after this will be a capital (ie, the c counts as the first lowercase letter).&lt;br /&gt;&lt;br /&gt;ULONG is typedefed as an unsigned long integer so you don't have to include other header files just for that definition. The macro CFAILED(x) is defined to check if x is an error code denoting the failure of a method, eg&lt;br /&gt;&lt;pre&gt;if (CFAILED(cg.SetCamera(&amp;cam))) {/* Do stuff */}&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Edit:&lt;br /&gt;Class names: All class names start with a prefix that indicates what core they belong to for ease of reference. These prefixes follow the same pattern as the constant prefixes except lower-case and without the underscore (eg, cgVertexBuffer). Each core includes a class (refered to as the top-level class sometimes) that provides an interface to the basic functionality of that core (eg, the graphics core has the cgGraphics class that handles tasks such as setting up the drawing surfaces). Most classes within the core will at some point (usually in the Init function) require a pointer to the top-level class in order to use this functionality.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113664833972830236?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113664833972830236/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/game-engine-bits.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113664833972830236'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113664833972830236'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/game-engine-bits.html' title='Game Engine bits'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-20636280.post-113659335599582971</id><published>2006-01-07T00:09:00.000Z</published><updated>2006-01-07T00:22:36.003Z</updated><title type='text'>First Post</title><content type='html'>Most unoriginal title ever, but it's to be expected really.&lt;br /&gt;&lt;br /&gt;As stated in the description, this would be where my brain core dumps in relation to my current projects. At current count these are:&lt;br /&gt;&lt;ul&gt;&lt;br /&gt; &lt;li&gt;A 3D game engine (no name as of yet)&lt;br /&gt; &lt;li&gt;A first-person RPG based on the above (think Vampire: Bloodlines)&lt;br /&gt; &lt;li&gt;An application that shows data from wireless sensors in real-time (also using the aforementioned engine)&lt;br /&gt; &lt;li&gt;A processor aimed at embedded systems&lt;br /&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;That's the main software ones I can think of right now. The game engine is going quite well in terms of the basic stuff (rendering stuff with FVF descriptors, all the usuals) minus a few annoying problems with free-floating cameras, though first-person ones work as expected :-)&lt;br /&gt;&lt;br /&gt;The RPG is going to take a very long time to hammer out a final design for (I'm mainly doing it as a creative exercise really) and I would need someone else to make the models and textures as my graphical skills aren't up to that task.&lt;br /&gt;&lt;br /&gt;The sensors app is something I'm doing for my final year computing project and I don't know how much info I'll be able to post about it without annoying my project supervisor or being detrimental to my grades, so vague info only until further notice.&lt;br /&gt;&lt;br /&gt;That brings us to the last item on the list, the processor. I decided I had too many software projects on the go (I have a lot of smaller ones in addition to these) so I could do with a hardware one, combine that with my "jump in at the deep end and you'll &lt;b&gt;have&lt;/b&gt; to learn" philosophy and viola.&lt;br /&gt;&lt;br /&gt;I think that's enough for my first post anyway, stay tuned...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20636280-113659335599582971?l=kempproject.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kempproject.blogspot.com/feeds/113659335599582971/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kempproject.blogspot.com/2006/01/first-post.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113659335599582971'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20636280/posts/default/113659335599582971'/><link rel='alternate' type='text/html' href='http://kempproject.blogspot.com/2006/01/first-post.html' title='First Post'/><author><name>Kemp</name><uri>http://www.blogger.com/profile/00254308947285339009</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
