Bluetooth Remote Control 0.8.5

By Jerome at December 25, 2007 17:56 Tags:

This is a minor release to fix a bug that slipped into the previous release. A blocker bug that prevented the software to run for new users... This is now fixed !

See here to download the fixed build.

Visual Studio 2008 Presentation in Montréal

By Jerome at December 11, 2007 21:46 Tags: ,

This last Monday, there's been a presentation for the GUVSM of Visual Studio 2008 at Microsoft Montréal by Guy Barrette, a Microsoft Regional Directory. The room was a bit crowded but there was a pretty good ambience. This was my first time there and I met a former distant colleague of mine from Winwise, Laurent Duveau.

On the menu, an overview of only the tooling that can be found in Visual Studio 2008. Not that C# 3.0 and .NET 3.5 are not interesting, far from it, but this will probably be the point of another session.

Multi Targeting

VS2005 forced the migration to .NET 2.0 when coming from VS2003. VS2008 does not enforce the migration to .NET 3.5, and leaves a choice of targeting .NET 2.0, 3.0 and 3.5. Solution and Project files don't change much, which means a smoother transition from VS2005 to VS2008. Some developers can run VS2005 and some others VS2008 without any difficulties. The only downside about the multi-targeting is that Microsoft dropped the support of .NET CF 1.0 and forces the conversion of projects to .NET CF 2.0.
The target framework can also be changed afterward, upgrade or downgrade. At that point, this is a good feature but if you have a solution that contains 100+ projects, this can be a repetitive task to migrate each and every one of them. I'll discuss that in an other post, but I wrote a small tool that converts every csproj file it can find to a .NET 3.5 project. That gave me the opportunity to test XLinq, by the way :)

VSTO (Visual Studio Tools for Office)

There is now no more the need to install add-ins to create VSTO addins, support for Office 2003 and 2007 is now included out of the box. Guy showed us how to create a simple plugin that creates a task pane which opens via a custom Excel Ribbon button, fills up from a database, and then fills the selected cell with some info. Pretty interesting stuff and easy to setup. It seems that now the deployment of VSTO addins has been greatly enhanced, compared to what could be done with VSTO and VS2005.

WCF

WCF now has an integrated webservice testing tool, that allows to call your WCF webservice without having to create the little testing project in Console that calls the webservice to test it. I'm guessing that it'll be useful only in the first few minutes of the webservice development, but after that... Maybe for the demos :)

Javascript

Javascript has a better support, especially for debugging. It is now possible to step into methods defined in javascript in the actual files, not in their memory representation. It is also possible to have custom help for javascript methods ! This is a hack using xml comments like in the ones found in C#, but that's helpful. I kind of hate the javascript development partly for the lack of debugging features and intellisense, but with this, I might hate it a little bit less...

SQL Server CE

It is a port of the SQL CE engine found on Mobile Devices. It's a small database engine similar to Jet could have been back in its days, but is compatible with SQL server to some extents. There's no stored procedures, no security, but it's a cheap way to store data instead of maybe using XML files to store data.

Database Cache

which is a out of the box component that is able to create a snapshot of the database, and handle the synchronization of the snapshot later in time.

Mobile Development

And finally a few words on mobile side, for which it is now possible to test security scenarios, with third party executable signature enabled, for instance.

This was a pretty rich session, with too much to say probably, but I learnt a few things along the way. I'll definitely attend the next one in january !

Visual Studio 2008 : Where is my Solution Explorer item sort gone ?

By Jerome at December 11, 2007 13:58 Tags: , ,

As a new user of VS2008 and senior user of VS2005, you may just just start to convert your projects to VS2008. Good. Then you look at your solution and start to look for your favorite project in the Solution Explorer and have trouble finding it... Of course ! The list is not sorted...

You may wonder, where is that sorting gone ? Well, I don't know exactly but it seems that if you select a project, press F2, then enter without modifying a thing... The tree sorts itself out! The bad thing is that you can't save that sorted list, as it seems that it is only the TreeView that sorts the item list, not the internal list that is sorted... I know for a fact that there are some PowerToys that sort the entries in the SLN file, I'll try to look for that.

How could something as visible as this has passed through the beta phase ? :)

The (non generic) System.Action delegate

By Jerome at December 09, 2007 22:33 Tags: , ,

There's been one delegate I wish would have been integrated in .NET 2.0 :

1:
2: namespace System
3: {
4:   public delegate void Action();
5: }

Well, it's been added to the .NET framework 3.5. That will avoid me to create here and there an empty delegate that returns nothing and takes nothing in parameter. It's particularly useful with anonymous methods.

My discovery of that particular type is a bit odd though. A big project I'm currently working on is defining this type :

1:
2: namespace T1 { public enum Action { A } }

"T1" is made up, "Action" is not. And it's being used like this :

1:
2: Action a = Action.A;

And it compiled just fine using .NET 2.0. During a migration to the .NET Framework 3.5, I came across some compilation problems telling me that the resolution of "Action" was ambiguous. I thought at first that this was because of a change in the resolutions of types in C# 3.0, but after a bit of digging I found out about that non-generic System.Action delegate, which is defined in System.Core.dll. By the way, they also added some other System.Action overloads with two, three and four generic parameters.

Reflector tells me that the non generic version is being used by System.Linq.Expressions.Expression. I'm guessing that might be used by LINQ in some way... maybe by some generated code.

Bluetooth Remote Control 0.8.4

By Jerome at December 09, 2007 20:06 Tags:

This is my first Canadian based release :) This is also a minor release that addresses a few issues and adds some cheap features that have an important added value.

Download here.

I've changed some minor things like :

  • Adding panning control to Winamp and the Windows Mixer
  • Adding the ability to start the server minimized to tray
  • Adding a Start with Windows option at install time and on the server side menu
  • Adding the ability to keep the Backlight on for the Mobile Side when connected
  • Adding new bindings for the Windows Media Center (Channel Up/Down, Zoom, The Green Button)
  • Building using Windows Broadcom SDK 6.1.0.1501 and Windows CE SDK 1.7.1.5201
  • Fixing mobile side crash when tapping on the screen in some situations
  • Adding a more explicit message when the Bluetooth Stack is not supported on the Mobile Side.

I'm also considering a migration to Visual Studio 2008 and .NET 3.5, but this means that I'll have to drop the support for WM 2003 based devices. VS2008 does not allow the compilation of .NET CF 1.0 projects, which bugs me a bit. So this release might be the last to support WM2003 devices. I don't have much of choice either... .NET 3.5 muses are quite appealing !

Have fun !

Snow in Montréal, QC

By Jerome at December 04, 2007 20:16 Tags: ,

Well, how original is that. Snow in Montréal. The last time there was that much snow in here at this time of the year was many years ago, and this time 40 centimeters fell from the sky in 24 hours. For what I can see here and there, some are happy about that, some a bit less. Schools are closed, traffic quite a bit jammed and offices part empty.

PublicLight in a Snow Storm
A Whole lot of Snow

Anyway, as long as you're on foot and have waterproof winter boots, that's good... and for now that suits me. I just wish I won't be needing a car in a too near future ! Is that really a car under this ?! :)

I just had to slide down to the street. The ambience outside was particularly interesting, and that was a pretty good moment to take some shots !

Snowy Stairs

News from Montréal

By Jerome at October 19, 2007 07:14 Tags:

There I am ! I'm now in Montréal, enjoying my strike-free environment ! Weather's still good with a pleasant temperature, at the end of the "été des indiens".

After visiting a bunch of canadian administrations, I'm now enjoying some peaceful time with my wife, visiting some places and friends we've seen the last time we went there. People here are so much cooler than in Paris... No one rushing even at peak hours in the subway, people waiting in line to take the bus... I like that ! I'm told that compared to Québec city, Montreal life is stressing. I wonder how's life in Québec ! Point of view and stuff... 

Relocating is not an easy thing to do, with so many things to think at once, like selling stuff, terminating contracts and stuff. Well, this is done now :) If you ever need to ship some personal effects from france, I can tell you that "Bagages du Monde" is doing great.

My new job at Averna is starting in a few days, I'll be telling you a bit more by then ! (as well as show some pictures !)

Bluetooth Remote Control 0.8.3 - Broadcom Bluetooth Support for Windows Mobile

By Jerome at September 10, 2007 11:26 Tags:

This time, I've added the support for the Broadcom (formerly Widcomm) stack on the Windows Mobile side.

This should add support for the Motorola Q9, which uses this particular stack.

On the stability and compatibility side, I've only tested on a version of the widcomm stack for the HTC Wizard, but only on WM6 and I don't know if it actually works on other devices :)

If it works for you, please let me know !

Download Bluetooth Remote Control 0.8.3 now !

If you ever want to install the Broadcom stack on WM6 for the HTC Wizard and you get a "Not enough driver memory", try changing the "StackMode" value from "0" to "1" in HKLM/Widcomm/BTConfig/General. It worked out for me :)

Broadcom/Widcomm Bluetooth Stack and SetSecurityLevel

By Jerome at September 05, 2007 15:37 Tags: ,

C++, my almost favorite language. This language had good intentions, really. But this is such a pain -- a  pit of despair -- to have to deal with library compatibility and compilation parameters matching issues, where it should be handled by the system.

Anyway, if you're trying to use the Broadcom Bluetooth SDK for Windows CE with VS2005 or VS2008, you might encounter this pretty message :

error LNK2019: unresolved external symbol "__declspec(dllimport) public: int __cdecl CRfCommIf::SetSecurityLevel(wchar_t *,unsigned char,int)" (__imp_?SetSecurityLevel@CRfCommIf@@QAAHPA_WEH@Z)

The symbol actually exists in the broadcom provided library (BtSdkCE30.lib or BtSdkCE30.lib)  but is defined like this :

SetSecurityLevel@CRfCommIf@@QAAHPAGEH@Z

which, undecorated, means :

int CRfCommIf::SetSecurityLevel(unsigned short *,unsigned char,int)

See the difference ? The wchar_t type the compiler is using should be an unsigned short. Basically, both types are binary equivalents but the compiler is treating them as different, hence the different signature.

To fix this, just set the option "Treat wchar_t as Built-in Type" to No.

This way, the wchar_t will go back to being a short, and then match the method built in the static library.

I'm going back to my C# code, now.

Canada !

By Jerome at August 31, 2007 11:52 Tags:

Well, that was as not easy as it would have seemed, but it's done ! I'm moving to Canada !

I'll be in Montréal by the end of the year, still working with .NET technologies, but with the canadian spirit that I think I'll enjoy to learn and live with !

There's a lot of french people over there, like SharkOne (maybe still there at that time ?), or Sanx, and some other Epitech students I've graded a few years ago... This'll be great !

And no worries about Bluetooth Remote Control, I'll continue working on it :)

About me

My name is Jerome Laban, I am a Software Architect, C# MVP and .NET enthustiast from Montréal, QC. You will find my blog on this site, where I'm adding my thoughts on current events, or the things I'm working on, such as the Remote Control for Windows Phone.