Generalized modular architecture for robot structures