<?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>Computer Solutions Blog</title>
	<atom:link href="http://www.computersolutions.cn/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.computersolutions.cn/blog</link>
	<description>Whats happening at Computer Solutions</description>
	<lastBuildDate>Thu, 02 Sep 2010 08:07:13 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>eFrontWPI &#8211; WordPress integration Plugin for eFront</title>
		<link>http://www.computersolutions.cn/blog/2010/09/efrontwpi-wordpress-integration-plugin-for-efront/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=efrontwpi-wordpress-integration-plugin-for-efront</link>
		<comments>http://www.computersolutions.cn/blog/2010/09/efrontwpi-wordpress-integration-plugin-for-efront/#comments</comments>
		<pubDate>Thu, 02 Sep 2010 06:28:52 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[eFront]]></category>
		<category><![CDATA[eFrontWPI]]></category>
		<category><![CDATA[integration]]></category>
		<category><![CDATA[wordpress plugin]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=601</guid>
		<description><![CDATA[One of our clients has a large eLearning website that we maintain. They&#8217;re based out of Bangkok, so they flew me up for some onsite work, part of which culminated in this plugin here. eFront is a Learning Management System, similar to Moodle. Its billed as a User Friendly Learning System, although having used it, [...]]]></description>
			<content:encoded><![CDATA[<p>One of our clients has a large eLearning website that we maintain.<br />
They&#8217;re based out of Bangkok, so they flew me up for some onsite work, part of which culminated in this plugin here.</p>
<p>eFront is a Learning Management System, similar to Moodle.<br />
Its billed as a User Friendly Learning System, although having used it, I&#8217;d say thats a bit of a white lie! <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>More on eFront here &#8211; <a href="http://www.efrontlearning.net/">http://www.efrontlearning.net/</a></p>
<h1>eFrontWPI Plugin Overview</h1>
<p>This plugin provides single login functionality for WordPress / BBPress and eFront</p>
<p>It will optionally create an eFront user if one does not exist (option to set this in plugin settings).<br />
For login to function the WordPress user and password must be the same as the eFront username and password.</p>
<p>Plugin is based on the v1 api provided by eFront.  Should work with v2 also.<br />
To use the v2 api, simply change the eFront URL to the appropriate URI</p>
<p><strong>IMPORTANT NOTE:</strong><br />
This plugin requires cURL (php5_curl) to be installed as a pre-requisite.</p>
<h1>Instructions</h1>
<p>Upload this folder into your wordpress / bbpress plugins folder.</p>
<p>Typically -&gt;<br />
[your wordpress folder]/wp-content/plugins/</p>
<p>Activate plugin, then go to eFrontWPI Plugin Settings, and enter the appropriate data:</p>
<p>* eFront URL should be the full URI for the eFront API on your server.<br />
eg</p>
<p>http://www.yourservername.com/eFront/www/api.php</p>
<p>or</p>
<p>http://www.yourservername.com/eFront/www/api2.php</p>
<p>* Admin Login<br />
The eFront Admin user (suggest create a user for the API to use)</p>
<p>* Admin Pass<br />
The eFront Admin user pass</p>
<p>* Create User checkbox<br />
Check if you want a user automatically created.</p>
<p>* Current eFront token<br />
This is a read only field which shows the current eFront API token (if any).<br />
This is a good way to check if the plugin is working &#8211; if you have a token, it should be working.</p>
<p>Download here &#8211; <a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/09/eFrontWPI.zip">eFrontWPI v1.0</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/09/efrontwpi-wordpress-integration-plugin-for-efront/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dell Mini 3i (possibly also Dell Aero too) Firmware Exploration</title>
		<link>http://www.computersolutions.cn/blog/2010/08/dell-mini-3i-firmware-exploration/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=dell-mini-3i-firmware-exploration</link>
		<comments>http://www.computersolutions.cn/blog/2010/08/dell-mini-3i-firmware-exploration/#comments</comments>
		<pubDate>Wed, 25 Aug 2010 18:20:34 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[Firmware]]></category>
		<category><![CDATA[Technical Mumbo Jumbo]]></category>
		<category><![CDATA[borqs]]></category>
		<category><![CDATA[dell]]></category>
		<category><![CDATA[firmware]]></category>
		<category><![CDATA[marvell]]></category>
		<category><![CDATA[mini 3i]]></category>
		<category><![CDATA[mini3i]]></category>
		<category><![CDATA[ophone]]></category>
		<category><![CDATA[pxa935]]></category>
		<category><![CDATA[tavor]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=593</guid>
		<description><![CDATA[As I&#8217;ve been reasonably successful in the past at figuring out file systems from flat files, I thought I&#8217;d have a go at the Dell Mini 3i 1.5 Firmware that surfaced at damipan (http://www.namipan.com/d/DELL_MINI3I_OMS1.5.rar/a5ba3b06ab0bfc9baeb2f09b44f54aa40bac3457ee8ebc04) The rar file unzips to a MFF file. This I&#8217;m probably guessing is probably named after Marvell File Format or Marvell [...]]]></description>
			<content:encoded><![CDATA[<p>As I&#8217;ve been reasonably successful in the past at figuring out file systems from flat files, I thought I&#8217;d have a go at the Dell Mini 3i 1.5 Firmware that surfaced at damipan (<a href="http://www.namipan.com/d/DELL_MINI3I_OMS1.5.rar/a5ba3b06ab0bfc9baeb2f09b44f54aa40bac3457ee8ebc04">http://www.namipan.com/d/DELL_MINI3I_OMS1.5.rar/a5ba3b06ab0bfc9baeb2f09b44f54aa40bac3457ee8ebc04</a>)</p>
<p>The rar file unzips to a MFF file.</p>
<p>This I&#8217;m probably guessing is probably named after Marvell File Format or Marvell Flasher File.<br />
Here&#8217;s my initial work on the file system of MFF format, based on  DELL_Mini3i_OMS1.5.mff</p>
<p><strong>Initial 80 bytes [0x0 - 0x080] (MFF HEADER)</strong></p>
<p>0&#215;00 &#8211;  0&#215;03 :  3 Bytes Header MFF<br />
0&#215;03 &#8211; 0&#215;07 : Still to figure out, probably file length  or crc.<br />
Have to grab another firmware file to check though..</p>
<p>0&#215;08 : Number of files?  9 listed, so quite probably&#8230;<br />
Rest of header padded out with zero&#8217;s to end of 80 bytes.</p>
<p><strong>[0x80 - 0x180]  File Allocation Table</strong><br />
0&#215;80 &#8211; our first file.  Looks like 0&#215;100 / 256 bytes per file listed, padded with 0&#215;0&#8242;s</p>
<p>File listing looks like this:</p>
<p>File header (for each file)<br />
8 bytes, then filename, padded with 0&#8242;s to fill 256 bytes length</p>
<p>First 4 bytes &#8211; offset in MFF of start of file.<br />
Second 4 bytes &#8211; length of file.</p>
<p>Remaining files repeat from next 256 byte intervals.</p>
<p>eg<br />
0&#215;180 &#8211; 0&#215;280<br />
0&#215;280 &#8211; 0&#215;380<br />
&#8230;</p>
<p><strong>[0x80 + 9 files x 0x100 bytes = 0x980]  Start of Data.</strong></p>
<p>How did I work this out?</p>
<p>HEADER                            | Filename (not in hex below as easier to read)<br />
80 09 00 00 34 BB 00 00  | Tavor Flasher_Samsung_ONENAND_h.bin</p>
<p>0&#215;0980 is the start of our first file data, so the first 2 bytes are definitely File Start.<br />
0xBB34 looks quite possibly like File Length.</p>
<p>We can check this easily with one of the plain text files.</p>
<p>Flash_Protection_table.ini is prefixed with 63 EA AD 09   4B 00 00 00</p>
<p>So it should start at  0&#215;09 AD &#8211; hmm, readable text starts at offset 9AD D564.<br />
Not quite right.  Start offset looks close though.</p>
<p>Lets look at another one.</p>
<p>Tavor_saar_onenand.ini &#8211; prefix says<br />
64 d5 ad 09 6f 01 00 00</p>
<p>Ah, 0&#215;9 AD D5 64 is actually our Tavor_saar_onenand.ini content.  Cool, a match.  So, the first 4 bytes are definitely our location pointer.</p>
<p>Lets look at the Flash protection table again Flash_Protection_table.ini</p>
<p>63 EA AD 09   |  4B 00 00 00<br />
Should start at 09 AD EA 63, and go for 4B length.  Bingo, it does <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Our file contents for that area are:</p>
<p>[PROTECTED_REGION_0]<br />
Block_Offset=0&#215;100000<br />
Length=0&#215;20000<br />
Mode=SKIP_BLOCKS</p>
<p>So, now we can start to split the files apart into their associated parts.</p>
<p>factory_BENZ2GWIFI.fbf is probably going to be the most interesting, as its the largest.</p>
<p>That starts at 0xC564, length of 0x09AD1000 and starts with &#8220;Marvell_FBF&#8221;<br />
Basic math says that 0x9ADD564 (0x09AD1000 + 0xC564) should be our end of file.<br />
Well, it is, as we know flash protection table.ini starts at 9add564.</p>
<p>So, should be fairly easy with that info to write an unpacker tool to rip out the first interior files from the MFF file format.<br />
Some of the files inside are also &#8220;packed&#8221;, but those appear to be fairly easy to rip apart also <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>I&#8217;m guessing with a bit more work I&#8217;ll be able to replace parts of the firmware with different versions quite soonish.</p>
<p>The file I&#8217;m using off of namipan has the following files inside:</p>
<blockquote><p>TavorFlasher_SAMSUNG_ONENAND_h.bin<br />
TavorFlasher_SAMSUNG_ONENAND_TIM.bin<br />
factory_BENZ2GWIFI.fbf<br />
Tavor_SAAR_OneNAND.ini<br />
factory_BENZ2GWIFI.mff.mlt<br />
magic_fbf.ini<br />
magic_fbf_inner.ini<br />
NTIM_fbw.ini<br />
Flash_Protection_Table.ini</p></blockquote>
<p>I&#8217;m guessing that our fbf file will probably be able to be split into parts as per our ntim_fbw.ini data.<br />
FBF = Flash Binary Format?</p>
<p>some interesting files listed<br />
ntim.bin &#8211; non trusted image module?<br />
blob_full.bin &#8211; from the borq&#8217;s blob gz?<br />
Tavor_M05_Poleg_AI_B0_Flash.bin &#8211; tavor = our product chip, as we&#8217;re running on a Marvel PXA935 (aka Tavor-P65)</p>
<p>Interesting thing of note &#8211; our OEM UniqueID: 0xF00F00 in Unicode is what glyph?<br />
Hint &#8211; its not an orange, or a pear <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p><strong>NTIM_fbw.ini</strong></p>
<blockquote><p>Version: 0&#215;030102<br />
Trusted: 0</p>
<p>Issue Date: 0&#215;08142006<br />
OEM UniqueID: 0xf00f00<br />
Boot Flash Signature: 0x4e414e02<br />
Number of Images: 10<br />
Size of Reserved in bytes: 0&#215;40</p>
<p>Image ID: 0x54494D48<br />
Next Image ID: 0x4F424D49<br />
Flash Entry Address: 0&#215;0<br />
Load Address: 0x5c008000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: NTIM.bin</p>
<p>Image ID: 0x4F424D49<br />
Next Image ID: 0x4F534C4F<br />
Flash Entry Address: 0&#215;20000<br />
Load Address: 0x5c013000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: obm_full.bin</p>
<p>Image ID: 0x4F534C4F<br />
Next Image ID: 0x5349474E<br />
Flash Entry Address: 0&#215;80000<br />
Load Address: 0&#215;83000000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: blob_full.bin</p>
<p>Image ID: 0x5349474E<br />
Next Image ID: 0x494D4549<br />
Flash Entry Address: 0&#215;00120000<br />
Load Address: 0&#215;84000000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: signature_full.bin</p>
<p>Image ID: 0x494D4549<br />
Next Image ID: 0x4152424C<br />
Flash Entry Address: 0&#215;00100000<br />
Load Address: 0xBFEE0000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: reliable_full.bin</p>
<p>Image ID: 0x4152424C<br />
Next Image ID: 0&#215;47524249<br />
Flash Entry Address: 0&#215;00140000<br />
Load Address: 0xBF600000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: arbel_full.bin</p>
<p>Image ID: 0&#215;47524249<br />
Next Image ID: 0x62746C67<br />
Flash Entry Address: 0&#215;00840000<br />
Load Address: 0xBFF00000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: tavor_full.bin</p>
<p>Image ID: 0x62746C67<br />
Next Image ID: 0x70636C67<br />
Flash Entry Address: 0x00A00000<br />
Load Address: 0xBF300000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: bootlogo_full.bin</p>
<p>Image ID: 0x70636C67<br />
Next Image ID: 0x464F5441<br />
Flash Entry Address: 0x00A20000<br />
Load Address: 0x8F300000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: prechangelogo_full.bin</p>
<p>Image ID: 0x464F5441<br />
Next Image ID: 0xFFFFFFFF<br />
Flash Entry Address: 0x0EA40000<br />
Load Address: 0&#215;80100000<br />
Image Size To CRC in bytes: 0&#215;0<br />
Image Filename: fota_full.bin</p>
<p>Reserved Data:<br />
0x4F505448<br />
0&#215;00000002<br />
0&#215;55415254<br />
0&#215;00000010<br />
0&#215;00004646<br />
0&#215;00000001<br />
0x50524F49<br />
0&#215;00000020<br />
0&#215;00000002<br />
0&#215;00000000<br />
0&#215;00000000<br />
0&#215;00000000<br />
0&#215;00000001<br />
0&#215;00000000<br />
0x5465726D<br />
0&#215;00000008</p></blockquote>
<p><strong>Flash_Protection_Table.ini</strong></p>
<blockquote><p>[PROTECTED_REGION_0]<br />
Block_Offset=0&#215;100000<br />
Length=0&#215;20000<br />
Mode=SKIP_BLOCKS</p></blockquote>
<p><strong>magic_fbf_inner.ini</strong></p>
<blockquote><p>[INTEL_FLASH_DEVICE_INPUT_FILE]<br />
Number_of_Images=20</p>
<p>[IMAGE_HEADER_0]<br />
Start_Address=0xfa00000<br />
Image_Length=0&#215;80000<br />
EraseBlocks=1<br />
WriteImage=0<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_1]<br />
Start_Address=0xdd40000<br />
Image_Length=0&#215;800000<br />
EraseBlocks=1<br />
WriteImage=0<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_2]<br />
Start_Address=0xeb40000<br />
Image_Length=0x8c0000<br />
EraseBlocks=1<br />
WriteImage=0<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_3]<br />
Filename=NTIM.bin<br />
Start_Address=0&#215;00000000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_4]<br />
Filename=Arbel_NVM_SAC_NOCOMMRTC.bin<br />
Start_Address=0&#215;00140000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_5]<br />
Filename=blob<br />
Start_Address=0&#215;00080000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_6]<br />
Start_Address=0x0bd40000<br />
Image_Length=0&#215;02000000<br />
EraseBlocks=1<br />
WriteImage=0<br />
VerifyWrite=0<br />
[IMAGE_HEADER_7]<br />
Filename=opl.img.yaffs<br />
Start_Address=0x0bd40000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_8]<br />
Filename=ramdisk_len.img<br />
Start_Address=0x00c40000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_9]<br />
Filename=ramdisk-recovery_len.img<br />
Start_Address=0x00cc0000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_10]<br />
Start_Address=0x00d40000<br />
Image_Length=0&#215;08000000<br />
EraseBlocks=1<br />
WriteImage=0<br />
VerifyWrite=0<br />
[IMAGE_HEADER_11]<br />
Filename=system.img.yaffs<br />
Start_Address=0x00d40000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_12]<br />
Filename=TAVOR_LINUX_NTOBM.bin<br />
Start_Address=0&#215;00020000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_13]<br />
Filename=Tavor_M05_Poleg_AI_B0_Flash.bin<br />
Start_Address=0&#215;00840000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_14]<br />
Start_Address=0x08d40000<br />
Image_Length=0&#215;03000000<br />
EraseBlocks=1<br />
WriteImage=0<br />
VerifyWrite=0<br />
[IMAGE_HEADER_15]<br />
Filename=userdata.img.yaffs<br />
Start_Address=0x08d40000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_16]<br />
Filename=zImage<br />
Start_Address=0x00a40000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_17]<br />
Filename=prdcfg.bin<br />
Start_Address=0&#215;00940000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_18]<br />
Filename=precharge_logo.out<br />
Start_Address=0x00a20000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p>
<p>[IMAGE_HEADER_19]<br />
Filename=logo_pic.gz.out<br />
Start_Address=0x00a00000<br />
EraseBlocks=1<br />
WriteImage=1<br />
VerifyWrite=0</p></blockquote>
<p>Lastly, hi to the people at http://www.allphone.com.cn  <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/08/dell-mini-3i-firmware-exploration/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Firmware hackery on Keychain &#8220;spycams&#8221; [AK36xx based]</title>
		<link>http://www.computersolutions.cn/blog/2010/08/firmware-hackery-on-keychain-spycams-ak36xx-based/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=firmware-hackery-on-keychain-spycams-ak36xx-based</link>
		<comments>http://www.computersolutions.cn/blog/2010/08/firmware-hackery-on-keychain-spycams-ak36xx-based/#comments</comments>
		<pubDate>Mon, 23 Aug 2010 17:59:27 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[Exploits]]></category>
		<category><![CDATA[Technical Mumbo Jumbo]]></category>
		<category><![CDATA[ak3651b]]></category>
		<category><![CDATA[ak3xx]]></category>
		<category><![CDATA[Anyka]]></category>
		<category><![CDATA[CK808]]></category>
		<category><![CDATA[Hacking Firmware]]></category>
		<category><![CDATA[Keychain Video Camera]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=579</guid>
		<description><![CDATA[As I&#8217;ve been busy with real life &#8482;, its been a while since I took a trip to the computer mall to see what new goodies I could play with. A friend is in town from Beijing, so took him down to the Shanzhai hell (or heaven depending on PoV) that is Qiu Jiang lu. [...]]]></description>
			<content:encoded><![CDATA[<p>As I&#8217;ve been busy with real life &#8482;, its been a while since I took a trip to the computer mall to see what new goodies I could play with.</p>
<p>A friend is in town from Beijing, so took him down to the Shanzhai hell (or heaven depending on PoV) that is Qiu Jiang lu.</p>
<p>I wasn&#8217;t aware that you could buy Keychain video recorders for 80rmb, but you can.  Apparently they&#8217;re even cheaper in eBay &#8211; although I don&#8217;t see how its possible, given that the factories here are pricing higher than they sell for in the States.  Rejects?</p>
<p>Anyhow, I bought 2 keychain video camera&#8217;s, and an MP3 looking one.</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/imgA.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/imgA.jpg" alt="(swiped from Chuck Lohr&#039;s post)" title="imgA" width="287" height="250" class="alignnone size-full wp-image-590" /></a></p>
<p>Dissected one and it contains the Anyka AK3651B as the main chip.</p>
<p>The AK36xx series is an SoC (System on a Chip).</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/ak36xx.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/ak36xx.jpg" alt="" title="ak36xx" width="575" height="388" class="alignnone size-full wp-image-589" /></a></p>
<p>As Anyka appears to be deathly afraid of giving out any useful information about their products, I&#8217;ve had to piece together info from what I found online.</p>
<p>Their own product page here &#8211; <a href="http://www.anyka.com/enProShow.asp?sortFlag=110&#038;sortName=Application%20Processor&#038;id=105">http://www.anyka.com/enProShow.asp?sortFlag=110&#038;sortName=Application%20Processor&#038;id=105</a><br />
says the following:</p>
<blockquote><p>32-bit Microprocessor Core<br />
Integrated I/D cache<br />
Memory Management Unit (MMU)</p>
<p>Video Coprocessor<br />
MPEG4.SP codec<br />
H.263 codec<br />
Motion JPEG codec</p>
<p>Audio Coprocessor<br />
MP3 decoder<br />
WMA decoder<br />
AAC/AAC+ decoder<br />
AMR codec<br />
Real-time audio stream in PCM/ADPCM format</p>
<p>Image Coprocessor<br />
JPEG HW codec</p>
<p>Glueless Dual LCD Displays<br />
Supporting MPU LCD<br />
Supporting RGB LCD<br />
Programmable LCD size and refreshing rate</p>
<p>Connectivity<br />
USB 2.0 HS OTG<br />
I2S master/slave<br />
UART<br />
SPI<br />
MMC/SD</p>
<p>Embedded ADCs and DACs<br />
SAR ADC for touch panel and voltage detect<br />
Sigma-Delta ADC for microphone<br />
Sigma-Delta DACs for stereo</p>
<p>Built-in Power Amplifier/Headphone Driver</p>
<p>External Memory Support<br />
Supporting SDRAM<br />
Supporting Nand Flash (SLC/MLC, with hardware ECC)</p>
<p>Package<br />
LQFP 128-pin/144-pin，FBGA 100-pin/144-pin</p></blockquote>
<p>Appears that they&#8217;re mostly used in MP3/MP4 players, which is why most of my googling on specs was ruined by whiny users asking for someone to please help them with their foobar&#8217;d player.</p>
<p>The first useful links on these are at Chuck&#8217;s pages here &#8211; <a href="http://www.chucklohr.com/808/">http://www.chucklohr.com/808/</a></p>
<p>He&#8217;s done a lot of useful work collating information, although some of his deductions are a little strange, so take some things with a pinch of salt.  Lots of good info though.</p>
<p>The main source of info on the hardware side is at <a href="http://www.readerme.com">http://www.readerme.com</a>, they have a most excellent section of downloads which provide more information on the chips than anything else out there!</p>
<p>We gave them a call and had a chat (one of the benefits of being located in China, is that we obviously speak Chinese in the office!).<br />
They don&#8217;t speak great Mandarin though &#8211; so it was bad cantonesedarin or Mandonese?   Hmm, have to come up with a word for that!  (similar to Chinglish but mixing Cantonese and Mandarin).</p>
<p>Both sides were laughing but we could at least talk to each other.   &#8220;Mo man tai, dui ma?&#8221;</p>
<p>They actually don&#8217;t sell products, they only do design work for others, but, thats good to know.<br />
They did point us in the direction of a few trading companies that could do FOB export, but shipping quantities are in the x,000&#8242;s so not so useful yet.</p>
<p>I&#8217;ll see if I can find the actual factories making these tomorrow.  (Although when I say we, I mean the staff).<br />
They did prove to be an excellent source of data on the chips though if one takes a look at the PDF&#8217;s on their site.</p>
<p>The golden data trove is here &#8211; <a href="http://www.readerme.com/html/html/%E7%9B%B8%E5%85%B3%E4%BA%A7%E5%93%81%E5%8E%9F%E7%90%86%E5%9B%BE%EF%BC%8C%E8%B4%B4%E7%89%87%E5%9B%BE.html">http://www.readerme.com/html/html/%E7%9B%B8%E5%85%B3%E4%BA%A7%E5%93%81%E5%8E%9F%E7%90%86%E5%9B%BE%EF%BC%8C%E8%B4%B4%E7%89%87%E5%9B%BE.html</a></p>
<p>According to Anyka (安凯 in Chinese) the 36xx chips are a series, so they should have similar functionality.  </p>
<p>While I don&#8217;t have data sheets, or a BSP, I can read the PDF&#8217;s at least to get an idea of where things are laid out.</p>
<p>AK3631B<br />
<a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/3631-pin-layout.gif"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/3631-pin-layout-295x300.gif" alt="" title="3631 pin layout" width="295" height="300" class="alignnone size-medium wp-image-583" /></a></p>
<p>AK3651B<br />
<a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/ak3651b-BGA100.gif"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/ak3651b-BGA100-296x300.gif" alt="" title="ak3651b BGA100" width="296" height="300" class="alignnone size-medium wp-image-584" /></a></p>
<p>They do look similar, so probably only minor differences in functionality (probably the newer ones are cheaper?).<br />
Again, hard to check, as Anyka datasheets appear to be hens teeth.  </p>
<p>I may give them a call also, and see if they&#8217;ll be willing to give us some info about their products, but I&#8217;m not holding my breath on that one.</p>
<p>I&#8217;ve also poked around a bit in the firmware files using strings, and taking a look at headers, and have come up with some preliminary conclusions.</p>
<p>I&#8217;m guessing their SoC is ARM5 based, given what i have found (haven&#8217;t decompiled yet, but looks like that).</p>
<p>Some common strings in the firmware&#8217;s from start:</p>
<p>00000 06 00 00 EA FE FF FF EA</p>
<p>Googling &#8220;06 00 00 EA FE FF FF EA&#8221; comes up with some other people talking about firmware for pxa312 devices, which have exactly that in their boot loader, so, seems likely.</p>
<p>The PXA312 is ARMv5TE&#8230;</p>
<p>I&#8217;m guessing some playing around with radare (<a href="http://radare.nopcode.org/get/radare.pdf.html">http://radare.nopcode.org/get/radare.pdf.html</a>) should get some more info about whats going on.</p>
<p>Running strings on the firmware files available shows interesting info:</p>
<blockquote><p>strings /Documents/Keychain\ Camera/cx311V2.04/Spiboot_36XX.bin<br />
ANYKA362<br />
  6KA49<br />
start read cfg<br />
file cnt:%d<br />
file name:%s<br />
Cannot find BIOS<br />
read file info fail<br />
load bios &#8230;&#8230;<br />
map:%d<br />
file len:%d<br />
ld addr:0x%x<br />
Load bios from spiflash successfuly!<br />
read BIOS fail<br />
spi boot start<br />
system clock: %d<br />
BIOS</p>
</blockquote>
<p>Thats our 4k bootloader, which obviously loads our 1M bios image from SPI flash memory (SPI = Serial Peripheral Interface)<br />
More on SPI here.<br />
<a href="http://en.wikipedia.org/wiki/Serial_Peripheral_Interface_Bus">http://en.wikipedia.org/wiki/Serial_Peripheral_Interface_Bus</a></p>
<p>Hmm, more reasons for me to get a Bus Pirate now&#8230;</p>
<p>We have a flasher also, although its Windows based.<br />
I&#8217;m guessing some USB sniffing will lead to some magic byte handshake sequence to get into the bootloader via USB, as the BIOS strings point to that.</p>
<p>eg: </p>
<blockquote><p>&#8220;The setup packet is not 8 byte!&#8221;
</p></blockquote>
<p>Also amusing is that its fairly easy to find the FAT32 code embedded in at least one of the firmwares</p>
<p>EB xx 90 &#8230; -> 55 AA (in Sprint1M.bin)</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/hex-view-of-spring1m.gif"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/hex-view-of-spring1m.gif" alt="" title="hex view of spring1m" width="646" height="218" class="alignnone size-full wp-image-581" /></a></p>
<p>The flasher tool is also nice enough to give us an idea of layout in the 1M flash chip.</p>
<p>You&#8217;ll need to install the Anyka M3 USB driver to talk to the chip, which appears to have the following attributes via USB:<br />
Vendor ID: 0471<br />
Product ID: 0666  (the product of the beast? hehe)</p>
<p>This is a bit naughty, as 0471 is in theory already taken by  Philips (or NXP) according to <a href="http://www.linux-usb.org/usb.ids">http://www.linux-usb.org/usb.ids</a></p>
<p>Its also astoundingly obvious that they used driverworks to make the driver. (From the oh so copied in China vid/pid, and the strings left in the driver).  An example of this here <a href="http://www.baiheee.com/OpenSource/Easy%20USB%2051%20Programer/Easy%20USB%2051%20Programer_DriveOurBoard.htm">http://www.baiheee.com/OpenSource/Easy%20USB%2051%20Programer/Easy%20USB%2051%20Programer_DriveOurBoard.htm</a></p>
<p>Want to bet someone read those instructions and its been repeated ad nauseum?<br />
Sadly, its so easy to see the minimal effort that&#8217;s gone into things.</p>
<p>Back to our flasher, it says that our 1M chip is laid out as follows:</p>
<blockquote><p>###Project Name<br />
project name = chaoxian</p>
<p>###Devie Number<br />
device channel = 8</p>
<p>###COM<br />
com bOpen = 0<br />
com base = 1<br />
com count = 1<br />
com baud rate = 38400</p>
<p>path producer sundance2 = producer_sundance2.bin<br />
path producer sundance2A uboot = producer_sundance2A_uboot.bin<br />
path producer sundance2A umass = producer_sundance2A_umass.bin<br />
path nandboot sundance2= Spiboot_36XX.bin<br />
path nandboot sundance2A= Spiboot_36XX.bin</p>
<p>bios run addr = 0&#215;30500000<br />
bios start addr = 0xc0000<br />
bios end addr = 0x1c0000<br />
bios backup start addr = 0x1c0000<br />
bios backup end addr = 0x2c0000</p>
<p>chip type = AK_3225<br />
chip uboot = 1<br />
chip power off gpio = 255<br />
chip usb2 = 0<br />
chip get aid = 0<br />
chip update = 0<br />
chip select loop = 1<br />
chip select nand0 = 1<br />
chip select nand1 = 1<br />
chip select nand2 = 1<br />
chip select nand3 = 1<br />
chip gpio_ce2 = 255<br />
chip gpio_ce3 = 255</p>
<p>ram size = 8<br />
ram row = 12<br />
ram column = 8<br />
ram bank = 4</p>
<p>moduleburn DownloadMode = 2<br />
moduleburn bDownloadFLS = 1<br />
moduleburn bDownloadEEP = 1<br />
moduleburn baudrate = 921600<br />
moduleburn gpio_dtr = 85<br />
moduleburn gpio_module_igt = 109<br />
moduleburn gpio_module_reset = 87<br />
moduleburn path_fls = LCG2.fls<br />
moduleburn path_eep = LCG2.eep</p>
<p>fs start addr = 0x6c0000<br />
fs reserver block = 64<br />
fs nonfs reserve size = 4</p>
<p>partition count = 0</p>
<p>download_to_udisk count = 0</p>
<p>download_to_nand count = 3<br />
download_to_nand1 = 0, Spring1M_bios.bin, 0&#215;30500000, BIOS<br />
download_to_nand2 = 0, Spring.bin, 0&#215;30000000, MMI<br />
download_to_nand3 = 0, AkResData.Bin, 0&#215;0, RES</p>
<p>download_to_mtd count = 0</p>
<p>nand supported count = 0
</p></blockquote>
<p>If we take a look at that, our Spring1M_bios.bin starts off at C000<br />
(bios start addr = 0xc0000)<br />
(Deduct a 0 as we&#8217;re not offset by 0&#215;300000000)</p>
<p>A look in a hex editor at that position shows:</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/spring1M_bios-0xc000.gif"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/08/spring1M_bios-0xc000.gif" alt="" title="spring1M_bios 0xc000" width="649" height="204" class="alignnone size-full wp-image-585" /></a></p>
<p>Note the 32bit word value &#8211; 0xE1A0C00D</p>
<p>Thats classic ARM, so we _know_ its arm based&#8230;</p>
<blockquote><p>romStart [0xe1a0c00d] mov r12,r13</p></blockquote>
<p>Our next line of code is exactly the same as listed here <a href="http://code.google.com/p/milestone-overclock/wiki/Disassembly">http://code.google.com/p/milestone-overclock/wiki/Disassembly</a></p>
<blockquote><p> e1a0c00d        mov     ip, sp<br />
 e92dd8f0        push    {r4, r5, r6, r7, fp, ip, lr, pc}</p></blockquote>
<p>So its looking like we can basically disassemble the code using  arm-none-linux-gnueabi-objdump</p>
<p>I&#8217;ll leave that for another day, but with a bit more work we could compile our own code for this as we now have a good idea of the target cpu.</p>
<p>The next step would be to get into the bootloader or debug mode via USB, and see what can be seen.</p>
<p>Tools used:</p>
<p>0xED &#8211; <a href="http://www.suavetech.com/0xed/0xed.html">http://www.suavetech.com/0xed/0xed.html</a><br />
A nice fast and compact hex viewer for OSX.</p>
<p>strings &#8211; built into most *nix based systems.</p>
<p>Grey matter &#8211; Available to all, unused by many <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Now hopefully I can get back to the Webcam firmware stuff as I&#8217;ve been promising to do.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/08/firmware-hackery-on-keychain-spycams-ak36xx-based/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Apple Store Opening in Shanghai</title>
		<link>http://www.computersolutions.cn/blog/2010/07/apple-store-opening-in-shanghai/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=apple-store-opening-in-shanghai</link>
		<comments>http://www.computersolutions.cn/blog/2010/07/apple-store-opening-in-shanghai/#comments</comments>
		<pubDate>Thu, 08 Jul 2010 11:03:35 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[China Related]]></category>
		<category><![CDATA[ifc]]></category>
		<category><![CDATA[pudong]]></category>
		<category><![CDATA[store opening]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=572</guid>
		<description><![CDATA[Although I was supposed to be on a plane today heading home, I did something silly and got the dates wrong. So, after a nice scenic trip yesterday evening to the airport and back, I get to do it all over again tonight. Although that was a total pain, I did get to spend another [...]]]></description>
			<content:encoded><![CDATA[<p>Although I was supposed to be on a plane today heading home, I did something silly and got the dates wrong.<br />
So, after a nice scenic trip yesterday evening to the airport and back, I get to do it all over again tonight.<br />
Although that was a total pain, I did get to spend another day in Shanghai, and luckily enough, it coincided with the new Apple Store opening in the IFC center over in Pudong.</p>
<p>Overall impression &#8211; this is good!<br />
I spoke with a number of the staff, and talked about the usual issues here (service, service, service&#8230;), and they were all quite understanding, and Apple&#8217;s genuinely trying to improve on things &#8211; hence their own store, and support in Shanghai (finally).</p>
<p>Shanghai has the biggest Genius bar in the world now.  Unfortunately the store is a bit lacking compared to others in Shanghai &#8211; no iPad, no iPhone (other than the official one), but they do carry software and iMac&#8217;s / Laptops in lots of configurations.<br />
I know where my next iMac is coming from <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Downsides of the store &#8211; the moat outside is going to claim lots of victims.  Its so subtle that you miss is &#8211; who&#8217;s idea was that?<br />
We already saw unhappy victims with wet feet while we were leaving.  I expect that to be changed in the near future, or the store will have to provide a shoe drying facility!</p>
<p>I also had the only iPad in the store (and possibly China at that point) that could play flash.   Ok, there were only 2 iPad&#8217;s in the store, but still.. <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Photo&#8217;s of the store on flickr, which I would upload, but China is being finicky again. Grrr<br />
Should be on the sidebar though.  </p>
<p><a href="http://www.flickr.com/photos/sheedl/sets/72157624448891934/">http://www.flickr.com/photos/sheedl/sets/72157624448891934/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/07/apple-store-opening-in-shanghai/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>Home made projector project (using LED lighting)</title>
		<link>http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=home-made-projector-project-using-led-lighting</link>
		<comments>http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/#comments</comments>
		<pubDate>Thu, 10 Jun 2010 15:27:52 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[50w]]></category>
		<category><![CDATA[controller]]></category>
		<category><![CDATA[lcd]]></category>
		<category><![CDATA[led]]></category>
		<category><![CDATA[light]]></category>
		<category><![CDATA[mad scientist]]></category>
		<category><![CDATA[projector]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=543</guid>
		<description><![CDATA[During the research into LCD updating on the T6x IBM&#8217;s, I learned a few new things. One of those was that I had some of the parts lying around the office necessary to make a projector. As my office desk typically looks like a mad scientist uses it, I thought I may as well add [...]]]></description>
			<content:encoded><![CDATA[<p>During the research into LCD updating on the T6x IBM&#8217;s, I learned a few new things.</p>
<p>One of those was that I had some of the parts lying around the office necessary to make a projector.<br />
As my office desk typically looks like a mad scientist uses it, I thought I may as well add some more goodies to fill the missing bits.</p>
<p>First up was an LED light off taobao.  As the 100 watt ones are still a little pricey, I&#8217;m going with a 50w one for testing purposes.<br />
Visitors to the office who still have LED driven holes burned into their retina&#8217;s agree that yes, it is quite bright.</p>
<p>Probably not bright enough for our purposes, but good enough for testing.</p>
<p>Some photos of that here &#8211; </p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0218.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0218-300x200.jpg" alt="" title="The light - it burns, it burns, aaaaaaaarghh." width="300" height="200" class="aligncenter size-medium wp-image-556" /></a></p>
<p>The hokey CPU fan cooler hooked up to the back adds to the effect.</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0208.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0208-300x200.jpg" alt="" title="Thats not an AMD!" width="300" height="200" class="aligncenter size-medium wp-image-547" /></a></p>
<p>The LED comes in a variety of color temperatures, ranging from yellow white, pure white, through to blue white, we chose pure white, as thats closest to what they normally use in projectors.</p>
<p>Projector and fan came to about 400rmb including shipping.  Seller was quite nice to deal with too, and advised us which would be best for the purpose.</p>
<p>Now that our lighting requirements were minimally in place, we looked at the next requirement.</p>
<p>LCD screens.</p>
<p>As the 2 or 3 people that read this blog are aware, I just bought some rather nice QXGA LCD&#8217;s.  These would be quite nice to use for a projector, but, unfortunately, getting hold of controllers for them is a little bit harder than I thought it would be.<br />
I did manage to find some, but the prices are a little high, so I put that on the back burner for now.  I will be looking into that again in the near future though.</p>
<p>First, a little detour onto the subject of LCD&#8217;s.</p>
<p>Essentially LCD&#8217;s are mass produced these days by a small handful of manufacturers, and the controllers for LCD&#8217;s are also mass produced.<br />
Controllers pretty much come in a few different capacities, but essentially they&#8217;re all the same featurewise.<br />
You buy a controller based on the maximum resolution it can handle, then program it for the LCD you have.</p>
<p>Controllers are dirt cheap &#8211; most can be found for 20rmb low end eg SVGA, through to 120rmb for medium end &#8211; eg 1920&#215;1200 /DVI+VGA.<br />
This means that most laptop screens can easily be reused as desktop screens for reasonably cheap prices.</p>
<p>TV&#8217;s are also essentially exactly the same as screens now, so the hardware is exactly the same.<br />
Controllers for TV are usually a little more expensive, but not overly so.  I bought a multi-input (HDMI, VGA, Tuner etc) with USB for 200rmb.<br />
Different chipsets do better jobs at HD, but its very very generic stuff these days.</p>
<p>You need an invertor board for the lighting (if its not an LED based LCD) &#8211; those go for 10-20rmb.<br />
You need a controller card to drive the LCD.  (Most sellers will make you a cable for your specific LCD, and program the controller for a minimal charge)<br />
You need a power supply (typically 12v 3amps+-).<br />
Lastly you need a case.</p>
<p>We gave this a test run with a salvaged a 14&#8243; LCD from a hosed laptop.<br />
We bought a controller board (20rmb), power supply + empty screen casing (130rmb) off taobao.   While it wasn&#8217;t necessarily worth it to do that, we did learn that its fairly easy.</p>
<p>Programming controllers is also pretty straightforward, but I&#8217;ll probably expand on that in another post.</p>
<p>As I wanted an HD capable projector I looked at what the smallest size HD screen (WUXGA) available on the market today is &#8211; that happens to be the Samsung LTN154U1<br />
I got mine for about 500rmb.</p>
<p>Most people will be wondering right now at this point how an LCD screen is going to be used in a projector.</p>
<p>Essentially LCD&#8217;s are transparent &#8211; an LCD screen typically comes sold ready to use.  This means its shipped with lighting built in, plus a reflective back surface.<br />
We&#8217;re going to need to denude the LCD off all that &#8211; I&#8217;m going to have to disassemble the LCD display, and take out all the non-essentials. What I&#8217;ll end up with will be transparent, and fairly delicate.<br />
Hopefully I won&#8217;t break anything when I take the LCD out of the casing, and remove the lighting, backing etc.  Breaking it will be costly!</p>
<p>Next we&#8217;ll need a way to shine our light source through the LCD.<br />
While we have a strong light &#8211; it won&#8217;t be very useful as is, as the light will mostly be concentrated in the center of wherever its pointed at.<br />
So, we need a way to disperse the light in a directed way.</p>
<p>Typically this is done with a Fresnel.  Fresnels are rather cool lens typically made out of plastic.  They magnify or reduce anything passed through them.<br />
We&#8217;ll be using a fresnel in front of the LED light to disperse the light evenly through the LCD.<br />
Once its through the LCD, we&#8217;ll be using another Fresnel to concentrate the light back into a smaller focal area, so that we can throw it through a lens, and see something on a screen.</p>
<p>For a 15.4&#8243; screen, we need a 400&#215;320 sized 330mm Fresnel, and a 500mm Fresnel.<br />
The 330mm (aka our collimator) will be placed in front of the light source, the LCD will be placed 10-15mm in front of that, then finally the 500mm (aka our collector) to concentrate the light + display output into a nice ready to use focal area for our rather expensive triplet lens.<br />
We&#8217;re using a 500mm triplet as the lens, mostly as all the projector websites are using those for 15.4&#8243; screens.</p>
<p>Fresnels were fairly cheap &#8211; 80rmb each or so.  </p>
<p>The lens was rather more expensive.  Ours was close to 600rmb with shipping!<br />
When it arrived, we saw why.  It definitely feels like its worth the money..  Unfortunately ours arrived with a crack from shipping, so we had to send it back.  The replacement should arrive in a day or three.</p>
<p>While I haven&#8217;t setup the fresnels yet in action, I did test out the controller board, and LCD.</p>
<p>Photo&#8217;s below of everything.</p>

<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0197/' title='IMG_0197'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0197-150x150.jpg" class="attachment-thumbnail" alt="IMG_0197" title="IMG_0197" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0200/' title='IMG_0200'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0200-150x150.jpg" class="attachment-thumbnail" alt="IMG_0200" title="IMG_0200" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0207/' title='IMG_0207'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0207-150x150.jpg" class="attachment-thumbnail" alt="IMG_0207" title="IMG_0207" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0208/' title='Thats not an AMD!'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0208-150x150.jpg" class="attachment-thumbnail" alt="Thats not an AMD!" title="Thats not an AMD!" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0209/' title='IMG_0209'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0209-150x150.jpg" class="attachment-thumbnail" alt="IMG_0209" title="IMG_0209" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0210/' title='IMG_0210'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0210-150x150.jpg" class="attachment-thumbnail" alt="IMG_0210" title="IMG_0210" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0211/' title='IMG_0211'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0211-150x150.jpg" class="attachment-thumbnail" alt="IMG_0211" title="IMG_0211" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0212/' title='IMG_0212'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0212-150x150.jpg" class="attachment-thumbnail" alt="IMG_0212" title="IMG_0212" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0214/' title='IMG_0214'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0214-150x150.jpg" class="attachment-thumbnail" alt="IMG_0214" title="IMG_0214" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0215/' title='IMG_0215'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0215-150x150.jpg" class="attachment-thumbnail" alt="IMG_0215" title="IMG_0215" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0216/' title='IMG_0216'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0216-150x150.jpg" class="attachment-thumbnail" alt="IMG_0216" title="IMG_0216" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0217/' title='IMG_0217'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0217-150x150.jpg" class="attachment-thumbnail" alt="IMG_0217" title="IMG_0217" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0218/' title='The light - it burns, it burns, aaaaaaaarghh.'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0218-150x150.jpg" class="attachment-thumbnail" alt="The light - it burns, it burns, aaaaaaaarghh." title="The light - it burns, it burns, aaaaaaaarghh." /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0219/' title='IMG_0219'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0219-150x150.jpg" class="attachment-thumbnail" alt="IMG_0219" title="IMG_0219" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0220/' title='IMG_0220'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0220-150x150.jpg" class="attachment-thumbnail" alt="IMG_0220" title="IMG_0220" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0223/' title='IMG_0223'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0223-150x150.jpg" class="attachment-thumbnail" alt="IMG_0223" title="IMG_0223" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0224/' title='IMG_0224'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0224-150x150.jpg" class="attachment-thumbnail" alt="IMG_0224" title="IMG_0224" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/img_0225/' title='IMG_0225'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/IMG_0225-150x150.jpg" class="attachment-thumbnail" alt="IMG_0225" title="IMG_0225" /></a>
<a href='http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/ghetto-projector-11_zcui6jnaihhi/' title='ghetto projector - 11_zCui6JnAIHHi'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/ghetto-projector-11_zCui6JnAIHHi-150x150.jpg" class="attachment-thumbnail" alt="ghetto projector - 11_zCui6JnAIHHi" title="ghetto projector - 11_zCui6JnAIHHi" /></a>

<p>While I haven&#8217;t built any casing  yet, I&#8217;m fairly confident we should be able to knock something up quickly to house all the parts.<br />
Hopefully ours will be sturdier than this professional build I saw online &#8211; </p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/ghetto-projector-11_zCui6JnAIHHi.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/06/ghetto-projector-11_zCui6JnAIHHi-300x225.jpg" alt="" title="ghetto projector - 11_zCui6JnAIHHi" width="300" height="225" class="aligncenter size-medium wp-image-566" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/06/home-made-projector-project-using-led-lighting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>T60 screen upgrade (they just don&#8217;t make things like they used to&#8230;)</title>
		<link>http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=t60-screen-upgrade-they-just-dont-make-things-like-they-used-to</link>
		<comments>http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/#comments</comments>
		<pubDate>Tue, 18 May 2010 12:59:30 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[Technical Mumbo Jumbo]]></category>
		<category><![CDATA[15" LCD]]></category>
		<category><![CDATA[IBM]]></category>
		<category><![CDATA[QXGA]]></category>
		<category><![CDATA[Replace]]></category>
		<category><![CDATA[T60]]></category>
		<category><![CDATA[T61]]></category>
		<category><![CDATA[Thinkpad]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=521</guid>
		<description><![CDATA[As someone I know was interested in getting a new (old) laptop, I did some trawling of the intertubes, and saw that there were quite a few IBM Thinkpad&#8217;s in nice condition available on Taobao. After checking away the requirements (one of which was not to go down in resolution to the crap they sell [...]]]></description>
			<content:encoded><![CDATA[<p>As someone I know was interested in getting a new (old) laptop, I did some trawling of the intertubes, and saw that there were quite a few IBM Thinkpad&#8217;s in nice condition available on Taobao.</p>
<p>After checking away the requirements (one of which was not to go down in resolution to the crap they sell nowadays), I decided on a T6x series.</p>
<p>A T60 with a 1400&#215;1050 screen was about RMB2500 on Taobao with fairly decent spec&#8217;s &#8211; DVD Writer, Bluetooth, Fingerprint Reader, SATA, Extended Battery.  3 month warranty, with a replacement 7 day swap for another unit.  I sent my staff to go take a look at the shop, they liked, and I was soon the owner of an ex-corporate laptop that looked like it came from Singapore originally (according to the model / software licence sticker on the laptop).  It even came with a legitimate licenced copy of Windows.</p>
<p>As I had ordered one for test purposes to see what the quality was like, I was pleasantly suprised.  The one I received is pretty much in mint condition.  In fact its in such good condition, that I decided I would keep it for myself!</p>
<p><span id="more-521"></span><br />
I&#8217;m justifying it as I need a PC for development work.  Although my collection of Mac&#8217;s are nice, sometimes you still need something with &#8216;old skool&#8217; outputs &#8211; eg Parallel, Serial* for development work.<br />
*No serial onboard but the docking bay has.  </p>
<p>While I was doing the research into what exactly to get, I noticed a small piece in the Thinkpad Wiki where they mentions briefly that the screens on the 15&quot; models can be replaced with higher resolution ones.</p>
<p>This was also something that was brought up on a recent Slashdot post where people mention the lack of good higher resolution screens.</p>
<p>I checked out the model number that they referenced &#8211; IAQX10N, and my favourite online site had sellers.  As I&#8217;m in China, certain things are cheap, and luckily this happened to be one of them.</p>
<p>I ordered a suitable 15&quot; donor screen from Taobao for the princely sum of 800rmb.<br />
The LCD took a while to get here, mostly as it was shipped from Japan.  We ordered on Friday, and it arrived Tuesday afternoon.  </p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/packaging.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/packaging.jpg" alt="" title="packaging" width="640" height="427" class="aligncenter size-full wp-image-533" /></a></p>
<p>This screen is an original IPS IDTech, which is priced insanely well, considering what they used to charge for these!</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/new-lcd-IAQX10N.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/new-lcd-IAQX10N.jpg" alt="" title="new lcd - IAQX10N" width="640" height="427" class="aligncenter size-full wp-image-534" /></a></p>
<p>Although I performed this upgrade on a T60 series, this upgrade can be done on any of the 15&#8243; IBM (non-widescreen models), from the T43p -> T61p (post T61, they went lo-res widescreen, which sucked).  Older Thinkpad laptops, and laptops with 1024&#215;768 resolution also need a replacement LCD cable (which is roughly 100RMB on Taobao).</p>
<p>Removing the old LCD was easy (as IBM engineering is excellent).  </p>
<p>I recommend you prepare by unplugging the power adaptor, and also removing the battery from the laptop, so that you don&#8217;t accidentally turn it on while disassembling it.  Once you&#8217;ve done that, you can start.</p>
<p>First step was to remove the 3 bottom screws on the front.<br />
Those are hidden behind round stickers, so use a small screwdriver, and gently nudge the stickers off.<br />
Once you have those off, unscrew and place the screws / stickers into something suitable for storage (a clean ashtray is ideal).  </p>
<p>Now do the same to the 3 sticker / screws located at the left side of the screen, and the 3 sticker / screws on the right side of the screen.</p>
<p>Put all the stickers and screws into your container.  As all the screws are the same size, we don&#8217;t need to separate them.</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/screws-and-sticker-covers.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/screws-and-sticker-covers.jpg" alt="" title="screws and sticker covers" width="640" height="427" class="aligncenter size-full wp-image-530" /></a></p>
<p>The front cover will still be clipped in, pick a corner, and gently pull away using fingernails or a credit card inbetween the front / back edge. Keep going up until you have one side unclipped, then continue until the whole front is unclipped.  The bottom part of the screen has some double sided tape affixed at the bottom.  If the front doesn&#8217;t want to come off easily, be patient.  Mine took about a minute to take apart (once the screws were off).  Take your time, and don&#8217;t break anything.</p>
<p>Eventually you should have separated the cover from the front.</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/front-facia-removed.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/front-facia-removed.jpg" alt="" title="front facia removed" width="427" height="640" class="aligncenter size-full wp-image-536" /></a></p>
<p>Here&#8217;s what my screen looked like sans cover.</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/My-thinkpad-goes-topless.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/My-thinkpad-goes-topless.jpg" alt="" title="My thinkpad goes topless" width="427" height="640" class="aligncenter size-full wp-image-535" /></a></p>
<p>Once the cover is off, you should be able to slowly push the existing screen downwards towards the keyboard (make sure that you don&#8217;t drop it, use a hand to support it on its way down).<br />
The IBM keylight is attached at the top of the case (connected to the LCD cable), it should pop out of its seat on its own, but if it doesn&#8217;t, carefully unlatch it while you pull the LCD downward.</p>
<p>You should see something similar to this now:</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/lcd-removed.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/lcd-removed.jpg" alt="" title="lcd removed" width="640" height="427" class="aligncenter size-full wp-image-532" /></a></p>
<p>The LCD should be facedown flat on the keyboard by now, so lets unplug the connectors.<br />
There are 2 connectors &#8211; 1 for power, and 1 for the screen.  Lets start with the screen cable.</p>
<p>Peel the plastic covering the back up slightly, and you&#8217;ll see the cable and connector.  In the photo below I&#8217;ve already unplugged the cable.  Pull gently levering side to side to pull the connector out.  In my case it was fairly easy to do.</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/unplugging-the-old-lcd-closer-view.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/unplugging-the-old-lcd-closer-view.jpg" alt="" title="unplugging the old lcd closer view" width="427" height="640" class="aligncenter size-full wp-image-529" /></a></p>
<p>Here&#8217;s a closer look at the connector:</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/unplugging-the-old-lcd.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/unplugging-the-old-lcd.jpg" alt="" title="unplugging the old lcd" width="640" height="427" class="aligncenter size-full wp-image-528" /></a></p>
<p>The bit hanging off the top of the connector is the ThinkLight. (aka the Keyboard light most people don&#8217;t know about!)</p>
<p>The other connector (the power one), should be fairly straightforward &#8211; pull gently, and unplug.<br />
(No photo&#8217;s, as I forgot!).</p>
<p>The LCD should be removable now.</p>
<p>We&#8217;ll also need the side mounts, so unscrew those from the LCD.</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/install-side-mount.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/install-side-mount.jpg" alt="" title="install side mount" width="427" height="640" class="aligncenter size-full wp-image-524" /></a></p>
<p>Place the old LCD somewhere safe face up.  By this point, I&#8217;d unpacked my other LCD, so I placed it into the same packaging that the new one came in &#8211; an antistatic bag, and a boatload of bubble-wrap.</p>
<p>Start off by putting the new LCD facedown on the keyboard in the same orientation as the old LCD.<br />
Plug in the screen connector, and the power connector.<br />
Although the ThinkWiki said I&#8217;d need to bend a cable, my unit fit perfectly. </p>
<p>We&#8217;re ready to test now.<br />
Carefully place the screen faceup, and plug in the power adaptor.</p>
<p>Hopefully you don&#8217;t see any magic smoke, and your Thinkpad makes the appropriate noises.<br />
In my case, I lucked out, and I didn&#8217;t even need to flash the LCD EDID (as per the Wiki).<br />
I booted into my OS (Linux Mint in this instance), and saw a login screen.  Yay!</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing.jpg" alt="" title="testing" width="640" height="427" class="aligncenter size-full wp-image-526" /></a></p>
<p>Note that the screen still has its protective shipping cover on, so looks a little dull.</p>
<p>More test shots below:</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing-2.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing-2.jpg" alt="" title="testing 2" width="427" height="640" class="aligncenter size-full wp-image-523" /></a></p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing-3.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing-3.jpg" alt="" title="testing 3" width="640" height="427" class="aligncenter size-full wp-image-527" /></a></p>
<p>As you can see, the laptop recognizes the resolution &#8211;  both Gizmodo, and Engadget fit nicely side by side, and the control panel shows our 2048 x 1536 QXGA goodness.</p>
<p>Sadly, we now have to shut everything down again.</p>
<p>Unplug the power again, and place the screen face down again.<br />
Carefully screw in the side mounts to both sides of the LCD.  Remember, be gentle.</p>
<p>Put the LCD face up again, and lift into place in the case.  Don&#8217;t force anything, everything goes in cleanly.  You may need to route some of the cabling again &#8211; in my case I had to use a small screwdriver to push the left cabling back into the original positions.  </p>
<p>Also don&#8217;t do what I did, and forget about the Keyboard light.  In the photo below, you&#8217;ll see that although I have the screen installed nicely, I neglected to put the light in the top.  Doh!</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/almost-installed.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/almost-installed.jpg" alt="" title="almost installed" width="640" height="427" class="aligncenter size-full wp-image-525" /></a></p>
<p>The light should fit into the top reasonably easily.  Its a tight fit for the cable to reach, and would probably be easier with 3 hands helping out, but its doable on your own.  Again, take it slowly, and carefully.  If you get frustrated, take a break, and come back to it.</p>
<p>Once you have the LCD in, start by screwing in 1 screw on each side.  You&#8217;ll need to lift the LCD slightly so that the screw holes line up.  Once the first ones are in, the rest are easy.  Do the sides (left, right) first.</p>
<p>We&#8217;re almost done.</p>
<p>Plug in the power again, and do another test run without the front facia, to make a final check.<br />
All good?</p>
<p>Put the side stickers back on.</p>
<p>The front facia clicks onto the front.  Line up the front facia carefully in its original position, and start pressing down.  It should click nicely back into place.  Go around the edges again, and push / click into place.  Pay careful attention to the side cabling.  If any cabling is in the way, use a small screwdriver to reposition the cable out of the way.  Once the front is clicked into place, screw the remaining 3 bottom screws into place.  Go around again, and make doubly sure that the front facia is clipped in 100%.</p>
<p>Slowly push the laptop lid closed, and make sure it all lines up ok.  </p>
<p>From start to finish, mine took about 10 minutes total, so its relatively quick to do the replacement.<br />
If you&#8217;ve never done something like this before, I&#8217;d estimate about 30 minutes max.  Just remember &#8211;  Be calm, go slowly, and be careful.  </p>
<p>I&#8217;m now the proud owner of a laptop with a screen resolution that dates back to&#8230; 2002.<br />
Yes, thats when they started making these screens.</p>
<p>Sadly, its all gone downhill from there,  I&#8217;d love to be using something along the lines of 4096 x 4096 on my 24&#8243; iMac, rather than having a laptop with <strong>better than HD</strong> resolution in a much smaller package.</p>
<p>Here&#8217;s the finished laptop &#8211; </p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/voila.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/voila.jpg" alt="" title="voila!" width="427" height="640" class="aligncenter size-full wp-image-522" /></a></p>
<p>Everything works perfectly, and the alignment / case fit is 100% perfect, which it should be, as IBM made the panels too!</p>
<p>As a non-vendor approved upgrade, this is probably the easiest upgrade I&#8217;ve done on a laptop too.  Usually doing this stuff is fiddly.</p>
<p>Thankfully IBM Thinkpads (+-pre-Lenovo) are engineered properly..</p>
<p>So, after all this I now have a dual core laptop with a QXGA screen ( <a href="http://en.wikipedia.org/wiki/QXGA" rel="nofollow">en.wikipedia.org/wiki/QXGA</a> )</p>
<p>Total cost &#8211; RMB3300</p>
<p>Next step &#8211; upgrade it to a T61 motherboard, so I can install 8G ram&#8230;</p>
<p><strong>References / Further Reading</strong>:<br />
<a href="http://www.thinkwiki.org/wiki/Installing_a_QXGA_display_in_a_R/T60_or_61">http://www.thinkwiki.org/wiki/Installing_a_QXGA_display_in_a_R/T60_or_61</a><br />
<a href="http://forum.fatmanandcircuitgirl.com/forum_posts.asp?TID=590">http://forum.fatmanandcircuitgirl.com/forum_posts.asp?TID=590</a><br />
<a href="http://wiki.keithl.com/index.cgi?QxGa">http://wiki.keithl.com/index.cgi?QxGa</a> &#8211; Flashing EDID (with i2C)<br />
<a href="http://forum.thinkpads.com/viewtopic.php?f=29&#038;t=77733">http://forum.thinkpads.com/viewtopic.php?f=29&#038;t=77733</a></p>
<p>Thanks to Eric Rucker for taking the time to add to the Thinkpad wiki about it (otherwise I&#8217;d never have known!)</p>
<p>More pictures of the entire process below:<br />

<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/voila/' title='voila!'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/voila-150x150.jpg" class="attachment-thumbnail" alt="voila!" title="voila!" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/testing-2/' title='testing 2'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing-2-150x150.jpg" class="attachment-thumbnail" alt="testing 2" title="testing 2" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/install-side-mount/' title='install side mount'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/install-side-mount-150x150.jpg" class="attachment-thumbnail" alt="install side mount" title="install side mount" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/almost-installed/' title='almost installed'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/almost-installed-150x150.jpg" class="attachment-thumbnail" alt="almost installed" title="almost installed" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/testing/' title='testing'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing-150x150.jpg" class="attachment-thumbnail" alt="testing" title="testing" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/testing-3/' title='testing 3'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/testing-3-150x150.jpg" class="attachment-thumbnail" alt="testing 3" title="testing 3" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/unplugging-the-old-lcd/' title='unplugging the old lcd'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/unplugging-the-old-lcd-150x150.jpg" class="attachment-thumbnail" alt="unplugging the old lcd" title="unplugging the old lcd" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/unplugging-the-old-lcd-closer-view/' title='unplugging the old lcd closer view'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/unplugging-the-old-lcd-closer-view-150x150.jpg" class="attachment-thumbnail" alt="unplugging the old lcd closer view" title="unplugging the old lcd closer view" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/screws-and-sticker-covers/' title='screws and sticker covers'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/screws-and-sticker-covers-150x150.jpg" class="attachment-thumbnail" alt="screws and sticker covers" title="screws and sticker covers" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/old-lcd-still-connected/' title='old lcd still connected'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/old-lcd-still-connected-150x150.jpg" class="attachment-thumbnail" alt="old lcd still connected" title="old lcd still connected" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/lcd-removed/' title='lcd removed'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/lcd-removed-150x150.jpg" class="attachment-thumbnail" alt="lcd removed" title="lcd removed" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/packaging/' title='packaging'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/packaging-150x150.jpg" class="attachment-thumbnail" alt="packaging" title="packaging" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/new-lcd-iaqx10n/' title='new lcd - IAQX10N'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/new-lcd-IAQX10N-150x150.jpg" class="attachment-thumbnail" alt="new lcd - IAQX10N" title="new lcd - IAQX10N" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/my-thinkpad-goes-topless/' title='My thinkpad goes topless'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/My-thinkpad-goes-topless-150x150.jpg" class="attachment-thumbnail" alt="My thinkpad goes topless" title="My thinkpad goes topless" /></a>
<a href='http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/front-facia-removed/' title='front facia removed'><img width="150" height="150" src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/front-facia-removed-150x150.jpg" class="attachment-thumbnail" alt="front facia removed" title="front facia removed" /></a>
</p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/05/t60-screen-upgrade-they-just-dont-make-things-like-they-used-to/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>IP Cam Hacking – pt#6</title>
		<link>http://www.computersolutions.cn/blog/2010/05/ip-cam-hacking-%e2%80%93-pt6/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=ip-cam-hacking-%25e2%2580%2593-pt6</link>
		<comments>http://www.computersolutions.cn/blog/2010/05/ip-cam-hacking-%e2%80%93-pt6/#comments</comments>
		<pubDate>Wed, 05 May 2010 16:07:41 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[IP Cam]]></category>
		<category><![CDATA[arm7]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[nc745]]></category>
		<category><![CDATA[nuvoton]]></category>
		<category><![CDATA[uclinux]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=509</guid>
		<description><![CDATA[I&#8217;ve uploaded a zip of my built test image here. I&#8217;ve only included telnetd, and ftpd, as the sshd binary is very large, and won&#8217;t fit into our rom image space! If someone is willing to test, feel free. Test Rom with FTPD and TELNETD binaries added This rom is 700k+- vs the normal 550kb. [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve uploaded a zip of my built test image here.  I&#8217;ve only included telnetd, and ftpd, as the sshd binary is very large, and won&#8217;t fit into our rom image space!</p>
<p>If someone is willing to test, feel free.</p>
<p><a href='http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/testrom.zip'>Test Rom with FTPD and TELNETD binaries added</a></p>
<p>This rom is 700k+- vs the normal 550kb. So this may / may not overwrite the web ui.</p>
<p>As China&#8217;s firewall is being particularly obnoxious this week as to what I can view on the web, I can&#8217;t actually get to the info I need to see where they typically write the UI to in rom.</p>
<p>In theory, we should be able to write to the same base address via the boot loader.</p>
<p>The original rom is written here -</p>
<p>Image: 6 name:romfs.img base:0×7F0E0000 size:0×0008D000 exec:0×7F0E0000 -a</p>
<p>And I&#8217;m pretty sure that the UI gets written somewhere after this, and not as a separate image.  I&#8217;d have to run Windows and a sniffer to test this though (using their firmware update software).</p>
<p>Our boot logs show that linux blkmem driver is set to view the whole area from 0×7F0E0000 through to 0x7F16D3FF, so we should easily have 200kb to waste^Hplay with.</p>
<p>From my boot logs:</p>
<p>Blkmem 1 disk images:<br />
0: 7F0E0000-7F16D3FF [VIRTUAL 7F0E0000-7F16D3FF] (RO)</p>
<p>Obstensibly, this should be a matter of going to the bootloader over serial, then uploading our img file.<br />
Suggest rename from testrom.img to romfs.img to be consistent.</p>
<p>It should be something like this:</p>
<p>bootloader > del 6<br />
(delete the current romfs.img)</p>
<p>bootloader > fx 6 romfs.img 0x7f0e0000 0x7f0e0000 -a<br />
Waiting for download<br />
Press Ctrl-x to cancel &#8230;  (while it waits, you have to select Transfer > Send File in Hyperterminal menu, choose the Xmodem protocol and select my rom image)<br />
CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC<br />
Flash programming &#8230;</p>
<p>bootloader> boot</p>
<p>Then see what happens in the logs.</p>
<p>It should boot, then attempt to run telnetd and ftpd.<br />
That probably WON&#8217;T work just yet, as they&#8217;ll complain about missing /etc/ config files. </p>
<p>You might also be missing the UI (as I think this gets written somewhere after our romfs.img in flash)</p>
<p>Send me the serial logs in the comments, and I can fix that up, and repackage.</p>
<p>I also know why the alleged clones (NB they&#8217;re not f..king clones sigh, they&#8217;re all made by 1 manufacturer here for different people, including FOSCAM) don&#8217;t work.  The linux.bin for older firmware is set to boot from  0x7f0D0000  as opposed to  0x7f0e0000, so image 6 and 7 both need to be reflashed.</p>
<p>Also of note is that the newer units have gone cheaper, and use 2M flash, previous units had 4M.<br />
uCLinux reports 8M, but its not talking about Flash, just RAM</p>
<p>Be prepared to brick (not completely, as we have a bootloader, and can reflash the original firmware) if it doesn&#8217;t work.</p>
<p>If my rom above doesn&#8217;t work initially for you, try flashing this <a href='http://www.computersolutions.cn/blog/wp-content/uploads/2010/05/linux.zip'>linux.zip</a> before reverting, and see if that helps it boot.</p>
<p>eg<br />
<code><br />
bootloader> del 7</p>
<p>bootloader> fx 7 linux.zip 0x7f020000 0x8000 -acxz<br />
Waiting for download<br />
Press Ctrl-x to cancel ...  (while it waits, you have to select Transfer > Send File in Hyperterminal menu, choose the Xmodem protocol and select my linux.zip)<br />
CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC<br />
Flash programming ...</p>
<p>bootloader> fx 6 romfs.img 0x7f0e0000 0x7f0e0000 -a<br />
Waiting for download<br />
Press Ctrl-x to cancel ...  (while it waits, you have to select Transfer > Send File in Hyperterminal menu, choose the Xmodem protocol and select my rom image)<br />
CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC<br />
Flash programming ...<br />
</code></p>
<p>Why aren&#8217;t I doing this?</p>
<p>Mostly as I don&#8217;t currently have a good serial connection, I&#8217;m waiting on headers.  Currently I have to hold the serial ports onto the board with fingers, and thats less than reliable!</p>
<p>I should get around to fixing that soonish though, I&#8217;m interested in testing this myself&#8230;</p>
<blockquote><p>I&#8217;d also appreciate the French contingent adding some info. I&#8217;m particularly interested in paillassou&#8217;s board photos, and any other firmware people have found for these so I can compare.</p></blockquote>
<p> I can&#8217;t get to Picasa, GadgetVictims, IrishJesus now in China. Grrr.</p>
<p>Yes, I know, use a VPN or proxy&#8230;  Unfortunately what we do precludes doing so, as I&#8217;d probably get told off by our beloved government here, and thats not worth the risk&#8230;</p>
<p>Comments please.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/05/ip-cam-hacking-%e2%80%93-pt6/feed/</wfw:commentRss>
		<slash:comments>64</slash:comments>
		</item>
		<item>
		<title>IP Cam Hacking &#8211; pt#5</title>
		<link>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt5/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=ip-cam-hacking-pt5</link>
		<comments>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt5/#comments</comments>
		<pubDate>Fri, 30 Apr 2010 08:04:11 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[arm7]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[nc745]]></category>
		<category><![CDATA[nuvoton]]></category>
		<category><![CDATA[uclinux]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=489</guid>
		<description><![CDATA[So far in this series, we&#8217;ve learnt a few things. First, is that this hardware is quite nice for hacking purposes, as they&#8217;ve left the uBoot in a nice state, and have easily accessible debug ports. Second is that doing this kind of thing isn&#8217;t really that complicated, and can be quite fun. We&#8217;re pretty [...]]]></description>
			<content:encoded><![CDATA[<p>So far in this series, we&#8217;ve learnt a few things.<br />
First, is that this hardware is quite nice for hacking purposes, as they&#8217;ve left the uBoot in a nice state, and have easily accessible debug ports.<br />
Second is that doing this kind of thing isn&#8217;t really that complicated, and can be quite fun.</p>
<p>We&#8217;re pretty much ready to start doing our own coding, as we know how the images are packed, and we can use the uBoot to either flash onl the romfs on or own, or alternately roll a complete linux + romfs binary image.</p>
<p>For that, we&#8217;ll need to be ready to roll up our sleeves, and actually do some development (finally!).</p>
<p>Getting a development environment setup is our next step, as we&#8217;re ready to test out adding binaries.</p>
<p>I&#8217;m using Debian, but most Linux environments should be similar.  OSX is BSD based, and more of a pain due to Apple not putting everything needed in the normal places, so I&#8217;m doing this in a VM on my Macbook under Debian.</p>
<p>Go grab a copy of &#8220;NUC700 Series MCU uCLinux BSP.zip&#8221; from here <a href="http://www.metavert.com/public/NO-SUPPORT/">http://www.metavert.com/public/NO-SUPPORT/</a></p>
<p>Setup a VM for Debian (not going to cover that) or install Debian or similar.</p>
<p>Copy the zip file to /home in the OS you use.</p>
<p><code>cd /home<br />
mkdir N745<br />
cd N745<br />
unzip ../NUC700\ Series\ MCU\ uCLinux\ BSP.zip</code></p>
<p>You should now see something like this:</p>
<p><code>:/home/N745/NUC700 Series MCU uCLinux BSP# ls -al<br />
total 68<br />
drwxr-xr-x 6 root root  4096 2009-05-15 20:02 .<br />
drwxr-xr-x 3 root root  4096 2010-04-30 02:23 ..<br />
drwxr-xr-x 3 root root  4096 2009-05-15 20:06 bootloader<br />
drwxr-xr-x 2 root root  4096 2009-05-15 20:03 bsp<br />
drwxr-xr-x 2 root root  4096 2009-05-15 20:02 doc<br />
drwxr-xr-x 4 root root  4096 2009-05-15 20:02 mkrom<br />
-r--r--r-- 1 root root 44632 2009-03-27 11:49 NUC700 uClinux BSP Release Note.pdf<br />
debian:/home/N745/NUC700 Series MCU uCLinux BSP# </code></p>
<p>Unfortunately the build *really* doesn&#8217;t like long filenames, so lets move all this to the N745 folder, and get rid of the annoyingly named folder.</p>
<p><code><br />
/home/N745/NUC700 Series MCU uCLinux BSP# mv * ..<br />
/home/N745/# cd ..<br />
/home/N745/# rm -r NUC700\ Series\ MCU\ uCLinux\ BSP/<br />
</code></p>
<p>We still need to unzip the BSP, as its compressed, so go into bsp</p>
<p><code><br />
/home/N745/# cd bsp<br />
/home/N745/bsp# tar -xzvf NUC700BSP.tar.gz<br />
NUC700BSP/<br />
NUC700BSP/arm_tools.tar.gz<br />
NUC700BSP/install.sh<br />
NUC700BSP/arm_tools_3.3.tar.gz<br />
NUC700BSP/build.tar.gz<br />
NUC700BSP/applications.tar.gz<br />
NUC700BSP/uClinux-dist.tar.gz<br />
</code></p>
<p>Yay, yet another bloody subdirectory.  Sigh.</p>
<p><code><br />
/home/N745/bsp# cd NUC700BSP<br />
debian:/home/N745/bsp/NUC700BSP# ls -al<br />
total 183300<br />
drwxr-xr-x 2 shanghaiguide shanghaiguide     4096 2009-03-26 22:38 .<br />
drwxr-xr-x 3 root          root              4096 2010-04-30 02:29 ..<br />
-rw-r--r-- 1 shanghaiguide shanghaiguide 29521418 2009-03-26 21:55 applications.tar.gz<br />
-rw-r--r-- 1 shanghaiguide shanghaiguide 43742203 2009-03-26 21:22 arm_tools_3.3.tar.gz<br />
-rw-r--r-- 1 shanghaiguide shanghaiguide 36108739 2009-03-26 21:11 arm_tools.tar.gz<br />
-rw-r--r-- 1 shanghaiguide shanghaiguide  5643452 2009-03-26 21:24 build.tar.gz<br />
-rwxr--r-- 1 shanghaiguide shanghaiguide     4370 2009-03-26 22:31 install.sh<br />
-rw-r--r-- 1 shanghaiguide shanghaiguide 72439431 2009-03-26 20:53 uClinux-dist.tar.gz<br />
debian:/home/N745/bsp/NUC700BSP#<br />
</code></p>
<p>Run the install &#8211; I&#8217;ve decided to install the whole shebang to /home/N745</p>
<blockquote><p>Note &#8211; The observant amongst you will notice I&#8217;m running this as root.<br />
This is <strong>NOT</strong> recommended.  I&#8217;m running under a VM solely created to play with this, so I don&#8217;t really care if I break it (as I can roll back to the initial install image fairly easy in vmware).  Don&#8217;t do this yourselves (unless you want to break things). </p></blockquote>
<p><code><br />
debian:/home/N745/bsp/NUC700BSP# ./install.sh<br />
firstly install arm_tools.tar.gz -->/usr/local/<br />
wait for a while<br />
successfully finished installing arm_tools.tar.gz<br />
now begin to install build.tar.gz,applications.tar.gz and uClinux-dist.tar.gz<br />
Please enter your absolute path for installing build.tar.gz, applications.tar.gz and uClinux-dist.tar.gz:<br />
/home/N745<br />
/home/N745 has existed<br />
please wait for a while, it will take some time<br />
whole installation finished successfully!<br />
debian:/home/N745/bsp/NUC700BSP#<br />
</code></p>
<p>We finally have our build environment unzipped, and its sitting in nuc700-uClinux.</p>
<p><code>debian:/home/N745# cd nuc700-uClinux/<br />
debian:/home/N745/nuc700-uClinux# ls -al<br />
total 24<br />
drwxr-xr-x  6 root root 4096 2010-04-30 02:31 .<br />
drwxr-xr-x  7 root root 4096 2010-04-30 02:31 ..<br />
drwxr-xr-x  7 root root 4096 2009-03-25 00:44 applications<br />
drwxr-xr-x  2 root root 4096 2009-03-26 21:23 image<br />
drwxr-xr-x 12 root root 4096 2009-03-26 04:54 romdisk<br />
drwxr-xr-x 10 root root 4096 2009-03-26 06:50 uClinux-dist<br />
debian:/home/N745/nuc700-uClinux# </code></p>
<p>uClinux-dist has the default binaries we want, plus we need to configure the kernel, so lets visit there first (the more adventurous can look at the other folders)</p>
<p><code><br />
debian:/home/N745/nuc700-uClinux# cd uClinux-dist/<br />
debian:/home/N745/nuc700-uClinux/uClinux-dist# ls -al<br />
total 84<br />
drwxr-xr-x  10 root root  4096 2009-03-26 06:50 .<br />
drwxr-xr-x   6 root root  4096 2010-04-30 02:31 ..<br />
drwxr-xr-x   2 root root  4096 2009-01-22 23:27 bin<br />
drwxr-xr-x   3 root root  4096 2009-03-26 06:50 config<br />
-rw-r--r--   1 root root 18007 2009-01-22 23:29 COPYING<br />
drwxr-xr-x   3 root root  4096 2009-01-22 23:27 Documentation<br />
drwxr-xr-x  11 root root  4096 2009-01-22 23:29 freeswan<br />
drwxr-xr-x   5 root root  4096 2009-01-22 23:29 lib<br />
drwxr-xr-x  15 root root  4096 2009-03-26 06:50 linux-2.4.x<br />
-rw-r--r--   1 root root  3228 2009-01-22 23:28 MAINTAINERS<br />
-rw-r--r--   1 root root  7977 2009-01-22 23:27 Makefile<br />
-rw-r--r--   1 root root  4935 2009-01-22 23:29 README<br />
-rw-r--r--   1 root root  1654 2009-01-22 23:29 SOURCE<br />
drwxr-xr-x 158 root root  4096 2009-01-22 23:28 user<br />
drwxr-xr-x   4 root root  4096 2009-03-12 03:54 vendors<br />
debian:/home/N745/nuc700-uClinux/uClinux-dist#<br />
</code></p>
<p>Looks like it should be fairly easy, right?<br />
Wrong.</p>
<p>The default build doesn&#8217;t work.   Why would it be that easy.</p>
<p>You&#8217;ll end up with issues like:</p>
<blockquote><p>entry-armv.S:782: Error: Internal_relocation (type 210) not fixed up<br />
(OFFSET_IMM)<br />
entry-armv.S:784: Error: Internal_relocation (type 208) not fixed up<br />
(IMMEDIATE)
</p></blockquote>
<p>So, we need to make sure we start off fresh.<br />
Also, note that we&#8217;re building for an N745 cpu, so we&#8217;ll need to configure that at the make config stage.<br />
Lastly, and <strong>EXTREMELY</strong> important, is that we&#8217;ll need to put our required tools in the path.</p>
<p><strong>DO NOT FORGET TO DO THIS</strong><br />
sample PATH below:</p>
<p>PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/arm_tools/bin</p>
<p><code><br />
debian:/home/N745/nuc700-uClinux/uClinux-dist# PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/arm_tools/bin</p>
<p>debian:/home/N745/nuc700-uClinux/uClinux-dist#make clean</p>
<blockquote><p>Now we have a choice - Recommend use make xconfig if possible.<br />
You need to  have a GUI, and have tk installed.  (apt-get install tk)<br />
Otherwise run make config, and run through the tediously large amount of questions</p></blockquote>
<p><strong>OPTION#preferred</strong></p>
<p>debian:/home/N745/nuc700-uClinux/uClinux-dist#make xconfig     </p>
<p><strong>OPTION#not recommended</strong></p>
<p>debian:/home/N745/nuc700-uClinux/uClinux-dist# make config<br />
config/mkconfig > config.in<br />
#<br />
# No defaults found<br />
#<br />
*<br />
* Target Platform Selection<br />
*<br />
*<br />
* Choose a Vendor/Product combination.<br />
*<br />
Vendor/Product (nuvoton/nuc710, nuvoton/nuc740, nuvoton/nuc745) [nuvoton/nuc710] (NEW) nuvoton/nuc745</p>
<p>[For the rest, I used the defaults (except for the Network Tools questions, which I said Y to all)]</p>
<blockquote><p>Continue here from whatever menu (x)config you used.</p></blockquote>
<p>debian:/home/N745/nuc700-uClinux/uClinux-dist#make oldconfig</p>
<p>[Needed, or compile doesn't work]</p>
<p>debian:/home/N745/nuc700-uClinux/uClinux-dist#make dep</p>
<p>[A gazillion pages of info later, we have a build environment!]<br />
</code></p>
<p>We&#8217;re finally ready to use our weapon of mass destruction.</p>
<p><code><br />
debian:/home/N745/nuc700-uClinux/uClinux-dist#make<br />
...</p>
<p></code></p>
<p>It should compile without issue.  </p>
<p>Next step is to mount our created rom image, and copy the binaries off, or just go to the compiled folders, and get the binaries.</p>
<p>I&#8217;ve done this step already, and have a zip file of a few useful files ready.</p>
<p>-rwxr-xr-x  1 root root  110888 2010-04-30 03:50 ftpd<br />
-rwxr-xr-x  1 root root   55164 2010-04-30 03:52 ping<br />
-rwxr-xr-x  1 root root 1201904 2010-04-30 03:51 ssh<br />
-rwxr-xr-x  1 root root 1219864 2010-04-30 03:51 sshd<br />
-rwxr-xr-x  1 root root  118004 2010-04-30 03:45 telnet<br />
-rwxr-xr-x  1 root root   45460 2010-04-30 03:45 telnetd</p>
<p> file *<br />
ftpd:    BFLT executable &#8211; version 4 ram<br />
ping:    BFLT executable &#8211; version 4 ram<br />
ssh:     BFLT executable &#8211; version 4 ram<br />
sshd:    BFLT executable &#8211; version 4 ram<br />
telnet:  BFLT executable &#8211; version 4 ram<br />
telnetd: BFLT executable &#8211; version 4 ram</p>
<p>Download that here &#8211; <a href='http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/arm7-nettools.zip'>arm7-nettools</a></p>
<p>All we need to do now is mount our romfs image, unzip the arm7-nettools.zip, copy the arm7 bFLT binaries over to bin, add telnetd, sshd, and  ftpd to our /bin/init, and rebuild by running genromfs on our filesystem.</p>
<p>We can then finally flash our new romfs, and test it out.</p>
<blockquote><p>
Don&#8217;t forget that romfs is a read only file system, so we can&#8217;t modify it by mounting it.  We need to mount, copying everything to elsewhere, do our required bits and pieces, then rebuild.</p>
<p>eg</p>
<p>mount -o loop -t romfs still_unsure.img /mnt/test -r</p>
<p>mkdir /mnt/new<br />
cd /mnt<br />
rsync -arv /mnt/test/ new<br />
cd new/bin<br />
wget http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/arm7-nettools.zip<br />
unzip arm7-nettools.zip<br />
rm arm7-nettools.zip</p>
<p>[We need to also edit init]<br />
pico init</p>
<p>Add </p>
<p>sshd&#038;<br />
telnetd&#038;<br />
ftpd&#038;</p>
<p>eg &#8211;<br />
cat init<br />
mount -t proc none /proc<br />
mount -t ramfs none /usr<br />
mount -t ramfs none /swap<br />
mount -t ramfs none /var/run<br />
mount -t ramfs none /etc<br />
mount -t ramfs none /flash<br />
mount -t ramfs none /home<br />
camera&#038;<br />
sshd&#038;<br />
telnetd&#038;<br />
ftpd&#038;<br />
sh</p>
<p>Change to the next directory up, and lets run genromfs</p>
<p> genromfs -d new -f testrom.img<br />
debian:/mnt# ls testrom.img<br />
testrom.img<br />
debian:/mnt# ls -al testrom.img<br />
-rw-r&#8211;r&#8211; 1 root root 3329024 2010-04-30 04:18 testrom.img</p>
<p>In theory, this should be usable (famous last words!).
</p></blockquote>
<p>Unfortunately, I can&#8217;t try testing on that at home, as all the equipment is at the office, but that should be fairly easy.</p>
<p>Probably also some small config issues to sort out, as ftpd, telnetd and sshd will probably choke without their related /etc/whatever config files needed, but we can sort that out via serial on the debug ports.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt5/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>IP Cam Hacking &#8211; pt#4</title>
		<link>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt4/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=ip-cam-hacking-pt4</link>
		<comments>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt4/#comments</comments>
		<pubDate>Thu, 29 Apr 2010 19:57:14 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[IP Cam]]></category>
		<category><![CDATA[Technical Mumbo Jumbo]]></category>
		<category><![CDATA[bflt]]></category>
		<category><![CDATA[bneg]]></category>
		<category><![CDATA[firmware]]></category>
		<category><![CDATA[foscam]]></category>
		<category><![CDATA[ipcam]]></category>
		<category><![CDATA[linux.bin]]></category>
		<category><![CDATA[pkzip]]></category>
		<category><![CDATA[uclinix]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=477</guid>
		<description><![CDATA[Spent a while checking out the different binaries available for the different OEM versions. Some interesting things I&#8217;ve found. If I take a look at a sample kernel &#8211; eg lr_cmos_11_14_1_46.bin ls -al lr_cmos_11_14_1_46.bin -rw-r--r-- 1 lawrence staff 1350539 Mar 15 13:47 lr_cmos_11_14_1_46.bin Our file size for the file i have is 1350539 bytes. A [...]]]></description>
			<content:encoded><![CDATA[<p>Spent a while checking out the different binaries available for the different OEM versions.<br />
Some interesting things I&#8217;ve found.</p>
<p>If I take a look at a sample kernel &#8211; eg<br />
lr_cmos_11_14_1_46.bin</p>
<p><code> ls -al lr_cmos_11_14_1_46.bin<br />
-rw-r--r--  1 lawrence  staff  1350539 Mar 15 13:47 lr_cmos_11_14_1_46.bin<br />
</code></p>
<p>Our file size for the file i have is 1350539 bytes.</p>
<p>A hexdump of the header shows:</p>
<p>00000000  42 4e 45 47 01 00 00 00  01 00 00 00 77 cb 0b 00  |BNEG&#8230;&#8230;..w&#8230;|<br />
00000010  00 d0 08 00 50 4b 03 04  14 00 00 00 08 00 3a 2e  |&#8230;.PK&#8230;&#8230;..:.|<br />
00000020  87 3b 3b e7 b8 16 03 cb  0b 00 bc d9 18 00 09 00  |.;;&#8230;&#8230;&#8230;&#8230;.|</p>
<p>PK is the standard file header for Zip compression (as Zip was invented by Phil Katz)<br />
Zip fingerprint in hex is &#8211; 0x04034b50, which matches nicely in our second line &#8211; 50 4b 03 04</p>
<p>On the offchance it contained a zip file, I tried unzipping from the start of the PK.</p>
<p>We can totally misuse dd to write from an offset of 20 bytes to a test.zip file as follows:</p>
<p><code><br />
lawrence$ dd if=lr_cmos_11_14_1_46.bin of=test.zip skip=0x14 bs=1 </p>
<p>(check I actually did that right)<br />
lawrence$ hexdump -C test.zip  |more<br />
00000000  50 4b 03 04 14 00 00 00  08 00 3a 2e 87 3b 3b e7  |PK........:..;;.|<br />
00000010  b8 16 03 cb 0b 00 bc d9  18 00 09 00 00 00 6c 69  |..............li|</p>
<p></code></p>
<p>Unfortunately this didn&#8217;t unzip.</p>
<p>However&#8230; </p>
<p><code>zipinfo test.zip<br />
Archive:  test.zip   1350519 bytes   1 file<br />
-rw-------  2.0 fat  1628604 b- defN  7-Dec-09 05:49 linux.bin<br />
1 file, 1628604 bytes uncompressed, 772867 bytes compressed:  52.5%</code></p>
<p>Says there is a valid zip file there, so we&#8217;re getting somewhere.  It should be something like 772867 bytes + whatever Zip header / footer file bits in size.</p>
<p>If we take a look at the Zip file format, it says that the end of directory (aka end of zip file) marker is 0x06054b50</p>
<p><code>ZIP end of central directory record </p>
<p>Offset 	Bytes 	Description[4]<br />
 0 	4 	End of central directory signature = 0x06054b50<br />
 4 	2 	Number of this disk<br />
 6 	2 	Disk where central directory starts<br />
 8 	2 	Number of central directory records on this disk<br />
10 	2 	Total number of central directory records<br />
12 	4 	Size of central directory (bytes)<br />
16 	4 	Offset of start of central directory, relative to start of archive<br />
20 	2 	ZIP file comment length (n)<br />
22 	n 	ZIP file comment</code></p>
<p>If we search the file for that, we get:<br />
000bcb70  78 2e 62 69 6e 50 4b 05  06 00 00 00 00 01 00 01  |x.binPK&#8230;&#8230;&#8230;|</p>
<p>So, from our Start PK 03 04 through to PK 05 06 we&#8217;re at position 0&#215;14 through 0x0bcb79</p>
<p>If we write that out now &#8211;<br />
dd if=lr_cmos_11_14_1_46.bin of=test.zip skip=0&#215;14 bs=1 count=0x0bcb79</p>
<p>Then try unzip test.zip &#8211; we have a winner!</p>
<p><code>lawrence$ unzip test.zip<br />
Archive:  test.zip<br />
  inflating: linux.bin<br />
lawrence$ ls -al test.zip<br />
-rw-r--r--  1 lawrence  staff  772985 Apr 30 03:28 test.zip<br />
lawrence$ ls -al linux.bin<br />
-rw-------@ 1 lawrence  staff  1628604 Dec  7 05:49 linux.bin<br />
</code></p>
<p>So, we know that the file has a header, then a zip file (which uncompresses to linux.bin, and has our linux binary), then more data.</p>
<p>If we take a look at what follows &#8211; ie the rest of the data in the original file after the end of the zip, it doesn&#8217;t look compressed</p>
<p>000bcb79  00 00 00 00 01 00 01 00  37 00 00 00 2a cb 0b 00  |&#8230;&#8230;..7&#8230;*&#8230;|<br />
000bcb89  00 00 2d 72 6f 6d 31 66  73 2d 00 08 cf a0 98 16  |..-rom1fs-&#8230;&#8230;|<br />
000bcb99  76 dd 72 6f 6d 20 34 62  31 63 62 36 38 66 00 00  |v.rom 4b1cb68f..|<br />
000bcba9  00 00 00 00 00 49 00 00  00 20 00 00 00 00 d1 ff  |&#8230;..I&#8230; &#8230;&#8230;|<br />
000bcbb9  ff 97 2e 00 00 00 00 00  00 00 00 00 00 00 00 00  |&#8230;&#8230;&#8230;&#8230;&#8230;.|<br />
000bcbc9  00 00 00 00 00 60 00 00  00 20 00 00 00 00 d1 d1  |&#8230;..`&#8230; &#8230;&#8230;|<br />
000bcbd9  ff 80 2e 2e 00 00 00 00  00 00 00 00 00 00 00 00  |&#8230;&#8230;&#8230;&#8230;&#8230;.|<br />
000bcbe9  00 00 00 00 00 c9 00 00  00 80 00 00 00 00 8c 88  |&#8230;&#8230;&#8230;&#8230;&#8230;.|<br />
000bcbf9  9d 47 73 77 61 70 00 00  00 00 00 00 00 00 00 00  |.Gswap&#8230;&#8230;&#8230;.|</p>
<p>&#8230;</p>
<p>000bd969  50 7d 64 68 63 70 63 00  00 00 00 00 00 00 00 00  |P}dhcpc&#8230;&#8230;&#8230;|<br />
000bd979  00 00 62 46 4c 54 00 00  00 04 00 00 00 40 00 01  |..bFLT&#8230;&#8230;.@..|<br />
000bd989  11 70 00 01 37 60 00 01  50 e8 00 00 28 00 00 01  |.p..7`..P&#8230;(&#8230;|<br />
000bd999  37 60 00 00 02 b5 00 00  00 05 00 00 00 00 00 00  |7`&#8230;&#8230;&#8230;&#8230;..|<br />
000bd9a9  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |&#8230;&#8230;&#8230;&#8230;&#8230;.|<br />
000bd9b9  00 00 1f 8b 08 00 f4 6b  45 3f 02 03 dc 5b 0f 70  |&#8230;&#8230;.kE?&#8230;[.p|<br />
000bd9c9  14 d7 79 7f bb 77 a7 bf  07 9c fe f0 c7 48 a0 95  |..y..w.......H..|<br />
000bd9d9  50 88 5c 23 b3 02 19 64  23 e0 84 30 76 72 b8 9c  |P.\#...d#..0vr..|<br />
000bd9e9  31 50 6c 2b 58 06 d7 25  84 d6 ea 80 6d 02 8c 7d  |1Pl+X..%....m..}|<br />
000bd9f9  48 02 64 17 b0 00 91 12  17 fb b6 29 ed 60 86 c6  |H.d........).`..|<br />
000bda09  4c aa 74 34 0e 71 0e 90  03 d3 d2 54 fc 51 87 30  |L.t4.q.....T.Q.0|</p>
<p>In fact it looks like more files...</p>
<p>bFLT is our flat ELF header..., and the other bits in-between look suspiciously like more files, and folders.<br />
So, we probably have a filesystem in there.</p>
<p>Its late, and thats all for today, but it looks like we might even get to play around with both the linux image and the web UI image.</p>
<p>Just had another thought though - if you recall, our romfs size was  0x0008D000</p>
<p>Image: 6 name:romfs.img base:0x7F0E0000 size:0x0008D000 exec:0x7F0E0000 -a</p>
<p>What do we see here - in our header?   00000010 00 d0 08 00 </p>
<p><code><br />
00000000 42 4e 45 47 01 00 00 00 01 00 00 00 77 cb 0b 00 |BNEG……..w…|<br />
00000010 00 d0 08 00 50 4b 03 04 14 00 00 00 08 00 3a 2e |….PK……..:.|<br />
</code></p>
<p>Seem to have a match, no?  0x 08 d0 00<br />
I'm going to bet that our 0x 00 0b cb 77 also has some meaning too in our header 20 bytes,  especially as the linux.bin zip file size is close to that at 0x00 0b cb 79.</p>
<p>Its highly probable I've miscounted something with the offset, and thats going to turn out to be the zip file size.</p>
<p>Now I've gotten this far, I'm too excited to go to sleep (its 4am here now!)</p>
<p>Lets try the filesystem from where we left off (aka from 0x0bcb79)<br />
dd if=lr_cmos_11_14_1_46.bin of=unsure_what_filesystem.img skip=0x0bcb79 bs=1 </p>
<p> mount -r unsure_what_filesystem.img<br />
mount: unsure_what_filesystem.img: unknown special file or file system.</p>
<p>Nope.</p>
<p>Kyle's blog comment has this gem in </p>
<blockquote><p>however the ‘-romfs-’ tag is offset by 0×14</p>
<p>so I used the line</p>
<p>fx 6 romfs.img 0x7f0a0000 0x7f0a0014 -a</p>
<p>the system then rebooted correctly…”</p></blockquote>
<p>Lets use that as the start.</p>
<p>hexdump -C unsure_what_filesystem.img |more<br />
00000000  00 00 00 00 01 00 01 00  37 00 00 00 2a cb 0b 00  |........7...*...|<br />
00000010  00 00 2d 72 6f 6d 31 66  73 2d 00 08 cf a0 98 16  |..-rom1fs-......|<br />
00000020  76 dd 72 6f 6d 20 34 62  31 63 62 36 38 66 00 00  |v.rom 4b1cb68f..|</p>
<p>-rom1fs- starts at position 0x12 [which is another indicator that I'm off by 2 bytes somewhere - as they mention 0x14 bytes, and the 12bytes prefix I have prior to the -rom1fs- are going to be from our second file header, I'll bet...<br />
 0x0bcb79 - 2 = 0x0bcb77, which is what the previous header said, so that really makes me think thats the filesize now! </p>
<p>Our ROMFS works out to  be 577 536 bytes, which is 0x8D000, which is also what the boot loader said, so getting a lot of good confirmation on these figures!]</p>
<p>Write that out to another file:<br />
dd if=unsure_what_filesystem.img of=still_unsure.img skip=0&#215;12 bs=1 </p>
<p>Still doesn&#8217;t mount on my Mac, however, some more googling for rom1fs uclinux got me here</p>
<p>http://romfs.sourceforge.net/</p>
<p>Which specifically mentions &#8211; </p>
<blockquote><p>Embedded projects using romfs</p>
<p>uClinux, the microcontroller Linux, is a port of the kernel, and selected user-space programs to capable, embedded processors, like some &#8220;smaller&#8221; Motorola m68k, and ARM systems. </p></blockquote>
<p>ROMFS looks like:</p>
<p>offset      content<br />
        +&#8212;+&#8212;+&#8212;+&#8212;+<br />
  0     |  &#8211;  |  r  |  o  | m  |  \<br />
        +&#8212;+&#8212;+&#8212;+&#8212;+    The ASCII representation of those bytes<br />
  4     |  1  |  f  |  s  |  &#8211;  |  /    (i.e. &#8220;-rom1fs-&#8221;)<br />
        +&#8212;+&#8212;+&#8212;+&#8212;+<br />
  8     |     full size       |    The number of accessible bytes in this fs.<br />
        +&#8212;+&#8212;+&#8212;+&#8212;+<br />
 12     |    checksum   |       The checksum of the FIRST 512 BYTES.<br />
        +&#8212;+&#8212;+&#8212;+&#8212;+<br />
 16     |  volume name     |    The zero terminated name of the volume,<br />
        :               :       padded to 16 byte boundary.<br />
        +&#8212;+&#8212;+&#8212;+&#8212;+<br />
 xx     |     file      |<br />
        :    headers    :</p>
<p>struct romfs_super_block<br />
{</p>
<p>__u32 word0;</p>
<p>__u32 word1;</p>
<p>__u32 size;</p>
<p>__u32 checksum;</p>
<p>char name[0];        /* volume name */</p>
<p>};</p>
<p>Which looks to be a *very* good match for what that header has!<br />
So, its in ROMFS format from the -rom1fs- start header.</p>
<p>(Mostly from here &#8211; <a href="http://zhwen.org/?p=articles/romfs">http://zhwen.org/?p=articles/romfs</a>) </p>
<p>Unfortunately my OSX box appears to be missing romfs support, so I can&#8217;t check it without going back to the office.</p>
<p>mount -o loop -t romfs  still_unsure.img /mnt<br />
mount: exec /System/Library/Filesystems/romfs.fs/Contents/Resources/mount_romfs for /mnt: No such file or directory</p>
<p>Booted up my Debian VM, and tried again.<br />
<code><br />
debian:/mnt/hgfs/FI8908，FI8908W# mount -o loop -t romfs still_unsure.img /mnt/test -r<br />
debian:/mnt/hgfs/FI8908，FI8908W# cd /mnt/test/<br />
debian:/mnt/test# ls -al<br />
total 4<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 .<br />
drwxr-xr-x 4 root root 4096 2010-04-29 16:19 ..<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 bin<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 dev<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 etc<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 flash<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 home<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 proc<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 swap<br />
drwxr-xr-x 1 root root   32 1969-12-31 18:00 usr<br />
</code></p>
<p>We have a winner!</p>
<p>Full file listing below:</p>
<p><code>.<br />
|-- bin<br />
|   |-- camera<br />
|   |-- dhcpc<br />
|   |-- ifconfig<br />
|   |-- init<br />
|   |-- iwconfig<br />
|   |-- iwpriv<br />
|   |-- mypppd<br />
|   |   |-- chap-secrets<br />
|   |   |-- options<br />
|   |   |-- pap-secrets<br />
|   |   `-- pppd<br />
|   |-- route<br />
|   |-- rt73.bin<br />
|   |-- sh<br />
|   |-- wetctl<br />
|   `-- wpa_supplicant<br />
|-- dev<br />
|   |-- console<br />
|   |-- display<br />
|   |-- dsp -> dsp1<br />
|   |-- dsp0<br />
|   |-- dsp1<br />
|   |-- fb0<br />
|   |-- hda<br />
|   |-- hda1<br />
|   |-- hda2<br />
|   |-- hdb<br />
|   |-- i2c0<br />
|   |-- i2c1<br />
|   |-- key<br />
|   |-- keypad<br />
|   |-- lp0<br />
|   |-- mixer -> mixer1<br />
|   |-- mixer0<br />
|   |-- mixer1<br />
|   |-- mouse<br />
|   |-- mtd0<br />
|   |-- mtd1<br />
|   |-- mtdblock0<br />
|   |-- mtdblock1<br />
|   |-- nftlA1<br />
|   |-- nftla<br />
|   |-- null<br />
|   |-- ppp<br />
|   |-- ppp1<br />
|   |-- ptmx<br />
|   |-- pts<br />
|   |-- ptyp0<br />
|   |-- ptyp1<br />
|   |-- ptyp2<br />
|   |-- ptyp3<br />
|   |-- ptyp4<br />
|   |-- ptyp5<br />
|   |-- ptyp6<br />
|   |-- ptyp7<br />
|   |-- ptyp8<br />
|   |-- ptyp9<br />
|   |-- ptz0<br />
|   |-- rom0<br />
|   |-- rom1<br />
|   |-- rom2<br />
|   |-- sda<br />
|   |-- sda1<br />
|   |-- sda2<br />
|   |-- sdb<br />
|   |-- sdb1<br />
|   |-- sdb2<br />
|   |-- smartcard0<br />
|   |-- smartcard1<br />
|   |-- tty<br />
|   |-- tty1<br />
|   |-- ttyS0<br />
|   |-- ttyS1<br />
|   |-- ttyS2<br />
|   |-- ttyS3<br />
|   |-- ttyp0<br />
|   |-- ttyp1<br />
|   |-- ttyp2<br />
|   |-- ttyp3<br />
|   |-- ttyp4<br />
|   |-- ttyp5<br />
|   |-- ttyp6<br />
|   |-- ttyp7<br />
|   |-- ttyp8<br />
|   |-- ttyp9<br />
|   |-- urandom<br />
|   |-- usb<br />
|   |   |-- lp.sh<br />
|   |   |-- lp0<br />
|   |   |-- lp1<br />
|   |   |-- lp2<br />
|   |   |-- lp3<br />
|   |   |-- lp4<br />
|   |   |-- lp5<br />
|   |   |-- lp6<br />
|   |   |-- lp7<br />
|   |   |-- lp8<br />
|   |   `-- lp9<br />
|   |-- usi<br />
|   |-- video0<br />
|   `-- video1<br />
|-- etc<br />
|-- flash<br />
|-- home<br />
|-- proc<br />
|-- swap<br />
|-- usr<br />
`-- var<br />
    `-- run</p>
<p>13 directories, 97 files</code></p>
<p>While I obviously can&#8217;t run any binaries locally, I can look at the text files to confirm that the ROMFS hasn&#8217;t just gotten the filesystem correct.</p>
<p><code>debian:/mnt/test/bin# cat init<br />
mount -t proc none /proc<br />
mount -t ramfs none /usr<br />
mount -t ramfs none /swap<br />
mount -t ramfs none /var/run<br />
mount -t ramfs none /etc<br />
mount -t ramfs none /flash<br />
mount -t ramfs none /home<br />
camera&#038;<br />
sh<br />
</code></p>
<p><code>debian:/mnt/test/bin# file camera<br />
camera: BFLT executable - version 4 ram gzip<br />
</code></p>
<p>Looking *very* good.</p>
<p>Thats all for tonight, but it looks like we can easily add bits to the firmware using genromfs, dd, and a hex editor, or just genromfs, and someone willing to test a rebuilt user rom with an extra binary.  Probably going to be telnetd as ssh requires a kernel recompile <img src='http://www.computersolutions.cn/blog/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>
<p>Next step, actually doing that, and testing.</p>
<p>I&#8217;m definitely going to bed now &#8211; its 5:30am.</p>
<p>Tomorrow is a holiday though (in China), so happy May holidays!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt4/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>IP Cam Hacking &#8211; pt#3</title>
		<link>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt3/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=ip-cam-hacking-pt3</link>
		<comments>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt3/#comments</comments>
		<pubDate>Tue, 27 Apr 2010 07:43:41 +0000</pubDate>
		<dc:creator>Lawrence Sheed</dc:creator>
				<category><![CDATA[Technical Mumbo Jumbo]]></category>
		<category><![CDATA[embedded]]></category>
		<category><![CDATA[foscam]]></category>
		<category><![CDATA[hacking]]></category>
		<category><![CDATA[ipcam]]></category>
		<category><![CDATA[nc745]]></category>
		<category><![CDATA[nuvoton]]></category>

		<guid isPermaLink="false">http://www.computersolutions.cn/blog/?p=468</guid>
		<description><![CDATA[I&#8217;ve finally received my 2nd camera, so I can now start working properly on it (assuming I get some free time too!) High resolution photos of the board are below: Main parts used are: RAM &#8211; Winbond W9812G61H-6 (2M) According to the data sheet, that 2M X 4 BANKS X 16 BITS SDRAM @ 3.3V [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve finally received my 2nd camera, so I can now start working properly on it (assuming I get some free time too!)</p>
<p>High resolution photos of the board are below:</p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/ipcam_underside.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/ipcam_underside-300x200.jpg" alt="" title="ipcam_underside" width="300" height="200" class="aligncenter size-medium wp-image-471" /></a></p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/ipcam_topside.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/ipcam_topside-300x200.jpg" alt="" title="ipcam_topside" width="300" height="200" class="aligncenter size-medium wp-image-470" /></a></p>
<p><a href="http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/ipcam_wifi_daughter_board.jpg"><img src="http://www.computersolutions.cn/blog/wp-content/uploads/2010/04/ipcam_wifi_daughter_board-300x200.jpg" alt="" title="ipcam_wifi_daughter_board" width="300" height="200" class="aligncenter size-medium wp-image-469" /></a></p>
<p>Main parts used are:</p>
<p><strong>RAM &#8211;  Winbond W9812G61H-6 (2M)</strong><br />
According to the data sheet, that 2M X 4 BANKS X 16 BITS SDRAM @ 3.3V / 166MHz/CL3<br />
Data sheet is here &#8211; <a href="http://jp.ic-on-line.cn/IOL/datasheet/w9812g6ih_4223255.pdf">http://jp.ic-on-line.cn/IOL/datasheet/w9812g6ih_4223255.pdf</a></p>
<p><strong>Flash &#8211; Spansion S29AL016D (2M)</strong><br />
Other boards are populated with different providers &#8211; some people have Samsung flash&#8230;<br />
Mine has the Spansion onboard both units.  Its programmable onboard (via the uBoot)<br />
Data sheet here &#8211; <a href="http://www.datasheetpro.com/259722_view_S29AL016D_datasheet.html">http://www.datasheetpro.com/259722_view_S29AL016D_datasheet.html</a></p>
<p><strong>Sound Card &#8211; ALC203</strong><br />
This is obviously used as the BSP for the Novotel provides sample code for that card, making their life easier&#8230;<br />
Data sheet here &#8211; <a href="http://realtek.info/pdf/alc203.pdf">http://realtek.info/pdf/alc203.pdf</a></p>
<p><strong>Wired Ethernet &#8211; Davicom DM9161AEP (10/100 Ethernet)</strong><br />
Data sheet here &#8211;<br />
<a href="http://www.davicom.com.tw/userfile/24247/DM9161AEPProductBrief_v1.0.pdf">http://www.davicom.com.tw/userfile/24247/DM9161AEPProductBrief_v1.0.pdf</a></p>
<p><strong>8 Port Relay Driver (for the motors etc) &#8211; ULN2803</strong><br />
Data sheet here  &#8211; <a href="http://www.rentron.com/Files/uln2803.pdf">http://www.rentron.com/Files/uln2803.pdf</a><br />
More info / explanation here &#8211; <a href="http://wiki.answers.com/Q/What_is_Relay_driver_ULN2803">http://wiki.answers.com/Q/What_is_Relay_driver_ULN2803</a></p>
<p><strong>Wifi &#8211; RALINK 2571 (on daughterboard).  Wireless G </strong><br />
This is a USB based chipset, so we&#8217;re using 4 usb connector pins for this one.<br />
No datasheet, as Ralink are dicks.</p>
<p><strong>CPU &#8211; ARM7 N745CDG (Arm 7 by Nuvoton)</strong><br />
Lot of info for chip available at Nuvoton. </p>
<p>W90N745 makes use of the ARM7TDMI microprocessor core of ARMR and 0.18um production to achieve standard operation at 80MHz. 128-Pin LQPF packing is also used to save electricity and lower costs. The built-in 4KBytes I-Cache and 4KBytes D-Cache of W90N745 can also be set as On-Chip RAM according to the needs of product developers. With regards to system integration, W90N745 is suitable for network-related applications such as management switch, IP cameras, VoIP and printer servers.<br />
Features<br />
    * One Ethernet MAC<br />
    * One USB 2.0 full speed Host controller<br />
    * One USB 2.0 full speed Host/Device controller<br />
    * AC97/I2S<br />
    * 4 UARTs<br />
    * I²C Master<br />
    * 31 GPIOs<br />
    * Power Management</p>
<p>Data sheets &#8211; <a href="http://www.nuvoton.com/hq/enu/ProductAndSales/ProductLines/ConsumerElectronicsIC/ARMMicrocontroller/ARMMicrocontroller/NUC745A.htm">http://www.nuvoton.com/hq/enu/ProductAndSales/ProductLines/ConsumerElectronicsIC/ARMMicrocontroller/ARMMicrocontroller/NUC745A.htm</a><br />
The uclinux sample distribution and files can be downloaded here &#8211; <a href="http://www.metavert.com/public/NO-SUPPORT/NUC700%20Series%20MCU%20uCLinux%20BSP.zip">http://www.metavert.com/public/NO-SUPPORT/NUC700%20Series%20MCU%20uCLinux%20BSP.zip</a></p>
<p>I&#8217;m just waiting on a JLINK USB adaptor, then I&#8217;m ready to roll.</p>
<p>[Updates]</p>
<p>David M from comments at <a href="http://irishjesus.wordpress.com/2010/03/30/hacking-the-foscam-fi8908w/#comments">http://irishjesus.wordpress.com/2010/03/30/hacking-the-foscam-fi8908w/#comments</a> provided his rom sizing from his device, I&#8217;ve got some notes on that here.</p>
<p>MAC Address : 00:30:10:C1:D0:39<br />
IP Address : 0.0.0.0<br />
DHCP Client : Enabled<br />
CACHE : Enabled<br />
BL buffer base : 0×00300000<br />
BL buffer size : 0×00100000<br />
Baud Rate : -1<br />
USB Interface : Disabled<br />
Serial Number : 0xFFFFFFFF</p>
<p>For help on the available commands type ‘h’</p>
<p>Press ESC to enter debug mode …</p>
<p>bootloader > ls<br />
Image: 0 name:BOOT INFO base:0x7F010000 size:0×00000038 exec:0x7F010000 -af<br />
Image: 7 name:linux.bin base:0x7F020000 size:0x000BB334 exec:0×00008000 -acxz<br />
Image: 6 name:romfs.img base:0x7F0E0000 size:0x0008D000 exec:0x7F0E0000 -a</p>
<p>My notes:</p>
<p>Image: 0 name:BOOT INFO base:0x7F010000 size:0×00000038 exec:0x7F010000 -af</p>
<p>[Image 0 is 38 bytes (small!).<br />
Boot info is not the bootloader - 38bytes is way too small for that.<br />
It actually stores our bootloader config settings.<br />
eg ip address, cache setting, boot loader buffer address etc.<br />
Our initial settings are below:</p>
<p>MAC Address : 00:30:10:C1:D0:39 (should be changed, this Mac range belongs to Cisco!)<br />
IP Address : 0.0.0.0 (unset)<br />
DHCP Client : Enabled  (pulls ip from dhcp..)<br />
CACHE : Enabled (onboard chip cache)<br />
BL buffer base : 0×00300000<br />
BL buffer size : 0×00100000<br />
Baud Rate : -1 (unset / so defaults to 115,200,8,n,1)<br />
USB Interface : Disabled (NC745 has no USB for bootloader)<br />
Serial Number : 0xFFFFFFFF (unset)</p>
<p>-af indicates Active (a) , and is a Filesystem image (f)]</p>
<p>Image: 7 name:linux.bin base:0x7F020000 size:0x000BB334 exec:0×00008000 -acxz<br />
[Image 7 is our OS - Linux 2.4.20 ucLinux  Not sure why Maverick didn't build on 2.6, there is more hardware support.  Probably time dependant - 2.6 may not have been available, plus the Nuvoton sample code is also 2.4 based...</p>
<p>-axcz says  active (a)  executable (x) copied to ram (c) compressed (z)  ]</p>
<p>Image: 6 name:romfs.img base:0x7F0E0000 size:0x0008D000 exec:0x7F0E0000 -a</p>
<p>[Our rom image - aka userland stuff.  This is where we'll be putting our own code.  Looks like its stuck quite high up in the flash, although doesn't need to be given size of the Linux rom.  We have plenty of room available.</p>
<p>We'll need to make appropriate changes to Image 6 size on flashing</p>
<p>-a says active partition.]</p>
]]></content:encoded>
			<wfw:commentRss>http://www.computersolutions.cn/blog/2010/04/ip-cam-hacking-pt3/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>
