$MORSE.REX: Difference between revisions

added comments concerning the use of the DELAY subroutine.
(Move to REXX library routines category)
(added comments concerning the use of the DELAY subroutine.)
Line 1:
The following is the   '''$MORSE.REX'''   (REXX) program.
 
<br>The help for the &nbsp; '''$MORSE.REX''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[$MORSE.HEL]].
<br><br>This program supports the ''International Morse code'' as well as the ''USA Morse code'' &nbsp; (the later being primarily used by the North American Railroads).
 
<br>Some translation is done for unsupported characters such as braces &nbsp; '''{''' &nbsp; '''}''', brackets &nbsp; '''[''' &nbsp; ''']''' &nbsp; and the like.
<br><br>This program supports the ''International Morse code'' as well as the ''USA Morse code'' &nbsp; (the later being primarily used by the North American Railroads).
<br>This REXX program normally shows Morse code words one word to a line before sounding.
 
<br><br>This REXX programs only works for Regina and PC/REXX, but other REXXes (specifically R4) will only display the Morse code, but not sound it.
<br><br>TheSome translation is done for unsupported characters such as braces &nbsp; '''$MORSE.REX{''' &nbsp; REXX'''}''', programbrackets makes&nbsp; use of'''[''' &nbsp; '''LINESIZE]''' &nbsp; REXX program (or BIF) which is used to determineand the screen width (orlike. linesize) of the terminal (console).
 
<br>The &nbsp; '''LINESIZE.REX''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[LINESIZE.REX]].
<br>This REXX program normally shows Morse code words one word to a line before sounding.
<br><br>The &nbsp; '''$MORSE.REX''' &nbsp; REXX program makes use of &nbsp; '''$T.REX''' &nbsp; REXX program which is used to display text and/or write the text to a file.
 
<br>The &nbsp; '''$T.REX''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[$T.REX]].
<br><br>This REXX programs only works for Regina and PC/REXX, but other REXXes (specifically R4) will only display the Morse code, but not sound it.
<br><br>The &nbsp; '''$MORSE.REX''' &nbsp; REXX program makes use of &nbsp; '''$ERR.REX''' &nbsp; REXX program which is used to display error messages (via &nbsp; '''$T.REX''').
 
<br>The &nbsp; '''$ERR.REX ''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[$ERR.REX]].
<br><br>The &nbsp; '''$MORSE.REX''' &nbsp; REXX program makes use of &nbsp; '''SOUND.REXLINESIZE''' &nbsp; REXX program (or BIF) which is used to expressdetermine soundthe screen width (viaor linesize) of the internalterminal speaker(console).
 
<br>The &nbsp; '''SOUND.REX''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[SOUND.REX]].
<br><br>Some older REXXes don't have aThe &nbsp; '''changestrLINESIZE.REX''' &nbsp; BIF, soREXX oneprogram is included here &nbsp; ──► &nbsp; [[CHANGESTRLINESIZE.REX]].
 
<br><br>The &nbsp; '''$MORSE.REX''' &nbsp; REXX program makes use of &nbsp; '''$T.REX''' &nbsp; REXX program which is used to display text and/or write the text to a file.
 
<br>The &nbsp; '''LINESIZE$T.REX''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[LINESIZE$T.REX]].
 
The &nbsp; '''$T.REX''' &nbsp; REXX program makes use of &nbsp; '''DELAY.REX''' &nbsp; REXX program which is used to delay (sleep) a specified amount time.
 
<br>The &nbsp; '''$ERRDELAY.REX ''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[$ERRDELAY.REX]].
 
<br><br>The &nbsp; '''$MORSE.REX''' &nbsp; REXX program makes use of &nbsp; '''$ERR.REX''' &nbsp; REXX program which is used to display error messages (via &nbsp; '''$T.REX''').
 
<br>The &nbsp; '''$TERR.REX ''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[$TERR.REX]].
 
The &nbsp; '''$MORSE.REX''' &nbsp; REXX program makes use of &nbsp; '''SOUND.REX''' &nbsp; REXX program which is used to express sound (via the internal speaker).
 
<br>The &nbsp; '''SOUND.REX''' &nbsp; REXX program is included here &nbsp; ──► &nbsp; [[SOUND.REX]].
 
Some older REXXes don't have a &nbsp; '''changestr''' &nbsp; BIF, so one is included here &nbsp; ──► &nbsp; [[CHANGESTR.REX]].
<lang rexx>/*REXX program sounds out (on the PC speaker) Morse code for (almost) any given text.*/
trace off /*suppress non-zero return code message*/