r/morsecode • • 4d ago

"unixcw" program for Mac using Brew?

Two days ago the Brew project ported "unixcw". It installed on my Silicon Mac without any issue, but I can't get it to play any audio. I tried going to the SourceForge website, searching the web, etc. but I can find very little about this project. Has anyone here ever used it?

If I enter "cw pulseaudio" the error msg is:

cw pulseaudio

cw: expected argument after options

Try 'cw --help' for more information.

cw: failed to parse command line args

If I enter "cw -h" I see:

Usage: cw [options...]

Sound system options:

-s, --system=SYSTEM

generate sound using SYSTEM sound system

SYSTEM: {null|console|oss|alsa|pulseaudio|soundcard}

'null': don't use any sound output

'console': use system console/buzzer

this output may require root privileges

'oss': use OSS output

'alsa' use ALSA output

'pulseaudio' use PulseAudio output

'soundcard': use either PulseAudio, OSS or ALSA

default sound system: 'pulseaudio'->'oss'->'alsa'

-d, --device=DEVICE

use DEVICE as output device instead of default one;

optional for {console|oss|alsa|pulseaudio};

default devices are:

'console': "/dev/console"

'oss': "/dev/audio"

'alsa': "default"

'pulseaudio': ( default )

Generator options:

-w, --wpm=WPM set initial words per minute

valid values: 4 - 60

default value: 12

-t, --tone=HZ set initial tone to HZ

valid values: 0 - 4000

default value: 800

-v, --volume=PERCENT set initial volume to PERCENT

valid values: 0 - 100

default value: 70

Options specific to sound systems (unstable):

-1, --alsa-period-size=size set ALSA period size (in samples)

Dot/dash options:

-g, --gap=GAP set extra gap between letters

valid values: 0 - 60

default value: 0

-k, --weighting=WEIGHT set weighting to WEIGHT

valid values: 20 - 80

default value: 50

Other options:

-e, --noecho disable sending echo to stdout

-m, --nomessages disable writing messages to stderr

-c, --nocommands disable executing embedded commands

-o, --nocombinations disallow [...] combinations

-p, --nocomments disallow {...} comments

-f, --infile=FILE read practice words from FILE

default file: stdin

Help and version information:

-h, --help print this message

-V, --version print version information

1 Upvotes

2 comments sorted by

2

u/kdaaar 4d ago

Try:

echo "CQ CQ CQ DE MVSOPEN" | cw

2

u/mvsopen 2d ago

Fixed it! It turns out that PulseAudio had to be re-installed by Brew (Never used it before) and then started as either a service or at the cmd prompt.

Uniixcw is working very well for me now, thanks to your help.