<?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>Marius Gundersen &#187; Marius</title>
	<atom:link href="http://www.mariusgundersen.net/author/admin/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.mariusgundersen.net</link>
	<description>MariusGundersen.net</description>
	<lastBuildDate>Thu, 12 Jan 2012 16:56:30 +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>OnGameStart 2011</title>
		<link>http://www.mariusgundersen.net/2011/10/27/ongamestart-2011/</link>
		<comments>http://www.mariusgundersen.net/2011/10/27/ongamestart-2011/#comments</comments>
		<pubDate>Thu, 27 Oct 2011 07:34:28 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=192</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2011/10/27/ongamestart-2011/" title="OnGameStart 2011"></a>On the 22nd and 23rd of September Warsaw was host to the first ever HTML5 games conference; OnGameStart. While game development in HTML5 is a relatively new area, the conference managed to bring together almost 300 people from all over &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2011/10/27/ongamestart-2011/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2011/10/27/ongamestart-2011/" title="OnGameStart 2011"></a><p>On the 22nd and 23rd of September Warsaw was host to the first ever HTML5 games conference; <a href="http://ongamestart.com" target="_blank">OnGameStart</a>. While game development in HTML5 is a relatively new area, the conference managed to bring together almost 300 people from all over the world to discuss the future of gaming and game development in the browser. Among those 300 people were 19 great speakers, a large group of organizers and the <a title="Opera had to leave early" href="https://plus.google.com/u/0/118397406534237711570/posts/E15yhETNWW8" target="_blank">4 major browser vendors</a>.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2011/10/ongamestart.png"><img class="aligncenter size-full wp-image-197" title="ongamestart" src="http://www.mariusgundersen.net/wp-content/uploads/2011/10/ongamestart.png" alt="" width="410" height="296" /></a>The talks ranged from how to publish and monetize games online to technical discussions on Oct-Trees and how to implement them. The variety of talks made it apparent that we who are interested in making games in HTML5 is a large and diverse group. There were several large companies present who had invested considerable time and money into making games in HTML5, investments which are only just becoming profitable. Some of these companies make game engines (for example <a href="http://impactjs.com/" target="_blank">ImpactJS</a> and <a href="http://enchantjs.com/en/" target="_blank">enchant.js</a>) while others focused on the publishing possibilities of HTML5 games (<a href="http://www.spilgames.com/" target="_blank">Spil Games</a>).</p>
<p>Microsoft, Opera, Mozilla and Google all had representatives present to evangelize their browser and boast about gaming on their platform. Even the W3C showed up to discuss features which could be included in HTML5 to make games in browsers even better (<a href="http://dvcs.w3.org/hg/webevents/raw-file/default/mouse-lock.html" target="_blank">Mouse Lock</a> is one such feature soon to make its way into the browser). With such major players all interested in game development in HTML5, the future of browser games looks very bright.</p>
<p>Several unsolved issues with HTML5 gaming were discussed, and especially Rob Hawkes (of <a href="http://rawkets.com/" target="_blank">Rawkets.com</a>) brought up some interesting points about cheaters and multiplayer games. Since the source code of HTML5 games are sent to all the players, and this code can be edited while the game is running, it becomes very easy to cheat in almost all HTML5 games. This is a major problem with realtime multiplayer games, where a JavaScript hacker can quickly ruin the game for all the other players. Rob discussed measures to prevent this by running the game engine on the server side, which introduced new problems due to the network implementation of WebSockets. Because WebSockets use TCP, packets are guaranteed to arrive in the correct order, at the cost of transmission delay. In a realtime game the delay should be as low as possible, and the value of a packet arriving quickly depreciates. Very few people have looked into this problem for WebSockets, and because it uses TCP instead of UDP, it is still uncertain how much can be borrowed from other multiplayer engines (<a href="http://www.reddit.com/r/programming/comments/eyp6h/latency_compensating_methods_in_clientserver_games" target="_blank">reddit discussion</a>).</p>
<p>Several demos of games in HTML5 were presented, including the <a href="http://www.isogenicengine.com/" target="_blank">Isogenic engine</a> by Rob Evans, and <a href="http://blog.tojicode.com/2011/10/source-engine-levels-in-webgl-video.html" target="_blank">Team Fortress 2</a> in WebGL by Brandon Jones. These demos show not only what is possible today, but what is possible in the near future. Based on these demos it is impossible to predict what will be available to gamers in 2 years time, when the technology has matured even further. There was also a large focus on mobile gaming, and several games were shown running on tablets and mobile phones, either in the browser or through technology like <a href="http://www.phonegap.com/" target="_blank">PhoneGap</a>. The latter is especially interesting, as it enables game developers to release the same native game for several platforms without any further work.</p>
<p><a href="http://vimeo.com/channels/ogs#31129124"><img class="aligncenter" title="OnGameStart presentation" src="http://b.vimeocdn.com/ts/209/547/209547968_200.jpg" alt="" width="200" height="150" /></a>My talk at OnGameStart2011 was titled "How to build a 3D engine in HTML5" and with it I wanted to show how the Canvas element can be combined with JavaScript to create a simple 3D engine in HTML5. A video of the talk is available at <a href="http://vimeo.com/channels/ogs#31129124" target="_blank">Vimeo</a>, the slides can be found <a href="http://projects.mariusgundersen.net/OnGameStart" target="_blank">online</a>, and the source code to each of the demos are available <del>in my <a href="http://svn.mariusgundersen.net" target="_blank">repository</a></del> (my SVN server crashed, so I have uploaded the presentation to <a href="https://github.com/mariusGundersen/OnGameStart-2011" target="_blank">GitHub</a>). The talk was to be less than an hour long, so I decided to focus on the absolute basics of making a 3D engine, completely from scratch. Instead of using WebGL, I wanted to show how a 3D engine could be made using only 2D API calls. While such an engine would not be as powerful as Brandons Source/Quake/Rage engines, it would demonstrate how 3D engines work, and how to optimize drawing in the 2D context.</p>
<p>In the short time since OnGameStart, several conferences have been held where HTML5 game dev has been discussed, including <a href="http://jsconf.eu/2011/" target="_blank">JSConf.eu</a>, a <a href="http://openmediaweb.eu/2011/09/14/workshop-on-html-next-for-gaming/" target="_blank">W3C event</a> and in the beginning of November San Francisco will host the <a href="http://www.newgameconf.com/" target="_blank">New Game Conf</a>. With all of this focus on browser game development, the future of HTML5 games looks really bright, and with the rapid development of modern browsers, things which were impossible two years ago is now easy in all of the browsers. By extrapolating from this it is obvious that nobody can predict what browser games will look like in a few years.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2011/10/27/ongamestart-2011/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>The Pimponator (finally) works!</title>
		<link>http://www.mariusgundersen.net/2011/04/13/the-pimponator-finally-works/</link>
		<comments>http://www.mariusgundersen.net/2011/04/13/the-pimponator-finally-works/#comments</comments>
		<pubDate>Wed, 13 Apr 2011 16:16:09 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[Project]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=173</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2011/04/13/the-pimponator-finally-works/" title="The Pimponator (finally) works!"></a>At the beginning of last semester i started designing a pimpin' Imponator, a Pimponator. This imponator, like all imponators, would use flashing LEDs to impress other students, but I would be able to reprogram it from my cellphone using Bluetooth. &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2011/04/13/the-pimponator-finally-works/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2011/04/13/the-pimponator-finally-works/" title="The Pimponator (finally) works!"></a><p>At the beginning of last semester i started designing a pimpin' <a title="Omega Verksteds webpage about the Imponator" href="http://omegav.no/byggekurs" target="_blank">Imponator</a>, a Pimponator. This imponator, like all imponators, would use flashing LEDs to impress other students, but I would be able to reprogram it from my cellphone using Bluetooth. The front of the Pimponator would have a 16 by 5 LED matrix, where the brightness of the LEDs could be controlled individually. The design was quickly finished, and I soon had a soldered device to play with. The only problem was that it didn't work. And so it ended up at the bottom of my electronics drawer, along with all the other projects I never finish, and it remained there for almost six months.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2011/03/pimponator_back.jpg"><img class="aligncenter size-medium wp-image-177" title="Backside of the Pimponator" src="http://www.mariusgundersen.net/wp-content/uploads/2011/03/pimponator_back-300x168.jpg" alt="" width="300" height="168" /></a>A few weeks ago I decided to make it work, no matter how much time it would take. The device had worked in a few tests, just not consistently, so I knew I would eventually get it to work. After a few days of scoping, debugging and soldering I finally got rid of the bugs, and had the Pimponator communicating with my Android phone. It took another few days to put the firmware and Android app together so it would work as intended.</p>
<p>The Pimponator Android application makes it easy to put together an animation for the device. Several scrolling text phrases can be combined to make an animation, which is compiled into hexcode on the phone before it is transferred using Bluetooth to the device. The device stores the animation in flash memory, so even if the battery is replaced, the animation is still there.</p>
<p style="text-align: center;"><iframe title="YouTube video player" src="http://www.youtube.com/embed/eLDVVwEIbq4" frameborder="0" width="560" height="349"></iframe></p>
<p>The Pimponator uses an AVR Atmega 128 micro controller, running at 7.372800Mhz, to control the 16 column by 5 row LED matrix. The micro controller has 64KiB of flash available for the animation, which means it can store almost 6000 frames. To transfer animations to the Pimponator an <a title="RN-41, by Roving Networks" href="http://www.rovingnetworks.com/rn-41.php" target="_blank">RN41 Bluetooth module</a>, which shows up as a virtual COM port, is used. The Android phone is running an app which opens a serial connection the the AVR when it is time to transfer the animation.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2011/03/pimponator_under.jpg"><img class="aligncenter size-medium wp-image-178" title="Underside of Pimponator" src="http://www.mariusgundersen.net/wp-content/uploads/2011/03/pimponator_under-300x168.jpg" alt="The Pimponator is 2 two-layer PCBs on top of each other" width="300" height="168" /></a></p>
<p>The Android app can store several animations, each made up of one or more sequences of frames. Currently the app only supports scrolling text, but because it is plugin based, it is very easy to write another app which produces a different sequence.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2011/04/13/the-pimponator-finally-works/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>NES TV Remote</title>
		<link>http://www.mariusgundersen.net/2010/10/26/nes-tv-remote/</link>
		<comments>http://www.mariusgundersen.net/2010/10/26/nes-tv-remote/#comments</comments>
		<pubDate>Tue, 26 Oct 2010 15:48:55 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[NESRemote]]></category>
		<category><![CDATA[Project]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=154</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2010/10/26/nes-tv-remote/" title="NES TV Remote"></a>A few weeks ago the remote to our TV went mysteriously missing, and since then we've had to change channels by getting out of our sofa. Obviously this is not the way TV should be enjoyed in the 21 century, &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2010/10/26/nes-tv-remote/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2010/10/26/nes-tv-remote/" title="NES TV Remote"></a><p>A few weeks ago the remote to our TV went mysteriously missing, and since then we've had to change channels by getting out of our sofa. Obviously this is not the way TV should be enjoyed in the 21 century, so we needed a new remote. Instead of buying one I figured I could make one. At first I attempted to make one for my Android phone, by <a title="LIRC audio" href="http://www.lirc.org/html/audio.html" target="_blank">connecting IR LEDs to the audio jack</a>, but so far that has failed to work. So over the weekend I decided to convert an old <a title="ebay search: NES controller" href="http://shop.ebay.com/i.html?_nkw=nes+controller" target="_blank">NES controller</a> into a remote control.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/10/C360_2010-10-26-09-58-05.jpg"><img class="aligncenter size-medium wp-image-156" title="NES Remote" src="http://www.mariusgundersen.net/wp-content/uploads/2010/10/C360_2010-10-26-09-58-05-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Step one was to make a PCB that would fit inside the controller and have all the buttons (8), plastic pins (3) and screws (6) align properly. On this PCB I also needed to fit an <a title="ATmega168 on AVRFreaks" href="http://www.avrfreaks.net/index.php?module=Freaks%20Devices&amp;func=displayDev&amp;objectid=78">ATmega168</a> and a <a title="Wikipedia: Button Cell" href="http://en.wikipedia.org/wiki/Button_cell" target="_blank">button cell</a>, along with some resistors and capacitors. After printing, exposing, developing and etching the board, it was soldered together and ready for programming.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/10/C360_2010-10-26-16-30-36.jpg"><img class="aligncenter size-medium wp-image-158" title="NES Remote PCB" src="http://www.mariusgundersen.net/wp-content/uploads/2010/10/C360_2010-10-26-16-30-36-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Step two was programming the AVR. Since the remote would run of a single button cell battery, it needed to use as little power as possible. ATmegas have the ability to sleep, which will turn off everything, including the system clock, and will only wake up when one of the buttons is pressed. In Power Down mode, the remote used 1.5uA, which means it will (theoretically) still work a decade from now on a single battery. When a button is pressed, however, the LED drains quite a lot of power, so it wont last anywhere near that long with active use.</p>
<p>Once a button has been pressed, the remote needs to send an IR signal to the TV. Most IR remotes transmit a 38kHz square wave which is turned on or off to encode bits. We (used to) have a <a title="RM-836.jpg" href="http://lirc.sourceforge.net/remotes/sony/RM-836.jpg" target="_blank">Sony TV remote</a>, which meant I had to replicate the <a title="Davshomepage: Sony IR Code" href="http://users.telenet.be/davshomepage/sony.htm" target="_blank">Sony IR protocol</a>. This is a really simple signal to create, since all the pulses are multiples of 600uS. The next step was to find the code each button had to send to the TV, something the <a title="RM-836 config file" href="http://lirc.sourceforge.net/remotes/sony/RM-836" target="_blank">LIRC project has available</a>. With each of the buttons programmed to transmit a different code (up and down changes channel, left and right changes the volume, select is mute, start is power, A changes to channel 1 and B changes to a random channel), the remote was complete. I tested the remote with my <a title="How to use a cell phone to test an old remote" href="http://www.ehow.com/how_5466798_use-tv-remote-isnt-dead.html" target="_blank">cell phone</a> and compared the signal (using an oscilloscope) with the intended signal, before heading home and confirming that it works on the TV.</p>
<p>The files for the NES Remote can be found in the Subversion repository: <a title="Repository" href="http://svn.mariusgundersen.net/NESRemote/" target="_blank">svn.mariusgundersen.net/NESRemote</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2010/10/26/nes-tv-remote/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>BraidMaker</title>
		<link>http://www.mariusgundersen.net/2010/08/06/braidmaker/</link>
		<comments>http://www.mariusgundersen.net/2010/08/06/braidmaker/#comments</comments>
		<pubDate>Fri, 06 Aug 2010 00:31:02 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[3D printing]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=139</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2010/08/06/braidmaker/" title="BraidMaker"></a>In my spare time this summer I've been working on a mechanical braiding machine. I'm not sure where the idea came from, but one night I jotted down the design for a mechanism to braid three threads together. The design &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2010/08/06/braidmaker/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2010/08/06/braidmaker/" title="BraidMaker"></a><p>In my spare time this summer I've been working on a mechanical braiding machine. I'm not sure where the idea came from, but one night I jotted down the design for a mechanism to braid three threads together. The design quickly went from the notepad by my bed to <a href="http://www.blender.org/" target="_blank">Blender</a>, where it took about 2 weeks of programming (the gears were generated by a python script) and modeling to have a finished braiding machine. Then it took <a href="http://www.shapeways.com" target="_blank">Shapeways </a>exactly one week to print up the device and deliver it to my door <img src='http://www.mariusgundersen.net/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/08/P8050046.jpg"><img class="aligncenter size-medium wp-image-141" title="BraidMaker (sideview)" src="http://www.mariusgundersen.net/wp-content/uploads/2010/08/P8050046-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>When I received it, a few parts were merged together, probably because of low clearance. Both the gears were merged with their respective axles, but a careful twist got them loose. The only other assembly required was to push the top axle with the gears into position (it was left out of position so the gears wouldn't merge together).</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/08/P8050043.jpg"><img class="aligncenter size-medium wp-image-142" title="BraidMaker (topview)" src="http://www.mariusgundersen.net/wp-content/uploads/2010/08/P8050043-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>The BraidMaker worked as intended right away, except for locking up once in a while. This is solved by gently tapping the device so the pieces fall into the right spot (I have to do this a few times in the video). It runs smoother the more you use it though, probably a combination of me learning how to operate it properly and the track getting smoothed by the moving parts.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/08/P8050047.jpg"><img class="aligncenter size-medium wp-image-143" title="BraidMaker (threads)" src="http://www.mariusgundersen.net/wp-content/uploads/2010/08/P8050047-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>Some of the parts of the device are very thin, like the gear teeth (which are no more than a millimeter thick) but it is still very tough and handles being used very well. The material is truly white, strong and flexible. When running it leaves a thin blanket of white dust on the ground, probably from the moving parts grinding against each other, but that is (hopefully) only while it is new.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/08/P8050061.jpg"><img class="aligncenter size-medium wp-image-144" style="width: 300px; height: 225px;" title="BraidMaker (braided)" src="http://www.mariusgundersen.net/wp-content/uploads/2010/08/P8050061-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>All in all I'm very satisfied with the BraidMaker. I was expecting several parts to be merged together, the gear teeth to be too thin and therefore snap when I'd try to use it, and the device failing to braid at all. Nothing has broken off yet, and it is quite capable of braiding (thin) threads!</p>
<p><center><object width="480" height="385"><param name="movie" value="http://www.youtube.com/v/a1-L7Kb82iQ&amp;hl=en_US&amp;fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/a1-L7Kb82iQ&amp;hl=en_US&amp;fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="480" height="385"></embed></object></center></p>
<p>The BraidMaker is available at my <a href="http://www.shapeways.com/shops/gundersen" target="_blank">Shapeways shop</a> for $17 in WSF.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2010/08/06/braidmaker/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Wake Me Up Spotify 0.2</title>
		<link>http://www.mariusgundersen.net/2010/01/25/wake-me-up-spotify-0-2/</link>
		<comments>http://www.mariusgundersen.net/2010/01/25/wake-me-up-spotify-0-2/#comments</comments>
		<pubDate>Mon, 25 Jan 2010 13:22:23 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[Wake Me Up Spotify]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=121</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2010/01/25/wake-me-up-spotify-0-2/" title="Wake Me Up Spotify 0.2"></a>I've fixed the biggest bug from the previous version of Wake Me Up Spotify; it is now possible to use a playlist to wake you up! The fix was simple, and like the rest of the app, a hack. It &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2010/01/25/wake-me-up-spotify-0-2/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2010/01/25/wake-me-up-spotify-0-2/" title="Wake Me Up Spotify 0.2"></a><p>I've fixed the biggest bug from the previous version of Wake Me Up Spotify; it is now possible to use a playlist to wake you up! The fix was simple, and like the rest of the app, a hack. It just closes spotify 2 minutes before you want to wake up. Then it reopens it again (T minus 1 minute), and starts playing at the specified wake up time.</p>
<p>The latest version can be downloaded here: <a href="http://www.mariusgundersen.net/downloadsWakeMeUpSpotify_0_2_0_1.zip" title="zip, 65.79 kB">WakeMeUpSpotify</a> (0.2)</p>
<h3>Using Wake Me Up Spotify</h3>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/01/locate.png"><img class="aligncenter size-medium wp-image-122" title="Using Wake Me Up Spotify" src="http://www.mariusgundersen.net/wp-content/uploads/2010/01/locate-230x300.png" alt="" width="230" height="300" /></a></p>
<p>When you start Wake Me Up Spotify for the first time, a yellow banner<strong><span style="color: #ff0000;"> (1)</span></strong> at the top of the app will indicate that you need to locate Spotify on your computer. Click on the banner, and find the folder where Spotify is installed (usually C:\Program Files\Spotify). You only have to do this once.</p>
<p>Now you need to specify the time you want to wake up at. Enter the time (in hours:minutes) in the small text box <strong><span style="color: #ff0000;">(2)</span></strong>. Next you need to find a song or playlist that you want to wake up to. Open Spotify and find a song or playlist, right click it, and click "Copy Spotify URI". Then paste it in the large textbox in Wake Me Up Spotify <strong><span style="color: #ff0000;">(3)</span></strong>. Now you are ready to go to sleep!</p>
<p>You can hide Wake Me Up Spotify by clicking the minimize arrow on the toolbar. This will minimize the app to the taskbar (the bottom right corner of Windows). The app will still run from here. If you close it, it will not wake you up.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2010/01/25/wake-me-up-spotify-0-2/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>CentripetalBox</title>
		<link>http://www.mariusgundersen.net/2010/01/15/centripetalbox/</link>
		<comments>http://www.mariusgundersen.net/2010/01/15/centripetalbox/#comments</comments>
		<pubDate>Thu, 14 Jan 2010 23:09:08 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[3D printing]]></category>
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=110</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2010/01/15/centripetalbox/" title="CentripetalBox"></a>I just received my first ever 3D printed object from Shapeways, a CentripetalBox. Shapeways provide a cheap and simple way to 3D print anything you can imagine in a variety of materials, including ABS (like Lego), stainless steel and even &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2010/01/15/centripetalbox/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2010/01/15/centripetalbox/" title="CentripetalBox"></a><p>I just received my first ever 3D printed object from <a title="Shapeways | passionate about creating" href="http://www.shapeways.com" target="_blank">Shapeways</a>, a CentripetalBox. Shapeways provide a cheap and simple way to 3D print anything you can imagine in a variety of materials, including ABS (like Lego), stainless steel and even color printed 3D objects. This is the first time I have 3D printed anything, so I was quite excited, but at the same time expecting a designflaw showing up in the finished product.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/01/locked.jpeg"><img class="aligncenter size-medium wp-image-112" title="locked" src="http://www.mariusgundersen.net/wp-content/uploads/2010/01/locked-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p>The design I got printed was a <a href="http://www.shapeways.com/model/69177/centripetalbox.html" target="_blank">CentripetalBox</a>, a cube which needs to be spun around quickly to be opened. You can see a video of how it works below. The original design had 4 plugs which would fit inside the 4 slots in the box and lid, but due to the inaccuracy of the printing process, the plugs where slightly too big. The lid was also a bit too big, and needed to be sanded down slightly to fit inside the box. This was expected, but what was not expected was how tough the material was. I printed in <a href="http://www.shapeways.com/materials/white_strong_flexible" target="_blank">White, Strong and Flexible</a>, and while the surface is quite rough and seems fragile (small particles of the raw material powder will come loose if you scratch it), the actual box is pretty solid. I tried sanding down the plugs so they would fit inside the slots, but quickly moved to a file instead. A Dremel might have been a good tool to have handy. Instead of using the printed plastic plugs I used a thin steel rod cut into plugs. It might even be that the plastic plugs are too light to work. A few more days of sanding/filing, and I'll know.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/01/P1140213.jpg"><img class="aligncenter size-medium wp-image-111" title="P1140213" src="http://www.mariusgundersen.net/wp-content/uploads/2010/01/P1140213-300x225.jpg" alt="CentripetalBox components" width="300" height="225" /></a><a href="http://www.mariusgundersen.net/wp-content/uploads/2010/01/P1140218.jpg"><img class="aligncenter size-medium wp-image-117" title="P1140218" src="http://www.mariusgundersen.net/wp-content/uploads/2010/01/P1140218-300x225.jpg" alt="The rought texture of the WSF material" width="300" height="225" /></a></p>
<p>Having discussed the end result and design with my dad, we came up with some improvements. I'll make a new version for the <a href="http://www.shapeways.com/shops/gundersen" target="_blank">Shapeways shop</a> with those improvements (and bug fixes, like smaller plugs, and a tiny gap between the lid and the box). This is the first thing I have ever made in Blender and then 3D printed, and the fact that it works (with a bit of post-production work) is more than I expected. I have a few other ideas for 3D printing, and I'll work on them this spring (or autumn, if you are in Australia).</p>
<p><img src="http://www.mariusgundersen.net/wp-content/plugins/flash-video-player/default_video_player.gif" /></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2010/01/15/centripetalbox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Very simple CMS: project category</title>
		<link>http://www.mariusgundersen.net/2009/11/24/very-simple-cms-project-category/</link>
		<comments>http://www.mariusgundersen.net/2009/11/24/very-simple-cms-project-category/#comments</comments>
		<pubDate>Tue, 24 Nov 2009 14:38:27 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[CMS]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[template]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=89</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2009/11/24/very-simple-cms-project-category/" title="Very simple CMS: project category"></a>I made this blog to have a place to post the applications and programs I have made, and for that I needed a Content Management System (CMS). I looked at some CMS plugins for WordPress, but most of them are &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2009/11/24/very-simple-cms-project-category/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2009/11/24/very-simple-cms-project-category/" title="Very simple CMS: project category"></a><p>I made this blog to have a place to post the applications and programs I have made, and for that I needed a Content Management System (CMS). I looked at some CMS plugins for WordPress, but most of them are overkill for what I need. Instead I decided to use the built inn Categories of WordPress. I created a category called Project, and for each project (a program, website or anything else I made) I would add a sub-category with that projects name. With this simple method I could create several posts describing the progress of a project. Now all I needed was a page with all the projects listed, and maybe the latest posts for each one.</p>
<p>I solved this by making a page Template (not to be confused with Theme, which is something completely different). The template lists all the subcategories of a category, specified in the page metadata, along with the category description and the last 5 posts for each category. This way you can list all the projects on one page and link to the most recent information for each one. Because the category name is specified in the page metadata, you can have multiple CMS pages, for example, ideas, projects or experiments.<br />
<span id="more-89"></span><br />
Add the template file to /wp-content/themes/&lt;active theme&gt;. To use this template, make a new page, then select the template called 'CMS' from the list of templates. The content will be shown at the top of the page. Next you need to add a metadata (also called custom field) to the page, with name 'category' and value equal to the category you want the page to show. You might need to edit the template slightly for it to display properly with your theme.</p>
<pre class="brush: php; html-script: true; title: ; notranslate">
&lt;?php

/*

Template Name: CMS

*/

?&gt;

&lt;?php get_header(); ?&gt;

&lt;?php if (have_posts()) : the_post(); update_post_caches($posts); ?&gt;

  &lt;div class=&quot;post&quot; id=&quot;post-&lt;?php the_ID(); ?&gt;&quot;&gt;

    &lt;h1&gt;&lt;?php the_title(); ?&gt;&lt;/h1&gt;

    &lt;div class=&quot;content&quot;&gt;

      &lt;?php the_content(); ?&gt;

      &lt;?php if(count(get_post_custom_values('category')) &gt; 0 ): ?&gt;

        &lt;?php $category_slug = get_post_custom_values('category'); $category_slug = $category_slug[0];?&gt;

        &lt;?php if(($category = get_category_by_slug($category_slug)) != null): ?&gt;

          &lt;?php $categories = get_categories(array('child_of' =&gt; $category-&gt;term_id, 'orderby' =&gt; 'name', 'order' =&gt; 'asc')); ?&gt;

          &lt;?php foreach($categories as $category): ?&gt;

            &lt;div class=&quot;post&quot;&gt;

              &lt;h2&gt;&lt;a class=&quot;title&quot; href=&quot;/category/&lt;?php echo $category_slug.&quot;/&quot;.$category-&gt;category_nicename; ?&gt;&quot;&gt;&lt;?php echo $category-&gt;name; ?&gt;&lt;/a&gt;&lt;/h2&gt;

              &lt;div class=&quot;content&quot;&gt;

                &lt;p&gt;&lt;?php echo $category-&gt;description; ?&gt;&lt;/p&gt;

                &lt;!--Latest post --&gt;

                &lt;?php $posts = get_posts(&quot;cat=$category-&gt;term_id&amp;numberposts=5&amp;order=DESC&amp;orderby=date&quot;); ?&gt;

                &lt;h5&gt;Latest posts&lt;/h5&gt;

                &lt;?php foreach($posts as $post): ?&gt;

                  &lt;?php setup_postdata($post); ?&gt;

                  &lt;div class=&quot;content&quot;&gt;

                    &lt;a class=&quot;title&quot; href=&quot;&lt;?php the_permalink(); ?&gt;&quot;&gt;&lt;?php the_title(); ?&gt;&lt;/a&gt;

                    &lt;span style=&quot;float:right&quot; class=&quot;date&quot;&gt;&lt;?php the_time(__('F jS, Y', 'inove')); ?&gt;&lt;/span&gt;

                  &lt;/div&gt;

                &lt;?php endforeach; ?&gt;

              &lt;/div&gt;

            &lt;/div&gt;

          &lt;?php endforeach; ?&gt;

        &lt;?php else: ?&gt;

          &lt;div class=&quot;errorbox&quot;&gt;

            &lt;?php echo(&quot;Category '$category_slug' was not found!&quot;); ?&gt;

          &lt;/div&gt;

        &lt;?php endif; ?&gt;

      &lt;?php else: ?&gt;

        &lt;div class=&quot;errorbox&quot;&gt;

          &lt;?php echo(&quot;Add a custom field with name 'category' and value equal to the name of a category&quot;); ?&gt;

        &lt;/div&gt;

      &lt;?php endif; ?&gt;

    &lt;/div&gt;

  &lt;/div&gt;

&lt;?php else : ?&gt;

  &lt;div class=&quot;errorbox&quot;&gt;

    &lt;?php echo('Sorry, no posts matched your criteria.'); ?&gt;

  &lt;/div&gt;

&lt;?php endif; ?&gt;

&lt;?php get_footer(); ?&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2009/11/24/very-simple-cms-project-category/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Wake Me Up Spotify</title>
		<link>http://www.mariusgundersen.net/2009/11/19/wake-me-up-spotify/</link>
		<comments>http://www.mariusgundersen.net/2009/11/19/wake-me-up-spotify/#comments</comments>
		<pubDate>Thu, 19 Nov 2009 12:51:39 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[Wake Me Up Spotify]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Spotify]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=79</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2009/11/19/wake-me-up-spotify/" title="Wake Me Up Spotify"></a>This simple app lets you wake up to your favorite song or playlist by using Spotify as an alarm clock. Just set the time you want to wake up and the Spotify URI you want it to play, and your &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2009/11/19/wake-me-up-spotify/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2009/11/19/wake-me-up-spotify/" title="Wake Me Up Spotify"></a><div id="attachment_78" class="wp-caption aligncenter" style="width: 240px"><a href="http://www.mariusgundersen.net/wp-content/uploads/2009/11/screenshot.png"><img class="size-medium wp-image-78" title="WakeMeUpSpotify" src="http://www.mariusgundersen.net/wp-content/uploads/2009/11/screenshot-230x300.png" alt="Wake Me Up Spotify Screenshot" width="230" height="300" /></a><p class="wp-caption-text">Wake Me Up Spotify</p></div>
<p>This simple app lets you wake up to your favorite song or playlist by using <a title="Spotify" href="http://www.spotify.com" target="_blank">Spotify </a>as an alarm clock. Just set the time you want to wake up and the Spotify URI you want it to play, and your done. It will automatically open Spotify and start playing, and you can minimize it to the tray so it stays out of the way.</p>
<p>This is the first program I've ever made in C# and WinForms, so it's pretty simple. Most of the development time was spent making WinForms look nice, something it's definitively not designed for. For example, to add the nice shadow around the app, I had to sacrifice the blinking caret in the textboxes. Styling textboxes is also pretty difficult, so the simplest thing is to position so they line up with a background picture of the form. The rest of the time was  spent making it work with Spotify, using the <a title="Spotify Remote API, from CodePlex" href="http://spotifyremote.codeplex.com/" target="_blank">Spotify Remote API</a>. Spotify gives you very little control; I'm only able to play, pause, stop, play next and previous song and change the volume. To play a song specified by a Spotify URI I have to <a title="Use Spotify as alarm-clock!" href="http://www.delay.no/use-spotify-as-alarm-clock/" target="_blank">start Spotify with that URI as argument</a>.</p>
<p>The program still has a few bugs, so don't use it as the only way to wake up. For example, while it is possible to play a song at any time by starting Spotify with a song URI, it is not possible to make it play playlist when it is already open. If you want to wake up to a playlist, make sure you close the Spotify before you go to bed!<a href="http://www.mariusgundersen.net/wp-content/uploads/2009/11/WakeMeUpSpotify.zip"></a></p>
<p>Download <a href="http://www.mariusgundersen.net/wp-content/uploads/2009/11/WakeMeUpSpotify.zip">WakeMeUpSpotify</a> (65kB)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2009/11/19/wake-me-up-spotify/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Regex Renamer</title>
		<link>http://www.mariusgundersen.net/2009/08/17/regex-renamer/</link>
		<comments>http://www.mariusgundersen.net/2009/08/17/regex-renamer/#comments</comments>
		<pubDate>Mon, 17 Aug 2009 03:06:06 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[Regex Renamer]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[XUL]]></category>
		<category><![CDATA[xulrunner]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=47</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2009/08/17/regex-renamer/" title="Regex Renamer"></a>This week I set out to make a simple batch application for renaming files. Specifically I wanted to rename folders containing episodes of a TV-show. These files tend to have very ugly names, containing the name of the show, the &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2009/08/17/regex-renamer/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2009/08/17/regex-renamer/" title="Regex Renamer"></a><p style="text-align: center;"><a href="http://www.mariusgundersen.net/wp-content/uploads/2009/08/regexrenamer.png"><img class="aligncenter size-medium wp-image-51" title="RegexRenamer" src="http://www.mariusgundersen.net/wp-content/uploads/2009/08/regexrenamer-300x223.png" alt="RegexRenamer" width="300" height="223" /></a></p>
<p>This week I set out to make a simple batch application for renaming files. Specifically I wanted to rename folders containing episodes of a TV-show. These files tend to have very ugly names, containing the name of the show, the season and episode, the guy who uploaded it and the file type. I want my collection to contain prettier names, and so I decided to make a batch renamer that could make the folder look more appealing.</p>
<p>I decided to make the application using XUL Runner. XUL Runner is made by Mozilla, and is essentially what Firefox and Thunderbird runs in. It lets you create an GUI using XUL, JavaScript and CSS and then run it as an application. Having made a few extensions to Firefox in my time, XUL was a familiar concept and it didn't take long until I had a simple working version.</p>
<p>Regex Renamer lets you pick a pattern from a drop down list. It will then look for files that match the regular expression, and renames only those files. This means that if you have a folder where all the files have similar names, then you can rename all of them with a single click. The application also lets you create custom patterns, import and export the list of patterns from/to a file.</p>
<p>It's not the most user friendly application in the world, and it could do with some work on editing the pattern list, and maybe have a cheatsheet on regex built inn. But for a simple application that took less than a week to code up, it works pretty well.</p>
<p>You can download the application for windows below. It should run on any system that XUL Runner runs on, which would include Windows, Linux and OS X, but you need to download XUL Runner for the last two platforms.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2009/08/RegexRenamer.rar">RegexRenamer</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2009/08/17/regex-renamer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>EcmaCalc 0.4</title>
		<link>http://www.mariusgundersen.net/2009/03/25/ecmacalc-04/</link>
		<comments>http://www.mariusgundersen.net/2009/03/25/ecmacalc-04/#comments</comments>
		<pubDate>Wed, 25 Mar 2009 13:00:25 +0000</pubDate>
		<dc:creator>Marius</dc:creator>
				<category><![CDATA[EcmaCalc]]></category>
		<category><![CDATA[Project]]></category>
		<category><![CDATA[calculator]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[program]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://www.mariusgundersen.net/?p=28</guid>
		<description><![CDATA[<a href="http://www.mariusgundersen.net/2009/03/25/ecmacalc-04/" title="EcmaCalc 0.4"></a>I have made some updates to EcmaCalc, and it's reached version 0.4. The new features includes: Abortion of long-running scripts Syntax highlighting (still a bit buggy) Help There are a few bugs left to sort out, but this version is &#8230;<p class="read-more"><a href="http://www.mariusgundersen.net/2009/03/25/ecmacalc-04/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://www.mariusgundersen.net/2009/03/25/ecmacalc-04/" title="EcmaCalc 0.4"></a><p>I have made some updates to EcmaCalc, and it's reached version 0.4. The new features includes:</p>
<ul>
<li>Abortion of long-running scripts</li>
<li>Syntax highlighting (still a bit buggy)</li>
<li>Help</li>
</ul>
<p>There are a few bugs left to sort out, but this version is a lot better than 0.1, so I decided to release it. If you notice any bugs or have any new ideas, post them in the comments.</p>
<p><a href="http://www.mariusgundersen.net/wp-content/uploads/2009/03/ecmacalc-04.rar">EcmaCalc 0.4</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mariusgundersen.net/2009/03/25/ecmacalc-04/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

