![]() |
3 months ago | |
---|---|---|
.vscode | 3 months ago | |
examples | 3 months ago | |
public | 3 months ago | |
src | 3 months ago | |
.gitignore | 3 months ago | |
LICENSE | 3 months ago | |
README.md | 3 months ago | |
index.html | 3 months ago | |
package.json | 3 months ago | |
tsconfig.json | 3 months ago | |
tsconfig.node.json | 3 months ago | |
vite.config.ts | 3 months ago | |
yarn.lock | 3 months ago |
README.md
Emergency Morse Translator
I dire times Scotty has to revert to ancient technology to make things work. Now that the universal translator subroutines are in maintenance, he quickly threw together a specialized translator subroutine to help with those strange messages encoded in strange, ancient ways.
Overview
This web application is written in Typescript, using Vue 3 and Vite. It comes with a recommended IDE setup, that I personally don't use, but I add it for completeness and all the VSCode fans out there: VSCode + Volar
I make heavy use of <script setup>
blocks and Vue's composition API. To learn more, check out the script setup docs and the Composition API overview.
Playing around
A live version is deployed on morse.k0r.in. There are example morse files in the examples directory. You can also find morse sounds on Wikipedia, try the original message or create your own messages with a tool like Stephan C. Phillips Morse Code Translator. In case you use a tool to generate your own morse sounds, please bear in mind that you should set tone frequency to something around 700Hz or above. This tool doesn't recognise lower frequencies very well.
How to run
To run everything locally you need Node 14+ and yarn or npm:
# inside repository root
yarn # or npm ci
yarn dev # or npm run dev
Acknowlegments
The wave form analysis wouldn't have been possible without the incredible morse-pro as a great example and learning resource.
The UI is highly inspired by StarTrek (duh). I found fantastic resources for the LCARS interface:
Hacking
On a high level:
You can find more detailed information about all the bits and pieces in the respective folders:
License
This web application is licensed under the permissive MIT license. See LICENSE.
Known Bugs and weaknesses
- When the "delete sample" button is used while a file is playing, it doesn't stop playing. Loading a new file in the meantime leads to unknown behaviour.
- Sounds below around 700Hz are not recognized well, if at all.
- A minor thing is that the translation code adds a word break at the end of any file, independent of the actual break. This is because the decoder doesn't know if the file is still playing and just waits for a long break to stop decoding.