This is hillarious.. A must hear for music lovers! And considering the sound comes from Windows XP and 98, a big kudos to the author!
This is hillarious.. A must hear for music lovers! And considering the sound comes from Windows XP and 98, a big kudos to the author!
So what’s the big buzz about WIndows 7? Firstly, it uses the same base architecture as its predecessor, Windows Vista. Recently, Bill Gates and Steve Ballmer had a chance to reveal a feature of Windows 7. You heard it right, a feature = a single feature, which we are all already aware of. MULTI-TOUCH!
Basically, they are trying to "squeeze" in the Microsoft Surface functionality into a Tablet PC. At D6, they were running a live demo of multi-touch feature of WIndows 7 on a Dell Latitude XT tablet. Considering this is going to be one of the core UX feature they have, it will be interesting to see where the OS are heading in few years time.
For those curious people out there, here is a little sneak-peek video of Windows 7.
Yesterday, we, the OZDreamTeam (consists of 4 university students: myself from Swinburne University, Dave from University of Tasmania, Ed from University of Melbourne and Long Zheng from Monash Univ) had the honour to be announced as Australian Imagine Cup winner for the Software Design stream.
We will be competing for the world finals in France on July 2008. Really looking forward for that.
Here is a brief overview of our project. Note: the information provided here is subject to change. We are planning to have a massive upgrade of our solution for the world finals.
SOAK which stands for “Smart Operational Agriculture ToolKit” is an integrated hardware and software platform that aims to help farmers make the most of the water (and other) resources on their land. It does this through an integration of a wide range of sensors which gathers data about the environment in real time, provide rich visual information to end-user about the status of the farm, and electronically controls various systems such as sprinklers.
For example by gathering online weather forecasts about the property, if the weather is predicted to rain in the next 48 hours and the current soil moisture is adequate till then, our system can conserve water usage by not watering before the rain falls. Also as a precaution, is the rainfall is inadequate, the watering system will resume operations to compensate for the difference.
Sensing the environment
SOAK supports a wide range of sensors such as
These sensors provide SOAK with the relevant real time information that is needed for the more advanced functionality.
External data resources
SOAK utilises a number of resources such as Microsoft Virtual Earth for mapping data, Weather forecasting for predictions on when to water, and the British Telecom SDK for SMS notifications when there is a critical event at a farm (such as a fault in farm equipment)
Manipulating the environment
An automated watering system allows for a very fine level of control over when to water. The weather forecasting is taken into consideration when calculating if now is the best time to water the crop. If rain is predicted to fall in the next 48hours, the system can hold back from water so as to reduce the water consumption of the farm.
User interaction
Currently SOAK has implemented 3 delivery mechanisms each targeted to a specific use and data consumption.
The Silverlight web application is the main access point for SOAK. Here we present very detailed and visual information tailored to management users. This was created as a mashup between Microsoft Virtual Earth and Silverlight 2.0 Beta1.
And here is the SideBar Gadget
The PDA application provides field operators with real-time summary information about the areas they are visiting and gives them access to a manual over-ride of the sprinkler system when out in the field.

A few weeks ago, ScottGu, ScottHan, and PhilHaack-ed (from the MVC team), released the MVC Preview 2. ScottGu also announced that they have made the source code available at CodePlex ASP.NET. Although it seems that they have taken the installer off from the original Microsoft site.
For those who are looking for the original MVC Preview 2 Installer, you can download it here.
On the side note, I have started playing around with MVC Framework after seeing how enthusiast ScottHan’s presentation at Mix08. So, I started new Blog Engine project hosted in CodePlex.
Why did I decide to do Blog Engine project? Well, first, it is fairly straight forward. Second, there isn’t much of a good .NET Blog Engine out there.. I have downloaded few of them, but none of them is comparable with WordPress (in terms of simplicity and extensibility).
So, based on these constraints, PandaBlog was born. For those of you who are wondering why on earth did I name it PandaBlog.. Well, I was inspired by the trailer of Kungfu Panda (by Jack Black). On top of that, panda is one cute little animal.
At the time of writing this post, PandaBlog is still a working progress. If you want to contribute to the project or wanna pass on your feedback, feel free to do so by emailing me at dimaz.pramudya@gmail.com
Thanks.
Singleton is one of the design pattern that only allows a single instance of a class exist at one point of time. See example below:
public class SampleSingleton{private static SampleSingleton _Instance;private SampleSingleton(){}public static SampleSingleton Instance{get{if (_Instance == null)_Instance = new SampleSingleton();return _Instance;}}}
However, the issue comes in to play when running the above code under multi-threaded environment. Let’s say if you have 2 threads accessing the Instance property above at the same time.
Thread 1 starts first. First, it checks if the _Instance is null, and since it is, it will execute the statements inside the if block. However, just before it executes the “_Instance = new SampleSingleton();” line, it gets context-switched out.
Thread 2 starts. Note that when Thread 2 is executing the “if (_Instance == null)” line, it will result in a true statement because the assignment from Thread 1’s action hasn’t been committed yet. Then, Thread 2 continues and return an instance of SampleSingleton (we call it InstanceA).
When Thread 1 is resumed, it will continue create another instance of SampleSingleton (we call it InstanceB) which is totally different than what Thread 2 has created previously.
So, you see the concurrency problem here?
To overcome this issue we have several solutions:
1. Put the lock statement (or SyncLock in VB) around the if statement to ensure that the checking and creation of the Singleton object is done in an atomic manner.
The downside of this approach is performance. Imagine if all access to this property should go through a lock mechanism.
2. There is a workaround (read: hack) which is specific for .NET compilers to allow the creation of Singleton object without the overhead of using lock statement. More below.
The trick is to define static constructor on the Singleton class. In .NET, static constructor cannot be inherited, nor be called directly.
Few of the following attributes of the static constructor:
public class SampleSingleton{private static readonly SampleSingleton _Instance = new SampleSingleton();/// <summary>/// Static constructor to ensure that all static fields initialization before this/// is done in an atomic manner./// </summary>static SampleSingleton(){}/// <summary>/// Private constructor to ensure that it can’t be initialized normally using new keyword/// </summary>private SampleSingleton(){}public static SampleSingleton Instance{get { return _Instance; }}}
On the code above, since the static constructor is guaranteed to executes at most once during the class initialization, it sort of acts as the “locking” mechanism to ensure that the _Instance initialization is done atomically, without the cost of using lock statement.