Modified comment (hint to threads)
Added more commands (currently broken)

Script is currently broken. The shell (/bin/sh) is waiting for more input when trying to define the sendrc() function.

Maybe defining a function in sh and bash is slightly different.