tag:blogger.com,1999:blog-73770574124462647202024-03-13T18:18:52.763-04:00Antipasto Hardware Blog<b>Hacking, Engineering, and Tech at <a href="http://www.liquidware.com">Liquidware</a></b>Unknownnoreply@blogger.comBlogger390125tag:blogger.com,1999:blog-7377057412446264720.post-32668463817318612182012-10-09T11:28:00.004-04:002012-10-09T11:28:57.832-04:00Maker Faire NY Re-cap<span style="font-family: inherit;"><i>It’s been a week since Justin, Mike Rith and I drove down to New York for Maker Faire. Mike and Justin had both tried to explain the nature of the beast that is Maker Faire, but it was clearly something that I had to experience for myself. Note to self: driving to New York City and getting there just as Friday night rush-hour traffic is beginning is a special breed of torture I wouldn't wish upon anyone</i>.</span><br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-36sDepFGEGs/UHQ_ZaG-5gI/AAAAAAAAADQ/xyu_VDkvus4/s1600/NYHSCI.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="239" src="http://2.bp.blogspot.com/-36sDepFGEGs/UHQ_ZaG-5gI/AAAAAAAAADQ/xyu_VDkvus4/s320/NYHSCI.jpg" width="320" /></a></div>
<br />
<span style="font-family: inherit;">My first glimpse of the New York Hall of Science where Maker Faire was held, was one filled with the bright blue, red and white Maker Faire signs, lines of excited Makers and visitors alike. On my way in, I chatted with a Maker about her most recent knitting project--a 7 foot by 3 foot shawl for her daughter's upcoming wedding that was going to be held practically right next door! </span><br />
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;">We brought down a variety of demos including a <a href="http://www.liquidware.com/shop/show/TSL/TouchShield+Slide">TouchShield Slide</a> with the <a href="http://antipastohw.blogspot.com/2009/02/paint-program-for-my-slide.html">Paint Program</a> installed, an <a href="http://www.liquidware.com/shop/show/BB-AND-DIY/Android+DIY+Starter+Kit+">Android DIY Starter Kit</a>, a <a href="http://antipastohw.blogspot.com/2012/08/introducing-dual-core-android-4-dev-kit.html">Dual-core Android 4 Dev Kit</a>, and a couple of <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Ambers</a>. Miguel from Long Island dropped by and brought an impressive project where he created a <a href="http://www.instructables.com/id/Arduino-Mancala-Game-Using-a-TouchShield-Slide/">Mancala app using a TouchShield Slide</a>, Lithium Backpack and an Arduino.</span><br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-YP3hHQWEBzg/UHRAoEJTCfI/AAAAAAAAADg/ZHp-gDl4lqg/s1600/2012-09-30+14.58.10.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="400" src="http://1.bp.blogspot.com/-YP3hHQWEBzg/UHRAoEJTCfI/AAAAAAAAADg/ZHp-gDl4lqg/s400/2012-09-30+14.58.10.jpg" width="238" /></a></div>
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;">After a quick set up, I found myself ready for action. By 10:15, The Arduino Pavilion was teeming with people. It was great to get a chance to interact with such a wide range of people--from those who'd never heard of Arduinos to 11-year olds grilling me on the merits and processing capabilities of one microcontroller over the other. Finding a way to communicate the same concepts to a range of people with different levels understanding was both challenging and rewarding. </span><br />
<span style="font-family: inherit;"><br /></span>
<div align="center">
<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="http://1.bp.blogspot.com/-rqaz5Dw4z4Y/UHRAJLBkjYI/AAAAAAAAADY/M8k7I-OVslQ/s1600/photo.JPG" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img border="0" height="476" src="http://1.bp.blogspot.com/-rqaz5Dw4z4Y/UHRAJLBkjYI/AAAAAAAAADY/M8k7I-OVslQ/s640/photo.JPG" width="640" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;"><em><span style="font-size: small;">Mike chatted with Will from <a href="http://www.tested.com/videos/449241-world-maker-faire-2012-beagleboard-computing-platform/">tested.com</a> about the Amber</span></em></td></tr>
</tbody></table>
</div>
<span style="font-family: inherit;">I had a lot of interesting, thought-provoking conversations with people from all over. I got the chance to speak with a few of developers from Germany, a couple from Washington looking to deaf-proof their house with Arduinos and TouchShields, and a whole host of people with a wide variety of interests. </span><br />
<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="http://lh3.ggpht.com/-BWVeaW0Wn2w/UHQ7a7z_cKI/AAAAAAAAACI/7a45858OXBc/s1600-h/clip_image006%25255B2%25255D.jpg" style="margin-left: auto; margin-right: auto;"><img alt="clip_image006" border="0" height="316" src="http://lh4.ggpht.com/-KdAMxjDEioU/UHQ7bv35hYI/AAAAAAAAACQ/6BtiTL6qQTY/clip_image006_thumb%25255B1%25255D.jpg?imgmax=800" style="background-image: none; border: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="clip_image006" width="419" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;"><span style="font-size: small;"><em style="font-family: inherit;">Those same kids went nuts once they found out that we had </em><a href="http://www.youtube.com/watch?v=c5e9K7uGB08&feature=g-user-u" style="font-family: inherit;"><em>installed the Angry Birds APK</em></a><em style="font-family: inherit;"> to one of the units</em></span></td></tr>
</tbody></table>
<span style="font-family: inherit;">It was also great to see so many kids at our booth asking questions about our products, and technology in general. For the most part, they interacted with it fearlessly--with a comfort and familiarity that makes me excited for future technological innovations. <span style="font-size: x-small;"></span></span><br />
<div style="text-align: center;">
<br /></div>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-ijlabII5T-s/UHRBHYZfy4I/AAAAAAAAADo/N1XWCAdGyIo/s1600/IMG_0377.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="http://1.bp.blogspot.com/-ijlabII5T-s/UHRBHYZfy4I/AAAAAAAAADo/N1XWCAdGyIo/s640/IMG_0377.JPG" width="640" /></a></div>
<span style="font-family: inherit;"> </span><br />
<span style="font-family: inherit;">Rith, Mike and Justin had things under control, so I snapped a couple of pictures, and snuck away to check out some neat projects </span><br />
<table 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;"><img alt="2012-09-29 13.12.26" border="0" height="640" src="http://lh4.ggpht.com/-tG6t6k39myw/UHQ7eLkbMNI/AAAAAAAAACw/4rlNyag8Q_E/2012-09-29%25252013.12.26_thumb%25255B7%25255D.jpg?imgmax=800" style="background-image: none; border: 0px; display: block; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="2012-09-29 13.12.26" width="355" /></td></tr>
<tr><td class="tr-caption" style="text-align: center;"><span style="font-size: small;"><a href="http://makerfaire.com/pub/e/9136"><em>Katy Perry, The Unicorn</em></a><em> was the first project I saw as we came in to setup, so I had to go back and get a quick shot of it. Missed out on the glitter sneezes though!</em></span></td></tr>
</tbody></table>
<a href="http://lh4.ggpht.com/-nLnIb2w50-Y/UHQ7dWEeOSI/AAAAAAAAACo/_LA5OYLBdJc/s1600-h/2012-09-29%25252013.12.26%25255B13%25255D.jpg"><span style="font-family: inherit;"></span></a><br />
<div style="text-align: center;">
<br /></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="http://1.bp.blogspot.com/-bMLofBhSn0s/UHRBh8DtQ9I/AAAAAAAAADw/tmDsUMDKD6g/s1600/photo(3).JPG" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img border="0" height="640" src="http://1.bp.blogspot.com/-bMLofBhSn0s/UHRBh8DtQ9I/AAAAAAAAADw/tmDsUMDKD6g/s640/photo(3).JPG" width="478" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;"><em><span style="font-family: inherit; font-size: small;">I imagine this project looked really cool by the end of the day on Sunday.</span></em></td></tr>
</tbody></table>
<span style="font-family: inherit;">After about 17 hours of non-stop Maker Faire activity, I was ready to pack it up, and head back to Boston. I tip my hat to the <a href="http://makezineblog.files.wordpress.com/2012/09/worldmakerfaireny2012crew-fb1.jpg?w=598&h=898">Maker Faire crew</a> for such a well-organized and special event. While my feet are still recovering, I can't wait for May 2013 to get a chance to get to do it all over again in California!</span><br />
<br />Anonymousnoreply@blogger.com1tag:blogger.com,1999:blog-7377057412446264720.post-73828652048178274162012-09-20T14:56:00.002-04:002012-09-20T14:56:46.340-04:00Getting Ready for Maker Faire NY!<em>Call me strange, but I’m a big fan of planning and logistics, so I’m pumped
that everything is set for our trip to </em><a href="http://makerfaire.com/newyork/2012/index.html"><em>Maker Faire
NY</em></a><em> next week!</em><br />
<em><br /></em>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-z5dP6syt0Ww/UFtQrCKn2II/AAAAAAAAAA0/5DCNYogy1VA/s1600/MFNYC12_round_logo.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="198" src="http://3.bp.blogspot.com/-z5dP6syt0Ww/UFtQrCKn2II/AAAAAAAAAA0/5DCNYogy1VA/s200/MFNYC12_round_logo.jpg" width="200" /></a></div>
<em><br /></em>
<em><br /></em>
<br />
We’re only 8 days, 20 hours, 35 minutes and 12, no 8 seconds away from Maker
Faire New York 2012. This will be my first Maker Faire, so I’m really excited to
head down and see what projects people have been working on. I’ve read through
the <a href="http://makerfaire.com/newyork/2012/makerinfo/index.html">list of
Makers</a> and can’t wait to sneak away to check out their projects.<br />
<br />
I’m heading down with Mike, Justin and Rith, who have all been to several
Maker Faires in the past and had great times. We’ll be bringing down our
<a href="http://antipastohw.blogspot.com/2012/08/how-to-build-diy-perpetually-powered.html">Digital
Rooster</a> project and a couple of other gadgets for people to check out, so
come find us in the Arduino Pavilion!Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-47713966371819466832012-09-04T20:27:00.001-04:002012-09-17T09:50:27.016-04:00How to connect a cellular modem on your Android and BeagleBoard on boot up<em>Last week, I wrote a tutorial about how to get a <a href="http://antipastohw.blogspot.com/2012/05/how-to-install-3g4g-cellular-modem-on.html">3G/4G cellular modem working on my Android/BeagleBoard</a> setup. The next question (after everything works) is, how can I get this running automatically every time I boot up my Android device?</em><br />
<em><br /></em>
<a href="http://www.liquidware.com/category/Android"><img alt="image" border="0" height="411" src="http://lh5.ggpht.com/-JsogvvtP4kQ/UEacca7pN3I/AAAAAAAAB4I/IoeqDQsBUoo/image%25255B6%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
Boot scripts are nothing too fancy, and anyone with some basic Linux or <a href="http://www.liquidware.com/shop/show/BB-AND-DEV/Android+Hardware+Development+Kit">Android</a> experience can navigate this process pretty easily. But I always find it helpful to have the actual scripts written out. As a beginner, it’s a great way to figure out what the commands actually mean, and as an advanced developer, it’s a huge timesaver to copy and paste what’s already been done.<br />
<br />
As a quick recap, I'm running all of this off my <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard xM</a>, <a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">BeagleTouch</a>, and <a href="http://www.liquidware.com/shop/show/BB-AND-AMB/Android+Ambrosia+SD+Card">Android Ambrosia SD card/image</a>. I decided to use a T-Mobile 4G Rocket 3.0 USB cellular modem, but any USB cellular modem <i>should </i>work, with some tweaks to the vendor/product ID as well as the chat script (more on that in the <a href="http://antipastohw.blogspot.com/2012/05/how-to-install-3g4g-cellular-modem-on.html">previous post</a>).<br />
<br />
<strong>Outline the process</strong><br />
<strong><br /></strong>
Looking through the original 3G/4G cellular modem integration process, I needed to do 4 things:<br />
<br />
1) Get <a href="http://www.draisberghof.de/usb_modeswitch/usb_modeswitch-1.1.9-arm-static.bz2">usb_modeswitch</a> and <a href="http://www.liquidware.com/system/0000/5711/usbserial.ko">usbserial.ko</a> onto your Android setup<br />
<br />
2) Execute usb_modeswitch using the correct usb_modeswitch.conf config file<br />
<br />
3) Once modeswitch was successful, install usbserial.ko module to the correct vendor and product ID for the device<br />
<br />
4) Execute chat script using pppd command <br />
<strong><br /></strong>
<strong>Wrap up relevant components into a script</strong><br />
<br />
I created a file called init_cellular_pppd.sh, which contains the relevant content and commands to create the usb_modeswitch.conf file as well as the dialtest.chat script.<br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;">#!/system/bin/sh<br />#This is a wrapper script to enable cellular wireless<br />TAG="Cellular"</span><br />
<span style="font-size: xx-small;">#<br /># echo usb modeswitch config<br />#<br />echo_modeswitch_conf_zte() {<br />echo "$TAG building modeswitch config"<br />cat > /system/etc/usb_modeswitch.conf << EOF<br /><br />########################################################<br /># ZTE devices</span><br />
<span style="font-size: xx-small;">DefaultVendor= 0x19d2</span><br />
<span style="font-size: xx-small;">DefaultProduct= 0x2000</span><br />
<span style="font-size: xx-small;">TargetVendor= 0x19d2</span><br />
<span style="font-size: xx-small;">TargetProductList="0001,0002,0015,0016,0017,0031,0037,0052,0055,0063,0064,0066,0091,0108,0117,0128,0157,2002,2003"</span><br />
<span style="font-size: xx-small;">MessageContent="5553424312345678000000000000061e000000000000000000000000000000"<br />MessageContent2="5553424312345679000000000000061b000000020000000000000000000000"<br />MessageContent3="55534243123456702000000080000c85010101180101010101000000000000"</span><br />
<span style="font-size: xx-small;">NeedResponse=1</span><br />
<span style="font-size: xx-small;">CheckSuccess=20<br />EOF<br />}</span><br />
<span style="font-size: xx-small;">#<br /># echo chatscript<br />#<br />echo_chatscript_tmobile() {<br />echo "$TAG building chatscript"<br />cat > /system/etc/ppp/dialtest.chat << EOF<br />TIMEOUT 10<br />ABORT 'BUSY'<br />ABORT 'NO ANSWER'<br />ABORT 'ERROR'<br />SAY 'Starting GPRS connect script\n'</span><br />
<span style="font-size: xx-small;">""'ATZ'<br />SAY 'Setting APN\n'<br />OK 'AT+CGDCONT=1,"IP","wap.voicestream.com"'</span><br />
<span style="font-size: xx-small;">ABORT 'NO CARRIER'<br />SAY 'Dialing...\n'<br />OK 'ATD*99***1#'<br />CONNECT<br />EOF<br />}</span><br />
<span style="font-size: xx-small;">#<br /># Switch USB modes<br />#<br />switch_usb() {<br /> echo "$TAG switching USB mode" && \<br /> usb_modeswitch -I -W -c /system/etc/usb_modeswitch.conf && \<br /> sleep 5 && \<br /> echo "$TAG mode switch success" && \<br /> return 0<br />}</span><br />
<span style="font-size: xx-small;">#<br /># Start T Mobile firmware<br />#<br />start_tmobile() {<br /> rmmod usbserial<br /> echo "$TAG tmobile firmware provider"</span><br />
<span style="font-size: xx-small;"> echo_modeswitch_conf_zte<br /> echo_chatscript_tmobile</span><br />
<span style="font-size: xx-small;"> switch_usb</span><br />
<span style="font-size: xx-small;"> echo "$TAG installing firmware"<br /> busybox insmod /system/etc/firmware/usbserial.ko vendor=0x19d2 product=0x0157<br /> <br /> echo "$TAG starting pppd"<br /> /system/bin/pppd /dev/ttyUSB1 persist defaultroute usepeerdns -detach crtscts noauth debug connect "/system/xbin/chat -v -s -f /system/etc/ppp/dialtest.chat" &<br />}</span><br />
<strong><br /></strong>
<strong>Insert command to run script into Android’s init.rc bootup commands</strong><br />
<br />
You’ll find init.rc in the root folder on your Android device.<br />
<br />
I placed the init_cellular_pppd.sh script in /system/etc/ppp, though it could technically go anywhere – as long as it’s being called in the right location, and the files it generates are going to the right places as well.<br />
<br />
Then I just added these two lines to Android’s init.rc bootup script:<br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;">service cellular_up /system/bin/logwrapper /system/xbin/busybox sh -c /system/etc/ppp/init_cellular_pppd.sh<br /> oneshot</span><br />
<br />
This ensures that I execute init_cellular_pppd.sh every time I boot, which in turn generates the files I need and executes the commands required to have a fully functional 3G/4G cellular connection every time I boot up my Android device, provided I have the modem plugged in.<br />
<em><br /></em>
<em>I</em><em>n my <a href="http://antipastohw.blogspot.com/2012/05/how-to-install-3g4g-cellular-modem-on.html">last blog post</a>, I cover which parameters you’ll want to tweak if you’re using a different modem or cellular provider, but if you have any questions or suggestions, I’d love to hear it.</em><br />
<em><br /></em>
<em>Email me at </em><a href="mailto:justin@liquidware.com"><em>justin@liquidware.com</em></a><em> or follow me on twitter <a href="http://www.blogger.com/twitter.com/liquidware">@liquidware</a></em>Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com1tag:blogger.com,1999:blog-7377057412446264720.post-62145849762930986032012-08-30T17:55:00.000-04:002012-09-17T09:53:15.180-04:00How to install a 3G/4G cellular modem on my Android BeagleBoard setup<em>A lot of folks have been asking me about this one, so I figured it’s about time to pull together my notes on the tutorial and get started…</em><br />
<em><br /></em>
In this case, I used an <a href="http://www.liquidware.com/shop/show/AND-UPK/Android+Ultimate+Pro+Kit">Android Ultimate Pro Kit</a>, which runs Android 2.3.4 on the <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+XM">BeagleBoard xM</a>/<a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">BeagleTouch</a>/<a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice+2">BeagleJuice, 2nd Gen</a>.<br />
<a href="http://www.liquidware.com/shop/show/AND-UPK/Android+Ultimate+Pro+Kit"><img height="282" src="http://www.liquidware.com/system/0000/3860/Android_Long_Exposure.jpg" style="display: block; float: none; margin-left: auto; margin-right: auto;" width="282" /></a><em>Note: There’s a much sleeker (beta) way to get cell modems running in Android with the new PPP widget from <a href="http://draisberghof.de/usb_modeswitch/">Draisberghof</a>. I haven’t tried it out yet, and hooking up modems the old-fashioned way helped me learn a few useful tips and tricks in navigating ADB, so I’m writing it all out here. Enjoy!</em><br />
<strong><br /></strong>
<strong>Hardware I used</strong><br />
1 <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard xM</a><br />
1 <a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">BeagleTouch</a><br />
1 <a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen">BeagleJuice, 2nd Gen</a> (optional – a <a href="http://www.liquidware.com/shop/show/BB-PWR/BeagleBoard+Power+Adapter">5V power supply</a> works fine too)<br />
1 <a href="http://www.liquidware.com/shop/show/BB-AND-AMB/Android+Ambrosia+SD+Card">Android Ambrosia SD card</a><br />
1 Linux or Mac computer (<a href="http://www.cygwin.com/">cygwin</a> for Windows could also do the job, with a little bit of toolchain setup. I used a dedicated Ubuntu EeePC) <br />
1 <a href="http://www.t-mobile.com/shop/phones/cell-phone-detail.aspx?cell-phone=T-mobile-Rocket-3.0-4G-Laptop-Stick">T-mobile Rocket 3.0 4G laptop stick</a> (but most will work – see below)<br />
1 Type B-mini USB cable for connecting the computer to Amber<br />
<strong><br /></strong>
<strong>Software I used</strong><br />
<a href="http://developer.android.com/sdk/index.html">Android SDK</a> with <a href="http://developer.android.com/guide/developing/tools/adb.html">Android Debug Bridge</a> <br />
Linux terminal (Asus Eee PC is *perfect* for this)<br />
<em><br /></em>
<em>This tutorial assumes that you already have Android SDK with Android Debug Bridge set up, and that you’re communicating to the BeagleBoard/Android device from a Terminal program.</em><br />
<strong><br /></strong>
<strong>Connecting your Android device</strong><br />
1. Switch on your BeagleJuice, 2nd Gen to power on the Android Ultimate Pro Kit.<br />
<br />
2. Once the <a href="http://www.blogger.com/beagleboard.org">BeagleBoard</a> is booted into Android, plug in a USB cable from the Linux terminal to the BeagleBoard’s OTG type B-mini port.<br />
<br />
3. Open up Terminal in Linux.<br />
<br />
4. I have the Android SDK and Android Platform Tools installed, so I can access Android Debug Bridge right from the prompt. The first thing I do is make sure my device is connected by typing:<br />
<em><br /></em>
<em>adb devices</em><br />
<br />
A list of connected and available Android devices should come up. <br />
<strong><br /></strong>
<strong>Tools you’ll need on the Android device</strong><br />
<br />
Most USB 3G/4G cellular modems are actually several “devices” rolled into one – the most notable being some form of onboard data storage.<br />
<br />
<a href="http://www.draisberghof.de/usb_modeswitch/">USB_ModeSwitch</a> is a fantastic utility that essentially does the heavy lifting of separating all these devices, so we can talk to the modem over USB serial directly. <br />
<br />
5. Download and unzip the static binary for ARM processors: <a href="http://www.draisberghof.de/usb_modeswitch/usb_modeswitch-1.1.9-arm-static.bz2">usb_modeswitch-1.1.9-arm-static.bz2</a><br />
<br />
From your working directory, push the usb_modeswitch application to <strong>/system/xbin/</strong> on your Android device:<br />
<em><br /></em>
<em>adb push usb_modeswitch-1.1.9-arm-static /system/xbin/usb_modeswitch</em><br />
<br />
6. Download the usbserial.ko kernel module from the <a href="http://www.liquidware.com/system/0000/5711/usbserial.ko">Liquidware site</a>. The reason I have it set up as a separate module is so that we can install usbserial as the driver for our modem, which is necessary to communicate. Then push usbserial.ko to your Android device:<br />
<em><br /></em>
<em>adb push usbserial.ko usbserial.ko</em><br />
<br />
This will put the usbserial.ko file in the root folder on your Android device, which is fine for our purposes.<br />
We’ll create the usb_modeswitch config file you’ll need later.<br />
<strong><br /></strong>
<strong>Find your modem identification information</strong><br />
<br />
7. Go into Android shell:<br />
<em><br /></em>
<em>adb shell</em><br />
<br />
Now you can issue commands as if you’re in a terminal application on the Android device. <br />
<br />
8. To see details about attached USB devices, first mount the usbfs file system.<br />
<em><br /></em>
<em>mount -t usbfs usbfs /proc/bus/usb</em> <br />
<br />
Now type in:<br />
<em><br /></em>
<em>cat /proc/bus/usb/devices</em><br />
<br />
You should see a list of devices appear. Each USB device will have a Vendor ID and a Product ID. This detailed information also clues you in by telling you what Driver the USB device is currently using.<br />
<br />
<a href="http://lh5.ggpht.com/-BWasx8hYEC8/UEDzwaNDJDI/AAAAAAAAB1o/ZI3Rwcw3FjU/s1600-h/image3.png"><img alt="image" border="0" height="571" src="http://lh5.ggpht.com/-km2ABC89gvc/UEDzw2GJYvI/AAAAAAAAB1w/j-YfBrw5aio/image_thumb1.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<br />
The one I’m looking for is the T-Mobile Rocket 4G, made by ZTE. Three relevant pieces of information:<br />
<br />
Vendor=19d2<br />
ProdID=2000<br />
Driver=usb-storage<br />
<br />
Each device has a vendor and product code identifier. The Driver is “usb-storage”, meaning that the composite modem is recognized as a USB mass storage device. Not very useful for our purposes. That’s where USB ModeSwitch comes in. You’ll tell USB ModeSwitch to send a special string of characters, which then splits the composite device into 6 independently communicating USB serial devices – one of which is our modem.<br />
<br />
Write down your Vendor and Product ID, as well as your Manufacturer, Product, and SerialNumber info. These will all be helpful in finding the correct string that you’ll need to send to the modem via ModeSwitch. <br />
<br />
7. In order for USB ModeSwitch to run properly, you’ll need to create USB modeswitch config file in the right format that has the correct string of characters. I started by looking on Draisberghof’s extensive list of <a href="http://www.draisberghof.de/usb_modeswitch/device_reference.txt">device references</a>. For the T-Mobile Rocket 4G 3.0 by ZTE, copy the following text into gedit on your Linux terminal, and create a file called usb_modeswitch.conf<br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;">########################################################</span> <br />
<span style="font-size: xx-small;"># ZTE devices</span> <br />
<span style="font-size: xx-small;">DefaultVendor= 0x19d2</span> <br />
<span style="font-size: xx-small;">DefaultProduct= 0x2000</span> <br />
<span style="font-size: xx-small;">TargetVendor= 0x19d2</span> <br />
<span style="font-size: xx-small;">TargetProductList="0001,0002,0015,0016,0017,0031,0037,0052,0055,0063,0064,0066,0091,0108,0117,0128,0157,2002,2003"</span> <br />
<span style="font-size: xx-small;">MessageContent="5553424312345678000000000000061e000000000000000000000000000000"</span> <br />
<span style="font-size: xx-small;">MessageContent2="5553424312345679000000000000061b000000020000000000000000000000"</span> <br />
<span style="font-size: xx-small;">MessageContent3="55534243123456702000000080000c85010101180101010101000000000000"</span> <br />
<span style="font-size: xx-small;">NeedResponse=1</span> <br />
<span style="font-size: xx-small;">CheckSuccess=20</span> <br />
<br />
8. Push usb_modeswitch.conf down to your Android device. <br />
<em><br /></em>
<em>adb push usb_modeswitch.conf /system/xbin/usb_modeswitch.conf</em> <br />
<br />
9. There is one additional file you’ll need, which is known as a chat script. It secures the connection with T-Mobile. Open up gedit again and copy the following text, creating a file called<em> dialtest.chat</em>: <br />
<span style="font-size: xx-small;"><br /></span>
<span style="font-size: xx-small;">TIMEOUT 10 </span> <br />
<span style="font-size: xx-small;">ABORT 'BUSY' </span> <br />
<span style="font-size: xx-small;">ABORT 'NO ANSWER' </span> <br />
<span style="font-size: xx-small;">ABORT 'ERROR' </span> <br />
<span style="font-size: xx-small;">SAY 'Starting GPRS connect script\n' </span> <br />
<span style="font-size: xx-small;">""'ATZ' </span> <br />
<span style="font-size: xx-small;">SAY 'Setting APN\n' </span> <br />
<span style="font-size: xx-small;">OK 'AT+CGDCONT=1,"IP","</span><a href="http://wap.voicestream.com/"><span style="font-size: xx-small;">wap.voicestream.com</span></a><span style="font-size: xx-small;">"' </span> <br />
<span style="font-size: xx-small;">ABORT 'NO CARRIER' </span> <br />
<span style="font-size: xx-small;">SAY 'Dialing...\n' </span> <br />
<span style="font-size: xx-small;">OK 'ATD*99***1#' </span> <br />
<span style="font-size: xx-small;">CONNECT</span> <br />
<br />
10. Push the file down to your Android device: <br />
<em><br /></em>
<em>adb push dialtest.chat dialtest.chat</em> <br />
<br />
This will put dialtest.chat into your root directory. <br />
<strong><br /></strong>
<strong>Turn on your 3G/4G cellular modem for Android</strong><br />
<strong><br /></strong>
<a href="http://lh4.ggpht.com/-o0KskIHUdiI/UEDzxyZQM_I/AAAAAAAAB14/FX70exMtjbw/s1600-h/image%25255B4%25255D.png"><img alt="image" border="0" height="415" src="http://lh5.ggpht.com/-FODD5ZBWYHg/UEDzysNC53I/AAAAAAAAB2A/xz9Zdq7cg_Y/image_thumb%25255B1%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<br />
Now that all the right files are in the right places, we can execute all the commands at once.<br />
<br />
11. Plug in your 3G/4G USB cellular modem. It should start blinking<br />
<br />
12. Go into shell on your Android device:<br />
<em><br /></em>
<em>adb shell</em><br />
<br />
13. At the Android shell prompt, enter the following:<br />
<em><br /></em>
<em>/system/xbin/usb_modeswitch -I -W -c usb_modeswitch.conf</em><br />
<em><br /></em>
<a href="http://lh6.ggpht.com/-x0dn2UOT6dc/UEDzzb34BcI/AAAAAAAAB2I/_GslUTgBG3s/s1600-h/image%25255B8%25255D.png"><img alt="image" border="0" height="729" src="http://lh4.ggpht.com/-vEZPHjeKXiQ/UEDz0MLTpMI/AAAAAAAAB2Q/wR2UtnQswxQ/image_thumb%25255B3%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<br />
The output will tell me whether the operation was successful, and if it was, you’ll see something like the above screenshot.<br />
<br />
14. Notice that the “matching” vendor/product ID is 19d2:0157. We can now install the usbserial kernel directly to that device. Make sure you are in the root directory, since that’s where we put the kernel file. The vendor ID and product ID need to be written in hex.<br />
<em><br /></em>
<em>insmod usbserial.ko vendor=0x19d2 product=0x0157</em><br />
<br />
15. Now check to see what devices are attached to USB at this point:<br />
<em><br /></em>
<em>cat /proc/bus/usb/devices</em><br />
<br />
You should see something like the following:<br />
<br />
<a href="http://lh3.ggpht.com/-w-f7cFEIGiA/UEDz02nX0BI/AAAAAAAAB2Y/u-wMEuP-LIc/s1600-h/image%25255B12%25255D.png"><img alt="image" border="0" height="459" src="http://lh6.ggpht.com/-U8wkovGdFI4/UEDz1B9d9zI/AAAAAAAAB2g/ADtURhfOpGo/image_thumb%25255B5%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<br />
Compare this to the original screenshot, where usb-storage was the only device and driver under this product.<br />
<br />
If you’d like, you can check this under the list of serial devices by typing:<br />
<em><br /></em>
<em>ls /dev/tty*</em><br />
<em><br /></em>
<a href="http://lh3.ggpht.com/-u_9EJ9zgJRk/UEDz1gp0rhI/AAAAAAAAB2o/BM89c13Mlkg/s1600-h/image%25255B16%25255D.png"><img alt="image" border="0" height="311" src="http://lh3.ggpht.com/-RGFrHlnKcgw/UEDz1xqfKFI/AAAAAAAAB2w/Vj_VyDdoFUg/image_thumb%25255B7%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<br />
If you see ttyUSB0-5, you’re good to go!<br />
<br />
16. This part usually takes a little experimenting to figure out which USB device you want to call with the <em>pppd</em> command. This is the correct one. It will execute the <em>dialtest.chat</em> script that you put on the device earlier. (If you’re looking closely, I put my dialtest.chat script in a different folder, but that’s not really a big issue as long as you have the right path)<br />
<em><br /></em>
<em>pppd /dev/ttyUSB1 persist defaultroute usepeerdns -detach crtscts noauth debug connect "/system/xbin/chat -v -s -f dialtest.chat"</em><br />
<em><br /></em>
<a href="http://lh6.ggpht.com/-ba4z4OF4iZk/UEDz2rrLE1I/AAAAAAAAB24/yZ5loKSglCE/s1600-h/image%25255B20%25255D.png"><img alt="image" border="0" height="249" src="http://lh4.ggpht.com/-1gxC5D0K1iA/UEDz2_Dwp-I/AAAAAAAAB3A/MqG8d0Hc3MA/image_thumb%25255B9%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<br />
Be sure to leave this terminal window open to maintain the connection.<br />
<br />
The above screen shot shows what happens on a successful initiation of the chat script. You are now ready to go online. ifconfig tells me what my network connections are. Note that ppp0 has an IP address, which means we’re connected to T-Mobile.<br />
<em><br /></em>
<em>ifconfig</em><br />
<em><br /></em>
<a href="http://lh3.ggpht.com/-ZhZJJAMIaRY/UEDz3h5IJbI/AAAAAAAAB3I/wyENQjXvZhk/s1600-h/image%25255B27%25255D.png"><img alt="image" border="0" height="423" src="http://lh5.ggpht.com/-SO7hYey838c/UEDz4GC8rYI/AAAAAAAAB3Q/iNRw6UYuLDw/image_thumb%25255B12%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<br />
And the beautiful turquoise beacon, and CNN.com confirms that I’m online!<br />
<br />
<a href="http://lh3.ggpht.com/-kY2d6Rwh3Xk/UEDz5P26BBI/AAAAAAAAB3Y/6w_XXJtBGXc/s1600-h/image%25255B31%25255D.png"><img alt="image" border="0" height="380" src="http://lh4.ggpht.com/-ZTC6aWd-bzU/UEDz5znIsEI/AAAAAAAAB3g/Epq7U0AJSnM/image_thumb%25255B14%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<em><br /></em>
<em>I’m sure there are going to be questions – email me at <a href="mailto:justin@liquidware.com">justin@liquidware.com</a> or find me on twitter @liquidware. Or just comment below, and I’ll get back to you immediately.</em><br />
<em><br /></em>
<em>Next up after the Labor Day Weekend, I’ll explain how to roll this all up into a boot script, so it can run instantly, every time you power on the Android device.</em><br />
<em><br /></em>
<em>A big thanks to <a href="http://freedune.wordpress.com/2011/06/23/success-with-usb-3g-modems-on-android/">freedune</a> for an excellent and well-written blog post, which steered me through most of this effort!</em>Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-73915512146728151122012-08-22T10:36:00.001-04:002012-09-17T09:58:27.486-04:00Introducing the Dual-Core Android 4 Dev Kit for PandaBoard<em>With dual-core processors and Android 4 (Ice Cream Sandwich, at least) a mainstay of smartphones and tablets, some folks suggested it was about time for the </em><a href="http://www.liquidware.com/shop/show/BB-ESK/Beagle+Embedded+Starter+Kit"><em>Beagle Embedded Starter Kit</em></a><em> and </em><a href="http://www.liquidware.com/shop/show/BB-AND-DEV/Android+Hardware+Development+Kit"><em>Android Hardware Development Kit</em></a><em> to get a big brother…</em><br />
<a href="http://lh3.ggpht.com/-cJk5JD4-_WM/UDTuZ2UjbFI/AAAAAAAABy4/WpP84qKMXMI/s1600-h/image%25255B20%25255D.png"><img alt="image" border="0" height="270" src="http://lh6.ggpht.com/-jdPwNPhBnFk/UDTuaXCUGQI/AAAAAAAABzA/-yGpXIxKk38/image_thumb%25255B9%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="650" /></a><br />
After quite a few months of requests, Chris and I got Android 4 running on the <a href="http://www.liquidware.com/shop/show/BB-PBE/PandaBoard+ES">PandaBoard</a>, along with an HDMI adapter board and some drivers to get the PandaBoard a “<a href="http://www.wired.com/gadgetlab/2010/06/build-your-own-tablet-for-400/">DIY tablet kit</a>” of its own. <br />
<a href="http://www.liquidware.com/shop/show/AND-ICS1/Dual-Core+Android+4+Dev+Kit"><img alt="image" border="0" height="546" src="http://lh4.ggpht.com/-CK5FGZ8PNKM/UDTubM07UHI/AAAAAAAABzI/jpwk36oGJsA/image%25255B21%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
<a href="http://www.liquidware.com/shop/show/AND-ICS1/Dual-Core+Android+4+Dev+Kit"><img alt="image" border="0" height="409" src="http://lh3.ggpht.com/-KfvJx2juO4Q/UDTub4Wz_SI/AAAAAAAABzQ/DirVsQknd34/image%25255B16%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="620" /></a><br />
Just as the name suggests, the <a href="http://www.liquidware.com/shop/show/AND-ICS1/Dual-Core+Android+4+Dev+Kit">Dual-core Android 4 Dev Kit</a> consists of the dual-core OMAP 4430 <a href="http://www.pandaboard.org/">PandaBoard</a>, Android 4 ICS (with <a href="http://antipastohw.pbworks.com/w/page/41729078/How-to%20use%20a%20serial%20port%20with%20Android,%20Liquidware%20Ambrosia%20edition">Android serial support</a>), 4.3” touchscreen enabled, powered by a laptop-grade battery pack, so it can be remote mounted, portable, or just permanently charging with a backup power supply.<br />
<a href="http://lh6.ggpht.com/-X4jhD7cl8KM/UDTucORNSjI/AAAAAAAABzY/7pyEbqtQlqM/s1600-h/IMG_0274%25255B5%25255D.jpg"><img alt="IMG_0274" border="0" height="349" src="http://lh6.ggpht.com/-OhxJoSqnnD0/UDTucuufOYI/AAAAAAAABzg/1blJosrvAR4/IMG_0274_thumb%25255B2%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="IMG_0274" width="620" /></a><br />
The popular 4.3” <a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">BeagleTouch OLED</a> display now works with the PandaBoard’s OMAP4430 with the help of a carrier board that conveniently brings the BeagleTouch pinouts to an HDMI connector.<br />
<a href="http://lh4.ggpht.com/-A9GWPp5MQIk/UDTudCrTQjI/AAAAAAAABzo/Rm7T69zk27o/s1600-h/IMG_0280%25255B4%25255D.jpg"><img alt="IMG_0280" border="0" height="349" src="http://lh4.ggpht.com/-YOwBZnDRNX4/UDTudRhuvOI/AAAAAAAABzw/ExLK-51NTkk/IMG_0280_thumb%25255B1%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="IMG_0280" width="620" /></a><br />
The other side of the PandaBoard sandwich is the <a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen">BeagleJuice, 2nd Generation</a>, providing smart, laptop-grade battery and power management capabilities to the PandaBoard’s 5V input jack.<br />
I don’t think that a few extra wires ever frightened any readers of this blog (if anything, there probably aren’t enough random wires on these boards!), but it’s fresh off the lab, so some of these extra wires are going to be solidified as the boards ship.<br />
Either way, I’m pretty pumped about having a portable display + battery setup that works with the PandaBoard, but also one that runs <a href="http://www.android.com/about/ice-cream-sandwich/">Android 4 (ICS)</a> and takes full advantage of Texas Instrument’s dual-core OMAP4430 processor.<br />
<a href="http://lh4.ggpht.com/-SeMrzfJsKSA/UDTud9CIP5I/AAAAAAAABz4/Ldau9bqdXuM/s1600-h/IMG_0276%25255B4%25255D.jpg"><img alt="IMG_0276" border="0" height="349" src="http://lh6.ggpht.com/-ITxSslfyiMk/UDTuelZLzKI/AAAAAAAAB0A/NIzLrlmUx0g/IMG_0276_thumb%25255B1%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="IMG_0276" width="620" /></a><br />
One of the reasons I decided to make the panel remote mount capable (connected by wires rather than headers) is that the PandaBoard has a bigger footprint than the <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard</a>, and a remote mount would allow the board and battery to be stored or mounted separately, much like most thin clients.<br />
<a href="http://lh3.ggpht.com/-S7X6yuBSR_Y/UDTufPzKwmI/AAAAAAAAB0I/1lT2iZAB8Gk/s1600-h/IMG_0286%25255B4%25255D.jpg"><img alt="IMG_0286" border="0" height="349" src="http://lh3.ggpht.com/-fh-7aQvS-OM/UDTuftQkpmI/AAAAAAAAB0Q/3aTjMtS2GOs/IMG_0286_thumb%25255B1%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="IMG_0286" width="620" /></a><br />
Here’s a quick demo I just put together:<br />
<center>
<iframe allowfullscreen="allowfullscreen" frameborder="0" height="360" src="http://www.youtube.com/embed/JfAT2k7OGFA" width="640"></iframe></center>
<em>I think this would make a cool, totally overkill, touchscreen thermostat that I could shove in my wall, not unlike the </em><a href="http://www.nest.com/"><em>Nest</em></a><em> (who knew thermostats could be so sexy?), but until next time, post questions, comments and project ideas to comments, </em><a href="mailto:justin@liquidware.com"><em>justin@liquidware.com</em></a><em>, or tweet me @liquidware …</em><a href="http://lh3.ggpht.com/-gsy1PrN8qPE/UDTugRcBcVI/AAAAAAAAB0Y/lznESp4J6no/s1600-h/image%25255B10%25255D.png"><img alt="image" border="0" height="311" src="http://lh4.ggpht.com/-Lzq2PPylbmc/UDTugxQkRmI/AAAAAAAAB0g/15fjOzotPD4/image_thumb%25255B5%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="300" /></a>Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com2tag:blogger.com,1999:blog-7377057412446264720.post-26160621526803920272012-08-14T17:10:00.001-04:002012-09-17T10:31:58.258-04:00Twittering shark laser intrusion detection system, in honor of Shark Week<em>Thanks again <a href="https://twitter.com/bbenchoff">@bbenchoff</a> for the <a href="http://www.blogger.com/bit.ly/MXJKfZ">post</a> about the <a href="http://antipastohw.blogspot.com/2012/08/how-to-build-diy-perpetually-powered.html">DIY perpetually-powered wireless outpost</a> on <a href="https://twitter.com/hackaday">@hackaday</a>! A lot of good discussion on natural/perpetual power sources :) </em><br />
<em><br /></em>
<em>I got an email from Dan earlier this week about making a fish tracking aquarium. Being that we’re right in the middle of <a href="http://dsc.discovery.com/tv/shark-week/">Shark Week</a>, I respectfully obliged…</em><br />
<em><br /></em>
<a href="http://dsc.discovery.com/tv/shark-week/"><img alt="image" border="0" height="87" src="http://lh6.ggpht.com/-VB1tEgp7nYs/UCstETVhBqI/AAAAAAAABts/xmMTcih7X28/image%25255B57%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="409" /></a><br />
<br />
This may or may not have implications for real-life shark tracking, but I’ll take an excuse to have my shark tweet me when he (or she, I’m no marine biologist) breaches the perimeter over to the sunny side of the tank. <br />
<br />
Of course, I’m doing this with my toy shark-on-a-stick and only a laser level and a light sensor, but it’s possible to make this much more accurate and granular just by adding more strategically placed sensors/light sources into the mix.<br />
<div align="left">
<em><br /></em>
<span style="background-color: yellow;"><em></em></span><em>Disclaimer: This project was designed purely with fun and proof-of-concept in mind, and in no way is designed to replace the $100 million <a href="http://www.businessinsider.com/heres-the-document-that-raytheon-really-doesnt-want-you-to-see-2012-8">airport intrusion detection system at JFK</a>. The jet ski was too big and too fast for my 10 gallon fishtank…</em><br />
<em><br /></em></div>
<div align="center">
<em></em><img height="255" src="http://undergroundmgzn.com/wp/wp-content/uploads/2012/05/laser-security-system.jpg" style="display: block; float: none; margin-left: auto; margin-right: auto;" width="377" /><em><strong>I couldn’t find a picture of Tom Cruise doing this </strong></em><br />
<em><strong>because the </strong></em><em><strong>lasers </strong></em><em><strong>in Mission Impossible weren’t visible…</strong></em></div>
<strong><br /></strong>
<strong>Concept</strong><br />
<br />
Most <a href="http://www.ehow.com/how-does_5001517_laser-security-systems-work.html">laser security systems</a> rely on infrared sensors that detect changes in heat, based on a beam of light hitting the sensor. If that beam is interrupted, it’s interpreted as a change in the thermal profile on the sensor, and an alarm goes off. Usually the beams are invisible too, so that picture above is mildly inaccurate. Here’s the basic idea of how the project went:<br />
<br />
<a href="http://lh3.ggpht.com/-SttG8jtfVHk/UCstEwHUR_I/AAAAAAAABtw/Reex-oxYXA0/s1600-h/image%25255B36%25255D.png"><img alt="image" border="0" height="401" src="http://lh4.ggpht.com/-3KShPzA9Ss4/UCstFb4HZcI/AAAAAAAABt4/eJeiwn0SnUU/image_thumb%25255B21%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="554" /></a><br />
<br />
<a href="http://lh5.ggpht.com/-e7whEMoOxBM/UCstFgir-JI/AAAAAAAABuA/fBzZOZcvEew/s1600-h/image%25255B37%25255D.png"><img alt="image" border="0" height="400" src="http://lh6.ggpht.com/-6ESYiNilIxI/UCstGCTO_fI/AAAAAAAABuE/Jxhib3CLuKg/image_thumb%25255B22%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="554" /></a><br />
<br />
I took a little field trip to Petco and Toys R Us to get a fish tank simulation setup. For the laser pointer, a laser light level I had in the shop worked really nicely, but any standard laser pointer will do.<br />
<br />
<strong><a href="http://lh4.ggpht.com/-aBAuKZ5PSNw/UCstGoQO3zI/AAAAAAAABuI/uSWwAnSEF9A/s1600-h/Tank%252520Setup%25255B6%25255D.jpg"><img alt="Tank Setup" border="0" height="390" src="http://lh6.ggpht.com/-kkupR0l3_dA/UCstHAuyTLI/AAAAAAAABuU/4eP-xhIRqdM/Tank%252520Setup_thumb%25255B3%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="Tank Setup" width="620" /></a></strong><br />
<strong><br /></strong>
<strong>Building the light sensor/laser setup</strong><br />
<br />
I ended up using a real, visible laser for two reasons: first, it’s easy to line up against my light sensor, and second, because I’m shooting the beam through water and 2 glass panels (on either side of my tank), which might otherwise diffuse the beam’s heat profile. Dry museums have it so easy…<br />
<br />
<a href="http://lh4.ggpht.com/-UQENfxfhRH4/UCstHl9youI/AAAAAAAABuc/5nCg54rYryU/s1600-h/Tank%252520Setup%252520Closeup%25255B4%25255D.jpg"><img alt="Tank Setup Closeup" border="0" height="349" src="http://lh4.ggpht.com/-FvRJyReF-p8/UCstIEN0g6I/AAAAAAAABuk/pGDbALz0teI/Tank%252520Setup%252520Closeup_thumb%25255B1%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="Tank Setup Closeup" width="620" /></a><br />
<br />
On the other side of the tank, I have an Arduino with a light sensor elegantly taped to the glass. <br />
<br />
<a href="http://lh6.ggpht.com/-bbiMRKtA0nA/UCstIUcRE7I/AAAAAAAABus/Zk68MIh_S1Q/s1600-h/Light%252520Sensor%252520Closeup%25255B4%25255D.jpg"><img alt="Light Sensor Closeup" border="0" height="209" src="http://lh6.ggpht.com/-Az9Kpv6bzx8/UCstIozse9I/AAAAAAAABu0/KHRgkbj8Ps4/Light%252520Sensor%252520Closeup_thumb%25255B1%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="Light Sensor Closeup" width="278" /></a><br />
<span style="color: #0000ee;"><u><br /></u></span>I cut a hole in the wallpaper – on the left side, the laser is hitting the sensor directly. On the right, I moved the laser away, so you can see it the light sensor more clearly. <br />
<br />
<a href="http://lh5.ggpht.com/-rPZ9BFrFgYc/UCstJCiZbqI/AAAAAAAABvA/-J7XBtirxvc/s1600-h/image%25255B18%25255D.png"><img alt="image" border="0" height="300" src="http://lh3.ggpht.com/-tPvsukPrj9c/UCstJ4LwQPI/AAAAAAAABvM/mLUOSYtn9HQ/image_thumb%25255B12%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="300" /></a> <a href="http://lh6.ggpht.com/-GWzfsWylOG0/UCstKjb41uI/AAAAAAAABvU/olplrC4atRI/s1600-h/image%25255B14%25255D.png"><img alt="image" border="0" height="300" src="http://lh6.ggpht.com/-lCJEbN4HIeA/UCstLdEhDlI/AAAAAAAABvc/hClfdP9V6Zo/image_thumb%25255B8%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="300" /></a><br />
<br />
Chris and I just have some basic code running on the Arduino to get analog readings out from the <a href="http://www.liquidware.com/shop/show/SEN-LTE/AMBI+Light+Sensor">AMBI light sensor</a>. (The dead simple <a href="http://antipastohw.blogspot.com/2010/04/introducing-ambi-ambient-light-sensor.html">up-and-running post</a> from way back when, as well as the wiki <a href="http://antipastohw.pbworks.com/w/page/26594512/AMBI%20Light%20Sensor">here</a>). I uploaded the code to the Arduino, checked the output from serial, it seems like I’m good to go!<br />
<br />
<strong>Connecting the sensor setup to a web-connected Android/BeagleBoard system</strong><br />
<strong><br /></strong>
I connected the Arduino + Light Sensor to the BeagleBoard/<a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">BeagleTouch</a>/Android <a href="http://www.liquidware.com/shop/show/BB-AND-DIY/Android+DIY+Starter+Kit+">stack</a> sitting in my freshly dug up <a href="http://antipastohw.blogspot.com/2012/08/how-to-build-diy-perpetually-powered.html">Mystery Box</a>.<br />
<br />
<a href="http://lh6.ggpht.com/-4-d7iDS-JHM/UCstL_sfk_I/AAAAAAAABvk/sJkd3t0R0ws/s1600-h/Mystery%252520Box%252520Setup%25255B5%25255D.jpg"><img alt="Mystery Box Setup" border="0" height="359" src="http://lh4.ggpht.com/-sWi_CfV8iuw/UCstMXg39dI/AAAAAAAABvs/2Rt9BhYoXyY/Mystery%252520Box%252520Setup_thumb%25255B2%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="Mystery Box Setup" width="620" /></a><br />
<br />
For a recap on how to connect the Arduino and sensor outputs over serial to output to the <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard</a> over <a href="http://www.liquidware.com/category/Android">Android</a>, here’s a link to the <a href="http://antipastohw.pbworks.com/w/page/41729078/How-to%20use%20a%20serial%20port%20with%20Android,%20Liquidware%20Ambrosia%20edition">Antipasto wiki post</a>. (This can still be tricky even with the <a href="http://www.liquidware.com/shop/show/BB-AND-AMB/Android+Ambrosia+SD+Card">Android Ambrosia</a> SD card, so email me <a href="mailto:justin@liquidware.com">justin@liquidware.com</a>, or comment below if you get stuck.)<br />
Once I was able to get readings from the light sensor/Arduino in Android, I wrote a quick little Android APK to do two things:<br />
<blockquote>
1) Flash a Red Alert on BeagleTouch screen<br />
2) Trigger a tweet to be sent</blockquote>
Why Twitter? It’s excellent for posting event alerts in an easy to subscribe fashion, and it’s also really easy to have these alerts forwarded to SMS, email, and Facebook. And they have a pretty excellent API, which I’ll get to in the next section.<br />
<br />
If nothing is obstructing the the light sensor, the laser drives a light value of about 700-800.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://lh5.ggpht.com/-uAO7u8F81Rg/UCstM-UKXdI/AAAAAAAABv0/s6L6P5ZWoSU/s1600-h/IMG_0255%25255B4%25255D.jpg" style="margin-left: 1em; margin-right: 1em;"><img alt="IMG_0255" border="0" height="349" src="http://lh5.ggpht.com/-55iCaQbBsPE/UCstNSIsWLI/AAAAAAAABv8/ddXLiShxI-w/IMG_0255_thumb%25255B1%25255D.jpg?imgmax=800" style="background-image: none; border-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="IMG_0255" width="620" /></a></div>
<br />
<a href="http://www.liquidware.com/category/Android"><img alt="BeagleTouch Android App Off" border="0" height="349" src="http://lh4.ggpht.com/-HrkJWMuwVfA/UCstN_wJOsI/AAAAAAAABwE/wwyvyIhlUJs/BeagleTouch%252520Android%252520App%252520Off%25255B5%25255D.jpg?imgmax=800" style="background-image: none; border: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="BeagleTouch Android App Off" width="620" /></a><br />
<br />
As soon as the laser is obstructed by Bruce the shark himself, that light value drops. Once it’s below 400, the Android program issues a Red Alert warning that the sensor has been tripped, and sends a tweet.<br />
<br />
<strong><a href="http://lh4.ggpht.com/-TuSvAKAW2kw/UCstOGLQWHI/AAAAAAAABwM/wIVhwT2aLiI/s1600-h/IMG_0256%25255B8%25255D.jpg"><img alt="IMG_0256" border="0" height="349" src="http://lh3.ggpht.com/-jnV8zcrBcOU/UCstO-9UzrI/AAAAAAAABwU/Lzh4Slaq9mA/IMG_0256_thumb%25255B2%25255D.jpg?imgmax=800" style="background-image: none; border-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="IMG_0256" width="620" /></a></strong><br />
<span style="color: #0000ee;"><b><u><br /></u></b></span><a href="http://www.liquidware.com/category/Android"><img alt="BeagleTouch Android App On" border="0" height="349" src="http://lh4.ggpht.com/-K-W7A5P6820/UCstPRtD8eI/AAAAAAAABwc/iJBCIidX5JM/BeagleTouch%252520Android%252520App%252520On%25255B5%25255D.jpg?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="BeagleTouch Android App On" width="620" /></a><br />
<br />
This serial app, which Chris originally wrote for the <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Liquidware Amber</a>, simply takes the values being sent from the Arduino/light sensor, then funnels it through the following logic:<br />
<br />
A ratchet digital filter that detects when the sensor has been obstructed (and resets) <br />
<h6>
<div style="background-color: white; color: #132bc3; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: #991664;">if</span><span style="color: black;"> ( (sensorVal < </span>NIGHT_TRIP_POINT<span style="color: black;">) && (</span>ratchetCounter<span style="color: black;"> > </span>ratchetMin<span style="color: black;">))</span></div>
<div style="background-color: white; color: #132bc3; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: black;"> </span>ratchetCounter<span style="color: black;">--;</span></div>
<div style="background-color: white; color: #991664; font-family: Monaco; font-weight: normal; margin: 0px; min-height: 15px;">
<br /></div>
<div style="background-color: white; color: #132bc3; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: #991664;">if</span><span style="color: black;"> (</span>ratchetCounter<span style="color: black;"> == </span>ratchetMin<span style="color: black;">)</span></div>
<div style="background-color: white; color: #132bc3; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: black;"> </span>time<span style="color: black;"> = </span>NIGHT<span style="color: black;">;</span></div>
<div style="background-color: white; color: #991664; font-family: Monaco; font-weight: normal; margin: 0px; min-height: 15px;">
<br /></div>
<div style="background-color: white; color: #132bc3; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: #991664;">if</span><span style="color: black;"> ((sensorVal > </span>DAY_TRIP_POINT<span style="color: black;">) && (</span>ratchetCounter<span style="color: black;"> < </span>ratchetMax<span style="color: black;">))</span></div>
<div style="background-color: white; color: #132bc3; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: black;"> </span>ratchetCounter<span style="color: black;">++;</span></div>
<div style="background-color: white; color: #991664; font-family: Monaco; font-weight: normal; margin: 0px; min-height: 15px;">
<br /></div>
<div style="background-color: white; color: #132bc3; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: #991664;">if</span><span style="color: black;"> (</span>ratchetCounter<span style="color: black;"> == </span>ratchetMax<span style="color: black;">)</span></div>
<div style="background-color: white; color: #991664; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: #132bc3;">time</span> = <span style="color: #132bc3;">DAY</span>;</div>
</h6>
Then here are a few of Bruce’s tweet alerts, stored in a String array:<br />
<h6>
<div style="background-color: white; color: #222222; font-family: Monaco; font-weight: normal; margin: 0px;">
String [] <span style="color: #132bc3;">mTweets</span> = {</div>
<div style="background-color: white; color: #222222; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: #4239f5;">"Yum."</span>,</div>
<div style="background-color: white; color: #4239f5; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: black;"> </span>"Fish are friends, not food!"<span style="color: black;">,</span></div>
<div style="background-color: white; color: #4239f5; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: black;"> </span>"I am a nice shark, not a mindless eating machine."<span style="color: black;">,</span></div>
<div style="background-color: white; color: #4239f5; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: black;"> </span>"Anchor! Chum!"<span style="color: black;">,</span></div>
<div style="background-color: white; color: #4239f5; font-family: Monaco; font-weight: normal; margin: 0px;">
<span style="color: black;"> </span>"So, what's a couple of bites like you doing out so late?"</div>
<div style="background-color: white; color: #222222; font-family: Monaco; font-weight: normal; margin: 0px;">
};</div>
</h6>
Finally, bringing these two pieces together…<br />
<h6>
<div style="background-color: white; color: #991664; font-family: Monaco; font-weight: normal; margin: 0px;">
<br />
<div style="margin: 0px;">
if ((<span style="color: #132bc3;">time</span> == <span style="color: #132bc3;">NIGHT</span>) && (<span style="color: #132bc3;">prevTime</span> == <span style="color: #132bc3;">DAY</span>)) {</div>
<div style="margin: 0px;">
<span style="color: #132bc3;">mAlertDlg</span>.setVisibility(View.<span style="color: #132bc3;">V<wbr></wbr></span></div>
</div>
</h6>
ISIBLE);
<br />
<div style="margin: 0px; min-height: 15px;">
<br /></div>
<div style="color: #132bc3; margin: 0px;">
<span style="color: black;"> </span>mTweetIndex<span style="color: black;">++;</span></div>
<div style="color: #132bc3; margin: 0px;">
<span style="color: black;"> </span><span style="color: #991664;">if</span><span style="color: black;"> (</span>mTweetIndex<span style="color: black;"> >= </span>mTweets<span style="color: black;">.</span>length<span style="color: black;">)</span></div>
<div style="margin: 0px;">
<span style="color: #132bc3;">mTweetIndex</span> = 0;</div>
<div style="margin: 0px; min-height: 15px;">
<br /></div>
<div style="margin: 0px;">
Tweet <span style="text-decoration: underline;">tweet</span> = new Tweet(<span style="color: #132bc3;">mContext</span>,</div>
<div style="color: #132bc3; margin: 0px;">
<span style="color: black;"> </span>mTweets<span style="color: black;">[</span>mTweetIndex<span style="color: black;">]);</span></div>
<div style="margin: 0px;">
}</div>
I posted the full source code to the Android serial reading application <a href="https://github.com/liquidware/amber-serial">on Github</a>, if you’re interested. Big thanks to the folks who developed the <a href="http://twitter4j.org/en/index.html">twitter4j Android library</a>!<br />
<br />
<strong>Twitter Alerts from Bruce the Shark</strong><br />
<br />
Two of the world’s most famous sharks have been named Bruce (see hints below):<br />
<br />
<img height="170" src="http://www.vancouverobserver.com/sites/vancouverobserver.com/files/images/blog/body/2138488.jpg" style="display: inline;" width="200" /><img height="224" src="http://www.iconsoffright.com/JAWS/Joe_and_Bruce.jpg" style="display: inline;" width="320" /><br />
<br />
So I figured <a href="https://twitter.com/BruceSharkAlert">@BruceSharkAlert</a> would be a fitting Twitter handle. In order to make Tweets actually happen, the code above needs to be linked to an authenticated Twitter developer account. Logging in as BruceSharkAlert on <a href="https://dev.twitter.com/">dev.twitter.com</a>, this is what I’ve got:<br />
<br />
I created this application…<br />
<br />
<a href="http://lh4.ggpht.com/-435MvH5vOhw/UCstPgn2vlI/AAAAAAAABwk/7hnnYP_Z3xc/s1600-h/image%25255B50%25255D.png"><img alt="image" border="0" height="190" src="http://lh4.ggpht.com/-C_PCARUr-7k/UCstP8OBcOI/AAAAAAAABws/3Ro9b1xn1Zg/image_thumb%25255B29%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="624" /></a><br />
<br />
Filled out the forms and got authentication keys…<br />
<br />
<a href="http://lh6.ggpht.com/-vnetlU-kTQo/UCstQuDQj7I/AAAAAAAABw0/4jsWQ1Lbrd0/s1600-h/image%25255B51%25255D.png"><img alt="image" border="0" height="386" src="http://lh6.ggpht.com/-rn55Ci33IQ8/UCstRAGGlQI/AAAAAAAABw8/pSj8oFpohvg/image_thumb%25255B30%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="624" /></a><br />
<br />
<a href="http://lh6.ggpht.com/-ZxQlwm3sZrA/UCstRb0ZOII/AAAAAAAABxA/zs7ZHulQ32U/s1600-h/image%25255B52%25255D.png"><img alt="image" border="0" height="200" src="http://lh6.ggpht.com/-ciwvATqjH5I/UCstR1QD90I/AAAAAAAABxM/wvaWAksLhGE/image_thumb%25255B31%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="624" /></a><br />
<br />
(which I neatly chopped out :) They’re required in my Tweet.java file, which requires an authenticated account to automate tweet posts:<br />
<h6>
<div style="background-color: white; color: #222222; font-family: Monaco; font-weight: normal; margin: 0px;">
<div style="margin: 0px;">
<span style="color: #991664;">package</span> com.liquidware.<wbr></wbr></div>
</div>
</h6>
<span style="font-size: xx-small;">networkedserial.app;
</span><br />
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"><span style="color: #991664;">import</span> android.os.AsyncTask;</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"><span style="color: #991664;">import</span> android.util.Log;</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"><span style="color: #991664;">import</span> twitter4j.Twitter;</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"><span style="color: #991664;">import</span> twitter4j.TwitterException;</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"><span style="color: #991664;">import</span> twitter4j.TwitterFactory;</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"><span style="color: #991664;">import</span> twitter4j.auth.AccessToken;</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="color: #991664; margin: 0px;">
<span style="font-size: xx-small;">public<span style="color: black;"> </span>class<span style="color: black;"> Tweet {</span></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">private</span> <span style="color: #991664;">static</span> <span style="color: #991664;">final</span> String <span style="color: #132bc3;">TAG</span> = <span style="color: #4239f5;">"Tweet"</span>;</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>/** Name to store the users access token */</span></div>
<div style="color: #4239f5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span><span style="color: #991664;">private</span><span style="color: black;"> </span><span style="color: #991664;">static</span><span style="color: black;"> </span><span style="color: #991664;">final</span><span style="color: black;"> String </span><span style="color: #132bc3;">PREF_ACCESS_TOKEN</span><span style="color: black;"> =</span>"[***your key here***]"<span style="color: black;">;</span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>/** Name to store the users access token secret */</span></div>
<div style="color: #4239f5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span><span style="color: #991664;">private</span><span style="color: black;"> </span><span style="color: #991664;">static</span><span style="color: black;"> </span><span style="color: #991664;">final</span><span style="color: black;"> String </span><span style="color: #132bc3;">PREF_ACCESS_TOKEN_SECRET</span><span style="color: black;"> =</span>"
[***your key here***] "<span style="color: black;">;</span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>/** Consumer Key generated when you registered your <span style="text-decoration: underline;">app</span> at<a href="https://dev.twitter.com/apps/" style="color: #1155cc;" target="_blank">https://dev.twitter.com/apps/</a> */</span></div>
<div style="color: #4239f5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span><span style="color: #991664;">private</span><span style="color: black;"> </span><span style="color: #991664;">static</span><span style="color: black;"> </span><span style="color: #991664;">final</span><span style="color: black;"> String </span><span style="color: #132bc3;">CONSUMER_KEY</span><span style="color: black;"> =</span>"
[***your key here***] "<span style="color: black;">;</span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>/** Consumer Secret generated when you registered your <span style="text-decoration: underline;">app</span> at<a href="https://dev.twitter.com/apps/" style="color: #1155cc;" target="_blank">https://dev.twitter.com/apps/</a> */</span></div>
<div style="color: #4239f5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span><span style="color: #991664;">private</span><span style="color: black;"> </span><span style="color: #991664;">static</span><span style="color: black;"> </span><span style="color: #991664;">final</span><span style="color: black;"> String </span><span style="color: #132bc3;">CONSUMER_SECRET</span><span style="color: black;"> = </span>"
[***your key here***] "<span style="color: black;">; </span><span style="color: #439075;">//</span><span style="color: #8eb0c8;">XXX</span><span style="color: #439075;"> Encode in your </span><span style="color: #439075; text-decoration: underline;">app</span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>/** Twitter4j object */</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">private</span> <span style="color: #991664;">final</span> Twitter <span style="color: #132bc3;">mTwitter</span>;</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>/** Called when the activity is first created. */</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">public</span> Tweet(String message) {</span></div>
<div style="color: #4239f5; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> Log.i(</span><span style="color: #132bc3;">TAG</span><span style="color: black;">, </span>"Loading TweetToTwitterActivity"<span style="color: black;">);</span></span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="color: #439075; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>// Load the twitter4j helper</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #132bc3;">mTwitter</span> = <span style="color: #991664;">new</span> TwitterFactory().getInstance();</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> Log.i(<span style="color: #132bc3;">TAG</span>, <span style="color: #4239f5;">"Got Twitter4j"</span>);</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="color: #439075; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>// Tell twitter4j that we want to use it with our <span style="text-decoration: underline;">app</span></span></div>
<div style="color: #132bc3; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>mTwitter<span style="color: black;">.setOAuthConsumer(</span>CONSUMER_KEY<span style="color: black;">,</span>CONSUMER_SECRET<span style="color: black;">);</span></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> Log.i(<span style="color: #132bc3;">TAG</span>, <span style="color: #4239f5;">"Inflated Twitter4j"</span>);</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #439075;">//</span><span style="color: #439075; text-decoration: underline;">tweet</span></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">new</span> postMessage().execute(message);</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> }</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #4e77c5;">/**</span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"> * Login and <span style="text-decoration: underline;">tweet</span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"> */</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">public</span> <span style="color: #991664;">class</span> postMessage <span style="color: #991664;">extends</span> AsyncTask<string void="void"> {</string></span></div>
<div style="color: #777777; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>@Override</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">protected</span> Void doInBackground(String... message) {</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> loginAuthorisedUser();</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> tweetMessage(message[0]);</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">return</span> <span style="color: #991664;">null</span>;</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> }</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> }</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #4e77c5;">/**</span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"> * The user had previously given our <span style="text-decoration: underline;">app</span> permission to use Twitter<span style="color: #9293ac;"></span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"> * Therefore we retrieve these <span style="text-decoration: underline;">credentials</span> and fill out the Twitter4j helper</span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"> */</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">private</span> <span style="color: #991664;">void</span> loginAuthorisedUser() {</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> String token = <span style="color: #132bc3;">PREF_ACCESS_TOKEN</span>;</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> String secret = <span style="color: #132bc3;">PREF_ACCESS_TOKEN_SECRET</span>;</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="color: #439075; margin: 0px;">
<span style="font-size: xx-small;"><span style="color: black;"> </span>// Create the twitter access token from the <span style="text-decoration: underline;">credentials</span> we got previously</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> AccessToken at = <span style="color: #991664;">new</span> AccessToken(token, secret);</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #132bc3;">mTwitter</span>.setOAuthAccessToken(at);</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> Log.d(<span style="color: #132bc3;">TAG</span>, <span style="color: #4239f5;">"Welcome back user."</span>);</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> }</span></div>
<div style="margin: 0px; min-height: 15px;">
<span style="font-size: xx-small;"><br /></span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #4e77c5;">/**</span></span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"> * Send a <span style="text-decoration: underline;">tweet</span> on your <span style="text-decoration: underline;">timeline</span>, with a //Toast <span style="text-decoration: underline;">msg</span> for success or failure</span></div>
<div style="color: #4e77c5; margin: 0px;">
<span style="font-size: xx-small;"> */</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">private</span> <span style="color: #991664;">void</span> tweetMessage(String message) {</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #991664;">try</span> {</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> <span style="color: #132bc3;">mTwitter</span>.updateStatus(message);</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> Log.d(<span style="color: #132bc3;">TAG</span>, <span style="color: #4239f5;">"Tweet successful!"</span>);</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> } <span style="color: #991664;">catch</span> (TwitterException e) {</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> e.printStackTrace();</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> }</span></div>
<div style="margin: 0px;">
<span style="font-size: xx-small;"> }</span></div>
<div style="margin: 0px;">
}<br />
<br /></div>
Now Bruce is tweeting one of the above pre-programmed lines (borrowed from <a href="http://en.wikipedia.org/wiki/Finding_Nemo">Finding Nemo</a>)<br />
<br />
<a href="http://lh6.ggpht.com/-CkUm1O9PR8s/UCstSWHpExI/AAAAAAAABxU/nemjFdkoFVo/s1600-h/sshot-149%25255B4%25255D.jpg"><img alt="sshot-149" border="0" height="482" src="http://lh3.ggpht.com/-OURvKbNNh88/UCstSyC86lI/AAAAAAAABxg/BxTUkBKV_70/sshot-149_thumb%25255B2%25255D.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="sshot-149" width="435" /></a><br />
<strong><br /></strong>
<strong>Phone Perimeter Breach Alerts</strong><br />
<br />
From there, I just followed <a href="https://twitter.com/BruceSharkAlert">@BruceSharkAlert</a>, and since I have <a href="https://support.twitter.com/articles/14014">Twitter via SMS</a> already set up, all I had to do was text <a href="https://support.twitter.com/articles/20170024">40404</a> (my Twitter “<a href="https://support.twitter.com/articles/14226-how-to-find-your-twitter-short-code-or-long-code">short code</a>”) the command ON BruceSharkAlert. Now Bruce’s Tweets show up on my phone every time he breaks the laser line:<br />
<br />
<a href="http://lh6.ggpht.com/-NrGjPUDXYNs/UCstTf2Z-2I/AAAAAAAABxs/cpUKS0AC0R4/s1600-h/image%25255B55%25255D.png"><img alt="image" border="0" height="382" src="http://lh4.ggpht.com/-5o6AZhswFWk/UCstULBUwxI/AAAAAAAABx0/kyVkTRfnWAw/image_thumb%25255B32%25255D.png?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="336" /></a><br />
<br />
Mike gives us a little video walkthrough here:<br />
<br />
<center>
<iframe allowfullscreen="allowfullscreen" frameborder="0" height="349" src="http://www.youtube.com/embed/wHJpeQcUvSM" width="620"></iframe></center>
<br />
When my phone goes off, I like to tell people that my shark tweeted me. Anyway, that’s my tribute to Shark Week, but if I had more time, laser pointers, and light sensors, I’d probably set up a crazy grid defense system. Till next time…<br />
<br />
<a href="http://lh3.ggpht.com/-ZV8CeAb7_AU/UCstUi6l4aI/AAAAAAAABx8/jHYwHIKfk_I/s1600-h/IMG_0253%25255B4%25255D.jpg"><img alt="IMG_0253" border="0" height="349" src="http://lh6.ggpht.com/-pTq3JaFWoxk/UCstUzx7K_I/AAAAAAAAByA/Vjy-dn_Oq0g/IMG_0253_thumb%25255B1%25255D.jpg?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="IMG_0253" width="620" /></a><br />
<em><br /></em>
<em>What else could I use this for? Let me know in the comments, over email at <a href="mailto:justin@liquidware.com">justin@liquidware.com</a> or tweet me @liquidware</em>Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com5tag:blogger.com,1999:blog-7377057412446264720.post-12175878720299243312012-08-13T11:17:00.001-04:002012-09-17T10:35:34.838-04:00Recap: "Forever Sensor" at the RI Mini Maker Faire On Saturday, Rith and I loaded up the car, and took the 30 minute ride down to Providence, RI for the 4th <a href="http://makerfaireri.com/mini-maker-faire-ri-2012/2012-makers/?project=33" target="_blank">Rhode Island Mini Maker Faire</a>!<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://makerfaireri.com/mini-maker-faire-ri-2012/2012-makers/?project=33" target="_blank"><img border="0" height="212" src="http://1.bp.blogspot.com/-ESPOxsBGaFM/UCkITMI0IWI/AAAAAAAAHnY/ijmE1LWyBIU/s400/minimfCapture.JPG" width="400" /></a></div>
During the faire, I had chance to explain the concept of the <a href="http://antipastohw.blogspot.com/2012/08/what-project-should-i-do-today.html" target="_blank">mystery box</a>, and the <a href="http://antipastohw.blogspot.com/2012/08/how-to-build-diy-perpetually-powered.html" target="_blank">rooster call</a> it kept making. The younger and artistic audience really like the concept of a digital rooster, and the engineers truly appreciated the <a href="http://antipastohw.pbworks.com/w/page/56963892/Environmental%20Study" target="_blank">technical hurdles</a> or the <a href="http://antipastohw.blogspot.com/2012/08/how-to-build-diy-perpetually-powered.html" target="_blank">DIY perpetually-powered wireless environmental study project</a>.<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://www.liquidware.com/shop" target="_blank"><img border="0" height="218" src="http://1.bp.blogspot.com/-Sznv38lcBS4/UCkO7-Mph8I/AAAAAAAAHnw/4K5R7nT1-PE/s400/photo.JPG" width="400" /></a></div>
<br />
At first, the customized <a href="http://www.liquidware.com/shop/show/BB-AND-DIY/Android+DIY+Starter+Kit+" target="_blank">Android Tablet</a>, 2 deep cycle marine batteries, the <a href="http://www.liquidware.com/shop/show/ARD-UNO/Arduino+Uno" target="_blank">Arduino</a>, the <a href="http://www.liquidware.com/shop/show/SEN-LTE/AMBI+Light+Sensor" target="_blank">light sensor</a>, the <a href="http://www.liquidware.com/category/Sensors" target="_blank">temperature/ humidity sensor</a>, the solar panels and Pelican case seemed like overkill, but once I explained our reasons for the project, a lot of makers started having their own ideas on what they'd do with something like this.<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://www.liquidware.com/shop" target="_blank"><img border="0" height="400" src="http://1.bp.blogspot.com/-PVeXRhvf2nA/UCkOXP9FpfI/AAAAAAAAHno/ani9thsQOh8/s400/photo%282%29.JPG" width="400" /></a></div>
Personally, this was my first time back to the <a href="http://antipastohw.blogspot.com/2009/09/maker-faire-ri-recap.html" target="_blank">Providence Maker Faire since 2009</a>, but it was a lot of fun, and I can't wait for the <a href="http://makerfaire.com/newyork/2012/index.html" target="_blank">Maker Faire in New York</a>!Anonymoushttp://www.blogger.com/profile/00088046538094789826noreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-25218449451849971472012-08-09T21:11:00.001-04:002012-09-17T10:36:55.851-04:00How to build a DIY perpetually-powered wireless outpost<p><em>Earlier this week, I had a mystery box of electronics and was looking for something to do with it. Thanks to Bryan from New Zealand, who asked about creating a wireless farm monitoring outpost…</em></p> <p>The idea of a <a href="http://electronicdesign.com/article/power/energy-harvester-perpetually-powers-wireless-senso">perpetual power supply</a> comes up now and again, mostly in the context of a remote outpost. Naturally, the idea of creating <a href="http://research.microsoft.com/en-us/projects/mesh/">mesh networks</a> in the wild and digital <a href="http://en.wikipedia.org/wiki/Dead_drop">dead drops</a> appeal to my inner Bourne, but that’s a story for a different day.</p> <p><a href="http://lh3.ggpht.com/-yEj2d51MMVU/UCRfrj5UZdI/AAAAAAAABrI/nFFYSEjWwcg/s1600-h/image%25255B13%25255D.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-LbJW6YGuII8/UCRfsUuvDqI/AAAAAAAABrQ/cewx3lRN6ZY/image_thumb%25255B5%25255D.png?imgmax=800" width="600" height="528"></a></p> <p>This project is really broken out into two parts: the perpetual powering, and then doing something useful with the perpetual power.</p> <p><strong>Perpetual (Self-Replenishing) Power</strong></p> <p>I found a couple of Mike’s old boat motor batteries, along with some 12V solar panels we had here in the lab. Since the batteries were 24V, I put the solar panels in series. Some back of the envelope math, along with my handy voltmeter, suggested that the solar panels could charge the batteries at about 200 mAH outside in the sun. </p> <p>For the month of August, here in the Boston area, I get about <a href="http://astro.unl.edu/classaction/animations/coordsmotion/daylighthoursexplorer.html">13.5 hours of sunlight</a>. That means, each day, I’m storing about +2700 mA per day. </p> <p><a href="http://lh4.ggpht.com/-ncMCQ8nNCCI/UCRftMG_U_I/AAAAAAAABrY/UpIDz2TFyM8/s1600-h/image%25255B5%25255D.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-yMvsdKsQ2NE/UCRfth7OpiI/AAAAAAAABrg/gyFsdQOJKls/image_thumb%25255B1%25255D.png?imgmax=800" width="450" height="344"></a></p> <p>Testing the system that I have in the mystery box (which I’ll get to in a second), I’m burning a low of -75 mAH and a high of –150 mAH. It averages out to be about –100 mAH, or –2400 mA per day, for a net of +300 mA per day. </p> <p>The massive batteries ensure that things will keep going for a while, even if I’m wrong about how much sun is getting through, and if there happens to be an unexpected volcanic cloud over Boston that day.</p> <p><strong>The Mystery Box (a.k.a. awesome Pelican case o’ stuff)</strong></p> <p>I put the batteries in the box, along with a <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard xM</a>, <a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen">BeagleJuice 2nd Gen</a>, and <a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">BeagleTouch</a>, as well as a couple <a href="http://www.liquidware.com/shop/show/ARD-UNO/Arduino+Uno">Arduinos</a> to run sensors.</p> <p><a href="http://lh3.ggpht.com/-EKwEpfQ0UIw/UCRfuPXGpxI/AAAAAAAABro/RlZ54g-YBcU/s1600-h/image%25255B23%25255D.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-C7XD5c5MSYA/UCRfu1tA6jI/AAAAAAAABrw/yyNkifj_IwA/image_thumb%25255B11%25255D.png?imgmax=800" width="600" height="449"></a></p> <p><a href="http://lh5.ggpht.com/-0c_lko2CbQU/UCRfvaBbVhI/AAAAAAAABr4/nKLCcZXjYUM/s1600-h/Mystery%252520Box%25255B6%25255D.jpg"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="Mystery Box" border="0" alt="Mystery Box" src="http://lh3.ggpht.com/-cF8PZuq3TLQ/UCRfvgg4nHI/AAAAAAAABsA/yOe7-xpwWM4/Mystery%252520Box_thumb%25255B3%25255D.jpg?imgmax=800" width="600" height="348"></a></p> <p>The Pelican case itself is designed to be waterproof, although I hacked the neoprene o-ring in the front to run wires out of a single location. For testing purposes, I have a light sensor hooked up to the <a href="http://www.liquidware.com/shop/show/ARD-UNO/Arduino+Uno">Arduino</a>, and I have an AT&T 3G setup running from the <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard</a>, which is sharing that Internet connection over WiFi to create a wireless hotspot. (If you look carefully at the top, I stuffed a wireless router in there as well)</p> <p>There are three key links here, which each deserve a separate blog post complete with code: </p> <p><a href="http://antipastohw.blogspot.com/2010/04/introducing-ambi-ambient-light-sensor.html">Light Sensor to Arduino</a><br><a href="http://antipastohw.blogspot.com/2010/06/two-open-source-worlds-collide-using.html">Arduino with Sensor to BeagleBoard</a><br>BeagleBoard to 3G (I’ll write a blog about how to do this as well, but Dune made an <a href="http://freedune.wordpress.com/2011/06/23/success-with-usb-3g-modems-on-android/">excellent post</a>, which got me started)</p> <p>Towards the bottom, I also included a couple USB-powered speakers… (Oh the possibilities! :-)</p> <p><a href="http://lh4.ggpht.com/-a4GlL7qvkzE/UCRfwewOBNI/AAAAAAAABsI/hxRH0Xsf14Q/s1600-h/image%25255B8%25255D.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-yvNmKtXhW80/UCRfw42i6vI/AAAAAAAABsM/aVd8n90OePE/image_thumb%25255B2%25255D.png?imgmax=800" width="282" height="382"></a></p> <p>Matt helped me dig a hole in the ground to bury the case, and then we ran some of the wires through a PVC contraption we made to mount the solar panels and WiFi antenna. It’s not the neatest thing in the world, but it works. </p> <p><a href="http://lh4.ggpht.com/-Ex9MZNbeH48/UCRfx0CkDTI/AAAAAAAABsY/W9y2mdX70t4/s1600-h/image%25255B15%25255D.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-snievjb9T6Q/UCRfySnOa5I/AAAAAAAABsg/ku1i8vGgKmI/image_thumb%25255B7%25255D.png?imgmax=800" width="600" height="523"></a></p> <p>I’ve built a (mostly) perpetually-powered outpost, using a Pelican case, solar panels, some boat batteries, and an Android-powered BeagleBoard setup that converts a 3G cellular connection into a WiFi hotspot, all while logging and uploading sensor data. Now all I need is a coffee maker, and I’ll basically have Starbucks!</p> <p>Naturally Mike had a brilliant idea for a light sensor and speakers…after all, what farm outpost would be complete without a rooster’s cockadoodledoo every morning. So I present to you, Mike’s Digital Cock app :-)</p> <p> <center><iframe height="315" src="http://www.youtube.com/embed/_ZY_d-CL0t0" frameborder="0" width="560" allowfullscreen></iframe></center> <p>Next week, I’ll break out each piece of the project into distinct tutorials, especially the 3G cellular modem + <a href="http://antipastohw.blogspot.com/2010/10/android-hacked-onto-beagleboard-oshw.html">BeagleBoard + Android</a> component, which quite a few folks have been asking about.</p> <p><em>What would you do with a remote, perpetually-powered wireless outpost? I’m planning to save this one for Halloween to have a robotic, motion-detecting scarecrow…</em></p> <p><em>Post your thoughts to comments, or get a hold of me on twitter @liquidware, or over email at </em><a href="mailto:justin.huynh@liquidware.com"><em>justin.huynh@liquidware.com</em></a></p> Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com3tag:blogger.com,1999:blog-7377057412446264720.post-50135339580601168402012-08-08T21:13:00.001-04:002012-09-17T10:40:07.464-04:00Powering my Raspberry Pi with the BeagleJuice, 2nd Gen Battery<p>My <a href="http://www.raspberrypi.org/">Raspberry Pi</a> finally showed up today! Naturally, an unboxing event was in order…</p> <p><a href="http://lh5.ggpht.com/-jpCuYtrV0ek/UCMOlOclt8I/AAAAAAAABpk/Gqy1K-ot1W0/s1600-h/P1020679%25255B11%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="P1020679" border="0" alt="P1020679" src="http://lh3.ggpht.com/-h5fIE4wk1jw/UCMOldzS_gI/AAAAAAAABpo/EG2Oh7uDURk/P1020679_thumb%25255B8%25255D.jpg?imgmax=800" width="320" height="240"></a><a href="http://lh6.ggpht.com/-etr6bO9XusI/UCMOl0dzQ_I/AAAAAAAABps/wTQxvKE6Bb4/s1600-h/P1020680%25255B6%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="P1020680" border="0" alt="P1020680" src="http://lh4.ggpht.com/-v5s2wJ39NzU/UCMOmdfvEvI/AAAAAAAABpw/uTOdsF3yGkA/P1020680_thumb%25255B3%25255D.jpg?imgmax=800" width="320" height="240"></a><a href="http://lh4.ggpht.com/-BIQhPY7JDS8/UCMOm8cJTsI/AAAAAAAABp0/X7zAQ_SOiIg/s1600-h/P1020681%25255B6%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="P1020681" border="0" alt="P1020681" src="http://lh6.ggpht.com/-A4T50bKX4Ss/UCMOnRrlQwI/AAAAAAAABp4/UKsGO7I2ymY/P1020681_thumb%25255B3%25255D.jpg?imgmax=800" width="320" height="240"></a><a href="http://lh4.ggpht.com/-_uAHBCN4CCk/UCMOn4OxoHI/AAAAAAAABp8/xM5qpghXBz0/s1600-h/P1020682%25255B5%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="P1020682" border="0" alt="P1020682" src="http://lh4.ggpht.com/-rHTRSUoQEys/UCMOoMFsbVI/AAAAAAAABqA/wK56JvWIHfg/P1020682_thumb%25255B2%25255D.jpg?imgmax=800" width="320" height="240"></a></p> <p>I haven’t gotten around to setting up my SD card yet, but I just wanted to see if it would power on with the <a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen">BeagleJuice</a> sitting on my desk. In theory, it should work, since the BeagleJuice outputs 5V from each of the 2-pin molex connectors.</p> <p><a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-IFlS_1gtaic/UCMOogly6zI/AAAAAAAABqE/Ezf9XeBasdU/image%25255B34%25255D.png?imgmax=800" width="640" height="401"></a></p> <p>I took the micro USB cable that I spliced last week and plugged it into the Raspberry Pi…</p> <p><a href="http://lh4.ggpht.com/-UqrdOfnF5W0/UCMOpZ3HmSI/AAAAAAAABqI/urfxioNzpGU/s1600-h/image%25255B33%25255D.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-yQn29M5_k0Y/UCMOqBfmubI/AAAAAAAABqM/eWD_3LU0cTM/image_thumb%25255B17%25255D.png?imgmax=800" width="640" height="483"></a></p> <p>…then I connected the other end to the BeagleJuice.</p> <p><a href="http://lh3.ggpht.com/-BYGBnluVZ9I/UCMOq0qUMGI/AAAAAAAABqQ/SHo8uq3L3TI/s1600-h/image%25255B32%25255D.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/--kOhchHFoIo/UCMOrWi2ITI/AAAAAAAABqU/G4QGg3r5gqk/image_thumb%25255B16%25255D.png?imgmax=800" width="640" height="327"></a></p> <p>And voila! The Raspberry Pi powers on, as indicated by the red power LED next to the audio jack. Just for kicks, I plugged in the <a href="http://www.liquidware.com/shop/show/BBONE/BeagleBone">BeagleBone</a> to the BeagleJuice as well (with a 5V barrel jack) to make sure they both run simultaneously, and they do :-)</p> <p><a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-ciy4YQAsQiY/UCMOrwYaHiI/AAAAAAAABqY/ARpWh5yB5fo/image%25255B31%25255D.png?imgmax=800" width="640" height="500"></a></p> Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com1tag:blogger.com,1999:blog-7377057412446264720.post-61394372252946179302012-08-07T18:10:00.001-04:002012-09-17T10:41:05.043-04:00What project should I do today?<p>Chris and I were kicking around a few ideas on excuses to get out of the office and work on some interesting projects while we’re at it. I’ve personally gotten quite a few emails for some cool projects, so we decided to kill two birds with one stone.</p> <p>As a huge fan of <a href="http://revision3.com/tbhs">The Ben Heck Show</a>, as well as Ladyada’s <a href="http://www.adafruit.com/chat/">Ask an Engineer</a>, I thought some kind of interactive weekly Youtube show might be a fun experiment that could also get some local Boston makers involved as well. It also solves the $1,000,000,000 question (that I wake up to most mornings):</p> <p><strong>What project should I do today?</strong></p> <p>The first idea I had is something like an <a href="http://en.wikipedia.org/wiki/Iron_Chef">Iron Chef</a> but for electronics and hacking. There’s some set of secret “ingredients” inside a <a href="http://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&ved=0CEEQFjAA&url=http%3A%2F%2Fwww.ted.com%2Ftalks%2Fj_j_abrams_mystery_box.html&ei=zYwhUKLpPIXo0QHq_YFY&usg=AFQjCNFZ327SKH5Y8MuIFMWzwn4NI8YJMw&sig2=VKyHAIt--DV8WTnhY0yGjQ">mystery box</a>, and the challenge is to come up with some kind of project we can do with what’s inside. </p> <p><a href="http://lh5.ggpht.com/-netlCkYO2V0/UCGSaNM_dII/AAAAAAAABnQ/SFaopq4rth4/s1600-h/sshot-79%25255B8%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; margin-left: auto; border-top: 0px; margin-right: auto; border-right: 0px; padding-top: 0px" title="sshot-79" border="0" alt="sshot-79" src="http://lh4.ggpht.com/-wAfc6XH1ntc/UCGSakDwmdI/AAAAAAAABnY/4BRjwiBItEg/sshot-79_thumb%25255B6%25255D.jpg?imgmax=800" width="324" height="281"></a></p> <p>A twist on this would be to pull a random project suggestion from the virtual mailbag, and then try to make things work with what’s inside. So if there’s a project you’ve been stuck on, just wanted to see built, or you just think would make a good tutorial, post to comments, twitter me @liquidware, or send me an email at <a href="mailto:justin@liquidware.com">justin@liquidware.com</a></p> <p>Now it’s time to think of a good title for this show…</p> Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com2tag:blogger.com,1999:blog-7377057412446264720.post-41192930204095033082012-08-06T17:19:00.001-04:002012-09-17T10:52:05.784-04:00How to build a high-tech prototype faster than it takes to build a 30-story hotel<p>I stumbled across a video recently that I thought was pretty amazing. It’s a time-lapse video of a 30-story hotel that was <a href="http://www.ibtimes.com/articles/278275/20120107/30-story-building-built-15-days-china.htm">built in 15 days</a>.</p> <p> <center><iframe height="281" src="http://www.youtube.com/embed/Hdpf-MQM9vY" frameborder="0" width="500" allowfullscreen></iframe></center><em></em></p> <p><em></em></p> <p>Mind you, this wasn’t a shoddy structure. It’s designed to withstand a 9.0 earthquake, along cutting-edge energy efficiency features. How’d they do it? (The longer story from Businessweek is <a href="http://www.businessweek.com/articles/2012-04-12/how-to-build-a-30-story-hotel-in-15-days-juliet-jiang">here</a>)</p> <blockquote> <p><em>We make 93 percent of the building in our factory. The basic block, a “main board,” is 3.9 meters by 15.6 meters (12.8 feet by 51.2 feet) and includes everything from water pipes and ventilation shafts down to floor tiles, lights, even toilets and the kitchen sink.</em></p></blockquote> <p>Building blocks. The principles of “prefabrication”, or <a href="http://en.wikipedia.org/wiki/Prefabrication">prefab</a>, for short, have been around for a while now, especially in the realm of architecture and construction. This project just took it to a whole new level. Everything in the building was modularized, trucked out, and assembled. These blocks were strategically unfinished, designed to be connected to other blocks to form the completed structure.</p> <p><strong>What can hardware and embedded systems design learn from this?</strong></p> <p>The modular hardware ecosystem has continued to grown, becoming more accessible to an ever-expanding base of developers. With the <a href="http://arduino.cc/">Arduino</a>, <a href="http://www.raspberrypi.org/">Raspberry Pi</a>, <a href="http://beagleboard.org/bone/">BeagleBone</a>, <a href="http://beagleboard.org/">BeagleBoard</a>, and others, there’s an incredible amount of processing capability out there, in an easy to integrate, easy to program, modular form factor.</p> <p><a href="http://lh3.ggpht.com/-Z_xMFUB6BvY/UCA06T0Rg7I/AAAAAAAABmo/s3jZ7MWHSsw/s1600-h/image%25255B8%25255D.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; margin-left: auto; border-top: 0px; margin-right: auto; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-IutdeBuIRH4/UCA068UgZiI/AAAAAAAABmw/mwR_W66x_fw/image_thumb%25255B6%25255D.png?imgmax=800" width="334" height="293"></a></p> <p>Prefabbed building blocks exist for the Arduino in the form of <a href="http://www.liquidware.com/category/Arduino">shields</a>, BeagleBone in the form of <a href="http://circuitco.com/support/index.php?title=BeagleBone_Capes">capes</a>, and the BeagleBoard in the form of <a href="http://www.liquidware.com/category/Embedded">modules</a>. These all make the integration process extremely low overhead – with hot-swappable operating systems bootable from removable media.</p> <p><a href="http://www.liquidware.com/shop/show/BB-AND-DIY/Android+DIY+Starter+Kit+"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; margin-left: auto; border-top: 0px; margin-right: auto; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-PQKXdANP8K0/UCA07Uj2W_I/AAAAAAAABm4/stGX6YZUIt0/image%25255B14%25255D.png?imgmax=800" width="369" height="312"></a></p> <p>David Blaza, Vice President of UBM Electronics (the wonderful folks who bring us the Embedded Systems Conference and EETimes) recapped this <a href="http://www.eetimes.com/electronics-blogs/techtropolis/4375405/-A-new-way-to-design-and-build-electronics-">growing trend in development</a>. Interestingly, it doesn’t even have to happen in this particular order anymore…and just about anyone can do it:</p> <p><strong>1) Outline the concept (5-10 hours). </strong>A lot of startups, entrepreneurs, hobbyists, and engineers already have this part nailed down really well. Napkin sketches or Visio flowcharts, the concept is something that comes naturally to inventive minds. It’s just useful to whittle down features and ideas to focus the very first prototype. </p> <p><strong>2) Raise financing – or not (2-3 hours to craft and setup a campaign).</strong> This is an optional step these days, but crowdfunding sites <a href="http://www.kickstarter.com/">Kickstarter</a> and <a href="http://www.indiegogo.com/">Indiegogo</a>, or peer-to-peer financing sites like <a href="http://www.prosper.com/">Prosper</a> provide an easy, accessible way for individuals to raise money and publicize their projects on the cheap.</p> <p><strong>3) Pick a hardware platform (3 hours).</strong> For me, it’s typically come down to a couple main hardware drivers. If I need <a href="http://www.liquidware.com/category/Sensors">analog sensors</a>, I’m probably going to involve an <a href="http://www.liquidware.com/shop/show/ARD-UNO/Arduino+Uno">Arduino</a> along the way. Then it’s a question of what screen size (<a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">4.3-inch</a> or <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">7-inch</a> are common) I’ll need, CPU speed, and connectivity. If I know it’s going to be fairly integrated (as all the folks asking for a custom tablet are aware), I’ve usually selected something like the <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Liquidware Amber</a>.</p> <p><strong>4) Pick a software platform (3 hours).</strong> Linux or <a href="http://www.xda-developers.com/">Android</a>? Being more open than other operating systems, it’s a little easier to get a stack going and piggyback off code, kernels and drivers that are out there. </p> <p><strong>5) Buy it (1-3 days). </strong>First I usually buy the mainboard (like a <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard</a> or <a href="http://www.liquidware.com/shop/show/BB-PND/PandaBoard">Pandaboard</a>), along with any complementary modules I’ll need for that platform. It’s worth doing a little planning ahead to buy some spare cables, too, since there’s nothing more frustrating than sitting around with hardware, and not having that USB or HDMI micro cable to test things out.</p> <p><strong>6) Build it (5 days).</strong> Hardware “assembly” should be fairly straightforward, with clear, standardized pinouts (as attested to by the Arduino pin-spacing hullabahoo of <a href="http://forums.adafruit.com/viewtopic.php?f=25&t=13666">late 2009</a>). I find that USB is pretty versatile and ideal for easy connectivity, but that’s the subject of a different post. </p> <p>If all goes well, assembling the hardware should be a 1-2 hour activity – max! Getting the OS running the way you want it to shouldn’t take too long, but it depends on how customized your kernel has to be.</p> <p>Then it’s time to develop the app. Bringing out data over serial is a favorite activity (Android Ambrosia tutorial <a href="http://antipastohw.pbworks.com/w/page/41729078/How-to%20use%20a%20serial%20port%20with%20Android,%20Liquidware%20Ambrosia%20edition">here</a>), as is building a GUI. Adobe AIR is also excellent for <a href="http://antipastohw.blogspot.com/2012/07/how-to-read-arduino-sensors-with-adobe.html">simulating application mockups</a> for a presentation.</p> <p><strong>7) Tell the world (4 hours).</strong> Ready for the big screen? Like Step 1, this final step comes naturally to most entrepreneurs – between blogging, emailing well-connected folks, posting to Twitter and Facebook, the <a href="http://blog.guykawasaki.com/#axzz22nrJlVMt">evangelizing</a> is usually everyone’s favorite part.</p> <p>Building a complex prototype has never been easier or more accessible. What’s your experience with modular development? Post thoughts and questions to comments, or just email me at justin dot huynh at liquidware dot com</p> Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-49539494824333570412012-08-03T10:19:00.001-04:002012-09-17T10:53:18.564-04:003 Useful Things to Know about the BeagleJuice, 2nd Gen<p><em>I got a few very good questions about the <a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen">BeagleJuice, 2nd Gen</a> from earlier <a href="http://antipastohw.blogspot.com/2012/07/introducing-beaglejuice-2nd-generation.html">this week</a>, so I thought I’d answer them in post form.</em></p> <p><strong>What are the specs on the I2C pins on the BeagleJuice?</strong></p> <p>The I2C pins (GND, Vext, SDA, and SCL) are exposed for custom headers or wiring. After bugging Chris several times, he decided to just draw me a schematic instead. The range of operation is 1.8V to 3.3V. Currently, there are drivers coded for Android/Linux and OMAP, but it could be hacked to anything that talks I2C.</p> <p><a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="BeagleJuice2 I2C Diagram" border="0" alt="BeagleJuice2 I2C Diagram" src="http://lh6.ggpht.com/-J-t1PXpPjPo/UBvdyeb9tXI/AAAAAAAABkw/Snx6QJIJzyI/BeagleJuice2-I2C-Diagram7.jpg?imgmax=800" width="543" height="304"></a></p> <p><strong>What else can I power with the BeagleJuice?</strong></p> <p>The BeagleJuice comes standard with the 2.1mm barrel plug, which works just fine with the 5V barrel jacks on the <a href="http://www.liquidware.com/shop/show/ARD-UNO/Arduino+Uno">Arduino</a>, BeagleBoard <a href="http://www.liquidware.com/shop/show/BB-C4/BeagleBoard+C4">C5</a> and <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">xM</a>, <a href="http://www.liquidware.com/shop/show/BB-PND/PandaBoard">PandaBoard</a>, as well as the <a href="http://www.liquidware.com/shop/show/BBONE/BeagleBone">BeagleBone</a>.</p> <p><a href="http://lh5.ggpht.com/-LPIjDysBuS0/UBvdzKsd8fI/AAAAAAAABk4/hvFM9L4YxdI/s1600-h/image7.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-z9TEB4h41dU/UBvd0O8GwGI/AAAAAAAABlA/AgKwM7mqs3M/image_thumb5.png?imgmax=800" width="538" height="376"></a></p> <p>That said, it is in fact just a 2-pin molex connector at the end, so Matt spliced up his own USB micro cable, put some heat-shrink on the tip, and voila! The BeagleJuice now charges anything that takes 5V – my phone, or even the <a href="http://www.raspberrypi.org/">Raspberry Pi</a> (when mine finally arrives!).</p> <p><strong>What’s with the strips of LEDs?</strong></p> <p>Aside from the fact that LEDs are always fun, they actually serve a purpose. </p> <p><a href="http://lh3.ggpht.com/-wrT_r8DZ22E/UBvd09qsYlI/AAAAAAAABlI/lyYcXZg1XbU/s1600-h/image6.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-25K1M7M5FYQ/UBvd1SmaKiI/AAAAAAAABlQ/dl_naSlOkc0/image_thumb3.png?imgmax=800" width="543" height="320"></a></p> <p>The ones on the left are battery charge status indicators, which were inspired by Chris’ Macbook Pro battery meter. (Sorry the picture is a little blurry – I tried to catch it as the lights were moving up!)</p> <p><a href="http://lh3.ggpht.com/-001zCZySQfs/UBvd1zdgNZI/AAAAAAAABl8/bwprzQAw-vQ/s1600-h/image%25255B11%25255D.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; margin-left: auto; border-top: 0px; margin-right: auto; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-BFpagkl4330/UBvd2syuBdI/AAAAAAAABmA/P-nzA7a7bag/image_thumb%25255B6%25255D.png?imgmax=800" width="283" height="294"></a><a href="http://lh6.ggpht.com/-iGd7hc_W7As/UBvd3DwiOPI/AAAAAAAABlo/_gvCnkpAAPU/s1600-h/image%25255B10%25255D.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; margin-left: auto; border-top: 0px; margin-right: auto; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-4gMQvZWn154/UBvd3pKWqPI/AAAAAAAABlw/IIZIkCHUrvk/image_thumb%25255B5%25255D.png?imgmax=800" width="284" height="240"></a></p> <p><em>There are a couple more “easter eggs” on the BeagleJuice, 2nd Gen – mostly holdovers from things Chris, Mike and I were working on here at the lab. Post your thoughts or guesses to the comments, or just send me a note – justin dot huynh at liquidware dot com</em></p> Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-74800162194937336722012-07-30T22:35:00.001-04:002012-09-17T10:54:53.338-04:00Introducing the BeagleJuice, 2nd Generation: Laptop-Grade Power Management for the BeagleBoard<em><a href="http://antipastohw.blogspot.com/2012/07/3-portable-power-management-systems-for.html">Last week</a>, I took a trip through some of the battery boards and power management systems we created for the <a href="http://www.liquidware.com/category/Arduino">Arduino</a>, <a href="http://www.liquidware.com/category/Embedded">BeagleBoard</a> and <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Amber</a>. The development of the 2nd generation BeagleJuice was inspired mostly by requests for a “standalone Amber backpack”.</em><br />
<a href="http://lh3.ggpht.com/-sYemYCr_7bg/UBdEYdqOgkI/AAAAAAAABjk/OA3fPBKD-dM/s1600-h/image%25255B28%25255D.png"><img alt="image" border="0" height="297" src="http://lh3.ggpht.com/-S0p2f6tKTbM/UBdEY6J8rQI/AAAAAAAABjs/eZmzkfyExOg/image_thumb%25255B18%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="306" /></a><br />
Sort of…I took a little artistic license with the picture above! The <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Liquidware Amber</a> power supply and <a href="http://www.liquidware.com/shop/show/BB-BJ2/BeagleJuice%2C+2nd+Gen">BeagleJuice, 2nd Gen</a> were both built with advanced power management principles in mind.<br />
<br />
<i>(Edit: I got a few questions about this - the BeagleJuice, 2nd Gen comes with the standard 5V barrel jack cable to charge any 5V device that fits the jack, like the <a href="http://www.liquidware.com/shop/show/BBONE/BeagleBone">BeagleBone</a> or <a href="http://www.liquidware.com/shop/show/BB-PND/PandaBoard">PandaBoard</a>. For the adventurous, it's not a huge stretch to wire your own cable to the 2-pin Molex connector...)</i><br />
<br />
The 2nd Generation BeagleJuice is a modern, laptop-grade power supply that implements smart charging technology to manage multiple cells in series to deliver higher charge capacity, as well as high-power output. It’s optimized for 2-cell, 3-cell, and 6-cell configurations to deliver 2800, 4200, or 8400 mAh of capacity.<br />
<a href="http://lh6.ggpht.com/-hdta8_C7q1c/UBdEZVCBt2I/AAAAAAAABj0/PgBtywRCs0c/s1600-h/image%25255B16%25255D.png"><img alt="image" border="0" height="296" src="http://lh6.ggpht.com/-PJBTmKQgTc0/UBdEZyknl9I/AAAAAAAABj8/13H4KORej3Y/image_thumb%25255B10%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="334" /></a><br />
Onboard LEDs provide multiple status readouts as well as charge information. Advanced features can be accessed over I2C pins directly, or via a Zero Insertion Force (ZIF) ribbon connector. Here at the lab, I’ve used the 2nd Gen BeagleJuice as a primary power supply for several <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard</a> units concurrently – which centralizes the power management system for remote installation clusters. The high-capacity BeagleJuice provides quad 5V outputs via discrete 2-pin Molex connectors. <br />
<a href="http://lh5.ggpht.com/-XLZ92zNkB5U/UBdEaZ9ANsI/AAAAAAAABkE/VlCW4R8gldg/s1600-h/image%25255B17%25255D.png"><img alt="image" border="0" height="327" src="http://lh4.ggpht.com/-K0YSLAcpQWU/UBdEanO6mtI/AAAAAAAABkM/71pL686Jjow/image_thumb%25255B11%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="371" /></a> <br />
I’ll cover some details on charging cycles in the next blog, but in addition to smart charging and power input management, the heavy-duty power supplies that the BeagleJuice is modeled after also focus on being fault tolerant and providing an added measure of battery preservation. This “safety” logic protects the battery from:<br />
<ul>
<li>over current charge/discharge</li>
<li>over temperature charge/discharge</li>
<li>over voltage charge/discharge</li>
<li>cell charge/discharge imbalances</li>
</ul>
While no system is perfect, taking these issues into consideration is a big step closer to advanced power management and portable power supplies, useful for hobbyist and embedded prototyping projects with the BeagleBoard alike. Since the BeagleJuice, 2nd Gen comes with 2 5V barrel jacks connectors, it can actually power the <a href="http://www.liquidware.com/shop/show/BB-PND/PandaBoard">PandaBoard</a> and <a href="http://www.liquidware.com/category/Arduino">Arduino</a>, as well as my phone with a custom-spliced USB connector. Here’s a quick shot of the new BeagleJuice in action:<br />
<center>
<iframe allowfullscreen="" frameborder="0" height="253" src="http://www.youtube.com/embed/aobklEGVFwM" style="height: 326px; width: 513px;" width="450"></iframe></center>
<em>This is Part 2 of 3 on portable power management for prototyping embedded systems. The next post will walk through some of the charging algorithms and explain some of the complexity around charge management ICs - justin dot huynh at liquidware dot com</em>Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com6tag:blogger.com,1999:blog-7377057412446264720.post-50085823672755518142012-07-27T15:06:00.001-04:002012-09-17T10:56:36.707-04:003 Portable Power Management Systems For Development and Prototyping<em>This post came about when we asked </em><em>Keith </em><em>about the difference between the battery setups we had, and whether it was possible to pull the Amber battery pack off, and use it for other things. [Cue flashback music…]</em><br />
<strong>Lithium Backpack for Arduino</strong><br />
About <a href="http://antipastohw.blogspot.com/2008/05/lithium-backpack-charging-it.html">4 years ago</a>, we started with the basics of power management: the <a href="http://www.liquidware.com/shop/show/MBP/Lithium+Backpack">Lithium Backpack</a>. For that, it was mostly around <a href="http://antipastohw.blogspot.com/2008/06/how-to-install-lithium-backpack-to-your.html">form factor and simplicity</a>, which was great since the <a href="http://www.arduino.cc/">Arduino</a> has both analog and digital capabilities. If it let me take my Arduino project around, I was happy. A single-cell system, it had 4 pins - +5V, +3v3, GND, and Status. Really, the only two that mattered was my positive and my ground. Simple.<br />
<img height="213" src="http://1.bp.blogspot.com/_k3fkObxktAc/SGBz2oFU-lI/AAAAAAAAAFk/rJJN1CUx7uU/s400/P1010823.JPG" style="display: block; float: none; margin-left: auto; margin-right: auto;" width="291" /><br />
<strong>BeagleJuice for BeagleBoard</strong><br />
So when we started working with the <a href="http://www.liquidware.com/shop/show/BB-XM/BeagleBoard+xM">BeagleBoard</a>, we started with the same concept: a “shield” type battery for the <a href="http://beagleboard.org/">BeagleBoard platform</a>. Just a little more heavy-duty, since the BeagleBoard is an embedded computer in its own right, and much like <a href="http://en.wikipedia.org/wiki/HTC_Evo_4G">my smartphone</a>, will run out of juice pretty quickly.<br />
<img border="0" height="286" src="http://www.liquidware.com/system/0000/3226/BeagleJuice_with_Power_Plug.jpg" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" width="270" /><br />
Nevertheless, the <a href="http://www.liquidware.com/shop/show/BB-BJC/BeagleJuice">BeagleJuice</a> idea was simple – single-cell battery, charging, mounting standoffs, USB-mini trickle charge capability, and an on-off switch. That was 2 years ago.<br />
<strong>Laptop Power Management and the Liquidware Amber</strong><br />
In the meantime, a few projects came along where we really had to wrap our heads around portable power supplies, power management for mobile devices, and the like. Thinking about products with lifecycles of 5 years or more also means that we had to consider things like battery longevity and smart charging cycles.<br />
This was a whole new ball game for us, so we started by taking a look at how consumer laptop batteries are put together. Chris’ old Sony laptop became the sacrificial lamb: <br />
<img align="left" height="181" src="http://batteries-store.com.au/images/largebattery/VGP-BPS13AS.jpg" style="display: inline; float: left;" width="269" /><br />
<a href="http://lh4.ggpht.com/-V4ej9mSl6GA/UBMRBd2bSeI/AAAAAAAABi8/X5G81lp0kVk/s1600-h/CIMG9938%25255B6%25255D.jpg"><img alt="CIMG9938" border="0" height="207" src="http://lh3.ggpht.com/-VhYozMpYyr8/UBMRBmOZHAI/AAAAAAAABjE/Q7CpPm4oowI/CIMG9938_thumb%25255B3%25255D.jpg?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="CIMG9938" width="260" /></a><a href="http://lh4.ggpht.com/-RwH9Yh4o3gY/UBLmyChB1II/AAAAAAAABiQ/mK_gd4oKxOg/s1600-h/CIMG99366.jpg"><img alt="CIMG9936" border="0" height="384" src="http://lh5.ggpht.com/-FgYBdQ3_X5M/UBLmyj5gwMI/AAAAAAAABiY/oI2nPyaP1r4/CIMG9936_thumb3.jpg?imgmax=800" style="background-image: none; border-bottom-width: 0px; border-left-width: 0px; border-right-width: 0px; border-top-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="CIMG9936" width="494" /></a><a href="http://lh4.ggpht.com/-qv7tfoamGDE/UBMRCVNLqzI/AAAAAAAABjM/Mc0xb4J7LcY/s1600-h/image%25255B8%25255D.png"><img alt="image" border="0" height="260" src="http://lh5.ggpht.com/-0Ko1m9ZIC60/UBMRC-SeHLI/AAAAAAAABjQ/nA_ftMe9iTo/image_thumb%25255B6%25255D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="494" /></a><br />
No big surprise – a PCB controller was attached to 6 rechargeable Lithium-ion battery cells. The real fun was in understanding the power management ICs on board, how they communicated with the computer, and what other information was being provided, since the battery pack had quite a few more pins than our original lithium backpack did!<br />
<img height="323" src="http://www.liquidware.com/system/0000/5369/Amber_04_medium.jpg" style="display: block; float: none; margin-left: auto; margin-right: auto;" width="442" />One of the big takeaways was that we needed to use some more complex power management units in order to provide the complex battery systems people were used to using with laptops and robust embedded systems. So for the <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Liquidware Amber</a>, we incorporated laptop power management circuitry, which enabled multiple cells in series to provide higher charge capacity as well as high-power output (the Liquidware Amber battery pack delivers 5V at up to 4A for an extended period of time). What does this mean for functionality? A lot of charge and discharge management algorithms that go on behind the scenes, but also the ability to read out current, temperature, and voltage status to the display – something we take for granted on most modern devices, but actually involves quite a bit more complexity than strapping some rechargeable batteries to a board!<br />
<em>This is the first post in a three-part series on portable power management. In the next one, I’ll discuss the specific features and algorithms we considered in building a laptop power management system, and answer Keith’s original question about a standalone Amber battery. Questions, thoughts or projects – email me directly: justin dot huynh at liquidware dot com.</em>Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-17262797612527826992012-07-19T20:20:00.001-04:002012-09-17T10:57:43.432-04:005 Reasons to Use a Custom Android Tablet<p>There’s two sides to every coin. In the <a href="http://antipastohw.blogspot.com/2012/07/5-reasons-to-customize-ipad-or-samsung.html">last post</a>, I talked about instances where I usually recommend that people use an off-the-shelf tablet or smartphone device for their custom applications. The primary principle being keeping things simple, I recommend developing portable apps wherever possible, and avoiding potentially time and cost intensive hardware turns and development. But sometimes a custom (Android) tablet is required, and it’s worth knowing when to recognize these instances, and follow the path of least resistance. </p> <p>It’s why the <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Liquidware Amber</a> exists. We designed it for internal use, and use in engineering projects. It saved us a ton of time having that extra level of hardware and firmware customization, without having to start from scratch each time.<img style="display: block; float: none; margin-left: auto; margin-right: auto" title="Liquidware Amber - Back" alt="" src="http://www.liquidware.com/system/0000/5369/Amber_04_medium.jpg" width="450" height="323"></p> <p><strong>1) Sensor specificity and connection interface.</strong> In many cases, the end device is driven as much by the sensor as it is by the display. For example, a tablet may serve as the human-machine interface for a medical diagnostic device, but the sensor that is attached to it could be highly complex. Or the sensor required talks over a very specific protocol, such as I2C or SPI.</p> <p><img style="display: block; float: none; margin-left: auto; margin-right: auto" src="http://www.cardiacscience.com/assets/002/5116_600w600h.jpg" width="450" height="365"></p> <p><strong>2) Custom hardware feature set.</strong> In many cases, the product calls for integrating more than just sensors to tablet HMI. Kiosks, industrial control terminals, and other large scale machinery come to mind. Nevertheless, the tablet portion doesn’t need to be built from scratch, and a custom tablet like the Amber allows for tight systems integration over several different interfaces.</p> <p><strong>3) Supply chain management with high volume.</strong> Designing a product to be deployed in volume brings other considerations into play. Considering that most consumer devices are built to be sold within a 24-month lifecycle or less, since they’re designed with obsolescence and upgrade paths in mind, the supply chain of these devices can be fickle. This means that in order to incorporate an off-the-shelf device into a product design, it’s probably a good idea to consider buying all the units you think you might need. Upfront. Which can translate to a pretty significant capital investment. A custom tablet enables tight control over the hardware manufacturing, and ensures longevity of the product, to maximize the value of upfront engineering, design, and systems integration work.</p> <p><strong>4) Custom OS and firmware.</strong> If the product is going to require highly customized kernels and special firmware that allows the tablet to integrate with other components of the device, it’s not exactly efficient to root and re-load a custom ROM/kernels on each individual unit. And voiding any sort of warranty in the process.</p> <p><strong>5) Security.</strong> The other (somewhat unexpected) driver of custom hardware requirements has actually been one of security. Understanding exactly what is going into a particular device and having control over all layers of software can help make the device less transparent and less vulnerable than stock devices currently available. For instance, a custom Android tablet include any manufacturer software, and doesn’t have GPS (if you don’t want it) so you’re not inadvertently broadcasting information that you don’t want released.</p> <p>There are many other considerations, such as form factor and branding, that just might tip the scales in favor of using a custom Android tablet. And as with big questions in embedded systems development, the answers aren’t always obvious. </p> <p>So if you’re on the fence about which way to take your custom tablet project, feel free to comment below, or get in touch – justin dot huynh at liquidware dot com.</p> Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-16414590303991211502012-07-18T14:58:00.001-04:002012-09-17T10:58:32.988-04:005 Reasons to Customize an iPad (or Samsung Galaxy, or any off-the-shelf Android tablet)<p>Since the <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Liquidware Amber</a> officially launched <a href="http://antipastohw.blogspot.com/2012/05/introducing-liquidware-amber.html">back in May</a>, I’ve gotten a few more questions about tablets, that usually go along the lines of:</p> <p>“<em>I’m building a special application for [my company]…can I just use an iPad/Galaxy/off-the-shelf tablet? Or should I use the Amber?</em>”</p> <p>As much as I could be self-serving in answering that question (mwahahaha!), the real answer is that it depends. The more targeted question to ask is:</p> <p><em>“If I just build an Android or iOS</em><em> app, without hardware accessories, does it get the job done?”</em></p> <p>There’s a bit of a gray area, and a lot of instances where you really could go one way or the other. But my take boils down to the fact that, if you can avoid building custom hardware, I’d recommend that. But if there’s no way around it, it’s usually worth putting in some effort to make the path as quick and painless as possible.</p> <p>Embedded development can typically be broken down into three levels:</p> <p><strong>Application Level. </strong>The front-end. Anything that can be downloaded on Apple’s App Store, or <a href="https://play.google.com/store?hl=en">Google Play</a>. This is anything that the end-user will interact with, and also constitutes <a href="http://developer.android.com/guide/topics/security/permissions.html">permissions</a> and access to resources within the OS and hardware. </p> <p><strong>Operating System Level. </strong>This involves kernels and <a href="http://www.cyanogenmod.com/">ROMs</a> that provide access to functionality on a piece of hardware. With Android on consumer devices, this usually includes <a href="http://lifehacker.com/5789397/the-always-up+to+date-guide-to-rooting-any-android-phone">rooting</a> the device, then adding functionality or removing OEM restrictions on the hardware.</p> <p><strong>Hardware Level.</strong> On one end of the spectrum, this entails something as “simple” as an accessory device, like <a href="https://squareup.com/card-reader">Square</a>’s credit card reader:</p> <p><a href="http://lh4.ggpht.com/-DSzeqiQmb8I/UAcHW9INsnI/AAAAAAAABhE/07QT9fkUKcw/s1600-h/image3.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-v3NFvdh0pp4/UAcHYi7o5VI/AAAAAAAABhM/5k60wf9iIjY/image_thumb1.png?imgmax=800" width="114" height="240"></a></p> <p>That said, not all accessories are made equal, and when added functionality, higher bandwidth, and larger amounts of data are required, the accessories become increasingly complex. (A common theme is the analog-sensor-to-Android-device project, which gets the Arduino and Amber/Android involved…subject of an upcoming blog post!) The more complex the accessory, the more likely it is to require OS level tweaks as well.</p> <p><strong>When to use an off-the-shelf tablet:</strong></p> <p>When it comes to custom applications, I typically recommend Android because of the simplicity in pushing down your own custom .apk file. The off-the-shelf tablet is ideal when…</p> <p><strong>1) Stock permissions are adequate. </strong>If the front-end app can be built without running into OS-level obstacles, that’s a great first sign that maybe going with a portable app that can be run on any consumer device is the way to go.</p> <p><strong>2) Low-complexity hardware accessories. </strong>Similarly, if power and data transfer to the device is simple, it may be easiest to use an existing interface – in most cases, Apple’s <a href="http://pinouts.ru/PortableDevices/ipod_pinout.shtml">30-pin</a> (soon to be <a href="http://techcrunch.com/2012/06/20/confirmed-the-new-iphone-will-have-a-19-pin-mini-connector/">19-pin</a>?) docking connector, or the micro USB OTG on Android devices. As soon as higher data rates are needed, level shifters come into play and you want to start transmitting across SPI, I2C, and have a million uses for various GPIO…it’s not a bad idea to think about a custom device.</p> <p><strong>3) Low volume/high speed deployment. </strong>If an extremely quick turn is required (say, a weekend-ish) for a prototype solution, and the deployment is pretty limited, supply chain and manufacturing concerns are just going to get in the way. Get an unlocked device and make modifications. There’s no time to burn sifting through custom specifications on potential hardware options. A device in the field is worth a hundred on paper, even if it’s not quite perfect. (One of my personal heroes, <a href="http://www.guykawasaki.com/">Guy Kawasaki</a>, is <a href="http://blog.paylane.com/interview-with-guy-kawasaki">big on this</a>.)</p> <p><strong>4) Minor OS Tweaking. </strong>In many cases, it’ll be necessary to root a device, and flash a custom Android ROM or kernel. For a few units, it’s not too big a deal, especially if you have some strong Android coders to navigate the low level, or maybe some skilled developers have already taken care of the <a href="http://forum.xda-developers.com/">heavy lifting</a>. Even better if you can get the devices “pre-rooted” or loaded with your custom version of Android.</p> <p><strong>5) Low-cost Networking/Battery. </strong>This weighs in quite heavily for mobile applications that meet all of the above. Aside from the CPU and display, WiFi/Bluetooth/3G/4G and good power management systems drive significant cost in any embedded device, especially in a compact package. Customizing an off-the-shelf device for these purposes takes advantage of the economies of scale of consumer products, and in some cases, subsidies from from cellular providers.</p> <p><strong>Bonus: Branding. </strong>This one has typically been a dealbreaker for many companies based on preference. Sometimes it doesn’t matter if the user knows that this is an off the shelf device, or that it’s running an OS behind the app, but this factor alone has driven teams to search for a fully customizable device.</p> <p><em>Stay tuned for Part II on when a custom Android tablet might just fit the bill. In the meantime, if you’re not sure about your project, or want to share your experience, feel free to comment below or email me: justin dot huynh at liquidware dot com.</em></p> Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-23902249489720900192012-07-13T16:02:00.002-04:002012-09-17T11:00:36.840-04:00How to read Arduino sensors with Adobe AIR Flex on Android<br />
<div class="MsoNormal">
Android now supports Adobe AIR / Flex apps. The main benefit to using Flex over Java is that it specifically facilitates rapid story boarding of mobile user experiences. Coding Adobe Flex is similar to the Visual Basic observer design pattern of push-based actions. Add a button, right click to edit the action.</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://www.michelletchin.net/images/ux-thesis-mockup.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="239" id="il_fi" src="http://www.michelletchin.net/images/ux-thesis-mockup.jpg" style="padding-bottom: 8px; padding-right: 8px; padding-top: 8px;" width="320" /></a></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
I decided to show how one could access the serial port using the <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Amber</a> Android handheld, <a href="http://www.liquidware.com/shop/show/ARD-UNO/Arduino+Uno">Arduino</a>, <a href="http://www.liquidware.com/shop/show/SEN-LTE/AMBI+Light+Sensor">AMBI light sensor</a> using Adobe Flex.</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<u>Arduino Code</u></div>
<div class="MsoNormal">
<u><br /></u></div>
<div class="MsoNormal">
Upload this simple sketch to the Arduino.</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
</div>
<div style="background-color: white; color: black; font-family: 'Courier New'; font-style: normal; font-weight: normal; text-decoration: none;">
<pre><span class="Apple-style-span" style="font-size: x-small;"><span style="color: purple; font-weight: bolder;">void</span> <span style="font-weight: bolder;">setup</span>() <span style="color: maroon;">{</span>
Serial.<span style="font-weight: bolder;">begin</span>(<span style="color: navy;">115200</span>);<span style="color: green; font-style: italic;">//setup a serial port with a baud of 115200</span>
<span style="font-weight: bolder;">pinMode</span>(<span style="color: navy;">18</span>, OUTPUT);
<span style="font-weight: bolder;">pinMode</span>(<span style="color: navy;">19</span>, OUTPUT);
<span style="font-weight: bolder;">digitalWrite</span>(<span style="color: navy;">18</span>, HIGH);
<span style="font-weight: bolder;">digitalWrite</span>(<span style="color: navy;">19</span>, LOW);
<span style="color: maroon;">}</span>
<span style="color: purple; font-weight: bolder;">void</span> <span style="font-weight: bolder;">loop</span>() <span style="color: maroon;">{</span>
<span style="color: purple; font-weight: bolder;">int</span> value = <span style="font-weight: bolder;">analogRead</span>(<span style="color: navy;">3</span>); <span style="color: green; font-style: italic;">//read arduino analog pin 3 and save it as an int to value</span>
<span style="font-weight: bolder;">delay</span>(<span style="color: navy;">1000</span>);<span style="color: green; font-style: italic;">//delay 1,000ms</span>
<span style="color: purple; font-weight: bolder;">char</span> <span style="color: purple; font-weight: bolder;">out</span><span style="color: maroon;">[</span><span style="color: navy;">200</span><span style="color: maroon;">]</span>;<span style="color: green; font-style: italic;">//create a 200 integer array</span>
<span style="color: #c04000; font-weight: bolder;">sprintf</span>(<span style="color: purple; font-weight: bolder;">out</span>, <span style="color: teal;">"hi\nLight=%d\n"</span>, value);<span style="color: green; font-style: italic;">//prep the out file</span>
Serial.<span style="color: #c04000; font-weight: bolder;">print</span>(<span style="color: purple; font-weight: bolder;">out</span>);<span style="color: green; font-style: italic;">//print the out array</span>
<span style="color: maroon;">}</span></span></pre>
</div>
<br />
<div class="MsoNormal">
<u><br /></u></div>
<div class="MsoNormal">
<u>Android Java Code</u></div>
<div class="MsoNormal">
<u><br /></u></div>
<div class="MsoNormal">
Android must forward serial messages to a local network socket so Adobe flex can handle the data. This is accomplished using the amber-serial app. </div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
Get the amber-serial source code on <a href="https://github.com/liquidware/amber-serial">github</a>, import this into a new project in Eclipse. Upload to Amber and keep the it running in the background.</div>
<div class="MsoNormal">
<o:p><br /></o:p></div>
<div class="MsoNormal">
<u><br /></u></div>
<div class="MsoNormal">
<u>Adobe AIR Flex Code</u></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
Create a flex app in the Adobe Flex builder through the wizard. Add a button to window and use the following code to read Arduino messages from a local network socket. I used port 8888, but you can use anything you'd like, just make sure to open the port in your firewall with iptables, if used.<o:p></o:p></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">socket
= <span style="color: #0d56f5;">new</span> Socket();</span><o:p></o:p></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">socket.addEventListener(Event.CONNECT,
onConnect);<o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">socket.addEventListener(ProgressEvent.SOCKET_DATA,
onSocketData);<o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">socket.connect(<span style="color: #b20c09;">"127.0.0.1"</span>, 8888);<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="color: #0d56f5; font-family: Monaco, serif; font-size: 8.5pt;">private</span><span style="font-family: Monaco, serif; font-size: 8.5pt;">
<span style="color: #1fa77e;">function</span> onConnect(e:Event):<span style="color: #0d56f5;">void</span> {<o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">textarea1.text
= textarea1.text + <span style="color: #b20c09;">"Connected to server"</span>;<o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">}<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="color: #0d56f5; font-family: Monaco, serif; font-size: 8.5pt;">private</span><span style="font-family: Monaco, serif; font-size: 8.5pt;">
<span style="color: #1fa77e;">function</span> onSocketData(event:ProgressEvent):<span style="color: #0d56f5;">void</span><o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">{<o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">textarea1.text
= textarea1.text + <span style="color: #b20c09;">"["</span> +
event.type + <span style="color: #b20c09;">"] "</span> +
socket.readUTF();<o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;">}<o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Monaco, serif; font-size: 8.5pt;"><br /><o:p></o:p></span></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-nrJyugPv9ck/UABzWvAOhcI/AAAAAAAAAAM/utdDCZay_2g/s1600/Amber+serial.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="320" src="http://3.bp.blogspot.com/-nrJyugPv9ck/UABzWvAOhcI/AAAAAAAAAAM/utdDCZay_2g/s320/Amber+serial.png" width="239" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<div class="MsoNormal">
App design tools have come a long way, now you can rapid prototype low-level sensors all the way up to the UI design.</div>Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-16911516316783777062012-05-18T20:03:00.001-04:002012-09-17T11:01:39.094-04:00Intro to Liquidware Amber, Part 2<p><em>First off, thanks to the wonderful folks over at </em><a href="http://www.adafruit.com/blog/2012/05/17/liquidware-introduces-the-amber-the-open-source-android-tablet/"><em>Adafruit</em></a><em> and </em><a href="http://www.engadget.com/2012/05/18/liquidware-debuts-customizable-android-development-tablet/"><em>Engadget</em></a><em> for checking out the Amber! It’s been great hearing all the thoughts, feedback, and questions so far. While Mike and I get some of the projects and walkthroughs all documented, I’ll be posting them over the next week. In the meantime, some behind-the-scenes action, and a preview of what’s on deck…</em></p> <p>Many of the questions about <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Liquidware Amber</a> revolve around a couple common themes, which I’ll do my best to explain here:</p> <p><strong>What exactly is this “Amber” again?</strong></p> <p>It’s an easily customizable Android tablet. It originated as a tool that a few of us here used in a variety of projects to get things going a little quicker. I think of it as an “80% finished” device…which means that it works for a variety of different applications that make up the last 20% percent of the project, such as peripheral sensors, wireless connectivity, and the finished form factor.</p> <p><strong>I don’t understand why I shouldn’t just go get an iPad.</strong></p> <p>I actually did buy a tablet, for tablet purposes – the <a href="http://acer.us/ac/en/US/content/iconia-tab-a500">Acer Iconia A500</a>. I liked that it was Android, that it had accessible, removable, upgradable microSD storage, and that it had a USB host port.</p> <p>As much as I’d like to say I would, I don’t use Liquidware Amber to read ebooks and PDFs in bed, or to sit in the park and watch <a href="http://www.hulu.com">Hulu</a>. I don’t need to customize a tablet for that. Any number of mass market consumer tablets would fit the bill way better, and cost a lot less (unfortunately, I’m not building millions of Ambers, and I don’t own massive overseas factories to do everything for me fast and ridiculously cheap!).</p> <p>However, if I needed a 7” touchscreen enabled interface for something like my own a special ATM that dispensed only Monopoly cash (that I’m only building 100 units of), the Amber would save me a ton of time. I have a customizable Android tablet ready, dual USB hosts and other GPIO that allows me to focus on integrating functional parts, rather than trying to build everything from scratch.</p> <p><a href="http://2.bp.blogspot.com/-JOakGv-c77g/Tunc_Scb-ZI/AAAAAAAACzo/77Psh__tXEg/s1600/DSC00856.JPG"><img style="display: block; float: none; margin-left: auto; margin-right: auto" src="http://2.bp.blogspot.com/-JOakGv-c77g/Tunc_Scb-ZI/AAAAAAAACzo/77Psh__tXEg/s1600/DSC00856.JPG" width="399" height="300" /></a></p> <p>It’s a little bit of an experiment in rapid prototyping, but more on that next time…</p> <p><strong>Okay…where can I see the Amber in action?</strong></p> <p>I’m in the process of putting up more Amber projects and tutorials, but a couple things I have handy along with my Amber are my Linux laptop, a good USB Type B-mini cable, and Android Debug Bridge (adb).</p> <p>This pretty much allows me to test out peripherals with the Amber, write my own drivers, test out my own apk’s and compile custom kernels. I’m starting to compile a lot of the very basic adventures in Android applications on the Amber over on the new <a href="http://antipastohw.pbworks.com/w/page/53710296/Amber%20Pro">Antipasto HW wiki page</a>.</p> <p><a href="http://lh4.ggpht.com/-lj2BW4Oi9Sk/T7bjVblgfCI/AAAAAAAABcg/1U19PnVjhj0/s1600-h/image%25255B2%25255D.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-ilKlbzCXot0/T7bjWccvN9I/AAAAAAAABco/E-8loLjietA/image_thumb.png?imgmax=800" width="266" height="338" /></a></p> <p>I’ll also be writing up a better tutorial on getting the toolchain going. I’ve learned the hard way how important that is…and how much I’d rather not sit around installing packages when I should be busy integrating my prototype!</p> <p>Also, here’s a sneak peek at some of the projects that I’ll be uploading as I get to them this week:</p> <p><em>Build my own DIY ATM (for Monopoly money) <br />Design a custom retina scanner and display for entry to my room <br />Install a 3G/4G cellular modem on Amber <br />Physical computing with Arduino and Amber <br />Cloud computing and kernel hacking on Amber</em></p> <p>And a couple recaps on basic network/Android debugging stuff that I found helpful when I started:</p> <p><em>Setting up Eclipse and Android SDK <br />Writing my own Android Skeleton App <br />ADB tips and tricks <br />Port forwarding for remote access</em></p> <p>That’s it for now, but I’ll be getting back to more questions over the weekend.  Feel free to suggest more in the comments, or just email me at justin at liquidware dot com…</p> Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com1tag:blogger.com,1999:blog-7377057412446264720.post-18753227870329767162012-05-16T15:49:00.001-04:002012-09-17T11:02:10.668-04:00Introducing Liquidware AmberOne of the most common questions I get is, “Can I build my own Android tablet for [my project]?”<br />
<br />
That’s also something that I spend a disproportionate amount of time working on. Now, rather than starting from scratch, I’m starting from the level of say, ripping the case off my tablet and <a href="http://www.tomsguide.com/us/Root-Your-Android-Phone,review-1688.html">rooting</a> it. It’s not as violent as it sounds. The point is, I need something about 80% of the way to a tablet.<br />
<br />
<a href="http://gorbachevteardowns.files.wordpress.com/2011/07/33-moborearview1.jpg" target="_blank" title="Acer Iconia A500 Teardown"><img height="327" src="http://gorbachevteardowns.files.wordpress.com/2011/07/33-moborearview1.jpg" style="display: block; float: none; margin-left: auto; margin-right: auto;" width="424" /></a><br />
<br />
Conversely, I could build my way back up from something like a <a href="http://www.liquidware.com/category/Embedded">BeagleBoard</a>, but in many cases, it’s much more of a prototype than I really need.<br />
<a href="http://www.liquidware.com/shop/show/BB-ESK/Beagle+Embedded+Starter+Kit"><img alt="image" height="237" src="http://lh4.ggpht.com/-kOfVNM_gCAw/T7QEkACzoLI/AAAAAAAABb0/v_agIrIw8lA/image%25255B15%25255D.png?imgmax=800" style="display: block; float: none; margin-left: auto; margin-right: auto;" title="image" width="469" /></a><br />
After a while, we had an “80%-finished”, 7” Android tablet that came in very handy as a starting point for custom tablet-related projects. I like to think of it as a “foundational technology”, but since that’s quite a mouthful, we decided to call it the <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Amber</a>. This is the part where it looks like a tablet…<br />
<a href="http://www.liquidware.com/system/0000/5462/ecg-02-v2_angled-R.png" title="Liquidware Amber"><img alt="image" height="371" src="http://lh4.ggpht.com/-PbX4Zxvm2K4/T7QElQbq93I/AAAAAAAABb8/ofOHirn8qvA/image%25255B14%25255D.png?imgmax=800" style="display: block; float: none; margin-left: auto; margin-right: auto;" title="image" width="550" /></a><br />
…And this is the part where it looks very…80%-finished.<br />
<br />
The whole idea being that I want a starting point far enough along, so I don’t need to build everything from scratch, but not so far along that it’s a pain to customize. <br />
<br />
The <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Amber</a> is a 7” projected capacitive tablet driven by a 1 GHz, ARM Cortex-A9 OMAP3730 from Texas Instruments. We’ve customized a version of Android Gingerbread 2.3.4 to run on the Amber, and its 2 USB host ports offer high-speed USB and serial communications to a pretty wide range of devices. WiFi, Ethernet, cellular, and battery configurations are available as part of the <a href="http://www.liquidware.com/shop/show/AE1/Amber+Enhanced">Enhanced</a> or <a href="http://www.liquidware.com/shop/show/AP1/Amber+Pro">Pro</a> versions of the Amber.<br />
<a href="http://2.bp.blogspot.com/-oBCbQoVjiNM/T7bO4nuwE6I/AAAAAAAABcU/T17u8fuboOE/s1600/call-out-02v2-PRO_825.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em; text-align: center;"><img border="0" height="424" src="http://2.bp.blogspot.com/-oBCbQoVjiNM/T7bO4nuwE6I/AAAAAAAABcU/T17u8fuboOE/s640/call-out-02v2-PRO_825.jpg" width="640" /></a><br />
<br />
<br />
I’ll be uploading more shots and tutorials of cool (and hopefully useful) things I’ve worked on with the Amber and Android development. Meanwhile, here’s a couple videos of the Amber in action:<br />
<br />
<div style="text-align: center;">
<iframe allowfullscreen="" frameborder="0" height="396" src="http://www.youtube.com/embed/XxfHJp2RSUU" width="540"></iframe></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
<iframe allowfullscreen="" frameborder="0" height="396" src="http://www.youtube.com/embed/k-hzVL1a1MY" width="540"></iframe></div>Justinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com5tag:blogger.com,1999:blog-7377057412446264720.post-54179731241400674832012-05-15T17:55:00.000-04:002012-09-17T11:04:19.932-04:00Two ways to accelerate embedded development and build your application fasterIntel’s <a href="http://en.wikipedia.org/wiki/Intel_Core_2">Core 2 Duo</a> was one of the first mainstream desktop uses of a dual-core microprocessor (2005-6), and Nvidia’s <a href="http://en.wikipedia.org/wiki/Tegra">Tegra 2</a> was an early dual-core appearance in mobile devices (2010).<br />
<br />
Embedded development typically follows the progression of mainstream computing, with an approximate 5 year lag. Approximate, because dual-core ARM Cortexes (Cortices?) and Intel Core 2 Duos are quite different, and designed for different applications.<br />
<br />
Even 5 years ago, though, personal desktop computers were quite powerful, and that power is now available for an incredible variety of dedicated or mobile applications. <br />
<br />
<a href="http://www.icebox500.com/wp-content/uploads/2010/12/4742540168_469357987f_b.jpeg" target="_blank"><img height="522" src="http://www.icebox500.com/wp-content/uploads/2010/12/4742540168_469357987f_b.jpeg" style="display: block; float: none; margin-left: auto; margin-right: auto;" width="522" /></a><br />
<br />
As embedded technology becomes increasingly powerful, development efforts have had to accelerate to take advantage of these advances before they become obsolete.<br />
<strong><span style="font-size: small;"><br /></span></strong><br />
<strong><span style="font-size: large;">Reconfigurable Computing</span></strong><br />
<br />
“Reconfigurable” can mean a couple different things. In one sense, you can talk about reconfigurable processor architecture – at the silicon level. National Instruments recently published its <a href="http://digital.ni.com/worldwide/bwcontent.nsf/web/all/74BD315BA6AE78F7862579B10051682D" target="_blank">2012 Embedded Systems Outlook</a>, which presents the spectrum of silicon available to embedded systems developers:<br />
<br />
<a href="http://lh4.ggpht.com/-pLYpMSYADKM/T7LQsYwYdaI/AAAAAAAABbQ/xILnxe0eLHk/s1600-h/image%25255B8%25255D.png"><img alt="image" height="354" src="http://lh4.ggpht.com/-o9T_vmCm0x8/T7LQspEj5QI/AAAAAAAABbY/xWNxi8qHuqs/image_thumb%25255B6%25255D.png?imgmax=800" style="display: block; float: none; margin-left: auto; margin-right: auto;" title="image" width="568" /></a><br />
<br />
However, “reconfigurable” can also refer to the design components involved. At the microcontroller level, <a href="http://www.parallax.com/" target="_blank">Parallax</a> and <a href="http://www.arduino.cc/" target="_blank">Arduino</a> play host to a number of functional, <a href="http://www.liquidware.com/category/Arduino" target="_blank">modular components</a> – reconfigurable for any variety of <a href="http://makezine.com/arduino/" target="_blank">applications</a>. With Texas Instruments’ line of high-performance embedded OMAP-family of microprocessors, the BeagleBoard platform provides a single-board computer base for assembling a custom handheld prototype.<br />
<br />
The idea is off-the-shelf hardware is designed in such a way that the work is shifted to integration, and piecing the parts together – rather than building everything from scratch (more on that next time).<br />
<strong><span style="font-size: small;"><br /></span></strong><br />
<strong><span style="font-size: large;">Toolchain Consolidation</span> </strong><br />
<br />
Anyone who designs and develops embedded systems can tell you what its like at the start of a new project. Which version of which OS do we need to be compatible with? Is there anything from the lower levels that we’ll need access to in the final application? I happen to do a lot of work with Android, and getting each of these pieces in line for a new project is an effort in itself!<br />
<br />
<img height="394" src="http://kebomix.files.wordpress.com/2010/08/android.jpg" style="display: block; float: none; margin-left: auto; margin-right: auto;" width="549" /><br />
<br />
During the early design and prototyping stages, there’s also a great deal of component selection, each of which has its own drivers that probably need to be integrated into your kernel. And if you’re starting from a clean machine, get ready to spend a few days installing your favorite Linux packages, editors, compare programs, and kernels.<br />
<br />
Much like the <a href="http://en.wikipedia.org/wiki/LAMP_(software_bundle)" target="_blank">LAMP stack</a> that goes into building a web server, I’ve built my own stack that comes in very handy when I start developing, then I saved it onto a VMWare slice that runs off an external hard drive (also known as the <a href="http://www.liquidware.com/shop/show/BB-AND-VIDE/Android+Virtual+IDE">Android V-IDE</a>). It’s similar to this, but I’ll update it every month or so with any new or useful packages that make my life easier. For the Windows users out there (I’ll confess I’m still hanging on), the other hack is to have a dedicated Linux netbook sitting around. Everything gets compiled on a remote server, but for testing different versions of an Android APK, it’s invaluable.<br />
<br />
What are some of your favorite strategies to hit the ground running? Post a comment or e-mail me – justin at liquidware dot comJustinhttp://www.blogger.com/profile/17883121569837305211noreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-79370702765320227212012-03-27T23:18:00.013-04:002012-09-17T11:03:40.702-04:00Android App Helps Blind Students Study Math<p>I thought I'd share this interesting Vanderbilt University MED Lab research. Jenna Gorlewicz has done an amazing job of demonstrating how an Android App she designed can help blind students study math.<br /></p><p><br /><span style="font-size:100%;"><iframe src="http://www.youtube.com/embed/Bv5aypfqyrQ" allowfullscreen="" frameborder="0" height="315" width="560"></iframe></span></p><p><span style="font-size:100%;">From Medgadget News: </span><span style="font-size:100%;"><a href="http://medgadget.com/2012/03/android-app-to-help-blind-people-study-math.html">Android App to Help Blind People Study Math</a></span></p>Anonymoushttp://www.blogger.com/profile/00088046538094789826noreply@blogger.com1tag:blogger.com,1999:blog-7377057412446264720.post-4054911778813400422011-11-17T20:46:00.000-05:002012-09-17T09:58:43.946-04:00Android Hardware Development Environment<div style="text-align: center;"><a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.liquidware.com/shop/show/BB-AND-HDE/Android+Hardware+Development+Environment"><img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 319px;" src="http://4.bp.blogspot.com/-DmtHSZu_JwA/TsW5nloCnDI/AAAAAAAAB_Y/kRAm6_AxG3Y/s320/android_hde.png" alt="" id="BLOGGER_PHOTO_ID_5676146995136470066" border="0" /></a><br /></div><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br />My favorite part of the <a href="http://www.liquidware.com/shop/show/BB-AND-HDE/Android+Hardware+Development+Environment">Android Hardware Development Environment</a> is that I can easily connect to a <a href="http://antipastohw.pbworks.com/w/page/41729078/How-to%20use%20a%20serial%20port%20with%20Android%2C%20Liquidware%20Ambrosia%20edition">serial port</a>/ use the USB host capabilities with Android. When I'm done with my project I typically burn my custom image of Android to a microSD card so I can reuse my operating system!Anonymoushttp://www.blogger.com/profile/00088046538094789826noreply@blogger.com2tag:blogger.com,1999:blog-7377057412446264720.post-63840473131726943512011-06-08T12:37:00.001-04:002012-09-17T09:58:43.974-04:00Maker Faire 2011– Bay Area Recap<p>Each year, I head out to <a href="http://makerfaire.com/">Maker Faire</a>, thinking I’ve seen it all, but I know that can’t be true. And year after year…well, I haven’t been disappointed yet! Besides enjoying some quality time in the gorgeous California sun, we managed to get our project demos up and running for the event.</p> <p>Here’s the booth, with Will and Francis doing some final setup work on the projects.</p> <p><a href="http://lh4.ggpht.com/-VoZbDz20x78/Te-kxgBKrmI/AAAAAAAAA3s/Hvk48smaSLE/s1600-h/Testing-the-Projects12.jpg"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Testing the Projects" border="0" alt="Testing the Projects" src="http://lh5.ggpht.com/-zH7RpnjG_YY/Te-kx-JaPRI/AAAAAAAAA3w/FGYSoWEuMLs/Testing-the-Projects_thumb9.jpg?imgmax=800" width="450" height="338" /></a></p> <p>Of course, it wouldn’t be Maker Faire without <a href="http://gerardspaella.com/">Gerard’s Paella</a>, which also makes for a great excuse to meet and mingle with some fellow makers:</p> <p><a href="http://lh6.ggpht.com/-zqY7m51CDtY/Te-k7IlG28I/AAAAAAAAA30/zFAu7y2Z6Sc/s1600-h/Paella5.jpg"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto; padding-top: 0px" title="Paella" border="0" alt="Paella" src="http://lh5.ggpht.com/-UmvcvxtiTyY/Te-k_0QyHWI/AAAAAAAAA34/bKlIkDM4Qjo/Paella_thumb2.jpg?imgmax=800" width="450" height="338" /></a></p> <p>By Saturday, we had a chance to deck out the booth with the RC “street view” car, affectionately named Zippy :)</p> <p><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="Zippy with a Camera" border="0" alt="Zippy with a Camera" src="http://lh6.ggpht.com/-UuCnMnhgAb0/TeV5i4K9ARI/AAAAAAAAAA8/RcxBTASNAbg/Zippy%252520with%252520a%252520Camera_thumb%25255B4%25255D.jpg?imgmax=800" width="450" height="338" /></p> <p>The car had a PS3 Eye camera strapped on to stream video out onto the BeagleBoard and BeagleTouch, which was something I only dreamed of doing as a kid. DIY tech has come a long way since!</p> <p>Speaking of DIY (and open source) tech, it’s pretty neat to see that the Arduino hasn’t lost any steam. Google put together an Android <a href="http://developer.android.com/guide/topics/usb/adk.html">Accessory Development Kit</a> that they were giving out.</p> <p><a href="http://lh6.ggpht.com/-Biuy9ttV-Qg/Te-lCPNyzXI/AAAAAAAAA38/NVmGrYVpA8Y/s1600-h/Google%252520Android%252520Accessory%252520Development%252520Kit%252520Box%25255B5%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: block; float: none; margin-left: auto; border-top: 0px; margin-right: auto; border-right: 0px; padding-top: 0px" title="Google Android Accessory Development Kit Box" border="0" alt="Google Android Accessory Development Kit Box" src="http://lh3.ggpht.com/-jS48WUG7rIc/Te-lCjh9g9I/AAAAAAAAA4A/0UGRt1eZutM/Google%252520Android%252520Accessory%252520Development%252520Kit%252520Box_thumb%25255B2%25255D.jpg?imgmax=800" width="450" height="270" /></a></p> <p>It comes with an <a href="http://www.liquidware.com/shop/show/AMEGA2560/Arduino+Mega+2560">Arduino Mega</a>-based board with an onboard USB host and USB OTG port, and the Accessory Demo Shield (bottom). The Accessory Demo Shield is especially neat…it’s like the ultimate controller/debugger shield, all in one. Buttons, relays, servo connectors, joystick and even a touch sensor! It puts a whole new spin on the kinds of <a href="http://antipastohw.blogspot.com/2010_06_01_archive.html">Android/Beagle/Arduino</a> projects I want to do…</p> <p><a href="http://lh6.ggpht.com/-PjACxDI7L2g/Te-lDVWtY5I/AAAAAAAAA4E/9I3qwl_IG9I/s1600-h/Google%252520Android%252520Accessory%252520Development%252520Kit%25255B3%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="Google Android Accessory Development Kit" border="0" alt="Google Android Accessory Development Kit" src="http://lh3.ggpht.com/-6a366FiG-U0/Te-lDrVlKeI/AAAAAAAAA4I/C_PVqOVuLL4/Google%252520Android%252520Accessory%252520Development%252520Kit_thumb.jpg?imgmax=800" width="450" height="269" /></a></p> <p>Microchip and Digilent came out with a PIC32 that <a href="http://coewww.rutgers.edu/~msproul/">Mark</a> shared with me. Pretty cool, since I can now drive all sorts of <a href="http://www.liquidware.com/category/Modules">Arduino shields</a> with a PIC controller…</p> <p><a href="http://lh6.ggpht.com/-1-Rhx8j9JuY/Te-lEMRmo8I/AAAAAAAAA4M/WKRc1e3gC-U/s1600-h/Pic32%252520Uno%25255B2%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="Pic32 Uno" border="0" alt="Pic32 Uno" src="http://lh6.ggpht.com/-2CpifD6Ck8M/Te-lEd650EI/AAAAAAAAA4Q/Ud1G1fUnSDY/Pic32%252520Uno_thumb.jpg?imgmax=800" width="450" height="269" /></a></p> <p><a href="http://lh6.ggpht.com/-6CU4iUQQCfU/Te-lEywP1PI/AAAAAAAAA4U/vxY9kq5BxuQ/s1600-h/Pic32%252520Mega%25255B2%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="Pic32 Mega" border="0" alt="Pic32 Mega" src="http://lh6.ggpht.com/-7gH5fk5zknw/Te-lFN1-S5I/AAAAAAAAA4Y/gMrT1NNyh4E/Pic32%252520Mega_thumb.jpg?imgmax=800" width="450" height="269" /></a></p> <p>Back at the booth, Will, Francis and I met a lot of hackers who stopped by to play around with the projects.</p> <p><a href="http://lh4.ggpht.com/-_rArzUzjzOQ/Te-lFa2rjAI/AAAAAAAAA4c/yqhw-GCHpJQ/s1600-h/Android%252520Demo%25255B4%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="Android Demo" border="0" alt="Android Demo" src="http://lh5.ggpht.com/-hVrXCD8NUGs/Te-lFwAqu1I/AAAAAAAAA4g/tCgbfeHOSZ4/Android%252520Demo_thumb%25255B1%25255D.jpg?imgmax=800" width="450" height="338" /></a></p> <p><a href="http://lh6.ggpht.com/-hatfbT8IK20/Te-lGMoivjI/AAAAAAAAA4k/zPCGBrGIKFg/s1600-h/Francis%25255B6%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="Francis" border="0" alt="Francis" src="http://lh6.ggpht.com/-BrpzK_WupLM/Te-lGn3Y51I/AAAAAAAAA4o/-4lPeVpH2kY/Francis_thumb%25255B3%25255D.jpg?imgmax=800" width="450" height="338" /></a></p> <p>Each of us had a few moments to sneak away from the booth (in shifts) to wander through the Faire and check out what everyone else was up to.</p> <p>I think this was the best country stage ever…the front porch if an old Western house.</p> <p><a href="http://lh4.ggpht.com/-XvMO1FKln78/Te-lJFT00nI/AAAAAAAAA4s/ZcXPw-v2Qlo/s1600-h/CIMG6630%252520%252528Large%252529%25255B3%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="CIMG6630 (Large)" border="0" alt="CIMG6630 (Large)" src="http://lh4.ggpht.com/-6UPqxgSs7RI/Te-lJd2Tj8I/AAAAAAAAA4w/TbcEqxLjKcY/CIMG6630%252520%252528Large%252529_thumb.jpg?imgmax=800" width="450" height="338" /></a></p> <p>A little steampunk and futuristic in a video-game kinda way, there’s nothing that stops you in your tracks like a robot sculpture that shoots fire. All I could say was…wow!</p> <p><a href="http://lh5.ggpht.com/-rpMudcsmcsY/Te-lJ_dC6VI/AAAAAAAAA40/WTcTJ0wN320/s1600-h/Robot%252520that%252520Shoots%252520out%252520Fire%25255B3%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="Robot that Shoots out Fire" border="0" alt="Robot that Shoots out Fire" src="http://lh6.ggpht.com/-gcqKXZluEwE/Te-lKELy7iI/AAAAAAAAA44/S1jSwU4qYYU/Robot%252520that%252520Shoots%252520out%252520Fire_thumb.jpg?imgmax=800" width="450" height="338" /></a></p> <p>And the most efficient four-wheeler ever- a new take on the tandem bike. I would love to have one of these, and maybe even mount an enclosure on this. I wonder what a cross-country road trip on this human powered car would be like. Probably fun and a great exercise :)</p> <p><a href="http://lh4.ggpht.com/-YuTOgMAYhfc/Te-lKi362jI/AAAAAAAAA48/CIo8-oKAZ0U/s1600-h/Most%252520Fuel%252520Efficient%252520Four%252520Wheeler%25255B3%25255D.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="Most Fuel Efficient Four Wheeler" border="0" alt="Most Fuel Efficient Four Wheeler" src="http://lh5.ggpht.com/-q6MVjbbfUQ0/Te-lOcAsrRI/AAAAAAAAA5A/JiB2TO7sOBo/Most%252520Fuel%252520Efficient%252520Four%252520Wheeler_thumb.jpg?imgmax=800" width="450" height="338" /></a></p> <p>That’s all I pulled off the camera for now, and I’ll upload more pictures to Flickr when I get them. Thanks again to all the makers and hackers who stopped by, and I’ll be on the edge of my seat waiting for the next Maker Faire!</p> Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-7377057412446264720.post-79852314487691562642011-05-19T20:54:00.001-04:002012-09-17T09:58:43.994-04:00I’m off to Maker Faire (2011 Edition)!<p>It’s that time of the year again! Some folks call in summer – I call it <a href="http://www.makerfaire.com/">Maker Faire</a>. So next week, I’m packing up a few of my favorite new projects, and hopefully show off something interesting at my table out in San Mateo.</p> <p><img style="display: block; float: none; margin-left: auto; margin-right: auto" src="http://cdn.makezine.com/make/makerfaire/bayarea/2011/banners/MF11_BA_Ad_Make_300x250_Green.gif" /></p> <p>One thing I’m really excited about is the stuff I’ve been hacking around with in Android. I always felt like <a href="http://www.liquidware.com/category/Android">Android</a> was one of those hardcore engineering things, but I’ve been able to get it to work with the <a href="http://www.liquidware.com/shop/show/BB-C4/BeagleBoard+C4">BeagleBoard</a> and <a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">BeagleTouch</a> to do some pretty fun stuff.</p> <p>Last week, Will, and I were sitting in the lab playing around with the old RC car and some of Playstation cameras we had from a project last year. Will always thought it would be cool if we could control the car without having to follow it around, so we gave it a whirl. Loading up the car with a couple hacked PlayStation 3 cameras, Will was able to drive the car around the house without leaving the room.</p> <p>By hooking up the PS3 camera to the car, Will and I were able to bring up the camera to the <a href="http://www.liquidware.com/shop/show/BB-BT/BeagleTouch">BeagleTouch</a> and see exactly what the <a href="http://antipastohw.blogspot.com/2010/03/making-of-gravitational-rc-driving-by.html">RC car</a> was seeing. I’ve always wondered what it would be like to be driven around on a little RC car (think Honey I Shrunk The Kids :) and this is just about the closest I’ll get.  <img style="display: block; float: none; margin-left: auto; margin-right: auto" src="http://moviesiwannasee.files.wordpress.com/2010/10/honey-i-shrunk-the-kids.jpg" width="242" height="339" />Using the same hack, I hooked up four PS3 cameras to the around my desk to make a “BeagleBoard Security System”, complete with split-screens and everything. It made me feel like a security guard/command-center operator of sorts, and plus, no one could sneak up on me.</p> <p>Not to say I’ve forgotten all about the Arduino - I’ve also been playing around with a low power, portable, WiFi/GPS/Arduino rig with the <a href="http://www.liquidware.com/shop/show/SEN-GEO/GeoShield">GeoShield</a>, which I’m going to test out at Maker Faire Exhibition Hall when I get there.</p> <p>I had some spare time on my hands the past couple weekends, and some cooler gear to play with, so there’s plenty more projects I’ll have to show off. I’ll be there the whole time, and would love to say hi to some fellow West Coast hackers…see you there!</p> Unknownnoreply@blogger.com2tag:blogger.com,1999:blog-7377057412446264720.post-75826566939728676112011-02-16T12:09:00.000-05:002012-09-17T09:58:43.988-04:00Android Platform DistributionThanks for all the emails and feedback over the last couple months on the <a href="http://www.liquidware.com/shop/show/BB-AND-DEV1/Android+Hardware+Development+Kit">Android Hardware Development kit</a>, we're very excited to be using this advanced hardware platform. In fact, Matt has been busy hacking into nearly all our devices around the office that have exposed serial. Interestingly, <span style="font-style: italic;">Droid Does</span> talk to quad CMOS sensor arrays to stream live video, but more on that later.<br /><br />One of the common questions asked was: which version of Android does the Android Hardware Development Kit ship with?<br /><br /><a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/-2spnxSr9WEY/TVwTQP3pXgI/AAAAAAAAAP0/ArO9rk3kjuM/s1600/Liquidware-Android-Hardware-Development-Kit.jpg"><img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 400px; height: 360px;" src="http://4.bp.blogspot.com/-2spnxSr9WEY/TVwTQP3pXgI/AAAAAAAAAP0/ArO9rk3kjuM/s400/Liquidware-Android-Hardware-Development-Kit.jpg" alt="" id="BLOGGER_PHOTO_ID_5574351608636595714" border="0" /></a><br /><br />The answer surprisingly turns out to be the in-line with the second most popular version on the market today, 2.1. This is great news because it shows a nexus of stable devices focused around Android 2.1 and 2.2 versions. This creates a stable base to upgrade from as the bleeding edge releases become more robust through aggressive software patch-work.<br /><br /><h3 id="Current">Current Distribution</h3>The following pie chart and table is based on the number of Android devices that have accessed Android Market within a 14-day period ending on the data collection date noted below.<br /><br /><div style="text-align: center;"><img alt="" src="http://chart.apis.google.com/chart?&cht=p&chs=460x250&chd=t:3.9,6.3,31.4,57.6,0.8&chl=Android%201.5%7CAndroid%201.6%7CAndroid%202.1%7CAndroid%202.2%7CAndroid%202.3&chco=c4df9b,6fad0c" height="250" width="460" /><br /></div><br /><br /><table style="width: 300px; border: medium none; height: 100px; border-collapse: collapse; text-align: left; margin-left: auto; margin-right: auto;" width="" cellpadding="0" cellspacing="0"><tbody><tr><td style="text-align: center; background-color: rgb(220, 220, 220); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">Platform<br /></td><td style="text-align: center; background-color: rgb(220, 220, 220); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">API Level<br /></td><td style="text-align: center; background-color: rgb(220, 220, 220); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">Distribution<br /></td></tr><tr><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">Android 1.5<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">3<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">3.9%<br /></td></tr><tr><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">Android 1.6<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">4<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">6.3%<br /></td></tr><tr><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">Android 2.1<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">7<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">31.4%<br /></td></tr><tr><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">Android 2.2<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">8<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">57.6%<br /></td></tr><tr><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">Android 2.3<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">9<br /></td><td style="text-align: center; background-color: rgb(255, 255, 255); color: rgb(0, 0, 0); height: 10px; vertical-align: middle; letter-spacing: 0pt; word-spacing: 0pt; width: 100px; border: medium none;">0.8%<br /></td></tr></tbody></table><div style="text-align: center;"><br /><div style="text-align: left;"><em>Data collected during two weeks ending on February 2, 2011</em></div></div><p></p><p><span style="font-style: italic;">From <a href="http://developer.android.com/resources/dashboard/platform-versions.html">developer.android.com</a></span><br /><em></em></p>Chrishttp://www.blogger.com/profile/12772971512697373580noreply@blogger.com1