<?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>&#62;dade</title>
	<atom:link href="http://www.creamdesign.it/blog/feed" rel="self" type="application/rss+xml" />
	<link>http://www.creamdesign.it/blog</link>
	<description>plans that either come to naught, or half a page of scribbled lines</description>
	<lastBuildDate>Sat, 30 Oct 2010 14:27:32 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>20W led from Hong Kong vs conventional lights</title>
		<link>http://www.creamdesign.it/blog/archives/307</link>
		<comments>http://www.creamdesign.it/blog/archives/307#comments</comments>
		<pubDate>Fri, 29 Oct 2010 17:48:46 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[Electronics]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=307</guid>
		<description><![CDATA[Pictures of a 20W led i found from an HK seller on eBay: impressive results! This led product could replace conventional lighting. At last led tech is mature enough to enter mass market.]]></description>
			<content:encoded><![CDATA[<p>Today I tried a power led I found on ebay, coming from an average wholesale Hong Kong seller. It&#8217;s a <strong>20 watt</strong> model, theoretically capable of putting out 1100 lumens&#8230; Unbelievable! One single 10$ led can replace conventional room lighting. See the pics.</p>
<p><span id="more-307"></span>Watching closely, it is not a single LED, but twenty single 1-W dies tied in series and parallel in a single package. The seller offers also a 50W model arranged in the same fashion</p>
<div id="attachment_304" class="wp-caption aligncenter" style="width: 235px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/10/wpid-IMAG0018.jpg"><img class="size-medium wp-image-304" title="test rig" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/10/wpid-IMAG0018-225x300.jpg" alt="20W led test rig" width="225" height="300" /></a><p class="wp-caption-text">The setup i rigged up for a quick and dirty test of the 20W led</p></div>
<p>These are the parameters of the led from the vendor; there is no official datasheet, even if the page of the seller cites the luxeon brand. The following information however is all I needed to make a quick try:</p>
<p>Lens Color: Water Clear<br />
Emitted Color : Warm White<br />
DC Forward Voltage <strong>(VF): 13.5 ~ 15.0 VDC </strong><br />
Forward Current <strong>(IF): 1400mA ~ 1800mA</strong><br />
Viewing Angle: 140 Degrees<br />
Color Temperature: 5500K<br />
Intensity Luminous (Iv): 1000LM</p>
<p>After some rough calculations I found that a 18V power supply and a couple of 1 ohm resistors (what I had lying around) was just about right to turn the led on and keeping inside spec. The heatsink (coming from an AMD processor box) keeps the led cool, and prevents it from frying up in a few seconds: this little beast puts out a lot of heat.</p>
<p>See for yourself the comparison pictures between a conventional light and the led ligt from the test setup:</p>
<div id="attachment_305" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/10/wpid-IMAG0015.jpg"><img class="size-medium wp-image-305" title="conventional lighting" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/10/wpid-IMAG0015-300x226.jpg" alt="My room lighted by my every day lighting (six fluorescent light bulbs)" width="300" height="226" /></a><p class="wp-caption-text">My room lit by my every day lighting (six fluorescent light bulbs)</p></div>
<div id="attachment_306" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/10/wpid-IMAG0017.jpg"><img class="size-medium wp-image-306" title="my room lit by the 20W led" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/10/wpid-IMAG0017-300x226.jpg" alt="my room lit by the 20W led" width="300" height="226" /></a><p class="wp-caption-text">my room lit by the 20W led</p></div>
<p>As you can see a single led can replace a whole chandelier of six light bulbs, giving comparable results and a clearer light. This is definitely going to be the lighting system of the future, because duration and consumption are far more efficient than conventional systems. I wonder what the 50W model could do.</p>
<p>A final word of recommendation: if you decide to try one of these leds, make sure you don&#8217;t watch it directly&#8230; it is like when you watch the sun with your bare eyes. Always wear sunglasses when you&#8217;re tinkering with these things.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/307/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>MassiveLyrics: get all the lyrics for your iTunes library</title>
		<link>http://www.creamdesign.it/blog/archives/280</link>
		<comments>http://www.creamdesign.it/blog/archives/280#comments</comments>
		<pubDate>Sun, 19 Sep 2010 10:35:38 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[iPod & iPhone]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=280</guid>
		<description><![CDATA[Fill the lyrics of your entire iTunes library in one click with this OSX app. No more blank lyrics on the iPod!]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/09/MassiveLyricsIcon.png"><img class="aligncenter size-full wp-image-281" title="MassiveLyricsIcon" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/09/MassiveLyricsIcon.png" alt="App Icon" width="256" height="256" /></a></p>
<p>Have you ever found yourself missing the lyrics for a song in your iPod, but you don&#8217;t want to go search and add lyrics manually to each song in your iTunes library? Then this is the app for you!</p>
<p>It can update the lyrics field in iTunes for the currently selected songs, automatically. The lyrics are fetched from the <a title="lyricwiki" href="http://lyricwiki.org/Main_Page">lyricwiki.org</a> website, which has a pretty good library of songs, even though some of them have been obscured by a copyright claim.</p>
<p>This is how to use it:</p>
<h2>Step 1: select some songs in iTunes</h2>
<div id="attachment_282" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/09/itunesSelection.png"><img class="size-medium wp-image-282" title="iTunes Selection" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/09/itunesSelection-300x195.png" alt="iTunes Selection" width="300" height="195" /></a><p class="wp-caption-text">Select some songs in iTunes. (you can use command-a to select all songs on screen)</p></div>
<h2>Step 2: open MassiveLyrics and hit the Get button</h2>
<div id="attachment_283" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/09/lyricsFetched.png"><img class="size-medium wp-image-283" title="Lyrics retrieved" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/09/lyricsFetched-300x193.png" alt="Some lyrics retrieved in the app" width="300" height="193" /></a><p class="wp-caption-text">The lyrics have been looked up</p></div>
<p>The app will start looking up songs on the internet. If the lyrics are not available it will be shown, otherwise you&#8217;ll see &#8216;lyrics found&#8217;</p>
<h2>Step 3: push Write all found lyrics to iTunes to update the songs in your library</h2>
<p>Just the songs in the &#8216;lyrics found&#8217; state will be updated in your iTunes library. Song state will be updated to lyrics written.</p>
<p>Each of the previous three steps will take some time, depending on the size of the selection you&#8217;ve made. Please be patient while it loads</p>
<h2>Step 4: enjoy!</h2>
<p>You will find the newly added lyrics in the get-info dialog of your iTunes songs, under the lyrics tab, and next time you&#8217;ll sync your music player they will be copied and available also on the go.</p>
<p style="text-align: center;"><a class="bigbut_green" href="http://www.creamdesign.it/blog/wp-content/uploads/2010/09/massivelyrics_1.1.zip">Download massivelyrics v1.1</a></p>
<p>I have tested the app for some time on my mac, and it works fine.<br />
However it is provided AS-IS and I cannot be held responsible for any damage it may make.<br />
If you download lots of lyrics with this app, please consider buying me a coffee donating a small amount through the button in the app. Thank you!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/280/feed</wfw:commentRss>
		<slash:comments>29</slash:comments>
		</item>
		<item>
		<title>Stepperino alpha version</title>
		<link>http://www.creamdesign.it/blog/archives/261</link>
		<comments>http://www.creamdesign.it/blog/archives/261#comments</comments>
		<pubDate>Fri, 20 Aug 2010 08:44:46 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[Arduino]]></category>
		<category><![CDATA[Electronics]]></category>
		<category><![CDATA[stepperino]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=261</guid>
		<description><![CDATA[Stepperino is a stepper motor controller based on arduino and cheap, commonly available components. This early version is capable of controlling an unipolar stepper motor (5, 6 or 8 wires) in full step mode and is the first step towards more sophisticated control to be achieved in firmware. ]]></description>
			<content:encoded><![CDATA[<p>Stepperino is a stepper motor controller based on arduino and cheap, commonly available components. This early version is capable of controlling an unipolar stepper motor (5, 6 or 8 wires) in half step mode and is the first step towards more sophisticated control to be achieved in firmware.</p>
<p>Here is the schematic [click to enlarge]:</p>
<p style="text-align: center;"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/08/stepperino-schem.png"><img class="size-medium wp-image-262 aligncenter" title="schematic-stepperino" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/08/stepperino-schem-300x180.png" alt="schematic-stepperino" width="300" height="180" /></a></p>
<p>The top left connector is for input from a microcontroller, which determines which coils are turned on. The rest is divided in four identical sections, each having a BC337 NPN transistor driving a TIP122 power darlington pair, which in turn is attached to the motor coil through the bottom right connector. Collectors of the power transistors are connected to a sense power resistor which allows fixed current to flow in the motor, independently of the voltage.<br />
As for now the motor I am using is underpowered: its spec says 24v but I am giving this circuit a 18v supply, so speed and torque may be affected. For now I can reach a speed of about 10 revolutions per second of the stepper.</p>
<p>Here is how it came out on a breadboard, attached to an arduino and to a stepper motor [click to enlarge]:</p>
<p><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/08/stepperino-bread.jpg"><img class="aligncenter size-medium wp-image-264" title="Stepperino on breadboard" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/08/stepperino-bread-300x199.jpg" alt="circuit mounted on breadboard" width="300" height="199" /></a></p>
<p>The little trimmer in the picture has been added for controlling a delay in the firmware, so to test different speeds of the motor. In fact the speed can be raised until the motor reaches resonance, and just a tad before that point the motor is going at full speed. This is the code:</p>
<pre name="code" class="cpp">void setup()   {
 DDRB = DDRB | B11111111;
}

int sensorPin = 0;
int sensorValue = 10;

void loop()
{
  sensorValue = analogRead(sensorPin);

  PORTB = B00000001;
  delayMicroseconds(sensorValue*10);
  PORTB = B00000011;
  delayMicroseconds(sensorValue*10);
  PORTB = B00000010;
  delayMicroseconds(sensorValue*10);
  PORTB = B00000110;
  delayMicroseconds(sensorValue*10);
  PORTB = B00000100;
  delayMicroseconds(sensorValue*10);
  PORTB = B00001100;
  delayMicroseconds(sensorValue*10);
  PORTB = B00001000;
  delayMicroseconds(sensorValue*10);
  PORTB = B00001001;
  delayMicroseconds(sensorValue*10);
}</pre>
<p>As you can see the code is very simple: it just does a full step sequence delayed by the value read from the trimmer. It is good for testing different speeds and step sequences, to see which one is best for achieving maximum speed.</p>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="560" height="340" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://www.youtube.com/v/4mYAfglFJN4?fs=1&amp;hl=en_US&amp;rel=0" /><param name="allowfullscreen" value="true" /><embed type="application/x-shockwave-flash" width="560" height="340" src="http://www.youtube.com/v/4mYAfglFJN4?fs=1&amp;hl=en_US&amp;rel=0" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<p>The next steps for beta version will be:</p>
<ul>
<li>add PWM to software</li>
<li>port software to avr-gcc and optimize timings</li>
<li>determine if BC337 are really necessary or not</li>
<li>add filtering caps for PWM</li>
<li>add diodes for coil protection</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/261/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>my wet iPhone dissection</title>
		<link>http://www.creamdesign.it/blog/archives/255</link>
		<comments>http://www.creamdesign.it/blog/archives/255#comments</comments>
		<pubDate>Sun, 11 Jul 2010 18:37:29 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[iPod & iPhone]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=255</guid>
		<description><![CDATA[The disassembly of my 2g phone that I accidentally dropped into water (toilet water to be precise)]]></description>
			<content:encoded><![CDATA[<p>My iPhone has been doing great since 2007, and no matter which kind of  &#8221;essential&#8221; features apple threw out in newer models, I was still pretty happy with my 2G&#8230; until yesterday, when it accidentally fell out of my hands and was dropped into water! And not just any kind of water but&#8230; yes it was toilet water. Fortunately nobody had used that toilet yet that day! But you imagine the double frustration of having a wet phone that isn&#8217;t just wet, but it is toilet wet.</p>
<p>Apple did not do a fair thing here: I watched in horror the screen turn progressively white, while hastily trying to power off the device. I couldn&#8217;t make use of the software switch and so I had to watch with even more horror the phone get warm and stay on until I came home from work (50 minutes).</p>
<p>Damn&#8230; <strong>there should be a hardware switch to turn it off</strong>&#8230; and <strong>iPhones should be waterproof too</strong>. I mean what is the use of having a compass inside? Make it waterproof instead. These would be killer features I think&#8230;</p>
<p>However to turn it off I picked up one of the many disassembly videos and followed the instructions carefully. The phone eventually did turn off, when I unlatched some cable inside, and this nice picture is what I ended up with.</p>
<div id="attachment_256" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/07/DSC_0253.jpg"><img class="size-medium wp-image-256 " title="iPhone dissection results" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/07/DSC_0253-300x149.jpg" alt="my iPhone dissection results" width="300" height="149" /></a><p class="wp-caption-text">my iPhone dissection results: click to see bigger</p></div>
<p>I hope I will be able to put it back&#8230; just to disassemble it was pretty hard. For now it is soaked into <a title="water + gadget = rice" href="http://lifehacker.com/269427/dry-out-your-soaked-gadgets-in-rice" target="_blank">rice</a>, so that some humidity will go out, especially  from the screen. I do not expect miracles, however it is worth a try, while waiting for the iPhone4 here in italy&#8230;  wish me luck!</p>
<p><strong>UPDATE: </strong>I tried to revive the phone&#8230; unfortunately when I reassembled the motherboard to the display it got quite hot and no image popped up on the screen. I have to go for the iPhone 4. Or the 3GS maybe. For now I stick with my ancient nokia 6110&#8230; not quite what you call a smartphone, but it&#8217;ll do for now.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/255/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting up mt-daapd/firefly</title>
		<link>http://www.creamdesign.it/blog/archives/244</link>
		<comments>http://www.creamdesign.it/blog/archives/244#comments</comments>
		<pubDate>Sun, 04 Apr 2010 15:39:15 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[NAS]]></category>
		<category><![CDATA[firefly]]></category>
		<category><![CDATA[iTunes]]></category>
		<category><![CDATA[music]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=244</guid>
		<description><![CDATA[mt-daapd, aka firefly, allows to serve a music folder directly to any iTunes running in your home network. This is great to share music across the house or to keep a music dump folder aside from your main itunes library. ]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/04/Screen-shot-2010-04-04-at-17.28.54.png"><img class="alignleft size-full wp-image-246" title="firefly" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/04/Screen-shot-2010-04-04-at-17.28.54.png" alt="" width="93" height="79" /></a><a href="http://www.fireflymediaserver.org/" target="_blank">mt-daapd, aka firefly</a>, allows to serve a music folder directly to any iTunes running in your home network. This is great to share music across the house or to keep a music dump folder aside from your main itunes library.</p>
<p><span id="more-244"></span></p>
<div style="display: block; padding: 10px; border: 2px solid #afa; background-color: #efe; margin-bottom: 1.2em;">This post belongs to a series detailing the services that can be set up on a home server. To view the full series head to the <a href="http://www.creamdesign.it/blog/archives/165" target="_self">master post</a></div>
<p>I personally use firefly to serve an enormous &#8216;music dump&#8217; folder which I keep on the NAS server, so that I am not forced to have all these songs into my iTunes library on my mac HD. This folder is for casual music i listen from time to time, and if I find some gem in it, I copy it on my main library to sync with ipods and iphone.</p>
<p>Installation in ubuntu is very simple: just</p>
<p><code>sudo apt-get install mt-daapd</code></p>
<p>and start the daemon by running</p>
<p><code>sudo /etc/init.d/mt-daapd start</code></p>
<p>If you want the program to start every time your server boots up execute the following:</p>
<p><code>sudo update-rc.d mt-daapd defaults</code></p>
<p>Now you should see in your iTunes a new shared library, like this:</p>
<div id="attachment_245" class="wp-caption aligncenter" style="width: 308px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/04/Screen-shot-2010-04-04-at-17.24.30.png"><img class="size-full wp-image-245 " title="firefly server as seen by iTunes" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/04/Screen-shot-2010-04-04-at-17.24.30.png" alt="firefly server as seen by iTunes" width="298" height="85" /></a><p class="wp-caption-text">firefly server as seen by iTunes</p></div>
<p>Now we are ready to configure a folder on the server for sharing. To do this there is the configuration file <strong>/etc/mtdaapd.conf</strong>, however it is more straightforward just to use the web interface at port 3689 on your server. The username is admin and the password is mt-daapd.</p>
<p>From the web interface you can set up the daemon and in the configuration section you can specify your music folders to be served. Just remember to make it perform a scan after you add something new. To be sure I configured some periodic scanning to go off every hour.</p>
<p>Performance of the server is very good. The library behaves as if it were local, if not even better.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/244/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting up Avahi</title>
		<link>http://www.creamdesign.it/blog/archives/217</link>
		<comments>http://www.creamdesign.it/blog/archives/217#comments</comments>
		<pubDate>Fri, 02 Apr 2010 21:14:34 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[NAS]]></category>
		<category><![CDATA[avahi]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=217</guid>
		<description><![CDATA[Avahi advertises the shares made available by netatalk to macs in your home network via bonjour, so that connecting to the file server means just clicking on its icon. This is how to set it up.]]></description>
			<content:encoded><![CDATA[<p>Avahi advertises the shares made available by netatalk to macs in your home network via bonjour, so that connecting to the file server means just clicking on its icon. This is how to set it up.</p>
<p><span id="more-217"></span></p>
<div style="display: block; padding: 10px; border: 2px solid #afa; background-color: #efe; margin-bottom: 1.2em;">This post belongs to a series detailing the services that can be set up on a home server. To view the full series head to the <a href="http://www.creamdesign.it/blog/archives/165" target="_self">master post</a></div>
<p>Avahi installation is almost hassle free; first you install the package:</p>
<p><code>sudo apt-get install avahi-daemon</code></p>
<p>Then edit your avahi configuration file located at /etc/avahi/services/afpd.service. The file should be empty, so you can</p>
<p><code>sudo gedit /etc/avahi/services/afpd.service</code></p>
<p>and then paste in the following XML</p>
<p><code><br />
<?xml version="1.0" standalone='no'?><!--*-nxml-*--><br />
<!DOCTYPE service-group SYSTEM "avahi-service.dtd"><br />
<service-group><br />
<name replace-wildcards="yes">%h</name><br />
<service><br />
<type>_afpovertcp._tcp</type></p>
<port>548</port>
</service><br />
<service><br />
<type>_device-info._tcp</type></p>
<port>0</port>
<txt-record>model=Xserve</txt-record><br />
</service><br />
</service-group><br />
</code></p>
<p>After that just restart the daemon:</p>
<p><code>sudo /etc/init.d/avahi-daemon restart</code></p>
<p>Back on your mac you should now see the service advertised in the Finder sidebar, like this:</p>
<div id="attachment_218" class="wp-caption alignleft" style="width: 192px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/04/Screen-shot-2010-04-02-at-23.06.05.png"><img class="size-full wp-image-218" title="Share advertised by avahi" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/04/Screen-shot-2010-04-02-at-23.06.05.png" alt="Finder sidebar" width="182" height="156" /></a><p class="wp-caption-text">Share advertised by avahi</p></div>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/217/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Setting up netatalk</title>
		<link>http://www.creamdesign.it/blog/archives/207</link>
		<comments>http://www.creamdesign.it/blog/archives/207#comments</comments>
		<pubDate>Mon, 29 Mar 2010 19:34:15 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[NAS]]></category>
		<category><![CDATA[afp]]></category>
		<category><![CDATA[apple]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[NETATALK]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[Ununtu]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=207</guid>
		<description><![CDATA[How to install and configure netatalk to serve files from ubuntu server to macs in your home network.]]></description>
			<content:encoded><![CDATA[<p><a href="http://netatalk.sourceforge.net/" target="_blank">Netatalk</a> is an open implementation of the afp protocol, needed to serve files to mac computers. This is how I installed it on my home server.</p>
<p><span id="more-207"></span></p>
<div style="display: block; padding: 10px; border: 2px solid #afa; background-color: #efe; margin-bottom:1.2em;">This post belongs to a series detailing the services that can be set up on a home server. To view the full series head to the <a href="http://www.creamdesign.it/blog/archives/165" target="_self">master post</a></div>
<p>Unfortunately the installation of netatalk in Karmic is a bit more complicated than an apt-get call. Due to licensing issues they could not distribute a package with SSL precompiled inside, and this security layer is mandatory if you try to connect from any mac running leopard or snow leopard.</p>
<p>Many tutorials exist (<a href="http://www.kremalicious.com/2008/06/ubuntu-as-mac-file-server-and-time-machine-volume/" target="_blank">here</a>, <a href="http://www.zaphu.com/2008/04/29/ubuntu-guide-configure-a-netatalk-file-server-based-on-apple-filing-protocol-afp/" target="_blank">here</a>) which explain how to recompile netatalk from source code, adding SSL support. But neither of these worked for me: no matter how i did configuration or compilation, my mac always failed to connect at the username/password screen, so still an authentication problem in spite of ssl.</p>
<p>So I had to remove netatalk completely (apt-get autoremove netatalk) and upgrade to a newer version, not yet distributed in the official repositories: 2.0.5.</p>
<p>This new version works out of the box: just install it, configure the folders you want to share and you are done. It also has a special option for setting up some space to work as a drive for time machine.  Thanks to <a href="http://sidikahawa.blogspot.com/2010/03/setting-up-time-machine-server-on-my.html" target="_blank">this article</a> we can find the packages to install for the new version. <strong>Just download and double click</strong> the packages <strong>in the listed order</strong>, say yes to any message recommending an older version.</p>
<p><a href="http://ftp.us.debian.org/debian/pool/main/d/db/libdb4.8_4.8.26-1_i386.deb"><strong>libdb4.8</strong></a><strong><br />
</strong><a href="http://ftp.us.debian.org/debian/pool/main/libg/libgcrypt11/libgcrypt11_1.4.5-2_i386.deb"><strong>libgcrypt11</strong></a><strong><br />
</strong><a href="http://ftp.us.debian.org/debian/pool/main/n/netatalk/netatalk_2.0.5-3_i386.deb"><strong>netatalk2.0.5</strong></a></p>
<p>now edit your <strong>/etc/netatalk/AppleVolumes.default</strong> file, appending a line for every share you want to export to your home macs, with this format <strong>for a generic share</strong>:</p>
<p><code>/full/path/on/linux/box   "name of the share"</code></p>
<p>or for <strong>time machine drive</strong>:</p>
<p><code>/full/path/on/linux/box   "TimeMachine"    options:tm</code></p>
<p>then restart the netatalk daemon:</p>
<p><code>/etc/init.d/netatalk restart</code></p>
<p>Finally you can check on your mac if everything went fine:<br />
open Finder and do &lt;command-k&gt;, enter the IP address of your server and your (ubuntu) username and password.<br />
You should now be connected and capable of browsing files, like this:</p>
<div id="attachment_208" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/03/connected_nas.png"><img class="size-medium wp-image-208" title="connected_nas" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/03/connected_nas-300x221.png" alt="connected NAS" width="300" height="221" /></a><p class="wp-caption-text">connected nas</p></div>
<p>Moreover, if you specified a time machine share, you will be able to set it up directly into time machine preferences pane without any terminal hacks on mac side. </p>
<p>The next step is to configure avahi, to advertise services on the network so that they come up in the finder sidebar (no more command-k to connect).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/207/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Enabling ssh access</title>
		<link>http://www.creamdesign.it/blog/archives/190</link>
		<comments>http://www.creamdesign.it/blog/archives/190#comments</comments>
		<pubDate>Sun, 21 Mar 2010 22:03:19 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[NAS]]></category>
		<category><![CDATA[networking]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=190</guid>
		<description><![CDATA[ssh enables remote terminal access to a linux box, and is the first step towards an headless machine. This is how to configure it for the first time in ubuntu]]></description>
			<content:encoded><![CDATA[<p><img class="size-thumbnail wp-image-191" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/03/gnome-terminal-150x150.png" alt="gnome-terminal" width="150" height="150" /><br />
ssh enables remote terminal access to a linux box, and is the first step towards an headless machine. <span id="more-190"></span></p>
<div style="display: block; padding: 10px; border: 2px solid #afa; background-color: #efe; margin-bottom:1.2em;">This post belongs to a series detailing the services that can be set up on a home server. To view the full series head to the <a href="http://www.creamdesign.it/blog/archives/165" target="_self">master post</a></div>
<p>Setting up ssh access is very easy:</p>
<p>first of all install the ssh package:</p>
<p><code>sudo apt-get install ssh</code></p>
<p>then append the following line to your /etc/hosts.allow file, telling to allow incoming connection on ssh port 22. In this case I&#8217;ve configured it to accept incoming connections from all the IPs of my local network. Edit the line to suit your IP configuration.</p>
<p><code>sshd: 192.168.0.*</code></p>
<p>That&#8217;s it! Now open a terminal (in mac/unix) and do</p>
<p>ssh &lt;username&gt;@&lt;server-IP&gt;</p>
<p>If you&#8217;re on Windows, you can use <a title="PuTTY" href="http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html" target="_blank">PuTTY</a> to connect to the server. Have fun!!!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/190/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Setting up MDADM</title>
		<link>http://www.creamdesign.it/blog/archives/173</link>
		<comments>http://www.creamdesign.it/blog/archives/173#comments</comments>
		<pubDate>Sat, 20 Feb 2010 12:22:39 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[NAS]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=173</guid>
		<description><![CDATA[MDADM (multi disk admin) is the software implementation of RAID on linux. It can be used to take a bunch of disks and make them into a single, powerful drive. This leads to several advantages, depending on the raid configuration you choose to implement.]]></description>
			<content:encoded><![CDATA[<div style="text-align: left;">
<p><a title="wikipedia MDADM" href="http://en.wikipedia.org/wiki/Mdadm" target="_blank">MDADM</a> (multi disk admin) is the software implementation of RAID on linux. It can be used to take a bunch of disks and make them into a single, powerful drive. This leads to several advantages, depending on the raid configuration you choose to implement.<br />
<span id="more-173"></span></p>
<div style="display: block; padding: 10px; border: 2px solid #afa; background-color: #efe; margin-bottom: 1.2em;">This post belongs to a series detailing the services that can be set up on a home server. To view the full series head to the <a href="http://www.creamdesign.it/blog/archives/165" target="_self">master post</a></div>
<p>For my setup I had chosen RAID5 with three disks. This means that if I loose one of them, I will not lose my data: pop in a fresh disk and go on, without even interrupting data availability.</p>
</div>
<p style="text-align: left;">MDADM does not come with ubuntu by default.</p>
<p><code> sudo apt-get mdadm<br />
</code></p>
<p style="text-align: left;">will take care of installation. Actually on my new system it took care of more: it automatically detected and assembled the array I had from a previous machine (that one had been built with MDADM as well), giving me this nice little icon on the desktop with all the content ready to go. This array is made up of three 250GB disks.</p>
<p style="text-align: center;"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/02/autodetect.png"><img class="size-full wp-image-176 aligncenter" title="Raid autodetect" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/02/autodetect.png" alt="Raid autodetect" width="151" height="92" /></a></p>
<p style="text-align: left;">However, the work needed to setup the array if you have only new disks is a bit more complicated than just popping in the disks and let linux autodetect everything for you. Here you can find the process to set up the array:</p>
<p><strong>1) Prepare the drives</strong><br />
Connect the disks and create an ext3 partition on each one. Partitions should be the same size and filesystem. You would want to span each drive with a single primary partition. Use <strong>fdisk</strong> and <strong>mkfs.ext3</strong> or <strong>gparted</strong> to do that. You should now have many partitions as your disks named for example /dev/sda1, /dev/sda2 and so on (if you are using IDE disks those will be /dev/hda1, /dev/hdb1&#8230;)</p>
<p><strong>2) Create the array</strong><br />
Merge the partitions into an array using mdadm:</p>
<p><code>mdadm --create /dev/md0 --level=5 --raid-devices=3 /dev/sda1 /dev/sdb1/dev/sdc1</code></p>
<p>This for example will create an array, accessible at /dev/md0, made up of your three partitions, using raid 5 as the level<br />
check the status of mdadm with:</p>
<p><code>cat /proc/mdstat</code></p>
<p><strong>3) Mount the array and use it</strong></p>
<p><code>sudo mkdir /media/raid<br />
sudo mount  /dev/md0 /media/raid</code></p>
<p>if the mount fails, you have to use format the new created drive md0, use again <strong>mkfs.ext3</strong>.</p>
<p><strong>4) Edit/check configuration files</strong><br />
for automatic recognition and mount in the next boot sequences edit the following files:</p>
<p><code>sudo gedit /etc/mdadm/mdadm.conf<br />
sudo gedit /etc/fstab</code></p>
<p>Now data written in /media/raid is safely stored, and an hard disk failure cannot compromise it. Being on a NAS server, this can be a solid foundation for all automatic backup needs of the home network;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/173/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>ATOM/ION nas home server</title>
		<link>http://www.creamdesign.it/blog/archives/165</link>
		<comments>http://www.creamdesign.it/blog/archives/165#comments</comments>
		<pubDate>Wed, 17 Feb 2010 22:34:18 +0000</pubDate>
		<dc:creator>dade</dc:creator>
				<category><![CDATA[NAS]]></category>
		<category><![CDATA[Tinkering]]></category>
		<category><![CDATA[Atom]]></category>
		<category><![CDATA[drives]]></category>
		<category><![CDATA[homeserver]]></category>
		<category><![CDATA[HTPC]]></category>
		<category><![CDATA[ION]]></category>
		<category><![CDATA[Nvidia]]></category>
		<category><![CDATA[sata]]></category>
		<category><![CDATA[server]]></category>

		<guid isPermaLink="false">http://www.creamdesign.it/blog/?p=165</guid>
		<description><![CDATA[Build and configure a cheap NAS/HTPC box based around the new Intel Atom processor and Nvidia ION chipset. Low power consumption, your files everywhere, torrenting, automated backups, reproduction of 1080p video, all for under 400$: how could you do without?]]></description>
			<content:encoded><![CDATA[<p>The replacement motherboard for my home server has finally arrived! This is the &#8216;master&#8217; post in which I&#8217;ll detail the configuration of the system, from software services to integration in the home network (MAC/WIN/LIN).<br />
<span id="more-165"></span><br />
This is the server in its actual form. As you can see it is quite &#8216;unpleasant&#8217; :)</p>
<div id="attachment_167" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.creamdesign.it/blog/wp-content/uploads/2010/02/dsc_0246-Modified.jpg"><img class="size-medium wp-image-167" src="http://www.creamdesign.it/blog/wp-content/uploads/2010/02/dsc_0246-Modified-300x225.jpg" alt="atom NAS server assembled (well... almost)" width="300" height="225" /></a><p class="wp-caption-text">atom NAS server assembled (well... almost)</p></div>
<h2>The Hardware</h2>
<p>The motherboard: <a title="review" href="http://www.anandtech.com/mb/showdoc.aspx?i=3630" target="_blank">asus AT3N7A-I</a>: based upon the new combination of Intel Atom processor and Nvidia ION chipset. This little thing is capable of low power consumption and reproduction of 1080p video. Given this it will double as a HTPC, which is the segment it was designed for.</p>
<p>The major limitations of the board for becoming an expandable NAS server are the small number of SATA II ports (three) and the reduced expansion capabilities (a single PCI slot). The 3 RAID hard drives in the picture are attached through a SATA expansion card, which sports four additional sata ports, while the main drive for the OS and additional space is attached to the motherboard. With this configuration I have a spare on the expansion card and two spares on the motherboard. Will do some performance tests to find the perfect combination.</p>
<p>Then the board has gigabit ethernet, bluetooth and HDMI out. Perfect for HTPC. I tested it with <a title="http://xbmc.org/" href="http://xbmc.org/" target="_blank">XMBC</a> and the overall system turns out to be ideal as a media center. With plenty of disk space attached it will provide an endless supply of video! cool!</p>
<p>A bad point of the motherboard is surely that nasty little fan that runs over the heatsink. I will have to find a way to reduce RPM, or to cut it off completely. The system must be very silent and up 24/7. It cannot be a noise machine as it currently is. I mean the fan noise is tolerable, but steady and in the long run can be annoying, at least for me. Right now &#8211; however &#8211; it is overtaken by the PSU fan, which is a cheapo one and for that very very noisy. I&#8217;ll find a way to silence that too!</p>
<h2>The software</h2>
<p>Everything will run upon the latest Ubuntu OS (regular version, not server, so to run XBMC or boxee). Right now I am using <a title="karmic" href="http://releases.ubuntu.com/karmic/" target="_blank">Karmic</a>, which installed flawlessly off an usb drive. The only minor thing has been installation of the latest Nvidia driver: the one installed by default by Ubuntu at this point was too old and did not play well (at least at 1080p): compiz was not able to run, and the overall performance was slow and buggy. The latest Nvidia driver fixed this, but it had to be <a href="http://tuxicity.wordpress.com/2008/06/04/howto-install-nvidia-manually-in-ubuntu-and-debian/" target="_blank">installed manually</a>.</p>
<p>These are the components i&#8217;ve set up so far. Each has its own dedicated post with instructions, just click on the big buttons. If you&#8217;d like, you can suggest more home server sw in the comments!</p>
<table>
<tbody>
<tr>
<td><a class="bigbut" href="http://www.creamdesign.it/blog/archives/173">mdadm</a></td>
<td>Merge some hard drives into a single, speedier, bigger and more reliable drive with software RAID</td>
</tr>
<tr>
<td><a class="bigbut" href="http://www.creamdesign.it/blog/archives/190">ssh</a></td>
<td>Enable remote access to the server via any terminal of your network</td>
</tr>
<tr>
<td><a class="bigbut" href="http://www.creamdesign.it/blog/archives/207" target="_self">netatalk</a></td>
<td>Share any folder of the server with macs in your network, set some networked storage to function as a drive for Leopard time machine</td>
</tr>
<tr>
<td><a class="bigbut" href="http://www.creamdesign.it/blog/archives/217">avahi</a></td>
<td>Advertise the folders served to macs so that they show up in finder</td>
</tr>
<tr>
<td><a class="bigbut" href="http://www.creamdesign.it/blog/archives/244">mt-daapd</a></td>
<td>Share music folders on the servers to iTunes in your local network</td>
</tr>
<tr>
<td><a class="bigbut" href="#">XBMC</a></td>
<td>Set up the best media center out there and squeeze out the power of the atom/ion platform</td>
</tr>
</tbody>
</table>
<p>The installs have been made with Karmic, so some distribution specific workarounds apply (netatalk, xbmc). If you are using a newer version these workarounds may not be applicable anymore and installing might be as simple as doing  apt-get install.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.creamdesign.it/blog/archives/165/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

