Turned connection process into function

Moved connection process at beginning into its own function. Added command to change 'yuchen' to 'yanchen'