Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

7 Commits

Repository files navigation

MicroPython Morse Code

Blink an LED with morse coded message

The library contains a class called Morse, this class has 2 functions, flash() which flashes the the pin specified when initializing the class for a the period of time specified in the arguments of the function, and the second function, send() that takes in the message you want to flash as an argument and flashes it the pin specified when initializing the class.

Default values

FunctionValueValue 2
initpin = 25wpm = 15
flasht = 0.5
sendmsg = "SOS"

Example main.py

Blink the phrase 'Hello World!" in morse code

frommorsecodeimportMorsedefmain() ->None:
code=Morse(12, 20) # Initialize with pin 12 and 20 WPMcode.send("Hello World!") # Send the message "Hello World!" in Morse codeif__name__=="__main__":
main() # Run the main function

About

MicroPython Morse Code

Resources

Stars

10 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages