How to demodulate (audio) Morse code

I have a radio. This audio output goes to my computer. The sound output contains a Morse code or about 440 Hz. This Morse code can have a speed of 2 to 20 WPM . I understand how to find out if another station is transmitting, but how can I accept this transmitting / not transmitting state and turn it into text? I thought there might be a better solution than brute force.

Complicating factors:

  • I want the program to be able to figure out how fast another station is transmitting, and not it is specified by the user, as in most Morse code programs.
  • There is noise
  • Morse code transmitters do not turn on and off instantly. Rise and fall times are around 4 milliseconds.
  • Most of this Morse code is sent by humans and therefore is not perfect:
    • For example, a pause between words should consist of 7 elements, but it can be from 5 to 8.
    • The transmission rate of individuals can vary by approximately 20% per conversation.
  • I want to do this in more or less real time. This is normal if the program issues something, understands that this is a mistake, and corrects it.

Source

An example of the output of the program so far. It can enable audio in keyed / not keyed, but resolving this on a dot / dash does not work.

###########################################################__________________________ _________________________________#################################################### ##################################################################################### #######################################______________________________________________ _____________________________________________________________________________________ _____________________________________________________________________________________ _____________________________________________________________________________________ _____________________________________________________________________________________ _________________________ 

Any code / suggestions on a subject that defines transmission / non-transmission and / or a section that permits this to Morse code will be appreciated.

+4
source share
1 answer

The idea of ​​separating dash points and spaces from each other is to start collecting statistics at the beginning of the conversation and put all the "XXms of keyed" events into one array (or something else) and all "YY ms of not keyed "to another array (or something). Then you will ultimately have a histogram probability (t) for the key and the same as without the key. These histograms should have some maximums and minimums, visible both for a person and for some algorithm. This way you round the curves, dividing them at these minima to separate the points to the left of the dash to the right, the same as there can be more than one minimum with spaces. This approach really picks up a conversation, but does not require customization.

+1
source

Source: https://habr.com/ru/post/1415313/


All Articles