added connect and send methods