Sandcastle and API Documentation

I’ve received a few emails recently on how I created the API documentation for my Wiimote library so I thought I’d answer here with a brief tutorial.

The answer, in case you didn’t read the post subject, is Sandcastle. Sandcastle is a tool developed by Microsoft which builds MSDN-style help files by using reflection and XML comments from the source code of a project. Out of the box, Sandcastle is command line driven and kind of a pain to deal with, so I highly recommend the very easy to use Sandcastle Help File Builder (SHFB) application also hosted on CodePlex. This front-end provides a simple UI for setting options and building your help file in just a few minutes. The rest of this post assumed you have both Sandcastle and Sancastle Help File Builder installed.

Building documentation is easy. First, add XML documentation comments directly to your source code. You can do this by typing 3 forward slashes in Visual Studio above your class/method/type/property/etc. and the IDE will fill in the documentation template. For example, if you had a method definition which looked like this:

Read More

WiimoteLib Survey Results

Once again, a bit thank you to all of you who took the time to respond.  I was amazed to receive 100 responses as quickly as I did.  So here are the results and a few comments.

1. What type of release schedule would you prefer?

Response

Response Percent

Response Count

Frequent, small updates

59.1%

55

Infrequent, large updates (what I have been doing so far)

40.9%

38

 

2. I broke backward compatibility between version 1.1 and 1.2. I'm looking to do it again by cleaning up various things such as:

  • Moving anything with an X/Y coordinate to a Point struct
  • Since there are now 4 IR points all with the same properties (X, Y, MidX, etc.), I'd like to turn an IR itself into a struct, thereby having 4 IR structs in the IRState struct instead of the mish-mash of properties
  • And anything else I haven't thought of or mentioned here...

How important is backward compatibility to you?

Read More

Tech Valley .NET Users Group Session

UPDATE: This event has been rescheduled to Tuesday, February 19 at 6:30pm due to the weather.

For those of you in the Capital District region of NY like myself, I'll be giving a session on how to interface external hardware using .NET at the Tech Valley .NET User Group on Tuesday, February 12 at 6:30pm.  Here's my poorly written blurb on the subject:

While developers write code to build software every day, not often are they exposed to code that drives and interfaces hardware. This session will attempt to bridge that gap and show how .NET can be used to effectively interface several hardware devices, including an RFID reader and tags, Phidget control boards with a variety of sensors, and a servo controller. Finally, the Nintendo Wiimote will be introduced along with my .NET Wiimote Library, demonstrating how to connect to a USB or Bluetooth HID device and use it from .NET, with examples showing what the Wiimote itself is capable of.

Read More