0

I'd like to know if it's possible to run rtl_fm from a .sh file: I know it's possible, but what I'd like to do is to run it, record for 5 seconds (I can place a sleep here) and stop the process (in the terminal, you need to do Crtl+C to do this). Or maybe there is an option to run it for a specific time? If it's not possible through a .sh script, maybe I could do it through a Python script, but still I'd need some help on this. Thanks!

2
  • I have no idea what you are trying to do, but I'm sure it's possible. Apr 17, 2018 at 16:58
  • see the answer below
    – itd
    Apr 18, 2018 at 7:17

1 Answer 1

0

Use rtl_fm “$@“ & sleep 5 ; pkill rtl_fm ; do_other_things. Here “$@“ are the arguments passed to your script, replace it with those.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.