The raspberry pi is not a real-time system, nor would the serial input automatically trigger an interrupt on the raspberry pi and the raspi digital input is unbuffered. Thus if the raspberry pi was too busy with all its multitasking it might miss the input from the bill acceptor and money would be accepted with nothing given in return. The arduino is there to provide buffered input. Right now it's not really doing that properly since it's just relaying immediately to the raspberry pi. What should happen is that it should buffer the input, then tell the raspberry pi and wait for an acknowledgement, buffering all input repeatedly telling the raspberry pi until acknowledgements are received. This also protects against raspberry pi crashes or crashes of the high level software running on it. Crashing the compiled program on the Atmega microcontroller on the other hand is much harder to do.