BrickEngineer: LEGO Design

LEGO Engineering for LEGO NXT and Robot Enthusiasts

Matlab Package for LEGO Mindstorms


I recently received a comment on my post on controlling NXT robots with Matlab that pointed me to the RWTH – Mindstorms NXT Toolbox for MATLAB®, which is a public domain Matlab package that enables one to interface with and control LEGO mindstorms.

The RWTH – Mindstorms NXT Toolbox for MATLAB® was developed as a student project in the Institute of Imaging and Computer Vision at RWTH Aachen University in Aachen Germany. It provides a Matlab interface with the NXT brick that includes Bluetooth communication, sensor interface and motor interface. It requires a working Matlab license, of course.

The package is very easy to set up. It took me less than ten minutes to successfully test the example programs over Bluetooth.

There are some very nice motor features, such as motor synchronization and speed ramp-up and ramp-down.

I have yet to explore how easy it is to modify or extend the code, but it ought to be a straightforward matter.

The package can be downloaded from
http://www.mindstorms.rwth-aachen.de

Kevin Knuth
Albany NY

Storing your LEGO Collection

It can be very difficult to figure out exactly how to store one’s LEGO parts. This depends greatly on the extent of your collection, and how mobile it needs to be. Below I offer a wide array of suggestions ranging from the size of one NXT set through tens of NXT sets with thousands of dollars of extra parts. Here I will review the solutions that I have found useful, and at the end I will provide a detailed description of my particular storage strategy.


Utility Boxes with Compartments
Clear plastic utility boxes with adjustable compartments are excellent for storing LEGO parts, keeping them separated, and making sure that they are accessible. I have found the products manufactured by Plano Molding Company to be especially useful. The Plano Prolatch with Adjustable Dividers
is secure and allows one to carry the box around without fear of accidental opening. These utility boxes are also included in the larger Plano Tackle Boxes, which provides an excellent means of both storage and transport.The new Custom Divider Systems (CDS) give you a great many ways to divide each box into bins with the greatest versatility. The other divider systems work well, but this is a nice option.

Small Box
Plano No. 2-3500-20
9-1/8″ Wide. x 1-1/4″ High x 5″ Deep
Up to 9 adjustable compartments
Order from Amazon.com
These fit into the Plano 1354 Tackle Box
below
Medium Box
Plano No. 2-3650-20

11″ Wide x 1-3/4″ High x 7-1/4″ Deep
Up to 18 adjustable compartments
These fit into the Plano 1364 Tackle Box below
Large Box
Plano No. 2-3750-20

14″ Wide x 2″ High x 9-1/4″ Deep
Up to 20 adjustable compartments
These fit into the Plano 1374 Tackle Box below

Tackle Boxes
Plano tackle boxes are designed to hold multiple (typically four) utility boxes above. This provides for a readily mobile storage solution. Your LEGO collection can be carried from your home, to the lab, a friend’s house, or into the field at a moment’s notice. Here is a photo of my Plano 1364 Tackle Box that I use for most of my construction needs.

Plano 1354 Tackle Box (3500 size)
I have found that the 1354 Tackle Box is a bit on the small side for even the smallest collections. You will be surprised at how many distinct kinds of Lego parts there are, when you find that they will never fit into the 9×4 compartments. However, this tackle box can hold 4 utility boxes, and you often can put an additional box in the top compartment.
Order at Amazon.com
Plano 1364 Tackle Box (3650 size)
This is a really nice size for a tackle box. I can easily store at least two NXT sets in this tackle box as well as many extra parts. Four Plano ProLatch 3650 stowaway boxes
fit in the tray resulting in 4×18 = 72 compartments. I also manage to keep an additional 3650 box in the top of the tackle box. I can often work with just this subset of my collection. In addition, it makes travel easy.
Plano 1364 Tackle Box at Amazon.com
Plano 1374 Tackle Box (3750 size)
This tackle box can hold a large number of parts. The top bulk storage compartment is sufficiently large and deep to actually hold smaller robots! The 3750 size utility boxes are very spacious, and this tackle box comes with one of the newer Custom Divider System (CDS) utility boxes, and one flip-sider, which is good for fishing tackle, but not so useful for LEGO parts. For this reason, you may need to buy an extra 3750 box to replace the flip-sider. And you may want an extra 3750 to fit in the top compartment.
Plano 1374 Tackle Box at Amazon.com

Compartmentalized Storage
For a more extensive LEGO collection, one may require more storage space for small parts, such as pins, axles, etc. Akro-Mills makes some very nice organizers with a large number of small drawers.

Akro-Mills 10724 24 Drawer Storage

This organizer can hold a healthy supply of small LEGO parts. The organizer comes with partitions that can be inserted into the drawers allowing one to keep more parts.Overall Size: W=20″ H=15.81″ D=6.38″ (inches)
Drawer Size: 4.25″ W x 5.25″ D x 2.0″ HI have three of these. One holds all of my pins and connectors. The second holds all of my axles and axle connectors, and the third holds all of my gears.
Akro-Mills 10124-2 44 Drawer Storage
This organizer can hold a healthy supply of small LEGO parts. The organizer comes with partitions that can be inserted into the drawers allowing one to keep more parts.Overall Size: W=20″ H=15.81″ D=6.38″ (inches)
Large Drawers: 4.38″ W x 5.25″ D x 2.0″ H
Small Drawers: 2.13″ W x 5.25″ D x 1.50″ H
Akro-Mils 10764 64-Drawer Storage

This organizer can hold many small LEGO parts. The organizer comes with partitions that can be inserted into the drawers allowing one to keep even more parts.Overall Size: W=20″ H=15.81″ D=6.38″ (inches)
Small Drawers: 2.13″ W x 5.25″ D x 1.50″ H

Large Storage Bins with Drawers
The larger collections require more extensive storage. Storage bins with drawers are excellent for storing large numbers of bricks of many colors and types. Stackable bins with drawers facilitate organization and access, although they require a good bit of space… or rather, your collection does!

Three Drawer Organizer
I have found the Sterilite ClearView™ Wide Three Drawer Organizer 2093 to work very well. Its dimensions are suffciently large to hold a large number of brick. Or one could make partitions (they do not come with the drawer) to store a wide array of parts in a single drawer. At this point, I use 20 of these to store my bricks, plates, liftarms, wheels, and specialized NXT parts. The clear drawers make it easy to see what is inside, and one can easily afix large easy-to-read labels.The dimensions of the three drawer organizer is:
14 5/8″ L x 14 1/2″ W x 10 5/8″ H.

Large Mobile Storage
My lab requires that a large proportion of my parts be easily transported. The best solution that I have found for this is the mobile toolbox together with a healthy set of Plano Utility Boxes (above). I was surprised to find that there is not the diversity in toolbox designs that I expected. I finally settled on the
Stanley Consumer Storage 033023R Pro Mobile Tool Chest.

This tool chest when packed full holds:
4 large Plano 3750 compartment boxes
3 medium Plano 3650 compartment boxes
6 small Plano 3500 compartment boxesThis is in addition to the large top tray that can hold Mindstorm NXT bricks, a great deal of cabling, and other tools that you might need.The tool chest has a handle and wheels, which makes for easy transportation.
Order from Amazon.com here.

See the more recent posts: COLORFUL LEGO STORAGE IDEAS and New LEGO STORAGE OPPORTUNITIES for more ideas.

Meta-Parts: Part III

This is a continuation from Meta-Parts: Part I and Part II and consists of a library of LEGO constructs that can in many cases act as liftarms for bracing various structures. Here we consider constructs made from the LEGO axle joiner perpendicular.

Axle Joiner Perpendicular Constructs I
These LEGO constructs are even more sturdy and can be used as extremely strong braces. These are especially good for LEGO Mindstorms NXT projects.

Axle Joiner Perpendicular Meta-Parts

Axle Joiner Perpendicular Constructs II
This figure shows the wide array of constructs that can be made with both the axle joiner perpendicular pieces. These pieces are constructed from either two or three of these joiners. An example showing seven of them is below. The number of combinations is staggering.

Axle Joiner Perpendicular Meta-Parts

I have found such LEGO constructs to be especially useful in robotics applications.

Meta-Parts: Part II

This is a continuation from Meta-Parts: Part I and consists of a library of LEGO constructs that can in many cases act as liftarms for bracing various structures. Note that these LEGO designs can easily pull apart when you apply forces in certain directions—usually within the plane of their design. They will not be stable for constructions requiring that they withstand forces in those directions. However, if you need to brace against forces that are directed out-of-plane, or to prevent torsion (twisting). These constructs may help. If you are desperate, and are willing to sacrifice purity, a drop of superglue will do wonders.

Planar Constructs
This is a strange set where the construct has round holes that lie in a plane. Some of these constructs are quite strong, but the next set is even stronger still.  These construct provide alternative ways to stabilize axles.

Planar Meta Parts

Rectangular Constructs
The following rectangular constructs are typically much stronger than the previous constructs. These examples sport round holes at either the corners of the side centers.

Rectangular Meta-Parts

Square Constructs
These squares are quite sturdy, and can be constructed to have a good number of round holes in the square interior. The constructs in the lower row enable one to firmly attach two beams at 90 degree angles to create cross shapes.

Square Meta-Parts

Intelligent Instruments

Intelligent Robotic Arm

The LEGO Mindstorm NXT robotics system is an excellent testbed for research in machine learning and artificial intelligence.  At Knuthlab Robotics at the University at Albany, we are developing intelligent instruments using LEGOs.

Our first instrument is a robotic arm that is designed to locate a characterize a white circle on a black background using the LEGO light sensor.  It relies on Bayesian inference, which is implemented using a technique called Nested Sampling, which was developed by John Skilling.  This software allows the robot to learn the characteristics of the circle using the light sensor data that it has collected.  The real advance here is the inquiry engine, which uses Bayesian adaptive exploration to decide which measurements to take next.  It does this by considering all the possible measurements that it could take, and computes the expected gain in information from each possible measurement.  It then chooses to take the measurement with the greatest expected information gain.  The process then repeats as the robot learns about the circle.

The system is easily generalized to solving other problems, such as exploring rooms, interpreting people’s emotions, and doing real science.

We recently presented our research at the MaxEnt 2007 workshop in Saratoga Springs NY.  Below are links to a video of the talk, my slides, and our research paper.

Video: Designing Intelligent Instruments, K.H. Knuth

Slides: Designing Intelligent Instruments, K.H. Knuth

Research Paper:
Knuth K.H., Erner P.M., Frasso S. 2007. Designing intelligent instruments. K.H. Knuth, A. Caticha, J.L. Center, A. Giffin, C.C. Rodriguez (eds.), Bayesian Inference and Maximum Entropy Methods in Science and Engineering, Saratoga Springs, NY, USA, 2007, AIP Conference Proceedings 954, American Institute of Physics, Melville NY, In press.

Meta-Parts: Part I

LEGO Technic Liftarms can be very useful for bracing structures. In these cases these L-shaped pieces are often used heavily. Many times, however, they are either the wrong size or shape for the job or you just don’t have enough pieces. One alternative is to create similar structures from smaller parts.

Complex structures are almost always constructed hierarchically. Small parts are combined to create more complex medium-sized parts. Medium-sized parts are combined to create even more complex larger parts. To help speed up the process, it often helps to have a library of small useful constructs.
Think of these as META-PARTS.

Here we present a library of constructs that can in many cases act as liftarms for bracing various structures. Note that these designs can easily pull apart when you apply forces in certain directions—usually within the plane of their design. They will not be stable for constructions requiring that they withstand forces in those directions. However, if you need to brace against forces that are directed out-of-plane, or to prevent torsion (twisting). These constructs may help. If you are desperate, and are willing to sacrifice purity, a drop of superglue will do wonders.

The Concepts
There are three L-shaped pieces that LEGO produces: 2 x 4 L-shaped Liftarm, 3 x 5 L-shaped Liftarm, and the 3 x 3 L-shaped Liftarm Thin. These are shown in the top row of the figure below.

Alternate Liftarms

One can construct pieces that act like the L-shaped liftarms, although they have only two holes. Two such constructs can be seen in the bottom row of the figure above. These pieces can easily come apart if pulled in the right direction, so some considerations must be made as to whether they are appropriate. They are also not quite as stable as the liftarms (although in desperate situations, where precision and permanence is required, some superglue would take care of both problems).

Below, is a library of LEGO Meta-Parts. Clearly, some will be more useful than others. This library is in no way exhaustive, as there are very many ways to combine parts. For an interesting discussion on the number of ways to combine 2 x 4 LEGO bricks consult:

“On the Entropy of LEGO (TM)” by Bergfinnur Durhuus and Soren Eilers, 2005, arXiv:math/054039v2″

L-Shaped Constructs
Here are five L-shaped constructs: 2 x 3 , 3 x 3 , and 4 x 4.
Note that the ends of the 4 x 4 L-shaped construct can be replaced by the Technic Connector with cross hole (the blue pieces elsewhere in this figure). These pieces can also be extended as long as you wish by adding the 180 degree Technic Angle Connector #2.

L-shaped Meta-Parts

T-Shaped Constructs
Here are five T-shaped constructs. Because the two on the top row (and the one on the bottom left) use an axle pin, they can twist, which may make them unsuitable for some applications. As you can see from the example on the bottom right, this is just the construct on the top left with the Technic Angle Connector #2 inserted.

T-shaped Meta-Parts

S, U, W -Shaped Constructs
Here is a set of constructs that are shaped like the letters S, U, and W. The ones with two pin Axle Joiners are typically a little more wobbly than the others.

S U W Shaped Constructs

The next installment will describe other meta-parts.

Content Protected Using Blog Protector By: PcDrome.