Timer commands

Timer commands can stop, start and pause recording on a given condition.

The general syntax of the commands are

start [at | if | after | on] condition
stop [at | if | after | on] condition
pause [at | if | after | on] condition

The timer field can contain several commands and lines written in English. Press the [Save] button or CNTR + S keys to save the command text. Use the # character to comment out unused lines.

Conditions

Clock time:

This can stop or start the recording at given clock time. The time has format hh:mm:ss (hours:minutes:seconds) and you can either use the 24-hour clock or 12-hour notation with am or pm suffix (ending).

These two timer commands will start recording at 09:30 pm.
start at 09:30 pm
start at 21:30

These commands will stop recording at 9 o'clock in the morning.
stop at 09:00
stop at 09:00 am

The time is valid once a day. The command will fire again next day.

Note. Use the colon ":" to distinguish clock time (hh:mm::ss) from time period or duration.

Stop or pause recording on silence:

Use the silence word to stop or pause recording when there is no particular input on the line. You can also give the silence duration in minutes/seconds and signal level in decibel (dB) or percent (%). The default silence period is 7 seconds and the default level value is -24 dB (that is around 7%).

Notice: If you use the silence word to pause recording, the recording will automatically continue after the condition becomes false (untrue).

Some examples
stop if silence
stop if silence 5s
And
pause if silence 5s -24dB
pause if silence
In these two cases the recording will pause when the average signal level goes under -24dB (7%) for 5 seconds time. The recording will automatically resume when the signal level rises over -24dB (ca. over 7%).

Activate recording on sound or voice:

Use the sound, voice or audio words to start recording when the signal level rises over a given level. All these three words mean the same. As with the silence command, you can give the duration in seconds and signal levels in dB or %. The default duration is 7 seconds and the default level value is -24 dB (that is around 7%).

Examples
start if sound
start if sound 4s
start if voice 3 sec 10%
start if audio -20dB

Notice: If you use the sound (voice or audio) words to start recording, the recording will automatically pause temporarily when the signal level drops under the given level value.

File size:

Stop or pause recording after certain file size. The file size must be an integer or decimal number. The size unit can be bytes, kB, MB, GB or TB.

For example this will stop recording when the file size reaches 500 KB.
stop if 500 kB
pause if 0.5MB

This will stop recording after 2GB or 12:00 pm.
stop after 2 GB | 12 pm

Time period:

Stop, start or pause recording after given time period. The period or duration has syntax #h #m #s.

Eg. this command will stop recording after 1 hour 20 minutes and 15 seconds.
stop after 1h 20m 15s

This will start recording after 22 minutes.
start after 22min

And this will pause recording after 30 minutes or 20 MB.
pause after 30 minutes | 20 mb

You can abbreviate the word hour with h, minutes with m or min, and seconds with s or sec.

Combine several values in one command

You can add several conditions to one timer command. Separate the conditions with the | character. The values are then or'ed.

For example, this will stop recording after 20 minutes or when the file size exceeds 1GB or if there is no input (the line is empty, silent) in 5 seconds time.
stop after 20 min | 1GB | silence 5s

Another example.
start if sound 6% | 10:00 pm

Commenting out lines

Use the # character to comment out (deactivate) lines.
This command has no effect.
# stop after 800 MB | 20:00:00

Command line options related to the timer

You can study the audio level values by starting the program with --debug-signal=1 option. The program will then print various level values (signal values) in dB (decibel) and % format. Pay attension to the last "Avg.rms=" value. The timer will use it to trigger the commands.

This example will start the program from a command line. Start a terminal window from the desktop's main menu and type
audio-recorder --debug-signal=1
or
audio-recorder -d 1

Then activate the timer and study the "Avg.rms" value. It may help you to set correct level value for the silence and sound|voice|audio commands.

For other options, type
audio-recorder --help