Delux.Morse (delux v0.4.1)

Copy Markdown View Source

Functions for Morse code patterns

Summary

Functions

Convert a text string to Morse code

Types

options()

@type options() :: [words_per_minute: number(), loop?: boolean()]

Functions

encode(c, string, options \\ [])

@spec encode(Delux.RGB.color(), String.t(), options()) :: Delux.Program.t()

Convert a text string to Morse code

Programs created by this function require more precise timing than most effects. Linux's HZ configuration setting can limit timer precision for blinking LEDs to 10 ms (HZ=100). Please see the README.md for more information and how to configure Delux to partially compensate.

Options:

  • :words_per_minute - the rate at which to send the message
  • :loop? - set to true to repeat the message (defaults to false)