<?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>electrons on radio</title>
	<atom:link href="http://www.electronsonradio.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.electronsonradio.com</link>
	<description>a blog about math, science and engineering</description>
	<lastBuildDate>Sat, 04 Feb 2012 02:37:01 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Quick start to Angstrom on the BeagleBoard</title>
		<link>http://www.electronsonradio.com/2012/02/quick-start-to-angstrom-on-the-beagleboard/</link>
		<comments>http://www.electronsonradio.com/2012/02/quick-start-to-angstrom-on-the-beagleboard/#comments</comments>
		<pubDate>Sat, 04 Feb 2012 02:37:01 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=111</guid>
		<description><![CDATA[Every time I put down my BeagleBoard for a while I forget what is needed to install Angstrom and get it set up and running. So to remind myself in...]]></description>
			<content:encoded><![CDATA[<p>Every time I put down my BeagleBoard for a while I forget what is needed to install Angstrom and get it set up and running. So to remind myself in the future, I made a quick start guide:</p>
<p>First I grab an image from <a href="http://narcissus.angstrom-distribution.org/  ">Narcissus</a></p>
<p>Set the machine to BeagleBoard, and choose the options though advanced complexity.<br />
Set all defaults except I add the following packages:<br />
Python<br />
OpenCV headers and libs<br />
All kernel modules<br />
Wireless-tools<br />
Bootloader Files</p>
<p>Check <a href="  http://treyweaver.blogspot.co.nz/2010/10/installing-angstrom-on-beagleboard-xm.html">this guide</a> for installing the image.</p>
<p>If having problem with serial, check post on <a href="http://www.electronsonradio.com/2011/06/beagleboard-character-faults-on-serial-after-boot-uart-wakeup-issue/">serial issues</a>.</p>
<p>Setup Angstrom using some details from <a href="http://www.gigamegablog.com/2012/01/29/beaglebone-linux-101-configuring-angstrom-linux/">this BeagleBone guide</a>.</p>
<p>Add user with &#8220;adduser&#8221;<br />
create .profile for user to set path environment variable:<br />
PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin<br />
export PATH</p>
<p>Reboot with<br />
shutdown -r now</p>
<p>Halt with<br />
shutdown -h now</p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2012/02/quick-start-to-angstrom-on-the-beagleboard/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Basic reddit api access in python</title>
		<link>http://www.electronsonradio.com/2012/01/basic-reddit-api-access-in-python/</link>
		<comments>http://www.electronsonradio.com/2012/01/basic-reddit-api-access-in-python/#comments</comments>
		<pubDate>Thu, 19 Jan 2012 04:42:21 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=109</guid>
		<description><![CDATA[Recently I&#8217;ve been working a bit with the reddit api and have made a basic python script for grabbing info off reddit through the api. You can check out the...]]></description>
			<content:encoded><![CDATA[<p>Recently I&#8217;ve been working a bit with the reddit api and have made a basic python script for grabbing info off reddit through the api. You can check out the script on my github (<a href="https://github.com/david-electrons" title="Github repo" target="_blank">link</a>). It currently has basic functionality for authorization and cookie handling and will grab a user&#8217;s info. </p>
<p>Before using and modifying you should pay attention to the <a href="https://github.com/reddit/reddit/wiki/API" title="Reddit API rules" target="_blank">reddit&#8217;s api rules</a> and <a href="http://www.reddit.com/help/faq" title="Reddit's general rules" target="_blank">reddit&#8217;s general rules</a>. Specially, make fewer than one request per two seconds, don&#8217;t lie about your user-agent and no &#8220;vote cheating&#8221;. Reddit has implemented anti-cheating and anti-spam code which is not available on their repo which detects misuse. It will find you and will ban you.</p>
<p>To get up and running you&#8217;ll need to setup a dv_settings.json file which contains the account information for login and target username. Here is an example:</p>
<p><code>{<br />
        "account": {<br />
                "username": "user123",<br />
                "password": "password123"<br />
        },<br />
        "target": "targetusername",<br />
        "user-agent": "reddit info grabber v0.1"<br />
}</code></p>
<p>The script also needs write access to the filesystem to create the cookies file.</p>
<p>Have fun!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2012/01/basic-reddit-api-access-in-python/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Thesis word count [In progress]</title>
		<link>http://www.electronsonradio.com/2011/12/thesis-word-count/</link>
		<comments>http://www.electronsonradio.com/2011/12/thesis-word-count/#comments</comments>
		<pubDate>Wed, 28 Dec 2011 11:42:14 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Comedy]]></category>
		<category><![CDATA[Research]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=102</guid>
		<description><![CDATA[I am currently in the process of writing my PhD thesis and am well on the way to handing in at the beginning of 2012. Just for fun I thought...]]></description>
			<content:encoded><![CDATA[<p>I am currently in the process of writing my PhD thesis and am well on the way to handing in at the beginning of 2012. Just for fun I thought I would run a script daily at midnight to calculate the number of words I have written during the day so that I could track the progress I make on any given day. As you can tell I am quite busy so the script is rather basic but you can find it here <a href="http://www.electronsonradio.com/downloads/wordcount.vbs" target="_blank">here</a>.
</p>

<script type="text/javascript" src="//ajax.googleapis.com/ajax/static/modules/gviz/1.0/chart.js"> {"dataSourceUrl":"//docs.google.com/spreadsheet/tq?key=0AgtooW6Pt6jodGJYbzVibEVNQ2tZRV81YUVfX1pzS0E&#038;transpose=0&#038;headers=1&#038;range=B1%3AE100&#038;gid=0&#038;pub=1","options":{"vAxes":[{"title":null,"minValue":null,"viewWindowMode":"pretty","viewWindow":{"min":null,"max":null},"maxValue":null},{"viewWindowMode":"pretty","viewWindow":{}}],"series":{"2":{"color":"#999999"}},"curveType":"","title":"","titleX":"Date","backgroundColor":"#FFFFFF","legend":"bottom","lineWidth":2,"logScale":false,"hAxis":{"maxAlternations":1},"hasLabelsColumn":true,"width":1014,"height":440},"state":{},"view":"{\"columns\":[0,1,2,3]}","chartType":"LineChart","chartName":"Chart 1"} </script>]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2011/12/thesis-word-count/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>cp210x usb to serial converter linux driver</title>
		<link>http://www.electronsonradio.com/2011/07/cp210x-usb-to-serial-converter-linux-driver/</link>
		<comments>http://www.electronsonradio.com/2011/07/cp210x-usb-to-serial-converter-linux-driver/#comments</comments>
		<pubDate>Thu, 28 Jul 2011 11:35:21 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=90</guid>
		<description><![CDATA[Silicon labs have a range of usb to serial converters called the cp210x series. With modern OEM computers moving away from installing serial ports these devices are becoming more and...]]></description>
			<content:encoded><![CDATA[<p>Silicon labs have a range of usb to serial converters called the cp210x series. With modern OEM computers moving away from installing serial ports these devices are becoming more and more useful. Now, cp210x actually refers to the chipset that is doing the conversion of USB to UART. So you can install these chips in your own designs to completely rid the dependence on serial cables. In windows Silicon Labs provide customizable drivers which means you can provide your own branding. For example, if I made a device with a cp2102 chip I could set it up so when someone plugged it into their computer it would read, &#8220;Dave&#8217;s awesome USB device&#8221;. </p>
<p>So I have been using the cp2102 evaluation kit from Silicon Labs. Basically because it is a robust and reliable method of USB-Serial conversion. An added benefit of these device is that they can support speeds higher than what is available with standard RS232 hardware. For example I can transfer data with a baud rate of 2Mbps. </p>
<p>I recently received a question about using cp210x from Silicon Labs with linux. So linux has basic support [2] for cp210x devices from a community made driver (as of 2.6.39). Silicon Labs have released new products in this product range, namely cp2105 for example, which the current linux driver doesn&#8217;t recognise. </p>
<p>For example:</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
usb 1-1.2: device v10c4 pea70 is not supported
usb 1-1.2: New USB device found, idVendor=10c4, idProduct=ea70
usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=5
usb 1-1.2: Product: CP2105 Dual USB to UART Bridge Controller
usb 1-1.2: Manufacturer: Silicon Labs
usb 1-1.2: SerialNumber: 0000BBA1
</pre>
<p>On the silicon labs website [1], they have released a new version of the driver. Unfortunately this doesn&#8217;t work out of the box and seems to be aimed towards Ret Hat users. So I am going to briefly go through how to build and install the new driver in Ubuntu. To make your life easier I have done the required modifications and have them here for download.</p>
<p>Drivers: <a href="http://www.electronsonradio.com/downloads/cp210x.tar">cp201x.tar</a></p>
<p>This driver supports the following devices:<br />
CP2101<br />
CP2102<br />
CP2103<br />
CP2104<br />
CP2105</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
./configure
make
make install
</pre>
<p>For example:</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/cp210x_silabs/cp210x-3.1.0/cp210x$ ./configure
Kernel version  : 2.6.38-8-generic
Module extension        : .ko
KO File   : cp210x.ko
Kernel Dir  : /lib/modules/2.6.38-8-generic/build
Module File  : cp2101.ko
Module Dir  : /lib/modules/2.6.38-8-generic
Current Dir  : /home/dave/cp210x_silabs/cp210x-3.1.0/cp210x
</pre>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/cp210x_silabs/cp210x-3.1.0/cp210x$ make
make -C /lib/modules/2.6.38-8-generic/build -I /home/dave/cp210x_silabs/cp210x-3.1.0/cp210x M=/home/dave/cp210x_silabs/cp210x-3.1.0/cp210x modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.38-8-generic'
  CC [M]  /home/dave/cp210x_silabs/cp210x-3.1.0/cp210x/cp210x.o
/home/dave/cp210x_silabs/cp210x-3.1.0/cp210x/cp210x.c:454:1: warning: &quot;/*&quot; within comment
/home/dave/cp210x_silabs/cp210x-3.1.0/cp210x/cp210x.c:723:1: warning: initialization from incompatible pointer type
/home/dave/cp210x_silabs/cp210x-3.1.0/cp210x/cp210x.c:724:1: warning: initialization from incompatible pointer type
/home/dave/cp210x_silabs/cp210x-3.1.0/cp210x/cp210x.c:728:1: warning: initialization from incompatible pointer type
  Building modules, stage 2.
  MODPOST 1 modules
  CC      /home/dave/cp210x_silabs/cp210x-3.1.0/cp210x/cp210x.mod.o
  LD [M]  /home/dave/cp210x_silabs/cp210x-3.1.0/cp210x/cp210x.ko
make[1]: Leaving directory `/usr/src/linux-headers-2.6.38-8-generic'
</pre>
<p>A couple of warnings in there, but we will ignore them for the time.</p>
<p>You can see from the output that it made the file: /home/dave/cp210x_silabs/cp210x-3.1.0/cp210x/cp210x.ko</p>
<p>You can do a &#8220;make install&#8221; but I didn&#8217;t want it to overwrite my existing driver:</p>
<p>Backed up my old driver</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/cp210x_silabs/cp210x-3.1.0/cp210x$ sudo mv /lib/modules/2.6.38-8-generic/kernel/drivers/usb/serial/cp210x.ko cp210x.ko.ori
</pre>
<p>Then copied over the new one:</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/cp210x_silabs/cp210x-3.1.0/cp210x$ sudo mv cp210x.ko /lib/modules/2.6.38-8-generic/kernel/drivers/usb/serial/cp210x.ko
</pre>
<p>I then did a depmod, then a modinfo.</p>
<pre class="brush: plain; collapse: true; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/cp210x_silabs/cp210x-3.1.0/cp210x$ sudo depmod
dave@ubuntu:~/cp210x_silabs/cp210x-3.1.0/cp210x$ sudo modinfo cp210x
filename:       /lib/modules/2.6.38-8-generic/kernel/drivers/usb/serial/cp210x.ko
version:        v1.10.0
license:        GPL
description:    Silicon Labs CP210x USB Serial Adaptor Driver
author:         RMS
srcversion:     35585FF341190212CF9E53A
alias:          usb:v18EFpE00Fd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v16D6p0001d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v166Ap0303d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v13ADp9999d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C5pEA61d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4pF004d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4pF003d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4pF002d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4pF001d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4pEA70d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4pEA61d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4pEA60d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p846Ed*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p83A8d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p8341d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p8293d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p826Bd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p822Bd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p8218d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p81E7d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p81E2d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p81C8d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p81ACd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p81A6d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p819Fd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p815Ed*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p814Bd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p814Ad*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p813Dd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p8115d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p80F6d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p80DDd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p80CAd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p807Ad*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p8066d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p8054d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p8053d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p803Bd*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10C4p800Ad*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10B5pAC70d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10ABp10C5d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v10A6pAA26d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v0FCFp1006d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v0FCFp1004d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v0FCFp1003d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v08E6p5501d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v0489pE000d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v0471p066Ad*dc*dsc*dp*ic*isc*ip*
depends:        usbserial
vermagic:       2.6.38-8-generic SMP mod_unload modversions 686
parm:           debug:Enable verbose debugging messages (bool)
</pre>
<p>Update:<br />
1. I have just noticed that make install doesn&#8217;t work for the driver I attached. Just copy it over like I did above, then do a depmod.<br />
2. I think that the driver version hasn&#8217;t been incremented, as it still reads v1.10.0 after update. You could update the source if you want it to read correctly.</p>
<p>References<br />
[1] http://www.silabs.com/products/mcu/Pages/USBtoUARTBridgeVCPDrivers.aspx<br />
[2] http://www.etheus.net/CP210x_Linux_Driver</p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2011/07/cp210x-usb-to-serial-converter-linux-driver/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Life of a PhD engineer (Time lapse video)</title>
		<link>http://www.electronsonradio.com/2011/07/life-of-a-phd-engineer-time-lapse-video/</link>
		<comments>http://www.electronsonradio.com/2011/07/life-of-a-phd-engineer-time-lapse-video/#comments</comments>
		<pubDate>Tue, 12 Jul 2011 12:58:16 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Comedy]]></category>
		<category><![CDATA[Research]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=88</guid>
		<description><![CDATA[Inspired by the indie game developer time lapse, I took a time lapse video of me working. While not as exciting as the game developer one, mainly due to the...]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.electronsonradio.com/wp/wp-content/uploads/2011/07/cap2011-07-07-13-48-00.png"><img src="http://www.electronsonradio.com/wp/wp-content/uploads/2011/07/cap2011-07-07-13-48-00-150x150.png" alt="" title="WTF APP CRASH" width="150" height="150" class="alignleft size-thumbnail wp-image-89" /></a></p>
<p>Inspired by <a href="http://www.youtube.com/watch?v=zEiqbwK51Ok&#038;feature=player_embedded" target="_blank">the indie game developer time lapse</a>, I took a time lapse video of me working. While not as exciting as the game developer one, mainly due to the fact I spend most of my time writing. But I find it particularly amusing. Especially if you slow it down and check out my thinking pose (00:55:09) and my WTF app crash pose (01:11:47, also to the left). Might try to get a better angle next time so you can check out some circuit action. And I swear, I&#8217;m not picking my nose- I am either holding my chin, rubbing my nose or pushing my glasses! Slow it down if you don&#8217;t believe me. Like all my time lapses, this was taken with my BeagleBoard xM with a Playstation Eye camera. </p>
<p>Link: <a href="http://t.co/4YKadib" target="_blank">http://t.co/4YKadib</a><br />
Or check it out embedded below:</p>
<p><object type="application/x-shockwave-flash" width="400" height="300" data="http://www.flickr.com/apps/video/stewart.swf?v=71377" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"><param name="flashvars" value="intl_lang=en-us&#038;photo_secret=d6d7df0741&#038;photo_id=5929555313"></param><param name="movie" value="http://www.flickr.com/apps/video/stewart.swf?v=71377"></param><param name="bgcolor" value="#000000"></param><param name="allowFullScreen" value="true"></param><embed type="application/x-shockwave-flash" src="http://www.flickr.com/apps/video/stewart.swf?v=71377" bgcolor="#000000" allowfullscreen="true" flashvars="intl_lang=en-us&#038;photo_secret=d6d7df0741&#038;photo_id=5929555313" height="300" width="400"></embed></object></p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2011/07/life-of-a-phd-engineer-time-lapse-video/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>IEEE EMBC 2011</title>
		<link>http://www.electronsonradio.com/2011/07/ieee-embc-2011/</link>
		<comments>http://www.electronsonradio.com/2011/07/ieee-embc-2011/#comments</comments>
		<pubDate>Sun, 10 Jul 2011 04:19:53 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Research]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=84</guid>
		<description><![CDATA[This is just a quick post to advertise my talk at IEEE Engineering in Medicine and Biology conference 2011 in Boston, MA. I will be presenting some of my PhD...]]></description>
			<content:encoded><![CDATA[<p>This is just a quick post to advertise my talk at IEEE Engineering in Medicine and Biology conference 2011 in Boston, MA. </p>
<p>I will be presenting some of my PhD work on wireless power control and it&#8217;s use for high bandwidth electrocardiogram (ECG) measurement from a fully implanted telemeter. </p>
<p>You can check out the abstract and preliminary scheduling here:<br />
<a href="https://embs.papercept.net/conferences/scripts/abstract.pl?ConfID=14&#038;Number=717">https://embs.papercept.net/conferences/scripts/abstract.pl?ConfID=14&#038;Number=717</a></p>
<p>And in the mean time you can check out our previous design:</p>
<p><p class="flickrTag_container"><a href="http://www.flickr.com/photos/40839498@N00/5920414169/" class="flickr"><img src="http://farm7.static.flickr.com/6136/5920414169_f4f7ae61d3_m.jpg" alt="Array" class="flickr small photo" /></a></p></p>
<p>See: <a href="http://ieeexplore.ieee.org/xpls/abs_all.jsp?arnumber=5372030&#038;tag=1">http://ieeexplore.ieee.org/xpls/abs_all.jsp?arnumber=5372030&#038;tag=1</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2011/07/ieee-embc-2011/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Angstrom on the BeagleBoard: Fixing your MAC Address.</title>
		<link>http://www.electronsonradio.com/2011/07/angstrom-on-the-beagleboard-fixing-your-mac-address/</link>
		<comments>http://www.electronsonradio.com/2011/07/angstrom-on-the-beagleboard-fixing-your-mac-address/#comments</comments>
		<pubDate>Fri, 01 Jul 2011 17:05:40 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[BeagleBoard]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=81</guid>
		<description><![CDATA[Just a quick post today about how to fix the MAC address on your BeagleBoard. Unfortunately the MAC address isn&#8217;t set in the EEPROM of the usb network adapter so...]]></description>
			<content:encoded><![CDATA[<p>Just a quick post today about how to fix the MAC address on your BeagleBoard. Unfortunately the MAC address isn&#8217;t set in the EEPROM of the usb network adapter so the driver randomly generates a new one on startup. </p>
<p>To overcome this I use a patch for the driver to pickup the MAC Address from the kernel boot arguments. The same has here [1]. Unfortunately open embedded had trouble reading that patch file. But &#8220;good news everybody&#8221;, I rehashed it and it is linked below:</p>
<p>Patch: <a href="http://www.electronsonradio.com/downloads/kernel-2.6.32-cli-mac-address.patch">kernel-2.6.32-cli-mac-address.patch</a></p>
<p>You can then place the following line in uEnv.txt to set your MAC address:</p>
<p>optargs=&#8221;ethaddr=00:11:22:33:44:66&#8243;</p>
<p>Then on startup you can tell if it is set:</p>
<p>[   11.681304] eth0: register &#8216;smsc95xx&#8217; at usb-ehci-omap.0-2.1, smsc95xx USB 2.0 Ethernet, 00:11:22:33:44:66</p>
<p>or by looking at ifconfig.</p>
<p>Update: Another method is to use the patch from [2], which will be included upstream in future kernels.</p>
<p>Patch: <a href="http://www.electronsonradio.com/downloads/smsc95xx-generate-random-MAC-address-once-not-every-ifup.patch">smsc95xx-generate-random-MAC-address-once-not-every-ifup.patch</a></p>
<p>This is easier than using kernel arguments because then you can then change your MAC address without a restart:</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
ifconfig usb0 down
ifconfig usb0 hw ether 00:11:22:33:44:55 up
</pre>
<p>Reference:<br />
[1] <a href="http://maxgalemin.blogspot.com/2010/11/patch-for-fixing-random-mac-address-on.html">http://maxgalemin.blogspot.com/2010/11/patch-for-fixing-random-mac-address-on.html</a><br />
[2] <a href="https://patchwork.kernel.org/patch/263861/">https://patchwork.kernel.org/patch/263861/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2011/07/angstrom-on-the-beagleboard-fixing-your-mac-address/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Playstation Eye + gstreamer examples</title>
		<link>http://www.electronsonradio.com/2011/06/playstation-eye-gstreamer-examples/</link>
		<comments>http://www.electronsonradio.com/2011/06/playstation-eye-gstreamer-examples/#comments</comments>
		<pubDate>Sun, 12 Jun 2011 04:33:36 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[BeagleBoard+PlaystationEye]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=69</guid>
		<description><![CDATA[Here are a few examples of using the Playstation Eye with gstreamer: Streaming live video from the camera at 1fps. gst-launch -v v4l2src ! ffmpegcolorspace ! video/x-raw-yuv,width=640,height=480,framerate=\(fraction\)30/1 ! queue !...]]></description>
			<content:encoded><![CDATA[<p>Here are a few examples of using the Playstation Eye with gstreamer:</p>
<p>Streaming live video from the camera at 1fps.<br />
<code>gst-launch -v v4l2src ! ffmpegcolorspace ! video/x-raw-yuv,width=640,height=480,framerate=\(fraction\)30/1 ! queue ! videorate ! video/x-raw-yuv,framerate=1/1 ! jpegenc ! multipartmux ! tcpserversink host=192.168.1.105 port=5000</code><br />
This can be captured in VLC:<br />
vlc tcp://192.168.1.106:5000</p>
<p>Single image capture:<br />
<code>gst-launch v4l2src num-buffers=1 ! video/x-raw-yuv,width=640,height=480,framerate=30/1 ! ffmpegcolorspace ! videorate ! video/x-raw-rgb,framerate=1/1 ! ffmpegcolorspace ! pngenc snapshot=true ! filesink location=test.png</code><br />
I noticed that the PSEYE ignores the &#8220;num-buffers=1&#8243; parameter so I use the snapshot flag on pngenc instead.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2011/06/playstation-eye-gstreamer-examples/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Building the bleeding-edge PSEYE driver (for your specific Kernel version!)</title>
		<link>http://www.electronsonradio.com/2011/06/building-the-bleeding-edge-pseye-driver-for-your-specific-kernel-version/</link>
		<comments>http://www.electronsonradio.com/2011/06/building-the-bleeding-edge-pseye-driver-for-your-specific-kernel-version/#comments</comments>
		<pubDate>Sun, 12 Jun 2011 02:58:34 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[BeagleBoard+PlaystationEye]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=63</guid>
		<description><![CDATA[So, you want to install the latest PSEYE driver and you&#8217;re running the latest kernel version. The drivers for the Playstation Eye usually are up to date with the latest...]]></description>
			<content:encoded><![CDATA[<p>So, you want to install the latest PSEYE driver and you&#8217;re running the latest kernel version. The drivers for the Playstation Eye usually are up to date with the latest kernel- which make life easy. Follow this tutorial for downloading the git and building the driver: [1]</p>
<p>But, what if you&#8217;re on a platform which doesn&#8217;t currently support the latest kernel version? Or maybe you just want to stick with the kernel version you&#8217;re currently running. But if you try to build the latest driver it can fail due to differences between kernel versions. So there are a couple of options:</p>
<p>1. Use the driver which was current for your version of the kernel- this is will work, but won&#8217;t contain any changes to the driver which has happened since then, so you&#8217;ll be missing out on all the new features!!</p>
<p>2. Use the current driver but only reverse patches that are applicable for the compatibility with the kernel. And luckily video for linux has your back! The media_build git (git://linuxtv.org/media_build.git) from linuxtv.org is just for this. It contains a set of patches which will revert the driver to the required kernel version without reverting new features to the drivers themselves. So you&#8217;ll want to do something like this: [2]</p>
<p>In my case I want to build the latest PSEYE for the 2.6.32 kernel, while the current drivers are time of writing are for the 2.6.40 kernel. For my project I will be compiling these drivers for the BeagleBoard using OpenEmbedded. Now this is a little bit tricky as I will need to manually insert all the relevant patches into the kernel recipe. I have discussed this process in an earlier post: &#8220;<a href="http://www.electronsonradio.com/?p=54">OpenEmbbeded: Linux kernel + adding PSEYE (patched) modules</a>&#8221; where I built the driver using method 1 from above, ie: reverting to an older driver version. </p>
<p>First I cloned the latest git of the gspca driver and the media_build git:</p>
<pre class="brush: plain; collapse: true; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/setup-scripts/sources/gspca-latest$ git clone git://linuxtv.org/jfrancois/gspca.git
Cloning into gspca...
remote: Counting objects: 2011313, done.
remote: Compressing objects: 100% (353721/353721), done.
remote: Total 2011313 (delta 1644787), reused 2003581 (delta 1639209)
Receiving objects: 100% (2011313/2011313), 472.56 MiB | 190 KiB/s, done.
Resolving deltas: 100% (1644787/1644787), done.
</pre>
<p>Rather than using the scripts in the media_build I want to run the patches manually with:</p>
<pre class="brush: plain; collapse: true; light: false; title: ; toolbar: true; notranslate">
for i in $(cat /home/dave/setup-scripts/sources/gspca-latest/media_build/backports/v2.6.32_series
    patch -p1 &lt; /home/dave/setup-scripts/sources/gspca-latest/media_build/backports/$i
done
</pre>
<pre class="brush: plain; collapse: true; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/setup-scripts/sources/gspca-latest/gspca$ ./do_patch_v2.6.32
patching file drivers/media/video/cx18/cx18-driver.c
patching file drivers/media/video/cx18/cx18-driver.h
patching file drivers/media/video/cx18/cx18-streams.h
patching file drivers/media/rc/rc-main.c
patching file drivers/media/dvb/dvb-usb/dvb-usb-remote.c
patching file drivers/media/video/videobuf2-memops.c
patching file drivers/media/dvb/firewire/firedtv-fw.c
patching file drivers/media/video/bt8xx/bttv-input.c
patching file drivers/media/video/cx18/cx18-i2c.c
patching file drivers/media/video/cx23885/cx23885-i2c.c
patching file drivers/media/video/em28xx/em28xx-cards.c
Hunk #1 succeeded at 2443 (offset -11 lines).
patching file drivers/media/video/ivtv/ivtv-i2c.c
patching file drivers/media/video/v4l2-common.c
patching file drivers/media/video/ivtv/ivtv-driver.c
Hunk #3 succeeded at 1013 (offset 2 lines).
Hunk #4 succeeded at 1241 (offset 2 lines).
Hunk #5 succeeded at 1381 (offset 2 lines).
patching file drivers/media/video/ivtv/ivtv-driver.h
patching file drivers/media/video/ivtv/ivtv-irq.c
patching file drivers/media/video/ivtv/ivtv-irq.h
patching file drivers/media/dvb/dvb-core/dvb_net.c
patching file drivers/media/rc/imon.c
patching file drivers/media/dvb/frontends/tua6100.c
patching file drivers/media/rc/rc-main.c
patching file drivers/media/dvb/dvb-usb/dvb-usb-remote.c
patching file drivers/media/video/pvrusb2/pvrusb2-sysfs.c
patching file drivers/media/rc/rc-core-priv.h
patching file drivers/media/rc/ir-raw.c
patching file drivers/media/video/cx23885/cx23888-ir.c
patching file drivers/media/video/cx25840/cx25840-ir.c
patching file drivers/media/video/meye.c
patching file drivers/media/video/meye.h
patching file include/media/lirc_dev.h
</pre>
<p>The driver is then patched for backwards compatibility with the 2.6.32 kernel. I then do a diff of this patched driver with the current 2.6.32 kernel driver:</p>
<pre class="brush: plain; collapse: true; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/setup-scripts/sources/gspca-latest$ diff -rupN v2.6.32_kernel/drivers/media/video/gspca/ gspca/drivers/media/video/gspca/ &gt; update_gspca.patch
</pre>
<p>So the patch I&#8217;ve just created, patches the 2.6.32 kernel with the new gspca driver which is patched for backwards compatibility.</p>
<p>I insert this into my OpenEmbedded recipes recompile the kernel in OpenEmbedded as described here: &#8220;<a href="http://www.electronsonradio.com/?p=54">OpenEmbbeded: Linux kernel + adding PSEYE (patched) modules</a>&#8220;:</p>
<pre class="brush: plain; collapse: true; light: false; title: ; toolbar: true; notranslate">
dave@ubuntu:~/setup-scripts$ MACHINE=beagleboard ./oebb.sh bitbake virtual/kernel -c clean
dave@ubuntu:~/setup-scripts$ MACHINE=beagleboard ./oebb.sh bitbake virtual/kernel
</pre>
<p>So if you&#8217;re doing anything like me and using an experimental driver which is off the main video for linux tree then it is highly possibly that you&#8217;ll get some compile errors due to changes in the code since the official version. You could either use the main v4l tree or go through each of the compile errors and fix them yourself. I decided to fix each of the errors as there didn&#8217;t appear to be too many.</p>
<p>The compile errors I was getting:</p>
<pre class="brush: plain; collapse: true; light: false; title: ; toolbar: true; notranslate">
|   CC [M]  drivers/media/video/gspca/conex.o
|   CC [M]  drivers/media/video/gspca/etoms.o
|   CC [M]  drivers/media/video/gspca/finepix.o
|   CC [M]  drivers/media/video/gspca/gspca.o
| drivers/media/video/gspca/gspca.c: In function 'alloc_and_submit_int_urb':
| drivers/media/video/gspca/gspca.c:216: error: implicit declaration of function 'usb_alloc_coherent'
| drivers/media/video/gspca/gspca.c:217: warning: assignment makes pointer from integer without a cast
| drivers/media/video/gspca/gspca.c:236: error: implicit declaration of function 'usb_free_coherent'
| drivers/media/video/gspca/gspca.c: In function 'create_urbs':
| drivers/media/video/gspca/gspca.c:738: warning: assignment makes pointer from integer without a cast
| drivers/media/video/gspca/gspca.c: In function 'gspca_release':
| drivers/media/video/gspca/gspca.c:1208: error: implicit declaration of function 'video_device_node_name'
| drivers/media/video/gspca/gspca.c:1208: warning: format '%s' expects type 'char *', but argument 2 has type 'int'
| drivers/media/video/gspca/gspca.c: In function 'gspca_dev_probe2':
| drivers/media/video/gspca/gspca.c:2270: warning: format '%s' expects type 'char *', but argument 2 has type 'int'
| drivers/media/video/gspca/gspca.c: In function 'gspca_disconnect':
| drivers/media/video/gspca/gspca.c:2324: warning: format '%s' expects type 'char *', but argument 2 has type 'int'
| make[4]: *** [drivers/media/video/gspca/gspca.o] Error 1
| make[3]: *** [drivers/media/video/gspca] Error 2
| make[2]: *** [drivers/media/video] Error 2
| make[1]: *** [drivers/media] Error 2
| make: *** [drivers] Error 2
| + die 'oe_runmake failed'
| + oefatal 'oe_runmake failed'
| + echo FATAL: 'oe_runmake failed'
| FATAL: oe_runmake failed
| + exit 1
NOTE: package linux-omap-psp-2.6.32-r100c+gitr5fc29e7b2a76a64a739f857858ef0b98294aa155: task do_compileconfigs: Failed
ERROR: Function 'do_compileconfigs' failed (see /home/dave/setup-scripts/build/tmp-angstrom_2008_1/work/beagleboard-angstrom-linux-gnueabi/linux-omap-psp-2.6.32-r100c+gitr5fc29e7b2a76a64a739f857858ef0b98294aa155/temp/log.do_compileconfigs.6497 for further information)
ERROR: Task 12 (/home/dave/setup-scripts/sources/openembedded/recipes/linux/linux-omap-psp_2.6.32.bb, do_compileconfigs) failed with exit code '1'
ERROR: '/home/dave/setup-scripts/sources/openembedded/recipes/linux/linux-omap-psp_2.6.32.bb' failed
</pre>
<p>So I found the best way to fix these compile errors is to jump onto the git history and look at kernel patches merges from the master tree. For my errors I narrowed it down to a particular kernel patch:</p>
<p><a href="http://git.linuxtv.org/jfrancois/gspca.git?a=commitdiff;h=997ea58eb92f9970b8af7aae48800d0ef43b9423#patch27">USB: rename usb_buffer_alloc() and usb_buffer_free() users </a><br />
<em>Daniel Mack [Mon, 12 Apr 2010 11:17:25 +0000 (13:17 +0200)]<br />
For more clearance what the functions actually do,<br />
usb_buffer_alloc() is renamed to usb_alloc_coherent()<br />
usb_buffer_free()  is renamed to usb_free_coherent()<br />
They should only be used in code which really needs DMA coherency. All call sites have been changed accordingly, except for staging drivers. </em></p>
<p>After successful compliation, I checked that the patch was applied by checking the logs (OE temp folder, log.do_patch) :</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
NOTE: Applying patch 'update_gspca.patch' (../sources/openembedded/recipes/linux/linux-omap-psp-2.6.32/update_gspca.patch)
</pre>
<p>Then I copy the new kernel + modules to the SD then boot it up! Once it has booted I can check the info on the module to see the updated version:</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
root@beagleboard:~# modinfo gspca_ov534
+ modinfo gspca_ov534
filename:       /lib/modules/2.6.32/kernel/drivers/media/video/gspca/gspca_ov534.ko
license:        GPL
description:    GSPCA/OV534 USB Camera Driver
author:         Antonio Ospite &lt;ospite@studenti.unina.it&gt;
srcversion:     43331721D0931CE8AD7191A
alias:          usb:v06F8p3002d*dc*dsc*dp*ic*isc*ip*
alias:          usb:v1415p2000d*dc*dsc*dp*ic*isc*ip*
depends:        gspca_main
vermagic:       2.6.32 preempt mod_unload modversions ARMv7
root@beagleboard:~#
</pre>
<p>Lets give it a try using gstreamer:<br />
<a href="http://www.electronsonradio.com/wp/wp-content/uploads/2011/06/vlcsnap-2011-06-12-14h53m31s146.png"><img src="http://www.electronsonradio.com/wp/wp-content/uploads/2011/06/vlcsnap-2011-06-12-14h53m31s146-300x225.png" alt="" title="Playstation Eye photo with latest drivers" width="300" height="225" class="aligncenter size-medium wp-image-68" /></a></p>
<p>Great! The auto-white balance is working. So here we have the Playstation eye plugged into a BeagleBoard -xM capturing video with the latest drivers on the 2.6.32 kernel.</p>
<p>References:<br />
[1] <a href="http://nuigroup.com/forums/viewthread/4079/">http://nuigroup.com/forums/viewthread/4079/</a><br />
[2] <a href="http://linuxtv.org/wiki/index.php/How_to_Obtain,_Build_and_Install_V4L-DVB_Device_Drivers">http://linuxtv.org/wiki/index.php/How_to_Obtain,_Build_and_Install_V4L-DVB_Device_Drivers</a></p>
<p>Update 2011-06-20<br />
As requested: gspca kernel objects for BeagleBoard 2.6.32 Kernel (current as of 2011-06-12): <a href='http://www.electronsonradio.com/wp/wp-content/uploads/2011/06/gspca.tar'>LINK</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2011/06/building-the-bleeding-edge-pseye-driver-for-your-specific-kernel-version/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>BeagleBoard character faults on serial after boot (UART wakeup issue)</title>
		<link>http://www.electronsonradio.com/2011/06/beagleboard-character-faults-on-serial-after-boot-uart-wakeup-issue/</link>
		<comments>http://www.electronsonradio.com/2011/06/beagleboard-character-faults-on-serial-after-boot-uart-wakeup-issue/#comments</comments>
		<pubDate>Tue, 07 Jun 2011 12:34:10 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[BeagleBoard]]></category>

		<guid isPermaLink="false">http://www.electronsonradio.com/?p=64</guid>
		<description><![CDATA[I have been getting junk/corrupting/incorrect characters on my serial line after I rebuilt Angstrom with OpenEmbedded. Here is an example: I managed to track it down to &#8220;UART wakeup and...]]></description>
			<content:encoded><![CDATA[<p>I have been getting junk/corrupting/incorrect characters on my serial line after I rebuilt Angstrom with OpenEmbedded. Here is an example:</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
.---O---.
|       |                  .-.           o o
|   |   |-----.-----.-----.| |   .----..-----.-----.
|       |     | __  |  ---'| '--.|  .-'|     |     |
|   |   |  |  |     |---  ||  --'|  |  |  '  | | | |
'---'---'--'--'--.  |-----''----''--'  '-----'-'-'-'
                -'  |
                '---'

The Angstrom Distribution beagleboard ttyS2

Angstrom 2011.03 beagleboard ttyS2

beagleboard login: ¹root
Ðass÷ïòdº
</pre>
<p>I managed to track it down to &#8220;UART wakeup and timeout options&#8221; as described here [1] and here [2]. The first character I type is rubbish, because of the wakeup and everything after that becomes corrupted. I noticed [3] has a solution which is outdated locations, once I found the new locations of these settings disabling the wakeup option of the ttyS2 uart fixed the problem.</p>
<p><code>echo disabled > /sys/devices/platform/serial8250.2/power/wakeup</code></p>
<p>Fixed:</p>
<pre class="brush: plain; collapse: false; light: false; title: ; toolbar: true; notranslate">
.---O---.
|       |                  .-.           o o
|   |   |-----.-----.-----.| |   .----..-----.-----.
|       |     | __  |  ---'| '--.|  .-'|     |     |
|   |   |  |  |     |---  ||  --'|  |  |  '  | | | |
'---'---'--'--'--.  |-----''----''--'  '-----'-'-'-'
                -'  |
                '---'

The Angstrom Distribution beagleboard ttyS2

Angstrom 2011.03 beagleboard ttyS2

beagleboard login: root
root@beagleboard:~#
</pre>
<p>You could also increase the timeout so that the UART doesn&#8217;t go to sleep but this isn&#8217;t very useful if you leave it running in the background!</p>
<p><code>root@beagleboard:~# tail /sys/devices/platform/serial8250.2/sleep_timeout<br />
5</code></p>
<p>Update: 2011-07-10<br />
Unfortunately I&#8217;ve still had a few issues with reliability on the serial port to the BeagleBoard. Appears to be some sort of grounding issue (combined with the timeout issue). I found it all clears up if I do the above and ground the BeagleBoard USB otg port to one of my laptop&#8217;s USB ports.</p>
<p>[1] <a href="http://groups.google.com/group/beagleboard/browse_thread/thread/718af8f541a8eed2/d803c87e452092f9?lnk=gst&#038;q=serial+characters#d803c87e452092f9">http://groups.google.com/group/beagleboard/browse_thread/thread/718af8f541a8eed2/d803c87e452092f9?lnk=gst&#038;q=serial+characters#d803c87e452092f9</a><br />
[2] <a href="http://groups.google.com/group/beagleboard/browse_thread/thread/a794ca286fbea94f">http://groups.google.com/group/beagleboard/browse_thread/thread/a794ca286fbea94f</a><br />
[3] <a href="http://elinux.org/OMAP_Power_Management#UART_wakeup_and_timeout_options">http://elinux.org/OMAP_Power_Management#UART_wakeup_and_timeout_options</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.electronsonradio.com/2011/06/beagleboard-character-faults-on-serial-after-boot-uart-wakeup-issue/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

