<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/2.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>jason parekh</title>
	<link>http://www.jasonparekh.com</link>
	<description>my life, my thoughts, my gadgets</description>
	<pubDate>Thu, 16 Nov 2006 05:25:59 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.2</generator>
	<language>en</language>
			<item>
		<title>Firefox and virtual desktops</title>
		<link>http://www.jasonparekh.com/2006/virtual-desktops-and-firefox/</link>
		<comments>http://www.jasonparekh.com/2006/virtual-desktops-and-firefox/#comments</comments>
		<pubDate>Thu, 16 Nov 2006 05:22:08 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/2006/virtual-desktops-and-firefox/</guid>
		<description><![CDATA[One thing I like about Konqueror is its ability to recognize virtual desktops (load a link in the current desktop&#8217;s Konqueror if it exists, otherwise open a new window on the current desktop).  Unfortunately, Firefox doesn&#8217;t have this ability natively, so I&#8217;ve created a wrapper.
Scenario:
kontact (mail app) on Desktop 1.  Surfing for a [...]]]></description>
			<content:encoded><![CDATA[<p>One thing I like about Konqueror is its ability to recognize virtual desktops (load a link in the current desktop&#8217;s Konqueror if it exists, otherwise open a new window on the current desktop).  Unfortunately, Firefox doesn&#8217;t have this ability natively, so I&#8217;ve created a wrapper.</p>
<p>Scenario:<br />
kontact (mail app) on Desktop 1.  Surfing for a new car on Desktop 3 .  New mail comes in, switch to D1, it has a link, I click.  Natively, firefox opens the link in my D3 window, ruining my task-oriented desktops (and making me switch to D3 just to see the opened link). What I would have liked is a new window of firefox to be opened in D1, at which point I can decide to move it to another desktop (extremely quickly with my bound keyboard shortcuts), or if it&#8217;s a quick task, do it on D1 and be done with it.</p>
<p>This depends on <code>wmctrl</code> (debian/ubuntu: <code>sudo apt-get install wmctrl</code>).</p>
<p>Put this file somewhere (I chose <em>/usr/local/bin/firefox-wrapper.sh</em>) and tell your WM to have it as the default web browser (for KDE: <code>kcmshell defaultapplication</code>).</p>
<p><a id="p21" href="http://www.jasonparekh.com/wp-content/uploads/2006/11/firefox-wrapper.sh">firefox-wrapper.sh</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/virtual-desktops-and-firefox/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Put that SPDIF out to use! (as an HDD or network indicator)</title>
		<link>http://www.jasonparekh.com/2006/put-that-spdif-out-to-use-as-an-hdd-or-network-indicator/</link>
		<comments>http://www.jasonparekh.com/2006/put-that-spdif-out-to-use-as-an-hdd-or-network-indicator/#comments</comments>
		<pubDate>Mon, 13 Nov 2006 08:02:12 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/2006/put-that-spdif-out-to-use-as-an-hdd-or-network-indicator/</guid>
		<description><![CDATA[Apple decided we don&#8217;t need an LED indicator for disk activity.  I decided we do.  Using the SPDIF out, we now have one!
I put together a quick little script that&#8217;ll poll the proc filesystem and toggle the SPDIF out accordingly.
Check it out:  MacBook LED
]]></description>
			<content:encoded><![CDATA[<p>Apple decided we don&#8217;t need an LED indicator for disk activity.  I decided we do.  Using the SPDIF out, we now have one!</p>
<p>I put together a quick little script that&#8217;ll poll the <code>proc</code> filesystem and toggle the SPDIF out accordingly.</p>
<p>Check it out:  <a href="linux-on-macbook/#macbook-led">MacBook LED</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/put-that-spdif-out-to-use-as-an-hdd-or-network-indicator/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Both headphone sensing and microphone fixed for Linux on MacBook!</title>
		<link>http://www.jasonparekh.com/2006/both-headphone-sensing-and-microphone-fixed-for-linux-on-macbook/</link>
		<comments>http://www.jasonparekh.com/2006/both-headphone-sensing-and-microphone-fixed-for-linux-on-macbook/#comments</comments>
		<pubDate>Mon, 13 Nov 2006 06:01:30 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/2006/both-headphone-sensing-and-microphone-fixed-for-linux-on-macbook/</guid>
		<description><![CDATA[The current (2006/11/12) state of ALSA for the MacBook (and MBP, ..?) is pretty strange:  If you&#8217;re using a vanilla kernel, chances are your headphone sensing works (when you plug in headphones, your internal laptop speakers mute and you hear audio from your headphones).  If you&#8217;re using a mactel-patched kernel (or the generic [...]]]></description>
			<content:encoded><![CDATA[<p>The current (2006/11/12) state of ALSA for the MacBook (and MBP, ..?) is pretty strange:  If you&#8217;re using a vanilla kernel, chances are your headphone sensing works (when you plug in headphones, your internal laptop speakers mute and you hear audio from your headphones).  If you&#8217;re using a mactel-patched kernel (or the generic Ubuntu kernel, maybe other distros that prepatch with mactel), chances are your microphone has the ability to work (you have to toggle between Line-in and Mic on the ALSA mixer for it to work), but your headphone sensing doesn&#8217;t (when you plug in headphones, you hear audio from both the internal speakers and the headphones).</p>
<p>After screwing around with the ALSA driver source code, the Windows driver files, and the Microsoft and Intel spec sheets, I&#8217;ve found a solution that allows for both the microphone and the headphone sensing to work!  <a href="linux-on-macbook/#microphone">Read more in the Linux on MacBook section</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/both-headphone-sensing-and-microphone-fixed-for-linux-on-macbook/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Hamachi nicknames to hostnames</title>
		<link>http://www.jasonparekh.com/2006/hamachi-nicknames-to-hostnames/</link>
		<comments>http://www.jasonparekh.com/2006/hamachi-nicknames-to-hostnames/#comments</comments>
		<pubDate>Thu, 09 Nov 2006 21:10:38 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/2006/hamachi-nicknames-to-hostnames/</guid>
		<description><![CDATA[If you have a set of machines (or friends) and you&#8217;re not using Hamachi, you should!  Creating a VPN is as simple as joining a room (think IRC, except you&#8217;re VPNed with all though in the room).  Pretty amazing.
They support many platforms (at least Windows, Linux, and OS X), but one problem I&#8217;ve [...]]]></description>
			<content:encoded><![CDATA[<p>If you have a set of machines (or friends) and you&#8217;re not using <a href="http://www.hamachi.cc" target="_blank">Hamachi</a>, you should!  Creating a VPN is as simple as joining a room (think IRC, except you&#8217;re VPNed with all though in the room).  Pretty amazing.</p>
<p>They support many platforms (at least Windows, Linux, and OS X), but one problem I&#8217;ve found on the *NIX is there isn&#8217;t a way to translate from the nicknames of those in your room to IP addresses without having to refer to the list.  I&#8217;ve created a bash script to parse the list of Hamachi users in your rooms and place them into your hosts file (<em>/etc/hosts</em> typically).</p>
<p>The general naming convention I use for my Hamachi nicknames are [computer owner&#8217;s name]@[computer name], or sometimes even just the [computer name].  An example of the former nickname style would be <code>jason@mooBook</code> (where <code>mooBook</code> is my laptop&#8217;s name), and the latter <code>mooMedia</code> (where <code>mooMedia</code> is my media server&#8211;like the moo theme?).  So, my script will take the [computer name], tack on the room name, and map that newly created hostname to the VPN IP of the machine.  Suppose both of these machines are in the room <code>mooNet</code>.  I can now ping <code>moomedia.moonet</code> (case insensitive) or <code>moobook.moonet</code>.  I&#8217;ve tacked on the room name to prevent adversarial behavior (although if you&#8217;re in the room <code>com</code> or <code>net</code> or any other TLD, you&#8217;re screwed ;).</p>
<p>You only need to run <code>hamachi2hosts.sh</code> once initially and when more users join your rooms.  It creates a section in your <em>/etc/hosts</em> for the automagically mapped Hamachi hosts.  Please be sure to change the settings near the top of the file.  Also, it assumes you&#8217;re logged in when you run it.</p>
<p>Here you go:  <a id="p16" href="http://www.jasonparekh.com/wp-content/uploads/2006/11/hamachi2hosts.sh">hamachi2hosts.sh</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/hamachi-nicknames-to-hostnames/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Wii!!</title>
		<link>http://www.jasonparekh.com/2006/wii/</link>
		<comments>http://www.jasonparekh.com/2006/wii/#comments</comments>
		<pubDate>Thu, 09 Nov 2006 01:53:02 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[gaming]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/2006/wii/</guid>
		<description><![CDATA[I had a pretty amazing surprise waiting for me during my NY visit this past weekend&#8211;the public debut of the Nintendo Wii!  We had to wait in line for about an hour and a half for 5 minutes with the Wii, but it was definitely worth it.  There are plenty of reviews online, [...]]]></description>
			<content:encoded><![CDATA[<p>I had a pretty amazing surprise waiting for me during my NY visit this past weekend&#8211;the public debut of the Nintendo Wii!  We had to wait in line for about an hour and a half for 5 minutes with the Wii, but it was definitely worth it.  There are plenty of reviews online, but I&#8217;ll add to that saying I&#8217;m REALLY looking forward to the release.  I&#8217;m glad Nintendo keeps up innovation (at an amazingly low price tag) while the other companies grow in realism and graphics.</p>
<p>We waited in line for Wii Sports (the packaged game with 7 different sports), and it was pretty darn cool.  I played tennis and baseball, both which were fun at first, but could lose their appeal after constant playing.  <strong>BUT</strong>, the concept is amazing, and from what I could tell, the hardware definitely has capability to capture precise movements (Wii Sports was overly simplified, I couldn&#8217;t throw a ball even if I tried.  I still got my ass handed to me in tennis, heh).  The controller felt pretty natural, and the graphics weren&#8217;t that bad from what I could tell (and taking the price into account).</p>
<p>I hardly ever think about buying brand new consoles, but the Wii is REALLY tempting.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/wii/feed/</wfw:commentRss>
		</item>
		<item>
		<title>VMware raw partition booting</title>
		<link>http://www.jasonparekh.com/2006/vmware-raw-partition-booting/</link>
		<comments>http://www.jasonparekh.com/2006/vmware-raw-partition-booting/#comments</comments>
		<pubDate>Thu, 09 Nov 2006 01:44:09 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/2006/vmware-raw-partition-booting/</guid>
		<description><![CDATA[VMware is amazing due to one outstanding feature: the ability to run a virtual machine from a raw partition.  I mention this in Linux on MacBook page, but I highly recommend this for everyone running Linux.
What this lets you do is have a single XP installation, that is able to be booted natively (for [...]]]></description>
			<content:encoded><![CDATA[<p>VMware is amazing due to one outstanding feature: the ability to run a virtual machine from a raw partition.  I mention this in <a href="/linux-on-macbook/#vmware">Linux on MacBook page</a>, but I highly recommend this for everyone running Linux.</p>
<p>What this lets you do is have a <strong>single</strong> XP installation, that is able to be booted natively (for games, etc.) and in the virtual machine (from Linux for random things, mostly turns out to be opening Office files that don&#8217;t load cleanly in OO).</p>
<p>I&#8217;ve updated the <a href="/linux-on-macbook/#vmware">Linux on MacBook&#8217;s VMware section</a> with detailed instructions on how to achieve this.  On the MacBook, I had issues with XP BSODing on boot, so I&#8217;ve noted how to fix this.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/vmware-raw-partition-booting/feed/</wfw:commentRss>
		</item>
		<item>
		<title>New section for Linux on MacBook</title>
		<link>http://www.jasonparekh.com/2006/new-section-for-macbook-on-linux/</link>
		<comments>http://www.jasonparekh.com/2006/new-section-for-macbook-on-linux/#comments</comments>
		<pubDate>Sun, 22 Oct 2006 04:35:23 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/?p=12</guid>
		<description><![CDATA[It seems like there is still a lot to be done with getting the MacBook to run nicely on Linux.  I&#8217;ll try to document all of these on this site, and having separate blog posts doesn&#8217;t seem too ideal for a newcomer wanting to get all the info at once.  I&#8217;ve created the [...]]]></description>
			<content:encoded><![CDATA[<p>It seems like there is still a lot to be done with getting the MacBook to run nicely on Linux.  I&#8217;ll try to document all of these on this site, and having separate blog posts doesn&#8217;t seem too ideal for a newcomer wanting to get all the info at once.  I&#8217;ve created the <a href="/linux-on-macbook">Linux on MacBook</a> page.  Most of the information there applies across Linux distros, but once in a while there may be something Ubuntu specific.  And once in a once in a while there may be something Kubuntu specific.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/new-section-for-macbook-on-linux/feed/</wfw:commentRss>
		</item>
		<item>
		<title>MacBook fan control in Linux</title>
		<link>http://www.jasonparekh.com/2006/macbook-fan-control-in-linux/</link>
		<comments>http://www.jasonparekh.com/2006/macbook-fan-control-in-linux/#comments</comments>
		<pubDate>Sun, 22 Oct 2006 04:21:57 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/?p=11</guid>
		<description><![CDATA[Turns out the applesmc kernel module (patch from Mactel) supports viewing/changing the fan speeds on the MacBook.  But, when you want to modify the fan speed, you must set it to manual mode and set a fixed fan speed.  I&#8217;d rather have automatic scaling to heat but specify a minimum fan speed.  [...]]]></description>
			<content:encoded><![CDATA[<p>Turns out the <code>applesmc</code> kernel module (patch from Mactel) supports viewing/changing the fan speeds on the MacBook.  But, when you want to modify the fan speed, you must set it to manual mode and set a fixed fan speed.  I&#8217;d rather have automatic scaling to heat but specify a minimum fan speed.  This was luckily an easy change in the <code>applesmc</code> module (just make the <code>/sys</code> device read/write and allow storing a value to the address).  Patch:  <a id="p10" href="http://www.jasonparekh.com/wp-content/uploads/2006/10/applesmc-change_minimum_fan_speed.patch">MacBook Minimum Fan Speed Patch</a>.  Afterwards, you can set the minimum speed (in this example, to 3000, double the default minimum speed) by:</p>
<blockquote><p><code>sudo sh -c "echo 3000 > /sys/devices/platform/applesmc/fan0_minimum_speed"</code></p></blockquote>
<p>Enjoy a cooler laptop!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/macbook-fan-control-in-linux/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Opening files from a shell with the default KDE handler</title>
		<link>http://www.jasonparekh.com/2006/opening-files-from-a-shell-with-the-default-kde-handler/</link>
		<comments>http://www.jasonparekh.com/2006/opening-files-from-a-shell-with-the-default-kde-handler/#comments</comments>
		<pubDate>Sun, 22 Oct 2006 01:06:44 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/?p=8</guid>
		<description><![CDATA[There are some things I miss from OS X, one being launching a file from a shell with the default handler.  In OS X, I used the open command.  In KDE, there is kfmclient which is a tool for communicating with Konqueror.  You can type:
kfmclient exec FILENAME
So, I&#8217;ve added an alias to [...]]]></description>
			<content:encoded><![CDATA[<p>There are some things I miss from OS X, one being launching a file from a shell with the default handler.  In OS X, I used the <code>open</code> command.  In KDE, there is kfmclient which is a tool for communicating with Konqueror.  You can type:</p>
<p><code>kfmclient exec FILENAME</code></p>
<p>So, I&#8217;ve added an alias to my <code>~/.bashrc</code>:</p>
<p><code>alias kopen='kfmclient exec'</code></p>
<p>and can conviently type:</p>
<p><code>kopen README.rtf</code></p>
<p>to open README.rtf with the bound handler.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/opening-files-from-a-shell-with-the-default-kde-handler/feed/</wfw:commentRss>
		</item>
		<item>
		<title>appletouch (Linux kernel driver for Apple trackpads) changes</title>
		<link>http://www.jasonparekh.com/2006/appletouch-linux-kernel-driver-for-apple-trackpads-changes/</link>
		<comments>http://www.jasonparekh.com/2006/appletouch-linux-kernel-driver-for-apple-trackpads-changes/#comments</comments>
		<pubDate>Mon, 16 Oct 2006 05:34:05 +0000</pubDate>
		<dc:creator>jasonparekh</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.jasonparekh.com/?p=6</guid>
		<description><![CDATA[It&#8217;s been almost two months since I first used OS X on my new MacBook, but I still miss Kubuntu (I&#8217;ll have a separate post soon on why).   I decided to switch back (well, triple boot&#8211;mostly in Kubuntu), but in doing so there have been a few roadblocks.  One of these is [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been almost two months since I first used OS X on my new MacBook, but I still miss Kubuntu (I&#8217;ll have a separate post soon on why).   I decided to switch back (well, triple boot&#8211;mostly in Kubuntu), but in doing so there have been a few roadblocks.  One of these is the trackpad (touchpad) working smoothly&#8211;both in terms of moving the mouse and also advanced features of two-finger scrolling, two/three finger taps (for right click and 3rd button click), etc.  I changed a few things in the appletouch kernel driver, and the results are pretty good!</p>
<p>The first issue I had was the mouse pointer jumping a few pixels constantly when moving around.  The trackpad consists of many sensors (20 on the X axis, 10 on the Y axis for the MacBooks), so when you glide your finger across, each sensor on your finger&#8217;s path will go high as the finger approaches/hovers (and go low once your finger leaves the sensor&#8217;s &#8216;zone&#8217;).  For the trackpad to be used for neat functions (two/three finger functionality), the synaptics X driver should be used, and in order for it to be used, the trackpad must give off absolute coordinates instead of relative (so the actual position of your finger(s) as opposed to the change in your finger(s)&#8217;s position).  There is thresholding for each of the sensors in order to discard jitter when the finger isn&#8217;t triggering a sensor.  As soon as a sensor passes the threshold, its value is used (along with the other sensors that are over the threshold) to calculate the absolute coordinates.  So, when a finger is approaching a sensor, the sensor&#8217;s contribution to the absolute coordinate calculation is 0, but when the finger gets close enough to allow the sensor to pass the threshold, the sensor&#8217;s contribution becomes at minimum the threshold value.  The default threshold level is 10, so this causes the sensor to go from giving 0 feedback on coordinates, to giving a value of 10 (not exactly) to the function to give coordinates.  So instead, I subtract the threshold from each sensor that contributes to the absolute coordinate function.  This ends up giving a smooth mouse movement when a sensor suddenly goes from below the threshold, to above.</p>
<p>The second issue was the accuracy of two finger (and three finger) detection.  These are used for two-finger scrolling, two-finger clicks, and three-finger clicks, so it&#8217;s pretty important in day-to-day use.  I found it difficult to trigger the multiple fingers properly (I couldn&#8217;t have my two fingers touching each other and I would have to make sure they maintained a good gap when scrolling), so two-finger scrolling was difficult to do.  The way it checked for multiple fingers is to count how many sensors that has passed the threshold are preceded by a sensor that is below the threshold.  So, the first finger would obviously pass, and then if there is a sensor gap between the first and second finger, the second finger would get triggered.  I didn&#8217;t like this as I don&#8217;t usually leave a gap between my two fingers (OS X didn&#8217;t have this constraint).  I changed it to check for &#8216;humps&#8217; in the sensors, so basically check for transitions from nonincreasing to increasing sequential sensor readings on each X/Y axis.  This works since the middle sensor(s) (sensors are close enough so when having two fingers down, there will be one sensor between the two) can still be over the threshold and still count as the lower part between humps.  After the patch, the two-finger scrolling works as well as OS X (from what I can tell).</p>
<p>The last small issue is being able to change the threshold value.  I turned this into a kernel module option (modinfo appletouch).</p>
<p>This patches against Mactel appletouch patch that allows MacBooks to work with that driver.  I&#8217;ve submitted it to the maintainer of the appletouch kernel driver, so we&#8217;ll hopefully see it there!</p>
<p><a id="p7" title="Patch for appletouch driver (patches on top of Mactel changes)" href="http://www.jasonparekh.com/wp-content/uploads/2006/10/appletouch-2finger_det-threshold_opt.patch">appletouch-2finger_det-threshold_opt.patch</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jasonparekh.com/2006/appletouch-linux-kernel-driver-for-apple-trackpads-changes/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
