A Data-Logging Flashlight

The next feature the customer wants to add to our ultimate flashlight is a data-logging facility. This will track the times when the flashlight has been switched on as well as the duration of each use. This tracking information will allow the performance of different batteries to be evaluated, and allows us to explore the manipulation of dates and times in the .NET Micro Framework. It will also let us see how we can build custom classes to store data, and how we can create a structure to hold a collection of data items.

Of course, the information is useless if it stays inside the flashlight, so we will need a way of transmitting the data to the outside world. Fortunately, the device we are using is fitted with an RS-232 ...

Get Embedded Programming with the Microsoft® .NET Micro Framework now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.