Wednesday, August 02, 2006

Inside the Lego Mindstorms NXT SDK

I've taken a look at what is inside the current NXT'TREME information (Lego's Open Source page).

Within the Software Development Kit (SDK), the "Executable File and Bytecode Reference" is a great source of information, and the perfect companion to the NXT Byte Code (NBC) compiler. This is great stuff for "power users" of the NXT. Has anybody tried to communicate over Bluetooth using NBC?

You can also interface with the driver on the PC/Mac. I haven't really looked deeply into this. It contains a number of .VI (LabView) files, and a number of header files. If someone has more information on the proper use of this SDK information, please comment.

The Hardware Developer Kit (HDK) is full of insightful information. The amount of disclosure here is perfect, it looks absolutely complete. Some insights drawn from the HDK:

  • The output ports use PWM signalling to the servo motors. This is a standard communication method for servo's, and it implies that other servo motors could be connected when properly wired.
  • The sensor ports have a pin for analog input. This input is digitized once every 3 milliseconds. The value is converted into a 10-bit value (range 0 - 1023).
  • Each sensor port can also communicate using the I2C communication protocol (only as master). The Ultrasonic sensor is currently the only standard Lego sensor using this capability. HiTechnic's and MindSensor's sensors use this capability too.
  • Analog sensing faster than every 3 milliseconds is possible using the NXT hardware, but currently not supported by the firmware.
  • The NXT has a RS485 serial port hidden behind sensor port 4. This enables extremely high data rate communication (theoretically up to 35 Mbs), or over longer distances (theoretically up to 1.2 kilometer/ 0.75 miles). The RS232 serial port we all know so well connects one device with one appliance. However, the RS485 was designed to connect up to 32 devices to a single serial port. In other words, there is a lot of opportunity to tap sensor port 4 for future applications. In the future, Lego considers using P-Net to connect multiple devices. Right now, this is not supported by the firmware.

Clearly, the amount of information Lego has released on the Lego Mindstorms NXT set is nothing short of amazing. They want to support the NXT community as much as possible. I almost feel guilty for still being left with this one question: are they going to open source the actual firmware source code too? I believe it would make a lot of sense to do so.

Filip

2 Comments:

At August 07, 2006 12:48 AM , Anonymous Anonymous said...

Hooray!

I have no reason not to purchase the NXT set now. RS485? I2C? I'm so happy I can hardly contain myself!

 
At August 07, 2006 9:56 PM , Blogger Drew Stevenson said...

I think I am starting to recognize the different annonymous's that are out there in NXT web land.

 

Post a Comment

Subscribe to Post Comments [Atom]

Links to this post:

Create a Link

<< Home