<?xml version="1.0" encoding="utf-8"?>
    <rss version="2.0">
    <channel>
    <title>Neil Schemenauer's Web Log</title>
    <link>http://python.ca/nas/log/</link>
    <description>Random thoughts and notes.</description>
    <item><title>Samsung Galaxy S (I9000) partitioning scheme</title><description>&lt;p&gt;I had trouble finding details about how flash memory is partitioned on this device, here's what I learned in case it helps others.  The device has two built-in flash memory devices: 8 or 16GB NAND and flash memory connected directly to the processor chip (MMC).&lt;/p&gt;
&lt;p&gt;The MMC can be partitioned using different schemes.  The stock ROMs use a scheme called BML.  Most open source ROMs use a more flexible scheme called MTD.  When you first install CyanogenMod 7, for example, the MMC is converted to use MTD partitioning.  The MMC partitions are as follows:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;kernel&lt;/li&gt;
&lt;li&gt;recovery&lt;/li&gt;
&lt;li&gt;/system (factorfs)&lt;/li&gt;
&lt;li&gt;/dbdata&lt;/li&gt;
&lt;li&gt;/cache&lt;/li&gt;
&lt;li&gt;/radio (modem)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you are familiar with the Heimdall or Odin tools, these names will be familiar.  Odin and Heimdall use the PIT file to control the partitioning of the MMC (e.g. s1_odin_20100512.pit).&lt;/p&gt;
&lt;p&gt;The NAND device is partitioned into two parts: /data and /mnt/sdcard.  The partition mounted on /mnt/sdcard is referred to as the internal SD card.  If you put a SD card in the external slot, it is mounted as /emmc (at least in CM9).&lt;/p&gt;
&lt;p&gt;For reference, here is the NAND partition information for my i9000m phone.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;klonk:~$ adb shell
shell@android:/ $ su
shell@android:/ # fdisk /dev/block/mmcblk0

The number of cylinders for this disk is set to 1953792.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
   (e.g., DOS FDISK, OS/2 FDISK)

Command (m for help): p

Disk /dev/block/mmcblk0: 16.0 GB, 16005464064 bytes
1 heads, 16 sectors/track, 1953792 cylinders
Units = cylinders of 16 * 512 = 8192 bytes

              Device Boot      Start         End      Blocks  Id System
/dev/block/mmcblk0p1               5     1708032    13664224   c Win95 FAT32 (LBA)
Partition 1 does not end on cylinder boundary
/dev/block/mmcblk0p2         1708033     1953792     1966080   c Win95 FAT32 (LBA)
Partition 2 does not end on cylinder boundary

Command (m for help): 
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;On my phone /data is formatted as ext4 and /mnt/sdcard as vfat.  One other thing, if you connect your phone to a computer with USB, the mass storage devices that are visible correspond to /mnt/sdcard and /emmc (i.e. one partition of the NAND and the external SD card).  The other devices are not visible.&lt;/p&gt;</description><pubDate>Wed, 04 Apr 2012 05:15:03 GMT</pubDate><link>http://python.ca/nas/log/201204/index.html#03_001</link><guid isPermaLink="false">tag:python.ca,2012-04-04:/nas/log/03_001</guid></item>
<item><title>Microsoft Exchange time-zone confusion</title><description>&lt;p&gt;This has happened to me more than once and somehow I think I'm not the only one.  When Microsoft Exchange sends out calendar related email, it includes time-zone information in the text of the message.  Good idea, right?  Well, the implementation leaves something to be desired.  For example, if the message contains the line:&lt;/p&gt;
&lt;blockquote&gt;When: Wednesday, March 28, 2012 3:00 PM-4:00 PM (GMT-06:00) Central Time (US &amp;amp; Canada).
&lt;/blockquote&gt;
&lt;p&gt;what time would you guess the event occurs at?  If you guessed 21:00 UTC (12+3+6) then you lose.  The time zone offset is actually GMT-5 as the &quot;text/calendar&quot; attachment (not so) plainly shows.  The problem is that the local time-zone of the sender was Central Daylight Time.
&lt;/p&gt;</description><pubDate>Wed, 28 Mar 2012 00:11:33 GMT</pubDate><link>http://python.ca/nas/log/201203/index.html#27_001</link><guid isPermaLink="false">tag:python.ca,2012-03-28:/nas/log/27_001</guid></item>
<item><title>Silly Quixote benchmark</title><description>&lt;p&gt;Looks like the &lt;a href=&quot;http://quixote.ca/&quot;&gt;old dog&lt;/a&gt; can &lt;a href=&quot;https://github.com/nascheme/quixote-shootout&quot;&gt;still run&lt;/a&gt; with the &lt;a href=&quot;http://flask.pocoo.org/&quot;&gt;young pups&lt;/a&gt;.  If you are starting a new web project in Python, Flask is worth a look.  I spent some time poking around at the source code and it looks decent.  The &quot;context&quot; hacks are probably the ugliest part of it but not so bad.  I don't care for Django, it's origin as a content delivery system is pretty apparent.
&lt;/p&gt;
&lt;p&gt;BTW, &lt;a href=&quot;http://wiki.python.org/moin/Durus&quot;&gt;Durus&lt;/a&gt; has been doing NoSQL for ages, almost as long as ZODB.  :-)
&lt;/p&gt;</description><pubDate>Mon, 20 Feb 2012 06:08:02 GMT</pubDate><link>http://python.ca/nas/log/201202/index.html#20_001</link><guid isPermaLink="false">tag:python.ca,2012-02-20:/nas/log/20_001</guid></item>
<item><title>Hooray for paper</title><description>&lt;p&gt;I like technology.  Sometimes though the old ways are still best.  I voted in the federal election this morning.  I used a graphite pencil to make a mark on a slip of paper.  It really was about as painless as possible.  The simplicity of system greatly reduces the chances of fraud or failures.&lt;/p&gt;
&lt;p&gt;I'm heading to the field soon.  There exist a number of field record keeping systems based on PDAs, mobile phones or computers.  For the foreseeable future I plan to continue to use a per-printed paper form, a clipboard and a pencil.  Entering the data into the computer after the fact is not a serious problem.  I'll let someone else be the technical pioneer in this case.  &lt;/p&gt;</description><pubDate>Mon, 02 May 2011 22:52:02 GMT</pubDate><link>http://python.ca/nas/log/201105/index.html#02_002</link><guid isPermaLink="false">tag:python.ca,2011-05-02:/nas/log/02_002</guid></item>
<item><title>Neil Macdonald reports on Osoma's death</title><description>&lt;p&gt;&quot;&lt;a href=&quot;http://www.cbc.ca/news/world/story/2011/05/02/neil-macdonald-osama-bin-laden.html&quot;&gt;The Devil likely died happy&lt;/a&gt;&quot;.
&lt;/p&gt;&lt;p&gt;I hope American citizens will continue to fight to restore lost liberties.  If you haven't seen it, &lt;a href=&quot;http://www.archive.org/details/ThePowerOfNightmares&quot;&gt;The Power of Nightmares&lt;/a&gt; seems fitting at this point given that some of the news reporters are asking what this means for the leadership of al-Qaeda.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Why_We_Fight_(2005_film)&quot;&gt;Why We Fight&lt;/a&gt; is also worth watching.  The notion that terrorists attack because they &quot;hate America's freedom&quot; is ludicrous.  To effectively fight someone you really should be clear on their motivations.&lt;/p&gt; </description><pubDate>Mon, 02 May 2011 22:39:33 GMT</pubDate><link>http://python.ca/nas/log/201105/index.html#02_001</link><guid isPermaLink="false">tag:python.ca,2011-05-02:/nas/log/02_001</guid></item>
<item><title>Sasktel's new 3G+ network</title><description>&lt;p&gt;Sasktel has been recently bragging about their new &quot;3G+&quot; network.  For a change, it actually is something worth bragging about.  Cell phone technology is &lt;a href=&quot;http://en.wikipedia.org/wiki/HSDPA&quot;&gt;extremely complicated&lt;/a&gt;.  There is an old saying that the good thing about standards is that there are so many to choose from.  Cellular network people have taken that idea to a whole new level.&lt;/p&gt;
&lt;p&gt;Johannes Lindenbaum has a pretty good &lt;a href=&quot;http://johanneslindenbaum.blogspot.com/2010/08/sasktels-3g-network-and-state-of.html&quot;&gt;explaination&lt;/a&gt; of the situation.  In summary, Sasktel, Telus, and Bell are all deploying UMTS/HSPA networks that use the 850/1900 MHz bands.  New phones will have SIM cards and so you can switch phones just by moving the SIM card. People in other countries had this feature with their GSM phones for long time already (many places it is required by law).  We North Americans are a little slow.&lt;/p&gt;
&lt;p&gt;The &lt;a href=&quot;http://www.howardforums.com/showthread.php/1632142-The-Official-quot-SaskTel-network-upgrade-amp-when-can-I-get-an-iPhone-thread-quot?p=13966156#post13966156&quot;&gt;buzz&lt;/a&gt; is that Sasktel is selling SIM cards to be used with unlocked phones.  This is much bigger news than the supposed superior data speed of the &quot;3G+&quot; network, IMHO.  People have already been buying iPhones elsewhere and then buying a $10 SIM card from Sasktel to activate them. Obviously you still have service fees but being able to buy and sell phones and easily move them between providers is a huge deal. &lt;/p&gt;
&lt;p&gt;Want to buy a phone to use on the Sasktel 3G+ network?  Minimally, it must support UTMS on 850 and 1900 MHz.  That will give you voice service.  Watch out, some phones support GSM on 850 and 1900 and UTMS on 900 and 2100 and sometimes the labeling can be confusing.  Most UTMS/HSPA networks in the USA use the 900/2100 bands and those phones will not work. AT&amp;amp;T uses 850/1900.  The phone should support HSPA if you want data services (I'm not sure about the difference between HSPA, HSPA+, and HSDPA). The phone needs to be &quot;unlocked&quot;.  Because phones are often sold at a loss, companies lock them to a single SIM card so they have to be used on a certain network.  Courts have ruled that it is legal to break this &quot;lock&quot; (usually you just need a numeric code) so you can use any SIM.  If the phone does not come unlocked you can usually pay someone to unlock it for about $20.&lt;/p&gt;
&lt;p&gt;One final note, you don't need a &quot;smartphone&quot; (another marketing term) or a data plan to get on the 3G+ network.  All you need is a phone that supports UTMS on the 850/1900 Mhz bands.  Finally take this information with grain of salt.  I'm not an expert so do your own research before spending big money on something like a &lt;a href=&quot;http://www.google.ca/search?hl=en&amp;amp;q=nexus+s&quot;&gt;Nexus S&lt;/a&gt;. ;-)&lt;/p&gt;</description><pubDate>Sat, 27 Nov 2010 04:28:44 GMT</pubDate><link>http://python.ca/nas/log/201011/index.html#26_001</link><guid isPermaLink="false">tag:python.ca,2010-11-27:/nas/log/26_001</guid></item>
<item><title>Using Git to checkout the Python source code</title><description>&lt;p&gt;The Python developers have decided to move from Subversion to Mercurial. However, that's taking some time to implement.  For those who want a DVCS now, there are Git repositories on svn.python.org that allow efficient use of Git.  I wrote a &lt;a href=&quot;http://wiki.python.org/moin/Git&quot;&gt;set of instructions&lt;/a&gt; on the Python wiki. The initial setup is a little complicated but day to day use is convenient, IMHO.&lt;/p&gt;
&lt;p&gt;Why would you want to use Git?  I can only speak for myself, but I was an early adopter of Subversion.  I lead the push while at the &lt;a href=&quot;http://www.mems-exchange.org/&quot;&gt;MEMS  Exchange&lt;/a&gt; to switch from CVS to Subversion (version 0.17.0 in 2002, I believe) . At the time, CVS's extremely poor support for moving and renaming files was hampering our ability to refactor our source code.  Subversion was a definite improvement and is still a decent choice for an internally developed project.  It's model of &lt;code&gt;svn up&lt;/code&gt; doing a rebase of local changes is intuitive for most users.&lt;/p&gt;
&lt;p&gt;Subversion still has a number of deficiencies for serious developers.  For one, the handling of multiple branches of development is awkward enough that many users avoid branches (I understand SVN is getting better in this regard).  Less notable but just as importantly, IMHO, it lacks many tools for dealing with changes as patches.  Often I would dump a change using &lt;code&gt;svn diff&lt;/code&gt;, edit the patch, and the apply the new patch to a different branch.  Since moving to Git, I rarely have to resort to manual patch editing (instead using tools like git rebase, git format-patch, git add -i,  git cherry-pick, etc).&lt;/p&gt;
&lt;p&gt;As a tip to someone dipping their toe in the Git waters, it is critical to understand the difference between merging changes and rebasing changes.  Git sort of defaults to merging but in the vast majority of cases you want to rebase instead.  As an example, for one of my projects I've probably done hundreds of rebase operations and only about three merges (those three are because we have a long lived branch for a variant of the software that can't be done using configuration files).  When I speak of &quot;merge&quot; I don't mean what Git calls a &quot;fast-forward merge&quot; since that's not really a merge a all.  Instead, the destination branch is a strict subset of the source branch and changes are just being appending to the head version.  Subversion defaults to doing rebasing rather than merging.  When you run &lt;code&gt;svn up&lt;/code&gt; your local changes are being rebased on the HEAD revision from the repository.&lt;/p&gt;
&lt;p&gt;Git definitely has a learning curve. When I first started using it I was often confused. However, after about a week I realized it was much better than any other VCS that I had experienced.  I now consider a DVCS with similar capabilities an essential developer's tool, just like a good text editor.&lt;/p&gt;</description><pubDate>Tue, 23 Feb 2010 19:06:13 GMT</pubDate><link>http://python.ca/nas/log/201002/index.html#23_001</link><guid isPermaLink="false">tag:python.ca,2010-02-23:/nas/log/23_001</guid></item>
<item><title>Quixote 2.7b2 beta released</title><description>&lt;p&gt;I released another &lt;a href=&quot;http://quixote.ca/&quot;&gt;Quixote&lt;/a&gt; beta about a week ago. I think it finally fixes the problem cased by Python 2.6's breakage of the ihooks module. What happened was that the when relative imports were implemented, the ihooks module got forgotten. If you use the 2.6 ihooks module and any package uses a relative import, you lose.&lt;/p&gt;
&lt;p&gt;I've fixed the ihooks module in the SVN trunk and it will be fixed in Python 2.7. Quixote 2.7b2 works around the problem by shipping with it's own ihooks module.&lt;/p&gt;</description><pubDate>Mon, 01 Feb 2010 02:14:17 GMT</pubDate><link>http://python.ca/nas/log/201001/index.html#31_010</link><guid isPermaLink="false">tag:python.ca,2010-02-01:/nas/log/31_010</guid></item>
<item><title>H1N1 flu takes off</title><description>&lt;p&gt;Take a look at the &lt;a href=&quot;http://www.google.org/flutrends/intl/en_us/ca/&quot;&gt;Google Flu trend graph&lt;/a&gt;. The Canada Health &lt;a href=&quot;http://www.phac-aspc.gc.ca/fluwatch/09-10/w41_09/index-eng.php&quot;&gt;FluWatch report&lt;/a&gt; has a similar graph. Saskatchewan is starting to roll out the vaccine but I suspect it will be too late to help most people.&lt;/p&gt;
&lt;p&gt;BTW, can the media please stop calling it &quot;swine flu&quot;? The &lt;a href=&quot;http://www.cdc.gov/h1n1flu/qa.htm&quot;&gt;CDC says&lt;/a&gt; &quot;further study has shown that this new virus is very different from what normally circulates in North American pigs. It has two genes from flu viruses that normally circulate in pigs in Europe and Asia and bird (avian) genes and human genes.&quot;&lt;/p&gt;
&lt;p&gt;Also interesting is that the best guess is that it's contagious one day before symptoms are shown. Based on that, I think it would be prudent for the government to shutdown schools and universities for a week or two. That would be a small cost in exchange to helping to avoid overloading the health care system.&lt;/p&gt;
&lt;p&gt;No need to panic but given that fact that this virus attacks lung tissue, some caution would be prudent. Please consider getting vaccinated.&lt;/p&gt;</description><pubDate>Wed, 28 Oct 2009 21:05:56 GMT</pubDate><link>http://python.ca/nas/log/200910/index.html#28_001</link><guid isPermaLink="false">tag:python.ca,2009-10-28:/nas/log/28_001</guid></item>
<item><title>Low cost parametric CAD software</title><description>&lt;p&gt;SolidWorks is cool but the price tag is sometimes difficult to justify. &lt;a href=&quot;http://www.alibre.com/&quot;&gt;Alibre Design&lt;/a&gt; looks like a great deal at $99. Based on this &lt;a href=&quot;http://www.youtube.com/watch?v=KF3V0lwy99Q&quot;&gt;YouTube video&lt;/a&gt;, I'm impressed by the focus of the company. I think it is important to decide what your software will focus on doing well, rather than trying to make it all things to all people.&lt;/p&gt;&lt;p&gt;Update: After a little research, I decided the deal was too good to pass up. Alibre Design really does cover most of the commonly used functionality of SolidWorks or AutoDesk Inventor. I suspect they are having the promotion because the next major version of the software is due to be released soon. Serious users will pay full price for the new version so it's a clever promotional strategy.&lt;/p&gt;</description><pubDate>Tue, 01 Sep 2009 19:30:13 GMT</pubDate><link>http://python.ca/nas/log/200909/index.html#01_001</link><guid isPermaLink="false">tag:python.ca,2009-09-01:/nas/log/01_001</guid></item>

    </channel>
    </rss>

