<?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/"
	>

<channel>
	<title>[protofusion]</title>
	<atom:link href="http://protofusion.org/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>http://protofusion.org/wordpress</link>
	<description>Generally Interesting</description>
	<lastBuildDate>Mon, 26 Jul 2010 18:18:57 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>JavaScript &#8220;Current Filename&#8221; Function</title>
		<link>http://protofusion.org/wordpress/2010/07/javascript-current-filename-function/</link>
		<comments>http://protofusion.org/wordpress/2010/07/javascript-current-filename-function/#comments</comments>
		<pubDate>Mon, 26 Jul 2010 16:01:18 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[Quick Tips]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[quick tip]]></category>
		<category><![CDATA[web design]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=621</guid>
		<description><![CDATA[I found the need to get the current filename, without the file extension, of a webpage using javascript. I made ]]></description>
			<content:encoded><![CDATA[<p>I found the need to get the current filename, without the file extension, of a webpage using javascript. I made a quick function to take care of this task that might save you some time.</p>
<pre class="brush: jscript;">
function getCurrentFile() {
  var filename = document.location.href;
  var tail = (filename.indexOf(&quot;.&quot;, (filename.indexOf(&quot;.edu&quot;)+1)) == -1) ? filename.length : filename.lastIndexOf(&quot;.&quot;);
  return (filename.lastIndexOf(&quot;/&quot;) &gt;= (filename.length - 1)) ? (filename.substring( filename.substring(0, filename.length - 2).lastIndexOf(&quot;/&quot;)+1, filename.lastIndexOf(&quot;/&quot;))).toLowerCase() : (filename.substring(filename.lastIndexOf(&quot;/&quot;)+1, tail)).toLowerCase();
}
</pre>
<p>This function returns the current filename (minus the file extension) in all lower-case. Feel free to modify it to suit your needs. It also works properly even when a URL does not have a file extension (such as with some asp-based sites), or when there is no filename present (returns the folder name). This function is great for highlighting menu items based on which page the user is currently browsing.</p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/07/javascript-current-filename-function/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Converting .MTS video files into .mp4 files</title>
		<link>http://protofusion.org/wordpress/2010/07/converting-mts-video-files-into-mp4-files/</link>
		<comments>http://protofusion.org/wordpress/2010/07/converting-mts-video-files-into-mp4-files/#comments</comments>
		<pubDate>Wed, 21 Jul 2010 04:34:04 +0000</pubDate>
		<dc:creator>NEO</dc:creator>
				<category><![CDATA[Quick Tips]]></category>
		<category><![CDATA[avidemux]]></category>
		<category><![CDATA[conversion]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=568</guid>
		<description><![CDATA[I have a Canon HF200 video camera and it outputs HD video, but it&#8217;s in .MTS file format. This is ]]></description>
			<content:encoded><![CDATA[<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/convert-mts-to-mp4.jpg" rel="lightbox[568]"><img class="alignnone size-large wp-image-615" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/convert-mts-to-mp4-500x206.jpg" alt="" width="500" height="206" /></a></p>
<p>I  have a Canon HF200 video camera and it outputs HD video, but it&#8217;s in  .MTS file format. This is a pain because there are no good free video  converters or editors for .MTS files. But using <a href="http://fixounet.free.fr/avidemux/download.html" target="_blank">Avidemux</a>, an open-source video converter, I was able to  edit and convert my video to .mp4 while keeping my sanity and my money.</p>
<p><span id="more-568"></span>If you know your way around avidemux, pay attention to black colored text.</p>
<p>If you need extra help along the way, or I have something pointless to say, it will be in <span style="color: #999999;">gray<span style="color: #000000;">.</span></span></p>
<h3>1 &#8211; Open the File</h3>
<p><span style="color: #999999;">The first thing you have to do is import your video into Avidemux by one of two methods:</span></p>
<p><span style="color: #999999;">1) file &#8211;&gt; open &#8211;&gt; your-video.MTS</span></p>
<p><span style="color: #999999;">2) drag and drop the video file into avidemux</span></p>
<p><span style="color: #999999;">A dialog will appear saying, &#8220;This looks like MPEG, Do you want to index it?&#8221;&#8230; say &#8220;yes&#8221;</span></p>
<p><span style="color: #999999;">Avidemux will then tell you that it has detected H.264, say &#8220;yes&#8221;  to it&#8217;s other mode.</span></p>
<h3><span style="color: #999999;"><span style="color: #000000;">2 &#8211; Set Encoding Options</span><br />
</span></h3>
<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/MPEG-4-AVC2.jpg" rel="lightbox[568]"><img class="size-full wp-image-570 alignnone" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/MPEG-4-AVC2.jpg" alt="" width="124" height="237" /></a></p>
<p>For the Video encoder you should use MPEG-4 AVC</p>
<p>For Audio I recommend AAC (Faac) and a bitrate of 192, <span style="color: #999999;">(I&#8217;ll tell you right now AC3 does NOT work with youtube).</span></p>
<p><span style="color: #999999;"><span style="color: #000000;">Use mp4 for the encapsulation <span style="color: #999999;">(not avi like in the above pic).</span></span><br />
</span></p>
<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/HQmp4.jpg" rel="lightbox[568]"><img class="size-full wp-image-576 alignnone" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/HQmp4.jpg" alt="" width="180" height="210" /></a><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/HQmp4_1.jpg" rel="lightbox[568]"><img class="size-full wp-image-577  alignnone" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/HQmp4_1.jpg" alt="" width="180" height="210" /></a></p>
<p>Configure &#8211;&gt; General</p>
<p style="padding-left: 30px;">Use CRF (Constant Rate Factor) around 16 &#8211; 20. A CRF of 16  produces a larger file size; the higher the number, the less the  quality and file size.</p>
<p>Configure &#8211;&gt; Motion</p>
<p style="padding-left: 30px;">Use UHS (Uneven Hexagonal Search) and SR (Subpixel Refinement) of  9 for  best results.</p>
<h3>3 &#8211; Fix Frame Rate  Issues</h3>
<p>Here is where everyone has the problem of &#8220;Why is the video half speed!?&#8221;</p>
<p><span style="color: #999999;">Well, that&#8217;s because avidemux doesn&#8217;t like you, and that <span style="color: #000000;">A</span></span>videmux decided to treat the predictive and reference frames differently.</p>
<p>The way I fixed this was to double the video frame rate:</p>
<p>Main menu &#8211;&gt; Video &#8211;&gt; Frame Rate</p>
<p><span style="color: #999999;">According to my TI-89, 29.97 * 2 = </span>59.94<span style="color: #999999;"> (or I just did it in my head, but think the 89 is a powerful tool, especially if you&#8217;re an electrical engineer)</span></p>
<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/frame-rate1.jpg" rel="lightbox[568]"><img class="size-full wp-image-578 alignnone" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/frame-rate1.jpg" alt="" width="266" height="174" /></a></p>
<p><span style="color: #999999;">Well&#8230; now your video is the right speed&#8230; but why is the file so large?</span></p>
<p><span style="color: #999999;">Go to video filters, transform &#8211;&gt; </span>Resample fps <span style="color: #999999;">(</span>back to 29.97<span style="color: #999999;">).</span></p>
<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/filters.jpg" rel="lightbox[568]"><img class="size-full wp-image-574 alignnone" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/filters.jpg" alt="" width="400" height="249" /></a></p>
<p><span style="color: #999999;">Yeah, I know, I went extra wide screen with my video, so I feel like a ninja when I watch it, big deal.</span></p>
<p>I used other filters as well to reduce the resolution and trim the unneeded parts of the video to save space.</p>
<h3>4 &#8211; Save the Video</h3>
<p>File &#8211;&gt; Save &#8211;&gt; Save Video</p>
<p><span style="color: #999999;">Make sure you use the .mp4 extension.</span></p>
<p><span style="color: #999999;"><span style="color: #000000;">That&#8217;s all, enjoy your well-compressed .mp4 video!</span></span></p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/07/converting-mts-video-files-into-mp4-files/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The OSRAM SLG2016 and AVR</title>
		<link>http://protofusion.org/wordpress/2010/07/the-osram-slg2016-and-avr/</link>
		<comments>http://protofusion.org/wordpress/2010/07/the-osram-slg2016-and-avr/#comments</comments>
		<pubDate>Sat, 17 Jul 2010 21:33:39 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[AVR]]></category>
		<category><![CDATA[attiny88]]></category>
		<category><![CDATA[osram]]></category>
		<category><![CDATA[slg 2016]]></category>
		<category><![CDATA[slg2016]]></category>
		<category><![CDATA[tiny88]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=531</guid>
		<description><![CDATA[I happened to scavenge a couple of SLG2016&#8242;s from some old workstation debug displays. After finally locating a datasheet, I ]]></description>
			<content:encoded><![CDATA[<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/slg2016-macro.jpg" rel="lightbox[531]"><img class="alignnone size-large wp-image-545" title="SLG2016 LED Display" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/slg2016-macro-500x375.jpg" alt="" width="500" height="375" /></a></p>
<p>I happened to scavenge a couple of SLG2016&#8242;s from some old workstation debug displays. After finally locating a datasheet, I realized that they used the standard ASCII charset, so they are extremely easy to drive. <em>Note: The SLG2016 differs from the SLR2016, SLO2016, and SLY2016 only by LED color.</em></p>
<p><em><span id="more-531"></span></em></p>
<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/attiny88-macro.jpg" rel="lightbox[531]"><img class="alignnone size-large wp-image-542" title="ATTINY88 on solderless breadboard" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/attiny88-macro-500x375.jpg" alt="" width="500" height="375" /></a></p>
<p>The only downside to these displays is that they use quite a few pins (7 data lines, 2 digit select lines, write line, and optional blanking line). For now, I&#8217;m driving the display with all pins in parallel on a tiny88 which has plenty of pins; however I plan on using a shift register to cut down on data bus pin usage in the future. The displays only need the data lines to be held stable during a write cycle, making shift registers well-suited to this task.</p>
<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/07/buspirate-macro.jpg" rel="lightbox[531]"><img class="size-large wp-image-544 alignnone" title="The Bus Pirate with probe cable attached" src="http://protofusion.org/wordpress/wp-content/uploads/2010/07/buspirate-macro-500x375.jpg" alt="" width="500" height="375" /></a></p>
<p>To flash the attiny88, I&#8217;m using a <a href="http://dangerousprototypes.com/category/bus-pirate/" target="_blank">Bus Pirate</a> (pictured above) flashed with the STK500v2 emulation firmware. This allows me to use avr-gcc with AVR Studio to program the chip.</p>
<p>Here is some code I used to test the displays, using PORTD for data lines, and the 2 LSB&#8217;s of PORTC for digit select lines. This is the first time I&#8217;ve worked with AVRs outside of the Arduino environment, so pardon any flagrant errors and drop me a comment if you have any suggestions.</p>
<pre class="brush: cpp;">
#define F_CPU 1000000UL

#include &lt;avr/io.h&gt;
#include &lt;util/delay.h&gt;
#include &lt;string.h&gt;
#include &lt;stdlib.h&gt;

void wr();
void wrChar(char toWrite, int dig);
void wrWord(char *word);
void scrollWord(char *word);
void delay_ms(uint16_t ms);

int main (void){
  DDRC=0xFF;
  DDRD=0xFF;
  PORTD=0x00;
  PORTC=0x00;

  // Loop through a few strings for testing
  while(1){
    wrWord(&quot;Helo&quot;);
    delay_ms(500);
    wrWord(&quot;*?%$&quot;);
    delay_ms(500);
  }
}

// Toggle write pin (PC0)
void wr() {
  PORTD &amp;= ~(1&lt;&lt;7);
  delay_ms(1);
  PORTD |= (1&lt;&lt;7);
}

// Write char to position
void wrChar(char toWrite, int pos){
  PORTC = pos;  // Set digit select lines
  PORTD = toWrite;  // Set data lines
  wr();  // Toggle write pin
}

// Write 4-char word
void wrWord(char *word){
  for(int i=3; i&gt;=0; i--){
    wrChar(word[i], 3-i);
  }
}

// Generic delay function
void delay_ms(uint16_t ms) {
  while (ms) {
    _delay_ms(1);
    ms--;
  }
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/07/the-osram-slg2016-and-avr/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New &#8220;Projects&#8221; Pages</title>
		<link>http://protofusion.org/wordpress/2010/07/new-projects-pages/</link>
		<comments>http://protofusion.org/wordpress/2010/07/new-projects-pages/#comments</comments>
		<pubDate>Thu, 01 Jul 2010 16:43:07 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[Announcements]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=511</guid>
		<description><![CDATA[I created a new &#8220;Projects&#8221; type to list some projects currently on protofusion. Check out the link in the top ]]></description>
			<content:encoded><![CDATA[<p>I created a new &#8220;Projects&#8221; type to list some projects currently on protofusion. Check out the link in the top menubar, or click <a href="/wordpress/projects-list/">here</a>. Have a project that needs some of the resources that protofusion can provide? Send an email to admin@protofusion.org.</p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/07/new-projects-pages/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Victor Speed Controllers and EMC2</title>
		<link>http://protofusion.org/wordpress/2010/06/victor-speed-controllers-and-emc2/</link>
		<comments>http://protofusion.org/wordpress/2010/06/victor-speed-controllers-and-emc2/#comments</comments>
		<pubDate>Wed, 16 Jun 2010 21:26:10 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[CNC]]></category>
		<category><![CDATA[emc2]]></category>
		<category><![CDATA[victor]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=427</guid>
		<description><![CDATA[I&#8217;m currently working on building a EMC2-controlled CNC machine with mostly parts I have on hand. I decided to use ]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/06/emcifi.png" rel="lightbox[427]"><img class="size-full wp-image-461 aligncenter" title="LinuxCNC and IFI" src="http://protofusion.org/wordpress/wp-content/uploads/2010/06/emcifi.png" alt="" width="300" height="124" /></a></p>
<p>I&#8217;m currently working on building a EMC2-controlled CNC machine with mostly parts I have on hand. I decided to use Victor 883&#8242;s to control my servos, but EMC2 does not put out the RC-style PWM signal that victors are driven with. Thankfully, hardware in EMC2 is configured with HAL, allowing the software to work with nearly any hardware. Below are the values and configuration I used. If you are planning on using other RC-style motor controllers, you&#8217;ll need to calculate these values yourself.</p>
<p><span id="more-427"></span></p>
<p>If you are planning on using an RC-style motor controller for a CNC machine, note that you will likely not get the precision achieved by professional servo controllers or homemade h-bridges. However, I have achieved excellent accuracy with the Victor 883 motor controller, my semi-tuned PID loop consistently gets +/-.0032&#8243; accuracy.</p>
<p><strong>Duty cycle range for Victor 883 </strong>(as measured)</p>
<p style="padding-left: 30px;">Maximum duty cycle: 95.29%<br />
Minimum duty cycle: 56.08%</p>
<p><strong>Scale and Offset Values</strong> (scale/offset from [-1, 1] to [.5608, .9529] )</p>
<p style="padding-left: 30px;">Scale amount: .1952<br />
Offset amount: .7554</p>
<p><strong>X-axis Configuration Example</strong></p>
<p style="padding-left: 30px;"># PWM output for X-axis<br />
linksp Xpwm =&gt; parport.0.pin-02-out</p>
<p style="padding-left: 30px;">setp pwmgen.0.pwm-freq 490.0 # seems to work well</p>
<p style="padding-left: 30px;"># Minimum and maximum duty cycle for the Victor 883<br />
setp pwmgen.0.max-dc .9529<br />
setp pwmgen.0.min-dc .5608</p>
<p style="padding-left: 30px;"># Scale and offset pwm signal<br />
setp pwmgen.0.scale .1952<br />
setp pwmgen.0.offset .7554</p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/06/victor-speed-controllers-and-emc2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Google Voice and Asterisk</title>
		<link>http://protofusion.org/wordpress/2010/06/google-voice-and-asterisk/</link>
		<comments>http://protofusion.org/wordpress/2010/06/google-voice-and-asterisk/#comments</comments>
		<pubDate>Mon, 14 Jun 2010 03:32:01 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Asterisk]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=419</guid>
		<description><![CDATA[There are numerous guides about setting up Google Voice and an incoming sip number for free outgoing calling. Sadly, all ]]></description>
			<content:encoded><![CDATA[<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/06/gvheader.png" rel="lightbox[419]"><img class="alignnone size-large wp-image-436" title="Google Voice &amp; Asterisk" src="http://protofusion.org/wordpress/wp-content/uploads/2010/06/gvheader-500x205.png" alt="Google Voice &amp; Asterisk" width="500" height="205" /></a></p>
<p>There are numerous guides about setting up Google Voice and an incoming sip number for free outgoing calling. Sadly, all of the guides I found were written for FreePBX or some other Asterisk bundle, and also used a shell script to do much of the work (scary!). I have compiled the minimal amount that you need to put in your asterisk conf files to make things work, GUI-free and variant-independent.</p>
<p><span id="more-419"></span></p>
<h2>Prerequisites</h2>
<p><a href="http://sipgate.com/" target="_blank"><img class="size-large wp-image-444 alignright" title="sipgate logo" src="http://protofusion.org/wordpress/wp-content/uploads/2010/06/sipgate-logo-500x187.jpg" alt="sipgate logo" width="225" height="84" /></a></p>
<p>First off, you need a sip number. I recommend <a href="http://sipgate.com/" target="_blank">sipgate</a> or <a href="http://ipkall.com/">ipkall</a> (I use sipgate, it&#8217;s much more user-friendly). If you google around, you&#8217;ll find out how to set up your sipgate/ipkall number as an incoming number in asterisk, I won&#8217;t waste time covering it here.</p>
<p>Secondly, you need a google voice number. Once you get said number, turn off call presentation. Also, assign the account a password that you don&#8217;t mind having plaintext in a conf file. In addition, you <strong><em>must</em></strong> add your incoming sip number as a phone in google  voice. I&#8217;d recommend connecting a softphone to your sip number to set this up with google&#8217;s verification call, or redirect all incoming calls in Asterisk to your extension.</p>
<p>Thirdly, you need <a href="http://code.google.com/p/pygooglevoice/" target="_blank">pygooglevoice</a>. Download and install it, or use python&#8217;s easy_install command.</p>
<h2>The outgoing rule</h2>
<p>Now for the actual configuration. First you need to set up an outgoing call rule, so all calls to the outside world (in this case, 10-digit numbers preceded with a &#8220;9&#8243;) are directed though google voice.</p>
<blockquote>
<p style="padding-left: 30px;">[CallingRule_LocalCalls]<br />
exten = _9XXXXXXXXXX,1,Goto(custom-gv,${EXTEN:-10},1)</p>
</blockquote>
<p><em><strong>Explanation:</strong> Any outgoing 10-digit number prefixed with a 9 will match this rule and go to the custom-gv section which we will set up later. The number that was dialed is passed (the &#8220;-10&#8243; excludes the 9 prefix from this) at the first dialplan rule.</em></p>
<h2>The GV dialer<em><br />
</em></h2>
<p>Now we need to set up the custom-gv section:</p>
<blockquote>
<p style="padding-left: 30px;">[custom-gv]<br />
exten =&gt; _X.,1,Verbose(0, Custom-GV Preparing to call and park call at number ${EXTEN})<br />
exten =&gt; _X.,n,Wait(1)<br />
exten =&gt; _X.,n,Playback(pls-wait-connect-call)<br />
exten =&gt; _X.,n,System(gvoice -e <span style="text-decoration: line-through;">me@me.com</span> -p <span style="text-decoration: line-through;">GVPassword</span> call ${EXTEN} <span style="text-decoration: line-through;">IncomingNum</span> &amp;)<br />
exten =&gt; _X.,n,Set(PARKINGEXTEN=701)<br />
exten =&gt; _X.,n,Park()</p>
</blockquote>
<p><em><strong>Explanation:</strong> After you dial an outgoing number, you&#8217;ll be dropped in here. The Verbose() function tosses some output in debug level 0 and up (see the console for this output). The System() command dials the number with google voice. Make sure you change the items in <span style="text-decoration: line-through;">strikethrough</span> to your own personal information. The call is then parked on extension 701 (70X extensions for parking are default. Switch to your parking extension range if you are using non-default options).</em></p>
<h2>Routing GV callbacks<em><br />
</em></h2>
<p>Now you need to set up an incoming call rule. Direct all incoming calls from your sip number at this rule.</p>
<blockquote>
<p style="padding-left: 30px;">[incoming-call-sifter]<br />
exten = s,1,NoOp(CIDredirect)<br />
exten = s,2,Verbose(0, Got incoming CID ${CALLERID(num)}, redirecting&#8230;)<br />
exten = s,3,GotoIf($["${CALLERID(num)}" == "<span style="text-decoration: line-through;">GVNumber</span>"]?custom-park,s,1)<br />
exten = s,4,Goto(<span style="text-decoration: line-through;">section-to-route-normal-incoming-calls</span>,s,1)</p>
</blockquote>
<p><em><strong>Explanation:</strong> If your google voice number rings your PBX, you know that it&#8217;s connecting you to the call you just dialed, so we need to reconnect it to the extension you dialed from. We&#8217;ll handle linking of the incoming GV call and your outgoing call (which is now parked) in the next section (custom-park).</em></p>
<h2>Bringing it all together<em><br />
</em></h2>
<p>The custom-park section links a google voice incoming call (which is actually ringing the person you originally dialed) with your original outgoing call (which is parked).</p>
<blockquote>
<p style="padding-left: 30px;">[custom-park]<br />
exten =&gt; s,1,Verbose(0, Got incoming GV Callback! Connecting to your original outgoing call&#8230;)<br />
exten =&gt; s,2,ParkedCall(701)</p>
</blockquote>
<p><em><strong>Explanation:</strong> After you dialed your external number, your call was parked as google voice started dialing the other number. This section joins your outgoing call with google voice&#8217;s incoming call, so you are connected to the party you originally dialed.</em></p>
<h2>You&#8217;re done!</h2>
<div class="simplePullQuote">Have comments, questions, or need clarification? Leave a  comment!</div>
<p>Well that turned out to be a bit longer than I expected, but if you know what you&#8217;re doing, you can just ignore the italicized text.</p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/06/google-voice-and-asterisk/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>End of the road for free data on iDen?</title>
		<link>http://protofusion.org/wordpress/2010/06/end-of-the-road-for-free-data-on-iden/</link>
		<comments>http://protofusion.org/wordpress/2010/06/end-of-the-road-for-free-data-on-iden/#comments</comments>
		<pubDate>Fri, 11 Jun 2010 21:11:08 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[iDen]]></category>
		<category><![CDATA[internet]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=429</guid>
		<description><![CDATA[It looks like getting free data access on iDen handsets is going to end, likely on or before 6/20/10 according ]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.engadget.com/2010/06/11/engadget-podcast-200-06-11-2010/"><img class="alignnone" title="Sprint Data Throttling and Blocking" src="http://www.blogcdn.com/www.engadget.com/media/2010/06/sprint-data-throttle.jpg" alt="" width="423" height="317" /></a></p>
<p>It looks like getting free data access on iDen handsets is going to end, likely on or before 6/20/10 according to this Sprint document (credit Engadget). Coincidentally, this is the same day that the Motorola i1 is released, the first Android phone on the iDen network. With this phone, Sprint would needed to lock down iDen data access a bit harder than blocking the phone&#8217;s built-in browser (the status quo), so the change will affect all phones on the iDen network (Boost and Nextel).</p>
<p>This also means that getting <a href="http://protofusion.org/wordpress/2009/09/arduino-mobile-connectivity/">mobile connectivity for your Arduino</a> will no longer be free. Boost mobile&#8217;s data rates run at $.35/day.</p>
<p><strong><em>Update: </em>6/20 has passed, and I still have data access.</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/06/end-of-the-road-for-free-data-on-iden/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Initial CNC Prototyping</title>
		<link>http://protofusion.org/wordpress/2010/05/initial-cnc-prototyping/</link>
		<comments>http://protofusion.org/wordpress/2010/05/initial-cnc-prototyping/#comments</comments>
		<pubDate>Wed, 26 May 2010 03:38:19 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[CNC]]></category>
		<category><![CDATA[Projects]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=384</guid>
		<description><![CDATA[I&#8217;ve started constructing the basic electronics for the CNC machine I&#8217;m working on. It&#8217;s going to be a cheap machine ]]></description>
			<content:encoded><![CDATA[<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/05/IMG_1534.jpg" rel="lightbox[384]"><img class="alignnone size-large wp-image-385" title="Parallel Breakout" src="http://protofusion.org/wordpress/wp-content/uploads/2010/05/IMG_1534-500x335.jpg" alt="" width="500" height="335" /></a></p>
<p>I&#8217;ve started constructing the basic electronics for the CNC machine I&#8217;m working on. It&#8217;s going to be a cheap machine made with what I have on hand, so don&#8217;t expect anything too amazing <img src='http://protofusion.org/wordpress/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> . Here are some random build photos&#8230;</p>
<p><span id="more-384"></span></p>
<div id="attachment_386" class="wp-caption alignnone" style="width: 510px"><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/05/IMG_1531.jpg" rel="lightbox[384]"><img class="size-large wp-image-386" title="Cat5 Interconnect" src="http://protofusion.org/wordpress/wp-content/uploads/2010/05/IMG_1531-500x438.jpg" alt="" width="500" height="438" /></a><p class="wp-caption-text">CAT5 signalling cable for quadrature encoder, motor PWM, and limit switches for a single axis</p></div>
<p>All communication for motor controllers (PWM), encoders, and limit switches is being done over CAT5 cable, just because it&#8217;s pluggable, easy to use, and longer or shorter cables can be swapped in. Currently it looks like I can live with 1 CAT5 cable per axis.</p>
<div id="attachment_387" class="wp-caption alignnone" style="width: 510px"><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/05/IMG_1533.jpg" rel="lightbox[384]"><img class="size-large wp-image-387" title="Motor Controller" src="http://protofusion.org/wordpress/wp-content/uploads/2010/05/IMG_1533-500x389.jpg" alt="" width="500" height="389" /></a><p class="wp-caption-text">Victor 883 Speed Controller, by Innovation First</p></div>
<p>For motor controllers, I&#8217;m using Victor 883&#8242;s. The controllers are currently running at 12v, but will run at 24v once I get some appropriate power supplies. These controllers weren&#8217;t intended for precise positioning and motion control (they are RC-style, meant for competitive robotics), but they perform amazingly well after some HAL PWM adjustments to EMC2.</p>
<div id="attachment_388" class="wp-caption alignnone" style="width: 410px"><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/05/IMG_1536.jpg" rel="lightbox[384]"><img class="size-large wp-image-388" title="EMC2 Setup" src="http://protofusion.org/wordpress/wp-content/uploads/2010/05/IMG_1536-500x617.jpg" alt="" width="400" height="494" /></a><p class="wp-caption-text">EMC2, E-stop button, and my crazy parallel port breakout</p></div>
<p>Speaking of which, I am using <a href="http://linuxcnc.org/" target="_blank">EMC2</a> to control my CNC machine. Communication is all over the parallel port, saving me a ton of cash that would otherwise be spent on an FPGA card (although I&#8217;ll be needing another parallel port PCI card). EMC2 provides a ton of functionality and, unlike all other software of its type, it allows low-level HAL descriptors for motor controllers, encoders, and any other hardware. This allows you to move some complexity from your hardware into your software, or to modify the software to use old or unsupported hardware.</p>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="400" height="300" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=11977571&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" /><embed type="application/x-shockwave-flash" width="400" height="300" src="http://vimeo.com/moogaloop.swf?clip_id=11977571&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<p><a href="http://vimeo.com/11977571">EMC2 Motor Controller Test</a> from <a href="http://vimeo.com/normaldotcom">Ethan Zonca</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p>I&#8217;ll be posting more information on the project as the summer progresses, although I expect progress to be quite slow.</p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/05/initial-cnc-prototyping/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Randomly Decent Music</title>
		<link>http://protofusion.org/wordpress/2010/05/randomly-decent-music/</link>
		<comments>http://protofusion.org/wordpress/2010/05/randomly-decent-music/#comments</comments>
		<pubDate>Wed, 26 May 2010 03:14:00 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[Music]]></category>
		<category><![CDATA[random]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=400</guid>
		<description><![CDATA[Here&#8217;s a quick aggregation of some decent not-incredibly-well-known-for-the-most-part music. Links just point to google searches, which will hopefully provide some ]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s a quick aggregation of some decent not-incredibly-well-known-for-the-most-part music. Links just point to google searches, which will hopefully provide some relevant method to play the song.</p>
<p><a href="http://www.google.com/search?q=Animal+Collective+-+Daily+Routine" target="_blank">Animal Collective &#8211; <em>Daily Routine</em></a></p>
<p><a href="http://www.google.com/search?q=Freelance+Whales+-+Generator+First+Floor" target="_blank">Freelance Whales &#8211; <em>Generator First Floor</em></a></p>
<p><a href="http://www.google.com/search?q=TV+on+the+Radio+-+Staring+at+the+Sun" target="_blank">TV on the Radio &#8211; <em>Staring at the Sun</em></a></p>
<p><a href="http://www.google.com/search?q=30+Seconds+to+Mars+-+This+is+War" target="_blank">30 Seconds to Mars &#8211; <em>This is War</em></a></p>
<p><a href="http://www.google.com/search?q=Chiddy+Bang+-+The+Opposite+Of+Adults" target="_blank">Chiddy Bang &#8211; <em>The Opposite of Adults</em></a></p>
<p><a href="http://www.google.com/search?q=Mute+Math+-+Stall+Out" target="_blank">Mute Math &#8211; <em>Stall Out</em></a></p>
<p><a href="http://www.google.com/search?q=Black+Gold+-+Detroit" target="_blank">Black Gold &#8211; </a><em><a href="http://www.google.com/search?q=Black+Gold+-+Detroit" target="_blank">Detroit</a><br />
</em></p>
<p><a href="http://www.google.com/search?q=Aqualung+-+Brighter+Than+Sunshine" target="_blank">Aqualung &#8211; </a><em><a href="http://www.google.com/search?q=Aqualung+-+Brighter+Than+Sunshine" target="_blank">Brighter Than Sunshine</a><br />
</em></p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/05/randomly-decent-music/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>(Really) Cheap RFID door opener</title>
		<link>http://protofusion.org/wordpress/2010/05/really-cheap-rfid-door-opener/</link>
		<comments>http://protofusion.org/wordpress/2010/05/really-cheap-rfid-door-opener/#comments</comments>
		<pubDate>Thu, 20 May 2010 20:07:33 +0000</pubDate>
		<dc:creator>Ethan Zonca</dc:creator>
				<category><![CDATA[Arduino]]></category>
		<category><![CDATA[Projects]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[RFID]]></category>
		<category><![CDATA[Technology]]></category>

		<guid isPermaLink="false">http://protofusion.org/wordpress/?p=363</guid>
		<description><![CDATA[Well, the school year is over, so I thought I&#8217;d post up some information about my (extremely cheap and junky-looking ]]></description>
			<content:encoded><![CDATA[<p><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/05/100_0470.jpg" rel="lightbox[363]"><img class="alignnone size-large wp-image-378" title="Handle Motor" src="http://protofusion.org/wordpress/wp-content/uploads/2010/05/100_0470-499x622.jpg" alt="" width="314" height="392" /></a></p>
<p>Well, the school year is over, so I thought I&#8217;d post up some information about my (extremely cheap and junky-looking but functional) door opener.<span id="more-363"></span></p>
<p>The door handle is turned by one 24v globe motor (which have encoders that I&#8217;m sadly not using at the moment), and is pulled open by another identical motor. A very affordable ($30) <a href="http://www.sparkfun.com/commerce/product_info.php?products_id=8419" target="_blank">SparkFun RFID reader</a> is attached to the back the door so cards can be scanned from the outside. An <a href="http://arduino.cc/" target="_blank">arduino</a> controls the process, and drives motors and a cooling fan with 3 darlington transistors.</p>
<div id="attachment_369" class="wp-caption alignnone" style="width: 510px"><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/05/100_0469.jpg" rel="lightbox[363]"><img class="size-large wp-image-369" title="Controller and Motor" src="http://protofusion.org/wordpress/wp-content/uploads/2010/05/100_0469-500x380.jpg" alt="" width="500" height="380" /></a><p class="wp-caption-text">Power supply case housing arduino and circuitry, along with door-pulling motor and ridiculously ugly tie-dye duct tape</p></div>
<p>The arduino was attached to an old Dell laptop, which ran the Apache webserver. A small password-protected php web interface was created to allow door opening from anywhere on campus. KDE4 widgets allowed door opening from computers inside the room, letting my roommate and I avoid walking less than 8 feet (or less) away to open the door for someone.</p>
<div id="attachment_374" class="wp-caption alignnone" style="width: 510px"><a href="http://protofusion.org/wordpress/wp-content/uploads/2010/05/100_0456.jpg" rel="lightbox[363]"><img class="size-large wp-image-374" title="Digital &quot;Whiteboard&quot;" src="http://protofusion.org/wordpress/wp-content/uploads/2010/05/100_0456-500x473.jpg" alt="" width="500" height="473" /></a><p class="wp-caption-text">Touchscreen mounted to wall, password widget not shown. And no, I did not actually go to school in Munich, Germany <img src='http://protofusion.org/wordpress/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p></div>
<p>I also put a password-protected KDE4 widget on our touchscreen mounted on the wall outside of our room, so if one of us forgot our RFID card, we could type in a password on the touchscreen, and the door would open. Fun stuff.</p>
<p>Unfortunately I don&#8217;t have too many pictures, and the entire thing is disassembled now. Hopefully next year I&#8217;ll improve it (encoders and PID for motion control?) and post some more information.</p>
]]></content:encoded>
			<wfw:commentRss>http://protofusion.org/wordpress/2010/05/really-cheap-rfid-door-opener/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
