Micro Framework TripComputer Sample
Micro Framework introduces a new approach to embedded development.
The following key points:
- Minimal hardware requirements
- Strong runtime support
- Easy and intuitive development model
- An extensible emulation environment
Make iteasy to address application development for simple devices used in consumer electronic and industrial automation.
Additional resources about Micro Framework are:
- Microframework WhitePaper
- MSDN Webcast: An Introduction to the .NET Micro Framework
- Micro Framework msdn web site.
- Micro Framework web site
- Alden Linn blog
- Micro Framework newsgroup
- Micro Framework SDK Download page
Attached, I propose the TripComputer Sample and SampleEmulator applications I used in a recent Webcast.
The Trip Computer sample is a very simple application that shows the structure of a Micro Framework application.
SampleEmulator application shows a simple customization where I added a GPIO button to the default emulator to better simulate the real tripcomputer.
The following figure shows the tripcomputer application run with the default emulator and with the customized version of the emulator:
The application starts on the static main() method of a class deriving from Microsoft.SPOT.Application.
Static main method creates an instance of the TripComputer Window and starts a Dispatch loop on it.
Class TripComputerWindow derives from Microsoft.SPOT.Presentation.Window and aggregates some panels and textboxes using the Windows Presentation Foundation (WPF) object model.
Load() Method shows the code to start a timer for updating the clock on the bottom right angle of the trip computer.
The TripComputer application shows some features unique to Micro Framework WPF graphic engine like the linear gradient brush on the background, the controls layout by means of vertical and horizontal stack panels and the interception of the ButtonUpEvent routed event at the main window level.
In summary, developing embedded applications with Micro Framework is easy and intuitive and relays on the same development model of other .Net applications
Comments
- Anonymous
April 27, 2007
La vision di Micro Framework Piccoli dispositivi elettronici controllati da microprocessori sono sempre