Starting code of message passing