This is the code which is implemented in the Arduino board for sending digital signals to the unity applications.