<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>BlackBerry Developer Blog &#187; Arduino</title>
	<atom:link href="http://devblog.blackberry.com/tag/arduino/feed/" rel="self" type="application/rss+xml" />
	<link>http://devblog.blackberry.com</link>
	<description></description>
	<lastBuildDate>Fri, 17 May 2013 17:47:42 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='devblog.blackberry.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://1.gravatar.com/blavatar/9ef0a66c09615fa946c4179662398878?s=96&#038;d=http%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>BlackBerry Developer Blog &#187; Arduino</title>
		<link>http://devblog.blackberry.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://devblog.blackberry.com/osd.xml" title="BlackBerry Developer Blog" />
	<atom:link rel='hub' href='http://devblog.blackberry.com/?pushpress=hub'/>
		<item>
		<title>BlackBerry Jam Unplugged: Connectivity</title>
		<link>http://devblog.blackberry.com/2013/05/blackberry-jam-unplugged-connectivity/</link>
		<comments>http://devblog.blackberry.com/2013/05/blackberry-jam-unplugged-connectivity/#comments</comments>
		<pubDate>Thu, 09 May 2013 01:25:34 +0000</pubDate>
		<dc:creator>Tim N.</dc:creator>
				<category><![CDATA[Adobe AIR Development]]></category>
		<category><![CDATA[Cascades]]></category>
		<category><![CDATA[Events]]></category>
		<category><![CDATA[Interviews/Thought Leadership]]></category>
		<category><![CDATA[Native SDK Development]]></category>
		<category><![CDATA[Platform Services]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Arduino]]></category>
		<category><![CDATA[Bluetooth]]></category>
		<category><![CDATA[GPS]]></category>
		<category><![CDATA[Jam]]></category>
		<category><![CDATA[nfc]]></category>
		<category><![CDATA[Unplugged]]></category>
		<category><![CDATA[WiFi]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=14873</guid>
		<description><![CDATA[We’ve now posted the final episode of the BlackBerry Jam Unplugged series where we learn a little more about connecting to the world around you with BlackBerry 10. I hope you’ve enjoyed the series and we look forward to seeing you all at BlackBerry Jam Americas in Orlando. Please let us know what you thought [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=14873&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>We’ve now posted the final episode of <a href="http://devblog.blackberry.com/?s=jam+unplugged&amp;search=" target="_blank">the BlackBerry Jam Unplugged series</a> where we learn a little more about connecting to the world around you with BlackBerry 10.</p>
<p>I hope you’ve enjoyed the series and we look forward to seeing you all at <a href="http://www.blackberryjamconference.com/americas" target="_blank">BlackBerry Jam Americas in Orlando</a>. Please let us know what you thought of the videos to ensure that we can bring information to you in a way that’s educational, but entertaining as well.</p>
<p>This particular video will give you some information about the current opportunities and upcoming roadmap items that we’re looking at for extending connectivity for developers. In this video we’re joined by <a href="https://twitter.com/robbieDubya" target="_blank">Rob Williams</a> who talks about how you can connect BlackBerry 10 to the world around you to incorporate context into your apps.</p>
<span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='640' height='390' src='http://www.youtube.com/embed/3jTckvem5pk?version=3&#038;rel=1&#038;fs=1&#038;showsearch=0&#038;showinfo=1&#038;iv_load_policy=1&#038;wmode=transparent' frameborder='0'></iframe></span>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/14873/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/14873/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=14873&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2013/05/blackberry-jam-unplugged-connectivity/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/3939390650b170ba28e9bf3c53d397ad?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">timneil1</media:title>
		</media:content>
	</item>
		<item>
		<title>Talking With Your Arduino via NFC on BlackBerry</title>
		<link>http://devblog.blackberry.com/2012/12/talking-with-your-arduino-via-nfc-on-blackberry/</link>
		<comments>http://devblog.blackberry.com/2012/12/talking-with-your-arduino-via-nfc-on-blackberry/#comments</comments>
		<pubDate>Fri, 14 Dec 2012 16:28:20 +0000</pubDate>
		<dc:creator>robwilliamsjnrrim</dc:creator>
				<category><![CDATA[How-to]]></category>
		<category><![CDATA[Native SDK Development]]></category>
		<category><![CDATA[Arduino]]></category>
		<category><![CDATA[BlackBerry 10]]></category>
		<category><![CDATA[nfc]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=12599</guid>
		<description><![CDATA[Did you know that it’s easy to exchange data between your NFC enabled smartphone and your Arduino? It can be arbitrary data too – it does not need to be formatted as NDEF tags or ISO 7816-4 APDUs! What does it take to get an Arduino that talks with BlackBerry running? Here’s what I used [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=12599&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><img class="aligncenter size-full wp-image-12600" alt="TITLE_IMAGE" src="http://rimdevblog.files.wordpress.com/2012/12/devblog-nfc-avec-arduino-e1354894489515.png?w=600&#038;h=163" width="600" height="163" /></p>
<p>Did you know that it’s easy to exchange data between your NFC enabled smartphone and your Arduino? It can be arbitrary data too – it does not need to be formatted as NDEF tags or ISO 7816-4 APDUs!</p>
<p>What does it take to get an Arduino that talks with BlackBerry running? Here’s what I used to make a very basic color mixing application that shares colors between the Arduino and the BlackBerry over NFC.</p>
<ul>
<li>Some NFC enabled BlackBerry devices. I’m using my Bold 9900s. &lt;3 the keyboard!</li>
<li>1 Arduino. I’m using an Arduino Uno R3 (it’s under the shield)</li>
<li>1 Adafruit Industries PN532 NFC/RFID shield. A great shield available here: <a href="http://adafruit.com/products/789">http://adafruit.com/products/789</a></li>
<li>1 BlackBerry application.</li>
<li>1 Arduino sketch</li>
<li>A copy of the Adafruit NFCShield library. Note that I have made modifications to get the functionality that I needed; <a href="https://github.com/blackberry/Adafruit_NFCShield_I2C">https://github.com/blackberry/Adafruit_NFCShield_I2C</a> (pull request pending&#8230;)</li>
<li><b><i>Imagination.</i></b> This is the most important ingredient! With these other ingredients you could build… anything! (Hit me up in the comments with your project!)</li>
</ul>
<ul>
<li>Optional: The manual for the PN532. <a href="http://www.adafruit.com/datasheets/pn532um.pdf">http://www.adafruit.com/datasheets/pn532um.pdf</a></li>
</ul>
<p><span id="more-12599"></span></p>
<h2>Arduino Sketch</h2>
<p>Here are the guts of my sketch – stripped to the barest functionality… I need to ‘inList’ a passive target and then ‘inDataExchange’. If you can ‘inList’ a target – then you can send data to it…</p>
<pre>if (nfc.inListPassiveTarget()) {
    while(true) {
      message[0] = 1; message[1] = r; message[2] = g; message[3] = b;
      uint8_t responseLength = sizeof(message);
      if (nfc.inDataExchange(message,sizeof(message),message,&amp;responseLength)) {
        uint8_t command = message[0];
        switch(command) {
        case 1:
          if (responseLength==4) {
            r = message[1];
            g = message[2];
            b = message[3];
            showColor();
          }
          else {
            //Serial.println("Doesn't seem to be a color...");
          }
          break;
        default:
          ;
        }</pre>
<p>The Adafruit samples show you everything you need to know about initializing the class.</p>
<p>The active NFC peer (the Arduino) is responsible for sending data first. You may have to keep on polling your passive peer.</p>
<h2>Java</h2>
<p>Again – just the basics. You need to create a VirtualISO14443Part4TypeATarget. You have to be aware that the target is only active when your app is in the foreground. The number below is not used by the API. <b>this</b> is an instance of VirtualISO14443Part4TargetCallback.</p>
<pre>    emulated = <b>new</b> VirtualISO14443Part4TypeATarget(<b>this</b>, "10451045", <b>null</b>);
    emulated.startEmulation();</pre>
<p>Then, in the callback I send the color that has been mixed on the screen (unless the user hasn’t chosen a color recently). The byte array returned from this method is transmitted over NFC.</p>
<p><b>private</b> <b>byte</b>[] processCommand(<b>byte</b>[] command) {</p>
<pre>        <b>if</b> (command == <b>null</b>) {
            <b>return</b> <b>new</b> <b>byte</b>[0];
        }
        <b>int</b> messageType = command[0] &amp; 0xff;
        <b>switch</b> (messageType) {
        <b>case</b> 1:
            <b>if</b> (command.length == 4) {
                <b>int</b> colorIn = (command[1] &amp; 0xff) &lt;&lt; 16;
                colorIn |= (command[2] &amp; 0xff) &lt;&lt; 8;
                colorIn |= (command[3] &amp; 0xff);

                <b>if</b> (colorIn != color) {
                    <b>if</b> (colorQueued) {

                        <b>byte</b>[] toReturn = <b>new</b> <b>byte</b>[4];
                        toReturn[0] = 1;
                        toReturn[1] = (<b>byte</b>) (color &gt;&gt; 16);
                        toReturn[2] = (<b>byte</b>) (color &gt;&gt; 8);
                        toReturn[3] = (<b>byte</b>) color;

                        <b>return</b> toReturn;</pre>
<p>Existing BlackBerry samples and tutorials explain the listener really well.</p>
<h2>The Result</h2>
<p>Here’s a very short video showing several BlackBerrys sharing colors with the Arduino. I built a paper cube around my LED to try and make it easier to capture on video.</p>
<span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='640' height='390' src='http://www.youtube.com/embed/SmGnn1Bb2yc?version=3&#038;rel=1&#038;fs=1&#038;showsearch=0&#038;showinfo=1&#038;iv_load_policy=1&#038;wmode=transparent' frameborder='0'></iframe></span>
<h2>My NFC Slogan</h2>
<p><b><i>You’re already there! No need to PAIR!</i></b></p>
<p>What I’m trying to say in my slogan is this: there are times when you want to be physically at a device and make it do something. To me – NFC feels a little like the crystals that power starship computers in SCI-FI shows. The hero moves them into the right spot; completing the system and saving the day, galaxy and timeline.</p>
<p>There are times that you don’t want to be there either… And there are lots of higher powered RF systems for that…</p>
<h2>What Can You Make?</h2>
<p>Who will make the first bridge for NFC to XBee that has a cradle form factor?</p>
<p>I’m looking forward to hearing in the comments what you are going to Make!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/12599/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/12599/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=12599&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2012/12/talking-with-your-arduino-via-nfc-on-blackberry/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6e3641573bfea7977bb68017a91c03b3?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">robwilliamsjnrrim</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/12/devblog-nfc-avec-arduino-e1354894489515.png" medium="image">
			<media:title type="html">TITLE_IMAGE</media:title>
		</media:content>
	</item>
		<item>
		<title>The BlackBerry PlayBook Protects Your Milk from Aliens (Or: Using the BlackBerry PlayBook for Rapid Prototyping)</title>
		<link>http://devblog.blackberry.com/2011/12/blackberry-playbook-arduino/</link>
		<comments>http://devblog.blackberry.com/2011/12/blackberry-playbook-arduino/#comments</comments>
		<pubDate>Fri, 02 Dec 2011 14:42:13 +0000</pubDate>
		<dc:creator>Luke Reimer</dc:creator>
				<category><![CDATA[Case Studies & Success Stories]]></category>
		<category><![CDATA[aliens]]></category>
		<category><![CDATA[Arduino]]></category>
		<category><![CDATA[blackberry playbook]]></category>
		<category><![CDATA[BlackBerry PlayBook OS]]></category>
		<category><![CDATA[electronics]]></category>
		<category><![CDATA[playbook apps]]></category>
		<category><![CDATA[prototyping]]></category>
		<category><![CDATA[tablet]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=8104</guid>
		<description><![CDATA[Mathias and Fredrik at The Astonishing Tribe show off the awesome power of the Arduino platform on the BlackBerry PlayBook tablet.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=8104&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p style="text-align:center;"><span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='560' height='315' src='http://www.youtube.com/embed/F64kxhVcsuY?version=3&#038;rel=1&#038;fs=1&#038;showsearch=0&#038;showinfo=1&#038;iv_load_policy=1&#038;wmode=transparent' frameborder='0'></iframe></span></p>
<p style="text-align:center;">[ <a href="http://www.youtube.com/watch?v=F64kxhVcsuY" target="_new">YouTube link for mobile viewing</a> ]</p>
<p><i>Hi everyone!  We’ve got a special treat for you today – Mathias and Fredrik, our friends at <a href="http://tat.se" target="_new">The Astonishing Tribe</a>, have put together a great blog post about the Arduino™ platform.  If you’re searching for E.T., this might be your best weapon – how? Find out below&#8230; &#8211; Ed.</i></p>
<p>Today’s consumer devices pack an unparalleled bang-for-your-buck, giving end users blazing-fast and high-performing products. This is more than “fine and dandy” for users in the intended demographic of the device, but what about users like ‘The Prototyper,’ ‘The Hobbyist,’ and ‘The Startup Techie,’ to name a few? You recognize them from their desire to change the way that we use devices; to disrupt the established models; to get their hands dirty and create something new.</p>
<p>Yep, people like us are especially excited by new devices, and in our experience the BlackBerry® PlayBook™ tablet’s power and performance has no equal for tinkerers.</p>
<p>With the relative complexity of today’s electronics, it’s not feasible to start from scratch; you need good building blocks to implement your vision. You’ll want to use commercial off- the-shelf (COTS) components as much as possible and you most likely don’t want to be bound to a bulky PC.</p>
<p>Fortunately, we have the BlackBerry PlayBook tablet. It’s a powerful and portable consumer tablet, with a great user interface and an <a href="http://devblog.blackberry.com/2011/10/native-sdk-for-blackberry-released/" target="_new">open SDK</a>.  We find it is an ideal platform to host your UI, crunch data, and more.</p>
<p>So how do we get started prototyping our ideas with the BlackBerry PlayBook tablet? For electronics concepts: enter Arduino.</p>
<p><span id="more-8104"></span></p>
<p><img src="http://rimdevblog.files.wordpress.com/2011/12/arduino-1.jpg?w=400&#038;h=298" alt="Arduino" title="Arduino" width="400" height="298" class="alignnone size-full wp-image-8109" /></p>
<p>Arduino is:</p>
<blockquote><p>“an open-source electronics-prototyping platform based on flexible, easy-to-use hardware and software. It&#8217;s intended for artists, designers, hobbyists, and anyone interested in creating interactive objects or environments.”</p></blockquote>
<p> (via <a href="http://arduino.cc/" target="_new">http://arduino.cc/</a>)</p>
<p>Arduino platform has spawned an innovative and affordable range of products, ranging from various Arduino boards to meet your form-factor requirements to I/O boards (“shields”) that facilitate connectivity. </p>
<p><strong>A Real World Problem</strong></p>
<p><img src="http://rimdevblog.files.wordpress.com/2011/12/arduino-2.jpg?w=600&#038;h=400" alt="" title="" width="600" height="400" class="alignnone size-full wp-image-8108" /></p>
<p><img src="http://rimdevblog.files.wordpress.com/2011/12/arduino-3.jpg?w=600&#038;h=400" alt="" title="" width="600" height="400" class="alignnone size-full wp-image-8107" /></p>
<p>We need to catch the milk thief! Is there no justice in the world?</p>
<p>How can we protect our milk from aliens? Perhaps we can rig a BlackBerry PlayBook tablet and use its camera to capture a photo of the nefarious milk thief. But the BlackBerry PlayBook tablet camera can’t see in the dark, making it difficult to detect intruders in a dark kitchen at night. </p>
<p>We’ll need a BlackBerry PlayBook tablet, an infrared (“IR”) sensor, a servo to pan the sensor, and a way to control the servo as well as to handle the IR sensor. </p>
<p><strong>Connecting</strong></p>
<p><img src="http://rimdevblog.files.wordpress.com/2011/12/tat_pb.jpg?w=600&#038;h=401" alt="" title="" width="600" height="401" class="alignnone size-full wp-image-8112" /></p>
<p><img src="http://rimdevblog.files.wordpress.com/2011/12/arduino-5.jpg?w=400&#038;h=292" alt="Arduino" title="Arduino" width="400" height="292" class="alignnone size-full wp-image-8106" /></p>
<p><img src="http://rimdevblog.files.wordpress.com/2011/12/arduino-6.jpg?w=600&#038;h=401" alt="" title="" width="600" height="401" class="alignnone size-full wp-image-8105" /></p>
<p>Done!</p>
<p><strong>Implementation</strong></p>
<p>The Arduino board uses an IR range sensor to find targets. The IR sensor is placed on a servo to scan the area of interest (e.g. kitchen). The data is sent to the BlackBerry PlayBook tablet, on which we’ve built an application to present a sonar map and look for movement. If movement is detected, the application will sound an alarm and take a picture. The video above shows the system in action.</p>
<p>Now, let’s catch that thief and bring an end to domestic lactose thieving!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/8104/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/8104/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=8104&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2011/12/blackberry-playbook-arduino/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/02798908b6c8de45a0e4aa8531a6d869?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">lukereim1</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2011/12/arduino-1.jpg" medium="image">
			<media:title type="html">Arduino</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2011/12/arduino-2.jpg" medium="image" />

		<media:content url="http://rimdevblog.files.wordpress.com/2011/12/arduino-3.jpg" medium="image" />

		<media:content url="http://rimdevblog.files.wordpress.com/2011/12/tat_pb.jpg" medium="image" />

		<media:content url="http://rimdevblog.files.wordpress.com/2011/12/arduino-5.jpg" medium="image">
			<media:title type="html">Arduino</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2011/12/arduino-6.jpg" medium="image" />
	</item>
	</channel>
</rss>
