-
Notifications
You must be signed in to change notification settings - Fork 1.6k
docs/applications/{morsey, txmorse}: Add documentation for Morse code features #19493
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
linguini1
wants to merge
4
commits into
apache:master
Choose a base branch
from
linguini1:morsey
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+152
−0
Open
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
f132c74
docs/applications/audioutils: Document Morsey library
linguini1 de1d92f
docs/applications/txmorse: Document the txmorse application
linguini1 6dbb6ab
boards/sim: Add configuration for Morse code example
linguini1 df59801
docs/sim: Document txmorse configuration
linguini1 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| ========================= | ||
| ``morsey`` Morsey library | ||
| ========================= | ||
|
|
||
| ``morsey`` is a simple library for parsing ASCII text into Morse code marks, and | ||
| playing Morse using a user-defined interface. | ||
|
|
||
| To use the ``morsey`` library, include it like so: | ||
|
|
||
| .. code:: c | ||
|
|
||
| #include <audioutils/morsey.h> | ||
|
|
||
| See the `Morsey repository <https://github.com/linguini1/morsey>`_ for | ||
| documentation on how to use the library. Note that there is also an included | ||
| ``example.c`` file where Morse code is printed to the console. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| ================================== | ||
| ``txmorse`` Morse code transmitter | ||
| ================================== | ||
|
|
||
| This application is an example which transmits Morse code messages using the | ||
| :doc:`Morsey library </applications/audioutils/morsey/index>`. | ||
|
|
||
| You can run ``txmorse -h`` to display help information. | ||
|
|
||
| Supported Devices | ||
| ----------------- | ||
|
|
||
| .. note:: | ||
|
|
||
| This application does not currently support all possible Morse code | ||
| transmission devices available on NuttX NuttX. Currently, only GPIO devices | ||
| are supported. | ||
|
|
||
| In order to add support for a new output device, you must submit a patch | ||
| modifying the program to define the interface for the Morsey library for each | ||
| type of output device. Take a look at the current application code to see | ||
| examples for console devices and GPIO devices. | ||
|
|
||
| The ``txfunc`` function is used by the ``morsey`` library to transmit a mark. | ||
| You can implement the appropriate driver operations (i.e. ``ioctl`` calls) in | ||
| this function. See the GPIO implementation for an example. | ||
|
|
||
| The ``cleanupfunc`` function is used to cleanup the implementation. For most | ||
| NuttX devices, this involves closing the file descriptor. | ||
|
|
||
| In the ``main`` function, the path to the output device is used to identify the | ||
| implementation to use. For instance, GPIO devices are under ``/dev/gpio<n>``, so | ||
| device paths containing "gpio" cause the GPIO driver to be selected. If no | ||
| player can be associated with the device, the default player is selected which | ||
| just prints the Morse code to the console. | ||
|
|
||
| Usage | ||
| ----- | ||
|
|
||
| The following will output "SOS" over a GPIO device (i.e. buzzer or LED): | ||
|
|
||
| .. code:: console | ||
|
|
||
| nsh> txmorse "sos" /dev/gpio0 | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,79 @@ | ||
| # | ||
| # This file is autogenerated: PLEASE DO NOT EDIT IT. | ||
| # | ||
| # You can use "make menuconfig" to make any modifications to the installed .config file. | ||
| # You can then do "make savedefconfig" to generate a new defconfig file that includes your | ||
| # modifications. | ||
| # | ||
| # CONFIG_NSH_CMDOPT_HEXDUMP is not set | ||
| CONFIG_ARCH="sim" | ||
| CONFIG_ARCH_BOARD="sim" | ||
| CONFIG_ARCH_BOARD_SIM=y | ||
| CONFIG_ARCH_CHIP="sim" | ||
| CONFIG_ARCH_SIM=y | ||
| CONFIG_AUDIOUTILS_MORSEY=y | ||
| CONFIG_BOARDCTL_APP_SYMTAB=y | ||
| CONFIG_BOARDCTL_POWEROFF=y | ||
| CONFIG_BOARD_LOOPSPERMSEC=0 | ||
| CONFIG_BOOT_RUNFROMEXTSRAM=y | ||
| CONFIG_BUILTIN=y | ||
| CONFIG_COVERAGE_ALL=y | ||
| CONFIG_COVERAGE_TOOLCHAIN=y | ||
| CONFIG_DEBUG_ASSERTIONS=y | ||
| CONFIG_DEBUG_ASSERTIONS_EXPRESSION=y | ||
| CONFIG_DEBUG_FEATURES=y | ||
| CONFIG_DEBUG_SYMBOLS=y | ||
| CONFIG_DEV_GPIO=y | ||
| CONFIG_DEV_LOOP=y | ||
| CONFIG_ETC_FATDEVNO=2 | ||
| CONFIG_ETC_ROMFS=y | ||
| CONFIG_ETC_ROMFSDEVNO=1 | ||
| CONFIG_EXAMPLES_GPIO=y | ||
| CONFIG_EXAMPLES_HELLO=y | ||
| CONFIG_EXAMPLES_TXMORSE=y | ||
| CONFIG_FAT_LCNAMES=y | ||
| CONFIG_FAT_LFN=y | ||
| CONFIG_FS_BINFS=y | ||
| CONFIG_FS_FAT=y | ||
| CONFIG_FS_HOSTFS=y | ||
| CONFIG_FS_PROCFS=y | ||
| CONFIG_FS_RAMMAP=y | ||
| CONFIG_FS_ROMFS=y | ||
| CONFIG_GPIO_LOWER_HALF=y | ||
| CONFIG_HAVE_CXXINITIALIZE=y | ||
| CONFIG_IDLETHREAD_STACKSIZE=4096 | ||
| CONFIG_INIT_ENTRYPOINT="nsh_main" | ||
| CONFIG_IOEXPANDER=y | ||
| CONFIG_IOEXPANDER_DUMMY=y | ||
| CONFIG_LIBC_ENVPATH=y | ||
| CONFIG_LIBC_EXECFUNCS=y | ||
| CONFIG_LIBC_LOCALE=y | ||
| CONFIG_LIBC_LOCALE_CATALOG=y | ||
| CONFIG_LIBC_LOCALE_GETTEXT=y | ||
| CONFIG_LIBC_MAX_EXITFUNS=1 | ||
| CONFIG_LIBC_NUMBERED_ARGS=y | ||
| CONFIG_NDEBUG=y | ||
| CONFIG_NSH_BUILTIN_APPS=y | ||
| CONFIG_NSH_FILE_APPS=y | ||
| CONFIG_NSH_READLINE=y | ||
| CONFIG_PATH_INITIAL="/bin" | ||
| CONFIG_PIPES=y | ||
| CONFIG_PSEUDOFS_ATTRIBUTES=y | ||
| CONFIG_PSEUDOFS_FILE=y | ||
| CONFIG_PSEUDOFS_SOFTLINKS=y | ||
| CONFIG_READLINE_TABCOMPLETION=y | ||
| CONFIG_RTC=y | ||
| CONFIG_RTC_ARCH=y | ||
| CONFIG_RTC_DRIVER=y | ||
| CONFIG_SCHED_BACKTRACE=y | ||
| CONFIG_SCHED_EVENTS=y | ||
| CONFIG_SCHED_HAVE_PARENT=y | ||
| CONFIG_SCHED_WAITPID=y | ||
| CONFIG_SIM_HOSTFS=y | ||
| CONFIG_SIM_WALLTIME_SIGNAL=y | ||
| CONFIG_START_MONTH=6 | ||
| CONFIG_START_YEAR=2008 | ||
| CONFIG_SYSTEM_DUMPSTACK=y | ||
| CONFIG_SYSTEM_GCOV=y | ||
| CONFIG_SYSTEM_NSH=y | ||
| CONFIG_TESTING_OSTEST=y |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.