That is the difference.... :-)
On the inject node the input field is read, and the \n is automatically escaped to be \\n internally... And that then appears as \n on the arduino... Doing it inside the function doesn't escape the \ so it then sends the "\n" character.
Good point...