Merge branch 'svn' into HEAD

I fixed dealing with NULL positions in the drivetrain.