This package can be used to take a look at an animation setup for Blender Exporter for Trainz. Lattices will only recognized if they follow the b.r.* naming convention for bones. You find the root bone unanimated and unrotated in the point of origin. It's name doesn't matter, the root bone is always the single bone without a parent. The animation is driven only by the rotation of b.r.flywheel. Any other movement is either a parent-child relation(b.r.rotation as child of b.r.flywheel) or a set of constraints(AHelper copy the position of b.r.rotation and track to b.r.piston). For bones that are animated by constraints(for example b.r.conrod) you should choose the root bone as parent, because you need a parent and any parent movement might disturb the animation.
The Lattices "old method" and "new method" only visualize the difference in animation between !_steam_anim and !_steam_anim_2. The old method simply copy the translation of b.r.rotation along the Y-axis, while the new method take into account also the length of the conrod. It's still not perfect, as AHelper track always to the position b.r.piston has the frame before, but I think it's sufficient for Trainz. If somebody knows a method to avoid this missalignement, please leave a message at sourceforge :).