Basic logic for connector choice added
Merge with local branch