Wednesday, May 28, 2008

Remoting with eventing is working!

It has been quite a while since we set ourselves the goal to realize .NET remoting with eventing. For several reasons, I couldn't put enough effort in it, but now I have a working prototype. Finally!

What is it?

The solution consists of two executables and a shared library containing the interface definitions.
For each there is a separate project within the solution.

Server.exe

A .NET Compact Framework WinForms application representing the server side that will be running on the eBox eventually.
For now, a picture of an iRobot Create is displayed with which you can interact.

Client.exe

A .NET Full Framework WinForms application representing the control application (client) running on a PC.
There is a checkbox that can be used to switch Roomba's power LED. Three other checkboxes are checked when Roomba's bumpers are pressed.

Interface.dll

Containing the IServer and IClient interface and some enums. Both client and server communicate with each other via these interfaces through (As Good As It Gets) remoting.

A short demo

It's important to start the server first.



When the server is running we can start the client. The server's ip address should be set in the client's config file. Directly after starting the client, it will try to connect to the server. After this connection is established, the server will setup a new connection channel to the client to transport callbacks. Via this channel the client is informed that we're ready to go. As a result the power checkbox is enabled and ready for user interaction.

Clicking this checkbox will change the power led's state on the roomba in the server window.



You can see the callbacks work by clicking (and holding) Roomba's virtual bumbers. This can be done in 5 different places: front, left, right, front left and front right.


These 'bumps' are reflected in the client via (combinations of) checkboxes.


For the complete solution, update from the Siibot archive and check out %SIIBOT%\Development\Trunk\Sw\PoC\
CallbackRemoting\CallbackRemoting.sln
Please check the Readme.txt first if you want to run the solution. If you still have questions, you can always ask me.

No comments: