Calling functions through serial?

Aaronkoe --- Why are you creating a new buffer? Especially one that is not NULL terminated?
Just give atoi receivedChars.