Philosophy of higher education

Posted in Personal on February 4th, 2010 by Nayruden – Be the first to comment

For one of my classes today we came up with our “purpose statement” for our being at college. It’s quite enlightening to sit down and actually think about the reasons why you’re actually spending all this time and money when the only direct, physical result is a piece of paper. Here’s my philosophy:

Higher education primarily ensures that graduates have the tools and knowledge they need for the career field they want to go into. The time spent learning while earning the degree is invested into research in the field and honing professional and interpersonal skills. Studying at an academic institution is often necessary to make certain that topics are fully understood, that any questions are answers, and that the new knowledge can be easily referenced if needed in the future.

Attending a higher learning facility and living in school’s dormitory has extra added benefits. Living with other people that you don’t initially know helps immensely in helping students learn to empathize with those around them as well as help the students realize what kind of person they are versus what kind of person they’d like to be. This social experience is every bit just as important as the traditional academic learning that the school provides and needs to be treated as such when students are considering college options.

GUI for NetTunnel

Posted in Development on February 2nd, 2010 by Nayruden – 3 Comments

Designing the GUI for NetTunnel put my creativity to the test. I’ve never actually designed a GUI before, but I’ve seen and read a lot about GUI design theory, but theory seems to be fairly pointless for this design process. It was interesting for me to try to translate the idea in my head to the controls given in Visual Studios.

My first attempt ended up like this:

Main Window

Main Window

Services Window

Services Window

This is okay, but not great. Most of those elements are static elements that don’t move even if you resize it. It’s certainly not something I’d feel comfortable working with every day. After getting lots and lots of advice from friends, my second and final GUI design ended up like so:

Main Window

Main Window

Services Window

Services Window

A much cleaner and easier to understand layout. Services can be toggled just by clicking on the ’service’ menu and then clicking on the appropriate service from the drop-down, or they can be toggled within the service window proper. All the most commonly used items in the gui are put in obvious places, while making sure that everything’s just a few clicks away. Everything resizes and can have the size proportions for it changed.

Now that I know how easy it is to create GUIs, I think I might start using them in future projects while retaining a command line version for power users.

Introducing NetTunnel

Posted in Development on January 30th, 2010 by Nayruden – Be the first to comment

As part of my requirements for obtaining my degree, I’m doing a network capstone project this semester.  I’ve always been somewhat fascinated with NATs and specifically, how to break them, so I decided to work on a NAT traversal application. Enter NetTunnel: The purpose of NetTunnel is to provide a means for users with a lack of knowledge of networking or on a restrictive network an easy and simple means to share network services with other users.

Basically, say I’m on a restrictive network (like the dorm network) that does not allow me to host servers with the world due to NAT restrictions. I want to run ventrilo on my machine and have my friends join so I can chat with them. Unaided, this would be impossible, but if my friends and I are running NetTunnel a “hole” will be opened up in the network so they can connect.

It’s a pretty simple concept that’s already done in most modern desktop applications like Skype and peer to peer games. As far as I could tell this idea’s never been extended to a general level like NetTunnel, so there is a definite need for it. The closest application to it I could find is GameRanger, though GameRanger is aimed specifically at games.

I’ve set up a quick static page for NetTunnel at nettunnel.nayruden.com. Keep an eye out for further development, and I’d love to hear feedback about it!

CODN

Posted in Development on January 29th, 2010 by Nayruden – Be the first to comment

While talking to LightSys, an organization that offers free IT services to mission organizations, I was told about the Christian Open Development Network or CODN (pronounced codin’). The site is in dire need of a refresh and a core community (last update is 2005?!). I felt like God was nudging me while they described what they wanted CODN to be, especially since what they need is exactly what I have experience with from managing the Ulysses community.

So, if you or any friends are interested in Christian open source development, be sure to watch the site over the following months as we work on it. If you’ve got any ideas on what you’d like to see there, be sure to drop a note in the comments.

Callback system in D

Posted in Development on November 24th, 2008 by Nayruden – 2 Comments

We’ve been evaluating D for use in Daydream, and I decided to see how easy it would be to create a callback system in the D  language (aka events or signals). This is a daunting task in C++ because C++ templates can only accept a static number of arguments… very bad when you have a function that can accept any number of arguments. To solve this problem in C++ you need to create a separate template for each number of possible arguments.

In D you can create templates that accept any number of arguments! You can treat these as a tuple, an array, or use them with tail recursion (à la PROLOG).

Combine this with the natural awesomeness of D and you’re setup for a power punch. Following this text is a very simple callback system in D.
A short but sweet 50 lines of code; it stores both functions and delegates and gives you a good launching point to create a more complicated call back system.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import tango.io.Stdout;

// Converts a function to a delegate. Stolen from http://dsource.org/projects/tango/ticket/1174
// Note that it doesn't handle ref or out though
R delegate(T) toDg(R, T...)(R function(T) fp) {
    struct dg {
        R opCall(T t) {
            return (cast(R function(T)) this) (t);
        }
    }
    R delegate(T) t;
    t.ptr = fp;
    t.funcptr = &dg.opCall;
    return t;
}

class SimpleCallback(R, P...)
{
    alias R delegate(P) callbacktype;
    alias R function(P) function_callbacktype;

    private callbacktype[] callback_list;

    typeof( this ) opCatAssign( in callbacktype callback )
    {
        callback_list ~= callback;
        return this;
    }

    typeof( this ) opCatAssign( in function_callbacktype callback )
    {
        auto dg = toDg!(R, P)( callback );
        return this ~= dg;
    }

    R emit( P p )
    {
        static if ( !is( R == void ) )
        R last;

        foreach( callback; callback_list )
        {
            static if ( !is( R == void ) )
            last = callback( p );
            else
                callback( p );
        }

        static if ( !is( R == void ) )
        return last;
    }

    alias emit opCall;
}

Here’s some example code:

SimpleCallback!( void ) sc = new SimpleCallback!( void );
SimpleCallback!( bool, char[] ) sc2 = new SimpleCallback!( bool, char[] );
sc ~= function void() { Stdout.formatln( "#1" ); };
sc ~= function void() { Stdout.formatln( "#2" ); };
sc2 ~= function bool( char[] str ) { Stdout.formatln( "#1 called with {}, returning false", str ); return false; };
sc2 ~= function bool( char[] str ) { Stdout.formatln( "#2 called with {}, returning true", str ); return true; };
sc();
Stdout.formatln( "Last sc2 callback returned {}", sc2( "coffee" ) );

And here’s the output:

#1
#2
#1 called with coffee, returning false
#2 called with coffee, returning true
Last sc2 callback returned true

Pleased with Daydream

Posted in Development on October 26th, 2008 by Nayruden – 3 Comments

The response I got with Daydream far exceeded my expectations! We now have four excellent developers onboard, myself included. We’ve been putting the rubber to the road and have been coming up with basic design documents for Daydream. This is tedious work for now, but well worth the time it will save us in the coming months.

Are you a modeler or texture artist looking to bolster your profile? Join Daydream and help us and your resume. We’re looking for all skill levels at this point.

Thank you all for your support, and watch this blog for various news about Daydream in the future. :)

Here’s some links for Daydream:

Website: http://daydreamonline.net (just redirects to forums right now)

Twitter updates: https://twitter.com/ProjectDaydream

Wiki: http://wiki.daydreamonline.net

Git repo: http://github.com/Nayruden/daydream

For those who may be interested, we’ve decided to use the LGPL license.

Project Daydream

Posted in Development on October 14th, 2008 by Nayruden – 6 Comments

Daydream has been a dream of mine (haha, get it?) for quite some time. It’s something that I believe is needed, but when I start looking at the time/effort needed to work on it, I usually run for the hills. I’ve compromised with myself in this regard, I do not expect to complete it. No matter how much I work on it or not, it will be worth the experience. I’ll take it nice and slow, baby steps the whole way. This is part of the reason I named it ‘Daydream’. If Garry Newman, whose math (see quaternion section) and programming skills never cease to amuse, can code something similar, I certainly can too.

So, what is it?

Daydream takes a page from Garry’s Mod’s book, an open sandbox. It makes a good starting point for our explanation and most of the readers have experience in GMod, so we’ll list some of the major points of difference between Daydream and GMod below instead of starting from scratch.

  • Stability. This is the crux of what’s holding GMod back from wide public acceptence. Server owners simply have to expect a popular to crash roughly once an hour. If you don’t believe me, I’d happily get you in touch with some other server owners. GMod is built off HL2, which was simply not built to do what GMod is doing. It’s true that VALVe has put a lot of effort into supporting this, but it’s simply not enough. Daydream will have a high emphasis on making it as stable as humanly possible.
  • Cross-platform. Steam, which powers HL2 clients, does not support anything except windows. This does not hold true for servers, but Garry has repeatedly refused to support Linux. Our goal for Daydream is to have it run on Mac, Linux, and Windows. I have lots of experience programming on all the platforms except Mac, but now that I own a Mac, supporting it shouldn’t be a problem. ;)
  • FOSS (Free and Open Source Software). The community has been vital to GMod’s success, and the same would certainly be true of Daydream. What better way to do this than to have true community collaboration? I personally believe that the community is what would make or break Daydream. Making this open source also brings in the traditional benefits… more help with coding, greater bug visibility, easier to make modifications, etc.
  • Support for more players. Garry built GMod with exclusively single player in mind, telling people asking for multiplayer that they were essentially crazy. I have no idea if Garry still sticks by this design decision, but the impacts can be clearly seen. Garry is also relegated to the fact that Source cannot support more than 32/64 players on a server. One of Daydream’s long-term goals is to be essentially an MMO (similar to Second Life). This isn’t a feature that can happen overnight, and considerations for hardware must be made. Phsyics sandboxes are very intensive in memory and CPU.
  • More focus on learning. An online MMO physics sandbox is a great place to learn about the real world! What happens when a soccer ball is hit with a tornado? What’s the best way to light a wooden house on fire? Users should feel like they have nearly limitless possiblities while using Daydream.
  • Persistance. Disconnecting from a server shouldn’t be a death sentence. You should be able to bring your creations with you wherever you go, share them with others as you like (maybe even sell!). If someone’s created an awesome model (the building blocks of a sandbox game), they should be able to show the model to other people without intervention of the server owners (with reservations). Ideally (until Daydream is a true MMO), there would be some sort of cooperation between server hosts in order to store information about players.

Other features we want to implement:

  • In place script editor. You should be able to look at the scripts powering, for example, an ATV and change the behavior of the object on the fly. I want to be able to create a sphere, bring up the editor and see all relevant functions either stubbed out for me or easily dropped in the script, and make the sphere act like the the golden snitch from Harry Potter within a period of five minutes.
  • Clearly defined and standardized object I/O. If an object can move, other objects should be able to control this outside the script editor. IE, I should be able to create a button, give it a value of 0 when off and 255 when on, and hook it up to say, a cube, specifying acceleration along the z-axis or such. Then, when I press the button, the cube will shoot straight up into the air accelerating at 255 units/sec. This clean I/O interface allows even non-programmers to take full advantage of their surroundings in new and innovative ways.
  • Everything must be standardized, modular, and extensible. We realize that we’re a small team and relatively inexperienced. To counter this, everything should be as modular and extensible as possible so we can come along later and easily improve previous work. This also goes toward our MMO goal. We should litterally be able to replace the server software completely with as few changes to the clients as possible. Even if clients written in completely different languages were to join the server, this shouldn’t be a problem. I know this goal sounds lofty, but it is attainable.

An invitation for other developers:

If you are experienced in C++ or Lua, we’d like to have your help! Our development approach is very casual. So far the development team is made up of college students who are in this mostly to learn. We’re in no rush, we want to go slowly and make sure we get this right.

If this sounds like your type of project, please get in touch with me! Either leave a comment here, or email me, using megiddo AT (the address of this domain).

Technologies you should be willing to learn and become familiar with as a developer:

  • Ogre3d – This is our graphics engine
  • Git – Our source control (via github)
  • Lua – Our scripting language
  • SWIG – Our interface to Lua
  • Newton – Probably? We’re still toying around, PhysX seems to limited

An invitation for ideas:

Have an idea for this project? Leave it in the comments! We appreciate any feedback we can get at all.

Website for daydream:

Not much to look at yet, but it’s http://daydreamonlinet.net

Howto: Install Boot Camp 2.1 drivers on a new MacBook Pro using a Leopard install DVD

Posted in Tips on September 7th, 2008 by Nayruden – 13 Comments

So you’re in Korea and you stupidly forgot your MacBook Pro install DVD that you need in order to install Boot Camp drivers, huh? Have no fear, as long as you can borrow a Leopard install DVD off someone, it’s possible to get everything working. The problem here is that even with the Leopard install DVD (at least in my case), the DVD has the Boot Camp 2.0 drivers which will give you a blue screen of death if you try to install it on the latest MacBook Pro revision.

Step 1: Copy the Boot Camp driver install files from the Leopard CD to your Boot Camp desktop.

Step 2: Find the Broadcom/wireless driver installer and delete it.

Step 3: Install the 2.0 firmware through Drivers\Apple\BootCamp.msi. It will automagically pass through the wireless driver installation with no BSoD. You’ll need to reboot after this install

Step 4: Now run the 2.1 update, found here: http://www.apple.com/support/downloads/bootcampupdate21forwindowsxp.html. Reboot.

Step 5: Enjoy!

Korea, Iowa, and Delta

Posted in Personal on August 31st, 2008 by Nayruden – 2 Comments

Long time no post! Since my last post, it seemed I was lucky if I had enough time to breathe, let alone write a blog entry. But now I’m in Korea and should start having some more time on my hands.

I closed up shop with Rockwell Collins in Iowa, it was a summer well spent. I even got to shake hands with the CEO on the last day! That was pretty neat.

My flight to Korea had a connection in San Fransisco. Unfortunately, my Delta flight to SFO was an hour and a half late to the gate because they couldn’t get an open gate to dock with. It was a terrible feeling, sitting in the plane knowing that if I could get out of the plane and simply walk to the international terminal, I could make it on time. Instead, I missed the flight out and got delayed an entire day at SFO. They wouldn’t even pay for food or a hotel. Argh.

Korea’s pretty fascinating. They have a lot higher quality roads here than in the US. The town I’m nearby is huge in US standards, but small in Asian standards. I’ve been into town a couple times to go shopping or play games; I like visiting just to see how friendly and honest the people there are. Korea definitely has some big advantages compared to the states.

Everyone kept telling me that I’d hate the food here, and while I didn’t love it at first, I’ve found that I really like it now. It’s got a lot of flavor and it’s really healthy for you too. The kimchi is usually the spiciest thing they give you, but as long as you mix it with some rice it’s okay.

In other news, the website is back up after what’s probably been at least a month. Sorry about that. I’ll try posting some pictures from Korea soon as well.

If a monkey can row with a ladle

Posted in Personal on July 11th, 2008 by Nayruden – Be the first to comment

Work has been interesting. We’ve been trying to make an editor to visualize some massive data lying around in databases. Our solution to this problem until yesterday afternoon was to use GMF, but for the past two weeks we’ve been bogged down with the seemingly simple but important task of how to place a label.

So yesterday afternoon, with a mere month left before we have to present our project to the CEO of Rockwell Collins, we decided to scrap the GMF idea and go with yEd. This may sound like a risky business move at first… but by 10 AM this morning we had replicated all functionality we had with GMF plus a little bit more. Wow! It’s another open vs closed source argument, but in this case closed source is not only champion, but king.

Speaking of work, I got asked to participate in a mock interview today. My technical lead has been disappointed with their interviewees not being able to answer their questions recently, so they wanted to interview me and my fellow interns to try and set a baseline expectation. First they asked us to explain a UML diagram. It was a simple diagram but using some conventions that you never really see in the real world which could trip you up. Then they had us write the code for that UML diagram. Next, we wrote an implementation of a doubly-linked list. I got nervous here and did rather poorly (lots of bugs), but my lead was happy and said I still did better than the others they had do it. Finally they had us identify some obfuscated C++ code. It was a template that could be used to turn any class into a singleton simply by inheriting the template. It was pretty cool, but you definitely have to be up to date on your C++.

On a completely different topic, I bought a MacBook Pro a few days ago. I want to continue to reserve judgement for a while longer, but so far two things have me really ticked.

First, the dock: While it’s ‘nicer’ than a taskbar it’s essentially useless if you’re a developer who likes to have a lot of windows open all at the same time. The dock will only take you to the most recently used window of an application. If you want the other windows you need to cmd-tab (hard with lots of windows) or use Expose (easier than cmd-tab but still more annoying than windows taskbar).

The second thing that annoys me to no end is the inability to create a file from finder. Maybe they did this because they didn’t want to be like Windows and have a big box of different types of files you can create, but Mac should at least let me create an empty plain text file!

On the positive side, I’m enjoying how nearly everything you need to do (except for creating a file) takes less mouse/keyboard navigation than on Windows. Big timesaver there! Also I’ve become a big fan of the multi touch trackpad. I’m finding that between the two finger scroll and the two finger right click, I have no need for an external mouse at all.

Still thinking about what to do for my hosting. Don’t think I’ll keep my current one while in Korea, but I also hate to lose ‘em (I’d never get something this nice at this price ever again).

EDIT: Slashdot had an article relevant to my interview discussion. Thought you might be interested.


Nayruden's /dev/random is Digg proof thanks to caching by WP Super Cache