<?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>Tonava of Ideas</title>
	<atom:link href="http://entropia.kapsi.fi/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://entropia.kapsi.fi/blog</link>
	<description>The life according to Entropia</description>
	<lastBuildDate>Fri, 04 Jan 2013 08:27:15 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>I²C troubleshooting</title>
		<link>http://entropia.kapsi.fi/blog/2013/01/i2c-troubleshooting/</link>
		<comments>http://entropia.kapsi.fi/blog/2013/01/i2c-troubleshooting/#comments</comments>
		<pubDate>Fri, 04 Jan 2013 08:26:23 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[microcontroller]]></category>
		<category><![CDATA[work]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=407</guid>
		<description><![CDATA[Sometimes you might run into a situation when one or more of your I2C devices don&#8217;t work. I deal with barometric pressure sensors in my work and these work on the I2C bus. I&#8217;ve been banging my head against the &#8230; <a href="http://entropia.kapsi.fi/blog/2013/01/i2c-troubleshooting/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>Sometimes you might run into a situation when one or more of your I2C devices don&#8217;t work. I deal with barometric pressure sensors in my work and these work on the I2C bus. I&#8217;ve been banging my head against the wall many times over simple things and mistakes, and that&#8217;s why I decided to share some of that &#8220;wisdom&#8221;.<span id="more-407"></span></p>
<p>If you have a prototype board where your sensor works nicely, but when you get a new revision of the board but the sensor suddenly stops working, try these things:</p>
<ul>
<li>Check I2C device voltages. They are usually 3.3 or 5.0 volts. If not, trace back to your regulator or power supply. Always measure the voltage directly from the device power supply pins. If you use a circuit common ground point, you might see voltage but if the ground is not connected to the device, this will cause a problem and you will be scratching your head.</li>
<li>Check that SDA and SCL are idling high. I2C data lines are always pulled up by resistors. Check that the lines are at 3.3 or 5.0 volts, depending on your voltage levels.</li>
</ul>
<p>If the device isn&#8217;t responding, but the previous steps are OK, move on:</p>
<ul>
<li>Check that SDA and SCL are the right way round. Double check. <em>Triple check.</em> The I2C device will simply not acknowledge its address if the data lines are swapped and you are left scratching your head.</li>
<li>If the device is operating at 5.0 volts but your MCU is working at 3.3 volts, there might be a problem with voltage level interpretation. For CMOS devices, it&#8217;s common to have logic high signal&#8217;s lowest voltage around 0.75 times the supply voltage. For 5.0 this is 3.75 volts. 3.3 volt I2C causes a problem where the device doesn&#8217;t recognize the 3.3 volts of the bus as logical 1. The solution would be to raise the I2C voltage if, your MCU permits. Some MCUs are 5V tolerant, or their supply voltage range might extend to 3.8 volts or beyond.</li>
<li>Some I2C devices will work on practically any bus frequencies. Other devices may require specific operating frequency. Check the datasheet to see what the working frequencies are for your device.</li>
<li>Timing is just like the frequency. Some device don&#8217;t really care, while others are extremely picky. This is where an oscilloscope comes in handy. Check that your start and stop conditions are as they are supposed to (see below). Also some devices may &#8220;lock up&#8221; if the SDA pulses when SCL remains steady. Check the device datasheet or ask the manufacturer if you suspect this kind of behaviour. You can also try to start-stop between sequences to clear these lock-ups.</li>
</ul>
<p>The I2C defines a few signal level conditions. These are the start and stop conditions. Below is an oscilloscope screenshot from Silicon Microstructures SM9541 differential pressure sensor communication.</p>
<ul>
<li>The start condition is when SDA goes down, while SCL is held up.</li>
<li>The stop condition is when SDA goes up, while SCL is held up.</li>
</ul>
<div id="attachment_408" class="wp-caption aligncenter" style="width: 490px"><a href="http://entropia.kapsi.fi/blog/2013/01/i2c-troubleshooting/tek00044/" rel="attachment wp-att-408"><img class="size-full wp-image-408" alt="Example I2C communication" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2013/01/TEK00044.png" width="480" height="234" /></a><p class="wp-caption-text">Example I2C communication</p></div>
<p>It&#8217;s also easy to read I2C communication by hand, when you have an oscilloscope and the traces are lined up nicely. You simply look up what SDA is when SCL is going up. The screenshot above contains three 9-bit messages. Here is the first, decoded:</p>
<ul>
<li>Start condition (SDA down while SCL is up)</li>
<li>0 1 0 1 0 0 0 &#8212; 7 bits, device address</li>
<li>1 &#8212; 8th bit is high, this means it&#8217;s a read request</li>
<li>0 &#8212; 9th bit is low, this means that device on the bus acknowledges and communications can proceed</li>
<li>The rest of the bits are device specific</li>
</ul>
<p>In read requests, every 9th bit is the master&#8217;s acknowledgement. When the bit is 0, the master acknowledges (ACK). This way the device knows to keep going. When the master issues bit 1, which is not acknowledged (NACK), the device stops. The master then issues a stop condition.</p>
<p>I hope this little blob of I2C info helps you along in your project!</p>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2013/01/i2c-troubleshooting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What happens when a V-groove hits your copper pour</title>
		<link>http://entropia.kapsi.fi/blog/2013/01/what-happens-when-a-v-groove-hits-your-copper-pour/</link>
		<comments>http://entropia.kapsi.fi/blog/2013/01/what-happens-when-a-v-groove-hits-your-copper-pour/#comments</comments>
		<pubDate>Wed, 02 Jan 2013 11:13:44 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[pcb]]></category>
		<category><![CDATA[work]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=402</guid>
		<description><![CDATA[When you design PCBs for work, cost-effectiveness is a big factor. To help you out in the that department, you usually design your board to be a big panel. This panel is then CNC routed to contain a V-groove. This &#8230; <a href="http://entropia.kapsi.fi/blog/2013/01/what-happens-when-a-v-groove-hits-your-copper-pour/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>When you design PCBs for work, cost-effectiveness is a big factor. To help you out in the that department, you usually design your board to be a big panel. This panel is then CNC routed to contain a V-groove. This is as the name implies, a V-shaped groove that runs between the individual boards on your panel. When you have pasted, stuffed and reflowed your boards you simply snap them off. This brings in the cost-effectiveness, to be able to process many tens of boards at once.<span id="more-402"></span></p>
<p>Anyway, back to the topic. You usually want to have a copper pour on your boards, be it ground or a power plane. Sometimes it just so happens that you send your Gerbers to the PCB fab but they reply back saying the V-groove will cut the copper, is this OK? Well, in one of my prototype boards I just told them &#8220;go ahead&#8221;. This is what came back:</p>
<div id="attachment_403" class="wp-caption aligncenter" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/2013/01/what-happens-when-a-v-groove-hits-your-copper-pour/img_20130102_125150/" rel="attachment wp-att-403"><img class="wp-image-403 " alt="When V-groove cuts in to the copper" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2013/01/IMG_20130102_125150-1024x771.jpg" width="640" height="481" /></a><p class="wp-caption-text">The result (click for bigger)</p></div>
<p>&nbsp;</p>
<p>It looks nasty, but the board is totally usable. You wouldn&#8217;t sell this to the customer, and actually I had one short caused by the bent copper near a connector. If you know the risk and you&#8217;re in a hurry, you can certainly let the V-grooving cut the copper. But I would advise to fix it anyway.</p>
<p>With typical V-groove specifications, you need to leave a guard area of 0.4 millimeters around the border of the board.</p>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2013/01/what-happens-when-a-v-groove-hits-your-copper-pour/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>I²C Address Probe for PICs (CCS compiler)</title>
		<link>http://entropia.kapsi.fi/blog/2012/10/i2c-address-probe-for-pics-ccs-compiler/</link>
		<comments>http://entropia.kapsi.fi/blog/2012/10/i2c-address-probe-for-pics-ccs-compiler/#comments</comments>
		<pubDate>Mon, 15 Oct 2012 09:41:28 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[coding]]></category>
		<category><![CDATA[microcontroller]]></category>
		<category><![CDATA[work]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=398</guid>
		<description><![CDATA[As a part of my work, I wrote this simple I2C address probe. It&#8217;s for PIC microcontrollers, using CCS compiler. (It&#8217;s here mostly as a note for myself, but you might find it useful as well.) void probeAllAddresses() { int &#8230; <a href="http://entropia.kapsi.fi/blog/2012/10/i2c-address-probe-for-pics-ccs-compiler/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>As a part of my work, I wrote this simple I<sup>2</sup>C address probe. It&#8217;s for PIC microcontrollers, using CCS compiler. (It&#8217;s here mostly as a note for myself, but you might find it useful as well.)</p>
<p><span id="more-398"></span></p>
<pre>void probeAllAddresses()
{
 int i = 0;
 int addr = 0;

 for(i = 0; i &lt; 128; i++)
 {
 addr = i &lt;&lt; 1;
 printf("Probing address WRITE %x (%u)...", addr, i);
 i2c_start();
 if(i2c_write(addr))
 {
 printf("no ack.\n");
 }
 else
 {
 printf("device found!\n");
 }
 i2c_stop();
 delay_ms(100);

 }
 printf("\n");
 for(i = 0; i &lt; 128; i++)
 {
 addr = i &lt;&lt; 1;
 addr = addr + 1;
 printf("Probing address READ %x (%u)...", addr, i);
 i2c_start();
 if(i2c_write(addr))
 {
 printf("no ack.\n");
 }
 else
 {
 printf("device found!\n");
 }
 i2c_stop();
 delay_ms(100);

 }
 printf("\n");

}</pre>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2012/10/i2c-address-probe-for-pics-ccs-compiler/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Comments disabled for now</title>
		<link>http://entropia.kapsi.fi/blog/2012/09/comments-disabled-for-now/</link>
		<comments>http://entropia.kapsi.fi/blog/2012/09/comments-disabled-for-now/#comments</comments>
		<pubDate>Sat, 08 Sep 2012 07:26:27 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=393</guid>
		<description><![CDATA[I&#8217;m disabling comments for now. I get two to three spam comments a day, which isn&#8217;t much by itself, but I get a notification on my phone every single time. That&#8217;s annoying. For spammers: don&#8217;t waste those poor Indian people&#8217;s &#8230; <a href="http://entropia.kapsi.fi/blog/2012/09/comments-disabled-for-now/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>I&#8217;m disabling comments for now. I get two to three spam comments a day, which isn&#8217;t much by itself, but I get a notification on my phone every single time. That&#8217;s annoying.</p>
<p>For spammers: don&#8217;t waste those poor Indian people&#8217;s time on solving reCAPTCHA&#8217;s for my site. No one of your stupid spams have ever got through.</p>
<p>If you wish to contact me, my account is mristila and the email server is gmail.com.</p>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2012/09/comments-disabled-for-now/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Mils to millimeters cheatsheet</title>
		<link>http://entropia.kapsi.fi/blog/2012/06/mils-to-millimeters-cheatsheet/</link>
		<comments>http://entropia.kapsi.fi/blog/2012/06/mils-to-millimeters-cheatsheet/#comments</comments>
		<pubDate>Sat, 09 Jun 2012 08:20:39 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[ideas]]></category>
		<category><![CDATA[pcb]]></category>
		<category><![CDATA[project]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=384</guid>
		<description><![CDATA[When I design PCBs I use millimeters for drill sizes, component pad distances and sizes and for board outlines. Somehow I ended up using mils for trace widths and clearances. This doesn&#8217;t really make sense, and now I decided I &#8230; <a href="http://entropia.kapsi.fi/blog/2012/06/mils-to-millimeters-cheatsheet/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>When I design PCBs I use millimeters for drill sizes, component pad distances and sizes and for board outlines. Somehow I ended up using mils for trace widths and clearances. This doesn&#8217;t really make sense, and now I decided I would move to millimeters altogether.</p>
<p>To help me in this, I made a simple lookup table from mils to millimeters and back. I also included ITead Prototype PCB service rules since I think many hobbyists order their PCBs from ITead. Below you can find links for the PDF as well as the original Excel sheet, so you can modify it to your liking. If you like it, or find any mistakes, please leave a comment!<span id="more-384"></span></p>
<p>PDF cheatsheet: <a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/06/mils_to_millimeters_cheatsheet.pdf">mils_to_millimeters_cheatsheet.pdf</a><br />
Excel original:  <a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/06/mils_to_millimeters_cheatsheet.xlsx">mils_to_millimeters_cheatsheet.xlsx</a></p>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2012/06/mils-to-millimeters-cheatsheet/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Project AmbiHDMI is progressing</title>
		<link>http://entropia.kapsi.fi/blog/2012/04/project-ambihdmi-is-progressing/</link>
		<comments>http://entropia.kapsi.fi/blog/2012/04/project-ambihdmi-is-progressing/#comments</comments>
		<pubDate>Wed, 18 Apr 2012 16:10:59 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=379</guid>
		<description><![CDATA[I&#8217;ve made progress with AmbiHDMI. The PCB shipment is on its way from China, and it should arrive early next week (I hope!). UPS dropped off a package from Farnell today. See, I was contacted by Farnell a few weeks &#8230; <a href="http://entropia.kapsi.fi/blog/2012/04/project-ambihdmi-is-progressing/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>I&#8217;ve made progress with AmbiHDMI. The PCB shipment is on its way from China, and it should arrive early next week (I hope!). UPS dropped off a package from Farnell today. See, I was contacted by Farnell a few weeks ago. They offered to ship me a few items in exchange for a review. I asked for a couple of <a href="http://uk.farnell.com/analog-devices/adv7611bswz-p/rx-hdmi-low-power-165mhz-64lqfp/dp/1903660?Ntt=adv7611" target="_blank">ADV7611 HDMI receivers</a> and a couple of <a href="http://uk.farnell.com/te-connectivity/1746679-1/receptacle-hdmi-a-flange/dp/1877696?Ntt=187-7696" target="_blank">HDMI receptables from TE Conn</a>. The packaging was totally overkill but atleast all the four bits made it from England to Finland in one piece!<span id="more-379"></span></p>
<p>Here is what I received:</p>
<div id="attachment_380" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/ambihdmi_1.jpg"><img class="size-large wp-image-380" title="ambihdmi_1" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/ambihdmi_1-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">The packaging</p></div>
<p>And here are the parts inside all of that packaging:</p>
<div id="attachment_381" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/ambihdmi_2.jpg"><img class="size-large wp-image-381" title="ambihdmi_2" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/ambihdmi_2-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">The goods</p></div>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2012/04/project-ambihdmi-is-progressing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Transformation of Samsung SCX-4200</title>
		<link>http://entropia.kapsi.fi/blog/2012/04/the-transformation-of-samsung-scx-4200/</link>
		<comments>http://entropia.kapsi.fi/blog/2012/04/the-transformation-of-samsung-scx-4200/#comments</comments>
		<pubDate>Wed, 11 Apr 2012 08:30:55 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[fix]]></category>
		<category><![CDATA[hack]]></category>
		<category><![CDATA[project]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=358</guid>
		<description><![CDATA[(This is the English translation of my reader article on Ruuvipenkki) I bought a Samsung SCX-4200 around five years ago. I was just starting my engineering studies and figured I&#8217;d need a printer. Searching around for a suitable candidate, the &#8230; <a href="http://entropia.kapsi.fi/blog/2012/04/the-transformation-of-samsung-scx-4200/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.ruuvipenkki.fi/foorumi/viewtopic.php?f=15&amp;t=556"><em>(This is the English translation of my reader article on Ruuvipenkki)</em></a></p>
<p>I bought a Samsung SCX-4200 around five years ago. I was just starting my engineering studies and figured I&#8217;d need a printer. Searching around for a suitable candidate, the SCX-4200 popped up. In addition to being a USB-connected laser printer it was also a scanner-copier. I think it cost 160 euros back then, so it was perfect for a poor student. The toner cartridge ran out after a year and in the end I didn&#8217;t really need a printer since I could do all my printing for free at school anyway. The scanner has seen twice the action than the printer part ever did.</p>
<p><span id="more-358"></span>Little over a year ago I finally decided to get a new toner cartridge. I ended up ordering a cheap knock-off cartridge from Germany but that didn&#8217;t end up too well. Read all about it from my <a title="Cheap laser toner cartridges – you get what you pay for" href="http://entropia.kapsi.fi/blog/2011/01/cheap-laser-toner-cartridges-you-get-what-you-pay-for/">blog post from January 2011</a>.</p>
<p>Since I got a better printer (a used HP LaserJet 2300DN) there was no need for the printer part of the Samsung anymore. I did however need a scanner every now and then and yesterday I just decided to start doing something about it. The SCX-4200 had been in the closet for over a year, collecting dust. I took it out and started dismantling it.</p>
<div id="attachment_360" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5725.jpg"><img class="size-large wp-image-360" title="IMG_5725" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5725-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Still intact (see the toner seepage in the paper tray)</p></div>
<p>You can see that the scanner part is &#8220;self-contained&#8221;, and sits at the top of the device. The gap between the body and the platen deliberate (you can lift it up to allow more prints to accumulate in one go).</p>
<div id="attachment_361" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5728.jpg"><img class="size-large wp-image-361" title="IMG_5728" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5728-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">The CPU board</p></div>
<p>The main CPU is an ARM7TDMI called Chorus2. It is, ofcourse, a Samsung-developed unit specifically designed for printer-scanners. It runs at 66 MHz, has 1 megabyte of RAM and 8 megabytes of memory for print/scan jobs. (If you want more details, get the SCX-4200 Service Manual.)</p>
<p>In the picture above, you can see a flat-flex cable and three different cable harnesses. The double-white is the fuser thermistor, so that&#8217;s unnecessary. The flat-flex is directly connected to the line camera unit in the scanner. The one behind the flex is scanner motor drive (bipolar stepper) and the red-blue one is the front panel data/power. The front panel communicates via UART at 9600 bps so it is very hacker friendly. It&#8217;s not necessarily needed but I connected it anyway.</p>
<div id="attachment_362" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5730.jpg"><img class="size-large wp-image-362" title="IMG_5730" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5730-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Toner spillage</p></div>
<p>As I was rotating the device and unscrewing things the toner was spilling from every nook and cranny. The pirate cartridge had really spewed a lot of toner inside the printer. In case you&#8217;ve never encountered laser toner, it is really fine. Like flour but even finer. It stains textiles so be careful.</p>
<div id="attachment_363" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5731.jpg"><img class="size-large wp-image-363" title="IMG_5731" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5731-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Main drive assy</p></div>
<p>As I was disassembling the unit I uncovered a lot of interesting things that can be definitely used again somewhere else. Notice the toner which has covered the gears.</p>
<div id="attachment_364" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5734.jpg"><img class="size-large wp-image-364" title="IMG_5734" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5734-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Finally separated</p></div>
<p>Finally after half an hour or so I managed to separate the scanner unit from the rest of the device.</p>
<div id="attachment_365" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5736.jpg"><img class="size-large wp-image-365" title="IMG_5736" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5736-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Inside the printer</p></div>
<p>Inside the printer is a lot more toner and more salvageable parts. The black flat box on top, that is secured to the piece of steel is the Laser scanner unit as Samsung calls it. This is the thing that actually &#8220;draws&#8221; the image in the process. It has a polygon mirror inside it and a 0.22 milliwatt laser emitter. (What to do with this thing? Any hack ideas?)</p>
<div id="attachment_366" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5738.jpg"><img class="size-large wp-image-366" title="IMG_5738" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5738-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Power supply and logic</p></div>
<p>Engine assy, sounds fancy eh? That&#8217;s what Samsung Service Manual calls the green PCB. Anyway, here&#8217;s the other needed bit in addition to the scanner unit. Half of the power supply is redundant since we no longer need -400 V or 1.25 kV but I&#8217;ll use it just like this.</p>
<div id="attachment_367" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5741.jpg"><img class="size-large wp-image-367" title="IMG_5741" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5741-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Test run</p></div>
<p>I decided to test the units separately before proceeding. It worked right off the bat. Windows 7 installed all necessary drivers automatically (from Windows Update), which is nice.</p>
<p>The operating panel LCD complains about the door being open and paper tray being empty but the scanner works fine nonetheless. I haven&#8217;t had it on for more than 15 minutes at one go so I don&#8217;t know if the CPU gets upset about the fuser unit not warming up to temperature. From reading the Service Manual I know that there are error conditions for too low a temperature, overtemperature and something called &#8220;open temperature&#8221;. These haven&#8217;t triggered yet, though. If they do, I might have to fool the unit by adding a resistor over the thermistor connector or something similar. I could get around the door open -error by figuring out which harness has the door limit switch but it&#8217;s just a waste of time for no gain.</p>
<div id="attachment_368" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5746.jpg"><img class="size-large wp-image-368" title="IMG_5746" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5746-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Finished prototype</p></div>
<p>We&#8217;re nearly there. I took the power supply/logic thing and glued it to the bottom of the scanner unit. Some felt pads were adhered to the bottom. I have no materials/tools to do any better job so this will have to do for now.</p>
<p>This is a perfect opportunity to hone my 3D modeling skills though. Design a housing for the bottom part and have it 3D printed at Shapeways maybe&#8230; I&#8217;ll see if I ever get to that.</p>
<div id="attachment_369" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5747.jpg"><img class="size-large wp-image-369" title="IMG_5747" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5747-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">Scanning some PCBs</p></div>
<p>The scanner works just like before, only now it&#8217;s much smaller than before. Yay!</p>
<div id="attachment_370" class="wp-caption alignleft" style="width: 650px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5748.jpg"><img class="size-large wp-image-370" title="IMG_5748" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/04/IMG_5748-1024x768.jpg" alt="" width="640" height="480" /></a><p class="wp-caption-text">The loot</p></div>
<p>Here&#8217;s all the goodies that were salvaged. A beefy stepper motor with gears, the laser scanner unit (LSU, not pictured here), two solenoids, a round fan, a limit switch and an acrylic &#8220;sword&#8221;. I&#8217;m not quite sure what this sword does, it has grooves that rotate and get closer together. Either it&#8217;s an illumination device or it contains a photodiode in the end to capture light. Maybe it&#8217;s used in calibration of the LSU?</p>
<p>I call this project a success!</p>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2012/04/the-transformation-of-samsung-scx-4200/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>About some projects that I&#8217;m working on</title>
		<link>http://entropia.kapsi.fi/blog/2012/03/about-some-projects-that-im-working-on/</link>
		<comments>http://entropia.kapsi.fi/blog/2012/03/about-some-projects-that-im-working-on/#comments</comments>
		<pubDate>Tue, 27 Mar 2012 17:46:21 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=350</guid>
		<description><![CDATA[I thought I&#8217;d write something here for a change. I have a pretty short attention span when it comes to my free time projects, but all the projects progress at some pace nevertheless. A lot of ideas marinate in my &#8230; <a href="http://entropia.kapsi.fi/blog/2012/03/about-some-projects-that-im-working-on/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>I thought I&#8217;d write something here for a change. I have a pretty short attention span when it comes to my free time projects, but all the projects progress at some pace nevertheless. A lot of ideas marinate in my head all the time and when the right time comes, they start materializing. Anyway, enough babbling, here is my list of on-going projects in no particular order.</p>
<p><span id="more-350"></span></p>
<p>&nbsp;</p>
<p><strong>An Android device running on 450-megahertz ARM9</strong></p>
<p>The processor I&#8217;ve chosen is probably the only hobbyist-friendly CPU capable of running real Linux. It&#8217;s <a href="http://uk.farnell.com/freescale-semiconductor/mcimx233cag4b/ic-mpu-arm9-i-mx23-128lqfp/dp/1800428" target="_blank">Freescale&#8217;s i.MX233</a> which can be obtained in a TQFP package. The i.MX233 runs at 454 MHz but sadly doesn&#8217;t have any graphics acceleration. There are some <a href="http://www.youtube.com/watch?v=t9vYkwp7GwE" target="_blank">videos on YouTube that show Android</a> (mainly old 1.6 Donut) running so it&#8217;s definitely possible. 64 megabytes of DDR will be complementing the CPU. I haven&#8217;t decided on the display yet, but most probably I will go for a 320&#215;240 LCD with a resistive touch screen. i.MX233 conveniently allows you to boot directly from an SD card so it&#8217;s impossible to brick this thing. If something goes wrong, just rewrite the filesystem on the card and pop it back into the i.MX233 system.</p>
<p>So far I&#8217;ve done some schematic capture on this project (CPU, DDR and SD portions drawn, PSU and display still needs to be done). After the schematics are complete, I need to verify them and proceed to PCB layouting. This thing definitely needs a 4-layer PCB which will be a first for me. I hope I can get this thing up and running with minimal troubleshooting because my 50 MHz Rigol scope or even the Openbench Logic Sniffer aren&#8217;t fast enough to debug DDR memory lines. I wish I had the bucks to buy a fast scope!</p>
<p>&nbsp;</p>
<p><strong>A GPS logger</strong></p>
<p>See a pattern here? Yes, the best way to learn is to re-invent the wheel.</p>
<p>I&#8217;m aiming for a polished, end-user friendly project. This will be simple by specifications, but still takes quite an effort to get finished. A generic GPS receiver will provide location and altitude data to a microcontroller. I haven&#8217;t yet decided on an MCU but I&#8217;m probably going for a Microchip PIC simply because I want to learn about them. In the past I&#8217;ve always used Atmel AVR so this is a perfect opportunity to try out something new.</p>
<p>User interace works via a few buttons and a small LCD. The device will save the location and other data to an SPI Flash memory. Power is provided from an onboard single cell lithium polymer battery. When plugged into a computer the device will charge its battery and provide a method for offloading the collected GPS data to the user. The MCU is probably configured as a virtual COM-port and a small program on the computer side will query the data and output suitable files (for Google Earth perhaps).</p>
<p>The most trouble for me at the moment is proper handling of the battery. You can&#8217;t overcharge it nor overdischarge it. This is practically always handled by the battery, but I don&#8217;t want to risk it. I have decided on the battery charger chip (<a href="http://www.maxim-ic.com/datasheet/index.mvp/id/2536" target="_blank">MAX1811</a>) and the system power regulator (<a href="http://www.maxim-ic.com/datasheet/index.mvp/id/1742" target="_blank">MAX710</a>). Overcharging protection is handled by the MAX1811 but I&#8217;m not so sure about overdischarging. MAX710 has a low-battery comparator and a shutdown input so theoretically I could set the low-battery comparator to, say, 3.2 volts and then run the comparator output straight into the shutdown input. That might start to oscillate as I have no idea if the low-battery comparator operates after shutdown is active. The datasheet is a bit ambiguous about this.</p>
<p>So far done: nothing else but component selection. I might just have to order the Maxim chips and see if my theory about the low-battery comparator works or not.</p>
<p>&nbsp;</p>
<p><strong>HDMI Philips Ambilight clone</strong></p>
<p>This might be a world-first. An Ambilight clone that works stand-alone from an HDMI video stream. There are a gazillion different Ambilight clones in the internet, but every single one of them relies on a computer to do all the heavy lifting. The actual hardware usually consists of a slow microcontroller that does nothing else but receive light intensities over a serial port and modulate RGB LEDs. This is a very effective method on one condition &#8212; that the source is a PC.</p>
<p>A few projects have aimed for stand-alone, such as <a href="http://chameleon.madwizard.org/" target="_blank">Chameleon</a>, but they work off of relatively slow signal like composite video. Chameleon showed promise but it&#8217;s development has ground to a halt over four years ago.</p>
<p>My idea is to pair a FAST microcontroller (the <a href="http://www.st.com/internet/mcu/subclass/1521.jsp" target="_blank">STM32F4</a>, ARM Cortex-M4 running at 168 MHz) to an HDMI receiver (<a href="http://www.analog.com/en/audiovideo-products/analoghdmidvi-interfaces/adv7611/products/product.html" target="_blank">Analog Devices ADV7611</a>). The trick is not to capture the whole image but only portions of interest. That way the processor is able to pull this off on its own.</p>
<p>Another idea that I came up with is to have a daisy-chained RGB LED boards instead of having the main controller modulate all the individual RGB LEDs. I have actually already designed this board (schematic and PCB layout). They consist of a very small ATtiny microcontroller and three MOSFETs to drive the RGB LED. Three leads come in to the board and three leads go out. These are power, ground and data. Data format is not yet decided upon, but it is going to be something simple. One candidate is to have four-byte packets that contain one address byte and three bytes for intensities for each RGB component. The main controller needs to know where the daisy-chained boards are and how many of them there are to calculate suitable values from the image data and pass them on. Data link from main controller to RGB boards is unidirectional.</p>
<p>In addition to the RGB board I&#8217;ve started work on the HDMI receiver. The schematic is ready to go. PCB layout is doable in two layers. The first prototype will only contain the ADV7611 and its power supply. Pixel data is broken out to a pin header that can be wired into an <a href="http://www.st.com/internet/evalboard/product/252419.jsp" target="_blank">STM32F4DISCOVERY</a> development board for post-processing. HDMI is also receive-only, so an active HDMI splitter is required. In the final revision there should also be an HDMI transmitter on the board to allow simple pass-thru operation.</p>
<p>What about HDCP I hear you ask? The ADV7611 has built-in HDCP decryption and keys. I don&#8217;t know how this works in practice but again it should be doable.</p>
<p>&nbsp;</p>
<p><strong>Touch-screen GSM phone</strong></p>
<p>This one&#8217;s pretty old, the idea dates back to summer 2011. A simple 320&#215;240 LCD with touch screen is paired with an STM32F4 and a <a href="http://wm.sim.com/sim/wm/html/en/WMS/EDGE%20Module/ProductDetail.aspx?id=770" target="_blank">SIM900</a> GSM modem. I&#8217;ve done the schematic and PCB layout. Both need verifying and revisioning before placing an order on the PCB though. 80% of this project is ARM software, which I&#8217;m not very keen on.</p>
<p>&nbsp;</p>
<p><strong>Laptop DJ&#8217;ing device</strong></p>
<p>The idea is to combine two PCM2706 (as used in my USBDAC), a USB-capable microcontroller and a USB hub to a single device. The microcontroller would mimic a MIDI device that would send control messages to the PC. This would then be used as a companion to Traktor or Serato and a separate DJ mixer. Traktor outputs the two decks&#8217; audio into a DJ mixer&#8217;s A and B channels. User can then apply effects using potentiometers that are translated into MIDI control messages that Traktor interpret. Pre-fader listening and mixing is done outboard on a separate mixer, while beat-matching and pitching is left for Traktor.</p>
<p>Done: component selection, schematic capture 75% done.</p>
<p>&#8211;</p>
<p>Phew, that&#8217;s the ones that I have on the top of my head. Believe me, I&#8217;ve got TONS of ideas stirring in my head. I just wonder where I&#8217;m going to find all the time to work on these and more importantly, just think of all the money that is going to go into the components alone&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2012/03/about-some-projects-that-im-working-on/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Designing a USB sound card</title>
		<link>http://entropia.kapsi.fi/blog/2012/03/designing-a-usb-sound-card/</link>
		<comments>http://entropia.kapsi.fi/blog/2012/03/designing-a-usb-sound-card/#comments</comments>
		<pubDate>Wed, 14 Mar 2012 08:00:20 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=335</guid>
		<description><![CDATA[(This is an English translation of my article at Ruuvipenkki forum.) 1. Introduction In this article I will discuss my own experiences about designing a USB sound card, which is the USBDAC. DAC is an acronym for Digital-to-Analog Converter because in &#8230; <a href="http://entropia.kapsi.fi/blog/2012/03/designing-a-usb-sound-card/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p><em>(This is an English translation of my article at <a href="http://www.ruuvipenkki.fi/foorumi/viewtopic.php?f=15&amp;t=522">Ruuvipenkki forum</a>.)</em></p>
<h2>1. Introduction</h2>
<p>In this article I will discuss my own experiences about designing a USB sound card, which is the USBDAC. DAC is an acronym for Digital-to-Analog Converter because in a sound card, digital data representing the sound is converted into analog voltage that moves the speaker cone.</p>
<p>My device is loosely based on the PCM2706 reference design. I will not go through the tecnical details but instead concentrate on my own experiences in the design of the device. This is to keep people not familiar with electronics, as well as newcomers to electronics design, interested. You will see that one working product is the result of many failed prototypes.</p>
<p><span id="more-335"></span></p>
<h2>2. The PCM2706</h2>
<p>First, let me introduce the star of the occasion. PCM2706 is a USB 1.1-compliant peripheral, that implements the USB audio device class. This means that when you plug in the PCM2706, the operating system knows that its a standard device and can start using it without a separate driver.</p>
<p>The PCM2706 was designed by Burr-Brown, but since TI bought BB, it&#8217;s now being manufactured by TI. PCM2706 supports up to 16-bit 48 kHz sampling rate. This corresponds to CD level quality. It has a built-in headphone amplifier and a digital S/PDIF output for example home theater amplifiers. The headphone amplifier puts out a reasonable 175 milliwatts (0.175 W). The device is available in prototyping-friendly 32-pin TQFP package. It has a built-in 3.3 V regulator, so practically it doesn&#8217;t need any other than passive components to function.</p>
<p>More details and datasheet can be found at <a href="http://www.ti.com/product/pcm2706">TI&#8217;s PCM2706 info page</a>.</p>
<p>One PCM2706 costs around 8.4 euros (0% VAT) at Digi-Key, so it&#8217;s not very cheap. In volume the price will, of course, drop, but hobbyists might want to check out TI&#8217;s excellent sample service. A few PCM2706 samples will arrive from USA in less than a week and TI pays all the expenses (duties and taxes included, if applicable).</p>
<p><em>A small moral notice on behalf of the electronics enthusiast community: don&#8217;t order samples just because it&#8217;s free. If you have no intention of using the samples, don&#8217;t order them. Manufacturers give out samples very generously, and if people start taking advantage of them just for the fun of it, they might stop. This has happened in the past with some smaller semiconductor companies.</em></p>
<p>&nbsp;</p>
<h2>3. A Gallery of Failures</h2>
<p>In this chapter I will go through all the revision from the first to the last. You will see that to make one functional device, you have to fail atleast once or twice. :-)</p>
<h3>3.1 Prototype Revision A</h3>
<p><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_a_onlypcb.jpg"><img class="aligncenter size-full wp-image-338" title="rev_a_onlypcb" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_a_onlypcb.jpg" alt="" width="640" height="345" /></a></p>
<p>Prototype A was a 1:1 copy of the datasheet reference design. I had made atleast five different mistakes that caused the device not to function even after I had bypassed the mistakes with jumper wires. The device was caught in an endless USB enumeration loop that was illustrated by the Windows &#8220;new device found&#8221; sound being heard ad infinitum. The PCM2706 was probably killed because USB&#8217;s 5 volts was fed into its 3.3-volt regulated pins. In addition, I was missing crucial pull-ups/pull-downs and the digital out lines that I chose to include didn&#8217;t work because they were configured incorrectly (also pull-ups/pull-downs).</p>
<p>In respect of PCB layout design, no rules were followed. There isn&#8217;t even a copper fill on the top layer. The design is in effect one-sided since the whole bottom layer is a ground plane.</p>
<p>Populating this board was the first time I did surface-mount soldering and it shows. All small resistors and caps are 1206. Bigger electrolytic caps have wrong footprint, so I had to bend their leads down to get them soldered.</p>
<p><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_a_populated.jpg"><img class="aligncenter size-full wp-image-339" title="rev_a_populated" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_a_populated.jpg" alt="" width="514" height="480" /></a></p>
<h3>3.2 Prototype Revision B</h3>
<p><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_b_onlypcb.jpg"><img class="aligncenter size-full wp-image-340" title="rev_b_onlypcb" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_b_onlypcb.jpg" alt="" width="496" height="441" /></a></p>
<p>B-version was much more polished. I removed all the errors that I found in the A-version and checked the schematics a couple of times before ordering. I ordered the PCBs for the revision A without even a second look which of course was very stupid. Experience has taught me that.</p>
<p>The &#8220;beta&#8221; didn&#8217;t work the first go (surprise!). A couple of mistakes made it through to this version as well. The device VDD (3.3 V) does not equal USB VBUS (5.0 V), so I cut that trace. In addition the USB D+ line has to have a 1.5 kilo-ohm pull-up but I had instead specified a 1 megaohm resistor. These were easy fixes though. It wasn&#8217;t recognized by Windows though. The USBDAC was caught in the enumeration limbo again, just like the prevision version. I deducted it must be toast because I again fed five volts into its regulated pins. I soldered together another board with the aforementioned fixes and this time it was recognized immediately. The feeling of success was intoxicating as I watched the analog output bounce up and down on the oscilloscope screen.</p>
<p>I quickly soldered together the analog output stage and added the 3.5-millimeter headphone jack that was now part of the PCB design. After connecting the headphones I made to discoveries. Firstly; the headphone amp is very powerful. On earbuds (Sennheiser CX-300) Windows mixer&#8217;s sound level has to be 1/100 so that it&#8217;s not too loud. On bigger headphones (Beyerdynamic DT331) a nice level is around 5 to 10/100. Secondly; the bass was completely non-existing. Otherwise the sound was very nice, with a lot of crispness in the mid-tones and higher end. I started to investigate the bass problem by looking at my schematics. It didn&#8217;t take long to find the source of the problem.</p>
<p><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_b_populated.jpg"><img class="aligncenter size-full wp-image-341" title="rev_b_populated" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_b_populated.jpg" alt="" width="541" height="542" /></a></p>
<p>The output stage has an RC-type high-pass filter with a 100 microfarad electrolytic cap and a 3.3 kilo-ohm resistor. The corner frequency of the filter is around 0.5 Hz to filter out DC from getting into, and ruining your speakers. Somehow in my schematic I had specified 100 uF cap and a 16 ohm resistor giving me a corner frequency of 100 Hz which nicely cuts out all the bass frequencies. This was, again, a quick fix as I replaced the resistors and now it sounded magnificent. About 25% of that magnificence was just from the success but in the following days I used it to listen to a lot of music while at work and it didn&#8217;t start to sound any worse. Compared to my work PC&#8217;s built-in Realtek HD, it actually sounds better. The reference setup consists of Edirol MA-10A monitor speakers&#8217; headphone out and Beyerdynamic DT331 headphones.</p>
<p>There was one problem with the layout as well; the audio channels were swapped. This is no problem with music but it would have to be fixed to the next revision.</p>
<h3>3.3 Revision C &#8212; Third Time&#8217;s the Charm</h3>
<p>I worked on the third revision patiently since I no longer had any rush to success. I started designing the schematic back in September 2011. I drew the board layout on one hung-over sunday in one go in October 2011. I made necessary modifications and fixes in the following months as I perfected the design.</p>
<p><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/origo_traces.jpg"><img class="aligncenter size-full wp-image-337" title="origo_traces" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/origo_traces.jpg" alt="" width="606" height="600" /></a></p>
<p>The PCB design was again in practice one-sided since the bottom was a single continuous ground plane. This time I paid attention to signal trace lengths (clock signal), USB differential signal routing and grounding. The grounding is star-type since all ground points are connected directly to the ground plane. The clock source is no longer a crystal with parallel loading caps, but a self-contained crystal oscillator. At the moment I have a regular XO (Xtal Oscillator) installed but in the future I plan to try out if a TCXO (Temperature-Compensated Xtal Oscillator) makes any difference. There is also a spot for a 128-byte I2C EEPROM on the PCB for providing a custom USB identification. By default the device enumerates as &#8220;USB Audio DAC&#8221;.</p>
<p>A bigger change in this revision is that I designed it to fit in an existing case. The case is a Hammond 1551S, which is small at 50&#215;50 millimeters. I got the case only in March 2012 and even though I designed the board in October 2011, it fit perfectly.</p>
<p><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_c_onlypcb.jpg"><img class="aligncenter size-full wp-image-342" title="rev_c_onlypcb" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_c_onlypcb.jpg" alt="" width="650" height="563" /></a></p>
<p>After populating the board it worked instantly. It sounded like it should. The only &#8220;problem&#8221; at the moment is the output stage aluminum electrolytic caps which are too tall to fit in the case. I have ordered the replacements, Nichicon Muse F95 premium audio tantalums. They should make the bass even better. I haven&#8217;t yet tried the I2C EEPROM identification but after checking the schematics and comparing to the datasheet many times, I don&#8217;t think it will be a problem. A bigger problem will probably be the tiny physical size of the EEPROM. :-) There is a solder jumper P4 on the board that selects between default ID and the EEPROM.</p>
<p>Here is the finished Rev C board being tested:</p>
<p><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_c_populated.jpg"><img class="aligncenter size-full wp-image-343" title="rev_c_populated" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/03/rev_c_populated.jpg" alt="" width="705" height="520" /></a></p>
<p>&nbsp;</p>
<h2>4. Thoughts After The Project</h2>
<p>When I started this project I didn&#8217;t really have much experience or knowledge in designing a PCB. It showed. In the past year I&#8217;ve gathered a huge amount of real-world knowledge and experience which is invaluable. I don&#8217;t think I will learn quite as much in such a short time ever again.</p>
<p>The foremost thought on my mind is that you should never be too rushed to order the PCBs. Part of that problem for me was that getting finished PCBs from ITead Studio takes almost a month. The other part of the problem is my short attention span. :-)</p>
<p>I&#8217;m happy with the project. The only thing that I think about is the real performance of the device. Does it meet TI&#8217;s specs (THD, SNR)? Does it exceed them? What is the real power of the headphone amp? I have no way of measuring these, so they will be a mystery.</p>
<p>I would be happy to receive comments from more experienced designers about my PCB design and other things. What could I have done better? What did I do well? If you are a beginner, I hope this brings your expectations about electronics projects closer to reality.</p>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2012/03/designing-a-usb-sound-card/feed/</wfw:commentRss>
		<slash:comments>30</slash:comments>
		</item>
		<item>
		<title>Installing Android 4.0.3 Ice Cream Sandwich on HTC Desire</title>
		<link>http://entropia.kapsi.fi/blog/2012/02/installing-android-4-0-3-ice-cream-sandwich-on-htc-desire/</link>
		<comments>http://entropia.kapsi.fi/blog/2012/02/installing-android-4-0-3-ice-cream-sandwich-on-htc-desire/#comments</comments>
		<pubDate>Fri, 17 Feb 2012 08:22:13 +0000</pubDate>
		<dc:creator>Mikko</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://entropia.kapsi.fi/blog/?p=329</guid>
		<description><![CDATA[I&#8217;ve had the HTC Desire since October 2010 IIRC. Back then, Android 2.2 was all the rage. I was very happy with it. Soon later, Android 2.3 was released and all Desire users eagerly anticipated the arrival. HTC eventually delivered&#8230; &#8230; <a href="http://entropia.kapsi.fi/blog/2012/02/installing-android-4-0-3-ice-cream-sandwich-on-htc-desire/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>I&#8217;ve had the HTC Desire since October 2010 IIRC. Back then, Android 2.2 was all the rage. I was very happy with it. Soon later, Android 2.3 was released and all Desire users eagerly anticipated the arrival. HTC eventually delivered&#8230; about half a year behind schedule and only to encourage only experienced users to try it out since they couldn&#8217;t make the whole Sense UI fit in. Needless to say I was pretty frustrated with HTC&#8217;s solution. Another half year passed by and I really wanted something fresh. Either a new phone or a new ROM for the old Desire.<span id="more-329"></span></p>
<p>Since the gf wouldn&#8217;t approve of buying a new phone, I decided to root and mod the Desire. A few hours of Googling and trying to find clear instructions how to do the job I finally had ICS installed. Most, if not all, of the instructions assumed a thing or two which made the process not work for me. All of them recommended using unrEVOked 3 which should take care of all HTC phones. I downloaded unrEVOked, installed the HBOOT driver as instructed. It was very important not to have HTC Sync installed, which I didn&#8217;t because that program is a piece of shit. All good, right? Wrong. unrEVOked couldn&#8217;t find my phone. What&#8217;s wrong? I did all the necessary steps but it still doesn&#8217;t work. The problem is that all the instruction writers assumed I had, at one point, had HTC Sync installed which also installs some kind of &#8220;ADB&#8221; drivers which are required. After installing HTC Sync, confirming it works and then uninstalling (making sure not uninstall the &#8220;HTC Drivers&#8221;) unrEVOked finally found my phone.</p>
<p>Off it went, restarting the phone into HBOOT, doing its thing. 5 minutes later I was greeted with the &#8220;failed to get root, is your software too new?&#8221; error message. <strong>*sigh* </strong>Indeed I had the most recent HTC OTA update which defeated the poor old unrEVOked.</p>
<p>45 minutes worth of Googling for all kinds of FAQs, I accidentally stumbled upon one blog comment which mentioned Revolutionary. I downloaded it, generated a key for myself and finally was able to root the phone. Revolutionary kindly asked me if I also wanted the Clockwork Mod to be installed. I answered yes and moments later I had a rooted phone capable of installing ROMs. (Btw, what a stupid name for a firmware package. Why not just call it &#8220;firmware&#8221; or &#8220;operating system&#8221;?).</p>
<p>I backed up everything from the Clockwork Mod menu, switched the MicroSD card from 4 GB to a blank 8 GB one, formatted it and installed ICS. Installation went smoothly and soon I had it running. The first start took very long, probably 5 minutes. After that I was ready.</p>
<div id="attachment_330" class="wp-caption aligncenter" style="width: 970px"><a href="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/02/402538_10150795959176982_718126981_12603174_1695139117_n.jpg"><img class="size-full wp-image-330" title="ICS on Desire" src="http://entropia.kapsi.fi/blog/wp-content/uploads/2012/02/402538_10150795959176982_718126981_12603174_1695139117_n.jpg" alt="" width="960" height="720" /></a><p class="wp-caption-text">Android 4.0.3 on HTC Desire</p></div>
<p>There&#8217;s a few bugs with the current <a href="http://forum.xda-developers.com/showthread.php?t=1355660">ICS Beta 0.4.1.1 from Sandvold</a> but if you avoid those, it works quite OK. The bugs are:</p>
<ul>
<li>Camera preview doesn&#8217;t work. When you take a pic, they come out fine, but it&#8217;s kind of hard to compose the picture if you can&#8217;t see any preview.</li>
<li>The phone usually freezes if you tilt it horizontal in home screen. Sometimes it copes, most of the time not. The Desire boots automatically if it freezes. Solution: turn off automatic rotation of screen (Settings -&gt; Display) or try to always hold it vertical while in the home screen. Tilting works just fine while you are in a browser for example.</li>
</ul>
<p>Other than that, I&#8217;ve not encountered any other problems so far. Thumbs up for Sandvold &amp; co. for making the ICS for Desire happen!</p>
<p>To my great surprise, the UI is very snappy. All the menus work nicely, and best of all, the web browser seems much faster (the UI responsiveness most of all) than the old 2.2. I recommend you try out this ROM.</p>
<p>Here are the necessary URLs to root and mod your Desire:</p>
<ul>
<li><a href="http://forum.xda-developers.com/showthread.php?t=1355660">ICS Beta 0.4.1.1 mod ROM</a></li>
<li><a href="http://revolutionary.io/">Revolutionary</a> for rooting and installing Clockwork Mod</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://entropia.kapsi.fi/blog/2012/02/installing-android-4-0-3-ice-cream-sandwich-on-htc-desire/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>
