BT

A Native of Silverlight with Full Hardware Access

by Jonathan Allen on Mar 15, 2012 |

Silverlight Embedded is specifically designed for embedded devices that do not necessarily have network connectivity, or if they do the connection is sporadic. XAML was chosen for the UI layer so that the same partial separation between designers and developers enjoyed by .NET and web developers could be employed for embedded systems. But the limitations of hardware meant that a native programming language is more appropriate.

It is important to note that this isn’t Windows 8/WinRT. Silverlight Embedded has full access to the Win32 API and underlying hardware exposed by the operating system. All of your legacy Windows Embedded libraries should continue to work under Silverlight.

That said, there are some similarities. For example, Hardware accelerated graphics are offered via DirectDraw or OpenGL, but they are not required. Data binding is supported in Silverlight Embedded using normal XAML binding expressions. On the code-side, the models need to implement the IXRPropertyBag interface instead of INotifyPropertyChanged. For other differences, see this comparison between Silverlight 3 and Silverlight Embedded.

The first version of Silverlight for Embedded was released for Windows Embedded CE 6 Release 3. This version had an API based on Silverlight 2. The next version was for Windows Embedded Compact 7, which uses the Silverlight 3 API. The tooling for the first version was rather crude, but with Microsoft is claiming this version is much more mature. The tools needed to get started are

  • Visual Studio 2008
  • Expression Blend 3
  • Silverlight for Embedded SDK
  • Platform Builder 7

The platform builder is especially import: this is the tool that creates the skeleton of a C++ project from Expression Blend’s Silverlight/XAML project. Controls that will be accessed need to be named and event-handlers registered before running the tool. Fields and callbacks that represent these will be automatically generated in the resulting C++ header and code files. As the XAML is changed, the tool is reapplied to update the generated code.

Other concepts such as animation are available in Silverlight Embedded. Storyboards are created in Expression Blend just as if you were building a Silverlight for web or Silverlight for Windows Phone application. Of course care must be taken to avoid using animations that are too complex for the target hardware. A demo of this can been seen in the video Creating and Using Silverlight for Embedded Applications.

Hello stranger!

You need to Register an InfoQ account or to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Tell us what you think

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Great! by Paulo Pinto

Nice to see C++ regaining first class status on Windows.

Re: Great! by sulfide smolder

c++...vomit.

Re: Great! by Faisal Waris

C++ '11 is a major overhaul of the language which adds (among many other features) functional aspects (lambdas) and new smart pointers (auto garbage collection).

See: www.softwarequalityconnection.com/2011/06/the-b...

I think C++ is worth another look now.

Re: Great! by Paulo Pinto

Which other multi-paradigm language would you use instead, to target high performance native code?

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

4 Discuss

Educational Content

General Feedback
Bugs
Advertising
Editorial
InfoQ.com and all content copyright © 2006-2013 C4Media Inc. InfoQ.com hosted at Contegix, the best ISP we've ever worked with.
Privacy policy
BT