Friday, January 8, 2016

New RPC library released, Smart-RPC.NET v1.0.8

A few weeks ago I started to play with a Universal Windows application on my Raspberry PI 2. I was able to interface with a WCF service, however running a webservice was a no-go.

At that time I decided it was time to create an RPC library, RPC stands for Remote Procedure Call. One of the reasons was that I was not satisfied with the found solutions. These solutions were either too complex, they missed certain functionality or some other reason. Another reason was that I saw it as a technical challenge.

During the last weeks I created the first version of the Smart-RPC.NET library. It is compiled as a portable assembly so using it in a Desktop or a Universal Windows application should offer no problems.

Some basic functionality:
  • Architecture in which certain parts can be extended with custom functionality. For example the communication path used between a client and a service can be customized.
  • Connection management, connection between client and service is monitored. When possible the connection is recreated from the client side.
  • Execution time of requests are monitor and terminated when the maximum period is exceeded. Client is informed when this happens to his request.
  • Notification mechanism in which the service side can trigger the client(s) without a direct request.

On the website the following is available:
  • a link to the project page at NuGet.
  • a link to a zipped example showing how to set up a client and service.
  • design information containing class diagrams and sequence diagrams detailing the mechanisms provided.

In the near future I will adapt the client side so that it can run on the micro .NET framework. I will be testing this on my Netduino Plus and Netduino Plus 2.

Thursday, January 9, 2014

[C#] Dialogs the MVVM Way

The Model-View-ViewModel pattern is really nice since it clearly defines the responsibility of the View, the ViewModel and the Model. There should be no direct contact between the View and the ViewModel and via the databinding mechanism, this is easily possible.
However, I ran into a problem when a confirmation was required from the user before removing an entity chosen by the user. The command responsible for the removal behavior was triggered from within the View and executed from within the ViewModel. In my opinion, the ViewModel should not directly use any presentation functionality (e.g. showing a MessageBox).
In my quest to find a reasonable solution on the web, I ran into the following solutions:
  1. Just show the messagebox from the ViewModel.  
  2. Use a solution that adds extra code to the View which reacts to a trigger from the ViewModel.
  3. Bind the View to a message property and have it show a messagebox when this changes.
  4. Use one of the available MVVM frameworks and use the solution they provide.
Solution 1 & 2 where directly discarded, solution 3 was getting close however I found it quite limiting to react to a change to a message. Solution 4 was not an option for me since I am not really fond of the MVVM frameworks I reviewed.

Because I was unable to find a solution matching my requirements, I came up with the solution as described in this linked article on CodeProject.

Wednesday, August 21, 2013

[Photos] Dive Site Mali Africa, Dubrovnik, Croatia

Picture made on July 26th 2013, maximum depth was 26.3 meters.

Tuesday, August 20, 2013

[Photos] Dive Site The Abyss, Dubrovnik, Croatia

Picture made on July 28th 2013, maximum depth was 17.7 meters.

Monday, August 19, 2013

[Photos] Dive Site The Abyss, Dubrovnik, Croatia

Pictures made on July 28th 2013, maximum depth was 17.7 meters.

Saturday, August 10, 2013

[Photos] Dive Site Sveti Andrija, Dubrovnik, Croatia

Some pictures I took when diving at the dive site Sveti Andrija. As one can see a lot of soft corals with quite some colors when using extra light. The dive was in the morning at 26 July 2013 with a maximum depth of 39.3 meters.

Sunday, July 14, 2013

[Photo] A nudibranch on the Thistlegorm

A nudibranch which I encountered while diving the Thistlegorm.