Blog header image

Welcome to our blog. We hope that these pages provide an insight into us, our products and how we develop them. Please feel free to write to us if you have anything to add to any of the posts here.

Current Entries  Archives  RSS

Visual Lint and Atmel AVR Studio 5

Friday, September 16, 2011

From our perspective one of the more intriguing embedded environments to appear recently is Atmel's AVR Studio 5.

When I first saw a screenshot of this IDE (it was mentioned in a post in the CodeProject Lounge) it was immediately obvious that this was some sort of Visual Studio derivative.

In fact, although it uses GCC toolchains, the environment is based on the Visual Studio 2010 isolated shell (which incidentally is something we briefly considered using ourselves for a future standalone GUI version of Visual Lint, but decided against because of its complexity and the size of the download).

It obviously occured to us then that as a Visual Studio derivative, it shouldn't be too difficult to get Visual Lint running within it. The first step was obviously to install the IDE in a VM (XP SP3 - doesn't XP look a bit old these days...?) and experiment with some projects.

AVR Studio 5 codebases uses the Visual Studio 2010 solution file format (albeit rebadged as a .avrsln file) and a new MSBuild based project file format (.avrgccproj), so the first thing we obviously had to do was implement parsers for these files (something that will also benefit LintProject Pro, of course). Once that was done, we turned our attention to getting Visual Lint to load within the IDE itself.

This turned out to be fairly straightforward. Although AVR Studio 5 does not seem to support COM add-in registration in HKEY_LOCAL_MACHINE (which is how the Visual Lint add-in registers in Visual Studio), the corresponding registration in HKEY_CURRENT_USER\Software\Atmel\AVRStudio\5.0\AddIns does work. Although this is problematical from an installation point of view (see my previous post on the Visual Studio 11 Developer Preview) it is not a showstopper by any means.

With manual add-in registration in place, Visual Lint loaded within the IDE. Although a few minor tweaks were needed to work around issues such as AVR reporting itself as "Visual Studio Express Edition, version 1.0" (which caused the version detection code in Visual Lint to default to 16 colour command bitmaps!) those were easily addressed.

As a result, we now have AVR Studio 5 running with a development build of Visual Lint:

Visual Lint running within AVR Studio 5

Visual Lint running within AVR Studio 5

Although we still have quite a bit to do (not least the code editor markers and installer) before AVR Studio 5 can become a supported host environment for Visual Lint this is a very promising start. Needless to say, beta testers are welcome.

Posted by Anna at 16:17 | Get Link

Visual Studio 11 Developer Preview

Thursday, September 15, 2011

Hot on the heels of the Windows 8 preview (which we're already experimenting with in a VM) comes something probably even more significant for us - an early preview of Visual Studio 11, no less!

The first thing we tried to do was of course to load Visual Lint into it. Although Visual Lint won't yet load automatically into VS11, by the simple trick of exporting the registry from HKEY_LOCAL_MACHINE\Software\Microsoft\VisualStudio\10.0\AddIns\Visual Lint and reimporting it to HKEY_LOCAL_MACHINE\Software\Microsoft\VisualStudio\11.0\AddIns\Visual Lint (with the Wow6432Node node on x64 machines, of course) we were able to get it to show up in the VS11 Add-In Manager.

Unfortunately, Visual Studio then reported an error when it tried to load the add-in.

After a little experimentation we discovered that VS11 COM add-in registration in HKEY_LOCAL_MACHINE is broken in the preview, but once we moved the registration to HKEY_CURRENT_USER Visual Lint loaded correctly (albeit without a toolbar or menu as its VSPackage implementation doesn't yet know about VS11).

If you really need the proof, here it is:

The Visual Lint Status View running within the Visual Studio 11 developer preview

The slightly unnerving thing about this is the issue it raises within the installer - writing to HKEY_CURRENT_USER from an elevated installer is highly discouraged behaviour (it will cause your app to fail a platform test if you submit it for formal testing) and for good reason - if the logged in user doesn't have admin privileges the user account that gets modified by the installer will be the wrong one.

Hence if this isn't fixed in VS11 we have some headscratching to do. Nevertheless, it's a start.

Posted by Anna at 20:32 | Get Link

Visual Lint has been released

Monday, September 5, 2011

The following changes are included in this build:

Posted by Anna at 13:37 | Get Link