I've made a working script in AutoHotkey to toggle recording sound via fmedia.exe. After killing fmedia.exe and opening my recording in WaveLab, it says the wav header is invalid. This won't happen if I run fmedia in a console and exit with CTRL-C. (The same broken wav header occurs in ffmpeg, if I kill the process. However, if ffmpeg is quit by CTRL-C it says "Exiting normally, received signal 2", which seems like a good clue to my issue. Basically, I want my command to be run hidden (no console) and preferably I want to programmatically send fmedia a signal to stop what it's doing and exit, with a good interrupt signal like SIGINT.
Here's my draft AutoHotkey script that toggles recording to a date-formated file:
I've made a working script in AutoHotkey to toggle recording sound via
fmedia.exe
. After killingfmedia.exe
and opening my recording in WaveLab, it says the wav header is invalid. This won't happen if I run fmedia in a console and exit with CTRL-C. (The same broken wav header occurs in ffmpeg, if I kill the process. However, if ffmpeg is quit by CTRL-C it says "Exiting normally, received signal 2", which seems like a good clue to my issue. Basically, I want my command to be run hidden (no console) and preferably I want to programmatically send fmedia a signal to stop what it's doing and exit, with a good interrupt signal likeSIGINT
.Here's my draft AutoHotkey script that toggles recording to a date-formated file: