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

<channel>
	<title>readme.blog &#187; Microsoft</title>
	<atom:link href="http://weblog.bbzzdd.com/category/technology/microsoft/feed/" rel="self" type="application/rss+xml" />
	<link>http://weblog.bbzzdd.com</link>
	<description></description>
	<lastBuildDate>Wed, 17 Nov 2010 19:47:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Chris vs. Synergy</title>
		<link>http://weblog.bbzzdd.com/2010/11/14/chris-vs-synergy/</link>
		<comments>http://weblog.bbzzdd.com/2010/11/14/chris-vs-synergy/#comments</comments>
		<pubDate>Sun, 14 Nov 2010 22:38:24 +0000</pubDate>
		<dc:creator>Chris</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Technology]]></category>
<category>htpc</category><category>os x</category><category>synergy</category><category>windows 7</category>
		<guid isPermaLink="false">http://weblog.bbzzdd.com/?p=115</guid>
		<description><![CDATA[My HTPC setup was less than ideal, seeing how it was basically a mini tower stuffed in a desk by the TV, so I decided to move the system into my wall unit proper. To do this, the first thing I needed a smaller case for the PC. After a lot of research, I decided [...]]]></description>
			<content:encoded><![CDATA[<p>My HTPC setup was less than ideal, seeing how it was basically a mini tower stuffed in a desk by the TV,  so I decided to move the system into my wall unit proper.  To do this, the first thing I needed a smaller case for the PC.   After a lot of research, I decided on the <a href="http://www.antec.com/Believe_it/product1.php?id=NzE4">Antec Fusion Black</a>.</p>
<p>It&#8217;s a really nice case.   It runs quiet and cool and it looks like an everyday receiver, not a PC, which is exactly what I wanted.  One thing though, the front LCD display is horrendous.  I recommend just leaving it turned off.  It&#8217;s very washed out, has slow refresh rate, and IMO there&#8217;s no need to look that the front to the PC to see the name of the movie you&#8217;re playing.</p>
<p>My mouse and keyboard are a <a href="http://www.logitech.com/en-us/428/163?section=downloads">Logitech G7</a> and an <a href="http://www.apple.com/keyboard/">Apple Wireless Keyboard</a>.  I installed the USB dongles for RF and Bluetooth inside the case thanks to a couple of <a href="http://www.newegg.com/Product/Product.aspx?Item=N82E16812200294&#038;cm_re=usb_header-_-12-200-294-_-Product">USB 4-pin to female adapters</a>. </p>
<p>After setting up the keyboard and mouse on the coffee table, I realized why I rarely use the HTPC &#8212; it&#8217;s just so counter intuitive to a have a KB/M out all the time,  especially when my MacBook Pro is always out anyway.  Waitaminute!</p>
<p>Enter <a href="http://synergy-foss.org/">Synergy</a>.  What is Synergy?  It&#8217;s is a really neat application that allows you to share a keyboard and mouse across multiple devices.  It&#8217;s sort of the same concept of a KV/M but turned upside-down, not to mention not as clumsy or expensive, not to mention to toggle switch!   With Synergy you install the software, do a simple *cough*BS*cough* config, and you&#8217;re sharing your keyboard and mouse between systems.</p>
<p>Ok, setup was not so easy.  On client side, the PC, I&#8217;m running Windows 7 Ultimate x64.  I installed the <a href="http://synergy-foss.org/pm/projects/synergy/tabs/download">latest stable release of Synergy</a> thinking that was my best bet, but I was wrong.  The problem is Synergy needs to run as administrator or when an <a href="http://en.wikipedia.org/wiki/User_Account_Control">UAC</a> prompt pops out you lose control of the keyboard and mouse.  </p>
<p>The solution was to install the latest beta (I grabbed 1.4.1) for Windows and have it run as a service.  This way Synergy has the privileges to interact with UAC prompts and you don&#8217;t need to keep a keyboard under the couch for UAC prompts alone.</p>
<p>The server side, the Mac, was a lot harder to configure.  The server runs as a daemon, meaning there&#8217;s no UI, so config is an under-the-hood experience.  There is a product called <a href="http://sourceforge.net/projects/synergykm/">SynergyKM</a> which has a UI configuration, but based on my evaluation it would not fit my needs.  Time to roll up my sleeves.</p>
<p>I used <a href="http://www.macports.org/">MacPorts</a> to install the Synergy binaries:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">chris<span style="color: #000000; font-weight: bold;">@</span>macbookpro:~$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> port <span style="color: #c20cb9; font-weight: bold;">install</span> synergy</pre></div></div>

<p>If you don&#8217;t have MacPorts you can install Synergy by <a href="http://synergy-foss.org/pm/projects/synergy/tabs/download">by downloading</a> it from the web site.   The current MacPorts version is a few point releases behind, but that&#8217;s not a problem for me.</p>
<p>My config is fairly straight-forward with a couple of exceptions.  I treat the PC as being to the right of the MacBook.  That means when I move my mouse to the right of the screen it appears on the PC.   I wanted control-click to act like a right mouse button click as it does on the Mac and Command to act as Control on the PC.  That way I don&#8217;t have to Command-C to copy on the Mac and Control-V to paste on the PC, I can just use Command for everything.  Finally, I wanted Option-Command-Plus and  Option-Command-Minus to zoom the screen via Windows Magnifier (it&#8217;s hard to see tiny text from six feet away).</p>
<p>Here&#8217;s my config file, which I store in ~/.synergy/synergy.conf</p>

<div class="wp_syntax"><div class="code"><pre class="apache" style="font-family:monospace;"> section: screens
    macbookpro:
    monster:
        super = alt
        alt = ctrl
        meta = super
 end
 section: aliases
    macbookpro: 
        macbookpro.local
 end
 section: links
    macbookpro:
        right = monster
    monster:
        left = macbookpro.local
 end
 section: <span style="color: #00007f;">options</span>
    mousebutton(control+<span style="color: #ff0000;">1</span>) = mousebutton(<span style="color: #ff0000;">3</span>)
    keystroke(super+alt+Plus) = keystroke(meta+Plus)
    keystroke(super+alt+Minus) = keystroke(meta+Minus)
 end</pre></div></div>

<p>Section by section. &#8220;screens&#8221; defines the system.  &#8220;monster&#8221; is my PC and obviously &#8220;macbookpro&#8221; is the Mac.    </p>
<p>The block&#8230;</p>

<div class="wp_syntax"><div class="code"><pre class="apache" style="font-family:monospace;">    super = alt
    alt = ctrl
    meta = super</pre></div></div>

<p>&#8230;is where I map the keys for Command and Option.  The names are misleading in Synergy.  On the Mac side, &#8220;super&#8221; is the Option key, &#8220;alt&#8221; is the Command key and &#8220;ctrl&#8221; is control.  There is no &#8220;meta&#8221; key.  Why that&#8217;s in the config will be explained later.</p>
<p>&#8220;aliases&#8221; simply maps the OS X name for the host to a more friendly format:</p>

<div class="wp_syntax"><div class="code"><pre class="apache" style="font-family:monospace;">     section: aliases
        macbookpro: 
            macbookpro.local
     end</pre></div></div>

<p>&#8220;links&#8221; is a straight-forward section:</p>

<div class="wp_syntax"><div class="code"><pre class="apache" style="font-family:monospace;">    macbookpro:
        right = monster
    monster:
        left = macbookpro</pre></div></div>

<p>Here the Mac is treated as the left screen, PC is on the right.</p>
<p>Finally, &#8220;options&#8221;:</p>

<div class="wp_syntax"><div class="code"><pre class="apache" style="font-family:monospace;">     section: <span style="color: #00007f;">options</span>
        mousebutton(control+<span style="color: #ff0000;">1</span>) = mousebutton(<span style="color: #ff0000;">3</span>)
        keystroke(super+alt+Plus) = keystroke(meta+Plus)
        keystroke(super+alt+Minus) = keystroke(meta+Minus)
     end</pre></div></div>

<p>The first directive maps Control + Click to the right mouse button on the PC.   The next two define Option + Command + (Plus | Minus) to the zoom commands on Windows 7 (Windows Key + [Plus | Minus]).  If you remember from before &#8220;meta&#8221; on the Mac maps to &#8220;Super&#8221; on the PC, which is the Windows key, so we define a faux mapping for &#8220;meta&#8221; to do this.  Yes, it <em>is</em> as confusing as it reads.</p>
<p>Now if you run the synergy server from the terminal,  you can test it out:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">chris<span style="color: #000000; font-weight: bold;">@</span>macbookpro:~$ synergys <span style="color: #660033;">-f</span> <span style="color: #660033;">--config</span> ~<span style="color: #000000; font-weight: bold;">/</span>.synergy<span style="color: #000000; font-weight: bold;">/</span>synergy.conf</pre></div></div>

<p>If that command does not bomb out you&#8217;re in good shape, so far.</p>
<p>Now to get Synergy to run when you log in is a challenge.  This is accomplished through <a href="http://developer.apple.com/macosx/launchd.html">launchd</a>.  </p>
<p>I created the following file as ~/Library/LaunchAgents/net.sourceforge.synergy2.plist:</p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;?xml</span> <span style="color: #000066;">version</span>=<span style="color: #ff0000;">&quot;1.0&quot;</span> <span style="color: #000066;">encoding</span>=<span style="color: #ff0000;">&quot;UTF-8&quot;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></span>
<span style="color: #00bbdd;">&lt;!DOCTYPE plist PUBLIC &quot;-//Apple Computer//DTD PLIST 1.0//EN&quot; </span>
<span style="color: #00bbdd;">&quot;http://www.apple.com/DTDs/PropertyList-1.0.dtd&quot;&gt;</span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;plist</span> <span style="color: #000066;">version</span>=<span style="color: #ff0000;">&quot;1.0&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;dict<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;key<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>Label<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/key<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;string<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>net.sourceforge.synergy2<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/string<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;key<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>ProgramArguments<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/key<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;array<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
            <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;string<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>/Users/chris/bin/synergy.sh<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/string<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/array<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;key<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>RunAtLoad<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/key<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;true</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/dict<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/plist<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>This will launch a shell script in my local bin directory at login.  For me the script is ~/bin/synergy.sh.  The contents are:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#! /bin/sh</span>
&nbsp;
<span style="color: #007800;">SYNERGYS</span>=<span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>synergys
<span style="color: #007800;">CONFIG</span>=<span style="color: #000000; font-weight: bold;">/</span>Users<span style="color: #000000; font-weight: bold;">/</span>chris<span style="color: #000000; font-weight: bold;">/</span>.synergy<span style="color: #000000; font-weight: bold;">/</span>synergy.conf
&nbsp;
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #000000; font-weight: bold;">!</span> <span style="color: #c20cb9; font-weight: bold;">ps</span> axco <span style="color: #7a0874; font-weight: bold;">command</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-q</span> <span style="color: #ff0000;">&quot;^synergys<span style="color: #000099; font-weight: bold;">\$</span>&quot;</span>
<span style="color: #000000; font-weight: bold;">then</span>    
    <span style="color: #007800;">$SYNERGYS</span> <span style="color: #660033;">--daemon</span> <span style="color: #660033;">--config</span> <span style="color: #007800;">$CONFIG</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #007800;">$?</span> <span style="color: #660033;">-ne</span> <span style="color: #000000;">0</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>
    <span style="color: #000000; font-weight: bold;">then</span>
        <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;synergys failed to load.&quot;</span>
    <span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">else</span>
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;synergys already loaded.&quot;</span>
<span style="color: #000000; font-weight: bold;">fi</span></pre></div></div>

<p>This script looks to see if the Synergy server is running, if not it will launch it.  Pretty simple.</p>
<p>That&#8217;s about it.   If anything fails be sure to check Console (Command-Space and type &#8220;Console&#8221;).</p>
<p>One very cool thing is the multi-touch commands are at a very low level of the  OS, so two-finger scroll etc. will all work on the Windows side just as it does on the Mac.</p>
<a href="http://weblog.bbzzdd.com/tag/htpc" rel="tag">htpc</a>, <a href="http://weblog.bbzzdd.com/tag/os-x" rel="tag">os x</a>, <a href="http://weblog.bbzzdd.com/tag/synergy" rel="tag">synergy</a>, <a href="http://weblog.bbzzdd.com/tag/windows-7" rel="tag">windows 7</a>]]></content:encoded>
			<wfw:commentRss>http://weblog.bbzzdd.com/2010/11/14/chris-vs-synergy/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>External Disk for Windows, OS X, and  Linux</title>
		<link>http://weblog.bbzzdd.com/2005/07/27/external-disk-for-windows-os-x-and-linux/</link>
		<comments>http://weblog.bbzzdd.com/2005/07/27/external-disk-for-windows-os-x-and-linux/#comments</comments>
		<pubDate>Wed, 27 Jul 2005 13:09:41 +0000</pubDate>
		<dc:creator>Chris</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Technology]]></category>

		<guid isPermaLink="false">http://www.bbzzdd.com/wordpress/?p=7</guid>
		<description><![CDATA[I wanted to use my external Firewire drive on all my systems. I found that formatting the whole thing for FAT32 was not the answer. The best solution I came across was to make two partitions, one FAT32 and the other HFS+. Windows can read FAT32, OSX and Linux can read both. Super. The best [...]]]></description>
			<content:encoded><![CDATA[<p>I wanted to use my external Firewire drive on all my systems.  I found that formatting the whole thing for FAT32 was not the answer.  The best solution I came across was to make two partitions, one FAT32 and the other HFS+.  Windows can read FAT32, OSX and Linux can read both.  Super.</p>
<p>The best way to do it is under OS X (10.4.2 in my case) using <code>diskutil</code>.  My drive is 160GB, so I did a 100GB FAT32 partition and a ~60GB HFS+ partition.  It&#8217;s as easy as:</p>
<p><code>diskutil partitionDisk disk2 2 MBRFormat MS-DOS FAT_VOL 100G HFS+ MAC_VOL 60G</code></p>
<p>Diskutil will figure out the change on the 60GB partition if you go over the free amount (it came to something like 55G).</p>
<p>You need the <code>MBRFormat</code> parameter if you want Windows to be able to read the FAT32 partition.  If in doubt check the <a href="http://www.hmug.org/man/8/diskutil.php">man page</a>.</p>
<p>Using either disk under Linux 2.6.x is as easy as:</p>
<p><code>mount -t vfat /dev/sda1 /mnt/exthd1/<br />
mount -t hfsplus /dev/sda2 /mnt/exthd2/</code></p>
<p>You need the vfat and hfsplus modules compiled for this to work of course.  Check my <a href="http://weblog.bbzzdd.com/archives/2005/07/impossible.html">Linux 1394 guide</a> for getting the disk to work under Linux.</p>
No Tags]]></content:encoded>
			<wfw:commentRss>http://weblog.bbzzdd.com/2005/07/27/external-disk-for-windows-os-x-and-linux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

