<?xml version="1.0" encoding="utf-8"?>
<feed version="0.3" xmlns="http://purl.org/atom/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xml:lang="en">
<title>Nonpolynomial Labs News</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/" />
<modified>2008-06-08T06:25:56Z</modified>
<tagline></tagline>
<id>tag:www.nonpolynomial.com,2008://13</id>
<generator url="http://www.movabletype.org/" version="4.12">Movable Type</generator>
<copyright>Copyright (c) 2008, qDot</copyright>

<entry>
<title>Falcon Uncasing</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/06/falcon-uncasing.php" />
<modified>2008-06-08T06:25:56Z</modified>
<issued>2008-06-08T06:20:16Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1193</id>
<created>2008-06-08T06:20:16Z</created>
<summary type="text/plain">Well, after two months of not getting much done I finally manage to zip a directory and call it v0.4 of libnifalcon, and the developer responsible for the SolidEdge simulation does a full uncasing of the Falcon, taking a great...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>Well, after two months of not getting much done I finally manage to zip a directory and call it v0.4 of <A HREF='http://www.sourceforge.net/projects/libnifalcon'>libnifalcon</A>, and the developer responsible for the <A HREF='http://www.nonpolynomial.com/archives/2008/05/solidedge-simulation-of-the-novint-falco.php'>SolidEdge simulation</A> <A HREF='http://picasaweb.google.com/kouellet/FalconProject?authkey=kAvHYd9lo5A'>does a full uncasing of the Falcon, taking a great picture set along the way</A>. I'm start to feel like I'm falling a bit behind in usefulness here. :)</p>

<p><CENTER><A HREF='http://picasaweb.google.com/kouellet/FalconProject?authkey=kAvHYd9lo5A'><IMG SRC='http://images.nonpolynomial.com/nonpolynomial.com/blog/deskfalcon.jpg' border=0></A></CENTER></p>

<p><small>Image by kouellet of the libnifalcon project</small></p>

<p>I really like this image for some reason.</p>]]>

</content>
</entry>

<entry>
<title>SolidEdge Simulation of the Novint Falcon done by libnifalcon team member</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/05/solidedge-simulation-of-the-novint-falco.php" />
<modified>2008-05-24T20:06:13Z</modified>
<issued>2008-05-24T20:02:02Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1190</id>
<created>2008-05-24T20:02:02Z</created>
<summary type="text/plain">So, I&apos;ve actually got some people helping out on libnifalcon now, and one of them just posted a neat video of a SolidEdge simulation of the Falcon hardware. More information and a model will be available at the Falcon Simulation...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>So, I've actually got some people helping out on <A HREF='http://www.sourceforge.net/projects/libnifalcon'>libnifalcon</A> now, and one of them just posted a neat video of a <A HREF='http://www.plm.automation.siemens.com/en_us/products/velocity/solidedge/'>SolidEdge</A> simulation of the Falcon hardware.</p>

<p><CENTER><embed style="width:400px; height:326px;" id="VideoPlayback" align="middle" type="application/x-shockwave-flash" src="http://video.google.com/googleplayer.swf?docId=-1184008318842321491&hl=fr" allowScriptAccess="sameDomain" quality="best" bgcolor="#ffffff" scale="noScale" salign="TL"  FlashVars="playerMode=embedded"> </embed><br /></CENTER></p>

<p><A HREF='http://libnifalcon.wiki.sourceforge.net/Falcon+Simulation'>More information and a model will be available at the Falcon Simulation page of the libnifalcon Wiki</A><br />
</p>]]>

</content>
</entry>

<entry>
<title>Video from Futuristic Music Design Contest at Yuri&apos;s Night</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/05/video-from-futuristic-music-design-conte.php" />
<modified>2008-05-19T03:01:40Z</modified>
<issued>2008-05-19T02:46:34Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1189</id>
<created>2008-05-19T02:46:34Z</created>
<summary type="text/plain">At Yuri&apos;s Night this year, CreateDigitalMusic.com had a futuristic music design competition to see what new an innovative audio interfaces people could come up with. I filmed the competition, and have finally gotten everything edited and up on YouTube. I...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs News</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>At Yuri's Night this year, <A HREF='http://www.createdigitalmusic.com'>CreateDigitalMusic.com</A> had a futuristic music design competition to see what new an innovative audio interfaces people could come up with. I filmed the competition, and have finally gotten everything edited and up on YouTube. I apologize in advance for the Blair Witch-esque camera work. :)<br />
 <br />
<CENTER><object width="500" height="370"><param name="movie" value="http://www.youtube.com/p/2EEC7516C6DD5A02"></param><embed src="http://www.youtube.com/p/2EEC7516C6DD5A02" type="application/x-shockwave-flash" width="500" height="370"></embed></object></CENTER></p>]]>

</content>
</entry>

<entry>
<title>libusb, libftdi, latency, and my own stupidity</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/04/libusb-libftdi-latency-and-my-own-stupid.php" />
<modified>2008-04-30T06:53:00Z</modified>
<issued>2008-04-30T04:59:56Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1182</id>
<created>2008-04-30T04:59:56Z</created>
<summary type="text/plain">When last we left off, I had an OpenGL kinematics simulator for my current OCD fulfillment object, the Novint Falcon. I&apos;ll get to the math behind all that in the next post, but for right now, suffice to say, it...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>When last we left off, I had an OpenGL kinematics simulator for my current OCD fulfillment object, the Novint Falcon. I'll get to the math behind all that in the next post, but for right now, suffice to say, it just works. The kinematics loops can easily hit 40000 iterations per second, which is more than enough for my first few basic projects, including mouse control. However, that really only mattered on windows, because when I finished the simulator, windows still had a 1000hz update rate, while linux and os x were still running at 70-150hz update rate on a good day with the wind going in the right direction. I spent last week trying to get linux and mac up to the same speed as windows. What follows is the story of that week.</p>

<p>But first off, let's rewind to August of last year. Before Novint put out their own SDK, I was bound and determined to get my own out, just because it seemed like a fun challenge. I managed to document out the firmware download process, but not completely replicate it. My first program worked by starting up one of their test programs to load firmware, then using my own code after that to communicate with the falcon. The hack ended up being successful, if ridiculously unsafe to look at in a normal workplace. The video of the results are at  http://www.youtube.com/watch?v=EfrMalBiXuY (NSFW), which is not autolinked because otherwise you'll click it at work, won't you? Yeah. Copy and paste. </p>

<p>Anyways, while doing this, I took some notes on the startup sequence for firmware loading. Here's a picture of those notes:</p>

<p><a href="http://www.flickr.com/photos/qdot76367/2446569720/" title="Comm Trace notes for the Novint Falcon by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2030/2446569720_27520421f3.jpg" width="500" height="375" alt="Comm Trace notes for the Novint Falcon" /></a></p>

<p>Now, fast forward back to last week. Time to make everything equally fast.</p>

<p>To start, how the falcon communicates. Using the test firmware that came with the disc in the falcon box (currently the only thing I have mapped, and I honestly don't even know if there's other firmware out there), it receives 16 bytes input, and upon receiving that, gives back 16 bytes as output (it's actually 18 bytes, due to ftdi modem status being tacked on the front, but those are negliable). That's it.</p>

<p>Let's look at the stats that test programs were putting out for each platform (thanks to people on the libnifalcon-devel list for helping out on this):</p>

<p>Linux:</p>

<p>Time between I/O Iterations: 0.015991s<br />
Average Frequency: 62.534351 per second</p>

<p>Windows:</p>

<p>Time between I/O Iterations: 0.000942s<br />
Average Frequency: 980.382853 per second</p>

<p>Yeah. Bit of a difference, eh? So something was causing I/O iterations on linux to take around 16ms each, while on windows, we were getting 1 iteration per millisecond, and achieving near the 1khz that's mentioned by Novint all the time. This is running on the EXACT same code, up to the point of the FTDI library being used. The Windows version was using the ftd2xx drivers, while linux was using libftdi. ftd2xx on linux seemed to run decently fast, though I don't have the number handy at the moment.</p>

<p>Now, I'd read a few things around the net about libftdi being ridiculously slow, mostly in terms of bitbanging though. Either way, I figured it was something in either libftdi or libusb that was causing the slowdown. Rebuilt everything with -gp and let gprof at it for a while, just to see that, nope, it was just sitting there waiting during the I/O loop, for 16ms at a time.</p>

<p>At this point, I start wondering if it's not the synchronousity of libusb-0.1 that's slowing me down. Luckily, <A HREF='http://libusb.wiki.sourceforge.net/Libusb1.0'>libusb-1.0 is in development right now, which enable asynchronous transfers for usb</A>. Pulled the dev branch of that, tried it out. Asynchronous sends, writes are superfast, reads... 16ms.</p>

<p>Damnit.</p>

<p>So, something in the read is taking 16ms. It's time to start playing with our read transfer and see what else we can change. First off, changing the read request size to 64 bytes, the maximum packet size for the endpoint.</p>

<p>Time between I/O Iterations: 0.000919s</p>

<p>Well, that made something happy. The problem there is, we're now sending 1000 input packets, and only getting back ~250 output packets. This means that there was something I was missing about sub-maximal packet sizes. </p>

<p>Much googling insues. No information found. Finally out of frustration, I just google "ftdi 64 bytes".</p>

<p><A HREF='http://www.ftdichip.com/Documents/AppNotes/AN232B-04_DataLatencyFlow.pdf'>And I find the FTDI Addendum on Data Throughput, Latency, and Handshaking for the FT232 Series Chips</A> (PDF)</p>

<p>There it is, clear as day. There's a latency timer on the chip that will send bytes to the host assuming one of three conditions:</p>

<p><UL><LI>A serial status line (DTR, RTS, etc...) is flipped</LI><LI>The buffer reaches maximum capacity (Thus our results with the 64 bytes</LI><LI>The latency timer overflows</LI></UL></p>

<p>We're obviously not playing with the first one. The second one we've seen the effects of, but we don't want to have to wait for 62 user bytes at a time. </p>

<p>What's the default starting value of the latency timer?</p>

<p>16ms.</p>

<p>If you scroll back up and look at my notes again, you'll see there's a line there that says "0x9 (latency timer?) 0x1". This was a control message sent over by the Falcon test program. 0x9 is the control message index, and 0x1 is the value. They set the latency timer to 1ms during the initialization stage. I totally skipped over that when transcribing the code for the initialization sequence, and it meant I was sitting on slow code for many, many months.</p>

<p>I added that single line of code to the libusb-0.1.12/libftdi based libnifalcon libraries.</p>

<p>Time between I/O Iterations: 0.002019s</p>

<p>Yyyaaaaaayyyyyyyy!!waitaminute. 2 ms?</p>

<p>And thus, the synchronous call issue comes back to bite me in the ass, except this time, it's actually a correct diagnosis. </p>

<p>You see, when you send a USB message, it's packed into a USB frame. Each USB frame can carry multiple messages, but at a rate of 1 frame per millisecond (we're at USB 2.0 fullspeed here). libusb-0.1.12 only packs one request per frame, so we have 1ms input, 1ms output. 2ms overall, locking our I/O loop to 500hz. DAMNIT.</p>

<p>So, the solution to this is to either figure out a way to get both input and output in the same frame, which may be possible with libusb-1.0. That remains to be seen, and that code is still very, very alpha. I'll keep working with it, though.</p>

<p>Anyways, this still leaves a couple of questions. First off, when I was checking the ftd2xx drivers for linux, I decided to check their symbol table for the dynamic library...</p>

<p>...<br />
<pre><br />
         U time<br />
         U tolower<br />
         U toupper<br />
00013673 T usb_bulk_read<br />
0001357d T usb_bulk_write<br />
00017d30 B usb_busses<br />
000132ff T usb_claim_interface<br />
00014309 T usb_clear_halt<br />
000120e6 T usb_close<br />
</pre><br />
...</p>

<p>HEY! Those are libusb calls! So ftd2xx is at least partially based on libusb. How they're managing the superfast I/O, I'm not sure. Could be threading, could be they've got their own asynch thing going on.</p>

<p>Secondly, I obviously didn't have the latency timer set on the ftd2xx version of the drivers, either. Why did my drivers run so fast on windows without that? I'm guessing there could be a config file I was missing somewhere, or maybe their drivers just do it themselves on connection or something.</p>

<p>Anyways, the moral of the story: Read the god damn spec sheet. And all the addendums. And pay attention to your own notes.</p>]]>

</content>
</entry>

<entry>
<title>Direct Kinematics Solver for the Novint Falcon</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/04/direct-kinematics-simulator-for-the-novi.php" />
<modified>2008-04-18T07:13:32Z</modified>
<issued>2008-04-18T07:03:35Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1181</id>
<created>2008-04-18T07:03:35Z</created>
<summary type="text/plain"> I swear this makes more sense if you actually see it moving, but nonetheless, I now have a neat little DK simulator for the Novint Falcon, actually controlled by the Falcon itself. The buttons on the falcon can rotate/zoom...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2422071335/" title="OpenGL Falcon Direct Kinematics Solver by qdot76367, on Flickr"><img src="http://farm4.static.flickr.com/3200/2422071335_9eb017d3f7.jpg" width="485" height="500" alt="OpenGL Falcon Direct Kinematics Solver" /></a></CENTER></p>

<p>I swear this makes more sense if you actually see it moving, but nonetheless, I now have a neat little DK simulator for the Novint Falcon, actually <i>controlled</i> by the Falcon itself. The buttons on the falcon can rotate/zoom the camera on the model. The triangle in back in the fixed frame (which I have NO idea on the size on, since the falcon is weirdly setup. That's partially why I created this simulation, so I could just change numbers until things seem right.), the three big white spheres are the knee positions, and the one out in front is the end effector origin. </p>

<p>Outside of the fact that the simulator can't reliably pick which solution it wants to use (meaning sometimes it thinks the end effector ends up behind the fixed frame, oops), and that it's not mirroring the exact wonky angles the Falcon axes come out at, it works! And all in under a day's work. Not bad for being a little rusty on my OGL.</p>]]>

</content>
</entry>

<entry>
<title>Kinematics: A Less than Relaxing Hobby</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/04/kinematics-a-less-than-relaxing-hobby.php" />
<modified>2008-04-15T07:51:32Z</modified>
<issued>2008-04-15T06:52:34Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1180</id>
<created>2008-04-15T06:52:34Z</created>
<summary type="text/plain">So, in my eternal quest to understand every single god damn thing about the Novint Falcon before ever using it for anything interesting, I&apos;ve now dug up a bunch of information on Direct/Inverse Kinematic analysis of DELTA style parallel robots....</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>So, in my eternal quest to <A HREF='http://www.nonpolynomial.com/archives/2008/03/everything-i-know-about-the-novint-falcon.php'>understand every single god damn thing about the Novint Falcon</A> before ever using it for anything interesting, I've now dug up a bunch of information on Direct/Inverse Kinematic analysis of DELTA style parallel robots. Of course, at the end of all that digging, I found one paper that explains it pretty thoroughly.</p>

<p><A HREF='http://www.nonpolynomial.com/pdf/claveldelta.pdf'>Descriptive Geometric Kinematic Analysis of Clavel's Delta Robot</A>, P.J. Zsombor-Murray, McGill University</p>

<p>I'll be doing a "unwind the <A HREF='http://www.youtube.com/watch?v=TD1LHejil6M'>retroencabulatoresque</A> wording" post later, but for those of you used to reading engineering/math papers, check out the "Rationale" section. It contains a really awesome abstract algebraic version of "go fuck yourself".</p>

<p>Anyways, this paper has one problem. The pictures at the end are... engineery. Very, very engineery. Unreadably so. So, I decided to spend a little time working in that whole Second Life thing that I spend all of my day job time on, except actually doing something creative in it.</p>

<p><a href="http://www.flickr.com/photos/qdot76367/2415446632/" title="Diagram of IK/DK Derivations for a Clavel DELTA Robot by qdot76367, on Flickr"><img src="http://farm4.static.flickr.com/3067/2415446632_2a7f2f9061.jpg" width="500" height="357" alt="Diagram of IK/DK Derivations for a Clavel DELTA Robot" /></a></p>

<p>And thus, my reworking of the IK/DK derivation, which is a hell of a lot easier to understand visually (basically: Expand everything out to constraint spheres, find the meeting points of 2 of those spheres, logic out which is the correct point of the meeting of the 3 to save yourself the unnecessary processing). This can be seen at http://slurl.com/secondlife/Hyperborea/160/45/23/</p>

<p>Oh yeah. And actually, two problems with the paper, now that I think about it. Bricks of BASIC are not helpful as code. Ever. And this is literal brick, too. Whitespace is for bitches.</p>

<p>For anyone else wondering about the Falcon; the paper above expresses the direct kinematics in terms of hip angles. However, the falcon's a little different. It gives you back encoder values from the motors, so you're stuck with a single integer value that relates to the extension distance of the thigh. This is due to one of the nice features of the Falcon, though. The bent extension thigh (versus usual static rotation-only bar thingy, or at least, that's my made up mechanical engineering term for it) gives you a smaller footprint for the workspace than usual haptics deltas would give you, which is important since this was made to go on a gamer's desk. It's probably a bit more rugged too, since those nice rotational sensors in $30,000 equipment probably weren't made to take cheeto dust either. So, good for you on that one, Novint.</p>

<p>Anyways, what that means is the encoder values refer to some point on a 4" arc that the knee traces on the hip constraint sphere, instead of an angle. You can either translate between those to get your angle back and plug into his code, or wait for me to just post my finished code here. The encoder value is probably a faster way to do this, too, since I'm betting you can avoid floating point math at some point with it.</p>

<p>This, of course, will all happen as soon as I decide to stop spending time making pretty pictures and posting about how proud I am of said pretty pictures.</p>]]>

</content>
</entry>

<entry>
<title>Speaking at Leather Leadership Conference this Weekend</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/04/speaking-at-leather-leadership-conferenc.php" />
<modified>2008-04-10T06:17:36Z</modified>
<issued>2008-04-10T06:17:05Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1178</id>
<created>2008-04-10T06:17:05Z</created>
<summary type="text/plain"> Yup, it took all of a month for my &quot;no new speaking until I have something new to say&quot; thing to fall apart. But, well, this is different! Really! Somehow. :) So yeah, I&apos;m now part of the BDSM...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs News</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p><CENTER><A HREF='http://loc.leatherleadership.org/llc12/index.html'><IMG SRC='http://loc.leatherleadership.org/llc12/images/LLC_medal_250h.jpg' border=0></A></CENTER></p>

<p>Yup, it took all of a month for my "no new speaking until I have something new to say" thing to fall apart. But, well, this is different! Really! Somehow. :)</p>

<p>So yeah, I'm now part of the BDSM and Web 2.0 panel at <A HREF='http://loc.leatherleadership.org/llc12/index.html'>the 12th Annual Leather Leadership Conference</A>. The panel takes place Sunday, April 13th, at 10:30am. The panel will include Thomas Roche (who I was also on a panel with at Arse Elektronika, now of <A HREF='http://www.kink.com'>kink.com</A>), Richard Hunter (of <A HREF='http://www.mr-s-leather.com'>Mr. S Leather</A>), Steve Bower (Webmaster for the <A HREF='http://www.soj.org/main.html'>Society of Janus</A>),  and others. Should be fun!<br />
</p>]]>

</content>
</entry>

<entry>
<title>libnifalcon v0.2 and np_nifalcon Max/Pd patches finished</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/04/libnifalcon-v02-and-np-nifalcon-maxpd-pa.php" />
<modified>2008-04-06T06:03:40Z</modified>
<issued>2008-04-06T05:57:54Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1175</id>
<created>2008-04-06T05:57:54Z</created>
<summary type="text/plain">Well, v0.2 of libnifalcon is all done. Yay. That took a lot more work than I thought it would. Of course, I&apos;ve also now run into the nasty fact that libftdi is around 4x slower than ftd2xx, meaning that what&apos;s...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>Well, <A HREF='http://libnifalcon.sf.net'>v0.2 of libnifalcon is all done</A>. Yay. That took a lot more work than I thought it would. </p>

<p>Of course, I've also now run into the nasty fact that libftdi is around 4x slower than ftd2xx, meaning that what's a 1000hz update rate on windows ends up being 300hz max on Linux and OS X. Not happy about this at /all/, but there's really not much I can do outside of porting to a kernel driver probably. Which, yeah, I've thought about doing, because I hate myself.</p>

<p>Anyways, I've also finished Max and Pd patches for the falcon for all platforms, thus my first real released "application" for this. Only took me 9 months. Go me.</p>

<p>Now then, see if you can figure out which program is the free one, and which one is the expensive one:</p>

<p>Max/MSP:</p>

<p><a href="http://www.flickr.com/photos/qdot76367/2389032528/" title="np_nifalcon Max External Tutorial by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2289/2389032528_fcc6668dea.jpg" width="500" height="365" alt="np_nifalcon Max External Tutorial" /></a></p>

<p>PureData:</p>

<p><a href="http://www.flickr.com/photos/qdot76367/2391872168/" title="np_nifalcon PureData External Tutorial by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2336/2391872168_f84a82107a_o.jpg" width="406" height="313" alt="np_nifalcon PureData External Tutorial" /></a></p>

<p>Is there such a thing as a pretty PD patch? I have yet to see one.</p>]]>

</content>
</entry>

<entry>
<title>Everything I Know About the Novint Falcon as of March 2008</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/03/everything-i-know-about-the-novint-falcon.php" />
<modified>2008-03-26T07:05:27Z</modified>
<issued>2008-03-26T05:52:07Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1174</id>
<created>2008-03-26T05:52:07Z</created>
<summary type="text/plain">After my article on the Novint Falcon box got linked by GameSetWatch and Ars Technica, it seems like it might be time to do a nice, technical throwdown about what&apos;s going on, inside and out of the novint falcon, since...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>After <A HREF='http://www.nonpolynomial.com/archives/2008/03/that-thingy-that-feels.php'>my article on the Novint Falcon box</A> got linked by <A HREF='http://www.gamesetwatch.com/2008/03/gamesetlinks_from_falcon_to.php'>GameSetWatch</A> and <A HREF='http://arstechnica.com/journals/thumbs.ars/2008/03/25/novint-falcon-at-retail-problems-in-selling-haptic-controllers'>Ars Technica</A>, it seems like it might be time to do a nice, technical throwdown about what's going on, inside and out of the novint falcon, since everyone else seems hung up on games usage (I guess it's a game controller, but that's not the fun part!). I've been working with the Falcon since early August, and am actually getting fairly far with it.</p>

<p>If you didn't understand my box article, read on anyways. I'm gonna try to make this as understandable to everyone as possible, so you'll all learn C and inverse kinematics and algebraic geometry and come romp with me down the happy streets of writing a driver for a badly marketed piece of hardware no one is buying. </p>

<p>Come on, what other relaxing hobbies do you have that involve Jacobian Matrices, hmmmmm?</p>

<p>Please note: I have not used Novint's SDK. I do not plan on using Novint's SDK (That would be cheating). I don't know what their developer support is like (though Tom seems nice enough on the forums. Hi Tom!). What you see here is what I've gained from lots of web searching, talking to people that know what they're doing (I'm not a haptics engineer, in fact, this is my project to learn haptics engineering and programming), and randomly trying things while hoping I don't break the falcon. I'll wikify all of this information in time, but it's honestly much faster for me to brain dump in conversational blog mode than it is into a wiki. </p>

<p><B>So what the God Damn Hell is the Falcon anyways?!?!</B></p>

<p>It's everyone's favorite time of class, video time! <i>*wheels in the TV with bad color and hissing, blinking 12:00 VCR*</i></p>

<p>Seriously. I can't figure out how to explain it. Novint can't figure out how to explain it. So, watch this video, which tries to explain it.</p>

<p><object width="425" height="355"><param name="movie" value="http://www.youtube.com/v/f3r3od7nah4&hl=en"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/f3r3od7nah4&hl=en" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed></object></p>

<p>If you don't understand what it is yet, well, I can't help you anymore. But enjoy this randomly technical description that follows anyways. I worked hard on it, and I did it <B>JUST FOR YOU</B>. Yes, <i>you</i>.</p>

<p><B>A Little Background on Parallel Robots and Haptic Controllers</B></p>

<p>Before we dig into the guts, let's start with what you can find out before you take the case off the thing. For reference, here's a picture of the Falcon:</p>

<p><CENTER><IMG SRC='http://images.nonpolynomial.com/nonpolynomial.com/blog/falcon/falcon.jpg'></CENTER></p>

<p>A bit of background (this will contain much glossing as I'd like to focus on the falcon, but it's good to have a knowledge of what's out there otherwise). In the world of haptics, there are two major types of controllers. Serial (pen type controllers), and parallel. <A HREF='http://www.bracina.com/haptichardware.html'>An overview of a bunch of the different hardware types is available in an article on bracina.com</A>. </p>

<p>The NovInt Falcon is a <A HREF='http://www.parallemics.org'>parallel robot</A>. <A HREF='http://en.wikipedia.org/wiki/Parallel_manipulator'>Parallel robots</A> are called such because they have multiple chains of joints working together to create the final position of the controller (or end effector, if you want to be technical about it). Not to mention, the math uses parallelograms to line up the positions.  </p>

<p>If you watch a lot of How It Works (which, if you have cable with the Discovery Channel, you invariably end up doing no matter what. That show is video heroin.), you've seen these before. </p>

<p><CENTER><IMG SRC='http://images.nonpolynomial.com/nonpolynomial.com/blog/falcon/parallel1.jpg'></CENTER></p>

<p>They're real popular in pick and place operations. That's exactly what it sounds like. Pick something up, put it somewhere else. Repeat ad inifinitum. Puttin' things in or on other things. They're good at that. </p>

<p>Here's one in action.</p>

<p><CENTER><object width="425" height="355"><param name="movie" value="http://www.youtube.com/v/wzvYsklwKqk&hl=en"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/wzvYsklwKqk&hl=en" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed></object></CENTER></p>

<p>So, you're probably like "But it's all pointing down"</p>

<p><CENTER><IMG SRC='http://images.nonpolynomial.com/nonpolynomial.com/blog/falcon/parallel2.jpg'></CENTER></p>

<p>Ok, look more familiar now? The NovInt Falcon is a parallel robot <i>turned on its side</i>. It's actually a Delta variant of the parallel manipulator (<A HREF='http://www.eurohaptics.vision.ee.ethz.ch/2001/grange.pdf'>Here's a nice overview of the Delta Haptic Device, which is quite similar to the Falcon/Omega setup</A>). If you want all sorts of interesting history about where it came from, <A HREF='http://www.parallemic.org/Reviews/Review002.html'>check out this article on parallemics.org</A>. But for now, we'll just say: France. It came from France.</p>

<p>There's lots of reasons why using parallel robots in haptics is important. However, I don't quite understand the math behind it all yet, so I'll just repeat what all the webpages say. "Good stiffness and accuracy in a small workspace". Having used some serial controllers before, I can see what they mean. Hard definitely feels... hard. I'm sure I'll be talking more about this in later articles on the development of <A HREF='http://libnifalcon.sourceforge.net'>libnifalcon</A>.</p>

<p>To show a bit of what else is out there, here's the <A HREF='http://www.forcedimension.com/'>ForceDimension and their Omega series of controllers</A>.</p>

<p><CENTER><IMG SRC='http://images.nonpolynomial.com/nonpolynomial.com/blog/falcon/omega3_2.jpg'></CENTER></p>

<p>Once again, looks familiar, no?</p>

<p>Well, one major difference.</p>

<p>The Falcon is $249US.</p>

<p>The Omega starts at around $20,000US (the more degrees of freedom, the more expensive. The Omega 7 is around $50k.)</p>

<p>Ok, and the Omega comes with a PCI interface and all sorts of APIs and what not and FD is actually an offshoot of the subset of France that we mentioned above that created this whole thing in the first place, but still. That's some significant 0's worth of difference there.</p>

<p>There's rumors that ForceDimension helped out on the Falcon design. There's also rumors that it came from Sandia with Tom. Only Art Bell truly knows.</p>

<p>So why all this about parallel robots? Well, many future posts will be talking about research in this field, so I figured I'd at least introduce the term. There's also lots of reference and searchable material in here if you're interested in going your own direction with this information. Anyways, back to hackyness.</p>

<p><B>Internal Circuitry</B></p>

<p>Now that we've got that out of the way, what's inside it?</p>

<p>Click the image below to go to an annotated flickr picture of the insides. </p>

<p><a href="http://www.flickr.com/photos/qdot76367/2275967695/" title="The Inside of the Falcon by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2093/2275967695_20b971efce.jpg" width="500" height="334" alt="The Inside of the Falcon" /></a></p>

<p>Connectors:<br />
<UL><LI>USB B Connector</LI><LI>Power Connector - goes to 30V 1A wall wart of DOOM</LI></UL></p>

<p>Yes, the falcon is quite possibly cranking 30W through the motors when you max the torque on all the axes.</p>

<p>Chips (Links to Datasheets or Product Websites):<br />
<UL><LI><A HREF='http://www.ftdichip.com/'>FTDI FT232R</A> USB to Serial Chip</LI><LI><A HREF='http://www.microchip.com/stellent/idcplg?IdcService=SS_GET_PAGE&nodeId=1335&dDocName=en010215'>PIC 16F688 Microcontroller</A></LI><LI><A HREF='http://focus.ti.com/docs/prod/folders/print/tms320r2811.html'>TI TMS320 R2811</A> DSP Processor</LI></UL></p>

<p>I don't have specific parts on the 3 motor blocks in the circuit (they're all exactly the same), but what you've basically got going on there is three really large old style mouse encoders. Each of the 3 large wheels attached to the motors have a disc attached to them, alternating little clear slots with opaque slots. There's a photoresistor that shines light through those slots. Whenever the light goes through (clear), you get a 1. Whenever the light is blocked (opaque), you get a zero. And that's how we know how far the motor has gone. </p>

<p>Whether direction is measured using some sort of quadrature encoding or Back-EMF polarity is something I forgot to check (but will do so at the point where I can figure out how to write my own firmware for this thing).</p>

<p><B>Communications and Initialization/Bootloading Sequence</B></p>

<p>Now, for the part I kinda sorta know more about than the other parts. </p>

<p>The Falcon uses the FTDI chip as it's main communications link to the computer. Everything is filtered back and forth through the FTDI chip, converting from USB on the computer side to RS232 on the circuit side. This is because it's orders of magnitude easier to program your microcontrollers to talk RS232 than it is to talk USB. </p>

<p>Novint distributes and uses the stock FTDI driver with their software. The only change they've made is to the VID and PID. They've chosen to use <A HREF='http://www.ftdichip.com/FTDrivers.htm'>FTDI's free "have a PID" program</A>, which has them listed under FTDI (0x0403) as a vendor, but with their own special product ID (0xcb48, as opposed to the default PID for FTDI chips, 0x6001).</p>

<p><i>NOTE: I have not actually proven this next paragraph, it's more what I think is going on than anything.</i> You might've noticed in the Internal Circuitry section that there are two microcontrollers on the board: the PIC and the TI. This is where the bootloader sequence comes in. The TI DSP uC is actually reconfigurable on connection to a PC. The PIC acts as a bootloader, maintaining the logic needed to run the FTDI communications to pick up firmware and program the TI with it. This allows a developer (currently just Novint, since I've had no luck analyzing the pins. Stupid tiny LQFP pins and my shaky hand.) to possibly speed up the control loop on the internal processor depending on application specific needs. Damn fine idea, even if it did crank the price of the hardware quite a bit, I'm sure.</p>

<p>When a program wants to connect to the falcon, the following sequence occurs (if you want to follow along, check out <A HREF='http://libnifalcon.svn.sourceforge.net/viewvc/libnifalcon/trunk/libnifalcon/src/nifalcon_libftdi.c?view=lo'>nifalcon_libftdi.c</A>). Note that the bauds get funky, because baud rate actually turns into a clock subdivision on the board, so I just converted the rate to the lowest clock subdivision possible that would still make them work. See the How I Mapped The Test Firmware Protocol section for more info.</p>

<p><UL><LI>Open connection to FTDI chip</LI><LI>The "Are we at least connected" Step:</LI><UL><LI>Set to 9600 8N1, No Flow Control, DTR High</LI><LI>Write a 3 byte check message, {0x0a, 0x43, 0x0d}</LI><LI>Read, expect 5 bytes back</LI></UL><LI>The "Send the firmware over" Step:</LI><UL><LI>Set 140000 baud, DTR Low</LI><LI>Write a single byte (Usually 0x41 "A")</LI><LI>Read, expect same byte back</LI><LI>Send firmware file in 128 byte chunks</LI><LI>Read, expect exact chunk we sent back from the falcon as error check</LI></UL><LI>The "Ready To Go" Step:</LI><UL><LI>Set baud to 1456213 (Maximum for the chip?)</LI></UL></UL></p>

<p>After we've gotten this far, we're ready to run an I/O loop to the falcon.</p>

<p><B>The Test Firmware</B></p>

<p>So far, the only firmware that's usable with code I've written is what I call the "test" firmware. This is the NOVINT.BIN file included with the drivers, that the utilities in "c:\Program Files\Novint\Falcon\TestUtilities\" in a normal windows nVent (I HATE NVENT but that's an article for another day) install will use.</p>

<p>Rather than repeat the info here, if you're interested in the packet layout of the test firmware, <A HREF='http://wiki.nonpolynomial.com/NovintFalcon'>check out my wiki page on it</A>. </p>

<p>Note, however, that there are a few things you might not be aware of. First off, when you set a motor torque, it's only for a very short period of time (Haven't scoped out the exact value). Basically, you're expected to be polling the falcon <i>constantly</i> and setting the torques as needed. The controlling program is closing the control loop to the falcon, as just keeping torques on until next update can cause lots of badness (motor wear, crunched fingers, etc...)</p>

<p><B>Goals of the libnifalcon Project</B></p>

<p>So, that's pretty much all I know about this thing right now. I'm working on learning the math behind the haptics and placement algorithms, and while I learn, you'll get to learn along with me, in the form of reading my ridiculously long blog posts!</p>

<p>All of this is going into code form in the <A HREF='http://libnifalcon.sourceforge.net'>libnifalcon</A> project on Sourceforge. As of this writing, v0.2 is sitting in the repository waiting for me to finish a few cleanup things.</p>

<p>Here's a few applications I have planned for <A HREF='http://libnifalcon.sourceforge.net'>libnifalcon</A>:</p>

<p><UL><LI>Max/MSP and PureData Patch (already done, just needs to be cleaned, threaded, and released. It's in the repository if you absolutely can't wait)</LI><LI>Mouse movement/simulation</LI><LI>Basic open source haptics library integration</LI><LI>Mapping the TMS320 pins and possibly starting on my own firmware</LI></UL></p>

<p>As you can see, right now I'm more interested in getting a code platform built and teaching myself haptics programming from the ground up than I am in implementing any specific application. However, I do spend a lot of time in Pd playing with the falcon at the moment, and will most likely be posting interesting projects out of that in between code geekouts.</p>

<p><B>Aside 1: How I Mapped the Test Firmware Protocol</B></p>

<p>Mapping the test firmware protocol was fairly easy. I used <A HREF='http://www.pcausa.com/Utilities/UsbSnoop/default.htm'>SniffUSB</A> to record the packets going to/from the Falcon in the test programs, then compared the data in those with the protocol mapping for the FTDI available in the <A HREF='http://www.intra2net.com/de/produkte/opensource/ftdi/'>libftdi</A> source code. The bootloader code is basically a handwritten replay of this sequence, except translated back into FTDI driver calls instead of pure USB comms, hence some of the weirdness in the explanation (the "send 3 get back 5" seqeuence, the odd baud rates, etc...). </p>

<p>This was, quite literally, all it took. No amazingness or code breaking or whatever. Figuring out the packet setup was just a matter of mapping the numbers from the test GUI to the changing bytes of the packets. </p>

<p><B>Aside 2: FTD2XX versus <A HREF='http://www.intra2net.com/de/produkte/opensource/ftdi/'>libftdi</A>, Operating Systems, and You</B></p>

<p><A HREF='http://libnifalcon.sourceforge.net'>libnifalcon</A> comes in two flavors right now.</p>

<p><UL><LI><A HREF='http://www.ftdichip.com'>FTD2XX</A></LI><UL><LI>This is the driver that FTDI distributes, and the one that the default Windows Falcon drivers use. It seems fine on windows, outside of the fact that I personally have issues connecting the Falcon through a hub. This may or may not be due to my machine. However, this drivers seem wildly unstable on Mac and Linux. Also, they have no versions available for 64-bit Linux</LI></UL><LI><A HREF='http://www.intra2net.com/de/produkte/opensource/ftdi/'>libftdi</A></LI><UL><LI>This is the free, reverse engineered version of FTDI's drivers, that use libusb. They seem to be stable across all platforms, though I only recommend using them for anything non-windows (or non-publically distributed on windows. Don't make people switch drivers if you don't have to.). It's GPL'd, too, so if you want to use libnifalcon under <A HREF='http://www.intra2net.com/de/produkte/opensource/ftdi/'>libftdi</A>, you're stuck with the GPL too. Meh.</LI></UL></UL><br />
</p>]]>

</content>
</entry>

<entry>
<title>&quot;That thingy that feels&quot;</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/03/that-thingy-that-feels.php" />
<modified>2008-03-18T06:45:05Z</modified>
<issued>2008-03-18T06:32:35Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1172</id>
<created>2008-03-18T06:32:35Z</created>
<summary type="text/plain">Having just finished up my libnifalcon page, I decided to post a few replies on the novint forums since libnifalcon had been coming up over there too over the past month, and since they haven&apos;t sued me yet, I figure...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs News</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>Having just finished up my <A HREF='http://libnifalcon.sourceforge.net'>libnifalcon</A> page, I decided to post a few replies on the novint forums since libnifalcon had been coming up over there too over the past month, and since they haven't sued me yet, I figure I'm ok.</p>

<p>I also decided to post some observations I had about their packaging. Reposting here to get people's opinions, since I know more than a few designers (both game and print/web) read this blog:</p>

<p><HR></p>

<p>First off, the packaging in question:<br />
<CENTER><a href="http://www.flickr.com/photos/qdot76367/2342792096/" title="Novint Falcon Packaging by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2148/2342792096_3bd54159cc_m.jpg" width="180" height="240" alt="Novint Falcon Packaging" /></a></CENTER></p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2342792496/" title="Novint Falcon Packaging by qdot76367, on Flickr"><img src="http://farm4.static.flickr.com/3177/2342792496_d9a2929660_m.jpg" width="180" height="240" alt="Novint Falcon Packaging" /></a></CENTER></p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2342792768/" title="Novint Falcon Packaging by qdot76367, on Flickr"><img src="http://farm4.static.flickr.com/3045/2342792768_4a8524150e_m.jpg" width="180" height="240" alt="Novint Falcon Packaging" /></a></CENTER></p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2341964071/" title="Novint Falcon Packaging by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2132/2341964071_4544e2965d_m.jpg" width="180" height="240" alt="Novint Falcon Packaging" /></a><br />
</CENTER></p>

<p><HR></p>

<p>So I was picking up some Falcons at a local CompUSA closing sale ($49!), and while giggling to myself that I was getting falcons for cheap (now I have 3!), a random person asked me what these large boxes I was carrying across the store awkwardly were.</p>

<p>It's then that I realized: there were 5 falcons left at the store. This was the last day it was going to be open. They were $49. Not even the people picking stuff up cheap the rehawk in downtown were getting them. Not good. </p>

<p>After setting the boxes down and trying to explain why 3 DOF haptics is important for immersion (which boiled down to "stuff like, feels, and stuff"), I realized there's nothing on the boxes to explain to anyone without some training in haptics hardware (i.e. anyone without medical or industrial robotics experience) what a falcon /is/. </p>

<p>I realize this is a really, really hard problem. Everyone I know that's excited about the falcon falls into two groups:</p>

<p>(1) They have an advanced degree and knows how much this hardware costs when packaged as a research tool or<br />
(2) They've actually used one.</p>

<p>The problem here is, neither of the groups can use word of mouth to convey the experience. It usually ends up in overly technical talk ("~1/800th inch encoder tick resolution per axis!"), or wild gesticulation and adjectives that don't quite fit the experience. Good for the user, bad for the uneducated customer. The choir can hardly preach to itself.</p>

<p>Not that I have any insight on this, but the box seems to be taken up by lots of pictures of the controller itself, with no informational diagrams about how it's used. In situations where you can't have one out (which is often, since it's awful big), this might help a lot.<br />
</p>]]>

</content>
</entry>

<entry>
<title>Upcoming Conference List</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/02/upcoming-conference-list.php" />
<modified>2008-02-18T08:24:25Z</modified>
<issued>2008-02-18T08:20:46Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1169</id>
<created>2008-02-18T08:20:46Z</created>
<summary type="text/plain">Yup, it&apos;s spring again, and it snuck up on me this time. First off, it&apos;s year 3 of GDC for me. Not speaking during the conference, though you can at least catch me at Brenda Braithwaite&apos;s Sex in Games Roundtables...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>Personal Posts</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>Yup, it's spring again, and it snuck up on me this time.</p>

<p><CENTER><A HREF='http://www.gdconf.com'><IMG SRC='http://images.nonpolynomial.com/slashdong.org/blog/gdc2008.jpg' BORDER=0></A></CENTER></p>

<p>First off, it's year 3 of GDC for me. Not speaking during the conference, though you can at least catch me at Brenda Braithwaite's Sex in Games Roundtables on <A HREF='https://www.cmpevents.com/GD08/a.asp?option=C&V=11&SessID=6397'>Wednesday</A> and <A HREF='https://www.cmpevents.com/GD08/a.asp?option=C&V=11&SessID=6548'>Thursday</A>, plus the various parties (Here's crossing my fingers for another World of Darkness party like last year. More game conferences need dominatrixes).</p>

<p><CENTER><A HREF='http://conferences.oreilly.com/etech/'><IMG SRC='http://images.nonpolynomial.com/slashdong.org/blog/etech2008.jpg' BORDER=0></A></CENTER></p>

<p>Wednesday, March 5th, it's off to <A HREF='http://conferences.oreilly.com/etech/'>O'Reillys Emerging Technologies Conference</A>, where I'm giving a talk on the usual (teledildonics and intimate interfaces). Due to the fact that I'm poor and SD is expensive, I'm only in for the day of my talk, so look for me on Wednesday if you're around.</p>

<p>And then... Nothing. Yes, I have absolutely no planned speaking engagements after that, and I plan on keeping it that way for a while.</p>]]>

</content>
</entry>

<entry>
<title>WiiYo Project Update</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/02/wiiyo-project-update.php" />
<modified>2008-02-11T06:45:27Z</modified>
<issued>2008-02-11T06:39:54Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1166</id>
<created>2008-02-11T06:39:54Z</created>
<summary type="text/plain">Well, I finally got new LEDs in, thanks to the nice people at Renoylds Electronics, who shipped another batch of LEDs after the first got lost in transit. I replaced the LEDs currently on the yoyo with OED-EL-1L2s, which have...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>Well, I finally got new LEDs in, thanks to the nice people at <A HREF='http://www.rentron.com'>Renoylds Electronics</A>, who shipped another batch of LEDs after the first got lost in transit. I replaced the LEDs currently on the yoyo with <A HREF='http://www.rentron.com/remote_control/IRLED.htm#1L2'>OED-EL-1L2s</A>, which have a 60 degree beam angle. This seems to have made a ton of difference, as the drawing program now makes tricks identifiable, especially with the scribbles where hold points are.</p>

<p>For instance, a sleeper:</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2256612367/" title="sleeper by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2258/2256612367_255047d5cf_m.jpg" width="240" height="180" alt="sleeper" /></a></CENTER></p>

<p>And a trapeze:</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2256612379/" title="trap by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2285/2256612379_d2f6227706_m.jpg" width="240" height="180" alt="trap" /></a></CENTER></p>

<p>Next step is getting all of this out of Max/MSP and into either <A HREF='http://puredata.info'>PD</A> or <A HREF='http://www.openframeworks.cc'>OpenFrameworks</A>, as my Max demo license ran out and I'm not throwin' down the cash until they finally announce their pricing scheme for Max 5.</p>]]>

</content>
</entry>

<entry>
<title>27: A year in brief review</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/01/27-a-year-in-brief-review.php" />
<modified>2008-01-17T07:25:04Z</modified>
<issued>2008-01-17T07:08:50Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1165</id>
<created>2008-01-17T07:08:50Z</created>
<summary type="text/plain">Yup, it&apos;s that time again. As the year revolves around my birthday (and not January 1st, but god bless you all for getting close), it&apos;s time for me to do a retrospective of my year of being 27 (on the...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>Personal Posts</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>Yup, it's that time again. As the year revolves around my birthday (and not January 1st, but god bless you all for getting close), it's time for me to do a retrospective of my year of being 27 (on the day before I cease being it), as seen through my public identity of aggregated 0's and 1's stored on servers around the world. It's my time to sit here and realize that I still have yet to make that great mathematical discovery, and I'm losing time quickly (it becomes impossible at age 30).</p>

<p>So, this year, I:</p>

<p>- Lived outside of Oklahoma for a full year for the first time, ever.<br />
- <A HREF='http://qdot.livejournal.com/196134.html'>Open sourced a dance accidently.</A><br />
- <A HREF='http://qdot.livejournal.com/202910.html'>Perverted a web service and then turned it into furniture</A><br />
- <A HREF='http://qdot.livejournal.com/213423.html'>Slapped together generative art</A><br />
- <A HREF='http://qdot.livejournal.com/230049.html'>And then slapped together some more generative art</A><br />
- <A HREF='http://qdot.livejournal.com/220788.html'>And some hand followy lights</A><br />
- <A HREF='http://qdot.livejournal.com/231282.html'>And hooked a yoyo to a wiimote</A><br />
- <A HREF='http://www.synthtopia.com/content/2007/11/26/moaning-lisa/'>Helped build knob boobs</A><br />
- <A HREF='http://www.flickr.com/photos/qdot76367/sets/72157601249957353/'>Went to my first SIGGRAPH</A><br />
- <A HREF='http://www.monochrom.at/arse-elektronika/about.html'>Helped organize a conference after I explicitly said I'd never do that again</A><br />
- Started my first open source projects (versus just helping on them) (<A HREF='http://sourceforge.net/projects/libnifalcon'>libnifalcon</A>, <A HREF='http://sourceforge.net/projects/libtrancevibe'>libtrancevibe</A>, <A HREF='http://sourceforge.net/projects/liblightstone'>liblightstone</A><br />
- Learned two new languages (Python, Max)<br />
- A bunch of other stuff I'm not documenting here, like awesome new people I met and all that.</p>

<p>Well. It was no <A HREF='http://qdot.livejournal.com/149780.html'>2005</A>, but it'll do. <br />
</p>]]>

</content>
</entry>

<entry>
<title>WiiYo: IR LED + Yoyo + WiiMote</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/01/wiiyo-ir-led-yoyo-wiimote.php" />
<modified>2008-01-14T07:54:41Z</modified>
<issued>2008-01-14T06:13:52Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1164</id>
<created>2008-01-14T06:13:52Z</created>
<summary type="text/plain">Taking some inspiration from Johnny Chung Lee&apos;s WiiMote Projects, I decided I&apos;d like to figure out something neat to do with the WiiMote&apos;s IR Camera. I didn&apos;t realize that it&apos;s 1024x768 @ 100hz for up to 4 IR points (with...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>NP Labs Projects</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>Taking some inspiration from <A HREF='http://www.cs.cmu.edu/~johnny/projects/wii/'>Johnny Chung Lee's WiiMote Projects</A>, I decided I'd like to figure out something neat to do with the WiiMote's IR Camera. I didn't realize that it's 1024x768 @ 100hz for up to 4 IR points (with 4 bits of depth, even), which gives you enough resolution to do some interesting stuff.</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2192046336/" title="yoyoproject by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2380/2192046336_40962cb9bc.jpg" width="500" height="375" alt="yoyoproject" /></a></CENTER></p>

<p>For those of you that haven't known me a while, you might not be aware that I used to yoyo quite a bit. I still play every so often, but not nearly as much as I used to. I ended up building up quite the collection, though. Something I always wanted to be able to do was yoyo tracking. I played a little bit with blob tracking and LEDs, but didn't have the hardware or experience back then (2000-2001ish) to really do what I wanted.</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2191251499/" title="yoyoproject 005 by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2239/2191251499_bd418c6510.jpg" width="500" height="375" alt="yoyoproject 005" /></a></CENTER></p>

<p>After seeing the head tracking and finger tracking videos, the first thing I thought of was trying the yoyo project again. Without taking the time to actually look at my collection, I decided to drill up an old freehand pog and electric tape it to my Pyro with a CR2032 pack attached to the back of the pog for power.</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2192039408/" title="yoyoproject 006 by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2415/2192039408_30013b1db0.jpg" width="500" height="375" alt="yoyoproject 006" /></a></CENTER></p>

<p>This ended up being such a colossally bad idea that I'm not gonna spend much time talking about it. The yoyo was unusably unbalanced. So, digging through my yoyo box somemore, I realized I still had some Torch LED pogs.</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2192039620/" title="yoyoproject 009 by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2277/2192039620_3792f6a831.jpg" width="500" height="375" alt="yoyoproject 009" /></a></CENTER> </p>

<p>I removed the Red LED off of these and replaced it with an IR LED and a smaller resistor. Since I didn't really have any Spintastics yoyos I wanted to throw the pog in, I ended up dismantling my already sort of broken Night Moves 2 (the plastic on the axle end had cracked on it a while ago for some reason), and hot gluing the pog in to hold it. Sure enough, the yoyo was slightly unbalanced, but completely usable for most any trick. After ninja starring the pog due to not having hot glued it well enough the first time, I made sure to do a better job, and now I have an IR yoyo!</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2192039668/" title="yoyoproject 010 by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2025/2192039668_8ddc30c628.jpg" width="500" height="375" alt="yoyoproject 010" /></a></CENTER></p>

<p>So, with yoyo+wiimote setup finished, I fired up Max/MSP and used the <A HREF='http://www.iamas.ac.jp/~aka/max/'>aka.objects wiiremote and appleremote</A> externals along with the LCD object to make a little drawing program. The Apple Remote works as a pen start/stop and clearing device, so I can clear the screen and start/stop drawing while standing far back from the computer. The Wiimote external is wired to draw lines depending on the first IR readout from the camera.</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2187280106/" title="gerbil by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2028/2187280106_abb8570bf4.jpg" width="500" height="375" alt="gerbil" /></a></CENTER></p>

<p>The above picture is a drawing from that program, of an almost-but-not-really version of the <A HREF='http://sector_y.yoyoing.com/Tricks/String_Tricks/Skin_the_Gerbil/Skin_the_Gerbil.htm'>"skin the gerbil" trick</A> by <A HREF='http://www.doctorpopular.com'>Doctor Popular</A>. </p>

<p>The picture also shows a couple of the current problems with the system. First off, I've completely trashed my office getting this done, so I can't back up very far and don't have a good idea of what the Wiimote is seeing. This could be fixed by calibration, which is something I plan on figuring out. Secondly, there's some sampling issue with large swings. Either my swings are causing tilt, the LED doesn't have a wide enough angle, or some combination of the two. I've ordered 5 more kinds of LEDs to test this.</p>

<p><CENTER><a href="http://www.flickr.com/photos/qdot76367/2190430077/" title="patchpic by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2228/2190430077_16ae778335.jpg" width="500" height="314" alt="patchpic" /></a></CENTER></p>

<p>Finally, I hooked up a little sample looper in Max/MSP to the setup so that it would spit out some noise, too.</p>

<p><CENTER><object width="425" height="355"><param name="movie" value="http://www.youtube.com/v/9RqBJgGNiE8&rel=1"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/9RqBJgGNiE8&rel=1" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed></object></CENTER><br />
 <br />
This video is a combination of the drawing and the video, processed through Jitter. Warning, the sound is VERY desynchronized from the video. 100% of my experience with Jitter has happened in the last 24 hours, and apparently I missed something about getting the video to synchronize (realtime setting, maybe?), which is why the sound doesn't match the video.</p>

<p>So, that was my weekend. The project still has a long way to go. I've got 2 more Torch boards to mod once the LEDs come in, and it'll be interesting to see which LEDs work best. I should have those later this week. I also plan on modding a spintastics top I have that has a torch board in it, so I can do Augmented Reality Battle Tops. </p>

<p>Have any interesting ideas for this project? Please leave comments! Seems like there's a million places this could go. </p>]]>

</content>
</entry>

<entry>
<title>Twittercore: Generative Internet Noise</title>
<link rel="alternate" type="text/html" href="http://www.nonpolynomial.com/archives/2008/01/twittercore-generative-internet-noise.php" />
<modified>2008-01-06T08:41:32Z</modified>
<issued>2008-01-06T08:40:02Z</issued>
<id>tag:www.nonpolynomial.com,2008://13.1161</id>
<created>2008-01-06T08:40:02Z</created>
<summary type="text/plain">The week of getting half-done projects to 3/4th done continues. GENTLEMEN, BEHOLD: Twitter Breakcore I created this back in September, when I was taking my Max/MSP classes at RobotSpeak. I decided to try layering twitter public timeline messages run through...</summary>
<author>
<name>qDot</name>
<url>http://www.numberporn</url>
<email>qdot@numberporn.com</email>
</author>
<dc:subject>Personal Posts</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://www.nonpolynomial.com/">
<![CDATA[<p>The week of getting half-done projects to 3/4th done continues.</p>

<p>GENTLEMEN, BEHOLD:</p>

<p><A HREF='http://www.30helensagree.com/mcinterwebz/'>Twitter Breakcore</A></p>

<p><a href="http://www.flickr.com/photos/qdot76367/2139791847/" title="twittercore by qdot76367, on Flickr"><img src="http://farm3.static.flickr.com/2189/2139791847_34dca32750_m.jpg" width="213" height="240" alt="twittercore" /></a></p>

<p>I created this back in September, when I was taking my Max/MSP classes at <A HREF='http://www.robotspeak.com'>RobotSpeak</A>. I decided to try layering <A HREF='http://www.twitter.com'>twitter</A> public timeline messages run through text-to-speech over fairly simple looped break samples, because noise + noise = noise.</p>

<p>Unfortunately, either Py/Ext or flite~ is causing Max/MSP to crash about 20-30 minutes in, regularly, so having a full time stream running is a bit of an issue right now. However, I made a small 2.5 minute track. </p>

<p><A HREF='http://www.30helensagree.com/mcinterwebz/twittercore1.mp3'>"actively gnawing on some guy's head"</A> (MP3, 2:20)</p>

<p>Lyrics:<br />
systems over single channel, IP<br />
Have fun and be safe. Happy New Year to you too. xx<br />
Bob Sinclar Ft Steve Edwards - World Hold On (David Guetta And Joachim Garraud Remix)<br />
Night Night everyone!!! xoxoxoxoxoxoxo<br />
comiendo pizza con cerveza de tercio..... perfect<br />
, do you ever get to see the wildlife?<br />
the internet by design is a communications platform. the goal is to put old communications systems over single channel, IP<br />
Back from dinner. Answering a few emails then watching Helvetica.<br />
Christmas Cheer? MST3k Santa #521 on Google Video<br />
mmmmm..... Ribs :). Lol<br />
Back in Columbus. Found 5 dead roaches in my apartment. Bleh.<br />
no run. GB Hogg to SC Ganguly, no run, fuller and on the off, driven hard but straight to cover<br />
no run. MG Johnson to SR Tendulkar, no run, full and outside the off, left alone, this one doesn't bounce too much and scoots along to t ...<br />
posteando<br />
Spacetime Continuum - Kairo (Carl Craig Mix)<br />
Helpful Tip: Don't let your brother-in-law take you to "I Am Legend."<br />
Rosie - Another Rosie Christmas<br />
Baby break dancing!<br />
when am i coming by for pie again?<br />
contestando mails de laburo :(<br />
I love spark people ! Haha. Going to sleep soon.<br />
Went to Kohl's tonight... I don't even know why I bother with that place.<br />
Borre bastantes twiteros ke no twiteaban como hace 1 o 2 meses!...<br />
congratulations on your laptop!<br />
is it just me or does firefox seem to get less and less stable with every patch?<br />
In San Jose, Ca<br />
queda una no tan larga noche por delante.<br />
“Arguments with furniture are rarely productive.”<br />
To be fair, it was actively gnawing on some guy's head when they shot it.<br />
i'm in ur eharmonies, communicatin' wif ur matches.</p>]]>

</content>
</entry>

</feed>