tag:blogger.com,1999:blog-23054336059329121152024-03-06T02:16:30.457-05:00Holding FocusTrying to find moments of clarity in a random world- by Paul BishopFocalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.comBlogger13125tag:blogger.com,1999:blog-2305433605932912115.post-56866358648804039522011-05-06T17:07:00.000-04:002011-05-06T17:07:44.317-04:00Frankenbotic Thinganator.. The design continues..<div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.blogger.com/video.g?token=AD6v5dzs6mtG4eXrGQCNofPct4Xp3TTYWCTLdYmIshUTaX_1i9iZJjfHw7JIjMj02tTvaIfBN0oHz3jFrAjfpeNo1Q' class='b-hbp-video b-uploaded' frameborder='0'></iframe></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjtImcp6M525segjGn1X2OO36iR8QwyOvoiExs5apARGUX05iQIiZ7pXJnzUz-ncTj_Pxo62FrmXnzyd4Z3WXLgJSEzCFJKIkjBNVlDyTtSy5SGVnCmnfzJ0ewJBctdSZJZ229p0G9pTUU/s1600/100_4732.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="200" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjtImcp6M525segjGn1X2OO36iR8QwyOvoiExs5apARGUX05iQIiZ7pXJnzUz-ncTj_Pxo62FrmXnzyd4Z3WXLgJSEzCFJKIkjBNVlDyTtSy5SGVnCmnfzJ0ewJBctdSZJZ229p0G9pTUU/s200/100_4732.JPG" width="150" /></a></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgVqWcbtUiiMFmC9vAmVRTnpAaNQbLHX3k0sC4OsH99oerHRLmyKKGTfAyM-qBoU4thzu91WdfWggQvMgGzfWW_O3l8E-JwV7XCbRCGN-ophOorFmwq1cbPwYCSGu4ELXMojnNjZMjjFmQ/s1600/100_4731.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="200" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgVqWcbtUiiMFmC9vAmVRTnpAaNQbLHX3k0sC4OsH99oerHRLmyKKGTfAyM-qBoU4thzu91WdfWggQvMgGzfWW_O3l8E-JwV7XCbRCGN-ophOorFmwq1cbPwYCSGu4ELXMojnNjZMjjFmQ/s200/100_4731.JPG" width="150" /></a> </div><br />
<div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjOlLWBkhUTHD1mrdnB8jUco5OIik_AsXANnZWnY67YKXXCqHRdWePtEW-C1u_oGo2kYQkjKkP57mPcPHAenRRUp6LKvzwOtSzMF5UhhWezdLNJ5BkRLoQmMOUjpv8t8DP0k1T6fCZv33M/s1600/100_4726.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjOlLWBkhUTHD1mrdnB8jUco5OIik_AsXANnZWnY67YKXXCqHRdWePtEW-C1u_oGo2kYQkjKkP57mPcPHAenRRUp6LKvzwOtSzMF5UhhWezdLNJ5BkRLoQmMOUjpv8t8DP0k1T6fCZv33M/s200/100_4726.JPG" width="200" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEisnpvl8upW-LHINPkQlI4tJXTfgbrNYFx-5_n3r6SUDhnG91tabgN6bhNe9tVlUpkvAJ_x1-6lmttu6DgnfUA9-YV_HaTvmgIWM3ZnnTBjrZ8PQgfy5Z1MqfOwWlWKNDwJ3idV2hEl-fQ/s1600/100_4734.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEisnpvl8upW-LHINPkQlI4tJXTfgbrNYFx-5_n3r6SUDhnG91tabgN6bhNe9tVlUpkvAJ_x1-6lmttu6DgnfUA9-YV_HaTvmgIWM3ZnnTBjrZ8PQgfy5Z1MqfOwWlWKNDwJ3idV2hEl-fQ/s200/100_4734.JPG" width="200" /></a></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;">The project continues. Today, I needed to relinquish the doorframe I had been using.. so I got a chunk of scrap lumber and have used that as a base. The motors are now mounted 48" apart, with the lines run over a pair of eyehooks to help keep things aligned. Above you can see the finished device leaning against a wall and outside on the grass.. along with a closeup of the motor/hooks, and a shot of it mounted on the wall above my desk. In addition, I mounted a cheap picture frame to use as a dry-erase surface as well as am using a dry-erase marker, it's a lot easier than changing paper over and over as I test various ideas.</div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0tag:blogger.com,1999:blog-2305433605932912115.post-30698470391328038602011-05-04T09:57:00.001-04:002011-05-04T10:13:52.581-04:00Frankenbotic Thinganator Stage Two<div class="separator" style="clear: both; text-align: center;"><object class="BLOGGER-youtube-video" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" data-thumbnail-src="http://2.gvt0.com/vi/fhtTlr_B-O4/0.jpg" height="266" width="320"><param name="movie" value="http://www.youtube.com/v/fhtTlr_B-O4&fs=1&source=uds" /><param name="bgcolor" value="#FFFFFF" /><embed width="320" height="266" src="http://www.youtube.com/v/fhtTlr_B-O4&fs=1&source=uds" type="application/x-shockwave-flash"></embed></object></div><br />
<br />
The first test of the Frankenbotic Thinganator... surprisingly, it worked the FIRST time!<br />
<br />
Here is the code for this alpha test.. mainly to show basic operation. The next steps include developing the math and functions for x,y location.. translating coordinates to tension lengths will require a little bit of math.<br />
<br />
<span style="color: blue; font-size: x-small;"><strong>#include <Stepper.h></strong></span><br />
<span style="color: blue; font-size: x-small;"><strong>#define STEPS 48</strong></span><br />
<span style="color: blue; font-size: x-small;"><strong>Stepper stepper1(STEPS, 2,3);<br />
Stepper stepper2(STEPS, 4,5);</strong></span><br />
<span style="color: blue; font-size: x-small;"><strong>void setup()<br />
{<br />
// set the speed of the motor to 30 RPMs<br />
stepper1.setSpeed(30);<br />
stepper2.setSpeed(30);<br />
}</strong></span><br />
<span style="color: blue; font-size: x-small;"><strong>void loop()<br />
{</strong></span><br />
<span style="color: blue; font-size: x-small;"><strong> for (int k=4; k>0; k=k-1) {<br />
stepper1.step(10);<br />
stepper2.step(10);<br />
for (int j=3; j>0; j=j-1) {<br />
for (int i=50; i>0; i=i-5) {<br />
stepper1.step(i);<br />
delay(0);<br />
stepper2.step(i);<br />
delay(0);<br />
stepper1.step(0-i);<br />
delay(0);<br />
stepper2.step(0-i);<br />
delay(0);<br />
};<br />
};<br />
};<br />
while (true) { }; // wait forever.<br />
}</strong></span><br />
<br />
<br />
Two small steppers salvaged from trash printers operate the plotter, by using gravity as the third vector we can locate the pen anywhere on the drawing surface by varying the length of the lines it is suspended by. This design is also called a Wall Plotter or Whiteboard Plotter.<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi1SO3g_uMSQSUyZ75jbgFaQWQJDGJMs0DPN56FMP6QVlkXnGUnXWR0ivFrmMNvHn3OB5qMn18U80VLstRx4FDH833Wbl5VtWPd05B67b_iU7ZmhQiQtJ_upjgn0M8VDGabfaB5ST80qx8/s1600/100_4713.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi1SO3g_uMSQSUyZ75jbgFaQWQJDGJMs0DPN56FMP6QVlkXnGUnXWR0ivFrmMNvHn3OB5qMn18U80VLstRx4FDH833Wbl5VtWPd05B67b_iU7ZmhQiQtJ_upjgn0M8VDGabfaB5ST80qx8/s200/100_4713.JPG" width="200" /></a></div><br />
<div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgyqA6vDfVBPMIPPIpdao3TjJq119RbuqW4AtTMXX3gW9ccep0OWRncJLMN7xUZJXN0_3yJE5mSL9yGTV6HRmf6JdCu5SDurSqmuSi_HpL0HPOc_xjKY6wdWarvrO9gIf34arZaCc9TtAo/s1600/100_4714.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgyqA6vDfVBPMIPPIpdao3TjJq119RbuqW4AtTMXX3gW9ccep0OWRncJLMN7xUZJXN0_3yJE5mSL9yGTV6HRmf6JdCu5SDurSqmuSi_HpL0HPOc_xjKY6wdWarvrO9gIf34arZaCc9TtAo/s200/100_4714.JPG" width="200" /></a> </div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgCW48ljkAdjx9fu0UxH46IGqilsbVP-i5gwT93Gl3DAXKctZLBgPxH8NwxFqqzNjM_nAyWAvg7DNlLmiU8gQzKr9q3cpUBEzw9t3Aw9BzXlfjERvQSyepFkeQK8xPyTGWlgCQJxOhMYHI/s1600/100_4715.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgCW48ljkAdjx9fu0UxH46IGqilsbVP-i5gwT93Gl3DAXKctZLBgPxH8NwxFqqzNjM_nAyWAvg7DNlLmiU8gQzKr9q3cpUBEzw9t3Aw9BzXlfjERvQSyepFkeQK8xPyTGWlgCQJxOhMYHI/s200/100_4715.JPG" width="200" /></a></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhyGOXTRB-0mkuaDlN4gcRYa1XkoRz1TcIwsr1CMeTU1Dc1eBblfI9F349zFxrUyJfbwqwjEAKFcepkjp0E2ocle941aUCPursQtSKQuezCK4bgb9S8aP2z8lCatOco-HxwtxjaHq3gptQ/s1600/100_4716.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhyGOXTRB-0mkuaDlN4gcRYa1XkoRz1TcIwsr1CMeTU1Dc1eBblfI9F349zFxrUyJfbwqwjEAKFcepkjp0E2ocle941aUCPursQtSKQuezCK4bgb9S8aP2z8lCatOco-HxwtxjaHq3gptQ/s200/100_4716.JPG" width="200" /></a> </div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjCcEPn2vtaMaRvfxwx9DoxuVt2BvW6IUSa72MikslJrqn4Gv2KCcqSlmLAmktT5Y3P-_vlHDU7IG9jPtsUZJTQPaKjWrOmL722UL8ZgdAnjsWlUrfIwh1jM58Co2EAkIsxiAJ8Ogw9uCo/s1600/100_4718.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjCcEPn2vtaMaRvfxwx9DoxuVt2BvW6IUSa72MikslJrqn4Gv2KCcqSlmLAmktT5Y3P-_vlHDU7IG9jPtsUZJTQPaKjWrOmL722UL8ZgdAnjsWlUrfIwh1jM58Co2EAkIsxiAJ8Ogw9uCo/s200/100_4718.JPG" width="200" /></a></div><br />
<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEib6moPuHxLMz2XS5iJJCjYCrhcpeD0DeCuWqhj5Ff00y9bzj9LemuvzS3P93n5R2YSOq0lhC0DyqfVLXN6Gg25cPSqo7pfCP5ChZijrTeXUrLdIBrTf5XoS_BWy425TDy7vxcKKxisw78/s1600/100_4719.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="240" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEib6moPuHxLMz2XS5iJJCjYCrhcpeD0DeCuWqhj5Ff00y9bzj9LemuvzS3P93n5R2YSOq0lhC0DyqfVLXN6Gg25cPSqo7pfCP5ChZijrTeXUrLdIBrTf5XoS_BWy425TDy7vxcKKxisw78/s320/100_4719.JPG" width="320" /></a></div><br />
Spools for the line were made by using Super Glue to hold together a washer on each side of a nut, then superglued to the small gears that were present on the stepper motor shafts. A card table was stood on a folding chair to make a drawing surface.. since I built this in a doorway, there's no immediate surface for the plotter to work on. If wall-mounted, the wall serves as the plotting surface. <br />
<br />
Also, since the "easel" isn't exactly vertical, a bit of inaccuracy and jerkiness is caused-- but again, this is just an alpha test of a prototype.. final versions will account for and eliminate this problem.Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0tag:blogger.com,1999:blog-2305433605932912115.post-22695593389201874772011-04-30T13:14:00.003-04:002011-04-30T13:31:45.140-04:00The Frankenbotic Thinganator - Making Stuff from JunkStep One: A trip to the local dump and a computer repair shop. Both free, got one older dot matrix<br />
Lexmark and a newer inkjet Dell printers. Physical teardown took approximately two hours including<br />
<div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;">torch desoldering of relevant ICs. Except for a handful of potentially useful-looking hardware and screws</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;">for the bins, the plastic and metal carcasses of the printers are then disposed of.</div><br />
<br />
<div style="text-align: left;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibWIAAVeCU3Ph6e3WNUurp8j991MSHFQLnkSNx8FEQoneI9v_MITpCUGgBYLJKAqUN6dDfbIRGubXabwHnh5_4vRR8EM3tAsjd0P3YkAnHePQZ1jp4L7jNU6BXRnE2J8FhjC1UHGmbqqA/s1600/100_4679.JPG" imageanchor="1" style="clear: left; cssfloat: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibWIAAVeCU3Ph6e3WNUurp8j991MSHFQLnkSNx8FEQoneI9v_MITpCUGgBYLJKAqUN6dDfbIRGubXabwHnh5_4vRR8EM3tAsjd0P3YkAnHePQZ1jp4L7jNU6BXRnE2J8FhjC1UHGmbqqA/s200/100_4679.JPG" width="200" /></a></div> <div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgONbcNIieUXIQWHevljbnrfVWdkiRVaU05vkp8d5UiTBISkkiGc4jIqmb1R0jiqrCoQlsnBZmzdegkMqyEAToL1aODoFE29hJOo0l7-bmCEMNa_ERlXWWVVcrsrz8kOordkmNA5ImWEBY/s1600/100_4689.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgONbcNIieUXIQWHevljbnrfVWdkiRVaU05vkp8d5UiTBISkkiGc4jIqmb1R0jiqrCoQlsnBZmzdegkMqyEAToL1aODoFE29hJOo0l7-bmCEMNa_ERlXWWVVcrsrz8kOordkmNA5ImWEBY/s200/100_4689.JPG" width="200" /></a> </div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgLk0KvHgWqHeynEjCEEc47rSk5V7gEZ6xO_C6v2O77wP2KHDxeJKGdANnEuPAOZ-0Ewr3qF3onvkc1fBYaHzknjDgYdlNg8i6_Frpbj07PGYqG7qNDTumHsv-Q3ca88gEfczki0G_jM3g/s1600/100_4699.JPG" imageanchor="1" style="clear: right; cssfloat: left; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgLk0KvHgWqHeynEjCEEc47rSk5V7gEZ6xO_C6v2O77wP2KHDxeJKGdANnEuPAOZ-0Ewr3qF3onvkc1fBYaHzknjDgYdlNg8i6_Frpbj07PGYqG7qNDTumHsv-Q3ca88gEfczki0G_jM3g/s200/100_4699.JPG" width="200" /></a></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEizAN5Kptj2-fm8KOTJj3OWt8UneO1TDAloVDS2k0e1LLKgq8wf7opCmR8BfeE5NmxqjBnvBOiUdSBCEW-2DIqQealSFJ2QfoKXr7FLRspMywyZhYQ_44IeIge_-q_8pF0DZE9UbhKydHQ/s1600/100_4684.JPG" imageanchor="1" style="clear: left; cssfloat: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEizAN5Kptj2-fm8KOTJj3OWt8UneO1TDAloVDS2k0e1LLKgq8wf7opCmR8BfeE5NmxqjBnvBOiUdSBCEW-2DIqQealSFJ2QfoKXr7FLRspMywyZhYQ_44IeIge_-q_8pF0DZE9UbhKydHQ/s200/100_4684.JPG" width="200" /></a> <br />
</div><div class="separator" style="clear: both; text-align: center;"></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div align="left" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;">Teardown of the Lexmark gives us several stepper motors, ranging from small low-torque ones, all the</div></div><div align="left" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;">way to a NEMA 23 and one other high-power stepper motor. The Dell inkjet gives up a nice standard DC motor, as well as another mid-power stepper motor.</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh0XZI3PISa9sa21gDDTB-LyQ3NWnLAxjq2VH9SuIbk8wJuBobi21C2zKiyJyOdvm9jp6eyXHdiS5tmklk1FBWcusGSu7mGJkRQX4musISiUPJhHMZUcSeReuAG3BCJjuaZrAmLcNCtYnA/s1600/100_4695.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh0XZI3PISa9sa21gDDTB-LyQ3NWnLAxjq2VH9SuIbk8wJuBobi21C2zKiyJyOdvm9jp6eyXHdiS5tmklk1FBWcusGSu7mGJkRQX4musISiUPJhHMZUcSeReuAG3BCJjuaZrAmLcNCtYnA/s200/100_4695.JPG" width="200" /></a></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjvtAh7r7Y9-7Yt3nFSHrBvaXEbzWyguJeFnE9FiXle3RO6UONNQd8PKX3EvdCwhu6BxhtA7ndx_R7Q3WiNxh35bGX3-M1EPGEqTgNec7O2X8RB6_zi-69Lv7FrkrZ2RlNb1W6rK9qXW3U/s1600/100_4696.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjvtAh7r7Y9-7Yt3nFSHrBvaXEbzWyguJeFnE9FiXle3RO6UONNQd8PKX3EvdCwhu6BxhtA7ndx_R7Q3WiNxh35bGX3-M1EPGEqTgNec7O2X8RB6_zi-69Lv7FrkrZ2RlNb1W6rK9qXW3U/s200/100_4696.JPG" width="200" /></a> </div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEivST6JgcZ95zV5K7VH_iF7a5pVa7rkERgXEIVcOv6P0DLvR4xvXwQT05eFNuycQN8ApDR3NlF322_72IACA-lkqLgjb3TfCNDnPbmVRQ9wfIcE6YWjAn4-sPoNzqAAwlW8GLRX-QfqNSo/s1600/100_4691.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEivST6JgcZ95zV5K7VH_iF7a5pVa7rkERgXEIVcOv6P0DLvR4xvXwQT05eFNuycQN8ApDR3NlF322_72IACA-lkqLgjb3TfCNDnPbmVRQ9wfIcE6YWjAn4-sPoNzqAAwlW8GLRX-QfqNSo/s200/100_4691.JPG" width="200" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjf15vGN_TpxFbAInD8RUk2D1NHMoWJQzqx9IA1_z_h9O6W2uFhQMQIh5lMXQck84FbnzeCQZUTO50IuM6fjf3AkMvm6C8-k12QNxptQBJoNjfa7uLd4r_2coC0k4ryC_5lQsZVPc605SU/s1600/100_4700.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjf15vGN_TpxFbAInD8RUk2D1NHMoWJQzqx9IA1_z_h9O6W2uFhQMQIh5lMXQck84FbnzeCQZUTO50IuM6fjf3AkMvm6C8-k12QNxptQBJoNjfa7uLd4r_2coC0k4ryC_5lQsZVPc605SU/s200/100_4700.JPG" width="200" /></a> </div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div class="separator" style="clear: both; text-align: center;"></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEifVLYkUd5GKdhNEf9G5Lu91RPxgRFfIntD3OzB1oXsEaTpZGZcs46L2RlcIaHffds5LmCtGIgwvcqMfXFFA4_zjytyUlCL_jHyfdSg-jkHdJrydM95d53_koEGr-aRHmYNhTxmROy6Uno/s1600/100_4693.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEifVLYkUd5GKdhNEf9G5Lu91RPxgRFfIntD3OzB1oXsEaTpZGZcs46L2RlcIaHffds5LmCtGIgwvcqMfXFFA4_zjytyUlCL_jHyfdSg-jkHdJrydM95d53_koEGr-aRHmYNhTxmROy6Uno/s200/100_4693.JPG" width="200" /></a></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiwrDp0bTfTF4OsnEDp9VGr5dyLDS1654fkQ4AkwAocdZCGXeXQdPP703kKt343ENvqzolgHxLAx1skIPgHWRU1Zsi2L4RFWXDhCwi73ZRGyHNHe_dd4X1IjtoEMKq72SmBMuB7caZVX3E/s1600/100_4701.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="150" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiwrDp0bTfTF4OsnEDp9VGr5dyLDS1654fkQ4AkwAocdZCGXeXQdPP703kKt343ENvqzolgHxLAx1skIPgHWRU1Zsi2L4RFWXDhCwi73ZRGyHNHe_dd4X1IjtoEMKq72SmBMuB7caZVX3E/s200/100_4701.JPG" width="200" /></a> </div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;">In addition to the motors themselves, a quick pass with a desoldering torch and we can reclaim the</div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;">driver IC's, a few power transistors, a few Darlington arrays, and some other miscellaneous</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;">parts.</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgk3e57dlxkceiKuj_2DcY8ssTk0_zd-oZIyEwXcDP21uxjA4o9f4pqn5Ypn98GBDQXoHKg-4m3aYP_FkRjFcXVkOot60HnmgSW5lZUZjYjHJQXX2dP9q3Uh6Nh6RhDa1W4FwpgbBtTuCk/s1600/100_4703.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="200" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgk3e57dlxkceiKuj_2DcY8ssTk0_zd-oZIyEwXcDP21uxjA4o9f4pqn5Ypn98GBDQXoHKg-4m3aYP_FkRjFcXVkOot60HnmgSW5lZUZjYjHJQXX2dP9q3Uh6Nh6RhDa1W4FwpgbBtTuCk/s200/100_4703.JPG" width="150" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgOiS8sjx3etuCZ1A5zW-8GC8fd7gm3lhyphenhyphenjWDBYTST5ADp3I2puHh_IdTIf1sgAIaKNjZzDxb2YVGx-hafgYQ_NUCQ6zUrxY4XP9nV9k0JSliCCEuMha125_WVqVroyKzCX9E1ahsS0F_Q/s1600/100_4709.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="200" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgOiS8sjx3etuCZ1A5zW-8GC8fd7gm3lhyphenhyphenjWDBYTST5ADp3I2puHh_IdTIf1sgAIaKNjZzDxb2YVGx-hafgYQ_NUCQ6zUrxY4XP9nV9k0JSliCCEuMha125_WVqVroyKzCX9E1ahsS0F_Q/s200/100_4709.JPG" width="150" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj_skbhvYdcA5lhZ7CH8aVupU6aCaK1OiGSg58zSr5spG0iDXvnSkbp-3kmNDnW-NhzG5aVRtRUXxVTnlNHrHHUimPpEtiq1CB91-mtdzkv1Yl4fhuU99F6ieFIrPkLVoM3izgCoB0T8X8/s1600/100_4711.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="200" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj_skbhvYdcA5lhZ7CH8aVupU6aCaK1OiGSg58zSr5spG0iDXvnSkbp-3kmNDnW-NhzG5aVRtRUXxVTnlNHrHHUimPpEtiq1CB91-mtdzkv1Yl4fhuU99F6ieFIrPkLVoM3izgCoB0T8X8/s200/100_4711.JPG" width="150" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhatU9_2S13jeTneTo95ht6QtQHhwPebinC6AtpNmo9ZJ06ZAmf-NizqPwODvb5L1a8pnzcdcWKzLZh-GP1KBRDJdldlvLwSwyJxQdqZTxUzcmhHeQQEc2AeMNpr8dJWbDfXnrtePQWeeQ/s1600/100_4707.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="200" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhatU9_2S13jeTneTo95ht6QtQHhwPebinC6AtpNmo9ZJ06ZAmf-NizqPwODvb5L1a8pnzcdcWKzLZh-GP1KBRDJdldlvLwSwyJxQdqZTxUzcmhHeQQEc2AeMNpr8dJWbDfXnrtePQWeeQ/s200/100_4707.JPG" width="150" /></a></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEho3wxCWPnMW4yg-1xLz-BkA01Yiy8kods_pCJO94HialNfFUSP1S3WBXidblyPndgvoi4vkyetqhuWHrOCYUhziG1u3UXNpv_1sulxgZyXXu3mff3ru8txSPa7vKx_XnhGBrM3d4AiI9w/s1600/100_4710.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="200" j8="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEho3wxCWPnMW4yg-1xLz-BkA01Yiy8kods_pCJO94HialNfFUSP1S3WBXidblyPndgvoi4vkyetqhuWHrOCYUhziG1u3UXNpv_1sulxgZyXXu3mff3ru8txSPa7vKx_XnhGBrM3d4AiI9w/s200/100_4710.JPG" width="150" /></a></div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0tag:blogger.com,1999:blog-2305433605932912115.post-70740801301601484312011-04-06T16:40:00.015-04:002011-04-11T23:18:12.554-04:00Arduino Light Pen!<div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: left;"> A simple Light Pen, created using the TVout library with the Arduino and a simple phototransistor sensor. </div><br />
<div class="separator" style="clear: both; text-align: center;"><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.youtube.com/embed/vuUE2AqZqSU?feature=player_embedded' frameborder='0'></iframe></div><div class="separator" style="clear: both; text-align: left;"><br />
</div><code>#include <TVout.h><br />
#include <fontALL.h> <br />
#include <video_gen.h></code><br />
<br />
<code>long s1,s2;<br />
TVout TV;<br />
int sz=8;</code><br />
<br />
<code>void setup() {<br />
TV.begin(0,128,96);<br />
TV.select_font(font6x8); <br />
}</code><br />
<br />
<code>void loop() { <br />
for (int x=3; x<112; x=x+16) {<br />
for (int y=32; y<40; y=y+16) {<br />
s1=analogRead(0);<br />
TV.draw_rect(x,y,sz,sz,1,1);<br />
TV.delay_frame(2);<br />
s2=analogRead(0);<br />
TV.draw_rect(x-2,y-2,sz+5,sz+5,0,0);<br />
if (abs(s2-s1)>10) {<br />
TV.draw_rect(x-2,y-2,sz+5,sz+5,1,0);<br />
TV.delay_frame(5);<br />
};<br />
};<br />
};<br />
}</code><br />
<br />
<code>Virtually any light sensor will work, as long as it can provide an output that can be handled by the ATMEGA328's Analog to Digital Converter. For the simplest form, a CDS photocell simply connected to +5v on one side and the Analog 0 input pin on the Arduino on the other may suffice.</code><br />
<br />
<code>To increase sensitivity or adjust response, a simple voltage divider can be created by adding a variable resistance between Analog 0 and Ground with the above sensor.</code>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.comtag:blogger.com,1999:blog-2305433605932912115.post-81348758434227930282011-03-05T12:48:00.001-05:002011-03-05T12:56:03.073-05:00Homebrew 1200W Halogen Adjustable Photo Flood<div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjswxT8qcWJDTrJgnMfcQp8EwPlQCujZF9XZU7_FohlKZrlr_7Eh1-SQtyYRiGulXUE93PG3taS6FVJ4iKXBLYmxtEGKa76w5-ZLZDISOpepg_EOzv0KZjP9NlAl6PM4NXjbpfGTfYUTDI/s1600/100_4639.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="150" l6="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjswxT8qcWJDTrJgnMfcQp8EwPlQCujZF9XZU7_FohlKZrlr_7Eh1-SQtyYRiGulXUE93PG3taS6FVJ4iKXBLYmxtEGKa76w5-ZLZDISOpepg_EOzv0KZjP9NlAl6PM4NXjbpfGTfYUTDI/s200/100_4639.JPG" width="200" /></a>So, I've got a few things coming up that require a portable, adjustable, high-power floodlight system for photography use. A wander around Home Depot, and for under $70, I was able to assemble a very workable Halogen flood rig using four 300W halogen bulbs in two heads, with linear faders, including reasonable-duty tripod.</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjNKWD0btAW8cfVPUCR4yFKVIDjauHadp-atDsOaj58f8gQkgsKdXuV6sF6QuSfgtRz-yvHZfVXF-v6fFVs8eBYy6hcri9BGQIRKu36DbUJ8jrsFb11W4LaXK8HYiPtVvomsQ8pjzwyJGY/s1600/100_4643.JPG" imageanchor="1" style="clear: left; cssfloat: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="200" l6="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjNKWD0btAW8cfVPUCR4yFKVIDjauHadp-atDsOaj58f8gQkgsKdXuV6sF6QuSfgtRz-yvHZfVXF-v6fFVs8eBYy6hcri9BGQIRKu36DbUJ8jrsFb11W4LaXK8HYiPtVvomsQ8pjzwyJGY/s200/100_4643.JPG" width="150" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLzaSEyJq4km6iuVJCaBNN0sd7vUYU2Esapc2E-RZq_uEo3lDBBgqOecfmuJKzN3B5O5v5FwJ4aXX7kPbUjM2HBZs04K4OL3h7PKyb9v7fRmOl1NsN2pGazPtU3v92bbnLlkvvfpBKcys/s1600/100_4642.JPG" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="200" l6="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLzaSEyJq4km6iuVJCaBNN0sd7vUYU2Esapc2E-RZq_uEo3lDBBgqOecfmuJKzN3B5O5v5FwJ4aXX7kPbUjM2HBZs04K4OL3h7PKyb9v7fRmOl1NsN2pGazPtU3v92bbnLlkvvfpBKcys/s200/100_4642.JPG" width="150" /></a>Home Depot sells a two-head, four bulb halogen floodlight with tripod for $45. Each head has two switches on the back to switch the individual bulbs in the head. Add in a 4" square wiring box ($1), and two standard dimmer switches ($10 ea), and you have a very powerful, adjustable flood for under $70.</div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;">Sure, it's not the most complex thing ever.. however, it is EXTREMELY useful and just about the cheapest solution I could come up on short notice. 1200 Watts (all on, full power) of Halogen light is simply blinding, and should provide plenty for full-length shots. Not shown (but coming) is PVC pipe counterbalanced boom attached to the tripod with a 250W Halogen flood, for providing downlighting. The halogen flood cost $13, and a 10' run of 1 1/4" PVC pipe cost $3.50... and another $2 in a couple of carriage bolts.</div></div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0tag:blogger.com,1999:blog-2305433605932912115.post-14540213722908656992010-12-27T19:56:00.007-05:002010-12-27T20:20:09.853-05:00Zombie Snack - an Arduino LCD game<span style="color: blue; font-family: "Courier New", Courier, monospace; font-size: x-small;"><span style="color: black; font-family: Times New Roman; font-size: small;">Zombie Snack... a simple game, inspired by some of the dice-roll combat games of years gone by. Eat brains, impress the ladies.<br />
<br />
Two buttons.. <br />
Button One (digital 2) is EAT, which sends you after your human prey. <br />
Button Two (digital 3) is RUN, which chooses to walk away.<br />
<br />
You have fifty hit points to kill and eat as many humans as you can, but humans vary in strength and they fight back! If you reach zero hit points before you walk away, you die.. and score zero brains, no matter how many you had eaten until that point. The goal is simple.. eat as many brains as you can while still having enough health to walk away!<br />
<br />
Choose when to EAT and when to RUN carefully!<br />
<br />
Press RESET to play again.<br />
<br />
Potential future enhancements: Multiplayer, High Score Retention, and Specials (powerups for both Zombies and Humans!)<br />
<br />
Full Code (in blue):</span></span><br />
<span style="color: blue;"><br />
<span style="font-family: "Courier New", Courier, monospace; font-size: x-small;"> </span><span style="font-family: "Courier New", Courier, monospace;"><span style="font-size: x-small;"><span style="color: blue;"><span style="color: blue;">// ** Zombie Snack 1.0 **<br />
// by Paul Bishop<br />
// 12/27/2010<br />
// --------------------------------<br />
// A Brain-Munching Game for<br />
// Arduino. Program assumes<br />
// 16x2 LCD connected on digital<br />
// lines 7-12, and button switches<br />
// on digital 2 & 3, ideally with<br />
// 10k pulldown resistors (below)<br />
//<br />
// 10k Ohm<br />
// Pin >----+---/\/\/\-------GND<br />
// |<br />
// SWITCH<br />
// |<br />
// +-----/\/\/\-------5v<br />
// 100 Ohm<br />
//<br />
// LCD pins may be changed, but switches<br />
// drive interrupts and must be on pins 2 & 3.<br />
//<br />
// Button connected to Pin 2 : "Eat"<br />
// Button connected to Pin 3 : "Run"</span></span></span></span><span style="color: blue;"><br />
<span style="font-family: "Courier New", Courier, monospace; font-size: x-small;">#include <LiquidCrystal.h><br />
LiquidCrystal lcd(7, 8, 9, 10, 11, 12); // 4-bit mode for LCD<br />
byte c1[8] = {<br />
14,14,4,14,17,4,10,27}; // bitmap for human<br />
int human;<br />
int brains=0;<br />
int hp=50;<br />
int i,j,k=0;<br />
int z;<br />
volatile byte eat_press=0;<br />
volatile byte run_press=0;<br />
int action;<br />
<br />
<br />
<br />
void setup() {<br />
pinMode(3,INPUT); // Input is two buttons,<br />
pinMode(2,INPUT); // "Eat" and "Run"<br />
digitalWrite(3,HIGH); // Enable pullup resistors<br />
digitalWrite(2,HIGH); //<br />
attachInterrupt(0, eat, RISING); // handling buttons via ISR<br />
attachInterrupt(1, run, RISING); // simplifies timing<br />
<br />
randomSeed(analogRead(0)); // Seed random number gen<br />
<br />
lcd.begin(16, 2); // set up the LCD's number of columns and rows<br />
lcd.clear(); // and set our preferences<br />
lcd.noAutoscroll();<br />
lcd.noCursor();<br />
lcd.createChar(0, c1); // 5x8 character bitmap from c1<br />
lcd.setCursor(0, 0); <br />
lcd.print("Zombie Snack 1.0"); // Splash screen.<br />
lcd.setCursor(0, 1);<br />
lcd.print(" Come-n-Get It!"); <br />
delay(3000); <br />
}<br />
<br />
<br />
<br />
void loop() {<br />
lcd.setCursor(0,0);<br />
lcd.print("Brains:");<br />
lcd.print(brains);<br />
lcd.print(" HP:");<br />
lcd.print(hp);<br />
lcd.print(" ");<br />
lcd.setCursor(0,1);<br />
lcd.print(" ");<br />
lcd.setCursor(0,1);<br />
lcd.print("Human! ");<br />
<br />
for (int k=0; k<6; k++) {<br />
lcd.setCursor(8,1);<br />
for (i=0; i<k; i++) {<br />
lcd.write(32);<br />
};<br />
lcd.write(0);<br />
delay(100);<br />
if (eat_press==1) {<br />
attack();<br />
};<br />
if (run_press==1) {<br />
game_over();<br />
};<br />
};<br />
<br />
for (int k=5; k>-1; k--) {<br />
lcd.setCursor(8,1);<br />
for (i=0; i<k; i++) {<br />
lcd.write(32);<br />
};<br />
lcd.write(0);<br />
lcd.write(32);<br />
delay(100);<br />
if (eat_press==1) {<br />
attack();<br />
};<br />
if (run_press==1) {<br />
game_over();<br />
};<br />
};<br />
}<br />
<br />
void eat()<br />
{<br />
eat_press=1;<br />
}<br />
<br />
void run()<br />
{<br />
run_press=1;<br />
}<br />
<br />
void attack()<br />
{<br />
lcd.clear();<br />
lcd.print("Zombie Attack!!");<br />
randomSeed(analogRead(0));<br />
human=random(10)+1;<br />
lcd.setCursor(0,1);<br />
lcd.print("Human- ");<br />
lcd.print(human);<br />
lcd.print(" hp!");<br />
<br />
delay(3000);<br />
while (human>0) {<br />
lcd.clear();<br />
lcd.print("Attack!!");<br />
lcd.setCursor(0,1);<br />
lcd.print("HP:");<br />
lcd.print(hp);<br />
lcd.print(" ");<br />
for (k=0; k<(10-human);k++) {<br />
lcd.print(" ");<br />
};<br />
for (k=0; k<human; k++) {<br />
lcd.write(0);<br />
};<br />
action=random(2)+1;<br />
if (action==1) { // Yeah! You Hit the Human!<br />
lcd.setCursor(0,0);<br />
lcd.print("CHOMP! Human -1");<br />
human=human-1;<br />
if (human==0) {<br />
delay(500);<br />
lcd.clear();<br />
lcd.setCursor(0,0);<br />
lcd.print(" Human Dead!");<br />
lcd.setCursor(0,1);<br />
lcd.print(">>> BRAINS! <<<");<br />
brains=brains+1;<br />
delay(2000);<br />
};<br />
};<br />
if (action==2) { // Ouch! You got hit!<br />
lcd.setCursor(0,0);<br />
lcd.print("OUCH! Your HP -1");<br />
hp=hp-1;<br />
if (hp==0) {<br />
game_over();<br />
};<br />
};<br />
delay(1000);<br />
};<br />
eat_press=0;<br />
lcd.setCursor(0,0);<br />
lcd.print("Brains:");<br />
lcd.print(brains);<br />
lcd.print(" HP:");<br />
lcd.print(hp);<br />
lcd.print(" ");<br />
lcd.setCursor(0,1);<br />
lcd.print(" ");<br />
lcd.setCursor(0,1);<br />
lcd.print("Human! ");<br />
}<br />
<br />
void game_over()<br />
{<br />
run_press=0;<br />
lcd.clear();<br />
if (hp==0) {<br />
brains=0;<br />
lcd.setCursor(0,0);<br />
lcd.print(">> You Died! <<");<br />
lcd.setCursor(0,1);<br />
lcd.print("Brains: 0");<br />
}<br />
else<br />
{<br />
lcd.setCursor(0,0);<br />
lcd.print("Good Ghoul!");<br />
lcd.setCursor(0,1);<br />
lcd.print("Brains Eaten: ");<br />
lcd.print(brains);<br />
};<br />
<br />
while (1) {<br />
}; //loop forever</span></span><br />
<span style="color: blue;"><span style="font-family: "Courier New", Courier, monospace; font-size: x-small;">}</span></span></span>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0tag:blogger.com,1999:blog-2305433605932912115.post-85764833083801211362010-11-19T13:50:00.015-05:002010-11-29T23:39:56.224-05:00Schematic- Arduino Spectrum Analyzer<div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: left;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"> <br />
<div style="text-align: right;"></div> <br />
<div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><strong><span style="font-size: large;">Arduino Spectrum Analyzer with Video Out - Schematic</span></strong></div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjRlvh-Oydwkczal10dhbtl3US16f-kkny8u6g2kDSTPP56YG_apfUTHrcuR_i_DCqN7t3SJ-HzujkgcVylJ5xLN-VVsZSHJwMDbQoKDx_xDV5gDZB4GEmqSt4uQQ2JON6crehoTA1ydVU/s1600/Untitled+Sketch_schem.jpg" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="264" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjRlvh-Oydwkczal10dhbtl3US16f-kkny8u6g2kDSTPP56YG_apfUTHrcuR_i_DCqN7t3SJ-HzujkgcVylJ5xLN-VVsZSHJwMDbQoKDx_xDV5gDZB4GEmqSt4uQQ2JON6crehoTA1ydVU/s320/Untitled+Sketch_schem.jpg" width="320" /></a> <br />
<div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><span style="color: blue;"><strong>Components:</strong></span></div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><span style="background-color: white; color: blue;">(1) 2n3904 NPN Transistor [Q1]</span></div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><span style="background-color: white; color: blue;">(3) 1k Ohm Resistor [R2,R4,R5]</span></div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><span style="background-color: white; color: blue;">(1) 330 Ohm Resistor [R6]</span></div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><span style="background-color: white; color: blue;">(1) 10k Ohm Resistor [R1]</span></div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><span style="background-color: white; color: blue;">(1) 100k Ohm Resistor [R3]</span></div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><span style="background-color: white; color: blue;">(1) Electrolytic Capacitor, 3.3MF [C1]</span></div></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><span style="background-color: white; color: blue;">(1) Electret Microphone [MIC1]</span></div></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"><br />
</div>If gain is insufficient, replace Q1 (2n3904 transistor) with higher gain transistor or darlington pair.<br />
<br />
Video out is NTSC/PAL Composite, if necessary a coupling capacitor and diode can be added.<br />
<br />
<br />
<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.blogger.com/video.g?token=AD6v5dw9sCggczSZlOiBwDbQiK_aZxkJO9U1fctjUKwYK3KhnU61cvkz-ZWMeLYsJiDnWvECL4QAz2lttHcnczLZeg' class='b-hbp-video b-uploaded' frameborder='0'></iframe></div><div class="separator" style="clear: both; text-align: center;"><br />
</div><div class="separator" style="clear: both; text-align: center;">The code for this version is on the previous blog entry, a revised version of both the code and the circuit will be posted within the next several days, as the TVout library is being re-released with significant changes which make compatibility with this setup a problem. I'm waiting on releasing the new code and circuit until the library author's release, to avoid confusing folks.</div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com6tag:blogger.com,1999:blog-2305433605932912115.post-53192339425060883372010-11-14T14:43:00.030-05:002010-11-19T13:53:40.745-05:00Arduino Realtime Audio Spectrum Analyzer with Video out!<div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhKaLmB038WBgSv3Vk9j0dt2V_PKwkhKTM_P3mQEiMebdU2S7iF7o39uaZbSwY7qoEwL5NhTWEta8l0auJ2kl-e2ct8ldan6rTsqyHlMQHIsUSzYzjeXj0I-kSErjT_6F-bdzE6l_vl0Rc/s1600/100_4492.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="240" px="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhKaLmB038WBgSv3Vk9j0dt2V_PKwkhKTM_P3mQEiMebdU2S7iF7o39uaZbSwY7qoEwL5NhTWEta8l0auJ2kl-e2ct8ldan6rTsqyHlMQHIsUSzYzjeXj0I-kSErjT_6F-bdzE6l_vl0Rc/s320/100_4492.JPG" width="320" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgf0sPUxFCJ5zlkpsxu9wh0zInFW7IWIDuHY79GBYVD0B7S6UJv2nhxXI1pyV7hJQPU-ZOV2ti84LR_PAsnZH4ekG-612rnPHtZnEpCttvRN5kcu8IvmuUsTmSH5dpwQNwiP1yCyC6MRvw/s1600/100_4493.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="240" px="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgf0sPUxFCJ5zlkpsxu9wh0zInFW7IWIDuHY79GBYVD0B7S6UJv2nhxXI1pyV7hJQPU-ZOV2ti84LR_PAsnZH4ekG-612rnPHtZnEpCttvRN5kcu8IvmuUsTmSH5dpwQNwiP1yCyC6MRvw/s320/100_4493.JPG" width="320" /></a></div><br />
<div style="text-align: justify;">Once again, I decided to put the old travel DVD player's screen to good use by using as an output device for the Arduino. Though the DVD mechanism is broken, the screen allows for standard NTSC composite video input.. runs on an attached rechargeable battery pack (can also power the Arduino.) </div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">I make no guarantees, and you do so AT YOUR OWN RISK, but it should work with any TV or device that allows NTSC Video In. I am in no way responsible if you damage yourself or your equipment. This is a prototype built by an amateur, keep that in mind.</div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; text-align: justify;"><br />
A brilliant bit of code, the TVout <span style="color: black;"><a href="http://www.arduino.cc/playground/Main/TVout">http://www.arduino.cc/playground/Main/TVout</a></span> library for Arduino, allows you to generate composite NTSC monochrome video with only two pins and two resistors. I generally leave the resolution at the default 128x96, which translates to 16x12 text with the default 8x8 font. Running under the defaults seems to give the least amount of trouble with this library, which is a work in progress. Note that due to this library being actively worked on, there's no guarantee the code I am using will work with other IDE or Library versions. This has been developed using version 0019, though I will be testing shortly on the most recent releases. In addition, though it should not matter, I am using a 5v Adafruit Boarduino. There should be no differences, as long as your Arduino is a 5v device. Also note that old versions of Arduino which use an Atmel ATmega168 won't be able to run this, they don't have enough memory.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">The other piece of the puzzle is collecting and processing audio, so we have something to display on our little display.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">The first piece- data collection- is fairly standard. I use an electret microphone (which alone only produces a few mV output, far too low for our Arduino to use directly) with a transistor amplifier as the signal source, which is then sampled via the ADC on the Analog 0 pin of the Arduino. </div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">To do spectrum analysis however, you need to capture signal over time, then process that data with what is known as a Fourier Transformation. This magical process takes a signal and breaks it down into buckets based upon frequencies found within the sample. This produces a remarkably good picture of the signal.. and if displayed, functions as a visual spectrum analyzer if looped over and over.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">In this project, I've used code posted by a user to the Arduino forums:<br />
<span style="color: black;"><a href="http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1286718155">http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1286718155</a>.</span><br />
<br />
This post contains a library which performs both the sampling and the Fast Fourier Transformation completely in C in 8 bits, amazing fast considering that fact, and uses a few tricks to be really stingy on memory, which is at a premium on Arduino- especially with the TVout data space eating up quite a bit. Since the Atmega 328 only has 2k of RAM, every byte counts. Matrix math done like this is nothing short of awesome. Best of all, it's usable as a library. Cut and paste the .cpp and .h into a new folder named "FFT" in the Libraries directory. My Arduino project code is adapted from the original code from the forum-posted Arduino program.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">So, to produce our desired outcome, we just need to get to get the whole show together and hope it can perform.. With only a handful of cheap components (a few dollars at most), it produces a perfectly usable and quite entertaining realtime 64-band video spectrum analyzer. Though not really "useful" for any real purposes, it makes an entertaining party display out of any television with a video input...</div><br />
<div class="separator" style="clear: both; text-align: center;"><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.blogger.com/video.g?token=AD6v5dz46imdhLChVE4GROZWl_SXMK7ziwioyjwwlpsDkI1dyL5ckhUFcvHFjKBgLLNm81qraZtW7gwc6MmUNTn3Ww' class='b-hbp-video b-uploaded' frameborder='0'></iframe></div><div class="separator" style="clear: both; text-align: center;"><br />
</div>There are a lot of improvements which can be made- the first being the amplifier gain to make it a bit more responsive, and optimization of the FFT code. In reality, it's the drawing of the bars which takes the most time per sample/display cycle..not the matrix math!<br />
<br />
Arduino Code:<br />
<br />
<span style="color: blue; font-family: Times New Roman;">#include <TVout.h><br />
#include <fix_fft.h></span><br />
<span style="color: blue; font-family: Times New Roman;">TVout TV;<br />
char im[128], data[128], lastpass[64];<br />
char x=32, ylim=90;<br />
int i=0,val;</span><br />
<span style="color: blue; font-family: Times New Roman;">void setup()<br />
{ <br />
TV.begin(_NTSC,128,96); // Initialize TV output, 128x96.<br />
TV.print_str(2,2," Realtime Arduino"); // TVout lib uses x,y for print<br />
TV.print_str(2,11," Spectrum Analyzer"); // statements. 8x8 default font.<br />
analogReference(DEFAULT); // Use default (5v) aref voltage. <br />
for (int z=0; z<64; z++) {lastpass[z]=80;}; // fill the lastpass[] array with dummy data<br />
};</span><br />
<span style="color: blue; font-family: Times New Roman;">void loop()<br />
{<br />
for (i=0; i < 128; i++){ // We don't go for clean timing here, it's<br />
val = analogRead(0); // better to get somewhat dirty data fast<br />
data[i] = val/4 -128; // than to get data that's lab-accurate<br />
im[i] = 0; // but too slow, for this application.<br />
};<br />
<br />
fix_fft(data,im,7,0);<br />
<br />
for (i=1; i< 64;i++){ // In the current design, 60Hz and noise<br />
data[i] = sqrt(data[i] * data[i] + im[i] * im[i]); // in general are a problem. Future designs<br />
TV.draw_line(i+x,lastpass[i],i+x,ylim,0); // and code may fix this, but for now, I<br />
TV.draw_line(i+x,ylim,i+x,ylim-data[i],1); // skip displaying the 0-500hz band completely.<br />
lastpass[i]=ylim-data[i]; // if you insist, initialize the loop with 0<br />
}; // rather than 1.<br />
};</span><br />
<span style="color: blue;"> </span><span style="color: black; font-family: Times, "Times New Roman", serif;">The circuit required is a simple microphone and transistor amplifier, as well as two resistors connected to D8 and D9 to provide video signal. See the next blog post for the schematic.. drawing is a much bigger pain than you'd think!</span>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com14tag:blogger.com,1999:blog-2305433605932912115.post-90147772712466639212010-08-13T16:10:00.007-04:002010-08-13T17:23:34.581-04:00Fiat Lux! (Let There Be Light)<div style="text-align: justify;">Since I wasn't up to retesting the HDR function at Wayside today, I've decided to do a little bench work and incorporate a light sensor. It seems that light-based triggers are a common project for people interfacing a camera to a microcontroller, and for very good reason.. both infrared and visible light triggering can be very useful in photography. No exceptions here, and we're going to use a very simple and flexible interface which will allow for use of several types of sensors with minimal headaches.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">The circuit itself really could not be more simple:</div><br />
<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4nCYv4BSz5t_BsTuD0SEWMvXbiEmVl4z0xKPxqqXO0hdjKIwPLughjIJzcSU1ua7lGNU-R-O3LsHmy2FUilMnCceF3pxna10Kk5E6WfzkiGPiM-kW5e1UN__5gq__D_WdcqaW08ptALk/s1600/sensor1.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="242" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4nCYv4BSz5t_BsTuD0SEWMvXbiEmVl4z0xKPxqqXO0hdjKIwPLughjIJzcSU1ua7lGNU-R-O3LsHmy2FUilMnCceF3pxna10Kk5E6WfzkiGPiM-kW5e1UN__5gq__D_WdcqaW08ptALk/s320/sensor1.jpg" width="320" /></a></div><div class="separator" style="clear: both; text-align: justify;">Basically, we're just going to create a voltage divider. Think of it this way: the balance between adjustment resistor and the sensor controls how much of the 5 volts goes to the analog port and how much gets dumped to ground. We'll use a variable resistor (a potentiometer) for the Adjustment Resistor, to obtain some working values. This adjustment resistor will account for varying response curves of various components, and allow us to tweak our build a bit. We'll be coming back to that adjustment resistance in the future.</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;">For our first run at this, I'll use an Infrared Phototransistor. This is sold by Radio Shack as part of an emitter/detector pair with part number 276-0142. I try to use very common and inexpensive components.. nearly any part I use is available at Radio Shack or other hobby electronics retailers. Keep the emitter around, we'll be having some fun with that too. Virtually any phototransistor will work, they just vary in terms of sensitivity and frequency range.</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;">The phototransistor from the Radio Shack emitter/detector pair is about as basic as you can get, peaks out sensitivity-wise around 850nm, and is easy to use. Simply put, configured as we have got it, the phototransistor will allow a varying voltage to reach the microcontroller's Analog Pin 0 based upon the amount of light falling on it. For the initial value of the adjustment resistor, I had a 15k ohm handy, which was enough for starters. The 15k resistor was replaced with a potentiometer to judge the effects with a number of different sensors, as we'll see.</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;">Now all we need is a little code to test it out. Happily, the Arduino IDE has "AnalogInSerialOut" as the first sketch in the code snippet library. We'll just load that up and open the Serial monitor to see the values being produced. That's all the usefulness we'll get from the sketch at the moment, but it's an easy interface to visualize the data so you can test. Of course, you can write your own sample-and-send-to-serial sketch also.. but I am tremendously lazy and am happy with kludges as long as they work. For reference, a "kludge" is a term used to discuss technical solutions which are by no means pretty or the right way- but they work. In some ways, Arduino is a huge kludge- it'll get the job done, but a purist may look on with disgust because we aren't developing in Assembler. In the end, if our project works.. it's the right answer, in my opinion. Maybe if this were a commercial product, but I see no reason to make life any harder than we have to for ourselves.</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div style="text-align: justify;"><br />
</div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0tag:blogger.com,1999:blog-2305433605932912115.post-4765603640154071762010-08-12T17:35:00.032-04:002010-08-13T14:57:49.947-04:00HDRduino Test Drive!<div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"></div><table align="center" border="1" cellpadding="0" style="width: 630px;"><tbody>
<tr align="center"><td><br />
<div></div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiVLZ3vbkYg1sQAiG23EmK8VtDGz8izW4lKr0n4SjsJGPjFOnvXzBpwUgR0AtHfMU4v5aNK0tX8Z2QXqxRfXc4vGudoJWE4kA15E7X60xtoHnuqfEohkXDfnKdy5Bu-ESQF6ol0LmVWTcI/s1600/IMG_6034.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="133" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiVLZ3vbkYg1sQAiG23EmK8VtDGz8izW4lKr0n4SjsJGPjFOnvXzBpwUgR0AtHfMU4v5aNK0tX8Z2QXqxRfXc4vGudoJWE4kA15E7X60xtoHnuqfEohkXDfnKdy5Bu-ESQF6ol0LmVWTcI/s200/IMG_6034.JPG" width="200" /></a></div><div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"></div></td><td><br />
<div></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjDBZlAyQhAd9_Wa6oqjAFz4fLyLyrJxJk_RuQo9qrI9xt3MXuVvcWZHAlG9LBajbtkLwp_FI8lqE2DCjnTcEuFMIwfc4M42Q2qeQDSUlcGuJko76r45yDoDCzB5lHlO9C4NFbD2HeQyLs/s1600/IMG_6033.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="133" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjDBZlAyQhAd9_Wa6oqjAFz4fLyLyrJxJk_RuQo9qrI9xt3MXuVvcWZHAlG9LBajbtkLwp_FI8lqE2DCjnTcEuFMIwfc4M42Q2qeQDSUlcGuJko76r45yDoDCzB5lHlO9C4NFbD2HeQyLs/s200/IMG_6033.JPG" width="200" /></a></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"></div></td><td><br />
<div></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhm1y0zXV2OZJEydTZzEJax9pobu0uYCElbv20c6pwvnDMFIOHwngkIlwYSVIYMhyphenhyphenhEAVDHvnzoG6vkUcXBb79FHHew82Mp2MRxEKN0k1GwenY5pBUn-8nIGVROZWKRCq1ELlmRAc5o64Q/s1600/IMG_6036.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="133" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhm1y0zXV2OZJEydTZzEJax9pobu0uYCElbv20c6pwvnDMFIOHwngkIlwYSVIYMhyphenhyphenhEAVDHvnzoG6vkUcXBb79FHHew82Mp2MRxEKN0k1GwenY5pBUn-8nIGVROZWKRCq1ELlmRAc5o64Q/s200/IMG_6036.JPG" width="200" /></a></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"></div></td></tr>
<tr><td><br />
<div></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg-aHDbwNiAb6i410dM3yaTltzNWvA-9mKWFTZvslwmevjVJxGVK7NnORBLGg878Y-vvpDD-1a8SJw0E6bu4JpJ164ydVuMjSX9_TQu4QEi_k43SWSf11LRrVyVKibwowPzeBvT7hKH3q8/s1600/IMG_6037.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="133" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg-aHDbwNiAb6i410dM3yaTltzNWvA-9mKWFTZvslwmevjVJxGVK7NnORBLGg878Y-vvpDD-1a8SJw0E6bu4JpJ164ydVuMjSX9_TQu4QEi_k43SWSf11LRrVyVKibwowPzeBvT7hKH3q8/s200/IMG_6037.JPG" width="200" /></a></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"></div></td><td><br />
<div></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEijvC5L1BiCW6qLPV9f4RSMoCzEXoUpaaxGLYhqdHjtzuyXcIGN0nR8CGUAT0CykVdxjQUHg6ZYveU5sZs0R1OPaaU2GjOKCq6kvz3K-TYgJF_AthhIhn_u3Pdm7AQoDHKJFE8w5y9sVsI/s1600/IMG_6038.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="133" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEijvC5L1BiCW6qLPV9f4RSMoCzEXoUpaaxGLYhqdHjtzuyXcIGN0nR8CGUAT0CykVdxjQUHg6ZYveU5sZs0R1OPaaU2GjOKCq6kvz3K-TYgJF_AthhIhn_u3Pdm7AQoDHKJFE8w5y9sVsI/s200/IMG_6038.JPG" width="200" /></a></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"></div></td><td><br />
<div></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj4xTYBp8ZNFmbI2dMImU9aeuYmlcFKCfgnSrPPjhvcLqVn5XWO64TRPhKuD9RubI53XQeIm8PT4Ti5aZaFj-lP6GScctjQrTcMDJItBh52197uFTeUZdiMAqNe6wtfu_eIHpbOIjgeu4Y/s1600/IMG_6039.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="133" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj4xTYBp8ZNFmbI2dMImU9aeuYmlcFKCfgnSrPPjhvcLqVn5XWO64TRPhKuD9RubI53XQeIm8PT4Ti5aZaFj-lP6GScctjQrTcMDJItBh52197uFTeUZdiMAqNe6wtfu_eIHpbOIjgeu4Y/s200/IMG_6039.JPG" width="200" /></a></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"></div></td></tr>
</></></></></>
<tr><td colspan="3"><div style="text-align: center;">Source Photos, Wayside Inn, Sudbury MA. Shots taken at 28mm f/29</div></td></tr>
</></></tbody></table><br />
<div></div><div style="text-align: justify;">Success! (of a sort). The six images above were produced using the Arduino-based HDR trigger we built and programmed last time. Of note was the fact the fastest shots were not picked up or taken reliably, of the nine shots triggered, only seven were taken by the camera itself. Consequently, we're successfully tested our HDR trigger, what's more, we've discovered that it may not perform quite as quickly as we had hoped. In addition, in retrospect, Wayside Grist Mill may not be the best choice, simply because the water wheel is in motion and becomes motion-blurred in longer shots. Note that we could account for that in editing, but for the moment, we're mainly concerned about the overall function.. and it did what we wanted it to do- took a series of bracketing exposures. <br />
<br />
<div></div>If you are doing this yourself, the camera needs to be set up in Manual mode, with the shutter duration set to "bulb"- which basically means externally controlled (by our trigger, at the moment). The scene is focused and a very small aperture is set on the lens- for this example, I used the smallest available aperture on my kit EF-S 18-55mm lens, f/29. Using a small aperture helps to maintain a deep field of focus, as well as allowing for longer exposure times. Once the scene is focused the lens is then placed in Manual focus mode, to prevent the lens from wasting time hunting for focus, especially since it will be a static scene. If we've focused once, it'll remain in focus during our time shots. </div><div style="text-align: justify;"><br />
<div></div></div><div style="text-align: justify;">Given the simplicity of the project, we shouldn't be displeased with the outcome. For processing, I chose ENFUSE!, with it's accompanying GUI. This is an Open Source software, and can be downloaded and used for non-commerical purposes under a GPL license. I processed the photos with the default software options, producing the HDR photo below. Now I'll agree it's probably not the most impressive HDR shot ever, however it does demonstrate that we're on the right track. We'll do some more shots after we address a few of the problems found, and see if we can get a little better at tweaking the software too. What's important to notice is that the HDR photo has uniform exposure across the entire scene- the brightness of the green trees in the foreground is lost in the "best" shot above, when the Mill is exposed well, leaving them underexposed. Conversely, some of the finer details are also lost to overexposure. The composite, or "High Dynamic Range" photo merges the exposures in an attempt to display all portions of the scene exposed properly.. at least that's the theory. In practice, it does a remarkable job at just that.. especially since this was our first attempt.<br />
<br />
<div></div></div><table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto; text-align: center;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiKLVYdF5P8g56G6Dv_2sfO5bD6m-ACMK_fTR4UfXGTj2cV4f6je5spj_Il7sbJNvTxYTQROzJn_F0vN3Xdj_uD11n0PdatO7RH_efcMstHmEpMOrITKii2MlK-z6fxHFbIgAeROnEvdW4/s1600/enfused3.jpg" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img border="0" height="428" ox="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiKLVYdF5P8g56G6Dv_2sfO5bD6m-ACMK_fTR4UfXGTj2cV4f6je5spj_Il7sbJNvTxYTQROzJn_F0vN3Xdj_uD11n0PdatO7RH_efcMstHmEpMOrITKii2MlK-z6fxHFbIgAeROnEvdW4/s640/enfused3.jpg" width="640" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Composite "HDR" Photograph produced from source photos, above.</td></tr>
</tbody></table><div align="justify" style="text-align: right;"><br />
<div></div></div><div align="justify" style="text-align: right;"></div><div style="text-align: justify;">Now, let's consider the other information learned:</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;"></div><div style="text-align: justify;">Two images were dropped, we'll assume they were the first two, due to short duration...Of the seven shots, the first two are so similar in exposure we have to assume we merely hit minimum exposure time on the longest. If we use "Mirror Lockup" mode we may gain some speed, so it appears somewhere near 1/100 second may be the fastest we'll get via shutter port (I'm using my Canon Rebel XT, for reference).</div><div style="text-align: justify;"></div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">Since we basically are saying the first three shots are being wasted, time wise, we're going to change our timing to begin at 1/100 second, as well as lock up the mirror in an attempt at getting just a little bit faster response. Eventually, we may move off of the shutter port and use USB to control the camera in much more precise a manner, but before we begin the rather painful undertaking of writing a USB host, we're going to explore and exploit the control we've gotten this far.<br />
<br />
It's important to note that any camera that has the ability to be remotely triggered will work with this device also, simply modify the plug to match the connection for your camera, as long as what's required is a simple switch-closure to operate the shutter.<br />
<br />
<span style="background-color: white; color: red;"><strong><u> As always, you probably void your warranty by connecting something like this to your camera-- anything you do, you do at your own risk!</u></strong></span><br />
<br />
Here's our updated code.. we'll set up for seven shots now, with a minimum of 10ms (1/100sec).. otherwise everything remains the same.<br />
<br />
<code></code><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>int shotcount = 7;</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>int shutterPin = 5;</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>long mintime = 10;</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>long delaytime;</strong></span><br />
<br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong></strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>void setup() </strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>{ </strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>pinMode(shutterPin, OUTPUT); </strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.begin(9600); // setup to communicate by serial</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>}</strong></span><br />
<br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong></strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>void loop() </strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>{</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.print("Sequence: "); // provide info by serial, if wanted</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.print(shotcount);</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.print(" shots, minimum ");</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.print(mintime);</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.println(" ms.");</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>int i=0;</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>delaytime=mintime;</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>while (i<shotcount) <="" p=""> < shotcount)</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>{ // loop until we take all the shots </strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.print("shot duration: "); // report out on serial line</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.print(delaytime);</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.println(" ms.");</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>digitalWrite(shutterPin, HIGH); // open the shutter</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>delay(delaytime); // wait for the exposure time</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>digitalWrite(shutterPin, LOW); // close the shutter</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>delay(2000); // wait two seconds for camera </strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>delaytime=delaytime*2; // double duration for 1eV step</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>i=i+1; </strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>};</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>Serial.println("Sequence Complete!");</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>while (1) {}; // Wait forever</strong></span><br />
<span style="font-family: Verdana, sans-serif; font-size: x-small;"><strong>}</strong></span><br />
<span style="font-family: "Courier New", Courier, monospace;"><br />
<strong></strong></span><br />
<span style="font-family: inherit;">Next time, we'll give our trigger another try with the new code, as well as look at how our Arduino looks at things...<br />
<strong></strong></span><br />
<span style="font-family: "Courier New", Courier, monospace;"><br />
<strong></strong></span><br />
<br />
</div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0tag:blogger.com,1999:blog-2305433605932912115.post-65265366378239330552010-08-04T20:10:00.031-04:002010-08-05T16:34:49.329-04:00HDRduino v1.0<div style="text-align: justify;">Last time, we fiddled with the Arduino, exploring the basics of what we need to do- essentially, open and close a switch in a sequenced and time-precise manner. This time, we're going to take the finished prototype, write the first version of the software, and give it a try.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">To begin, the circuit we'll be using is very simple- a single resistor and an optical isolator to protect our equipment from damaging voltages. The first version has no interface to the user- you plug it into the camera, set the camera to the aperture and focus you need, and turn on the Arduino. It will run through the program we write once, then put itself into an endless loop doing nothing until we remove power. Later I'll be putting this in a case of some sort, and adding at least a power switch. Until then, we'll simply connect the battery once everything else is in place. Not the most elegant solution, but I had no reasonable switches at the moment and we're only prototyping. Doing things like this is not really recommended- but if you are like me, you'll try to find a way to make do with what you have got.</div><br />
<br />
<div class="separator" style="clear: both; text-align: center;"></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRQUDum-LFFDpnLHytQb8ucPbFCtwQm6iTaU0bs-b2qbgujqjA08q5VtrFua0QopyoRtSmDEq-2cD8GIVez_GWt-ldMkUpUxkZZRRVzee2VZeAgaifPZZQGqbqVHHffJIVsaU8Up7KRdc/s1600/100_4378a.jpg" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" bx="true" height="126" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRQUDum-LFFDpnLHytQb8ucPbFCtwQm6iTaU0bs-b2qbgujqjA08q5VtrFua0QopyoRtSmDEq-2cD8GIVez_GWt-ldMkUpUxkZZRRVzee2VZeAgaifPZZQGqbqVHHffJIVsaU8Up7KRdc/s200/100_4378a.jpg" width="200" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgzVMTiH5qRnINKdIM6o-FuvNH0Yg9MbetupD05KsjyuTZ06VLVa28xAzi6UFm9mux4QeK7jWdN-oCxSC834akEc7BeWNOPOPyoHBgkX4AjpQJY1vFQsrWwvFM50m2AJt-jv_cdfdji_xM/s1600/shuttercircuit1.jpg" imageanchor="1" style="clear: right; cssfloat: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" bx="true" height="137" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgzVMTiH5qRnINKdIM6o-FuvNH0Yg9MbetupD05KsjyuTZ06VLVa28xAzi6UFm9mux4QeK7jWdN-oCxSC834akEc7BeWNOPOPyoHBgkX4AjpQJY1vFQsrWwvFM50m2AJt-jv_cdfdji_xM/s200/shuttercircuit1.jpg" width="200" /></a><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhw7xVCtJGkPxSWWhhmlum1V_eFZ_VLa5VGFV3VbrAEo0iAP4YBfVuDi1wBDvKXXktdrIBPzQBNYepBJSvvQO7IumT2Yb9uyFZdiGCQ_kYjjpNbBozT42bF19karoTQm3cKKpgPtopK6ug/s1600/100_4372.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" bx="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhw7xVCtJGkPxSWWhhmlum1V_eFZ_VLa5VGFV3VbrAEo0iAP4YBfVuDi1wBDvKXXktdrIBPzQBNYepBJSvvQO7IumT2Yb9uyFZdiGCQ_kYjjpNbBozT42bF19karoTQm3cKKpgPtopK6ug/s320/100_4372.JPG" /></a></div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: justify;">Assembled prototype, with 9v battery for power. The Arduino's onboard 5v regulator (seen just above the power plug in this photo) happily produces clean 5v for quite some time from a standard 9v battery. The tip and shield contacts from the 2.5mm plug go to the optoisolator output, which acts as a switch. Canon remote shutter releases are nothing more than pushbutton switches connected between these contacts. To make prototyping easier, the wires from the 2.5mm plug were soldered onto three breadboard header pins and then secured together with a dab of epoxy for a bit of mechanical strength.</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: justify;"><br />
</div><div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: justify;">The code we'll use this time includes reporting of the trigger's status via the serial port, mainly for troubleshooting purposes- however, since the overhead is small, I try to include some status outputs from my code to both illustrate it's function as well as potentially provide usable information. A running status feed is sometimes very useful to have.. and also allows others to use those feeds for their own purposes. Making ways for others to piggyback on your work is always a good idea in my book.</div><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">int shotcount = 9; // Hardcode for 9 shots for now</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">int shutterPin = 5; // </span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">long mintime = 4; // Try for 1/250sec min exposure</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">long delaytime;</span><br />
<br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">void setup() </span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">{ </span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">pinMode(shutterPin, OUTPUT); </span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.begin(9600); // setup to communicate by serial</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">}</span><br />
<span style="background-color: white; color: #073763;"><br />
<span style="font-family: "Courier New", Courier, monospace;">void loop() </span></span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">{</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.print("Sequence: "); // provide summary info by serial</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.print(shotcount);</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.print(" shots, minimum ");</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.print(mintime);</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.println(" ms.");</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">int i=0;</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">delaytime=mintime;</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">while (i < shotcount) {</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.print("shot duration: "); // dump shot info to serial</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.print(delaytime);</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.println(" ms.");</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">digitalWrite(shutterPin, HIGH); // open the shutter</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">delay(delaytime); // wait for the exposure time</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">digitalWrite(shutterPin, LOW); // close the shutter</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">delay(2000); // wait two seconds for camera </span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">delaytime=delaytime*2; // double duration for 1eV step</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">i=i+1; // go on to the next shot</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">};</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">Serial.println("Sequence Complete!");</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">while (1) {}; // Wait forever</span><br />
<span style="background-color: white; color: #073763; font-family: "Courier New", Courier, monospace;">}</span><br />
<br />
<div style="text-align: justify;"><span style="font-family: inherit;">When we upload the program to the Arduino and open the Serial Monitor (which displays the information the Arduino sends on the serial port), we get the following output over a period of about twenty seconds total. Power cycling or pressing the Reset button on the Arduino produces the same. If we assume the remote shutter hardware works properly, the results should be a series of nine photos, starting with a 1/250sec exposure and finishing with a 1 second exposure (1.024 seconds actually).</span></div><br />
<span style="color: #073763;">Sequence: 9 shots, minimum 4 ms.</span><br />
<span style="color: #073763;">shot duration: 4 ms.</span><br />
<span style="color: #073763;">shot duration: 8 ms.</span><br />
<span style="color: #073763;">shot duration: 16 ms.</span><br />
<span style="color: #073763;">shot duration: 32 ms.</span><br />
<span style="color: #073763;">shot duration: 64 ms.</span><br />
<span style="color: #073763;">shot duration: 128 ms.</span><br />
<span style="color: #073763;">shot duration: 256 ms.</span><br />
<span style="color: #073763;">shot duration: 512 ms.</span><br />
<span style="color: #073763;">shot duration: 1024 ms.</span><br />
<span style="color: #073763;">Sequence Complete!</span><br />
<br />
<div style="text-align: justify;">A few remarks: First that the minimum exposure of 4ms may not fully work. This is because it's been reported the fastest speed one can trigger on the shutter release is around 5ms which is 1/200sec. This minimum therefore will either work to produce a 1/250sec exposure, or as close as we'll get. As I understand this may be able to be reduced by using "Mirror Lock Up" function on the camera- but we'll worry about camera settings in a little while, after we get the trigger working. Additionally, since I am simply doubling the exposure time at each interval, we're not getting "true" standard exposure times.. but not too far off to make them unusable. In terms of exposure, there's little difference between a second and 1.024 seconds.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">This all being said, when plugged into the shutter release port on the side of my Canon Rebel XT and powered up, the camera began dutifully clicking away under the command of the little Arduino.</div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com2tag:blogger.com,1999:blog-2305433605932912115.post-25695002446853359782010-08-04T10:48:00.038-04:002010-08-04T19:42:25.017-04:00Arduino II.. A blinky light, and then something useful!<div style="text-align: justify;">Last time, I introduced the Arduino platform and the version of it that I am using, a "Boarduino" from Adafruit Technologies. In function, all of these devices are very similar. For my purposes I decided to go with the Boarduino simply because the vendor was local and I could get it quickly, as well as offering a basic set of extra components for experimentation.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">I will suggest that folks who are completely new to microcomputers and interfacing go for the "true" Arduino at the outset. The reason is simply that the support community and software out there focus on the Arduino as the common ground.. therefore "everything" works on the Arduino, while some variants (such as mine, the Boarduino) might require a little bit of tweaking to work properly. For me, this was a fun challenge- for some it might have been discouraging. In the end, to work with the latest version of the programming environment, I needed to select the device as a "Lilypad 328" and edit the file to properly reflect the 16Mhz CPU clock rate. That's something a novice wouldn't know to do, and had I been working with "true" Arduino hardware, the problems I had would not have been there in the first place. This being said, I truly am happy with my choice of the Boarduino, and think that there's room for both the off-the-rack Arduino and the Boarduino in my toolbox. The Boarduino is cheaper, simpler, and easy to incorporate into a finished project.. the Arduino is good for development, as it is the gold standard of the platform. From here on, I will refer to the Boarduino as an Arduino, as in all aspects that matter in terms of this project, they are functionally equivalent. I won't give a complete tutorial on the Arduino programming language, there are a number of them available online. If you are using this blog to construct a similar device, I also assume that you have gotten an Arduino of some flavor, and have successfully connected to it.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">If you decide to get an Arduino, the first thing you are going to do is make a blinky light. The reason is quite simple.. the most basic demonstration program for the Arduino is "Blink"... which blinks the LED on the Arduino off and on once a second. This is about as basic a program as can be written that actually DOES something, if you can call using hours of work and thirty dollars to do something that you can do with a $1.99 component from Radio Shack (blinking LED's are cheap) "something". This of course should not stop you from being proud that you did it. Here's the program, with the program comments changed.. this is the original "Blink" code included as an example program in the programming environment. A double slash "//" indicates the rest of the text on a line is a comment.</div><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>int ledPin = 13; // The arduino has an LED on pin 13. This requires no external wiring.</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>void setup() // When the arduino starts up, the setup() routine is run once</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>{</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>pinMode(ledPin, OUTPUT); // Tell the Arduino we plan to use the LED pin for output.</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>}</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>void loop() // The loop() routine runs over and over as long as the unit has power.</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>{</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>digitalWrite(ledPin, HIGH); // set the LED on</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>delay(1000); // wait for a second</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>digitalWrite(ledPin, LOW); // set the LED off</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>delay(1000); // wait for a second</strong></span><br />
<span style="font-family: Arial, Helvetica, sans-serif; font-size: xx-small;"><strong>}</strong></span><br />
<br />
<div style="text-align: justify;"><span style="font-family: inherit;">When this program is downloaded to the Arduino, sure enough, the LED blinks off and on, once a second. The program itself shows the simplified "C" language structure used, as well as what will be the most heavily used functions in control projects.. the ability to turn a pin output off and on, and the ability to implement precise enough delays to control external things, in my case, a camera. The program is simple enough for nearly anyone to understand and modify.. for example, if you were asked how to make the blink rate two seconds, it's not hard to figure out that would be done by changing the delay(1000) to delay(2000). (the delay command takes milliseconds, thousandths of a second, as it's parameter.) "Blink" is an excellent program to fiddle with, to learn a little. Try setting the "on" period to two seconds, with a half a second "off" period. The Arduino is "for" fiddling and learning, go ahead and fiddle and learn. Just don't admit in public just how much time you were able to amuse yourself by making a blinking light..</span></div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">Blink is the core of what I will be doing- controlling external hardware based upon timing. The first project for the camera, an HDR Photography shutter trigger, is scarcely more complex, only adding some changing delays to handle a range of exposures. </div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">HDR, or High Dynamic Range photography, is a process that is the natural extension of a photographic process known as bracketing. When a photo is taken, due to the nature of light, certain parts of any scene will be overexposed, some underexposed, and hopefully most will fall into the middle "correct" exposure. Bracketing simply means taking extra pictures, intentionally underexposing and overexposing on the extras- with the end result being that between the shots, ALL parts of the scene will have been properly exposed. These shots are then combined to produce a single image, with correct exposure levels on all parts of the scene. Sometimes aspects are manipulated for artistic effect, but often, the effect of HDR in general is both beautiful and surreal without taking liberties. Most higher-end consumer cameras and all professional cameras can do single bracketing, taking one shot above and below in terms of exposure, as a function. This project will do full-range bracketing for two ranges.. daylight and night. To do this, we lock the camera in terms of aperture and focus, and simply use the shutter "bulb" mode controlled by the Arduino via the remote control port on the camera. Via the shutter remote port, we can get speeds as fast as 1/200 second, which should be usable in the aperture ranges we will use.. typically f8 to f11- because at small apertures, the "in focus" depth of field will change little as the shutter time changes. Our little Arduino's job will be to open and close an electronic "switch" at the proper intervals to take the series of time shots to produce up nine bracketing images, across the entire range of exposures.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">There are a number of methods that could be used to change the digital output of the Arduino into the switch-type behavior we want- but for the sake of doing it "the right way" and protecting external equipment (like my camera), either a relay or an optical isolator puts an electronic barrier between your circuit and what you are controlling.. protecting both in the process. Relays introduce a certain amount of delay, draw quite a bit of current, and are more expensive- so I've chosen optical isolators. I was able to get a pack of six for three dollars from a local electronics store, Radio Shack also sells comparable ones. I'll be using Fairchild 4N25 Optoisolators. Aside from a couple of wires and a 2.5mm phono plug (Canon's remote trigger plug is simply a 2.5mm stereo plug) all we need is one of these optoisolators and a single resistor.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">If you question the need for the isolator, as I have been experimenting, I was triggering a flash unit which was faulty and backfed nearly 2000 volts into the circuit.. and the Arduino was still also connected to the PC at the time. Had the optoisolator not been in place, that voltage could have ended up frying both the Arduino and even potentially my PC. The fault cost me a fifty cent isolator, and convinced me to isolate as much as I can, to avoid problems!</div><br />
<div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjv8RkVUtUPSHAq04WP8jqplP-c5FPuO17S79Fr1u0_EUBAQGqQyOxRidD6Oi7uWGlwOMUS87xXXv8_XvdXtNlUrzbyLLr4izmH8XPBQ0PWVyUFC2pW8GbihyphenhyphenM1x8uA6pOfrl80eLEKutU/s1600/shuttercircuit1.jpg" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" bx="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjv8RkVUtUPSHAq04WP8jqplP-c5FPuO17S79Fr1u0_EUBAQGqQyOxRidD6Oi7uWGlwOMUS87xXXv8_XvdXtNlUrzbyLLr4izmH8XPBQ0PWVyUFC2pW8GbihyphenhyphenM1x8uA6pOfrl80eLEKutU/s320/shuttercircuit1.jpg" /></a> <span style="color: red;"><strong>Note: Connecting anything to your camera other than approved hardware probably voids the warranty! I am an experimenter and do not accept responsibility if you damage your equipment. If you are looking for a no-risk finished product, there are commercial products which perform these functions without the risks. This blog is for folks aware of the risks of prototyping hardware- I try to design well, but I provide no warranty as to the safety or usability of any project!</strong></span></div><div align="left" class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;">We'll be using Digital Pin 5 as the shutter control pin, as later on, we'll be using other pins for other functions. Next time, we'll upload our first version HDR program to the Arduino, plug it in, and see if we can get some useful shots!</div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0tag:blogger.com,1999:blog-2305433605932912115.post-9826014265642952762010-07-23T14:03:00.015-04:002010-08-04T16:06:44.766-04:00Adowhatnow? (Arduino and Atmel AVR Twiddling) : What is it?<span style="font-size: large;"><span style="color: red;"><strong><em><span style="font-size: x-large;">A</span>dowhatnow?</em></strong></span></span> Your Humble Narrator introduces the backbone of several projects.<br />
<br />
<div style="text-align: justify;">"<a href="http://www.arduino.cc/">Arduino</a>" is an open-source set of hardware and software designed around the ATMEGA series of microcontrollers. These are entire computers contained within a single chip.. with one of these chips, and a small number of external components, you have the framework for complex electronic projects and intelligent devices. It's intended to be used by people not normally interested in getting their hands dirty in the inner workings- artists (kinetic sculptures), robot builders, students, and prototyping hobbyists. In short, it simplifies the process of creating a special-purpose "smart" device.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">When referencing Arduino, many people refer to the entire package- the chip, the on-chip boot software, and the programming environment- as a single unit. In reality, nearly all aspects can be changed- the chips and hardware come in several flavors, as do boot software and the programming environment. To deviate from the "package" is fine, but with certain tradeoffs. Different flavor of hardware offer varying feature sets like memory size and operating speeds, while different development software platforms provide varying levels of programming ease traded off against efficiency. Development languages run the gamut- from simplified Firmata Scripting to Assembly Language coding (not for the faint of heart). There are even compiled and interpreted forms of BASIC which can be used. Because it provides a nice balance of simplicity and power, at least at the outset I will be using the Arduino development language, which is similar to "C" and based on a scripting language called Wiring. If you have ever done Java, Pascal, C++, or similar coding, then Arduino code should be easy to adapt to. Since this is mainly a command and control device, and we don't want to get too bogged down in syntax, the Arduino language and IDE will serve nicely while still keeping the code simple.. I'm a firm believer that keeping things simple makes for a better outcome. One nice aspect of the wide support base is that you can choose what you use- you don't need to change hardware if you change programming language and vice versa.</div><div style="text-align: justify;"><br />
</div><div style="text-align: justify;">To start off, I chose a variant of the Arduino called a Boarduino. I chose this variant because it offered several benefits for me over the "Off the Rack" standard Arduino. First, the Boarduino came as a self-assemble kit, not a finished product. It's been some time since I had done much electronic assembly, and considered that a well-designed kit would give me some much-needed practice soldering and handling components, while still being a project needing only an hour or so of relatively simple work. Secondly, the Boarduino design minimizes the component count, minimizing the complexity. Lastly, the Boarduino is extremely inexpensive, with the module components totalling around $15 per module, making it reasonable to dedicate a module to a "permanent" project. The absolute minimum hardware implementation of the chip circuit can be had for under $10 on eBay and other online vendors as of July 2010. Though underpowered for some of the projects I intend, there are Atmel processors which scale down to an eight-pin chip selling for under $2 each which still maintains a substantial amount of the function contained in the Atmega328/Arduino platform. Conversely, Atmel and others produce similar but far more powerful devices at substantially higher cost also. For my purposes, the chosen platform offers a nice blend of power while still fitting into a Hobby budget.</div><br />
<br />
<strong><span style="color: blue; font-size: large;"><em>Boarduino kit, Assembled. The birth of a new machine.</em></span></strong><br />
<br />
<div class="separator" style="clear: both; text-align: justify;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRfXgIWLk33wtWpraUfxbHv9XY8m9SUWxBkM14Fc-NsIKhOzCHrLNmfjlDGVqFWQB2Il3CaM45yVfYeOWMtMcU_SkYMi28dxe_lA_zwAUnYCfZGutUqkbrMSzfmLHs9yGi80M73QXEOVI/s1600/IMG_5097a.jpg" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" hw="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRfXgIWLk33wtWpraUfxbHv9XY8m9SUWxBkM14Fc-NsIKhOzCHrLNmfjlDGVqFWQB2Il3CaM45yVfYeOWMtMcU_SkYMi28dxe_lA_zwAUnYCfZGutUqkbrMSzfmLHs9yGi80M73QXEOVI/s320/IMG_5097a.jpg" /></a>Boarduino kit, purchased locally but designed and sold by <a href="http://www.adafruit.com/">Adafruit</a>. The local seller is actually a college student who is an avid fan of the Arduino/Atmega platform. In addition to the components and board for the Boarduino itself, included was a kit-form interface card to allow a home computer to communicate with it via a PC serial port, a solderless prototyping breadboard, and a small assortment of components (LED's, resistors, etc) to start out with.</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj9xmWySNHJCy4Uh4VRp4eoiITPOIoRKZWyoCrblC4q32qxFWv36R0w1fSnQEPXnVdxTqjHrRrOtSosFuwPTWJKCL31KcJxP7jehoM6IvS4knFbRqGcli9qistn73AWlPvrc6WkCDDJC3Y/s1600/IMG_5098a.jpg" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" hw="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj9xmWySNHJCy4Uh4VRp4eoiITPOIoRKZWyoCrblC4q32qxFWv36R0w1fSnQEPXnVdxTqjHrRrOtSosFuwPTWJKCL31KcJxP7jehoM6IvS4knFbRqGcli9qistn73AWlPvrc6WkCDDJC3Y/s320/IMG_5098a.jpg" /></a> Assembled Boarduino parked happily on the breadboard. Online assembly instructions for the module were fairly good, and would be able to be read and followed by a high school student with relative ease. Even before I first powered it, I've decided this module would make an EXCELLENT project for any tech-minded teen. Not only is the kit manageable, the module, when done, opens worlds of experiments for an inquisitive and creative mind. </div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhxTyEk6pOs7D0AKwqI6Vm0pm3gSOcda4-0ci2ArBVVC4dOBmxyAPtmK8q_OOUmq51XHCWcAhMCODV-GDRbBk5wsAEg7z5IuQoCf8WiQAbG_Mpm6-iucynWj_Lf9nYVmrmpoHKPs5BTZfs/s1600/IMG_5099a.jpg" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" hw="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhxTyEk6pOs7D0AKwqI6Vm0pm3gSOcda4-0ci2ArBVVC4dOBmxyAPtmK8q_OOUmq51XHCWcAhMCODV-GDRbBk5wsAEg7z5IuQoCf8WiQAbG_Mpm6-iucynWj_Lf9nYVmrmpoHKPs5BTZfs/s320/IMG_5099a.jpg" /></a>Boarduino module, along with assembled "Wulfden P4b" Serial-to-TTL communications board. This board allows for programming of and communication with the Boarduino via a home computer. Though useful as a computer interface, the module's real strength is that once programmed, the module only requires a battery to operate.. making it a totally portable, extremely low-power computing and control platform, perfect for small projects at low cost. Though small, this module is substantially more powerful a computer than several of the first home computers I owned.</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;"><br />
</div><div class="separator" style="clear: both; text-align: justify;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhOTfXNXG0Keb91geDwGW2_GHFEqS17LkVVVzbnGGgf5uTGT7_Hic-vqIDStMQJIiCgYQNB_53oVyO2ETWGrUe_s2pBAVREH1OQAld7TvEACyd-KxvkN_9xBfcqzusJ8tdX1hyphenhyphenC4N32nno/s1600/IMG_5100a.jpg" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" hw="true" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhOTfXNXG0Keb91geDwGW2_GHFEqS17LkVVVzbnGGgf5uTGT7_Hic-vqIDStMQJIiCgYQNB_53oVyO2ETWGrUe_s2pBAVREH1OQAld7TvEACyd-KxvkN_9xBfcqzusJ8tdX1hyphenhyphenC4N32nno/s320/IMG_5100a.jpg" /></a>Solder-pad/header side of the Adafruit Boarduino module and Wulfden P4b Serial-to-TTL interface. The total assembly time for the two boards was about two hours, including needing to desolder and resolder one component I installed incorrectly the first time. For the electronics folks, I can say I am very pleased with the pin header layout- the fact that the module is designed for breadboarding is really apparent, with all signals and connections readily available.</div><div class="separator" style="clear: both; text-align: center;"><br />
</div><div class="separator" style="clear: both; text-align: center;"><br />
</div><div class="separator" style="clear: both; text-align: center;"><br />
</div><div align="left" class="separator" style="clear: both; text-align: center;">So.. we have an assembled kit. What now? Stick around and see!</div>Focalisthttp://www.blogger.com/profile/13405215876083231936noreply@blogger.com0