introduce my_connected and connected() for checking if the bot is connected or not, also rename test to process and disconnect if a receive error happens