Why
recorder.send('record')
instead of recorder.record()
As the latter allows better error control and also add something like record(60). Which would start a timer and stop after 60seconds.