<?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>Protected * Void &#187; KDE</title>
	<atom:link href="http://labs.danilocesar.com/blog/category/kde/feed/" rel="self" type="application/rss+xml" />
	<link>http://labs.danilocesar.com/blog</link>
	<description>Free your code, Free your mind!</description>
	<lastBuildDate>Thu, 03 Nov 2011 17:45:49 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Beat Maker: The drum loop maker written with Qt</title>
		<link>http://labs.danilocesar.com/blog/2010/10/14/beat-maker-a-drum-loop-application-written-with-qt/</link>
		<comments>http://labs.danilocesar.com/blog/2010/10/14/beat-maker-a-drum-loop-application-written-with-qt/#comments</comments>
		<pubDate>Thu, 14 Oct 2010 23:37:11 +0000</pubDate>
		<dc:creator>Danilo Cesar</dc:creator>
				<category><![CDATA[KDE]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Maemo]]></category>
		<category><![CDATA[Qt]]></category>
		<category><![CDATA[chord]]></category>
		<category><![CDATA[music]]></category>
		<category><![CDATA[musicians]]></category>
		<category><![CDATA[n900]]></category>
		<category><![CDATA[nokia]]></category>
		<category><![CDATA[openbossa]]></category>

		<guid isPermaLink="false">http://labs.danilocesar.com/blog/?p=86</guid>
		<description><![CDATA[Beat Maker is my &#8220;pet project&#8221; with Allyson Soares at INdT. It is, basically, a drum loop emulator to be used by musicians during practicing sessions. You just need to select the samples, define a BPM value and listen to the rhythm ;) If you can&#8217;t wait for the official release at Ovi Store, you [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.youtube.com/watch?v=Ke0zBk73_Zc"><img title="BeatMaker" src="http://labs.danilocesar.com/blog/wp-content/uploads/2010/10/bm.png" width="400" height="213" /></a></p>
<p><strong>Beat Maker</strong> is my &#8220;pet project&#8221; with Allyson Soares at INdT.</p>
<p>It is, basically, a drum loop emulator to be used by musicians during practicing sessions.</p>
<p>You just need to select the samples, define a BPM value and listen to the rhythm ;)</p>
<p>If you can&#8217;t wait for the official release at Ovi Store, you can try the <a href="http://labs.danilocesar.com/qt/maemo/beat-maker_0.1-1_armel.deb">beta version</a> for n900 devices.</p>
<p>Remember: it&#8217;s a <strong>beta</strong> version of an open source software. The code can be found linked to my <a href="http://gitorious.org/beat-maker">gitorious</a> account.</p>
<p><strong>The technical point of view:</strong></p>
<p>I&#8217;m a little bit disappointed with phonon. After a <a href="http://lists-archives.org/kde-devel/24844-multiple-sounds-with-phonon.html">long discussion</a> I&#8217;ve realized that phonon could not be used on Beat Maker.</p>
<p>At this time I&#8217;m using an approach suggested by <a href="http://atdrez.wordpress.com/">Adriano Rezende</a>: play the sound using pulseaudio&#8217;s API. I know, it&#8217;s not portable. But hey, my target is N900 devices and it worked pretty well at the time.<br />
However, it doesn&#8217;t scale. So, now, I&#8217;m working on a kind of &#8220;in-app-mixer&#8221;, which should solve this problem.</p>
<p>There is another problem, related to QTimer. Qt can&#8217;t guarantee the timing between the beats using QTimer events. Especially when you generate mouse events.  Anyway, the mixer controller loop should solve this as well.</p>
<p>Big thanks to Adriano for the tips, and Allyson who made the excellent UI design.</p>
<p>I hope you enjoy it.<br />
Suggestions are welcome =)</p>
<p>ps.: youtube video bellow<br />
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="640" height="390" 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://www.youtube.com/v/Ke0zBk73_Zc&amp;hl=en_US&amp;feature=player_embedded&amp;version=3" /><param name="allowfullscreen" value="true" /><embed type="application/x-shockwave-flash" width="640" height="390" src="http://www.youtube.com/v/Ke0zBk73_Zc&amp;hl=en_US&amp;feature=player_embedded&amp;version=3" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
]]></content:encoded>
			<wfw:commentRss>http://labs.danilocesar.com/blog/2010/10/14/beat-maker-a-drum-loop-application-written-with-qt/feed/</wfw:commentRss>
		<slash:comments>25</slash:comments>
		</item>
		<item>
		<title>Symbian development using Linux on real life&#8230;</title>
		<link>http://labs.danilocesar.com/blog/2010/05/05/symbian-development-using-linux-on-real-life/</link>
		<comments>http://labs.danilocesar.com/blog/2010/05/05/symbian-development-using-linux-on-real-life/#comments</comments>
		<pubDate>Wed, 05 May 2010 13:30:13 +0000</pubDate>
		<dc:creator>Danilo Cesar</dc:creator>
				<category><![CDATA[KDE]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Maemo]]></category>
		<category><![CDATA[Qt]]></category>
		<category><![CDATA[Symbian]]></category>
		<category><![CDATA[gnupoc]]></category>
		<category><![CDATA[nokia]]></category>
		<category><![CDATA[QtS60]]></category>

		<guid isPermaLink="false">http://labs.danilocesar.com/blog/?p=28</guid>
		<description><![CDATA[I believe most companies that develop Symbian products uses windows, and only windows, on their development process. Well&#8230; We don&#8217;t =) When we started to develop symbian applications at INdT we, as open source developers, decided to find a way to keep using linux as our development environment. On the beginning we didn’t have yet an official [...]]]></description>
			<content:encoded><![CDATA[<p>I believe most companies that develop Symbian products uses windows, and only windows, on their development process. Well&#8230; We don&#8217;t =)</p>
<p>When we started to develop symbian applications at <a href="http://www.indt.org.br/">INdT</a> we, as open source developers, decided to find a way to keep using linux as our development environment.<br />
On the beginning we didn’t have yet <a href="http://labs.trolltech.com/blogs/2010/04/21/symbian-development-using-linux/" target="_blank">an official way to compile our applications on linux</a>, so we used (and still use)<a href="http://lizardo.wordpress.com/2010/02/18/installing-qt-for-symbian-sdk-4-6-2-on-linux/" target="_blank"> Lizardo&#8217;s patchs</a> that enables gnupoc to compile Qt-symbian applications on Linux.</p>
<h3>First tip:</h3>
<p>Personally I think finding errors on gnupoc output is an exhaustive job. So, the first tip for those who&#8217;re using Lizardo&#8217;s approach is to use a small piece of code in your <strong>.bashrc</strong></p>
<pre>function makes60
{
  make debug-gcce 2&gt;&amp;1 | while read line
  do
    echo -e $(echo $line |
      sed 's@\\@\\\\@g' |
      sed "s/.*error.*/\\\e[0;31m(&amp;)\\\e[0;31m/I" |
      sed "s/warning/\\\E[33m(&amp;)\\\E[0;37m/gI" |
      sed "s/No such file/\\\E[33m(&amp;)\\\E[0;37m/gI"
      )
  tput sgr0;
done;
}
</pre>
<p><em>By calling <strong>makes60</strong>, every error/warning message will be highlighted in read/yellow.</em><br />
It's a simple tweak, but it is very useful.</p>
<p>So, we can compile our application, easily read the compiler messages... Now what?</p>
<h3>Analyzing the process:</h3>
<p>Let me list our development phases:</p>
<ul>
<li> <span style="color: #339966;">Coding: OK </span>with vim</li>
<li> <span style="color: #339966;">Compiling: OK</span> with gcce and some tweaks</li>
<li> <span style="color: #c1c100;">Debugging:</span> (As we work almost only with default Qt API, we build for linux first and debug there). So, it's almost OK.</li>
<li> <span style="color: #339966;">Packaging .sis</span>: OK with make sis</li>
<li> <span style="color: #ff0000;">Send to device, install and test</span>: It's a slow process yet.</li>
</ul>
<p>Testing on the device is a very difficult/slow task on linux. We don't have a debugger.  We don't even have any output message (Ok, we have: with <a href="http://developer.symbian.org/wiki/index.php/Platform_Opening/Did_You_Know%3F/P.I.P.S.#The_stdio_Subsystem_.28libc.29" target="_blank">stdioserver</a> writing on an txt file. Too hard!).</p>
<p>How does it works for Windows developers? <a href="http://www.forum.nokia.com/Tools_Docs_and_Code/Tools/IDEs/Carbide.c++/" target="_blank">Carbide++</a> and TRK!</p>
<p>Of course we don't want to install Carbide++ on linux. So, can we use TRK with linux? Yes, we can! First of all you need to get the TRK application in <a href="http://www.forum.nokia.com/Tools_Docs_and_Code/Tools/IDEs/Carbide.c++/" target="_blank">Carbide++</a> package or in newly released <a href="http://conversations.nokia.com/2010/04/27/nokia-rolls-out-qt-sdk-for-unified-mobile-developer-experience/" target="_blank">Nokia SDK</a>.</p>
<h3>Installing TRK:</h3>
<ol>
<li>Send and execute TRK.sis on the device.</li>
<li>Open TRK application / Options / Settings,  and select <strong>Connection = USB </strong>instead of bluetooth.</li>
<li>Go to TRK mainscreen / Options / Connect.</li>
</ol>
<p>If your USB cable is plugged you will receive a "<strong>Status: Connected</strong>" message on your phone.</p>
<p>Now you need to create a serial connection between the device and your linux machine. If you're using a 2.6.33 kernel you don't need to do that. Otherwise you need to create it manually.</p>
<p>Before you do that you need some information about the device. It can be retrieved with:</p>
<pre>[danilo@docbrown ~]$ lsusb  | grep Nokia
Bus 001 Device 011: ID <strong>0421:0154</strong> Nokia Mobile Phones</pre>
<p>So, <strong>my</strong> vendor ID is <strong>0421</strong>, and my product ID is <strong>0154</strong>.  <span style="color: #ff0000;">Remember to use your own numbers</span> =)<br />
And then you can load the usbserial mobule with the command:</p>
<pre>sudo modprobe usbserial vendor=0x0<strong>421</strong> product=0x<strong>0154</strong></pre>
<p>If everything went OK you should see a message like this:</p>
<pre>[danilo@docbrown ~]$ dmesg | grep ttyUSB
[34063.949446] usb 1-4.3.1.4: generic converter now attached to ttyUSB0</pre>
<p>Your serial port was created on /dev/ttyYSB0.</p>
<p>Ok, perfect! But how to communicate with TRK?</p>
<p>Trolls are working on that, but for now we&#8217;re using the <a href="http://qt.gitorious.org/qt/qt/trees/4.7/tools/runonphone">runonphone</a> tool. It&#8217;s the same tool used by QtCreator on Windows and you can get it by cloning <a href="http://qt.gitorious.org/qt" target="_blank">Qt Repository</a> and compiling the /tools/runonphone folder.</p>
<h3>On device testing</h3>
<p>After compiled, runonphone can be used by passing the serial port, the sis package and the executable file to it.<br />
<em>runonphone -p /dev/ttyUSB0 -s test_package.sis test_package.exe</em></p>
<p>As you probably noticed all your qWarning() messages are being redirected to runonphone output. Which is very nice!</p>
<p><strong>On device debugging</strong></p>
<p>We don&#8217;t have an interative gdb tool as we have on windows, but Qt guys are close and I&#8217;m sure we will have good news in a few days.</p>
<h3>Concluding</h3>
<p>I&#8217;m sure that Symbian development on Linux is near, and it will be massively adopted when those tools became part of QtCreator for linux. For those who can&#8217;t wait, or think that VIM is the best IDE ever, I hope those tips can help you. =)</p>
<p>And for those who&#8217;re working with Qt for symbian, remember to join the <strong>#qt-symbian</strong> on <strong>Freenode</strong>.</p>
]]></content:encoded>
			<wfw:commentRss>http://labs.danilocesar.com/blog/2010/05/05/symbian-development-using-linux-on-real-life/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Have you ever seen KDE Mobil?</title>
		<link>http://labs.danilocesar.com/blog/2009/08/27/have-you-ever-seen-kde-mobil/</link>
		<comments>http://labs.danilocesar.com/blog/2009/08/27/have-you-ever-seen-kde-mobil/#comments</comments>
		<pubDate>Thu, 27 Aug 2009 17:27:07 +0000</pubDate>
		<dc:creator>Danilo Cesar</dc:creator>
				<category><![CDATA[KDE]]></category>
		<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://labs.danilocesar.com/blog/?p=24</guid>
		<description><![CDATA[I have! =)]]></description>
			<content:encoded><![CDATA[<p><a href="http://labs.danilocesar.com/blog/wp-content/uploads/2009/08/kde_mobil.jpg"><img class="alignnone size-medium wp-image-23" title="KDE Mobil" src="http://labs.danilocesar.com/blog/wp-content/uploads/2009/08/kde_mobil-300x225.jpg" alt="KDE Mobil" width="300" height="225" /></a></p>
<p>I have! =)</p>
]]></content:encoded>
			<wfw:commentRss>http://labs.danilocesar.com/blog/2009/08/27/have-you-ever-seen-kde-mobil/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

