tag:blogger.com,1999:blog-41648348942565100232024-03-19T01:51:51.719-07:005VMy adventure in electronics.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.comBlogger18125tag:blogger.com,1999:blog-4164834894256510023.post-70280734213853546702014-07-03T11:32:00.003-07:002014-09-09T05:57:23.775-07:00Installing STM32CubeMX on LinuxSTMicroelectronics has a nice little tool to plan out your pin mapping for their STM32 microcontrollers, called <a href="http://www.st.com/web/catalog/tools/FM147/CL1794/SC961/SS1743/PF259242?icmp=stm32cubemx_pron_pr-stm32cubef2_apr2014&sc=stm32cube-pr2">STM32CubeMX</a>, but unfortunately they packaged it in to an .exe file. I first tried running the exe under wine but I was greeted with a message that it requires Java. I know a lot of these installers are really just executable zip files so I just ran unzip on it.<br />
<blockquote class="tr_bq">
<span style="font-family: Courier New, Courier, monospace;">mkdir stm32cubemx<br />cd stm32cubemx<br />unzip ../SetupSTM32CubeMX-4.3.0.exe</span></blockquote>
<br />
Taking a look at "META-INF/MANIFEST.MF" you'll see it want's to run "com.izforge.izpack.installer.bootstrap.Installer" so I did that next.<br />
<blockquote class="tr_bq">
<span style="font-family: Courier New, Courier, monospace;">java -cp . com.izforge.izpack.installer.bootstrap.Installer</span></blockquote>
<br />
Looking at the install directory we find another exe. Lets unzip again. This time in place (zip bomb, but that's ok).<br />
<blockquote class="tr_bq">
<span style="font-family: Courier New, Courier, monospace;">cd <install location></span><br />
<span style="font-family: 'Courier New', Courier, monospace;">unzip STM32CubeMX.exe</span></blockquote>
<br />
Looking at "META-INF/MANIFEST.MF" we now see "com.st.microxplorer.maingui.IOConfigurator" so I ran that.<br />
<blockquote class="tr_bq">
<span style="font-family: Courier New, Courier, monospace;">java -cp . com.st.microxplorer.maingui.IOConfigurator</span></blockquote>
Seems to work just fine.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgBkNKRH6AlHrvCfeTcGB67yFTxemplSU0jdz-3kNIeWC7myGMXdCbdGpyNVQMIrcA5rgBCeXevn8C-yUeh_ovCFNM8cXptvLGen1pjSlUzJ6nS1Y9sCPk-4X6IzktzJ47T83eSQa56jHww/s1600/stm32cubemx-screenshot.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgBkNKRH6AlHrvCfeTcGB67yFTxemplSU0jdz-3kNIeWC7myGMXdCbdGpyNVQMIrcA5rgBCeXevn8C-yUeh_ovCFNM8cXptvLGen1pjSlUzJ6nS1Y9sCPk-4X6IzktzJ47T83eSQa56jHww/s1600/stm32cubemx-screenshot.jpg" height="240" width="320" /></a></div>
<br />
<br />Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com26tag:blogger.com,1999:blog-4164834894256510023.post-10039352551977082802014-07-03T11:20:00.002-07:002014-07-03T11:20:39.397-07:00Telepresence Robot Video<div class="separator" style="clear: both; text-align: center;">
<object width="320" height="266" 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="https://ytimg.googleusercontent.com/vi/nxQw_-PgoPo/0.jpg"><param name="movie" value="https://youtube.googleapis.com/v/nxQw_-PgoPo&source=uds" /><param name="bgcolor" value="#FFFFFF" /><param name="allowFullScreen" value="true" /><embed width="320" height="266" src="https://youtube.googleapis.com/v/nxQw_-PgoPo&source=uds" type="application/x-shockwave-flash" allowfullscreen="true"></embed></object></div>
<br />
<span style="background-color: white; color: #333333; font-family: arial, sans-serif; font-size: 13px; line-height: 17px;">After seeing a commercial for a Telepresence robot on TV, I knew I wanted to play with one, but after looking at prices I didn't want to pay for one.</span><br style="background-color: white; color: #333333; font-family: arial, sans-serif; font-size: 13px; line-height: 17px;" /><br style="background-color: white; color: #333333; font-family: arial, sans-serif; font-size: 13px; line-height: 17px;" /><span style="background-color: white; color: #333333; font-family: arial, sans-serif; font-size: 13px; line-height: 17px;">I used an Android Nexus 7 tablet for the video conferencing. A custom PCB with an STM32 ARM processor and an FTDI USB chip to connect the Android tablet with the motors.</span><br style="background-color: white; color: #333333; font-family: arial, sans-serif; font-size: 13px; line-height: 17px;" /><br style="background-color: white; color: #333333; font-family: arial, sans-serif; font-size: 13px; line-height: 17px;" /><span style="background-color: white; color: #333333; font-family: arial, sans-serif; font-size: 13px; line-height: 17px;">All the code and design files can be found here: </span><a href="https://github.com/joeferner/telepresenceRobot">Telepresence Robot GitHub Repo</a><br />
<br />Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com0tag:blogger.com,1999:blog-4164834894256510023.post-11442881328502198142011-04-08T15:11:00.000-07:002011-04-08T15:11:06.819-07:00First Run of my Air MotorUsing two air solenoids and an ATmega328 I was able to get my air motor up and running. The timing was a little touchy but I got it to work. This project is based off of one I saw over at Nuts and Volts. Next up, tuning the motor to get maximum efficiency. I also want to rewrite the algorithm to take target RPMs and calculate the necessary timing to get there.<br />
<br />
<iframe width="480" height="295" src="http://www.youtube.com/embed/rV2_pbWvqqg?fs=1" frameborder="0" allowFullScreen=""></iframe><br />
<br />
As always the code can be found in google code.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com0tag:blogger.com,1999:blog-4164834894256510023.post-5928937189641045382011-01-30T20:43:00.000-08:002011-01-31T08:21:34.167-08:00Hacking a Scale to Add ZigBee GoodnessMy idea is to take this scale<br />
<a href="http://goo.gl/photos/STRsbKfeNP" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh6.ggpht.com/_rcMJMTIkw6I/TPenwYflQiI/AAAAAAAADgs/acMPjJXP3BM/s512/IMG_2909.JPG"></a><br />
and add ZigBee wireless so that I can automatically capture my weight on my computer without having to remember it.<br />
<br />
OK lets backup. Why did I choose the scale above? The first reason I chose this scale is because it has an LED display. I knew this would make the task of hacking much easier because the chances would be good that the display would be 4 - 7 segment displays that I could easily read. The second reason is (after opening the box in the aisle at Target) it looked easy to disassemble, just a couple of screws holding the back on. The third reason, it was cheap, I didn't want to waste a bunch of money on something I could easily break in the process. Finally it needed to have room for the electronics so I found a scale that wasn't glass or super thin. By the way its a Taylor model 9856 if you care.<br />
<br />
On to the hacking...<br />
<br />
After popping off the back (yes it really was just a couple of screws) I saw the following...<br />
<a href="http://goo.gl/photos/90KgJESTUa" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh6.ggpht.com/_rcMJMTIkw6I/TPenyGWGL2I/AAAAAAAADhE/r2X5DtOIAIY/s512/IMG_2916.JPG"></a><br />
<br />
Flipping up the LED I saw this...<br />
<a href="http://goo.gl/photos/gG25iXwChf" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh3.ggpht.com/_rcMJMTIkw6I/TUYyydZzicI/AAAAAAAAD7E/9tzelU_hp5g/s512/IMG_2921_chips.jpg"></a><br />
<br />
It was almost too easy, the chips were clearly marked and the board didn't have much mystery at all except for the black epoxied MCU on the right. But, I didn't need that. I had everything I needed exposed right where I could get at it. I had two options: tap into the EEPROM or read the LEDs. I chose the later. Why? Well, after scoping the EEPROM I couldn't make heads or tails out of what was being sent, on the other hand scoping the HC164 and the four transistors it made complete sense.<br />
<br />
Basically here is how it works. Each of the four transistors drives one digit of the LED (actually they enable the LED by switching the cathode or ground side). The HC164 receives the 7 bits that make up the digit along with 1 bit for the decimal point (see <a href="http://en.wikipedia.org/wiki/Seven-segment_display">Seven Segment Display</a>). So the process goes like this: all four transistors are turned off. The HC164 is loaded with the data for digit 1. The first transistor is then turned on for 3.5ms. It is then turned off and the next digit is shown. Over and over again. Because this is all happening in roughly 20ms per refresh it looks to our eyes that all digits are lit at the same time (<a href="http://en.wikipedia.org/wiki/Persistence_of_vision">persistence of vision</a>).<br />
<br />
So how do we know when it has the final weight? The scale I have displays a little night rider effect. "o" in the first spot, followed by "o" in the second, then third, then forth, and repeat for 3 iterations. In the firmware as soon as I see an "o" in any spot I take the last good decimal reading and send that over my ZigBee network.<br />
<br />
Here is a shot of my prototype. I'm using an <a href="http://www.atmel.com/dyn/products/product_card.asp?PN=ATmega328P">ATmega 328P</a> (same chip used in the Arduino) to read the signals.<br />
<a href="http://goo.gl/photos/w5XImbeZBL" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh3.ggpht.com/_rcMJMTIkw6I/TPen0wioNxI/AAAAAAAADho/1vuap0l9bNw/s512/IMG_2924.JPG"></a><br />
<br />
Here is the schematic of whats happening...<br />
<a href="http://goo.gl/photos/V88yfWV9Bl" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh4.ggpht.com/_rcMJMTIkw6I/TUY6i1DKj6I/AAAAAAAAD7c/DwUJNCHJifs/s512/schematic.png"></a><br />
<br />
I wanted to fit everything back into the scale so I didn't have any external components so I needed to design a circuit board that would fit into the very cramped case. This is what I ended up with...<br />
<a href="http://goo.gl/photos/SvF8a5nHAZ" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh4.ggpht.com/_rcMJMTIkw6I/TUY3_EGJZ8I/AAAAAAAAD7U/IEJIFebQmN0/s512/circuit_board.png"></a><br />
<br />
Finally a photo with everything in place...<br />
<a href="http://goo.gl/photos/YghdRExc5t" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh5.ggpht.com/_rcMJMTIkw6I/TUTW8EzclUI/AAAAAAAAD5o/BUBs4DKCpgQ/s512/IMG_2947.JPG"></a><br />
<br />
So where do all these readings go? My computer of course. I have a ZigBee coordinator to USB adapter on my computer. I wrote a simple windows service that listens for the ZigBee traffic and if it receives a new weight it stores it in a MSSQL database. It also handles multiple users by looking at the previous weights of each user and picks the closest match. To display the data I wrote a .NET MVC web site to display pretty graphs and such, but that was trivial compared with the rest.<br />
<br />
Schematics, Firmware, Web Site, etc. can be found <a href="http://code.google.com/p/fivevolt/source/browse/#hg%2FWirelessScale">here</a>Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com12tag:blogger.com,1999:blog-4164834894256510023.post-75340471614731952112010-11-03T19:14:00.000-07:002010-11-03T19:18:49.699-07:00Enabling 32MHz Operation on the AVR XMEGA<style type="text/css">
.csharpcode, .csharpcode pre
{
font-size: small;
color: black;
font-family: Consolas, "Courier New", Courier, Monospace;
background-color: #ffffff;
/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt
{
background-color: #f4f4f4;
width: 100%;
margin: 0em;
}
.csharpcode .lnum { color: #606060; }
</style><br />
I received an <a href="http://www.sparkfun.com/commerce/product_info.php?products_id=9546">AVR XMega100 Breakout</a> from SparkFun in the mail yesterday and I've started doing some experimenting with it. The first problem I ran across was getting into 32MHz clock mode. The XMegas have a internal oscillator but by default they are set to 2MHz operation. What's kind of neat about the XMegas though is that you can switch the speed at runtime. What tripped me up was the fact that the registers that control the oscillator and clock are both protected registers. I'm not really sure what the benefit of this is but in any case here is the code to enter 32MHz mode.<br />
<br />
<pre class="csharpcode"><span class="kwrd">void</span> setClockTo32MHz() {
CCP = CCP_IOREG_gc; <span class="rem">// disable register security for oscillator update</span>
OSC.CTRL = OSC_RC32MEN_bm; <span class="rem">// enable 32MHz oscillator</span>
<span class="kwrd">while</span>(!(OSC.STATUS & OSC_RC32MRDY_bm)); <span class="rem">// wait for oscillator to be ready</span>
CCP = CCP_IOREG_gc; <span class="rem">// disable register security for clock update</span>
CLK.CTRL = CLK_SCLKSEL_RC32M_gc; <span class="rem">// switch to 32MHz clock</span>
}</pre><br />
A couple things to note. Check that you set the clock speed (F_CPU) in your compile to 32000000. And since the clock can be modified at runtime, anything that relies on the F_CPU constant may be effected, this includes the build in delay functions. For what I'm doing I'm not concerned with switching back and forth but some low power applications may find that useful.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com2tag:blogger.com,1999:blog-4164834894256510023.post-48417773562765645332010-09-08T19:22:00.000-07:002010-09-08T19:37:04.333-07:00Populated PCB<a href="http://goo.gl/photos/1yHz" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh3.ggpht.com/_rcMJMTIkw6I/TIhDoqiwZPI/AAAAAAAADKc/95cRGFgKkhk/s512/P1000289.JPG"></a><br />
<br />
Soldering is all done. I tested the board and everything seems to work well. I did discover a little mechanical errors with my board, the ICSP header and IMU are a little too close, and I have to remove the IMU to use the ICSP. Overall I'm quite happy how things turned out. The final board weighs in at 50g.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com1tag:blogger.com,1999:blog-4164834894256510023.post-63584597737731266822010-09-04T07:00:00.000-07:002010-09-04T07:04:37.353-07:00PCBs Arrived<a href="http://goo.gl/photos/hgtd" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh4.ggpht.com/_rcMJMTIkw6I/TIF_9kkAm2I/AAAAAAAADJI/G--ZuYdWvMw/s512/P1000285.JPG"></a><br />
<br />
After patiently waiting 3 weeks, I finally received my PCBs from <a href="http://batchpcb.com">BatchPCB</a>. These are the first PCBs I have ever sent out to be manufactured. Pricing models, gerber files, board thickness, etc. have always seemed so intimidating but, BatchPCB and a <a href="http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=115">tutorial at SparkFun</a> made the process easy. With shipping, it came out to be less than $50. I just hope it works.<br />
<br />
If you noticed in the photo above I received two PCBs but I only ordered one. I've heard this happening with BatchPCB. I'm not really sure if it's an artifact of how they build their panels but I'm not complaining.<br />
<br />
Now I'm off to a fun night of soldering all the parts. The board has three ATmega328 that are in TQFP32 packages and since I have never soldered anything with a pitch that small it should be interesting. After watching numerous surface mount soldering tutorials on YouTube it doesn't look to be all that hard.<br />
<br />
Here are some more pictures of the board...<br />
<br />
Front<br />
<a href="http://goo.gl/photos/MIGd" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh3.ggpht.com/_rcMJMTIkw6I/TIF_-P51KfI/AAAAAAAADJM/j-_scKTIkdU/s512/P1000286.JPG"></a><br />
<br />
<br />
Back<br />
<a href="http://goo.gl/photos/4vXu" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh4.ggpht.com/_rcMJMTIkw6I/TIF_-TmRbDI/AAAAAAAADJQ/B4cttAkUx60/s512/P1000287.JPG"></a>Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com2tag:blogger.com,1999:blog-4164834894256510023.post-81512897460402729802010-09-01T06:31:00.000-07:002010-09-04T06:38:47.419-07:00Rigol DS1052E Oscilloscope<a href="http://goo.gl/photos/wilR" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh6.ggpht.com/_rcMJMTIkw6I/TIF_-30NPfI/AAAAAAAADJU/Xj0aP2X2Jb0/s512/P1000288.JPG"></a><br />
<br />
New equipment! I received my Rigol DS1052E oscilloscope today. I choose this oscilloscope based on the glowing reviews by Dave over at the <a href="http://www.eevblog.com/">EEVblog</a>. After I play with it for a while I'll need to post my own review.<br />
<br />
I bought it from <a href="http://www.amazon.com/Rigol-DS1052E-50MHz-Digital-Oscilloscope/dp/B001P63VOA/ref=sr_1_1?ie=UTF8&s=hi&qid=1283607418&sr=8-1">Amazon</a> because I had a bunch of Amazon gift certificates, but you can find elsewhere.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com0tag:blogger.com,1999:blog-4164834894256510023.post-57474556907867690032010-08-28T06:12:00.000-07:002010-09-04T07:02:33.938-07:00Using a Complementary Filter to Combat VibrationThis is the data I received from the <a href="http://www.sparkfun.com/commerce/product_info.php?products_id=10010">IMU</a> along the y-axis (pitch). Accelerometer data is in radians and the gyro data is in radians per second. The data points from 0 to 41 are before the motors turned on. 41-89 is the quad tilting left. 89-129 is the quad tilting right. 129- is the quad tilting to the left again.<br />
<br />
<a href="http://picasaweb.google.com/lh/photo/_oBurFh7rp6Uj-dgHdFgIFCsQtB09CrGlr9TLRZKWkQ?feat=embedwebsite"><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgOJ56NL0RsbghC1MUXSXrapxjJjPotLe3HM6yNEEnBMHPWgw1NoHxhCce_o5SnPnoRB_fFE0ybreY53pvyXsocNHZFychoNYOuWW9bPWuX2DlLTXrpI4mnf1yTmQv0SofazM0KA0__ObAo/s400/before_filter.jpg" /></a><br />
<br />
As you can see the accelerometer data is quite noisy. I tried dampening the vibration using foam underneath the circuit board, but that didn't help much. Looking at the gyro data it is quite smooth in comparison.<br />
<br />
So I looked into using filters that combine the accelerometer data with the gyro data. Using the code for a <a href="http://www.rcgroups.com/forums/showpost.php?p=12082524&postcount=1286">Complementary Filter</a> (thanks to RoyLB). I was able to produce the following results.<br />
<br />
<a href="http://picasaweb.google.com/lh/photo/pzhoQK3xrU4xL2Rq9ivTZ1CsQtB09CrGlr9TLRZKWkQ?feat=embedwebsite"><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgjTIJpVvOl6yMhRa6-3UvRs1Hnfh-ZJCZUgEsWJ21t5fNeclszRQDlBXLJ6ZhyphenhyphenXFZ3Xst8YGbr5gm43xhUnVsoCaL3652TAF-1whI4WTXCV-tqrOxjgGjJ-fJfzRoHS7uf_DPZb-LaCfXr/s400/after_filter.jpg" /></a>Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com1tag:blogger.com,1999:blog-4164834894256510023.post-81410458796615937962010-08-22T17:45:00.000-07:002010-08-22T17:45:47.452-07:00First Balance Test<object width="640" height="385"><param name="movie" value="http://www.youtube.com/v/68S4V44dmiQ?fs=1&hl=en_US"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/68S4V44dmiQ?fs=1&hl=en_US" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="640" height="385"></embed></object><br />
<br />
I adjusted the support rig to hold the quadcopter at the left and right arms allowing it to pivot in only one axis. Above is a video after spending 3-4 hours tweaking the code and adjusting the <a href="http://en.wikipedia.org/wiki/PID_controller">PIDs</a> (I'm still out one motor and I disabled the other motor for testing). It seems to start the balance quite well but begins to destabilized. After some debugging it looks like the receiver chip is receiving some bad signals. Sometime this week I'm going to debug the receiver code to figure out what's happening. I may also try to remove the receiver code for now to see if I can get a stable balance.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com0tag:blogger.com,1999:blog-4164834894256510023.post-46610989178807613362010-08-22T17:36:00.000-07:002010-08-22T17:36:15.776-07:00Puff!!! There Goes A Motor.During a firmware upgrade one of the motors started making a very strange noise. After 3-4 seconds a puff of smoke, the motor was dead. Still not sure what happened. Unfortunately that means ordering another one from <a href="http://www.hobbycity.com/">Hobby City</a> which has the best price but takes at least a week to get here.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com2tag:blogger.com,1999:blog-4164834894256510023.post-14574687372436044642010-08-15T17:32:00.000-07:002010-08-16T17:58:22.577-07:00First Take-Off<object height="385" width="640"><param name="movie" value="http://www.youtube.com/v/qmmIEoDAg-E?fs=1&hl=en_US"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/qmmIEoDAg-E?fs=1&hl=en_US" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="640" height="385"></embed></object><br /><br />I managed to have a clean take-off and landing. I don't have any of the sensor data mixed in yet just the R/C receiver throttle. I have the quadcopter held down using zip ties. Next step, new rig to get higher and more control over the flight.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com0tag:blogger.com,1999:blog-4164834894256510023.post-67695179994651319362010-08-15T17:15:00.000-07:002010-08-16T17:57:16.693-07:00Circuit Physical Layout<a href="http://goo.gl/photos/qC91" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh4.ggpht.com/_rcMJMTIkw6I/TGgnhms9JwI/AAAAAAAADCo/9jJN5T1h27E/s512/P1000231.JPG"></a><br /><br />Before I sent the PCB off to <a href='http://www.batchpcb'>BatchPCB</a> I wanted to make sure the physical layout would work. I printed a 1:1 version of the circuit and took a piece of foam and tried out the parts. Good thing I checked because I had an overlap between a couple of the components. My circuit also has expansion ports for GPS, general IO and other TWI components.<br /><br /><a href='http://www.batchpcb.com/product_info.php?products_id=40184&check=ad6371a96574a32d78958d920a8c9213'>My ciruit on BatchPCB</a>Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com0tag:blogger.com,1999:blog-4164834894256510023.post-61865231050174960852010-08-15T17:11:00.000-07:002010-08-16T17:55:54.544-07:00Quadcopter Eats Some Propellers<a href="http://goo.gl/photos/pc33" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh5.ggpht.com/_rcMJMTIkw6I/TGgnhP_I1LI/AAAAAAAADCo/eSV-wZdnVRU/s512/P1000230.JPG"></a><br /><br />My quad ate it's first propellers. During my first hover I guess things weren't secured as well as they should have been and the propellers and speed controllers had a collision.<br /><br />Here is what I think happened: I had the speed controllers taped to the board and the quad took-off and ripped the tape up. Then I landed and the speed controllers went up into the props. Thankfully the speed controllers came out with only a couple of gashes.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com1tag:blogger.com,1999:blog-4164834894256510023.post-44988210692217233182010-08-15T17:06:00.000-07:002010-08-16T17:53:56.908-07:00Quadcopter Circuit<a href="http://goo.gl/photos/idyr" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh5.ggpht.com/_rcMJMTIkw6I/TGgngX5LT6I/AAAAAAAADCo/1kswKjlDJl8/s512/P1000228.JPG"></a><br /><br />I'm using 3 ATmega328P processors for the prototype circuitry. The first is used to communicate with the R/C receiver and filter the results. The second is used to communicate and process the sensor data from the accelerometers, gyros, and compass. Those talk to the main processor over TWI which combines the receiver and sensor data to control the motors. The main processor also sends out telemetry data using an XBee serial connection as well as monitor the battery voltage.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com3tag:blogger.com,1999:blog-4164834894256510023.post-46353255945605636792010-08-15T16:48:00.000-07:002010-08-16T17:51:30.906-07:00Quadcopter Prototype<a href="http://goo.gl/photos/wp3b" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh3.ggpht.com/_rcMJMTIkw6I/TGgnfIdWsqI/AAAAAAAADCo/7Fpv7tVlMpI/s512/P1000224.JPG" /></a><br /><br />My first project is a quadcopter (prototype pictured). The frame is made from 3/4" aluminum square tube. The proto breadboard in the center has the accelerometers and gyros (<a href="http://www.sparkfun.com/commerce/product_info.php?products_id=10010">IMU 6DOF Razor</a>), the Magnetometer (<a href="http://www.sparkfun.com/commerce/product_info.php?products_id=9371">HMC5843</a>), and breakouts for the 4 speed controllers (<a href="http://www.hobbycity.com/hobbyking/store/uh_viewItem.asp?idProduct=2164">TURNIGY Plush 30amp Speed Controller</a>). The four motors are <a href="http://www.hobbycity.com/hobbyking/store/uh_viewItem.asp?idProduct=5690">Turnigy 2217 16turn 1050kv 23A Outrunners</a> with APC <a href="http://www.apcprop.com/ProductDetails.asp?ProductCode=LP12038SF">12x3.8 standard</a> and <a href="http://www.apcprop.com/ProductDetails.asp?ProductCode=LP12038SFP">12x3.8 pusher</a> props. Not connected in the photo is the <a href="http://www.hobbycity.com/hobbyking/store/uh_viewItem.asp?idProduct=7634">ZIPPY Flightmax 4000mAh 3S1P 20C</a> battery.<br /><br /><a href="http://goo.gl/photos/qchL" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh4.ggpht.com/_rcMJMTIkw6I/TGgnfgEFCfI/AAAAAAAADCo/c-uAbLAv6Do/s512/P1000225.JPG"></a><br /><br />Here's a closeup of the power distribution. I'm still working out options that are lighter but for now this should work for prototyping. With each motor pulling up to 20Amps times 4 for a total of 80Amps I needed some pretty beefy power distribution. The wire is <a href='http://www.hobbycity.com/hobbyking/store/uh_viewItem.asp?idProduct=9674'>Turnigy 12AWG</a> which has very high braid count for more amperage capacity. I used a terminal block (available at Home Depot) and <a href='http://www.lowes.com/pd_136093-12704-770300_4294821936_4294937087?productId=3127725&pl=1¤tURL=/pl_Wiring%2BDevices%2B_4294821936_4294937087_?rpp=30$No=210'>terminal wire connectors</a>.<br /><br /><a href="http://goo.gl/photos/kh4W" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh6.ggpht.com/_rcMJMTIkw6I/TGgnf6ZqaEI/AAAAAAAADCo/3SLJkENm87U/s512/P1000226.JPG"></a>Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com6tag:blogger.com,1999:blog-4164834894256510023.post-29473599433209854082010-08-15T16:38:00.000-07:002010-08-16T17:48:48.759-07:00ATX Power Supply Conversion<a href="http://goo.gl/photos/H04v" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh3.ggpht.com/_rcMJMTIkw6I/TGgne2t79iI/AAAAAAAADCo/FqnURj580Rk/s512/P1000223.JPG"></a><br /><br />I had a bunch of old ATX power supplies laying around, so I decided to convert one into a bench power supply until I could find one. The on/off switch on the right is hooked up to the green wire and black wire of the 20pin connector. I also brought out a hand full of grounds (black banana plugs), as well as +12V, +5V, and +3.3V. It's kind of hard to see in the photo but I also added a small LED to the left of the switch to indicate power status.Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com2tag:blogger.com,1999:blog-4164834894256510023.post-35342498311662892032010-08-15T10:47:00.000-07:002010-08-16T17:47:53.101-07:00Welcome to 5Volt BlogWelcome! I'm starting this blog to document my electronics hobby. Ever since my son Ian was born I've had to put my other hobby, woodworking, on hold. I decided to get back into electronics, a hobby of mine since I was young, which is much quieter.<br /><br /><a href="http://goo.gl/photos/fEdD" imageanchor="1" style="clear:right;margin-bottom:1em;margin-left:1em"><img border="0" src="http://lh4.ggpht.com/_rcMJMTIkw6I/TGgneFl7o6I/AAAAAAAADCo/uNrQ-2MXMhY/s512/P1000221.JPG" /></a><br /><br />One half of our unfinished basement is reserved for my woodshop. I decided to take over the other half of the basement for electronics, and repurposed some old storage furniture for a work space. Above is a picture of my electronics workbench. Since most of the projects I have planned require quite a bit of firmware I've set up a computer on the left. On the top shelf are various components. On the middle shelf I have my old Radio Shack multimeter, a converted computer power supply, an Aoyue 2900 Soldering Station, a PanaVise 350 Work Center. On the bottom I have various hookup wires and tools. Off to the right I have more storage.<br /><br />If it weren't for all the unused baby stuff lying around, my basement would be my version of a perfect "man cave."Joehttp://www.blogger.com/profile/01925206161623391235noreply@blogger.com0