<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>BrickEngineer</title>
	<atom:link href="http://www.brickengineer.com/pages/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.brickengineer.com/pages</link>
	<description>Engineering for LEGO Enthusiasts</description>
	<lastBuildDate>Sun, 15 Nov 2009 23:55:34 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Grown Man Builds LEGO Boba Fett Costume!</title>
		<link>http://www.brickengineer.com/pages/2009/11/15/grown-man-builds-lego-boba-fett-costume/</link>
		<comments>http://www.brickengineer.com/pages/2009/11/15/grown-man-builds-lego-boba-fett-costume/#comments</comments>
		<pubDate>Sun, 15 Nov 2009 23:55:34 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=133</guid>
		<description><![CDATA[Geekologie posted an article about a man who made a wearable Boba Fett costume out of LEGOs.  Mind you, its not a full costume.  The helmet is most impressive, the rest are pieces of LEGO body armor that attach to his outfit.
Actually, I am a bit more impressed by the LEGO Darth Vader [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.geekologie.com/2008/08/grown_man_builds_lego_boba_fet.php">Geekologie posted an article</a> about a man who made a wearable Boba Fett costume out of LEGOs.  Mind you, its not a full costume.  The helmet is most impressive, the rest are pieces of LEGO body armor that attach to his outfit.</p>
<div id="attachment_134" class="wp-caption aligncenter" style="width: 460px"><img src="http://www.brickengineer.com/pages/wp-content/uploads/2009/11/boba-lego-1.jpg" alt="LEGO Boba Fett Costume" title="LEGO Boba Fett Costume" width="450" height="300" class="size-full wp-image-134" /><p class="wp-caption-text">LEGO Boba Fett Costume</p></div>
<div id="attachment_135" class="wp-caption aligncenter" style="width: 460px"><img src="http://www.brickengineer.com/pages/wp-content/uploads/2009/11/boba-lego-2.jpg" alt="LEGO Boba Fett Helmet" title="LEGO Boba Fett Helmet" width="450" height="338" class="size-full wp-image-135" /><p class="wp-caption-text">LEGO Boba Fett Helmet</p></div>
<p>Actually, I am a bit more impressed by the LEGO Darth Vader costume!<br />
Who IS that masked man???</p>
<div id="attachment_136" class="wp-caption aligncenter" style="width: 460px"><img src="http://www.brickengineer.com/pages/wp-content/uploads/2009/11/darth-lego.jpg" alt="LEGO Darth Vader Costume" title="LEGO Darth Vader Costume" width="450" height="600" class="size-full wp-image-136" /><p class="wp-caption-text">LEGO Darth Vader Costume</p></div>
<p>If only, it had lights that were controlled by the LEGO Mindstorms Brick, and a Breathing apparatus controlled by the LEGO pneumatic system!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2009/11/15/grown-man-builds-lego-boba-fett-costume/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Interface a Potentiometer to the NXT</title>
		<link>http://www.brickengineer.com/pages/2009/10/05/interface-a-potentiometer-to-the-nxt/</link>
		<comments>http://www.brickengineer.com/pages/2009/10/05/interface-a-potentiometer-to-the-nxt/#comments</comments>
		<pubDate>Mon, 05 Oct 2009 15:12:40 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Electronics]]></category>
		<category><![CDATA[Hacking]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[extreme]]></category>
		<category><![CDATA[hack]]></category>
		<category><![CDATA[interface]]></category>
		<category><![CDATA[LEGO]]></category>
		<category><![CDATA[NXT]]></category>
		<category><![CDATA[potentiometer]]></category>
		<category><![CDATA[robot]]></category>
		<category><![CDATA[Robotics]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=92</guid>
		<description><![CDATA[NOTE: WE ARE NOT RESPONSIBLE FOR ANY DAMAGE YOU MAY DO TO YOUR NXT BRICK.
THIS EXERCISE PRESUMES SOME WORKING KNOWLEDGE OF ELECTRONICS.
In this exercise, I will walk you through interfacing a potentiometer (variable resistor) to the NXT brick.
You will need:
- A stripped NXT cable
- A potentiometer with a maximum resistance no more than 
- A [...]]]></description>
			<content:encoded><![CDATA[<p><strong>NOTE: WE ARE NOT RESPONSIBLE FOR ANY DAMAGE YOU MAY DO TO YOUR NXT BRICK.<br />
THIS EXERCISE PRESUMES SOME WORKING KNOWLEDGE OF ELECTRONICS.</strong></p>
<p>In this exercise, I will walk you through interfacing a potentiometer (variable resistor) to the NXT brick.<br />
You will need:<br />
- A stripped NXT cable<br />
- A potentiometer with a maximum resistance no more than <img src='http://www.brickengineer.com/pages/latexrender/pictures/070c47ad71d57ef2eacf1d64186ccd3a.gif' title='$10 k\Omega$' alt='$10 k\Omega$' align=absmiddle><br />
- A small piece of wire<br />
- An NXT Brick</p>
<p>This exercise is derived and expanded from a chapter in Extreme NXT by Gasperi, Hurbain and Hurbain.</p>
<p><strong>THEORY</strong></p>
<p>The NXT monitors the potential difference between the black and white wires with an Analog-to-Digital (A/D) converter.  The A/D converter converts this potential difference to a RAW value between 0 and 1023 (10 bits accuracy).  This RAW value is given by the ratio</p>
<p>(1)     <img src='http://www.brickengineer.com/pages/latexrender/pictures/1cad6789deeb4cd24eda028aaf82c9d4.gif' title='$RAW = \frac{RAW_{max}}{V_{max}} V_{R} = \frac{1023}{5} V_{R}$' alt='$RAW = \frac{RAW_{max}}{V_{max}} V_{R} = \frac{1023}{5} V_{R}$' align=absmiddle></p>
<p>where <img src='http://www.brickengineer.com/pages/latexrender/pictures/b43b792b8a0ad9e20bbed3ffe589f270.gif' title='$RAW_{max}$' alt='$RAW_{max}$' align=absmiddle> is the maximum RAW value of 1023, <img src='http://www.brickengineer.com/pages/latexrender/pictures/dd101dae0851cc03c2c9afa9ee7d58eb.gif' title='$V_{max} = 5V$' alt='$V_{max} = 5V$' align=absmiddle> is the voltage used by the NXT A/D Converter, and <img src='http://www.brickengineer.com/pages/latexrender/pictures/bec7483bf7de7666e8169bfb2677affc.gif' title='$V_{R}$' alt='$V_{R}$' align=absmiddle> is the voltage drop between the black and white wires.</p>
<p>The circuit diagram looks like this:</p>
<p><img src="http://www.brickengineer.com/pages/wp-content/uploads/2009/10/ad-nxt-schematic.jpg" alt="NXT A/D Converter Schematic" title="NXT A/D Converter Schematic" width="300" height="300" class="aligncenter size-full wp-image-108" /></p>
<p>I have a little <img src='http://www.brickengineer.com/pages/latexrender/pictures/5e0f22e358604402c3a03443068c077c.gif' title='$1k\Omega$' alt='$1k\Omega$' align=absmiddle> potentiometer that can turn over a range of about <img src='http://www.brickengineer.com/pages/latexrender/pictures/75509215276170cb42d350f8ef4d0a82.gif' title='$0^{\circ}$' alt='$0^{\circ}$' align=absmiddle> to <img src='http://www.brickengineer.com/pages/latexrender/pictures/0bd080041b349b48631cfa8cadce5cd8.gif' title='$270^{\circ}$' alt='$270^{\circ}$' align=absmiddle>.  Below is a diagram.  The resistance between the leftmost and rightmost pins is the maximum resistance of <img src='http://www.brickengineer.com/pages/latexrender/pictures/5e0f22e358604402c3a03443068c077c.gif' title='$1k\Omega$' alt='$1k\Omega$' align=absmiddle>.  We will focus on the resistance between the leftmost and center pins, which varies based on the angle through which the potentiometer has been rotated.  To keep things safe, we wire the center pin and rightmost pin together.  This doesn&#8217;t affect the potential difference between the leftmost and center pins.</p>
<p><img src="http://www.brickengineer.com/pages/wp-content/uploads/2009/10/potentiometer.jpg" alt="Potentiometer Wiring" title="Potentiometer Wiring" width="145" height="200" class="aligncenter size-full wp-image-111" /></p>
<p>I will assume that it is a linear potentiometer (a pretty good assumption), which means that the resistance at any given angle <img src='http://www.brickengineer.com/pages/latexrender/pictures/53d147e7f3fe6e47ee05b88b166bd3f6.gif' title='$A$' alt='$A$' align=absmiddle> is given by</p>
<p>(2)     <img src='http://www.brickengineer.com/pages/latexrender/pictures/9b17fb6a4e23964da4aa54b217d99d7e.gif' title='$R = \frac{A}{A_{max}} R_{max} = \frac{A}{270} \times 1 k\Omega}$' alt='$R = \frac{A}{A_{max}} R_{max} = \frac{A}{270} \times 1 k\Omega}$' align=absmiddle></p>
<p>where <img src='http://www.brickengineer.com/pages/latexrender/pictures/db89de390ca9a572d5f3db56a7d989e5.gif' title='$A_{max}$' alt='$A_{max}$' align=absmiddle> is the maximum angle of the potentiometer and <img src='http://www.brickengineer.com/pages/latexrender/pictures/ea449f9e9a48e2959872aac8fa65e1ca.gif' title='$R_{max}$' alt='$R_{max}$' align=absmiddle> is the <img src='http://www.brickengineer.com/pages/latexrender/pictures/5e0f22e358604402c3a03443068c077c.gif' title='$1k\Omega$' alt='$1k\Omega$' align=absmiddle> maximum resistance.</p>
<p>Equation (2) says that if the angle <img src='http://www.brickengineer.com/pages/latexrender/pictures/d1b9d96e40897ca243ff281f5aee7ce0.gif' title='$A = 0^{\circ}$' alt='$A = 0^{\circ}$' align=absmiddle> then the resistance of the potentiometer  <img src='http://www.brickengineer.com/pages/latexrender/pictures/8a8aab1169d4020852d8d06a8a3e1e24.gif' title='$R_{max} = 0 \Omega$' alt='$R_{max} = 0 \Omega$' align=absmiddle>, and if the angle  <img src='http://www.brickengineer.com/pages/latexrender/pictures/deb17e4443c1eb6e6c679a8913933bd7.gif' title='$A = 270^{\circ}$' alt='$A = 270^{\circ}$' align=absmiddle> then the resistance of the potentiometer is maximum <img src='http://www.brickengineer.com/pages/latexrender/pictures/dd63154537d0661b80239a820feece0e.gif' title='$R_{max} = 1 k\Omega$' alt='$R_{max} = 1 k\Omega$' align=absmiddle>.</p>
<p>Looking at the circuit diagram for the A/D converter, the potential drop across our potentiometer (represented by resistor <img src='http://www.brickengineer.com/pages/latexrender/pictures/1e438235ef9ec72fc51ac5025516017c.gif' title='$R$' alt='$R$' align=absmiddle>) is given by the typical voltage divider relation</p>
<p>(3)     <img src='http://www.brickengineer.com/pages/latexrender/pictures/2bac90d7a171d06bd46e916b0780ff0b.gif' title='$V_R = \frac{R}{R+R_{int}} V_{max} = \frac{R}{R+10k\Omega} \times 5V$' alt='$V_R = \frac{R}{R+R_{int}} V_{max} = \frac{R}{R+10k\Omega} \times 5V$' align=absmiddle></p>
<p>We can now substitute (2) into (3) so that the voltage between the black and white wires is determined by the angle of the potentiometer rather than its resistance.  Then we can substitute the result into (1) to get an equation for the RAW value</p>
<p>(4)     <img src='http://www.brickengineer.com/pages/latexrender/pictures/761c502e47967e1b8673cdaa66330032.gif' title='$RAW = RAW_{max} \frac{A R_{max}}{A R_{max} + A_{max} R_{int}}$' alt='$RAW = RAW_{max} \frac{A R_{max}}{A R_{max} + A_{max} R_{int}}$' align=absmiddle></p>
<p>with my particular values, this is</p>
<p><img src='http://www.brickengineer.com/pages/latexrender/pictures/7780912834bf8933662f2c391d669f62.gif' title='$RAW  = 1023 \frac{A \times 1 k\Omega}{(A \times 1 k\Omega) + (270 \times 10 k\Omega)}$' alt='$RAW  = 1023 \frac{A \times 1 k\Omega}{(A \times 1 k\Omega) + (270 \times 10 k\Omega)}$' align=absmiddle></p>
<p>This formula will let us predict the NXT RAW value based on the angle of the potentiometer.</p>
<p>For my potentiometer, I find that a maximum angle of <img src='http://www.brickengineer.com/pages/latexrender/pictures/0bd080041b349b48631cfa8cadce5cd8.gif' title='$270^{\circ}$' alt='$270^{\circ}$' align=absmiddle> gives me a maximum value of 93.  This is less than 7 bits of information, and each RAW value corresponds to <img src='http://www.brickengineer.com/pages/latexrender/pictures/e22be5d833d32b48854ad4fdf237aff7.gif' title='$2.9^{\circ}$' alt='$2.9^{\circ}$' align=absmiddle>.  If you want a nice angle detector, you will probably need a <img src='http://www.brickengineer.com/pages/latexrender/pictures/070c47ad71d57ef2eacf1d64186ccd3a.gif' title='$10 k\Omega$' alt='$10 k\Omega$' align=absmiddle> potentiometer!</p>
<p><strong>TRY IT</strong></p>
<p>1. Before beginning, you need to cut and strip one of the NXT cables so that you can interface with the wires directly.  I have placed a layer of solder on mine, so they can be inserted into a breadboard for easy connecting.</p>
<p>2. Next connect the center and right pins of the potentiometer together with a wire</p>
<p>3. Plug the other end of the NXT cable into the NXT brick.</p>
<p>I wrote a simple NXT-G program to read the sensor and display the RAW value.  Notice that the Touch Sensor actually reads the resistance between the wires.  So we are just replacing the Touch Sensor with a potentiometer.  We will use the raw number output of the Touch Sensor Block, which is represented by the 1010 0101 symbol.  We then need to convert it to text so it can be displayed on the NXT LCD panel.</p>
<p><img src="http://www.brickengineer.com/pages/wp-content/uploads/2009/10/potentio-01.jpg" alt="potentio-01.rbt Screenshot" title="potentio-01.rbt Screenshot" width="470" height="389" class="aligncenter size-full wp-image-114" /></p>
<p>You may download it here,<br />
<a href="http://www.brickengineer.com/pages/downloads/code/Potentio-01.rbt">Potentio-01.rbt</a><br />
or write your own.</p>
<p>When I try my potentiometer, I find that the RAW value goes from 0 to 95, pretty close to my predicted range of 0 to 93.  So it works! Not bad considering I guessed that the potentiometer sweeps through and angle of <img src='http://www.brickengineer.com/pages/latexrender/pictures/0bd080041b349b48631cfa8cadce5cd8.gif' title='$270^{\circ}$' alt='$270^{\circ}$' align=absmiddle>.</p>
<p><strong><br />
Determining the Angle of the Potentiometer</strong></p>
<p>Now, let&#8217;s convert this RAW value to an angle.<br />
In Extreme NXT, the authors worry about the fact that the resulting relationship is nonlinear with respect to the RAW value.  As far as I can see, this isn&#8217;t a problem.  We simply solve (4) above for the angle <img src='http://www.brickengineer.com/pages/latexrender/pictures/53d147e7f3fe6e47ee05b88b166bd3f6.gif' title='$A$' alt='$A$' align=absmiddle> in terms of RAW.  We can output the angle if we wish, but here I&#8217;ll take it a step further and demonstrate the resulting equation by controlling a motor so that it maintains an angle equal to the angle through which I have rotated the potentiometer.</p>
<p>I will leave out the algebra. Try it yourself.  Solve (4) for angle A:</p>
<p>(5)     <img src='http://www.brickengineer.com/pages/latexrender/pictures/67c4dab90b1bc204c427800a89470354.gif' title='$A = \frac{RAW A_{max} R_{int}}{R_{max} (RAW_{max} &amp;#8211; RAW)}$' alt='$A = \frac{RAW A_{max} R_{int}}{R_{max} (RAW_{max} &amp;#8211; RAW)}$' align=absmiddle></p>
<p>for my potentiometer, this is simply</p>
<p><img src='http://www.brickengineer.com/pages/latexrender/pictures/2dc5e0f8c1957bd00d73303eedad972f.gif' title='$A = \frac{2700 RAW}{(1023 &amp;#8211; RAW)}$' alt='$A = \frac{2700 RAW}{(1023 &amp;#8211; RAW)}$' align=absmiddle></p>
<p>which is easy to code in NXT-G.<br />
You can download my code here:<br />
<a href="http://www.brickengineer.com/pages/downloads/code/Potentio-03.rbt">Potentio-03.rbt</a></p>
<p>The motor control is a bit crude, but it works well enough for the demonstration.<br />
Check out the YouTube video to see it in action!</p>
<p><object width="350" height="283"><param name="movie" value="http://www.youtube.com/v/HpFQX-aM6-c&#038;hl=en&#038;fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/HpFQX-aM6-c&#038;hl=en&#038;fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="350" height="283"></embed></object></p>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2009/10/05/interface-a-potentiometer-to-the-nxt/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Danny &#8211; NXT Matlab Bluetooth Router</title>
		<link>http://www.brickengineer.com/pages/2009/02/16/danny-nxt-matlab-bluetooth-router/</link>
		<comments>http://www.brickengineer.com/pages/2009/02/16/danny-nxt-matlab-bluetooth-router/#comments</comments>
		<pubDate>Mon, 16 Feb 2009 05:56:20 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Hacking]]></category>
		<category><![CDATA[MATLAB]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Bluetooth]]></category>
		<category><![CDATA[LEGO]]></category>
		<category><![CDATA[mindstorms]]></category>
		<category><![CDATA[NXT]]></category>
		<category><![CDATA[robot]]></category>
		<category><![CDATA[Robotics]]></category>
		<category><![CDATA[robots]]></category>
		<category><![CDATA[starting]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=79</guid>
		<description><![CDATA[Daniele Benedettelli introduces a MATLAB-based NXC Bluetooth Router.  This router relies on connecting a master NXT Brick to a computer via USB.  This master NXT Brick then can communicate messages to up to three additional slave NXT Bricks up to a distance of 10 meters from the master.  This software would allow [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://robotics.benedettelli.com" target="_blank">Daniele Benedettelli</a> introduces a <a href="http://robotics.benedettelli.com/BT_router.htm" target="_blank">MATLAB-based NXC Bluetooth Router</a>.  This router relies on connecting a master NXT Brick to a computer via USB.  This master NXT Brick then can communicate messages to up to three additional slave NXT Bricks up to a distance of 10 meters from the master.  This software would allow one to create small swarms of up to three LEGO robots, which is a nice starting point for investigating distributed robotic systems.</p>
<div id="attachment_80" class="wp-caption alignleft" style="width: 310px"><img class="size-full wp-image-80" title="MATLAB NXT Bluetooth Router" src="http://www.brickengineer.com/pages/wp-content/uploads/2009/02/bluetooth-router.jpg" alt="MATLAB NXT Bluetooth Router" width="300" height="400" /><p class="wp-caption-text">MATLAB NXT Bluetooth Router</p></div>
<p>The system relies on the <a href="http://www.mindstorms.rwth-aachen.de/" target="_blank">RWTH &#8211; MINDSTORMS NXT Toolbox</a>, the <a href="http://mindstorms.lego.com/support/updates/" target="_blank">NXT Fantom Library</a>, and <a href="http://bricxcc.sourceforge.net/lms_arm_jch.zip" target="_blank">John Hansen&#8217;s enhanced firmware</a>.  The brick software is written in <a href="http://bricxcc.sourceforge.net/nbc/" target="_blank">Not eXactly C (NXC)</a>, which requires <a href="http://bricxcc.sourceforge.net/nbc/" target="_blank">Brick CC 3.3</a>.</p>
<p><a href="http://robotics.benedettelli.com" target="_blank">Daniele Benedettelli</a> also has a book published titled <a href="http://www.amazon.com/gp/product/1590599667?ie=UTF8&amp;tag=onlicort-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=1590599667">Creating Cool MINDSTORMS NXT Robots (Technology in Action)</a><img style="border:none !important; margin:0px !important;" src="http://www.assoc-amazon.com/e/ir?t=onlicort-20&amp;l=as2&amp;o=1&amp;a=1590599667" border="0" alt="" width="1" height="1" /></p>
<p><iframe src="http://rcm.amazon.com/e/cm?t=onlicort-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=1590599667&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2009/02/16/danny-nxt-matlab-bluetooth-router/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Infrared-Ultrasonic Beacons for Localization</title>
		<link>http://www.brickengineer.com/pages/2009/02/16/infrared-ultrasonic-beacons-for-localization/</link>
		<comments>http://www.brickengineer.com/pages/2009/02/16/infrared-ultrasonic-beacons-for-localization/#comments</comments>
		<pubDate>Mon, 16 Feb 2009 05:38:15 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Electronics]]></category>
		<category><![CDATA[Findings]]></category>
		<category><![CDATA[Hacking]]></category>
		<category><![CDATA[beacon]]></category>
		<category><![CDATA[filter]]></category>
		<category><![CDATA[kalman]]></category>
		<category><![CDATA[LabVIEW]]></category>
		<category><![CDATA[localization]]></category>
		<category><![CDATA[microcontrollers]]></category>
		<category><![CDATA[NXT]]></category>
		<category><![CDATA[projects]]></category>
		<category><![CDATA[robot]]></category>
		<category><![CDATA[Robotics]]></category>
		<category><![CDATA[robots]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[spatial]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=75</guid>
		<description><![CDATA[An article at NXTasy.org highlights a three-wheeled robot that moves in one dimension and detects signals from an external beacon that emits ultrasonic bursts.  The robot relies on a microcontroller that runs a Kalman filter to perform and maintain spatial localization.  The NXT software is implemented using the LabVIEW NXT toolkit
Details on the project can [...]]]></description>
			<content:encoded><![CDATA[<p>An <a href="http://nxtasy.org/2009/01/25/1d-navigation-using-a-scalar-kalman-filter/" target="_blank">article at NXTasy.org</a> highlights a three-wheeled robot that moves in one dimension and detects signals from an external beacon that emits ultrasonic bursts.  The robot relies on a microcontroller that runs a <a href="http://en.wikipedia.org/wiki/Kalman_filter" target="_blank">Kalman filter</a> to perform and maintain spatial localization.  The NXT software is implemented using the LabVIEW NXT toolkit</p>
<div id="attachment_76" class="wp-caption alignleft" style="width: 321px"><img class="size-full wp-image-76" title="NXT Reciever with Kalman Filter " src="http://www.brickengineer.com/pages/wp-content/uploads/2009/02/nxt_receiver.png" alt="NXT Reciever with Kalman Filter " width="311" height="261" /><p class="wp-caption-text">NXT Reciever with Kalman Filter </p></div>
<p>Details on the project can be found at <a href="http://www.convict.lu/htm/rob/ir_us.htm#Kalman" target="_blank">http://www.convict.lu/htm/rob/ir_us.htm#Kalman</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2009/02/16/infrared-ultrasonic-beacons-for-localization/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>LEGO Rendering Tutorial: The Basics</title>
		<link>http://www.brickengineer.com/pages/2009/02/15/lego-rendering-tutorial-the-basics/</link>
		<comments>http://www.brickengineer.com/pages/2009/02/15/lego-rendering-tutorial-the-basics/#comments</comments>
		<pubDate>Mon, 16 Feb 2009 01:44:37 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Rendering]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[animation]]></category>
		<category><![CDATA[exploration]]></category>
		<category><![CDATA[image]]></category>
		<category><![CDATA[LDRAW]]></category>
		<category><![CDATA[LEGO]]></category>
		<category><![CDATA[list]]></category>
		<category><![CDATA[MLCAD]]></category>
		<category><![CDATA[parts]]></category>
		<category><![CDATA[POV-Ray]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[render]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[solutions]]></category>
		<category><![CDATA[starting]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=49</guid>
		<description><![CDATA[This is the first in a series of installments that describe how to render high-quality 3D images of your LEGO creations.  You will need the following free software:

LDraw
MLCad
L3P
POV-Ray v3.6

which can be downloaded with the LDraw All In One Installer
In this tutorial, we will be aiming for a nice simple still image of three bricks.  In [...]]]></description>
			<content:encoded><![CDATA[<p>This is the first in a series of installments that describe how to render high-quality 3D images of your LEGO creations.  You will need the following <em>free</em> software:</p>
<ul>
<li>LDraw</li>
<li>MLCad</li>
<li>L3P</li>
<li>POV-Ray v3.6</li>
</ul>
<p>which can be downloaded with the <a title="LDRAW Installer" href="http://www.ldraw.org/Article104.html" target="_blank">LDraw All In One Installer</a></p>
<p>In this tutorial, we will be aiming for a nice simple still image of three bricks.  In later tutorials, we will animate them.  That will require extra software to put a series of inages together to form a video or an animated gif.  I use Adobe ImageReady to make animated gifs, but there are cheaper solutions.</p>
<p>You can also download all the files we will create here<br />
<a href="http://www.brickengineer.com/pages/files/BE_render_tutorial_1.zip">BE_render_tutorial_1.zip</a><br />
and follow along.</p>
<p><strong>STEP 1: Create an MLCad file of the scene to be rendered<br />
</strong></p>
<p>Open MLCad and prepare to place a few LEGO pieces in the scene.</p>
<p><strong><em>Step 1.1</em>: </strong>Set up a 1&#215;1 brick<br />
On the upper left-hand side, click on <em>Brick</em>.<br />
Drag the 1&#215;1 brick into one of the three viewing panels.<br />
With the brick selected click the <span style="color: #ff0000;">RED</span> color button to color it red.<br />
Right-click on the brick and select <em>Enter Pos. + Rot&#8230;<br />
Use Position Values</em> should be checked<br />
Set the X and Z values all to zero and Y to -100 (negative 100)</p>
<p><strong><em>Step 1.2</em>: </strong>Add a 2&#215;4 brick<br />
Following the steps above, find the 2&#215;4 brick in the <em>Brick</em> list (+ will expand the list) and add it to the scene.  Set its color to <span style="color: #ffcc00;">YELLOW</span> and its position to X=100, Y=-100,  Z=50.</p>
<p><strong><em>Step 1.3</em>: </strong>Add a 2&#215;6 plate<br />
Following the steps above, find the 2&#215;6 plate in the <em>Plate</em> list (you will have to scroll down to the <em>Plate</em> tab) and add it to the scene.  Set its color to <span style="color: #0000ff;">BLUE</span> and its position to X=100, Y=-100,  Z=-100.</p>
<p>Be sure that these pieces are all at Y=-100.  The -y direction points upward and this will place them above the Y=0 plane.</p>
<p><strong><em>Step 1.4</em>: </strong>Save your work as <strong><em>part-zoo-1.ldr</em></strong></p>
<p>The screenshot below shows what you should see at this point on your MLCad screen.</p>
<div id="attachment_57" class="wp-caption alignleft" style="width: 460px"><img class="size-full wp-image-57" title="mlcad-screenshot-render-tutorial-1_450x316" src="http://www.brickengineer.com/pages/wp-content/uploads/2009/02/mlcad-screenshot-render-tutorial-1_450x316.jpg" alt="MLCad Screenshot" width="450" height="316" /><p class="wp-caption-text">MLCad Screenshot</p></div>
<p><em><br />
</em><strong><em></em></strong></p>
<p><strong>STEP 2: Create a POVRay file using L3PAO</strong></p>
<p>Open LP3AO (<em>L3P-Add-on)</em> keeping in mind where you stored your MLCad files.  This figure shows you the basic L3PAO window.</p>
<div id="attachment_59" class="wp-caption alignleft" style="width: 460px"><img class="size-full wp-image-59" title="l3pao-screenshot-render-tutorial-1_450x468" src="http://www.brickengineer.com/pages/wp-content/uploads/2009/02/l3pao-screenshot-render-tutorial-1_450x468.jpg" alt="L3PAO Screenshot" width="450" height="468" /><p class="wp-caption-text">L3PAO Screenshot</p></div>
<p><strong><em>Step 2.1</em>:</strong> In the <em>L3P-Add-on</em> window set the <em>Model File</em> to point to your MLCad file.  To browse, you may need to click on the button labeled &#8230;</p>
<p><strong><em>Step 2.2</em>:</strong> In the <em>L3P-Add-on</em> window set the <em>POV-Ray Output File</em> to point to the folder where you want your POV-Ray file to go.  To browse, you may need to click on the button labeled &#8230;</p>
<p><strong><em>Step 2.3</em>:</strong> In the middle of the right-hand column is the Quality Level setting.  Set this to 2.  IF you select 3 it prints the LEGO logo on every stud.  If you want this, you may leave it.  But I prefer to remove them.</p>
<p><strong><em>Step 2.4</em>:</strong> At the bottom of the middle column is the <em>Render upon Completion</em> option.  This will launch POV-Ray automatically.  However, if you have problems with the automatic launch, turn this option off and load it manually.  In later tutorials, we will edit the POV-Ray file manually anyway.</p>
<p><strong>Step: 2.5:</strong> To start <em>L3PAdd-on</em> click on the <em>Run L3P</em> button in the lower right.  This will create the POV-Ray <strong><em>part-zoo-1.pov</em></strong> file in the directory you specified, and possibly launch POV-Ray depending on the settings you used in <em>Step 2.4</em> above.</p>
<p><strong>STEP 3: Render the Image with POV-Ray<br />
</strong></p>
<p>If you launched POV-Ray automatically, you will already have your image.  Here we assume that you will render it manually.</p>
<div id="attachment_60" class="wp-caption alignleft" style="width: 460px"><img class="size-full wp-image-60" title="povray-screenshot-render-tutorial-1_450x433" src="http://www.brickengineer.com/pages/wp-content/uploads/2009/02/povray-screenshot-render-tutorial-1_450x433.jpg" alt="POV-Ray Screenshot" width="450" height="433" /><p class="wp-caption-text">POV-Ray Screenshot</p></div>
<p><strong><em>Step 3.1</em>:</strong> Open POV-Ray and in the <em>File Menu</em>, use <em>Open File</em> to open the .pov file that was created by L3pAO.</p>
<p><strong><em>Step 3.2</em>:</strong> Once the file is open, you can simply press the <em>Run</em> button on the upper bar.  This will create a default image, which is a 640&#215;480 .bmp bitmap image.  This is saved automatically in the same folder as your .pov file.  Here it is:</p>
<div id="attachment_61" class="wp-caption alignleft" style="width: 460px"><img class="size-full wp-image-61" title="part-zoo-1-default" src="http://www.brickengineer.com/pages/wp-content/uploads/2009/02/part-zoo-1-default.jpg" alt="Part-Zoo-1 Default image" width="450" height="338" /><p class="wp-caption-text">Part-Zoo-1 Default image</p></div>
<p>Note that the LEGO pieces are lifted up above the floor.  This is because we set their y-coordinates to be -100, which is above the floor at zero.  Remember that negative y is up.  We now look to change a few features of our render.</p>
<p><strong><em>Step 3.3</em>:</strong> If you click on the <em>Ini</em> button (to the left of <em>Run</em> above), you will go to a screen that enables you to change the size of the output image.  The <em>Section</em> field on the right has many options that include the resolution of the final image as well as whether <a title="Anti-Aliasing" href="http://en.wikipedia.org/wiki/Anti-aliasing" target="_blank">Anti-Aliasing</a> (AA) is used.  Try changing the resolution and look at the differences between anti-aliased images and non-anti-aliased images.</p>
<p>Note however, that the output images will always be saved in either .bmp or .png format.  You will have to use another program to convert them to other formats if you are interested.</p>
<p><strong><em>Step 3.4</em>: </strong>You can try playing with the commands in the .pov file.  POV-Ray acts like an editor and you can manually edit your files.  For example, there is a section near the bottom that reads:</p>
<blockquote><p>// Floor:<br />
object {<br />
plane { y, 24 hollow }<br />
texture {<br />
pigment { color rgb &lt;0.8,0.8,0.8&gt; }<br />
finish { ambient 0.4 diffuse 0.4 }<br />
}<br />
}</p></blockquote>
<p>This code controls the floor of the image.  If you delete it completely, the floor will disappear as you can see here in this image:</p>
<div id="attachment_64" class="wp-caption alignleft" style="width: 460px"><img class="size-full wp-image-64" title="part-zoo-1-no-floor" src="http://www.brickengineer.com/pages/wp-content/uploads/2009/02/part-zoo-1-no-floor.jpg" alt="Part-Zoo-1 with No Floor" width="450" height="338" /><p class="wp-caption-text">Part-Zoo-1 with No Floor</p></div>
<p><strong>Step 3.4: </strong>IF you don&#8217;t like the black background, look in the .pov file for the <em>Background</em> section:</p>
<blockquote><p>// Background:<br />
background { color rgb &lt;0,0,0&gt;}</p></blockquote>
<p>Changing the rgb (red, green, and blue) colors to &lt;0.7, 0.7, 1.0&gt;:</p>
<blockquote><p>// Background:<br />
background { color rgb &lt;0.7, 0.7, 1.0&gt;}</p></blockquote>
<p>Will give you an image with no floor and a light blue background:</p>
<div id="attachment_66" class="wp-caption alignleft" style="width: 460px"><img class="size-full wp-image-66" title="part-zoo-1-blue-background" src="http://www.brickengineer.com/pages/wp-content/uploads/2009/02/part-zoo-1-blue-background.jpg" alt="Part-Zoo-1 with a blue blackground" width="450" height="338" /><p class="wp-caption-text">Part-Zoo-1 with a blue blackground</p></div>
<p>We have explored making simple cad images in MLCad, generating a .pov file using L3PAO, and rendering a high-quality bitmap image using POV-Ray.   You should read through the .pov file and try to figure out what the different parts do.  You can change their values and re-render the image to see what impact your changes have.  Just remember that POV-Ray saves the changes on top of the original file,  so you may want to make a backup first.</p>
<p>Happy Rendering!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2009/02/15/lego-rendering-tutorial-the-basics/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MATLAB Packages for the NXT</title>
		<link>http://www.brickengineer.com/pages/2009/02/11/matlab-packages-for-the-nxt/</link>
		<comments>http://www.brickengineer.com/pages/2009/02/11/matlab-packages-for-the-nxt/#comments</comments>
		<pubDate>Wed, 11 Feb 2009 07:10:14 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Resources]]></category>
		<category><![CDATA[Robotics]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Bluetooth]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[LEGO]]></category>
		<category><![CDATA[MATLAB]]></category>
		<category><![CDATA[mindstorms]]></category>
		<category><![CDATA[NXT]]></category>
		<category><![CDATA[package]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[robot]]></category>
		<category><![CDATA[robots]]></category>
		<category><![CDATA[starting]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=45</guid>
		<description><![CDATA[There are now several MATLAB packages for robotics, and specifically for the NXT.  One paradigm is to run the code on a PC and have it communicate direct commands to the NXT Brick via Bluetooth or USB.  I have found this paradigm to be a bit dangerous since in the event of a MATLAB crash [...]]]></description>
			<content:encoded><![CDATA[<p>There are now several MATLAB packages for robotics, and specifically for the NXT.  One paradigm is to run the code on a PC and have it communicate direct commands to the NXT Brick via Bluetooth or USB.  I have found this paradigm to be a bit dangerous since in the event of a MATLAB crash or a miscommunication, the NXT Brick will continue with its last command until ordered to stop.  This has the potential to destroy your robot.  The paradigm that I prefer to use is to write several programs that run on the brick.  These programs take commands from files on the brick that can be uploaded rapidly from the PC.  The MATLAB code then is in charge of sending the command files and starting and stopping programs.  In the event of a MATLAB crash or communication failure, the software running on the NXT Brick can be designed to terminate gracefully.</p>
<p>Here are the MATLAB packages that I know of.  The first two are specifically geared toward the NXT; whereas the last is a general robotics package.</p>
<ul>
<li>LEGO MINDSTORMS NXT Toolkit for MATLAB and Simulink<br />
<a href="http://www.mathworks.com/programs/mindstorms/" target="_blank">http://www.mathworks.com/programs/mindstorms/</a></li>
<li>Robotics Toolbox for MATLAB (Release 7.1) (P.I. Corke)<br />
<a href="http://petercorke.com/Robotics%20Toolbox.html" target="_blank">http://petercorke.com/Robotics%20Toolbox.html</a></li>
<li>RWTH Mindstorms NXT Toolbox for Matlab<br />
<a href="http://www.mindstorms.rwth-aachen.de/" target="_blank">http://www.mindstorms.rwth-aachen.de/</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2009/02/11/matlab-packages-for-the-nxt/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Blossoming Lotus: LEGO Kinetic Art</title>
		<link>http://www.brickengineer.com/pages/2008/11/07/the-blossoming-lotus-lego-kinetic-art/</link>
		<comments>http://www.brickengineer.com/pages/2008/11/07/the-blossoming-lotus-lego-kinetic-art/#comments</comments>
		<pubDate>Sat, 08 Nov 2008 00:17:04 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Art]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[animation]]></category>
		<category><![CDATA[circle]]></category>
		<category><![CDATA[construction]]></category>
		<category><![CDATA[creation]]></category>
		<category><![CDATA[Geometry]]></category>
		<category><![CDATA[Hoberman]]></category>
		<category><![CDATA[instructions]]></category>
		<category><![CDATA[LEGO]]></category>
		<category><![CDATA[MLCAD]]></category>
		<category><![CDATA[parts]]></category>
		<category><![CDATA[projects]]></category>
		<category><![CDATA[sphere]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=38</guid>
		<description><![CDATA[I call this creation The Blossoming Lotus.  It was originally posted on Online Cortex, but I have decided to repost it here because its just plain fun. Basically it is a large 2D version of a Hoberman sphere.  Why did I not make a large Hoberman sphere?  First, the parts to make the [...]]]></description>
			<content:encoded><![CDATA[<p>I call this creation The Blossoming Lotus.  It was originally posted on <a href="http://www.huginn.com/knuth/blog/2007/05/10/the-blossoming-lotus/">Online Cortex</a>, but I have decided to repost it here because its just plain fun. Basically it is a large 2D version of a <a href="http://www.hoberman.com/fold/Sphere/sphere.htm" target="_blank">Hoberman sphere</a>.  Why did I not make a large Hoberman sphere?  First, the parts to make the circle cost almost $80 US.  Second, I have other more pressing projects I am working on.</p>
<div id="attachment_39" class="wp-caption aligncenter" style="width: 360px"><a href="http://www.brickengineer.com/pages/wp-content/uploads/2008/11/blossoming-lotus-anim.gif"><img class="size-full wp-image-39" title="blossoming-lotus-anim" src="http://www.brickengineer.com/pages/wp-content/uploads/2008/11/blossoming-lotus-anim.gif" alt="The Blossoming Lotus Kinetic Art" width="350" height="260" /></a><p class="wp-caption-text">The Blossoming Lotus Kinetic Art</p></div>
<p>It is about 4 feet in diameter when completely extended and is pretty impressive.  Its relatively easy to make.  My design consists of constructing each petal with two interlocking pieces: a single-claw arm and a double-claw arm.  The parts needed to make the two arms are illustrated below.</p>
<div id="attachment_40" class="wp-caption aligncenter" style="width: 360px"><a href="http://www.brickengineer.com/pages/wp-content/uploads/2008/11/lotus-parts.png"><img class="size-full wp-image-40" title="lotus-parts" src="http://www.brickengineer.com/pages/wp-content/uploads/2008/11/lotus-parts.png" alt="Parts for a Single Lotus Petal" width="350" height="262" /></a><p class="wp-caption-text">Parts for a Single Lotus Petal</p></div>
<p>To make the entire circle of petals, one needs 20 copies of each petal.  The job then is to put them all together.  I will post detailed instructions on a website in the near future.  For now, here is a closeup of the blossom when completed.</p>
<div id="attachment_41" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.brickengineer.com/pages/wp-content/uploads/2008/11/lotus_close-up_small.png"><img class="size-medium wp-image-41" title="lotus_close-up_small" src="http://www.brickengineer.com/pages/wp-content/uploads/2008/11/lotus_close-up_small-300x225.png" alt="Close Up of the Lotus Blossom" width="300" height="225" /></a><p class="wp-caption-text">Close Up of the Lotus Blossom</p></div>
<p>And of course, the project wouldn&#8217;t be complete without that animation above made with <a href="http://www.lm-software.com/mlcad/" target="_blank">MLCAD</a>, <a href="http://l3pao.malagraphixia.com/" target="_blank">L3PAO</a>, and <a href="http://www.povray.org/" target="_blank">POV Ray</a>.  The animation was straightforward&#8212;once you get the geometry right (which is not straightforward).  I will post a lesson on the geometry and the animation of this creation in the future as well.  For now, enjoy.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2008/11/07/the-blossoming-lotus-lego-kinetic-art/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Knuth: Developing Robotic Scientists for Space Exploration</title>
		<link>http://www.brickengineer.com/pages/2008/10/22/knuth-developing-robotic-scientists-for-space-exploration/</link>
		<comments>http://www.brickengineer.com/pages/2008/10/22/knuth-developing-robotic-scientists-for-space-exploration/#comments</comments>
		<pubDate>Wed, 22 Oct 2008 04:12:19 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[News]]></category>
		<category><![CDATA[Research]]></category>
		<category><![CDATA[demonstration]]></category>
		<category><![CDATA[exploration]]></category>
		<category><![CDATA[inquiry]]></category>
		<category><![CDATA[intelligence]]></category>
		<category><![CDATA[LEGO]]></category>
		<category><![CDATA[machine learning]]></category>
		<category><![CDATA[Robotics]]></category>
		<category><![CDATA[space]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=36</guid>
		<description><![CDATA[The University at Albany (SUNY) has highlighted Knuth&#8217;s research in a recent news piece.

UAlbany Professor Kevin Knuth with a robot built from LEGOs. (Photo Mark Schmidt)
Kevin Knuth has a laboratory in the physics department of the University at Albany that is filled with LEGOs. The bricks are relatively cheap and can be used to rapidly [...]]]></description>
			<content:encoded><![CDATA[<p>The University at Albany (SUNY) has highlighted Knuth&#8217;s research in a <a href="http://www.albany.edu/news/update_4522.shtml">recent news piece</a>.</p>
<p><img src="http://www.albany.edu/news/feedimages/689_0560.jpg" alt="UAlbany Professor Kevin Knuth with a robot built from LEGOs. (Photo Mark Schmidt) " width="250" height="166" /><br />
UAlbany Professor Kevin Knuth with a robot built from LEGOs. (Photo Mark Schmidt)</p>
<blockquote><p>Kevin Knuth has a laboratory in the <a href="http://www.albany.edu/physics/">physics department</a> of the University at Albany that is filled with LEGOs. The bricks are relatively cheap and can be used to rapidly prototype a robot&#8217;s body. Knuth&#8217;s robots are being programmed to solve such problems as mapping complex terrain.</p>
<p>At <a href="http://www.albany.edu/ualbanyday/">UAlbany Day</a> on Saturday, Oct. 25, he will give a demonstration on <em>Robotics and Robotic Exploration</em> in Life Sciences Room 143 at 10:45 a.m.</p></blockquote>
<p>More here: <a href="http://www.albany.edu/news/update_4522.shtml"><br />
http://www.albany.edu/news/update_4522.shtml</a></p>
<p><a href="http://www.brickengineer.com/robots/2008/10/21/knuth-developing-robotic-scientists-for-space-exploration/"></a></p>
<p>Building instructions for the robot shown in the UAlbany article can be found on <a href="http://www.brickengineer.com/pages/2008/10/12/little-rover-with-instructions-and-code/">Brickengineer.com</a></p>
<p>Visit <a href="http://www.autonomous-exploration.com/blog/?p=15">Autonomous Exploration News</a> for information on Knuth&#8217;s company <a href="http://www.autonomous-exploration.com/">Autonomous Exploration Inc.</a></p>
<p>Visit <a href="http://www.brickengineer.com/robots/2008/10/21/knuth-developing-robotic-scientists-for-space-exploration/">Robots Everywhere</a> for a general blog on robotics news.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2008/10/22/knuth-developing-robotic-scientists-for-space-exploration/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Little Rover with Instructions and Code</title>
		<link>http://www.brickengineer.com/pages/2008/10/12/little-rover-with-instructions-and-code/</link>
		<comments>http://www.brickengineer.com/pages/2008/10/12/little-rover-with-instructions-and-code/#comments</comments>
		<pubDate>Sun, 12 Oct 2008 05:43:54 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Constructs]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Robotics]]></category>
		<category><![CDATA[code software]]></category>
		<category><![CDATA[instructions]]></category>
		<category><![CDATA[NXT]]></category>
		<category><![CDATA[NXT-G]]></category>
		<category><![CDATA[robot]]></category>
		<category><![CDATA[rover]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/?p=26</guid>
		<description><![CDATA[
I have finally compiled building instructions for my Little Rover, which can be seen above in a 3D Rendering courtesy of POVRay.  An earlier version of this rover can be seen in this YouTube video:

Little Rover Prototype Video
Rover Design
The complete detailed building instructions can be found here in this 94-page pdf file.
Warning: it is about [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.brickengineer.com/pages/wp-content/uploads/2008/10/little-rover-on-mars-med.jpg"><img class="aligncenter size-full wp-image-34" title="little-rover-on-mars-med" src="http://www.brickengineer.com/pages/wp-content/uploads/2008/10/little-rover-on-mars-med.jpg" alt="" width="450" height="321" /></a></p>
<p>I have finally compiled building instructions for my Little Rover, which can be seen above in a 3D Rendering courtesy of <a href="http://www.povray.org/" target="_blank">POVRay</a>.  An earlier version of this rover can be seen in this YouTube video:</p>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="425" height="344" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="src" value="http://www.youtube.com/v/cShU-TzoK6w&amp;hl=en&amp;fs=1" /><embed type="application/x-shockwave-flash" width="425" height="344" src="http://www.youtube.com/v/cShU-TzoK6w&amp;hl=en&amp;fs=1" allowfullscreen="true"></embed></object></p>
<p><a href="http://www.youtube.com/watch?v=cShU-TzoK6w">Little Rover Prototype Video</a></p>
<p><strong>Rover Design</strong></p>
<p>The complete detailed building instructions can be found <a title="Little Rover Building Instructions" href="http://www.brickengineer.com/pages/instructions/little-rover-building-instructions.pdf" target="_self">here in this 94-page pdf file</a>.<br />
Warning: it is about 9MB in size.  The design is not entirely compatible with the standard NXT Mindstorms Kit.  This design relies on two touch sensors, several 1&#215;9 bent liftarms, and as far as I can tell from Peeron, the NXT Kit has only two.  This may require a little redesign.  Other compatibility issues and their solutions can be found in the Parts List in the <a title="Little Rover Building Instructions" href="http://www.brickengineer.com/pages/instructions/little-rover-building-instructions.pdf" target="_self">instructions</a>.</p>
<p>Remember to <a href="http://www.brickengineer.com/pages/downloads/code/Little-Rover.zip">download the software DriveSmart here as well</a>.<br />
Installation instructions can be found in the zip file.</p>
<p><strong>DriveSmart Code</strong></p>
<p>The main file is called DriveSmart.rbt.  Drive Smart runs four threads:</p>
<p>Drive Thread<br />
The Drive Thread (lowest one of the four) drives until a warning flag is set by one of the other<br />
threads. It then waits until it gets an all clear message via the Wait Until Free block, and then<br />
it starts driving again.</p>
<p>Bumper Threads<br />
There are two threads that monitor the bumpers.<br />
The reaction is only activated if nothing else is currently commanding the robot.  In this case the<br />
bumper has been pressed and the robot will veer away from the hazard.</p>
<p>Ultrasound Thread<br />
This thread monitors the ultrasound rangefinder.<br />
The reaction is only activated if nothing else is currently commanding the robot.  When the robot<br />
comes too close to a hazard, the robot is commanded to stop.  It then looks both ways and then turns<br />
in the direction with more room.  If the robot is within 10 cm of a hazard on both sides, it then<br />
backs up.</p>
<p>The robot can roam about a wide variety of rooms and not get stuck.<br />
He does not detect stairs though!  So be careful.</p>
<p>Download: <a title="Little Rover Building Instructions" href="http://www.brickengineer.com/pages/instructions/little-rover-building-instructions.pdf" target="_self">instructions</a> and <a href="http://www.brickengineer.com/pages/downloads/code/Little-Rover.zip">code</a>.</p>
<p>Enjoy!<br />
Kevin Knuth</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2008/10/12/little-rover-with-instructions-and-code/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>LEGO NXT Motor Wiring</title>
		<link>http://www.brickengineer.com/pages/2008/09/05/lego-nxt-motor-wiring/</link>
		<comments>http://www.brickengineer.com/pages/2008/09/05/lego-nxt-motor-wiring/#comments</comments>
		<pubDate>Fri, 05 Sep 2008 05:15:58 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Design]]></category>
		<category><![CDATA[Electronics]]></category>
		<category><![CDATA[Hacking]]></category>
		<category><![CDATA[Robotics]]></category>
		<category><![CDATA[hack]]></category>
		<category><![CDATA[interface]]></category>
		<category><![CDATA[LEGO]]></category>
		<category><![CDATA[motor]]></category>
		<category><![CDATA[NXT]]></category>
		<category><![CDATA[wire]]></category>
		<category><![CDATA[wiring]]></category>

		<guid isPermaLink="false">http://www.brickengineer.com/pages/2008/09/05/lego-nxt-motor-wiring/</guid>
		<description><![CDATA[After posting Hacking the LEGO Mindstorms NXT Standard Motor, I received several requests for more information regarding the wiring of the motor.
The NXT cable has six wires.   Below I list a table with the wires and their colors:


Color    
Name


White
Motor 1


Black
Motor 2


Red
GND


Green
4.3 Volts


Yellow
Tach01


Blue
Tach02


The WHITE and BLACK wires (Motor 1 and Motor [...]]]></description>
			<content:encoded><![CDATA[<p>After posting <a href="http://www.brickengineer.com/pages/2008/04/05/hacking-the-lego-mindstorms-nxt-standard-motor/" title="Hacking the LEGO Motor">Hacking the LEGO Mindstorms NXT Standard Motor</a>, I received several requests for more information regarding the wiring of the motor.</p>
<p>The NXT cable has six wires.   Below I list a table with the wires and their colors:</p>
<table>
<tr>
<td><strong>Color    </strong></td>
<td><strong>Name</strong></td>
</tr>
<tr>
<td>White</td>
<td>Motor 1</td>
</tr>
<tr>
<td>Black</td>
<td>Motor 2</td>
</tr>
<tr>
<td>Red</td>
<td>GND</td>
</tr>
<tr>
<td>Green</td>
<td>4.3 Volts</td>
</tr>
<tr>
<td>Yellow</td>
<td>Tach01</td>
</tr>
<tr>
<td>Blue</td>
<td>Tach02</td>
</tr>
</table>
<p>The WHITE and BLACK wires (Motor 1 and Motor 2) deliver power to the motor.<br />
If standard batteries are used, the potential difference will be 9 volts, otherwise the NiMH rechargeable batteries provide 7.2 volts.  If the white wire is positive and black is negative, the motor will turn one way.  If you reverse the polarity, the motor will turn the other way.</p>
<p>The RED wire is connected to the ground (GND).  Note that in the sensors, RED and BLACK are connected to one another.  This is not the case in the motors.</p>
<p>The GREEN wire is connected to the +4.3 NXT power supply.</p>
<p>The YELLOW and BLUE wires are connected to the <a href="http://en.wikipedia.org/wiki/Rotary_encoder">quadrature encoder</a>, also called an <a href="http://en.wikipedia.org/wiki/Rotary_encoder">incremental rotary encoder</a>.</p>
<p><img src="http://upload.wikimedia.org/wikipedia/commons/thumb/c/c1/Basic-Rotary.jpg/180px-Basic-Rotary.jpg" alt="Basic Rotary Encoder" align="middle" height="179" width="180" /></p>
<p><a href="http://en.wikipedia.org/wiki/Quadrature_encoder"><img src="http://upload.wikimedia.org/wikipedia/en/thumb/6/68/Quadrature_Diagram.svg/300px-Quadrature_Diagram.svg.png" alt="Square waves from quadrature encoder" align="middle" /></a></p>
<p>As shown in the figure from Wikipedia above, (<a href="http://en.wikipedia.org/wiki/Quadrature_encoder">http://en.wikipedia.org/wiki/Quadrature_encoder</a>) the wires return square wave pulses that are 90 degrees out of phase.  If the rising pulse on TACH00 leads the rising pulse of TACH01 by 90 degrees, then the motor is going forward.  If it instead lags by 90 degrees, the motor is rotating backwards.  One complete square wave cycle corresponds to 2 degrees of rotation.  In the diagram above, if TACH00 refers to A and TACH01 refers to B, we can see that the motor is going backwards as TACH00 is lagging TACH 01.</p>
<p>By measuring the frequency of the square wave oscillation, one can compute the rotational velocity.  Since one cycle corresponds to 2 degrees of rotation, one cycle per second (1 Hz) corresponds to 2 degrees/sec.  If you record a frequency of X Hz, then the rotation rate is 2X cycles/sec.</p>
<p>Note also that by tracking both square waves, you can identify quarter cycles, which gives you a resolution of 1/4 of 2 degrees, which is 0.5 degrees.</p>
<p>The motor speed is controlled by <a href="http://en.wikipedia.org/wiki/Pulse-width_modulation">pulse-width modulation</a> (pwm), which works by driving the motor with a variable duty cycle square wave.  This effectively turns the motor on and off, fast.  The longer it is on, the more torque it will generate and the faster it will go.</p>
<p>These details and more can be found in the excellent book: Extreme: NXT with a sneak peak <a href="http://books.google.com/books?id=ze1vS5f4apUC&amp;pg=PA32&amp;lpg=PA32&amp;dq=lego+mindstorms+quadrature+encoder&amp;source=web&amp;ots=AdmPVFnk6s&amp;sig=RY_mOg7YTePFTb_YMg-slF0VP-w&amp;hl=en&amp;sa=X&amp;oi=book_result&amp;resnum=7&amp;ct=result#PPA32,M1">here</a>.</p>
<p>Additional details can be found in the excellent book <a href="http://www.amazon.com/gp/product/1590598180?ie=UTF8&amp;tag=onlicort-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=1590598180">Extreme NXT: Extending the LEGO MINDSTORMS NXT to the Next Level (Technology in Action)</a><img src="http://www.assoc-amazon.com/e/ir?t=onlicort-20&amp;l=as2&amp;o=1&amp;a=1590598180" style="border: medium none ; margin: 0px" border="0" height="1" width="1" /> by Michael Gasperi, Philippe E. Hurbain, and Isabelle L. Hurbain.</p>
<p><a href="http://www.amazon.com/gp/product/1590598180?ie=UTF8&amp;tag=onlicort-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=1590598180"><img src="http://www.brickengineer.com/pages/pics/books/extreme-nxt.jpg" border="0" /></a><img src="http://www.assoc-amazon.com/e/ir?t=onlicort-20&amp;l=as2&amp;o=1&amp;a=1590598180" style="border: medium none ; margin: 0px" border="0" height="1" width="1" /></p>
<p>Philo uploaded a comment, and reminded me that &#8220;Note that there are some internal photos of the NXT motor here: <a href="http://philohome.com/nxtmotor/nxtmotor.htm" onclick="javascript:pageTracker._trackPageview('/outgoing/philohome.com/nxtmotor/nxtmotor.htm');" rel="nofollow">http://philohome.com/nxtmotor/nxtmotor.htm</a> and schematics here: <a href="http://www.brickshelf.com/cgi-bin/gallery.cgi?i=1846577" onclick="javascript:pageTracker._trackPageview('/outgoing/www.brickshelf.com/cgi-bin/gallery.cgi?i=1846577');" rel="nofollow">http://www.brickshelf.com/cgi-bin/gallery.cgi?i=1846577</a>&#8221;</p>
<p>Happy Hacking!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brickengineer.com/pages/2008/09/05/lego-nxt-motor-wiring/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
