Grasshopper advanced truss

You can also check out this thread, where scripting trusses is discussed at large.