An integrated diagnostic architecture for autonomous robots