From 9a0d311f05ded2078d2a9c66cc0554cc11bcc4d6 Mon Sep 17 00:00:00 2001 From: Georgi Gerganov Date: Sun, 10 Jan 2021 15:32:29 +0200 Subject: [PATCH] Update README.md --- examples/ggwave-to-file/README.md | 36 +++++++++++++++++++++++++++++-- 1 file changed, 34 insertions(+), 2 deletions(-) diff --git a/examples/ggwave-to-file/README.md b/examples/ggwave-to-file/README.md index f8c2466..7c40e2c 100644 --- a/examples/ggwave-to-file/README.md +++ b/examples/ggwave-to-file/README.md @@ -2,9 +2,41 @@ Output a generated waveform to an uncompressed WAV file. -```bash -echo "Hello world!" | ./bin/ggwave-to-file > example.wav ``` +Usage: ./bin/ggwave-to-file [-vN] [-sN] [-pN] + -vN - output volume, N in (0, 100], (default: 50) + -sN - output sample rate, N in [1024, 48000], (default: 48000) + -pN - select the transmission protocol (default: 1) + + Available protocols: + 0 - Normal + 1 - Fast + 2 - Fastest + 3 - [U] Normal + 4 - [U] Fast + 5 - [U] Fastest +``` + +### Examples + +- Generate waveform with default parameters + + ```bash + echo "Hello world!" | ./bin/ggwave-to-file > example.wav + ``` + +- Generate waveform at 24 kHz sample rate + + ```bash + echo "Hello world!" | ./bin/ggwave-to-file -s24000 > example.wav + ``` + +- Generate ultrasound waveform using `[U] Fast` protocol + + ```bash + echo "Hello world!" | ./bin/ggwave-to-file -p4 > example.wav + ``` + ## HTTP service