Ben's notes

Linux, Unix, network, radio...

User Tools

Site Tools


Practice Morse code words with Anki

This is an experiment in training Morse code using Anki, an open source flashcard app. Free for Windows, Linux, Mac and Web. This page is based on a Ubuntu 20 LTS install.

Quote from the Anki Documentation: There are two simple concepts behind Anki: ‘active recall testing’ and ‘spaced repetition’. They are not known to most learners, despite having been written about in the scientific literature for many years. Understanding how they work will make you a more effective learner.

If you are interested in the science behind this, I really recommend the book: 'Make It Stick'.

Try it

Here you can download Anki Deck exports to try it out yourself.


  • Install Anki using the package manager, or download latest binary from the Anki website.
    # via package manager:
    sudo apt install anki
    # via download from website:
    sudo apt install mplayer
    tar xf anki-2.1.38-linux.tar.bz2
    cd anki-2.1.38-linux
    sudo ./
  • Start Anki and create a new Deck.

Generate Morse audio files

  • Example script:
    set -e
    # Needs ebook2cw; sudo apt install ebook2cw
    # One word per line in a file.
    # Output directory
    # File that you can import with Anki
    echo "# import this file with Anki" > "${anki_export}"
    if [[ ! -d "${output_dir}" ]]; then
    	mkdir "${output_dir}"
    cat "${words}" | while read word
    	# generate morse audio files
    	echo "${word}" | ebook2cw -w 25 -f 600 -a CALLSIGN -t "${word}" -y 2021 -o "${output_dir}/${word}"
    	# generate Anki export
    	echo "[sound:${word}0000.mp3]; ${word}" >> "${anki_export}"
    	echo "${word}"
  • Copy all output/*.mp3 files to your directory. You can find that directory with:
    find ~ -type d -name ""
  • For other OS's find the subdirectory below:
    Windows: %APPDATA%\Anki2
    Mac: ~/Library/Application Support/Anki2

Import cards

  • Open you new Morse Deck.
  • Go to File→Import…
  • Select output/anki.txt
  • Click Import button.


  • You can click 'Study Now' to start studying. You can also change the schedule, study more cards, randomize etc. Read the Anki Documentation here:
  • Keyboard Shortcuts (mouse over buttons for most shortcuts). From the manual: When studying, either space or enter will show the answer. When the answer is shown, you can use space or enter to select the Good button. You can use the 1-4 keys to select a specific ease button. Many people find it convenient to answer most cards with space and keep one finger on 1 for when they forget.
  • r repeat audio.
anki_morse_code.txt · Last modified: 2021/01/13 06:20 by admin