<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-5586001299793205042</id><updated>2011-07-30T14:04:42.325-07:00</updated><category term='robot race 2009'/><category term='waterloo'/><category term='video'/><category term='robot'/><category term='eeePC battery'/><category term='race'/><category term='race day'/><category term='race practice video'/><category term='testrun'/><category term='vision guidance colour AI'/><category term='eeePC'/><category term='video guidance pantilt cephalisation'/><title type='text'>Snowtires</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>31</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-2974664798317099093</id><published>2009-07-27T21:38:00.000-07:00</published><updated>2009-07-28T18:25:08.358-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='robot'/><category scheme='http://www.blogger.com/atom/ns#' term='waterloo'/><category scheme='http://www.blogger.com/atom/ns#' term='race day'/><category scheme='http://www.blogger.com/atom/ns#' term='robot race 2009'/><category scheme='http://www.blogger.com/atom/ns#' term='race'/><title type='text'>Waterloo Robot Race 2009</title><content type='html'>&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_bg57Qjxi-VY/Sm6BGsW0_XI/AAAAAAAAAFQ/6O86WSHJkZ8/s1600-h/waterloorobotrace.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 320px; height: 181px;" src="http://3.bp.blogspot.com/_bg57Qjxi-VY/Sm6BGsW0_XI/AAAAAAAAAFQ/6O86WSHJkZ8/s320/waterloorobotrace.JPG" alt="" id="BLOGGER_PHOTO_ID_5363366158230945138" border="0" /&gt;&lt;/a&gt;&lt;span style="font-weight: bold;"&gt;Waterloo Robot Race 2009&lt;/span&gt; &lt;/div&gt;&lt;br /&gt;Snowtires went to the races, and competed in the &lt;a href="http://www.eng.uwaterloo.ca/%7Erracing/"&gt;Waterloo Robot Race&lt;/a&gt; for 2009, competing against 10 other robots, qualifying for the final race, and finally placing second overall.  This competition marks the culmination of this project (for now).  I was ecstatically pleased with the performance of Snowtires, and happy to note that some of the other UBC robots used elements of the Snowtires guidance code for their own vision systems.&lt;br /&gt;&lt;br /&gt;The Waterloo Robot Race is a trio of challenges.  The first is a drag race, a flat-out speed competition down a cone-lined track.  The second is a round of static judging for aesthetic and technical appeal.  The third round is the circuit race: a cone-lined figure-8 track with a moving purple obstacle cone at the intersection.  There are also two stop signs and a traffic signal.  The robots face penalties if they do not stop for three seconds at the signs and for the duration of the red light at the signal.  Additional penalties are levelled when robots take the wrong path or hit the orange cones.&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: left;"&gt;The UBC-CERM3 Thunderbird robotics team entries:&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_bg57Qjxi-VY/Sm6EuBqDFCI/AAAAAAAAAFY/xLF71RSKUqg/s1600-h/6robots.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 320px; height: 240px;" src="http://4.bp.blogspot.com/_bg57Qjxi-VY/Sm6EuBqDFCI/AAAAAAAAAFY/xLF71RSKUqg/s320/6robots.JPG" alt="" id="BLOGGER_PHOTO_ID_5363370132498486306" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;From left to right: Snowfury MkIII, Johnny5, Snowtires, Big Dave, Quartz, and Oscar.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Snowfury MkIII was the original Team Thunderbird 1/10th scale racer, and is shown here in its third incarnation as a vision-guided robot.  It uses the snowtires vision code in an underdamped, aggressive configuration.  The basic platform is a Tamiya Hummer with an ASUS eeePC 701 computer onboard.  Snowfury was constructed and operated by Marcel Veronesi, with assistance from Tim Lee.  Snowfury achieved the shortest time in its heat and placed fourth overall in the competition.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Johnny5 is another vision-based robot, which runs a more conservative configuration than Snowfury.  Johnny5's creator Tom Huryn pioneered the rear-mounted camera configuration - the further back the camera is, the better peripheral vision the robot has, improving its ability to avoid objects at close ranges.  The underlying platform is a Traxxas Rustler, with an eeePC for the brains.  Johnny5 placed 5th in the competition.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Snowtires is my machine, seen here with its new bodyshell.  We integrated infrared rangefinders for close-range collision avoidance, but in the bright sunlight of race day they were of little use except at point-blank ranges.  Snowtires placed second in the competition.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Big Dave is our fourth vision machine, constructed and operated by Tim Lee.  It is configured similarly to Snowtires, with an up-front camera and pure vision guidance.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Quartz is the team flagship, constructed and operated by Ash McKay.  Equipped with a laser rangefinder, it has an accurate and detailed 2D view of the world.  It uses a vision system to detect stop signs and traffic signals.  The rangefinder can detect the purple obstacle cone, and so Quartz is distinguished and the only robot in the entire competition with a full suite of features, capable of handling all of the competition challenges.  Quartz placed third in the competition, and would have placed first if the penalties for ignoring the traffic signs and lights were of any significance.  It wowed the crowd right out of the starting gate for recovering from a guidance error by backing up and correcting its course.&lt;/li&gt;&lt;li&gt;Oscar is the maverick robot, eschewing vision guidance for sonar-modulated odometry guidance.  Oscar had a map of the course, and verified its position using sonar readings.  However, sonar units have trouble in outdoor areas, particularly under the high winds that we experienced on race day.&lt;/li&gt;&lt;/ul&gt;Race Day!&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_bg57Qjxi-VY/Sm6a9E9VbPI/AAAAAAAAAFo/UZpTF2i5rPs/s1600-h/rain.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 320px; height: 240px;" src="http://2.bp.blogspot.com/_bg57Qjxi-VY/Sm6a9E9VbPI/AAAAAAAAAFo/UZpTF2i5rPs/s320/rain.JPG" alt="" id="BLOGGER_PHOTO_ID_5363394580338535666" border="0" /&gt;&lt;/a&gt;Race day opened with an electrical storm.  The competition&lt;br /&gt;rules said rain or shine, so we got to work putting the waterproofing&lt;br /&gt;on our robots - plastic bags covering the gaps in their bodyshells.&lt;br /&gt;Fortunately the rain cleared up by the time we got there.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_bg57Qjxi-VY/Sm6a1WGI0ZI/AAAAAAAAAFg/ZzVLl6qWErQ/s1600-h/snowtiresatwaterloo.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 320px; height: 240px;" src="http://2.bp.blogspot.com/_bg57Qjxi-VY/Sm6a1WGI0ZI/AAAAAAAAAFg/ZzVLl6qWErQ/s320/snowtiresatwaterloo.JPG" alt="" id="BLOGGER_PHOTO_ID_5363394447499907474" border="0" /&gt;&lt;/a&gt;Here's Snowtires in race regalia, during a practice run on the&lt;br /&gt;course.  The course was largely dry with puddles by the&lt;br /&gt;time we were practicing.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_bg57Qjxi-VY/Sm6cUEbYr7I/AAAAAAAAAFw/dRnhySxT-9s/s1600-h/crossroads.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 320px; height: 240px;" src="http://1.bp.blogspot.com/_bg57Qjxi-VY/Sm6cUEbYr7I/AAAAAAAAAFw/dRnhySxT-9s/s320/crossroads.JPG" alt="" id="BLOGGER_PHOTO_ID_5363396074844762034" border="0" /&gt;&lt;/a&gt;The crossroads, compete with stop sign and purple cone (with its crane).&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-52384ce94645ff70" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v1.nonxt5.googlevideo.com/videoplayback?id%3D52384ce94645ff70%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143777%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D1B42295711828605116398F1C830E48768985D05.72E94D4B27F0C7760CFB536C8CE1C25BDC2FE400%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D52384ce94645ff70%26offsetms%3D5000%26itag%3Dw160%26sigh%3DMJBnhHKCTe7LG3zPl-rvDAxETZk&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v1.nonxt5.googlevideo.com/videoplayback?id%3D52384ce94645ff70%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143777%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D1B42295711828605116398F1C830E48768985D05.72E94D4B27F0C7760CFB536C8CE1C25BDC2FE400%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D52384ce94645ff70%26offsetms%3D5000%26itag%3Dw160%26sigh%3DMJBnhHKCTe7LG3zPl-rvDAxETZk&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;A test run with Snowtires (I don't have any race footage as I&lt;br /&gt;was poised over the panic button in case the robot made&lt;br /&gt;an error: I'll post some of my colleague's footage when&lt;br /&gt;I get it.  Note how Snowtires avoids puddles when it sees&lt;br /&gt;the reflection of a cone in them.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: center;"&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-99e04b5c1e689b60" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v23.nonxt2.googlevideo.com/videoplayback?id%3D99e04b5c1e689b60%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143777%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D723BAFCF8FD263DB20C7834B00CBBAB241E32D75.FEC1A4FB549D0AAAB41C49204B05EA0C564611C%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D99e04b5c1e689b60%26offsetms%3D5000%26itag%3Dw160%26sigh%3D42j22X8oqjbgwfWscfD2gfG_TFg&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v23.nonxt2.googlevideo.com/videoplayback?id%3D99e04b5c1e689b60%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143777%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D723BAFCF8FD263DB20C7834B00CBBAB241E32D75.FEC1A4FB549D0AAAB41C49204B05EA0C564611C%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D99e04b5c1e689b60%26offsetms%3D5000%26itag%3Dw160%26sigh%3D42j22X8oqjbgwfWscfD2gfG_TFg&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;Here's the drag race: my heat against the Windsor U. robot.&lt;br /&gt;The Windsor robot was a torpedo: it went on to win the competition&lt;br /&gt;due to its mixture of vision guidance and raw power.  A little&lt;br /&gt;frightening recovery at the end there, but awesome to behold.&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-3898f7ccff90e2f1" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v19.nonxt5.googlevideo.com/videoplayback?id%3D3898f7ccff90e2f1%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143777%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D8258C53F0449E96FFA2DAFB29971FF20EDEBF866.4AB9FF2A6E100B18D28FF22F2C6A521E4A653288%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D3898f7ccff90e2f1%26offsetms%3D5000%26itag%3Dw160%26sigh%3DvfL1Hhfi_9gkr-3la_SXkBoWlKA&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v19.nonxt5.googlevideo.com/videoplayback?id%3D3898f7ccff90e2f1%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143777%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D8258C53F0449E96FFA2DAFB29971FF20EDEBF866.4AB9FF2A6E100B18D28FF22F2C6A521E4A653288%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D3898f7ccff90e2f1%26offsetms%3D5000%26itag%3Dw160%26sigh%3DvfL1Hhfi_9gkr-3la_SXkBoWlKA&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;My robot is considerably more conservative.  So much so that&lt;br /&gt;this video is of the same drag race, just, you'know... later.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: center;"&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-d4ddb1e90014a034" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v21.nonxt3.googlevideo.com/videoplayback?id%3Dd4ddb1e90014a034%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143778%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D34A387E2C927A7C38357262C4711A332FC8CC3D5.B9F560E35BA017984B1EFDD91A294D432CB0C4B%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Dd4ddb1e90014a034%26offsetms%3D5000%26itag%3Dw160%26sigh%3D7vkOFWlGNWnB-uJVaAcCDQFToFs&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v21.nonxt3.googlevideo.com/videoplayback?id%3Dd4ddb1e90014a034%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143778%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D34A387E2C927A7C38357262C4711A332FC8CC3D5.B9F560E35BA017984B1EFDD91A294D432CB0C4B%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Dd4ddb1e90014a034%26offsetms%3D5000%26itag%3Dw160%26sigh%3D7vkOFWlGNWnB-uJVaAcCDQFToFs&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;In the second round, I was up against Quartz.  My starting timer&lt;br /&gt;didn't engage, so I started three seconds before I should have,&lt;br /&gt;and took a 3 second penalty.  It didn't matter anyway as Quartz&lt;br /&gt;&lt;div style="text-align: center;"&gt;passed Snowtires on the straightaway to take the victory.&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-c417986462111366" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v14.nonxt3.googlevideo.com/videoplayback?id%3Dc417986462111366%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143778%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D24DEE0B591F6F3D67C8DF9793DFBDEB0F88490CB.108550DD35DCFF7C0940DAE57F0EE02941048E62%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Dc417986462111366%26offsetms%3D5000%26itag%3Dw160%26sigh%3Dtl92O8Lx60x_HloSOHBSX3cbhh4&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v14.nonxt3.googlevideo.com/videoplayback?id%3Dc417986462111366%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143778%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D24DEE0B591F6F3D67C8DF9793DFBDEB0F88490CB.108550DD35DCFF7C0940DAE57F0EE02941048E62%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Dc417986462111366%26offsetms%3D5000%26itag%3Dw160%26sigh%3Dtl92O8Lx60x_HloSOHBSX3cbhh4&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;This is Windsor's Team Invincible running the circuit race.&lt;br /&gt;Their robot has impressive speed, and really pulled out all the&lt;br /&gt;stops for the main race.  As they pass the intersection you can&lt;br /&gt;see Johnny5 crossing the finish line as part of the previous heat.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_bg57Qjxi-VY/Sm6svkeWOJI/AAAAAAAAAF4/_NdqKX195h4/s1600-h/quartz.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 320px; height: 240px;" src="http://1.bp.blogspot.com/_bg57Qjxi-VY/Sm6svkeWOJI/AAAAAAAAAF4/_NdqKX195h4/s320/quartz.JPG" alt="" id="BLOGGER_PHOTO_ID_5363414139489630354" border="0" /&gt;&lt;/a&gt;Here's Quartz mere feet from the finish line.  Due to a battery issue,&lt;br /&gt;Quartz had a slow second half of the race, but placed third anyway&lt;br /&gt;due to making only a single error in three whole laps.&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-fdb5e22c1500af89" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v8.nonxt5.googlevideo.com/videoplayback?id%3Dfdb5e22c1500af89%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143778%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D33BFFE4DF57B0C8E3D5C207A196C7D5FDD9DAB08.5F84585FA4B677A35E078AD746D84020134C87B8%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Dfdb5e22c1500af89%26offsetms%3D5000%26itag%3Dw160%26sigh%3DGIOssF96p6rqs3uHlahnHuShDTc&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v8.nonxt5.googlevideo.com/videoplayback?id%3Dfdb5e22c1500af89%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143778%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D33BFFE4DF57B0C8E3D5C207A196C7D5FDD9DAB08.5F84585FA4B677A35E078AD746D84020134C87B8%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Dfdb5e22c1500af89%26offsetms%3D5000%26itag%3Dw160%26sigh%3DGIOssF96p6rqs3uHlahnHuShDTc&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;And here's Snowfury doing its wild weasel routine.  The vision&lt;br /&gt;guidance is underdamped, so the robot "bounces" off the sides of&lt;br /&gt;the course, as it usually can only see one side at a time.  It had the&lt;br /&gt;second fastest lap time after Windsor, and lapped Snowtires, but&lt;br /&gt;incurred more penalties while doing so.  Definitely the&lt;br /&gt;"people's choice" and really entertaining to watch.&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: left;"&gt;Windsor took first, and UBC took places 2-6.  None of the other robots fielded were able to qualify to race, in some cases only due to issues with outdoor operation.  There were several impressive contenders, but in the end it was a Windsor/UBC field.  We're very pleased with the results, and we'll be passing a good legacy on to future Thunderbird robotics club members.&lt;br /&gt;&lt;br /&gt;A big thanks goes out to our sponsors, and to everyone who made this possible.  To our team leader, Dr. John Meech, and all the robotics club members this has been fantastic, thanks for one wild ride.&lt;br /&gt;&lt;br /&gt;-t&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-2974664798317099093?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=3898f7ccff90e2f1&amp;type=video%2Fmp4' length='0'/><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=52384ce94645ff70&amp;type=video%2Fmp4' length='0'/><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=99e04b5c1e689b60&amp;type=video%2Fmp4' length='0'/><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=c417986462111366&amp;type=video%2Fmp4' length='0'/><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=d4ddb1e90014a034&amp;type=video%2Fmp4' length='0'/><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=fdb5e22c1500af89&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/2974664798317099093/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=2974664798317099093' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/2974664798317099093'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/2974664798317099093'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2009/07/waterloo-robot-race-2009.html' title='Waterloo Robot Race 2009'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_bg57Qjxi-VY/Sm6BGsW0_XI/AAAAAAAAAFQ/6O86WSHJkZ8/s72-c/waterloorobotrace.JPG' height='72' width='72'/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-1348646445216967023</id><published>2009-06-14T12:16:00.000-07:00</published><updated>2009-06-14T12:41:53.302-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='video guidance pantilt cephalisation'/><title type='text'>Indoor testing with panning camera</title><content type='html'>Here's a video of a test run indoors.  I've incorporated the pan-tilt unit into the vision system, so the camera now turns in the direction the robot is steering.  This allows the vision system to image the road in the predicted direction without having to wait for the robot to roll forward and the chassis to turn.  This takes a large amount of latency out of the guidance loop and improves performance, allowing the robot to move faster.&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-e8c4e7f7a99ec76b" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v20.nonxt1.googlevideo.com/videoplayback?id%3De8c4e7f7a99ec76b%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143779%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D72ABD15C2A22824A71507EF7B3832D4926957620.86088CCF48098AC8BE5AD645522DFF11698825D6%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3De8c4e7f7a99ec76b%26offsetms%3D5000%26itag%3Dw160%26sigh%3DgspQwCqEKwUo02UHd8TuYPq9ebY&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v20.nonxt1.googlevideo.com/videoplayback?id%3De8c4e7f7a99ec76b%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143779%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D72ABD15C2A22824A71507EF7B3832D4926957620.86088CCF48098AC8BE5AD645522DFF11698825D6%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3De8c4e7f7a99ec76b%26offsetms%3D5000%26itag%3Dw160%26sigh%3DgspQwCqEKwUo02UHd8TuYPq9ebY&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;This is an example of cephalisation - placing sensors on a "head" whose orientation is not directly coupled with the main body, allowing the sensor suite to be directed independently from the body orientation.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-1348646445216967023?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=e8c4e7f7a99ec76b&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/1348646445216967023/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=1348646445216967023' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/1348646445216967023'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/1348646445216967023'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2009/06/indoor-testing-with-panning-camera.html' title='Indoor testing with panning camera'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-5875267777455508059</id><published>2009-06-11T14:09:00.001-07:00</published><updated>2009-06-11T14:27:49.395-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='vision guidance colour AI'/><title type='text'>The new guidance system</title><content type='html'>&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_bg57Qjxi-VY/SjFy4vn7G1I/AAAAAAAAAFI/9v4iOhYnESw/s1600-h/Picture+1.png"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 320px; height: 146px;" src="http://1.bp.blogspot.com/_bg57Qjxi-VY/SjFy4vn7G1I/AAAAAAAAAFI/9v4iOhYnESw/s320/Picture+1.png" alt="" id="BLOGGER_PHOTO_ID_5346180551847648082" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;Fig. 1: the guidance visualisation: on the left is the&lt;br /&gt;source image, and on the right is the perspective&lt;br /&gt;warped map of the ground ahead.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;Snowtires is a vision-guided robot, so here's a rundown of the the vision system works.  The basic idea is really simple: the robot veers away form any objects of a designated colour in front of it.  In practice this requires several steps:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Capture an image of the road ahead (left side of Fig. 1)&lt;/li&gt;&lt;li&gt;Determine the horizon line in the image (top of green box)&lt;/li&gt;&lt;li&gt;Determine the perspective transformation from the image to the ground plane.&lt;/li&gt;&lt;li&gt;Transform the section of the image below the horizon to see the image is though it were viewed orthogonally from above.  (Fig. 1 , right side)&lt;/li&gt;&lt;li&gt;Filter the transformed image to determine if there are any orange pixels (or whatever colour you're avoiding)&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Draw a selection of possible paths onto the image&lt;/li&gt;&lt;li&gt;Compute the number of orange pixels that are within a set distance of each curve - this will be the curve's penalty.&lt;/li&gt;&lt;li&gt;Choose the curve that passes over or near the fewest orange pixels&lt;/li&gt;&lt;/ol&gt;It sounds fairly simple, and it is with the help of OpenCV.  First, OpenCV allows the camera capture using the HighGUI functions.  I choose the horizon line manually, and hope that the robot doesn't rock forward or back too much...  You could use a horizon detector here, but I can't be bothered right now.&lt;br /&gt;&lt;br /&gt;Next comes the transformation.  This is really easy.  OpenCV has the function GetPerspectiveTransform which takes as inputs the corners of the rectangle in the source image and the corners of the trapezoid in the distorted image, and returns a 3x3 matrix representing the perspective transform in homogeneous coordinates.  Next, you feed the matrix and the imge into WarpPerspective, and it deposits the warped image into the map.  I draw the trapezoid just to be sure all my math is lining up.&lt;br /&gt;&lt;br /&gt;To filter the colour, first convert the map to the HSV (Hue, Saturation, Value) colour space.  The hue represents "colour" in the sense of where on the rim of the colour wheel that colour would be (0 is red, orange is 15, yellow is 30, etc etc), so we can filter out any pixels that are not within a threshold of the hue we want.  The saturation represents the colour's intensity.  The cones have extremely high saturation, whereas the saturation of the pavement is very low.  Filter any pixels with low saturation.  Finally, Value represents the grayscale illuminance of the colour.  I filter out any pixels that have really low value.&lt;br /&gt;&lt;br /&gt;That leaves only the bright orange pixels.  I create a series of curves, and apply a penalty to each curve dependent on the number of orange pixels within a certain distance (usually the image width/8) of the curve.  The curve with the least number of orange pixels within that range "wins" and its curvature is used to determine the steering output.  Note that in the figure, due to my ineptitude, curves with high penalties are green and curves with low penalties are red.  Sigh.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-5875267777455508059?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/5875267777455508059/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=5875267777455508059' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/5875267777455508059'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/5875267777455508059'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2009/06/new-guidance-system.html' title='The new guidance system'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_bg57Qjxi-VY/SjFy4vn7G1I/AAAAAAAAAFI/9v4iOhYnESw/s72-c/Picture+1.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-80589052755337174</id><published>2009-06-08T08:32:00.001-07:00</published><updated>2009-06-11T14:45:56.970-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='eeePC battery'/><title type='text'>eeePC battery issues</title><content type='html'>Immediately after the practice race I put the eeePC away in its sleeve.  About an hour later I pulled it out, only to discover that is was extremely hot - apparently it had not shut down properly and had overheated while unable to cool itself in the sleeve.  I removed the battery and allowed it to cool.  Fortunately, the eeePC still seems to work normally, however, the battery will no longer charge up - it remains at 33% charge no matter how long you charge it.  So, it looks like the battery was thermally damaged somehow.  I'll have to get it repaired or a new one - race day is a month away.&lt;br /&gt;&lt;br /&gt;&lt;update&gt;  The bettery is indeed damaged.  I haven't experimented with it yet but I suspect that the 33% reading is accurate and that's where this battery tops out now.  Anyhow, I got a new 8800 mAh battery to replace it, and I'm going to try to get NCIX to replace my existing battery under warranty.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-80589052755337174?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/80589052755337174/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=80589052755337174' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/80589052755337174'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/80589052755337174'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2009/06/eeepc-battery-issues.html' title='eeePC battery issues'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-7498189191757847589</id><published>2009-06-07T17:38:00.001-07:00</published><updated>2009-06-08T08:35:53.432-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='race practice video'/><title type='text'>So it's been a while...</title><content type='html'>Well, after five months I'm blogging again.  Only very recently did I make any tangible progress over what's been previously posted.  Now things are rolling again, and there's a lot to report from the past month or so of work, so I'll elaborate those over the next little while.&lt;br /&gt;&lt;br /&gt;First, what you really want to see: a video.&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-95128c594b5ae83" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v6.nonxt4.googlevideo.com/videoplayback?id%3D095128c594b5ae83%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143779%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D934126F3D151667752C997AF25792E90A92F0D9.4CDA2A304C73C1222B64FDBD11F283A2BFAB0077%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D95128c594b5ae83%26offsetms%3D5000%26itag%3Dw160%26sigh%3DUiDG3BWGQy3YW-PvdCdWPro7tt0&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v6.nonxt4.googlevideo.com/videoplayback?id%3D095128c594b5ae83%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143779%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D934126F3D151667752C997AF25792E90A92F0D9.4CDA2A304C73C1222B64FDBD11F283A2BFAB0077%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D95128c594b5ae83%26offsetms%3D5000%26itag%3Dw160%26sigh%3DUiDG3BWGQy3YW-PvdCdWPro7tt0&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;Here you see Snowtires in its new form doing a lap at the Thunderbird robotics club practice intramurals race day.  We set up a race to mock up the conditions of the actual Waterloo race in order to test the robots under realistic conditions.  The robots need to do laps of a concrete course lined with the usual orange cones.  Doing this outside introduces some new challenges, namely, outside there's an abundance of IR radiation going around, which completely blinds the camera if not filtered.  To this effect I installed a mirror-finish sunglass lens and a pair of polarizing filters to reduce glare and block IR.  This dims the image enough for effective vision even under direct sunlight.  The camera is now on a pan-tilt unit mounted front and center on the chassis.  It is coupled to a new guidance system that I will elaborate on later.  Other modifications include the replacement of the Arduino-based chassis controller with a Furious Module: a USB-based servo and sensor controller designed by the team's own Ash McKay (for details see: &lt;a href="http://www.ashleymckay.com/ashleymckay/cms/?q=node/195"&gt;his website&lt;/a&gt;).&lt;br /&gt;&lt;br /&gt;Snowtires won the practice race by completing three laps of the course with only a single error.  At the moment the guidance system only works at very low speed: I'll be attempting to improve that as time goes on, but we're getting close to the July 11th competition date.  Other requirements: a stop sign detector, a stop light detector, and a purple-object avoidance routine.  TIme to get back to work...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-7498189191757847589?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=95128c594b5ae83&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/7498189191757847589/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=7498189191757847589' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/7498189191757847589'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/7498189191757847589'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2009/06/so-its-been-while.html' title='So it&apos;s been a while...'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-3157840216775749390</id><published>2009-01-19T13:58:00.000-08:00</published><updated>2009-01-19T14:29:02.687-08:00</updated><title type='text'>Another test run</title><content type='html'>Here's the latest test run, this time using cones for the course markers.  It does two successful laps before missing a turn.  It would appear that the guidance has the most trouble with sharp turns, particularly if that results in it approaching a wall at a near-perpendicular angle.  Future improvements will hopefully address this problem.&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-bdcf24725aaafa41" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v1.nonxt8.googlevideo.com/videoplayback?id%3Dbdcf24725aaafa41%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143779%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D6D91195C25CDFC714CB8F4747D686F73F8D17EB3.6757CD4723159219B7B4AB9CAB89314BA1058AD8%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Dbdcf24725aaafa41%26offsetms%3D5000%26itag%3Dw160%26sigh%3DZf1FOC5usk7ihVy_5dz32fIW8II&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v1.nonxt8.googlevideo.com/videoplayback?id%3Dbdcf24725aaafa41%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143779%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D6D91195C25CDFC714CB8F4747D686F73F8D17EB3.6757CD4723159219B7B4AB9CAB89314BA1058AD8%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Dbdcf24725aaafa41%26offsetms%3D5000%26itag%3Dw160%26sigh%3DZf1FOC5usk7ihVy_5dz32fIW8II&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;P.S. If the video plays absurdly fast, just restart it.  Some browsers seem to have an issue with the video playback.&lt;br /&gt;&lt;br /&gt;P.P.S.  If you're wondering at the three-month gap in posting, I've been finishing my Master's thesis, and have only recently reemerged into the sunlit world.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-3157840216775749390?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=bdcf24725aaafa41&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/3157840216775749390/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=3157840216775749390' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/3157840216775749390'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/3157840216775749390'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2009/01/another-test-run.html' title='Another test run'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-1942508226175540295</id><published>2008-10-21T15:34:00.000-07:00</published><updated>2008-10-21T15:40:34.515-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='video'/><category scheme='http://www.blogger.com/atom/ns#' term='testrun'/><category scheme='http://www.blogger.com/atom/ns#' term='eeePC'/><title type='text'>A new video</title><content type='html'>As you can see in the following video, the eeePC now operates the robot.  However, there are some issues.  Since it's not nearly as powerful as the Macbook Pro, I had to reduce the resolution of the input image.  This makes the line-finding less precise.  Also, it's not yet tuned properly, so you can see it tends to overcorrect and constantly be "bouncing" off the sides of the course.  You can see as it rounds the curve that the guidance picks up the left line of the course as the right line by accident, causing it to run between the two sides of the U-shaped course.  Needs some work.&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-9b85e88e5c2b7048" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v23.nonxt8.googlevideo.com/videoplayback?id%3D9b85e88e5c2b7048%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143779%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D3CC90473AD6BAA0A6A068AF96317D0C0E0E3F845.17D921F7904CB36727F20A1E78D87288DFA42720%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D9b85e88e5c2b7048%26offsetms%3D5000%26itag%3Dw160%26sigh%3DlKX3DQz_kke3gYYkXWYzvLtI66c&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v23.nonxt8.googlevideo.com/videoplayback?id%3D9b85e88e5c2b7048%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143779%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D3CC90473AD6BAA0A6A068AF96317D0C0E0E3F845.17D921F7904CB36727F20A1E78D87288DFA42720%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D9b85e88e5c2b7048%26offsetms%3D5000%26itag%3Dw160%26sigh%3DlKX3DQz_kke3gYYkXWYzvLtI66c&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-1942508226175540295?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=9b85e88e5c2b7048&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/1942508226175540295/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=1942508226175540295' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/1942508226175540295'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/1942508226175540295'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/10/new-video.html' title='A new video'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-3692241504137919833</id><published>2008-10-21T15:19:00.000-07:00</published><updated>2008-10-21T15:34:14.027-07:00</updated><title type='text'>eeePC up and running</title><content type='html'>Lately I've been a bit busy, but there's been some progress.  The eeePC now has full functionality and can operate the vehicle in place of the Macbook Pro.  Here are some pics:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_bg57Qjxi-VY/SP5V-GukvlI/AAAAAAAAADM/Sl6SHHzroIg/s1600-h/DSCN3849.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://1.bp.blogspot.com/_bg57Qjxi-VY/SP5V-GukvlI/AAAAAAAAADM/Sl6SHHzroIg/s320/DSCN3849.JPG" alt="" id="BLOGGER_PHOTO_ID_5259735940261527122" border="0" /&gt;&lt;/a&gt;First, the eeePC with the screen shut on its new aluminium tray on the Stampede.  Note the webcam between the two front springs.  It's a USB2 Logitech Quickcam Deluxe for Notebooks.  It's got a glass lens and no autofocus.  (Autofocus can play havoc with vision software, as autofocus will change the image's focus without warning.)&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_bg57Qjxi-VY/SP5Wms3G-II/AAAAAAAAADU/8sFrRykgbsg/s1600-h/DSCN3852.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://1.bp.blogspot.com/_bg57Qjxi-VY/SP5Wms3G-II/AAAAAAAAADU/8sFrRykgbsg/s320/DSCN3852.JPG" alt="" id="BLOGGER_PHOTO_ID_5259736637692639362" border="0" /&gt;&lt;/a&gt;This shot shows the eeePC with the screen open.  This setup means that I can walk behind the robot and see what it's seeing: this is very useful for debugging the guidance.  The grey USB cable goes to the microcontroller.  The black USB cable goes to the camera.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_bg57Qjxi-VY/SP5W9mS1KtI/AAAAAAAAADc/ApfZyUa6Lp0/s1600-h/DSCN3842.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://4.bp.blogspot.com/_bg57Qjxi-VY/SP5W9mS1KtI/AAAAAAAAADc/ApfZyUa6Lp0/s320/DSCN3842.JPG" alt="" id="BLOGGER_PHOTO_ID_5259737031066856146" border="0" /&gt;&lt;/a&gt;The chassis remains largely unchanged.  The computer tray attaches to the four body posts that used to hold the lexan truck body on.  It can be removed by taking out the four retaining clips.  A piece of scrap lexan from a keyboard's packaging makes a small tray to hold the Arduino microcontroller (blue, on right side of vehicle) and the wire breakout board (green, left side of vehicle).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-3692241504137919833?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/3692241504137919833/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=3692241504137919833' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/3692241504137919833'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/3692241504137919833'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/10/eeepc-up-and-running.html' title='eeePC up and running'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_bg57Qjxi-VY/SP5V-GukvlI/AAAAAAAAADM/Sl6SHHzroIg/s72-c/DSCN3849.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-5275944637194094047</id><published>2008-08-19T14:55:00.000-07:00</published><updated>2008-09-01T15:46:55.088-07:00</updated><title type='text'>Ubuntu Install via external optical drive</title><content type='html'>If you have better luck than I, you may be able to install Ubuntu 8.04 from a USB stick.  If you read my previous post, you'll know that I can't get that to work.&lt;br /&gt;&lt;br /&gt;So here's what to do:  beg, buy or borrow a USB2 DVD drive.  (I went with "buy").  The helpful guy at the Future Shop sold me a &lt;span class="tx-heading3-dgrey"&gt;LG 20X Super Multi External DVD Rewriter (GE20)&lt;/span&gt;, which just happened to be the cheapest USB2-optical device available in my area of the city.  He warned me that some computers' BIOS' support booting from USB2 drives and some don't.  Given that the eeePC comes with a recovery DVD and support CD, I assumed that it was able to boot from an external optical drive.  This turned out to be correct.&lt;br /&gt;&lt;br /&gt;So, I booted from the Xubuntu 8.04 Live CD, and lo and behold, the eeePC boots!  (It refuses to do so with almost all of the USB drives I tried to create.)  Up comes the load screen, and then the Live session begins.  I chose to install Xubuntu.  I won't go into the details here, because the install failed.  I think, in retrospect, this is because I chose to change the partition setup, but I did not click the little "format" checkboxes in the installer.  Whatever the reason, the installer fails due to an unspecified I/O error at 53% into the install process (This happened twice in two attempts, at the identical point.)&lt;br /&gt;&lt;br /&gt;So I tried booting from the Ubuntu 8.04 CD.  The only difference here is that Ubuntu uses the Gnome desktop, and Xubuntu uses the XFCE lightweight desktop.&lt;br /&gt;&lt;br /&gt;The Ubuntu live session booted, and I started the install.  When asked how I wanted to partition the drive, I chose "manual".  In its stock (Xandros) configuration, the drive has 4 partitions on the fast 4Gb motherboard-mounted hard disk and two on the slower 16Gb removable hard disk.   The first thing is to select "new partition table" for each drive.  For the 4Gb drive, I created one partition, in the ext2 format.  The "mount point" is "/", to indicate that the root of the filesystem goes in that drive, with all the system files.  Be sure to check the "format" checkbox to ensure that the drive is wiped before installing, as I think omitting that killed the Xubuntu installer.  For the 16Gb drive, I made one partition, in ext3 format, mount point "/home", to indicate that the user's files will go on this drive.  Again check the "format" checkbox.  When you accept the configuration, it will warn you that you have not allocated any swap space.  This can affect performance when you use a lot of RAM, but using the SSD drives for swap space can reduce their lifetime, as they have a finite number of writes before they die.  I hope the system can function well without swap.  We shall see.  It also warns that this will wipe any files on the drives.  I don't have anything of importance on my machine, but if you do, then don't hit that button until you copy your files somewhere safe.&lt;br /&gt;&lt;br /&gt;The rest of the installation went fine.  I was worried that Gnome would be too resource-intensive for the eeePC but it runs well, even with some of the graphical effects turned on.  I will detail the setup later once I have it working, but suffice to say that within an hour of installing Ubuntu, I had working Wifi, Ethernet, custom keys on the keyboard, installed build-essential, got the camera working, and installed subversion and GTK.&lt;br /&gt;&lt;br /&gt;Now that Ubuntu is installed and configured, it's like night and day.  I will never go back to the default Xandros OS.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-5275944637194094047?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/5275944637194094047/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=5275944637194094047' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/5275944637194094047'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/5275944637194094047'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/08/ubuntu-install-via-external-optical.html' title='Ubuntu Install via external optical drive'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-4790629255621898762</id><published>2008-08-19T14:38:00.000-07:00</published><updated>2008-08-19T15:25:19.197-07:00</updated><title type='text'>USB-Install hell</title><content type='html'>So, the consensus among my Linux-savvy friends regarding getting GTK, gcc, glut and opencv working on the eeePC was a resounding "GET RID OF XANDROS!".  The rest of the robotics club uses Ubuntu or the lightweight derivative Xubuntu.  People have reported various levels of success on eeeUser regarding Ubuntu installs, so I decided to give it a shot.&lt;br /&gt;&lt;br /&gt;It was at this point I discovered that I have some sort of curse regarding bootable USB drives.  I tried creating bootable Xubuntu, Ubuntu, Kubuntu (all 8.04),  and eeeXubuntu (7.??) USB drives to install some favour of Ubuntu on my eeePC.&lt;br /&gt;&lt;br /&gt;Here's a list of tutorials that I tried in turn:&lt;br /&gt;&lt;br /&gt;First, I made an eeeXubuntu USB install using this tutorial: &lt;a href="http://wiki.eeeuser.com/ubuntu:eeexubuntu:home"&gt;http://wiki.eeeuser.com/ubuntu:eeexubuntu:home&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The tutorial and script work quite well, and I created an eeeXubuntu USB drive which boots on my eeePC.  Great, right?  Well no.  Discussion on the eeeUser forum indicates that eeeXubuntu doesn't work so well on the eee PC 901, the model I have.  Apparently it's better to install the vanilla version of the newer 8.04 version of Ubuntu or its derivatives Kubuntu or Xubuntu.  Alright.  I'll do that:&lt;br /&gt;&lt;br /&gt;------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;So next I tried these:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.pendrivelinux.com/2008/05/21/usb-xubuntu-804-persistent-install-from-live-cd/"&gt;http://www.pendrivelinux.com/2008/05/21/usb-xubuntu-804-persistent-install-from-live-cd/&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.pendrivelinux.com/2008/05/15/usb-kubuntu-804-persistent-install-via-the-live-cd/"&gt;http://www.pendrivelinux.com/2008/05/15/usb-kubuntu-804-persistent-install-via-the-live-cd/&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.pendrivelinux.com/2008/05/08/usb-ubuntu-804-persistent-install-via-the-live-cd/"&gt;http://www.pendrivelinux.com/2008/05/08/usb-ubuntu-804-persistent-install-via-the-live-cd/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;All three of these failed with the same fdisk error: "WARNING: re-reading the partition table failed with error: 22.  Invalid Argument."&lt;br /&gt;&lt;br /&gt;Also, if you can get past this, the tutorials require downloading syslinux during the Live session, and of course, neither ethernet nor wifi worked during the Live session on any of the three computers I used to attempt this.&lt;br /&gt;&lt;br /&gt;------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;A helpful person on the eeeUser forum suggested Unetbootin:  &lt;a href="http://unetbootin.sourceforge.net/"&gt;http://unetbootin.sourceforge.net/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I tried this using a Windows machine, and the process went smoothly.  However, the eeePC refused to boot from the USB drive, though my MacBook Pro and a PC tower both would.&lt;br /&gt;&lt;br /&gt;------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;Next I tried this:&lt;br /&gt;&lt;a href="http://www.pendrivelinux.com/2008/04/09/usb-ubuntu-804-installation-from-windows/"&gt;http://www.pendrivelinux.com/2008/04/09/usb-ubuntu-804-installation-from-windows/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;This created a working Ubuntu installation as well, but again, the eee PC 901 refused to boot from it.&lt;br /&gt;&lt;br /&gt;------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;At this point I was just really pissed off and about ready to hurl the Live CDs, USB keys and the rest out the window.  I'd probably spent about 12 hours trying to make these various USB installs at this point.&lt;br /&gt;&lt;br /&gt;The solution?  Get an external USB2 DVD drive.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-4790629255621898762?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/4790629255621898762/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=4790629255621898762' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/4790629255621898762'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/4790629255621898762'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/08/usb-install-hell.html' title='USB-Install hell'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-7956012316991239720</id><published>2008-08-17T09:47:00.000-07:00</published><updated>2008-08-17T10:29:27.791-07:00</updated><title type='text'>GTK woes</title><content type='html'>The OpenCV library provides image capture, processing, and a display GUI for vision programs.  It forms the foundation of my guidance programs.  It relies on the GTK interface library for image capture and the GUI elements.  The GTK binaries are functional on the eeePC, but the development files necessary to compile GTK support into OpenCV are missing.  All attempts to install them (from the libgtk2.0-dev package or others) have failed.  I think the writing is on the wall for the built-in Xandros OS.  I'm going to try to install eeeXubuntu, the modified Ubuntu distro that's configured for the eeePC.  We'll see how that goes.  I'm going to try to preserve the restore partition so that I can bring back the Xandros if necessary.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-7956012316991239720?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/7956012316991239720/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=7956012316991239720' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/7956012316991239720'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/7956012316991239720'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/08/gtk-woes.html' title='GTK woes'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-1732758054243166480</id><published>2008-08-10T23:16:00.000-07:00</published><updated>2008-08-10T23:21:05.088-07:00</updated><title type='text'>Arduino setup on Linux</title><content type='html'>The Arduino site has eeePC-specific instructions for setting up the Arduino environment.  It turns out to be as simple as installing a few packages and then uncompressing the Linux Arduino software.  Just follow the links:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.arduino.cc/en/Main/Software"&gt;The Arduino Download page&lt;/a&gt;.&lt;br /&gt;&lt;a href="http://www.arduino.cc/playground/Learning/Linux"&gt;Arduino for Linux instructions&lt;/a&gt;.&lt;br /&gt;&lt;a href="http://www.arduino.cc/playground/Linux/Xandros"&gt;Arduino for eeePC Xandros Linux instructions&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Note: while the instructions say to use the Debian repositories to get your packages, it is better to use the Xandros repositories.  If you have not already, go back two entries in this blog to see how to set this up.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-1732758054243166480?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/1732758054243166480/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=1732758054243166480' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/1732758054243166480'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/1732758054243166480'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/08/arduino-setup-on-linux.html' title='Arduino setup on Linux'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-6654814950257010740</id><published>2008-08-10T23:08:00.001-07:00</published><updated>2008-08-10T23:11:17.809-07:00</updated><title type='text'>A pic for scale</title><content type='html'>&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_bg57Qjxi-VY/SJ_XdxofHFI/AAAAAAAAAC0/5F83uNWNjmk/s1600-h/RobotAndEeePC.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://4.bp.blogspot.com/_bg57Qjxi-VY/SJ_XdxofHFI/AAAAAAAAAC0/5F83uNWNjmk/s320/RobotAndEeePC.jpg" alt="" id="BLOGGER_PHOTO_ID_5233138198567132242" border="0" /&gt;&lt;/a&gt;Snowtires and the eeePC&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: left;"&gt;So I pulled the laptop podium off the robot and I'm preparing to make a cradle for the eeePC.  Above is a picture for scale.  The Stampede's suspension takes the weight easily, unlike the Apple which compressed the springs all the way down.&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-6654814950257010740?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/6654814950257010740/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=6654814950257010740' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/6654814950257010740'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/6654814950257010740'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/08/pic-for-scale.html' title='A pic for scale'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_bg57Qjxi-VY/SJ_XdxofHFI/AAAAAAAAAC0/5F83uNWNjmk/s72-c/RobotAndEeePC.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-7413965362969332705</id><published>2008-08-07T22:28:00.000-07:00</published><updated>2008-08-10T23:22:49.667-07:00</updated><title type='text'>Setting up the eee PC</title><content type='html'>For the eee PC to function as the robot's computer, it needs several things:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;A fully-featured development tools set, including gcc, make and the standard libraries.  These are not installed by default on the stock eee Xandros system.&lt;/li&gt;&lt;li&gt;A regular Linux desktop, with the ability to easily control settings and active devices.&lt;/li&gt;&lt;li&gt;A working install of OpenCV - the Open Computer Vision library, which forms the basis of all my vision code.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;The usual extra tools, like a decent text editor, image editor, and video codecs.&lt;/li&gt;&lt;/ol&gt;The default eee PC interface is a launcher-style tabbed menu.  It has a terminal and a file browser, but it's not well-suited to development use.  Fortunately, there's an "Advanced Mode" which is just a version of the KDE linux desktop.  Instructions for installing and invoking his mode are on the eeeUser wiki: &lt;a href="http://wiki.eeeuser.com/howto:getkde"&gt;here&lt;/a&gt;.  Use method #1, "the Easy Way".  Do not use method #4.  I tried that first and it prevented the system from booting up properly.&lt;br /&gt;&lt;br /&gt;** EDIT: The following turned out to be  BAD IDEA.  Correction Below. ** [ To install the dev tools, follow the instructions on &lt;a href="http://technologycast.wordpress.com/2007/12/30/my-asus-eee-pc/"&gt;this&lt;/a&gt; blog.  The short version is to add the main debian repository for the apt-get package manager.  With that as a source, apt-get can download and install the package called build-essential, which contains compilers, linkers, debuggers, build tools, and all that good stuff.] **  End Bad Idea **&lt;br /&gt;&lt;br /&gt;Installing Debian packages can cause all sorts of incompatibilities, so don't do the above.  Instead, install Xandros packages onto your Xandros-based eeePC.  What logic.  Anyway, the right instructions are &lt;a href="http://wiki.eeeuser.com/addingxandrosrepos"&gt;here&lt;/a&gt;.  Once you've set up apt-get to pull software from the Xandros repositories, you can then use the console to  run the following commands:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&gt; sudo apt-get install build-essential&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&gt; sudo apt-get install pkg-config&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This will install compilers such as gcc, build tools, and all the other stuff you need to write/compile software.&lt;br /&gt;&lt;br /&gt;Now that you have gcc and all the rest, you can download the OpenCV source from &lt;a href="http://sourceforge.net/projects/opencvlibrary/"&gt;its page on sourceforge&lt;/a&gt;.  For me, OpenCV installed without a hitch.  The final glitch is that any program that uses OpenCV needs to know where to find the OpenCV runtime libraries.  The installer placed the libraries in /usr/local/lib/, so I added the line:&lt;br /&gt;&lt;br /&gt;export LD_LIBRARY_PATH=/usr/local/lib&lt;br /&gt;&lt;br /&gt;to the end of the file  ".bash_profile" in th main user's home directory.  This sets up the dynamic link path so that the shell can pass this on to the executable and it can find the libraries.  Now your executables will run.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-7413965362969332705?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/7413965362969332705/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=7413965362969332705' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/7413965362969332705'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/7413965362969332705'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/08/setting-up-eee-pc.html' title='Setting up the eee PC'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-3269194960138775010</id><published>2008-08-06T14:19:00.000-07:00</published><updated>2008-08-06T14:29:03.011-07:00</updated><title type='text'>eee PC Arrives</title><content type='html'>It's here.  The eee PC finally arrived.  It's really cool, really small, and has amazing battery life (with its 6-cell battery).  The built-in Xandros-Linux-derived interface is pretty slick, and the included software is cool, but I think a Xubuntu install will get the most out of this little beast.  The small keyboard is going to take some getting used to, but my first impressions are good.&lt;br /&gt;&lt;br /&gt;With regards to the robot, it remains to be seen how well thi machine stands up to the rigors of vision processing, but it can play back video smoothly and it handles the OpenGL Tux Racer game with aplomb, so I'm not too worried.  The vision algorithms work just as well at 320x240 resolution as they do in 640x480, so if this machine can b 1/4 as fast as the Apple it should still work.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-3269194960138775010?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/3269194960138775010/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=3269194960138775010' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/3269194960138775010'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/3269194960138775010'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/08/eee-pc-arrives.html' title='eee PC Arrives'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-443364664582103512</id><published>2008-08-02T20:10:00.000-07:00</published><updated>2008-12-09T18:05:31.216-08:00</updated><title type='text'>Success</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_bg57Qjxi-VY/SJUlShvF43I/AAAAAAAAACs/RbiTAIEmzk0/s1600-h/Snowtires.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://3.bp.blogspot.com/_bg57Qjxi-VY/SJUlShvF43I/AAAAAAAAACs/RbiTAIEmzk0/s320/Snowtires.jpg" alt="" id="BLOGGER_PHOTO_ID_5230127542484460402" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;The robot works.  It rolled around under its own power for the first time.  There is a huge amount of work yet to be done, but this proves to concept.  I used my MacBook because the eee PC still hasn't arrived.  It looks like Canada lost out when it came to getting part of the first wave of shipments.  I had to take the rear shocks and springs out and replace them with solid links to take the weight.  Hopefully the eee PC will arrive soon and halve the payload.&lt;br /&gt;&lt;br /&gt;Here's a video of the robot following a path marked by green lines.  It works fairly well, but it definitely makes errors, as witnessed at the end of the video.  I don't have a wheel encoder working yet, so I have to adjust the throttle manually to keep the robot moving as the battery level drops.&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-b3679ee662e4bc13" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v17.nonxt5.googlevideo.com/videoplayback?id%3Db3679ee662e4bc13%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143781%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D33F1941618CDF25046100BBB3E475C7EC56DDE09.5CC07F494F294ED024B32FB3F1D5B69BE7A2F8ED%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Db3679ee662e4bc13%26offsetms%3D5000%26itag%3Dw160%26sigh%3DOpWnRYV2G23IfWORnETNXb1Mceo&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v17.nonxt5.googlevideo.com/videoplayback?id%3Db3679ee662e4bc13%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143781%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D33F1941618CDF25046100BBB3E475C7EC56DDE09.5CC07F494F294ED024B32FB3F1D5B69BE7A2F8ED%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3Db3679ee662e4bc13%26offsetms%3D5000%26itag%3Dw160%26sigh%3DOpWnRYV2G23IfWORnETNXb1Mceo&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: left;"&gt;This is a good moment to thank everyone who's helped me get this project going.  Particularly everyone in the UBC Thunderbird Robotics Team, without whose help this project would never have even begun, much less gone anywhere.&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-443364664582103512?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=b3679ee662e4bc13&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/443364664582103512/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=443364664582103512' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/443364664582103512'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/443364664582103512'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/08/success.html' title='Success'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_bg57Qjxi-VY/SJUlShvF43I/AAAAAAAAACs/RbiTAIEmzk0/s72-c/Snowtires.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-6097220730749417475</id><published>2008-07-17T22:21:00.000-07:00</published><updated>2008-07-19T23:07:02.232-07:00</updated><title type='text'>USB Communication part II</title><content type='html'>The Arduino can receive string signals from the computer, but the computer has to send them.  I have searched high and low for a multi-platform API to connect to a USB device and send strings to it in C++.  No luck.  Under windows there's CSerial, and Linux has libUSB, but instructions on how to use them are sparse, particularly on Unix/Linux.&lt;br /&gt;So I turned to Python.  Python is an interpreted language, useful for rapid prototyping software and scripting.  It also has a brilliant USB communications library called pyserial.  It also can be embedded in a C++ program.  What follows is at best a hack.  At worst it's a terrible kludge.  Either way it works quite well.  Python is installed by default on the Mac OS, so I didn't have to do anything beyond finding the right include directory.  You can download it from &lt;a href="http://www.python.org/"&gt;python.org&lt;/a&gt; and pyserial from &lt;a href="http://pyserial.wiki.sourceforge.net/pySerial"&gt;sourceforge&lt;/a&gt;.  Using Python to send messages over the USB connection is impressively simple.  The test code looks like this:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;import serial&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;import time&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;ser = serial.Serial('/dev/tty.usbserial',9600)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;time.sleep(2)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;ser.write('Any message string you want.')&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;time.sleep(0.1)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;ser.write('Another message string')&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;time.sleep(1.0)&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The sleep commands ensure that the serial connection has time to start up (in the first case), and that it has time to transmit before the script ends (in the last case).  In between, the connection buffers all the messages you send so the middle sleep isn't technically necessary.&lt;br /&gt;&lt;br /&gt;Now I need to insert these commands into a C++ program.  Fortunately, this is simple too.  If you #include Python.h &lt;python.h&gt; you gain access the the Python interpreter.  I tried several different tutorials for using the various functions in Python.h, but the one that worked the best was the simple "PyRun_SimpleString(char* str);".  With that, you can simply create your Python command in a char[] string in C++ and send it off.  With that in mind I created the following wrapper class called serialBridge, which encapsulates the python commands including the setup and shutdown.&lt;br /&gt;&lt;br /&gt;Here's the code:&lt;br /&gt;&lt;a href="http://www.mech.ubc.ca/%7Emabauman/Files/robot/serialBridge.h"&gt;serialBridge.h&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.mech.ubc.ca/%7Emabauman/Files/robot/serialBridge.cpp"&gt;serialBridge.cpp&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;And here's how to use it:&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;br /&gt;#include "iostream"&lt;iostream&gt;&lt;/iostream&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;#include "Python.h"&lt;python.h&gt;&lt;/python.h&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;#include "serialBridge.h"&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;using namespace std;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;int main()&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  rSerial::serialBridge ser;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  ser.setObserverStream(&amp;amp;cout);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  ser.init("/dev/tty.usbserial",9600);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  ser.delay(2.0);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  for(int i = 0; i &lt;&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    ser.sendString("\"#");&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    ser.delay(1);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    ser.sendString("\"~");&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    ser.delay(1);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  return 0;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/python.h&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-6097220730749417475?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/6097220730749417475/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=6097220730749417475' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/6097220730749417475'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/6097220730749417475'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/07/usb-communication-part-ii.html' title='USB Communication part II'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-880883475572409045</id><published>2008-07-11T15:13:00.000-07:00</published><updated>2008-12-09T18:05:31.420-08:00</updated><title type='text'>Ordered a computer</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_bg57Qjxi-VY/SHfgIjQDuZI/AAAAAAAAACc/grq6YMMINPo/s1600-h/eeepc901s.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://3.bp.blogspot.com/_bg57Qjxi-VY/SHfgIjQDuZI/AAAAAAAAACc/grq6YMMINPo/s320/eeepc901s.jpg" alt="" id="BLOGGER_PHOTO_ID_5221888730465548690" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;I just put in a preorder for an ASUS eee PC 901 at NCIX.  They had the Windows-equipped versions sitting right there on the counter, but I decided to wait for the Linux version.  Why?  Two reasons.  The first is that for the same price, the Linux version come with a 20Gb Solid-State hard disk, as compared the 12Gb SSD in the Windows version.  This offsets the cost of the Windows license.  The second reason is that if I did get the Windows version, I'm stuck with an OEM copy of Windows XP Home on the computer, with no install disks.  So that means that putting Xubuntu or some other flavour of Linux on the machine means wiping out that windows install and possibly never getting it back.  I'll wait a week or two for the better machine with the free OS, thanks.  I don't know if the stock Xandros-based Linux flavour will be okay or whether I should wipe it and install another distro.  Time will tell.&lt;br /&gt;&lt;br /&gt;The specs look like this:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;ASUS Eee PC 901.&lt;/li&gt;&lt;li&gt;Intel Atom 1.6 GHz Diamondville Processor.&lt;/li&gt;&lt;li&gt;1 Gb of DDR2-533/667 RAM (planning an upgrade to 2Gb).&lt;/li&gt;&lt;li&gt;20 Gb Solid-State Hard Disk (4Gb on motherboard plus 16Gb in removable SSD).&lt;/li&gt;&lt;li&gt;8.9in 1024x600 LCD Display.&lt;/li&gt;&lt;li&gt;802.11n (draft) wireless.&lt;/li&gt;&lt;li&gt;1.3 Megapixel webcam.&lt;/li&gt;&lt;li&gt;Bluetooth onboard.&lt;/li&gt;&lt;li&gt;Xandros Linux preinstalled (Replace with Xubuntu?).&lt;/li&gt;&lt;li&gt;6 Cell battery - they claim 4-8 hours of life.  I'm skeptical, but hopeful.&lt;/li&gt;&lt;li&gt;3 USB ports, an SD card reader, VGA-out and ethernet.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Final price: $617.59 CAN.&lt;/li&gt;&lt;/ul&gt;The only thing missing is firewire, and I'm sure I can find a decent USB camera, so I'm not worried.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-880883475572409045?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/880883475572409045/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=880883475572409045' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/880883475572409045'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/880883475572409045'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/07/ordered-computer.html' title='Ordered a computer'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_bg57Qjxi-VY/SHfgIjQDuZI/AAAAAAAAACc/grq6YMMINPo/s72-c/eeepc901s.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-2532916896237220786</id><published>2008-07-10T18:23:00.000-07:00</published><updated>2008-12-09T18:05:31.647-08:00</updated><title type='text'>Vision Software</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_bg57Qjxi-VY/SHa9128kipI/AAAAAAAAACU/KfZCOFN9oL4/s1600-h/LineDetect.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://4.bp.blogspot.com/_bg57Qjxi-VY/SHa9128kipI/AAAAAAAAACU/KfZCOFN9oL4/s320/LineDetect.jpg" alt="" id="BLOGGER_PHOTO_ID_5221569550962952850" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;In order to guide the robot I need to process video data from a camera.  Initially, the goal is to get the robot to travel down a course defined by two rows of orange cones.  This is the basis of the Waterloo Robot Racing competition.  A simple algorithm to guide the robot tries to detect two rows of cones as lines forming two sides of a triangle.  By heading towards the center of the triangle we will (roughly) head down the course.  Obviously, we'll have to handle cases where the robot can't see two distinct lines.  This can happen when the robot isn't pointing down the course, or when the rows of cones don't resolve themselves into easily distinguished rows.&lt;br /&gt;&lt;br /&gt;For now, I'm using OpenCV to capture frames from a camera.  This is surprisingly easy to do with many USB or firewire cameras when you have drivers.  OpenCV also provides the functions for the colour space conversion to HSV and the Hough transform line detection.  The algorithm looks like this:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Capture a frame from the camera&lt;/li&gt;&lt;li&gt;Convert the image to the HSV (hue, saturation, value) colour space.  The hue channel tells us the colour of the pixel as an angle in a colour wheel.  The saturation channel tells us how strong the colour is.&lt;/li&gt;&lt;li&gt;Create a binary image where a pixel is zero unless the corresponding image pixel has a hue angle near to orange and a high saturation.&lt;/li&gt;&lt;li&gt;Use a Hough Transform to detect lines in the binary image.  The Hough Transform works by comparing many candidate lines to the image, and letting pixels "vote" for any line they lie upon.  It returns the lines that have large numbers of votes.&lt;/li&gt;&lt;li&gt;Group the lines into those with positive vs. negative slope.  Compute an average for each group of lines.&lt;/li&gt;&lt;li&gt;The triangle is formed by these two average lines.  The bottom of the image provides the third line.  Compare the center of the triangle to the vertical centerline of the image to get a value for the robot's steering.&lt;/li&gt;&lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-2532916896237220786?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/2532916896237220786/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=2532916896237220786' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/2532916896237220786'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/2532916896237220786'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/07/vision-software.html' title='Vision Software'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_bg57Qjxi-VY/SHa9128kipI/AAAAAAAAACU/KfZCOFN9oL4/s72-c/LineDetect.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-3754645618289339808</id><published>2008-06-25T18:01:00.001-07:00</published><updated>2008-06-25T18:19:21.792-07:00</updated><title type='text'>Spur Gear Wobble</title><content type='html'>The gears have been making a lot of noise, and it looks like it's because the spur gear is wobbling.  (The spur gear is the large black plastic gear that receives power from the metal pinion gear on the motor.)  Here's a video of the gear wobbling:&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-5b151978fc607531" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v6.nonxt6.googlevideo.com/videoplayback?id%3D5b151978fc607531%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143782%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D6BC201830AD4F39D9618CF57098182F1EDB58E8F.3ED3861569852F6F9FDCE704501173F4AABE0A51%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D5b151978fc607531%26offsetms%3D5000%26itag%3Dw160%26sigh%3Dnh0_6uSgEiIR7PN8zDpCQN5rN7k&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v6.nonxt6.googlevideo.com/videoplayback?id%3D5b151978fc607531%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143782%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D6BC201830AD4F39D9618CF57098182F1EDB58E8F.3ED3861569852F6F9FDCE704501173F4AABE0A51%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D5b151978fc607531%26offsetms%3D5000%26itag%3Dw160%26sigh%3Dnh0_6uSgEiIR7PN8zDpCQN5rN7k&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;The strange thing is that both this and the replacement spur gear wobble in the same way.  So I thought it might be the transmission top shaft.  With the spur gear off, you can see that the top shaft doesn't wobble.&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-9cf8c1456e374802" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v19.nonxt7.googlevideo.com/videoplayback?id%3D9cf8c1456e374802%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143782%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D2C01F8240A429F5AAC26BF7D14B1CABE337B5615.5640069C35BAC15CC1EA1A09F87C878B5046B2D5%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D9cf8c1456e374802%26offsetms%3D5000%26itag%3Dw160%26sigh%3DwUG4MVmpDwYgIw2vMWmhz-7wMOw&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v19.nonxt7.googlevideo.com/videoplayback?id%3D9cf8c1456e374802%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143782%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D2C01F8240A429F5AAC26BF7D14B1CABE337B5615.5640069C35BAC15CC1EA1A09F87C878B5046B2D5%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D9cf8c1456e374802%26offsetms%3D5000%26itag%3Dw160%26sigh%3DwUG4MVmpDwYgIw2vMWmhz-7wMOw&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;So I'm not sure what's wrong: it might be the slipper clutch assembly that lies inside the spur gear: if it's not square, then the spur gear which attaches to it would also wobble.  I hope it's not the clutch: it's expensive.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-3754645618289339808?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=5b151978fc607531&amp;type=video%2Fmp4' length='0'/><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=9cf8c1456e374802&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/3754645618289339808/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=3754645618289339808' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/3754645618289339808'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/3754645618289339808'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/06/spur-gear-wobble.html' title='Spur Gear Wobble'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-8018497012166602308</id><published>2008-06-24T15:25:00.000-07:00</published><updated>2008-06-24T15:30:46.131-07:00</updated><title type='text'>Addendum - Pin # change on the Arduino</title><content type='html'>If you're actually using the code, you may have noticed that I changed the signal pin numbers (t_chassis.h).  They were originally 12 (steering) and 13 (drive).  However, pin 13 also connects to the Arduino's onboard LED, so I'd prefer to leave that one unused, or connect it to an LED on the outside of the robot for debugging purposes.  Thus, I have changed the signal pins to pins # 11(steering) and #12(drive).  I had to make a new adapter board to accommodate this.  The only difference is that the connector going to the Arduino has four pins instead of three, plugging into digital pins GND, 13, 12 and 11.  Pin 13 is currently not connected to anything.  Aide from the pin # changes, everything else is the same.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-8018497012166602308?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/8018497012166602308/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=8018497012166602308' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/8018497012166602308'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/8018497012166602308'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/06/addendum-pin-change-on-arduino.html' title='Addendum - Pin # change on the Arduino'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-8182857389777963153</id><published>2008-06-19T20:17:00.000-07:00</published><updated>2008-06-19T20:46:10.552-07:00</updated><title type='text'>USB Communication</title><content type='html'>Now that the Arduino can control the mechanics, I need to get the Arduino to accept input via the USB connection.  The Arduino already has serial communication libraries, so it's a matter of checking for a message from the computer, parsing it, and setting the chassis object.&lt;br /&gt;&lt;br /&gt;Here's a new Arduino main program to replace the old one.&lt;br /&gt;&lt;a href="http://www.mech.ubc.ca/%7Emabauman/Files/robot/serialControl.cpp"&gt;serialControl.cpp&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I have no idea if there is an established protocol for this sort of thing: so far searching for any info on USB communication in C++ has been fruitless, so I'm making this up as I go along.  I want the messages to be short to keep things fast and simple.  Since the USB connection works as a sequence of bytes, it's easiest to parse the input as characters.  I'm going to use two bytes as a message, the first byte will be the header, and currently that'll only involve two values: one for steering, and one for throttle.  The second byte will be the value.  It would be possible to do this all with one byte, but with two bytes I get a larger range of possible values, and some flexibility if I want to add additional message types, as there are plenty more possible header values.  For ease of testing and debugging, I'm only going to use characters that are represented on a qwerty keyboard.  That way I can type messages directly into the Arduino compiler's Serial input to test the system.&lt;br /&gt;Looking at an &lt;a href="http://www.asciitable.com/"&gt;ASCII table&lt;/a&gt;, the lowest value that is not a special character is the spacebar: #32.  The highest is #126, the tilde ~.  I'm going to reserve the space as a sort of "Null" message - unused whitespace.  So, the throttle header will be #33 , the ! character, and the steering header will be #34, the " character.  The data will range from #35 to #126.  For example:&lt;br /&gt;&lt;br /&gt;!#   = full reverse&lt;br /&gt;!Q   = zero throttle&lt;br /&gt;!~   = full throttle&lt;br /&gt;&lt;br /&gt;"#   = maximum left turn&lt;br /&gt;"Q   = center steering&lt;br /&gt;"~   = maximum right turn&lt;br /&gt;&lt;br /&gt;Now I need to write a program for the computer to generate these messages.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-8182857389777963153?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/8182857389777963153/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=8182857389777963153' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/8182857389777963153'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/8182857389777963153'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/06/usb-communication.html' title='USB Communication'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-4945455046422110349</id><published>2008-06-19T19:36:00.000-07:00</published><updated>2008-06-19T20:16:04.955-07:00</updated><title type='text'>Chassis Abstraction</title><content type='html'>Now that the servo works, it's time to create a class to represent the chassis servo and ESC in the microcontroller code.  I want to create a "chassis" object, which can be commanded to set the steering and throttle somewhere between -100% and 100%.  The chassis object will be calibrated and will translate the abstract percentage into the correct servo values.  Here's the code:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.mech.ubc.ca/%7Emabauman/Files/robot/t_chassis.h"&gt;t_chassis.h&lt;/a&gt; - header file describing the class&lt;br /&gt;&lt;a href="http://www.mech.ubc.ca/%7Emabauman/Files/robot/t_chassis.cpp"&gt;t_chassis.cpp&lt;/a&gt; - implementation file&lt;br /&gt;&lt;a href="http://www.mech.ubc.ca/%7Emabauman/Files/robot/util.h"&gt;util.h&lt;/a&gt; - a few macros and definitions&lt;br /&gt;&lt;br /&gt;By including this in the Arduino program, and changing the constants in t_chassis.h to match the correct values for the servo minimum, center and maximum, and the corresponding values for the ESC.&lt;br /&gt;&lt;br /&gt;An example Arduino program would look like this:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.mech.ubc.ca/%7Emabauman/Files/robot/chassisTest.cpp"&gt;chassisTest.cpp&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Here's a video of the program in action:&lt;br /&gt;&lt;br /&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-7cd418a5574fce08" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v1.nonxt2.googlevideo.com/videoplayback?id%3D7cd418a5574fce08%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143783%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D75107AF8651EE6E9B7852BD626884BA123A46C4A.8474243A9ED8482895B71B27117FB7530DA2556A%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D7cd418a5574fce08%26offsetms%3D5000%26itag%3Dw160%26sigh%3DbI4crj9WG6cI4ZKq6m14DLmRyDs&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v1.nonxt2.googlevideo.com/videoplayback?id%3D7cd418a5574fce08%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143783%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D75107AF8651EE6E9B7852BD626884BA123A46C4A.8474243A9ED8482895B71B27117FB7530DA2556A%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3D7cd418a5574fce08%26offsetms%3D5000%26itag%3Dw160%26sigh%3DbI4crj9WG6cI4ZKq6m14DLmRyDs&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-4945455046422110349?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=7cd418a5574fce08&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/4945455046422110349/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=4945455046422110349' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/4945455046422110349'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/4945455046422110349'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/06/chassis-abstraction.html' title='Chassis Abstraction'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-6763143373319711326</id><published>2008-06-09T14:27:00.000-07:00</published><updated>2008-06-19T19:47:09.765-07:00</updated><title type='text'>Choosing a computer</title><content type='html'>One of the remaining major choices to make is what computer to mount on this thing.  There are many choices, but they boil down to three major categories:&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Mini-ITX computers.  These junior-sized motherboards, frequently used for in-car entertainment systems, are quite powerful, relatively cheap, and have lots of options in terms of ports (firewire, USB, serial, ethernet, wireless, bluetooth, PCI-E, etc.  However, using one would require an additional battery-powered power supply and dedicated batteries.  The other major downside is that I'd need to carry around a monitor, keyboard, and mouse just to be able to do any kinds of programming in the field.  This option probably offers the best performance and flexibility, but at the cost of convenience.&lt;/li&gt;&lt;li&gt;Mini-laptops.  There is a flood of these laptops coming onto the market right now.  Priced under $1000 and weighing 3 lbs or less, they seem to be a pretty good choice.  The best ones (which have yet to actually hit the market as of this writing) are powered by Intel's new Atom processor (the Diamondville variant being teh most desirable right now).  They all have USB, but none have firewire.  They all package a VIA C7 or Intel Atom processor, 1-2 Gb of RAM, a screen, keyboard and trackpad, and of course, built-in batteries.  The main downside is that it's all locked up in a tidy package that inevitably will be mounted quite high on the robot's body, so some work will be involved to keep all that payload stable.&lt;/li&gt;&lt;li&gt;Smaller-scale hardware.  There are various options such as Pico-ITX scale motherboards and Gumstix: tiny computers on a board.  They have similar disadvantages to the mini-ITX board, with the additional performance hits inherent to miniaturization.  Their low power draw means that they could probably be run off the chassis batteries.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;Overall, since this will be a development platform, I think I'll go with a Mini-laptop, either the Asus 901, the MSI wind, or the ECS G10-IL.  The advantages of the all-in-one nature of a laptop are worth the loss of flexibility.  Later robots can use the mini/picoITX boards if necessary.&lt;br /&gt;&lt;br /&gt;Here's a &lt;a href="http://www.mech.ubc.ca/%7Emabauman/Files/robot/ComputerTable.html"&gt;comparison table&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-6763143373319711326?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/6763143373319711326/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=6763143373319711326' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/6763143373319711326'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/6763143373319711326'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/06/choosing-computer.html' title='Choosing a computer'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-2052960068991806832</id><published>2008-05-28T22:21:00.000-07:00</published><updated>2008-12-09T18:05:32.284-08:00</updated><title type='text'>Servo Wiring</title><content type='html'>Connecting the Arduino board to the forward servo and the ESC requires an adapter board.  Marcel and Ash from the robotics team sketched out the wiring and soldered it for me, as that's a skill I've yet to pick up.  Here's a pic:&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_bg57Qjxi-VY/SD4_uS_DKcI/AAAAAAAAABU/iZatxco_dhY/s1600-h/AdapterBoard.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://1.bp.blogspot.com/_bg57Qjxi-VY/SD4_uS_DKcI/AAAAAAAAABU/iZatxco_dhY/s320/AdapterBoard.jpg" alt="" id="BLOGGER_PHOTO_ID_5205668283889691074" border="0" /&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;Arduino and the adapter board.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: left;"&gt;&lt;span style="font-size:100%;"&gt;Sometimes I'll refer to the ESC as a servo, as that's how it needs to be treated electronically.  The adapter serves three purposes:&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;ol style="text-align: left;"&gt;&lt;li&gt;&lt;span style="font-size:100%;"&gt;Connects the signal wires from each servo to digital output pins on the Arduino.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size:100%;"&gt;Connects the Arduino's ground pin to both servo ground wires.  The ground must be common, or none of the signalling will work.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size:100%;"&gt;Connects the steering servo's 6V supply to the ESC's 6V line, to provide power.  This doesn't connect to the Arduino at all.&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;div style="text-align: left;"&gt;&lt;span style="font-size:100%;"&gt;Here's the wiring diagram:&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_bg57Qjxi-VY/SD5BiC_DKdI/AAAAAAAAABc/IJMcTl_CDq8/s1600-h/ServoWiring.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://4.bp.blogspot.com/_bg57Qjxi-VY/SD5BiC_DKdI/AAAAAAAAABc/IJMcTl_CDq8/s320/ServoWiring.jpg" alt="" id="BLOGGER_PHOTO_ID_5205670272459549138" border="0" /&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;Adapter board wiring.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: left;"&gt;&lt;span style="font-size:100%;"&gt;S1 and S2 are the signal lines, going to digital pins 12 and 13 on the Arduino, respectively.  Digital pin 13 also happens to control the built-in LED indicator, which flickers now when that signal is sent.  The ground is common, of course.  The servo lines therefore plug directly into the adapter board, so it can replace the radio receiver.&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_bg57Qjxi-VY/SD5EQi_DKeI/AAAAAAAAABk/Ydadv6-BbU0/s1600-h/ServoInterface.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://2.bp.blogspot.com/_bg57Qjxi-VY/SD5EQi_DKeI/AAAAAAAAABk/Ydadv6-BbU0/s320/ServoInterface.jpg" alt="" id="BLOGGER_PHOTO_ID_5205673270346721762" border="0" /&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;Everything all connected.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: left;"&gt;&lt;span style="font-size:100%;"&gt;Using the Servo.h library for Arduino, it's relatively easy to control the steering servo: you specify a position between 0 and 180 degrees, and call refresh at least once every 20ms, and the servo will move.  The servo doesn't need its full range of motion, as the steering links don't have that much travel.  Moving the servo between 40 and 140 degrees is enough to fully articulate the steering: any more and you can hear the servo grinding and the servo saver stressing.&lt;br /&gt;Unfortunately the ESC is another story.  So far no signal I've sent it has elicited any response.  I'll have to find some documentation on how that one works.&lt;br /&gt;&lt;br /&gt;The servo code is based on the &lt;a href="http://www.arduino.cc/playground/ComponentLib/Servo"&gt;tutorial&lt;/a&gt; on the Arduino Playground.  Here it is:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;#include &lt;servo.h&gt;&lt;/servo.h&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;#define pin1 12&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;#define pin2 13&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Servo servo1;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Servo servo2;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;int angle = 90;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;int dir = 1;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;int counter = 0;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;int counterMax = 100;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;void setup()&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  servo1.attach(pin2);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  Serial.begin(9600);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  Serial.print("Ready");&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;void loop()&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  static int v = 0;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  if(counter &gt; counterMax)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    counter = 0;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    angle = angle + dir;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    if(angle &gt; 140){dir = -1;}&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    if(angle &lt; dir =" 1;}    servo1.write(angle);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    Serial.print("angle: ");&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    Serial.println(angle); &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  counter++;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;  Servo::refresh();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;div style="text-align: left;"&gt;&lt;span style=";font-family:georgia;font-size:100%;"  &gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-size:100%;"&gt;Note that you need to download the Servo.h code, which is available through the tutorial linked earlier.  Anyway, here's a video of the Arduino running the steering:&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;object width="320" height="266" class="BLOG_video_class" id="BLOG_video-e0abe66188fe4caf" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="movie" value="http://www.youtube.com/get_player"&gt;&lt;param name="bgcolor" value="#FFFFFF"&gt;&lt;param name="allowfullscreen" value="true"&gt;&lt;param name="flashvars" value="flvurl=http://v12.nonxt6.googlevideo.com/videoplayback?id%3De0abe66188fe4caf%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143784%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D570B000F612F3846A957970B383A67B0DE895B93.858D721EE2BF85F2B5F3B1356DA51543A66373F8%26key%3Dck1&amp;amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3De0abe66188fe4caf%26offsetms%3D5000%26itag%3Dw160%26sigh%3DYjtoJGSzcKriOO7AWq4e12kLOxw&amp;amp;autoplay=0&amp;amp;ps=blogger"&gt;&lt;embed src="http://www.youtube.com/get_player" type="application/x-shockwave-flash"width="320" height="266" bgcolor="#FFFFFF"flashvars="flvurl=http://v12.nonxt6.googlevideo.com/videoplayback?id%3De0abe66188fe4caf%26itag%3D5%26app%3Dblogger%26ip%3D0.0.0.0%26ipbits%3D0%26expire%3D1330143784%26sparams%3Did,itag,ip,ipbits,expire%26signature%3D570B000F612F3846A957970B383A67B0DE895B93.858D721EE2BF85F2B5F3B1356DA51543A66373F8%26key%3Dck1&amp;iurl=http://video.google.com/ThumbnailServer2?app%3Dblogger%26contentid%3De0abe66188fe4caf%26offsetms%3D5000%26itag%3Dw160%26sigh%3DYjtoJGSzcKriOO7AWq4e12kLOxw&amp;autoplay=0&amp;ps=blogger"allowFullScreen="true" /&gt;&lt;/object&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-2052960068991806832?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='enclosure' type='video/mp4' href='http://www.blogger.com/video-play.mp4?contentId=e0abe66188fe4caf&amp;type=video%2Fmp4' length='0'/><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/2052960068991806832/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=2052960068991806832' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/2052960068991806832'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/2052960068991806832'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/05/servo-wiring.html' title='Servo Wiring'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_bg57Qjxi-VY/SD4_uS_DKcI/AAAAAAAAABU/iZatxco_dhY/s72-c/AdapterBoard.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-9173706992203993399</id><published>2008-05-25T19:35:00.000-07:00</published><updated>2008-12-09T18:05:33.205-08:00</updated><title type='text'>Electrical Anatomy of the Stampede</title><content type='html'>The first thing was to partially disassemble the Stampede and work out how the pieces go together.  I'm not planning any major changes to the chassis mechanics.  Most R/C modifications are for better speed and performance, which is not the intention here.  The chassis is a rectangular plastic tub with shock towers at each end.&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_bg57Qjxi-VY/SDolci_DKYI/AAAAAAAAAA0/FVPjhzpueaA/s1600-h/DSCN3723.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://2.bp.blogspot.com/_bg57Qjxi-VY/SDolci_DKYI/AAAAAAAAAA0/FVPjhzpueaA/s320/DSCN3723.JPG" alt="" id="BLOGGER_PHOTO_ID_5204513491737848194" border="0" /&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-size:85%;"&gt;Stampede chassis with wheels removed.&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;div style="text-align: left;"&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-size:100%;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;div style="text-align: left;"&gt;&lt;span style="font-size:100%;"&gt;Only the rear wheels are powered, and the steering is controlled by a single servo, visible as a black box between the two front shock absorbers.  The shocks attach to the black shock tower, which sports two body mount posts above it.  The battery normally lies in the well in the chassis center, and connects to the yellow Electronic Speed Control (ESC).  You can also see the blue aftermarket bumper (by RPM Racing) that will protect the front suspension from damage (and hopefully prevent a repeat of the broken caster block).&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-size:100%;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_bg57Qjxi-VY/SDonsy_DKZI/AAAAAAAAAA8/MiyCHqZcHTE/s1600-h/DSCN3726.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://3.bp.blogspot.com/_bg57Qjxi-VY/SDonsy_DKZI/AAAAAAAAAA8/MiyCHqZcHTE/s320/DSCN3726.JPG" alt="" id="BLOGGER_PHOTO_ID_5204515969933978002" border="0" /&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;Front Assembly with steering servo (left under shock tower) and radio receiver (right).&lt;br /&gt;&lt;/span&gt;&lt;div style="text-align: left;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="text-align: left;"&gt;&lt;div style="text-align: left;"&gt;&lt;span style="font-size:100%;"&gt;Sorry for the slightly blurry picture.  The radio receiver has two channels, channel 1 in the bottom slot controls the steering.  A servo has a three-wire interface.  The black is the ground wire, the red is the 6V power, and the white is the signal line.  The receiver gets its power from the ESC, and returns a signal back to the ESC (channel 2) on the white wire, treating it as a servo.  The ESC interprets that signal to control the main motor.  The steering servo on channel 1 receives its power from the radio receiver, as well as a signal on the white wire.&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-size:100%;"&gt;If I'm going to replace the receiver with the microcontroller, the steering servo still requires a power supply from the ESC.  So, the microcontroller must only send a signal on the white wires, and must be connected into the black ground wire.  The red power wire must bypass the microcontroller and remain connected to the servo.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-size:100%;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_bg57Qjxi-VY/SDosFC_DKaI/AAAAAAAAABE/05uoFbnqW-U/s1600-h/DSCN3727.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://4.bp.blogspot.com/_bg57Qjxi-VY/SDosFC_DKaI/AAAAAAAAABE/05uoFbnqW-U/s320/DSCN3727.JPG" alt="" id="BLOGGER_PHOTO_ID_5204520784592316834" border="0" /&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;The Electronic Speed Control (ESC)&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;The ESC receives power from the battery (far left) and passes power to the motor.  These wires are heavy-gauge to accommodate the high current passing to the main motor.  The thinner three-strand wire at the bottom of the image goes to the receiver, powering the receiver and the steering servo, and receiving back a signal on the white wire, as noted previously.&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_bg57Qjxi-VY/SDotpi_DKbI/AAAAAAAAABM/cUk9ablouoY/s1600-h/DSCN3728.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://2.bp.blogspot.com/_bg57Qjxi-VY/SDotpi_DKbI/AAAAAAAAABM/cUk9ablouoY/s320/DSCN3728.JPG" alt="" id="BLOGGER_PHOTO_ID_5204522511169169842" border="0" /&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;The main drive motor.&lt;br /&gt;&lt;/span&gt;&lt;div style="text-align: left;"&gt;&lt;br /&gt;The main motor itself is a Titan 550 12-turn.  There's not much need for modifications here: except perhaps to gear the system down.  The truck's really fast: far too fast for an autonomous system.&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-9173706992203993399?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/9173706992203993399/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=9173706992203993399' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/9173706992203993399'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/9173706992203993399'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/05/electrical-anatomy-of-stampede.html' title='Electrical Anatomy of the Stampede'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_bg57Qjxi-VY/SDolci_DKYI/AAAAAAAAAA0/FVPjhzpueaA/s72-c/DSCN3723.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-694311826434099509</id><published>2008-05-16T00:58:00.000-07:00</published><updated>2008-12-09T18:05:33.600-08:00</updated><title type='text'>Arduino Diecimila</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_bg57Qjxi-VY/SC1B4mi2RmI/AAAAAAAAAAs/WC_Ul7fz9UM/s1600-h/Arduino.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://4.bp.blogspot.com/_bg57Qjxi-VY/SC1B4mi2RmI/AAAAAAAAAAs/WC_Ul7fz9UM/s320/Arduino.jpg" alt="" id="BLOGGER_PHOTO_ID_5200885585357981282" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;My very own Arduino Diecimila microcontroller arrived today.  The Arduino implements the "wiring" communications library and is open-source to boot.  It can serve as the robot's brain, but is limited to simple analog or digital inputs, so vision is right out.  It also has a USB-b connector, so it can communicate with a larger computer and can thus serve as a simple chassis interface.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-694311826434099509?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/694311826434099509/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=694311826434099509' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/694311826434099509'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/694311826434099509'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/05/arduino-diecimila.html' title='Arduino Diecimila'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_bg57Qjxi-VY/SC1B4mi2RmI/AAAAAAAAAAs/WC_Ul7fz9UM/s72-c/Arduino.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-719163020372302912</id><published>2008-05-16T00:35:00.000-07:00</published><updated>2008-12-09T18:05:33.794-08:00</updated><title type='text'>Traxxas Stampede</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_bg57Qjxi-VY/SC07_Wi2RlI/AAAAAAAAAAc/NNlwXiAvwpc/s1600-h/Stampede.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://3.bp.blogspot.com/_bg57Qjxi-VY/SC07_Wi2RlI/AAAAAAAAAAc/NNlwXiAvwpc/s320/Stampede.jpg" alt="" id="BLOGGER_PHOTO_ID_5200879104252331602" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;So there it is: a Traxxas Stampede.  It's so much fun to drive around I'm rather reluctant to tear it apart.  I'll have to take some care to retain the ability to run it as an R/C car.&lt;br /&gt;&lt;br /&gt;The stampede is a 2WD Monster truck.  It has a single servo for steering and is capable of 30 mph.  I'll reduce the gearing so that it has more torque and a lower top speed for safety.&lt;br /&gt;&lt;br /&gt;If you look carefully you can see that the front-right tire is askew.  That's because I ran it into a curb and broke the front right caster block.  It's currently awaiting a new caster block so it'll run again.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-719163020372302912?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/719163020372302912/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=719163020372302912' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/719163020372302912'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/719163020372302912'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/05/so-there-it-is-traxxas-stampede.html' title='Traxxas Stampede'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_bg57Qjxi-VY/SC07_Wi2RlI/AAAAAAAAAAc/NNlwXiAvwpc/s72-c/Stampede.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-4941832801412011173</id><published>2008-05-15T08:50:00.001-07:00</published><updated>2008-05-15T09:05:50.681-07:00</updated><title type='text'>The Plan</title><content type='html'>The robot will have the following:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;An off-road capable R/C chassis in 1/10 scale (good brand names I know: Tamiya and Traxxas)&lt;/li&gt;&lt;li&gt;A microcontroller to interface with the chassis electronics and perhaps some of the simpler onboard sensors.  (I have a small amount of experience with the Arduino board which makes it my first choice.)&lt;/li&gt;&lt;li&gt;An onboard computer for the AI and Vision processing.  Right now the leading candidate is the Asus eee PC, but the HP 2133 Mini-Note and various Mini-ITX computers are all in the running.  More on this debate later.&lt;/li&gt;&lt;li&gt;Camera(s) for vision.  Stereo would be great, but that requires two cameras rigidly fixed to one another.  I also have to consider the limitations of the computer's USB or Firewire Bus and processor to handle that much incoming camera data at once.&lt;/li&gt;&lt;li&gt;Other sensors.  Candidates are Ultrasonic Rangefinders, Bump sensors, and Infrared Rangefinders.&lt;/li&gt;&lt;li&gt;Power will be supplied by the chassis battery and a additional battery for the computer.  Laptops are the most convenient in that regard.&lt;/li&gt;&lt;/ul&gt;The main task I want the robot to perform initially is roaming with obstacle avoidance, and mapping.  Basically the robot should accumulate a map of its surroundings by wandering around and observing them, while keeping track of its own position relative to previously-viewed landmarks.  Formally, this is called Simultaneous Localisation And Mapping, or SLAM.  Once that's working, who knows what I'll program it to do.&lt;br /&gt;&lt;br /&gt;For a software structure the plan is to use Player/Stage with Gazebo, which is an open-source framework for developing robots.&lt;br /&gt;&lt;br /&gt;Big plans.  We'll see where they go.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-4941832801412011173?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/4941832801412011173/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=4941832801412011173' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/4941832801412011173'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/4941832801412011173'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/05/plan.html' title='The Plan'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-4330126918577676568</id><published>2008-05-15T08:43:00.000-07:00</published><updated>2008-08-02T21:01:17.600-07:00</updated><title type='text'>The History</title><content type='html'>This entire project started as a result of participating in the Waterloo Robot Racing competition representing the University of British Columbia as part of the Thunderbird Robotics Team.  The challenge was to build a small autonomous robot that could navigate a course demarcated by orange traffic cones.  Our entry was based on a Tamiya remote-control Hummer kit, and was controlled by an Arduino microcontroller.  The robot had infrared line-following sensors and ultrasonic rangefinders.  What the robot really needed was a vision system.  I was so enthused by the whole project that I decided that I wanted to build a robot of my own, based on an R/C car.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-4330126918577676568?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/4330126918577676568/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=4330126918577676568' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/4330126918577676568'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/4330126918577676568'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/05/history.html' title='The History'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5586001299793205042.post-6403171846412066472</id><published>2008-05-14T13:35:00.000-07:00</published><updated>2008-08-02T21:01:53.349-07:00</updated><title type='text'>Inception</title><content type='html'>Welcome to the Snowtires Blog, my personal chronicle of the process of building a vision guided robot.  This will be my first foray into electronics building and robot construction, so who knows where it will end up.  Bear with me and I hope there will be some interesting times ahead.&lt;br /&gt;&lt;br /&gt;-tetracanth&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5586001299793205042-6403171846412066472?l=snowtiresrobot.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://snowtiresrobot.blogspot.com/feeds/6403171846412066472/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5586001299793205042&amp;postID=6403171846412066472' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/6403171846412066472'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5586001299793205042/posts/default/6403171846412066472'/><link rel='alternate' type='text/html' href='http://snowtiresrobot.blogspot.com/2008/05/inception.html' title='Inception'/><author><name>tetracanth</name><uri>http://www.blogger.com/profile/13378461776304673262</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
