From 6bfd22811c329539111ed72bafc1d18514af8a74 Mon Sep 17 00:00:00 2001
From: Daniele Forsi <iu5hkx@gmail.com>
Date: Sun, 19 Sep 2021 20:51:18 +0200
Subject: [PATCH 1/3] Fix errors in comments

Errors found with codespell.
---
 CMakeLists.txt                |  2 +-
 conf/99-direwolf-cmedia.rules |  2 +-
 external/geotranz/mgrs.h      |  2 +-
 src/agwlib.c                  | 10 +++++-----
 src/ais.c                     |  4 ++--
 src/aprs_tt.c                 | 18 +++++++++---------
 src/aprs_tt.h                 |  2 +-
 src/atest.c                   |  4 ++--
 src/audio.c                   |  4 ++--
 src/audio.h                   |  8 ++++----
 src/audio_portaudio.c         |  4 ++--
 src/audio_win.c               |  4 ++--
 src/ax25_link.c               | 36 +++++++++++++++++------------------
 src/ax25_pad.c                |  4 ++--
 src/ax25_pad.h                |  4 ++--
 src/ax25_pad2.c               |  2 +-
 src/cdigipeater.c             |  4 ++--
 src/cm108.c                   |  6 +++---
 src/config.c                  | 20 +++++++++----------
 src/decode_aprs.c             | 28 +++++++++++++--------------
 src/demod.c                   |  8 ++++----
 src/demod_9600.c              |  4 ++--
 src/demod_afsk.c              |  8 ++++----
 src/demod_psk.c               |  4 ++--
 src/digipeater.c              |  2 +-
 src/direwolf.c                |  2 +-
 src/direwolf.h                |  2 +-
 src/dlq.c                     |  2 +-
 src/dtmf.c                    |  2 +-
 src/dwgps.c                   |  2 +-
 src/dwgpsd.c                  |  4 ++--
 src/dwgpsnmea.c               |  4 ++--
 src/encode_aprs.c             | 10 +++++-----
 src/fx25_rec.c                |  2 +-
 src/hdlc_rec.c                |  4 ++--
 src/hdlc_rec2.c               |  2 +-
 src/igate.c                   |  2 +-
 src/kiss.c                    |  4 ++--
 src/kiss_frame.c              |  2 +-
 src/kiss_frame.h              |  2 +-
 src/kissnet.c                 |  2 +-
 src/kissserial.c              |  4 ++--
 src/multi_modem.c             |  2 +-
 src/pfilter.c                 | 10 +++++-----
 src/ptt.c                     |  4 ++--
 src/recv.c                    |  2 +-
 src/server.c                  |  6 +++---
 src/telemetry.c               |  8 ++++----
 src/textcolor.c               |  2 +-
 src/tt_text.c                 |  2 +-
 src/tt_user.c                 | 10 +++++-----
 src/xid.c                     |  2 +-
 src/xmit.c                    |  4 ++--
 test/CMakeLists.txt           |  2 +-
 54 files changed, 150 insertions(+), 150 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 9e710f52..3338ac8f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -131,7 +131,7 @@ endif()
 # auto include current directory
 set(CMAKE_INCLUDE_CURRENT_DIR ON)
 
-# set OS dependant variables
+# set OS dependent variables
 if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
   set(LINUX TRUE)
 
diff --git a/conf/99-direwolf-cmedia.rules b/conf/99-direwolf-cmedia.rules
index 587f6168..24e7c160 100644
--- a/conf/99-direwolf-cmedia.rules
+++ b/conf/99-direwolf-cmedia.rules
@@ -3,7 +3,7 @@
 #	$ ls -l /dev/hidraw*
 #	crw------- 1 root root 247, 0 Sep 24 09:40 /dev/hidraw0
 #
-# An ordinary user, trying to acccess it will be denied.
+# An ordinary user, trying to access it will be denied.
 #
 # Unnecessarily running applications as root is generally a bad idea because it makes it too easy
 # to accidentally trash your system.  We need to relax the restrictions so ordinary users can use these devices.
diff --git a/external/geotranz/mgrs.h b/external/geotranz/mgrs.h
index 79a1c28e..bd0453a1 100644
--- a/external/geotranz/mgrs.h
+++ b/external/geotranz/mgrs.h
@@ -236,7 +236,7 @@ extern "C" {
  *  The function Convert_MGRS_To_UPS converts an MGRS coordinate string
  *  to UPS (hemisphere, easting, and northing) coordinates, according 
  *  to the current ellipsoid parameters. If any errors occur, the error 
- *  code(s) are returned by the function, otherwide UPS_NO_ERROR is returned.
+ *  code(s) are returned by the function, otherwise UPS_NO_ERROR is returned.
  *
  *    MGRS          : MGRS coordinate string           (input)
  *    Hemisphere    : Hemisphere either 'N' or 'S'     (output)
diff --git a/src/agwlib.c b/src/agwlib.c
index 09881097..337c85b6 100644
--- a/src/agwlib.c
+++ b/src/agwlib.c
@@ -600,7 +600,7 @@ int agwlib_G_ask_port_information (void)
  * Returns:	Number of bytes sent for success, -1 for error.
  *
  * Description:	This only starts the sequence and does not wait.
- *		Success or failue will be indicated sometime later by ?
+ *		Success or failure will be indicated sometime later by ?
  *
  *--------------------------------------------------------------------*/
 
@@ -635,7 +635,7 @@ int agwlib_C_connect (int chan, char *call_from, char *call_to)
  * Returns:	Number of bytes sent for success, -1 for error.
  *
  * Description:	This only starts the sequence and does not wait.
- *		Success or failue will be indicated sometime later by ?
+ *		Success or failure will be indicated sometime later by ?
  *
  *--------------------------------------------------------------------*/
 
@@ -722,13 +722,13 @@ int agwlib_D_send_connected_data (int chan, int pid, char *call_from, char *call
  *		hand we don't want to get TOO far ahead when transferring a large file.
  *
  *		Before disconnecting from another station, it would be good to know
- *		that it actually recevied the last message we sent.  For this reason,
+ *		that it actually received the last message we sent.  For this reason,
  *		I think it would be good for this to include frames that were 
- *		transmitted but not yet acknowleged.  (Even if it was transmitted once,
+ *		transmitted but not yet acknowledged.  (Even if it was transmitted once,
  *		it could still be transmitted again, if lost, so you could say it is
  *		still waiting for transmission.)
  *
- *		See server.c for a more precise definition of exacly how this is defined.
+ *		See server.c for a more precise definition of exactly how this is defined.
  *
  *--------------------------------------------------------------------*/
 
diff --git a/src/ais.c b/src/ais.c
index cadf6482..938fa012 100644
--- a/src/ais.c
+++ b/src/ais.c
@@ -338,7 +338,7 @@ void ais_to_nmea (unsigned char *ais, int ais_len, char *nmea, int nmea_size)
  *
  * Name:        ais_parse
  *
- * Purpose:    	Parse AIS sentence and extract interesing parts.
+ * Purpose:    	Parse AIS sentence and extract interesting parts.
  *
  * Inputs:	sentence	NMEA sentence.
  *
@@ -594,7 +594,7 @@ int ais_parse (char *sentence, int quiet, char *descr, int descr_size, char *mss
  *
  * Returns:	-1		Invalid message type.
  *		0		Good length.
- *		1		Unexpected lenth.
+ *		1		Unexpected length.
  *
  *--------------------------------------------------------------------*/
 
diff --git a/src/aprs_tt.c b/src/aprs_tt.c
index 0543f8a7..cc1917e3 100644
--- a/src/aprs_tt.c
+++ b/src/aprs_tt.c
@@ -208,7 +208,7 @@ void aprs_tt_init (struct tt_config_s *p)
  *		The complete message is then processed.
  *		The touch tone decoder sends $ if no activity
  *		for some amount of time, perhaps 5 seconds.
- *		A partially accumulated messge is discarded if
+ *		A partially accumulated message is discarded if
  *		there is a long gap.
  *
  *		'.' means no activity during processing period.
@@ -574,7 +574,7 @@ static int parse_fields (char *msg)
  * Purpose:     Expand compact form "macro" to full format then process.
  *
  * Inputs:      e		- An "entry" extracted from a complete
- *				  APRStt messsage.
+ *				  APRStt message.
  *				  In this case, it should contain only digits.
  *
  * Returns:	0 for success or one of the TT_ERROR_... codes.
@@ -689,7 +689,7 @@ static int expand_macro (char *e)
  * Purpose:     Extract traditional format callsign or object name from touch tone sequence.
  *
  * Inputs:      e		- An "entry" extracted from a complete
- *				  APRStt messsage.
+ *				  APRStt message.
  *				  In this case, it should start with "A".
  *
  * Outputs:	m_callsign
@@ -845,7 +845,7 @@ static int parse_callsign (char *e)
  * Purpose:     Extract object name from touch tone sequence.
  *
  * Inputs:      e		- An "entry" extracted from a complete
- *				  APRStt messsage.
+ *				  APRStt message.
  *				  In this case, it should start with "AA".
  *
  * Outputs:	m_callsign
@@ -901,7 +901,7 @@ static int parse_object_name (char *e)
  * Purpose:     Extract symbol from touch tone sequence.
  *
  * Inputs:      e		- An "entry" extracted from a complete
- *				  APRStt messsage.
+ *				  APRStt message.
  *				  In this case, it should start with "AB".
  *
  * Outputs:	m_symtab_or_overlay
@@ -995,7 +995,7 @@ static int parse_symbol (char *e)
  * Purpose:     Extract QIKcom-2 / APRStt 3 ten digit call or five digit suffix.
  *
  * Inputs:      e		- An "entry" extracted from a complete
- *				  APRStt messsage.
+ *				  APRStt message.
  *				  In this case, it should start with "AC".
  *
  * Outputs:	m_callsign
@@ -1073,7 +1073,7 @@ static int parse_aprstt3_call (char *e)
  * Purpose:     Extract location from touch tone sequence.
  *
  * Inputs:      e		- An "entry" extracted from a complete
- *				  APRStt messsage.
+ *				  APRStt message.
  *				  In this case, it should start with "B".
  *
  * Outputs:	m_latitude
@@ -1415,7 +1415,7 @@ static int parse_location (char *e)
  *		defined in the configuration file.
  *
  * Inputs:      e		- An "entry" extracted from a complete
- *				  APRStt messsage.
+ *				  APRStt message.
  *				  In this case, it should start with "B".
  *
  *		valstrsize	- size of the outputs so we can check for buffer overflow.
@@ -1566,7 +1566,7 @@ static int find_ttloc_match (char *e, char *xstr, char *ystr, char *zstr, char *
  * Purpose:     Extract comment / status or other special information from touch tone message. 
  *
  * Inputs:      e		- An "entry" extracted from a complete
- *				  APRStt messsage.
+ *				  APRStt message.
  *				  In this case, it should start with "C".
  *
  * Outputs:	m_comment
diff --git a/src/aprs_tt.h b/src/aprs_tt.h
index 8cc845d8..656d2732 100644
--- a/src/aprs_tt.h
+++ b/src/aprs_tt.h
@@ -123,7 +123,7 @@ struct tt_config_s {
 	int obj_recv_chan;		/* Channel to listen for tones. */
 
 	int obj_xmit_chan;		/* Channel to transmit object report. */
-					/* -1 for none.  This could happpen if we */
+					/* -1 for none.  This could happen if we */
 					/* are only sending to application */
 					/* and/or IGate. */
 
diff --git a/src/atest.c b/src/atest.c
index 5c197759..b7068cd8 100644
--- a/src/atest.c
+++ b/src/atest.c
@@ -25,10 +25,10 @@
  *
  * Purpose:     Test fixture for the AFSK demodulator.
  *
- * Inputs:	Takes audio from a .WAV file insted of the audio device.
+ * Inputs:	Takes audio from a .WAV file instead of the audio device.
  *
  * Description:	This can be used to test the AFSK demodulator under
- *		controlled and reproducable conditions for tweaking.
+ *		controlled and reproducible conditions for tweaking.
  *	
  *		For example
  *
diff --git a/src/audio.c b/src/audio.c
index 613be06d..3db8f5c8 100644
--- a/src/audio.c
+++ b/src/audio.c
@@ -201,7 +201,7 @@ static int calcbufsize(int rate, int chans, int bits)
  *				more restrictive in its capabilities.
  *				It might say, the best I can do is mono, 8 bit, 8000/sec.
  *
- *				The sofware modem must use this ACTUAL information
+ *				The software modem must use this ACTUAL information
  *				that the device is supplying, that could be different
  *				than what the user specified.
  *              
@@ -769,7 +769,7 @@ static int set_oss_params (int a, int fd, struct audio_s *pa)
  * This was long ago under different conditions.
  * Should study this again some day.
  *
- * Your milage may vary.
+ * Your mileage may vary.
  */
 	err = ioctl (fd, SNDCTL_DSP_GETBLKSIZE, &ossbuf_size_in_bytes);
    	if (err == -1) {
diff --git a/src/audio.h b/src/audio.h
index 61dec9d9..baa1eccc 100644
--- a/src/audio.h
+++ b/src/audio.h
@@ -158,7 +158,7 @@ struct audio_s {
 
 	    enum v26_e { V26_UNSPECIFIED=0, V26_A, V26_B } v26_alternative;
 
-					// Original implementaion used alternative A for 2400 bbps PSK.
+					// Original implementation used alternative A for 2400 bbps PSK.
 					// Years later, we discover that MFJ-2400 used alternative B.
 					// It's likely the others did too.  it also works a little better.
 					// Default to MFJ compatible and print warning if user did not
@@ -261,7 +261,7 @@ struct audio_s {
 #define MAX_GPIO_NAME_LEN 20	// 12 would cover any case I've seen so this should be safe
 
 		char out_gpio_name[MAX_GPIO_NAME_LEN];
-					/* orginally, gpio number NN was assumed to simply */
+					/* originally, gpio number NN was assumed to simply */
 					/* have the name gpioNN but this turned out not to be */
 					/* the case for CubieBoard where it was longer. */
 					/* This is filled in by ptt_init so we don't have to */
@@ -298,7 +298,7 @@ struct audio_s {
 		int in_gpio_num;	/* GPIO number */
 
 		char in_gpio_name[MAX_GPIO_NAME_LEN];
-					/* orginally, gpio number NN was assumed to simply */
+					/* originally, gpio number NN was assumed to simply */
 					/* have the name gpioNN but this turned out not to be */
 					/* the case for CubieBoard where it was longer. */
 					/* This is filled in by ptt_init so we don't have to */
@@ -312,7 +312,7 @@ struct audio_s {
 	    int dwait;			/* First wait extra time for receiver squelch. */
 					/* Default 0 units of 10 mS each . */
 
-	    int slottime;		/* Slot time in 10 mS units for persistance algorithm. */
+	    int slottime;		/* Slot time in 10 mS units for persistence algorithm. */
 					/* Typical value is 10 meaning 100 milliseconds. */
 
 	    int persist;		/* Sets probability for transmitting after each */
diff --git a/src/audio_portaudio.c b/src/audio_portaudio.c
index 6d53f6af..77c4ee35 100644
--- a/src/audio_portaudio.c
+++ b/src/audio_portaudio.c
@@ -156,7 +156,7 @@ static int calcbufsize(int rate, int chans, int bits)
  * the same device name for more then one connected device
  * (ie two SignaLinks). Appending a Portaudio device index to the
  * the device name ensure we can find the correct one. And if it's not
- * available return the first occurence that matches the device name.
+ * available return the first occurrence that matches the device name.
  *----------------------------------------------------------------*/
 static int searchPADevice(struct adev_s *dev, char *_devName, int reqDeviceNo, int io_flag)
 {
@@ -513,7 +513,7 @@ static int paOutput16CB( const void *inputBuffer, void *outputBuffer,
  *				more restrictive in its capabilities.
  *				It might say, the best I can do is mono, 8 bit, 8000/sec.
  *
- *				The sofware modem must use this ACTUAL information
+ *				The software modem must use this ACTUAL information
  *				that the device is supplying, that could be different
  *				than what the user specified.
  *
diff --git a/src/audio_win.c b/src/audio_win.c
index 2183d107..a6035b5b 100644
--- a/src/audio_win.c
+++ b/src/audio_win.c
@@ -209,7 +209,7 @@ static struct adev_s {
  *				more restrictive in its capabilities.
  *				It might say, the best I can do is mono, 8 bit, 8000/sec.
  *
- *				The sofware modem must use this ACTUAL information
+ *				The software modem must use this ACTUAL information
  *				that the device is supplying, that could be different
  *				than what the user specified.
  * 
@@ -921,7 +921,7 @@ int audio_get (int a)
  *		c	- One byte in range of 0 - 255.
  *
  *
- * Global In:	out_current	- index of output buffer currenly being filled.
+ * Global In:	out_current	- index of output buffer currently being filled.
  *
  * Returns:     Normally non-negative.
  *              -1 for any type of error.
diff --git a/src/ax25_link.c b/src/ax25_link.c
index 041066e1..c39f5ab4 100644
--- a/src/ax25_link.c
+++ b/src/ax25_link.c
@@ -255,7 +255,7 @@ typedef struct ax25_dlsm_s {
 						// addrs[OWNCALL] is owncall for this end of link.
 						// Note that we are acting on behalf of
 						// a client application so the APRS mycall
-						// might not be relevent.
+						// might not be relevant.
 
 #define PEERCALL AX25_DESTINATION
 						// addrs[PEERCALL] is call for other end.
@@ -319,8 +319,8 @@ typedef struct ax25_dlsm_s {
 
 	int reject_exception;			// A REJ frame has been sent to the remote station. (boolean)
 
-						// This is used only when receving an I frame, in states 3 & 4, SREJ not enabled.
-						// When an I frame has an unepected N(S),
+						// This is used only when receiving an I frame, in states 3 & 4, SREJ not enabled.
+						// When an I frame has an unexpected N(S),
 						//   - if not already set, set it and send REJ.
 						// When an I frame with expected N(S) is received, clear it.
 						// This would prevent us from sending additional REJ while
@@ -1157,7 +1157,7 @@ void dl_disconnect_request (dlq_item_t *E)
  *
  * Erratum:	Not sure how to interpret that.  See example below for how it was implemented.
  *
- * Version 1.6:	Bug 252.  Segmentation was occuring for a V2.0 link.  From the spec:
+ * Version 1.6:	Bug 252.  Segmentation was occurring for a V2.0 link.  From the spec:
  *			"The receipt of an XID response from the other station establishes that both
  *			stations are using AX.25 version 2.2 or higher and enables the use of the
  *			segmenter/reassembler and selective reject."
@@ -1564,7 +1564,7 @@ void dl_unregister_callsign (dlq_item_t *E)
  *
  * Description:	This is the sum of:
  *		- Incoming connected data, from application still in the queue.
- *		- I frames which have been transmitted but not yet acknowleged.
+ *		- I frames which have been transmitted but not yet acknowledged.
  *
  *------------------------------------------------------------------------------*/
 
@@ -1633,7 +1633,7 @@ void dl_outstanding_frames_request (dlq_item_t *E)
  * Description:	By client application we mean something that attached with the 
  *		AGW network protocol.
  *
- *		Clean out anything related to the specfied client application.
+ *		Clean out anything related to the specified client application.
  *		This would include state machines and registered callsigns.
  *	
  *------------------------------------------------------------------------------*/
@@ -2201,7 +2201,7 @@ void lm_data_indication (dlq_item_t *E)
 	    break;
 
 // Erratum: The AX.25 spec is not clear about whether SREJ should be command, response, or both.
-// The underlying X.25 spec clearly says it is reponse only.  Let's go with that.
+// The underlying X.25 spec clearly says it is response only.  Let's go with that.
 
 	  case frame_type_S_SREJ:
 	  case frame_type_U_DM:
@@ -2224,7 +2224,7 @@ void lm_data_indication (dlq_item_t *E)
 	  case frame_type_U_UI:
 	    // Don't test at this point in case an APRS frame gets thru.
 	    // APRS doesn't specify what to put in the Source and Dest C bits.
-	    // In practice we see all 4 possble combinations.
+	    // In practice we see all 4 possible combinations.
 	    // I have an opinion about what would be "correct" (discussed elsewhere)
 	    // but in practice no one seems to care.
 	    break;
@@ -2701,7 +2701,7 @@ static void i_frame_continued (ax25_dlsm_t *S, int p, int ns, int pid, char *inf
 
 	  if (S->rxdata_by_ns[ns] != NULL) {
 	    // There is a possibility that we might have another received frame stashed
-	    // away from 8 or 128 (modulo) frames back.  Remove it so it doesn't accidently
+	    // away from 8 or 128 (modulo) frames back.  Remove it so it doesn't accidentally
 	    // show up at some future inopportune time.
 
 	    cdata_delete (S->rxdata_by_ns[ns]);
@@ -2786,7 +2786,7 @@ static void i_frame_continued (ax25_dlsm_t *S, int p, int ns, int pid, char *inf
 // we discard 3,4,5,6, and tell the other end to resend everything starting with 2.
 
 // At one time, I had some doubts about when to use command or response for REJ.
-// I now believe that reponse, as implied by setting F in the flow chart, is correct.
+// I now believe that response, as implied by setting F in the flow chart, is correct.
 
 	  int f = p;
 	  int nr = S->vr;		// Next expected sequence number.
@@ -2796,7 +2796,7 @@ static void i_frame_continued (ax25_dlsm_t *S, int p, int ns, int pid, char *inf
 	  S->reject_exception = 1;
 
 	  if (s_debug_retry) {
-	      text_color_set(DW_COLOR_ERROR);	// make it more noticable.
+	      text_color_set(DW_COLOR_ERROR);	// make it more noticeable.
 	      dw_printf ("sending REJ, at %s %d, SREJ not enabled case, V(R)=%d", __func__, __LINE__, S->vr);
 	  }
 
@@ -2860,7 +2860,7 @@ static void i_frame_continued (ax25_dlsm_t *S, int p, int ns, int pid, char *inf
 // In version 1.4:
 // We end up sending more SREJ than necessary and and get back redundant information.  Example:
 // When we see 113 missing, we ask for a resend.
-// When we see 115 & 116 missing, a cummulative SREJ asks for everything.
+// When we see 115 & 116 missing, a cumulative SREJ asks for everything.
 // The other end dutifully sends 113 twice.
 //
 // [0.4] DW1>DW0:(SREJ res, n(r)=113, f=0)
@@ -2890,7 +2890,7 @@ static void i_frame_continued (ax25_dlsm_t *S, int p, int ns, int pid, char *inf
 //	      int allow_f1 = 0;		// F=1 from X.25 2.4.6.4 b) 3)
 	      int allow_f1 = 1;		// F=1 from X.25 2.4.6.4 b) 3)
 
-// send only for this gap, not cummulative from V(R).
+// send only for this gap, not cumulative from V(R).
 
 	      int last = AX25MODULO(ns - 1, S->modulo, __FILE__, __func__, __LINE__);
 	      int first = last;
@@ -3447,7 +3447,7 @@ static void rr_rnr_frame (ax25_dlsm_t *S, int ready, cmdres_t cr, int pf, int nr
 // we received RR frames with N(R) values indicating that the other side received everything
 // that we sent.  Eventually rc could reach the limit and we would get an error.
 // If we are in state 4, and other guy ack'ed last I frame we sent, transition to state 3.
-// The same thing was done for receving I frames after check_i_frame_ackd.
+// The same thing was done for receiving I frames after check_i_frame_ackd.
 
 // Thought: Could we simply call check_i_frame_ackd, for consistency, rather than only setting V(A)?
 
@@ -3759,7 +3759,7 @@ static void rej_frame (ax25_dlsm_t *S, cmdres_t cr, int pf, int nr)
  *
  *		The SREJ command/response initiates more-efficient error recovery by requesting the retransmission of a
  *		single I frame following the detection of a sequence error. This is an advancement over the earlier versions in
- *		which the requested I frame was retransmitted togther with all additional I frames subsequently transmitted and
+ *		which the requested I frame was retransmitted together with all additional I frames subsequently transmitted and
  *		successfully received.
  *
  *		When a TNC sends one or more SREJ commands, each with the P bit set to "0" or "1", or one or more SREJ
@@ -4409,7 +4409,7 @@ static void disc_frame (ax25_dlsm_t *S, int p)
  *		earliest opportunity. If the TNC is not capable of accepting a SABME command, it responds with a DM frame.
  *
  *		A TNC that uses a version of AX.25 prior to v2.2 responds with a FRMR.
- *		( I think the KPC-3+ has a bug - it replys with DM - WB2OSZ )
+ *		( I think the KPC-3+ has a bug - it replies with DM - WB2OSZ )
  *
  *		4.3.3.5. Disconnected Mode (DM) Response
  *
@@ -4636,7 +4636,7 @@ static void ua_frame (ax25_dlsm_t *S, int f)
 	    if (f == 1) {
 	      if (S->layer_3_initiated) {
 	        text_color_set(DW_COLOR_INFO);
-	        // TODO: add via if apppropriate.
+	        // TODO: add via if appropriate.
 	        dw_printf ("Stream %d: Connected to %s.  (%s)\n", S->stream_id, S->addrs[PEERCALL], S->state == state_5_awaiting_v22_connection ? "v2.2" : "v2.0");
 	        // There is a subtle difference here between connect confirm and indication.
 	        // connect *confirm* means "has been made"
@@ -5615,7 +5615,7 @@ static void clear_exception_conditions (ax25_dlsm_t *S)
  *
  *					Other guy gets RR/RNR command P=1.
  *					Same action for either state 3 or 4.
- *					Whether he has outstanding un-ack'ed sent I frames is irrelevent.
+ *					Whether he has outstanding un-ack'ed sent I frames is irrelevant.
  *					He calls "enquiry response" which sends RR/RNR response F=1.
  *					(Read about detour 1 below and in enquiry_response.)
  *
diff --git a/src/ax25_pad.c b/src/ax25_pad.c
index d8af765d..32e89b60 100644
--- a/src/ax25_pad.c
+++ b/src/ax25_pad.c
@@ -49,7 +49,7 @@
  *
  *
  *	APRS uses only UI frames.
- *	Each starts with 2-10 addressses (14-70 octets):
+ *	Each starts with 2-10 addresses (14-70 octets):
  *
  *	* Destination Address  (note: opposite order in printed format)
  *
@@ -940,7 +940,7 @@ int ax25_check_addresses (packet_t pp)
  *
  * Name:	ax25_unwrap_third_party
  * 
- * Purpose:	Unwrap a third party messge from the header.
+ * Purpose:	Unwrap a third party message from the header.
  *
  * Inputs:	copy_from	- Existing packet object.
  *
diff --git a/src/ax25_pad.h b/src/ax25_pad.h
index 22568f74..5869bee3 100644
--- a/src/ax25_pad.h
+++ b/src/ax25_pad.h
@@ -11,7 +11,7 @@
 
 
 #define AX25_MAX_REPEATERS 8
-#define AX25_MIN_ADDRS 2	/* Destinatin & Source. */
+#define AX25_MIN_ADDRS 2	/* Destination & Source. */
 #define AX25_MAX_ADDRS 10	/* Destination, Source, 8 digipeaters. */	
 
 #define AX25_DESTINATION  0	/* Address positions in frame. */
@@ -98,7 +98,7 @@ struct packet_s {
 			         *
 				 * Bits:   H  R  R  SSID  0
 				 *
-				 *   H 		for digipeaters set to 0 intially.
+				 *   H 		for digipeaters set to 0 initially.
 				 *		Changed to 1 when position has been used.
  				 *
 				 *		for source & destination it is called
diff --git a/src/ax25_pad2.c b/src/ax25_pad2.c
index efba8879..862f913b 100644
--- a/src/ax25_pad2.c
+++ b/src/ax25_pad2.c
@@ -406,7 +406,7 @@ packet_t ax25_s_frame (char addrs[AX25_MAX_ADDRS][AX25_MAX_ADDR_LEN], int num_ad
 	}
 
 	// Erratum: The AX.25 spec is not clear about whether SREJ should be command, response, or both.
-	// The underlying X.25 spec clearly says it is reponse only.  Let's go with that.
+	// The underlying X.25 spec clearly says it is response only.  Let's go with that.
 
 	if (ftype == frame_type_S_SREJ && cr != cr_res) {
 	  text_color_set(DW_COLOR_ERROR);
diff --git a/src/cdigipeater.c b/src/cdigipeater.c
index edfa2ddc..b126b83b 100644
--- a/src/cdigipeater.c
+++ b/src/cdigipeater.c
@@ -34,7 +34,7 @@
  *		are significantly different and I thought it would be
  *		too confusing to munge them together.
  *
- * References:	The Ax.25 protcol barely mentions digipeaters and
+ * References:	The Ax.25 protocol barely mentions digipeaters and
  *		and doesn't describe how they should work.
  *		
  *------------------------------------------------------------------*/
@@ -255,7 +255,7 @@ static packet_t cdigipeat_match (int from_chan, packet_t pp, char *mycall_rec, c
  *				Originally this was the only one.
  *				Should we change it to AFILTER to make it clearer?
  *	CFILTER		- Similar for connected moded digipeater.
- *	IGFILTER	- APRS-IS (IGate) server side - completely diffeent.
+ *	IGFILTER	- APRS-IS (IGate) server side - completely different.
  *				Confusing with similar name but much different idea.
  *				Maybe this should be renamed to SUBSCRIBE or something like that.
  *
diff --git a/src/cm108.c b/src/cm108.c
index ad3b0b8f..019bc4b2 100644
--- a/src/cm108.c
+++ b/src/cm108.c
@@ -30,7 +30,7 @@
  *		
  * Description:
  *
- *	There is an incresing demand for using the GPIO pins of USB audio devices for PTT.
+ *	There is an increasing demand for using the GPIO pins of USB audio devices for PTT.
  *	We have a few commercial products:
  *
  *		DMK URI		http://www.dmkeng.com/URI_Order_Page.htm
@@ -51,7 +51,7 @@
  *	painful roundabout way.  This is documented in the User Guide, section called,
  *		 "Hamlib PTT Example 2: Use GPIO of USB audio adapter.  (e.g. DMK URI)"
  *
- *	It's rather involved and the explantion doesn't cover the case of multiple
+ *	It's rather involved and the explanation doesn't cover the case of multiple
  *	USB-Audio adapters.  It is not as straightforward as you might expect.  Here we have
  *	an example of 3 C-Media USB adapters, a SignaLink USB, a keyboard, and a mouse.
  *	
@@ -584,7 +584,7 @@ int cm108_inventory (struct thing_s *things, int max_things)
  *		ptt_device_size	- Size of result area to avoid buffer overflow.
  *
  * Outputs:	ptt_device	- Device name, something like /dev/hidraw2.
- *				  Will be emptry string if no match found.
+ *				  Will be empty string if no match found.
  *
  * Returns:	none
  *
diff --git a/src/config.c b/src/config.c
index 8588a8cc..2722b0e9 100644
--- a/src/config.c
+++ b/src/config.c
@@ -317,7 +317,7 @@ static double parse_ll (char *str, enum parse_ll_which_e which, int line)
  *		  - Negative zone for south.
  *		  - Separate North or South.
  *		
- *		I'm using the first alternatve.
+ *		I'm using the first alternative.
  *		GEOTRANS uses the third.
  *		We will also recognize the second one but I'm not sure if I want to document it.
  *
@@ -1808,7 +1808,7 @@ void config_init (char *fname, struct audio_s *p_audio_config,
 	      }
 	      strlcpy (p_audio_config->achan[channel].octrl[ot].ptt_device, t, sizeof(p_audio_config->achan[channel].octrl[ot].ptt_device));
 
-	      // Optional serial port rate for CAT controll PTT.
+	      // Optional serial port rate for CAT control PTT.
 
 	      t = split(NULL,0);
 	      if (t != NULL) {
@@ -2642,11 +2642,11 @@ void config_init (char *fname, struct audio_s *p_audio_config,
  *			  There is discussion about this in the document called
  *			  Why-is-9600-only-twice-as-fast-as-1200.pdf
  *
- *	IGFILTER	- APRS-IS (IGate) server side - completely diffeent.
+ *	IGFILTER	- APRS-IS (IGate) server side - completely different.
  *			  I'm not happy with this name because IG sounds like IGate
  *			  which is really the client side.  More comments later.
  *			  Maybe it should be called subscribe or something like that
- *			  because the subscriptions are cummulative.
+ *			  because the subscriptions are cumulative.
  */
 
 	  else if (strcasecmp(t, "FILTER") == 0) {
@@ -3677,7 +3677,7 @@ void config_init (char *fname, struct audio_s *p_audio_config,
 	    strlcpy(tl->pattern, "", sizeof(tl->pattern));
 
 	    /* Pattern: Any combination of digits, x, y, and z. */
-	    /* Also make note of which letters are used in pattern and defintition. */
+	    /* Also make note of which letters are used in pattern and definition. */
  	    /* Version 1.2: also allow A,B,C,D in the pattern. */
 
 	    t = split(NULL,0);
@@ -4664,7 +4664,7 @@ void config_init (char *fname, struct audio_s *p_audio_config,
 	      strlcpy (p_misc_config->waypoint_serial_port, t, sizeof(p_misc_config->waypoint_serial_port));
 	    }
 	
-	    /* Anthing remaining is the formats to enable. */
+	    /* Anything remaining is the formats to enable. */
 
 	    t = split(NULL,1);
 	    if (t != NULL) {
@@ -5031,7 +5031,7 @@ void config_init (char *fname, struct audio_s *p_audio_config,
 /*
  * V20  address [ address ... ] 	- Stations known to support only AX.25 v2.0.
  *					  When connecting to these, skip SABME and go right to SABM.
- *					  Possible to have multiple and they are cummulative.
+ *					  Possible to have multiple and they are cumulative.
  */
 
 	  else if (strcasecmp(t, "V20") == 0) {
@@ -5065,9 +5065,9 @@ void config_init (char *fname, struct audio_s *p_audio_config,
 
 /*
  * NOXID  address [ address ... ] 	- Stations known not to understand XID.
- *					  After connecting to these (with v2.2 obviously), don't try using XID commmand.
+ *					  After connecting to these (with v2.2 obviously), don't try using XID command.
  *					  AX.25 for Linux is the one known case so far.
- *					  Possible to have multiple and they are cummulative.
+ *					  Possible to have multiple and they are cumulative.
  */
 
 	  else if (strcasecmp(t, "NOXID") == 0) {
@@ -5480,7 +5480,7 @@ static int beacon_options(char *cmd, struct beacon_s *b, int line, struct audio_
 	}
 
 /*
- * Convert UTM coordintes to lat / long.
+ * Convert UTM coordinates to lat / long.
  */
 	if (strlen(zone) > 0 || easting != G_UNKNOWN || northing != G_UNKNOWN) {
 
diff --git a/src/decode_aprs.c b/src/decode_aprs.c
index 3afa3773..d4661e04 100644
--- a/src/decode_aprs.c
+++ b/src/decode_aprs.c
@@ -26,7 +26,7 @@
  *
  * Description: Present the packet contents in human readable format.
  *		This is a fairly complete implementation with error messages
- *		pointing out various specication violations. 
+ *		pointing out various specification violations.
  *
  * Assumptions:	ax25_from_frame() has been called to 
  *		separate the header and information.
@@ -441,7 +441,7 @@ void decode_aprs_print (decode_aprs_t *A) {
 	if (A->g_power > 0) {
 	  char phg[100];
 
-	  /* Protcol spec doesn't mention whether this is dBd or dBi.  */
+	  /* Protocol spec doesn't mention whether this is dBd or dBi.  */
 	  /* Clarified later. */
 	  /* http://eng.usna.navy.mil/~bruninga/aprs/aprs11.html */
 	  /* "The Antenna Gain in the PHG format on page 28 is in dBi." */
@@ -492,7 +492,7 @@ void decode_aprs_print (decode_aprs_t *A) {
 
 	if (A->g_lat != G_UNKNOWN || A->g_lon != G_UNKNOWN) {
 
-// Have location but it is posible one part is invalid.
+// Have location but it is possible one part is invalid.
 
 	  if (A->g_lat != G_UNKNOWN) {
   
@@ -1022,7 +1022,7 @@ N1ZZN-9>T2SP0W:'c_Vm6hk/`"49}Byonics TinyTrack4|4
 
 # The next group starts with metacharacter "T" which can be any of space > ] ` '
 # But space is for original Mic-E, # > and ] are for Kenwood, 
-# so ` ' would probably be less ambigous choices but any appear to be valid.
+# so ` ' would probably be less ambiguous choices but any appear to be valid.
 
 N1ZZN-9>T2SP0W:'c_Vm6hk/`"49}Hamhud\9
 N1ZZN-9>T2SP0W:'c_Vm6hk/`"49}Argent/9
@@ -1130,7 +1130,7 @@ static void aprs_mic_e (decode_aprs_t *A, packet_t pp, unsigned char *info, int
 		 mic_e_digit(A, dest[5], 0, &std_msg, &cust_msg)) / 6000.0;
 
 
-/* 4th character of desination indicates north / south. */
+/* 4th character of destination indicates north / south. */
 
 	if ((dest[3] >= '0' && dest[3] <= '9') || dest[3] == 'L') {
 	  /* South */
@@ -1172,7 +1172,7 @@ static void aprs_mic_e (decode_aprs_t *A, packet_t pp, unsigned char *info, int
 /* First character of information field is longitude in degrees. */
 /* It is possible for the unprintable DEL character to occur here. */
 
-/* 5th character of desination indicates longitude offset of +100. */
+/* 5th character of destination indicates longitude offset of +100. */
 /* Not quite that simple :-( */
 
 	ch = p->lon[0];
@@ -1456,7 +1456,7 @@ static void aprs_mic_e (decode_aprs_t *A, packet_t pp, unsigned char *info, int
  *
  * Inputs:	info 	- Pointer to Information field.
  *		ilen 	- Information field length.
- *		quiet	- supress error messages.
+ *		quiet	- suppress error messages.
  *
  * Outputs:	A->g_msg_type		Text description for screen display.
  *
@@ -1480,7 +1480,7 @@ static void aprs_mic_e (decode_aprs_t *A, packet_t pp, unsigned char *info, int
  *
  * Cases:	:xxxxxxxxx:PARM.		Telemetry metadata, parameter name
  *		:xxxxxxxxx:UNIT.		Telemetry metadata, unit/label
- *		:xxxxxxxxx:EQNS.		Telemetry metadata, Equation Coefficents
+ *		:xxxxxxxxx:EQNS.		Telemetry metadata, Equation Coefficients
  *		:xxxxxxxxx:BITS.		Telemetry metadata, Bit Sense/Project Name
  *		:xxxxxxxxx:?			Directed Station Query
  *		:xxxxxxxxx:ack			Message acknowledged (received)
@@ -1503,7 +1503,7 @@ static void aprs_message (decode_aprs_t *A, unsigned char *info, int ilen, int q
 	  char message[73];		/* 0-67 characters for message */
 					/* Optional { followed by 1-5 characters for message number */
 
-					/* If the first chracter is '?' it is a Directed Station Query. */
+					/* If the first character is '?' it is a Directed Station Query. */
 	} *p;
 
 	char addressee[AX25_MAX_ADDR_LEN];
@@ -4034,7 +4034,7 @@ static void substr_se (char *dest, const char *src, int start, int endp1)
  *
  *			!DAO!			APRS precision and Datum option.
  *
- *		Protocol reference, end of chaper 6.
+ *		Protocol reference, end of chapter 6.
  *
  *			/A=123456		Altitude
  *
@@ -4074,7 +4074,7 @@ static void substr_se (char *dest, const char *src, int start, int endp1)
  *		  This same thing has been observed from others and is intermittent.
  *
  *		* AGW Tracker can send UTF-16 if an option is selected.  This can introduce nul bytes.
- *		  This is wrong.  It should be using UTF-8 and I'm not going to accomodate it here.
+ *		  This is wrong.  It should be using UTF-8 and I'm not going to accommodate it here.
  *
  *
  *		The digipeater and IGate functions should pass along anything exactly the
@@ -4241,7 +4241,7 @@ static void process_comment (decode_aprs_t *A, char *pstart, int clen)
 /*
  * Watch out for buffer overflow.
  * KG6AZZ reports that there is a local digipeater that seems to 
- * malfunction ocassionally.  It corrupts the packet, as it is
+ * malfunction occasionally.  It corrupts the packet, as it is
  * digipeated, causing the comment to be hundreds of characters long.
  */
 
@@ -4448,7 +4448,7 @@ static void process_comment (decode_aprs_t *A, char *pstart, int clen)
  * This would not make sense to use this with a compressed location which
  * already has much greater resolution.
  *
- * It surprized me to see this in a MIC-E message.
+ * It surprised me to see this in a MIC-E message.
  * MIC-E has resolution of .01 minute so it would make sense to have it as an option.
  */
 
@@ -4904,7 +4904,7 @@ int main (int argc, char *argv[])
 	        hex_dump (kiss_frame, kiss_len);
 
 	        // Put FEND at end to keep kiss_unwrap happy.
-	        // Having one at the begining is optional.
+	        // Having one at the beginning is optional.
 
 	        kiss_frame[kiss_len++] = FEND;
 
diff --git a/src/demod.c b/src/demod.c
index 281367bc..500cf6ce 100644
--- a/src/demod.c
+++ b/src/demod.c
@@ -492,7 +492,7 @@ int demod_init (struct audio_s *pa)
 	      // In versions 1.4 and 1.5, V.26 "Alternative A" was used.
 	      // years later, I discover that the MFJ-2400 used "Alternative B."
 	      // It looks like the other two manufacturers use the same but we
-              // can't be sure until we find one for compatbility testing.
+              // can't be sure until we find one for compatibility testing.
 
 	      // In version 1.6 we add a choice for the user.
 	      // If neither one was explicitly specified, print a message and take
@@ -698,7 +698,7 @@ int demod_init (struct audio_s *pa)
 	        else if (ratio < 10) {
 
 	          // 48000 / 9600 is 5.00
-	          // Need more reasearch.  Treat like above for now.
+	          // Need more research.  Treat like above for now.
 
 	          save_audio_config_p->achan[chan].upsample = 4;
 	        }
@@ -821,7 +821,7 @@ int demod_init (struct audio_s *pa)
  * Global In:	save_audio_config_p->adev[ACHAN2ADEV(chan)].bits_per_sample - So we know whether to 
  *			read 1 or 2 bytes from audio stream.
  *
- * Description:	Grab 1 or two btyes depending on data source.
+ * Description:	Grab 1 or two bytes depending on data source.
  *
  *		When processing stereo, the caller will call this
  *		at twice the normal rate to obtain alternating left 
@@ -836,7 +836,7 @@ __attribute__((hot))
 int demod_get_sample (int a)		
 {
 	int x1, x2;
-	signed short sam;	/* short to force sign extention. */
+	signed short sam;	/* short to force sign extension. */
 
 
 	assert (save_audio_config_p->adev[a].bits_per_sample == 8 || save_audio_config_p->adev[a].bits_per_sample == 16);
diff --git a/src/demod_9600.c b/src/demod_9600.c
index 2f989830..c0943b9c 100644
--- a/src/demod_9600.c
+++ b/src/demod_9600.c
@@ -322,7 +322,7 @@ void demod_9600_process_sample (int chan, int sam, struct demodulator_state_s *D
  * Future project?  Rather than shifting the samples,
  * it might be faster to add another variable to keep
  * track of the most recent sample and change the 
- * indexing in the later loops that multipy and add.
+ * indexing in the later loops that multiply and add.
  */
 
 	/* Scale to nice number for convenience. */
@@ -478,7 +478,7 @@ void demod_9600_process_sample (int chan, int sam, struct demodulator_state_s *D
  *
  * Returns:	None
  *
- * Descripton:	A PLL is used to sample near the centers of the data bits.
+ * Description:	A PLL is used to sample near the centers of the data bits.
  *
  *		D->data_clock_pll is a SIGNED 32 bit variable.
  *		When it overflows from a large positive value to a negative value, we
diff --git a/src/demod_afsk.c b/src/demod_afsk.c
index 7a007d1f..467a7c93 100644
--- a/src/demod_afsk.c
+++ b/src/demod_afsk.c
@@ -309,7 +309,7 @@ void demod_afsk_init (int samples_per_sec, int baud, int mark_freq,
  * Calculate constants used for timing.
  * The audio sample rate must be at least a few times the data rate.
  *
- * Baud is an integer so we hack in a fine ajustment for EAS.
+ * Baud is an integer so we hack in a fine adjustment for EAS.
  * Probably makes no difference because the DPLL keeps it in sync.
  *
  * A fraction if a Hz would make no difference for the filters.
@@ -642,7 +642,7 @@ void demod_afsk_process_sample (int chan, int subchan, int sam, struct demodulat
  * A simple IIR filter is faster but FIR produces better results.
  *
  * It is a balancing act between removing high frequency components
- * from the tone dectection while letting the data thru.
+ * from the tone detection while letting the data thru.
  */
 
 	if (D->lpf_use_fir) {
@@ -717,7 +717,7 @@ void demod_afsk_process_sample (int chan, int subchan, int sam, struct demodulat
  *
  * First, let's take a look at Track 1 of the TNC test CD.  Here the receiver
  * has a flat response.  We find the mark/space strength ratios very from 0.53 to 1.38
- * with a median of 0.81.  This in in line with expections because most
+ * with a median of 0.81.  This in in line with exceptions because most
  * transmitters add pre-emphasis to boost the higher audio frequencies.
  * Track 2 should more closely resemble what comes out of the speaker on a typical
  * transceiver.  Here we see a ratio from 1.73 to 3.81 with a median of 2.48.
@@ -831,7 +831,7 @@ inline static void nudge_pll (int chan, int subchan, int slice, int demod_data,
  * If we adjust it too quickly, the clock will have too much jitter.
  * If we adjust it too slowly, it will take too long to lock on to a new signal.
  *
- * Be a little more agressive about adjusting the PLL
+ * Be a little more aggressive about adjusting the PLL
  * phase when searching for a signal.  Don't change it as much when
  * locked on to a signal.
  *
diff --git a/src/demod_psk.c b/src/demod_psk.c
index f01ee217..6e5d22f8 100644
--- a/src/demod_psk.c
+++ b/src/demod_psk.c
@@ -60,7 +60,7 @@
  *		"bis" and "ter" are from Latin for second and third.
  *		I used the "ter" version which has phase shifts of 0, 90, 180, and 270 degrees.
  *
- *		There are ealier references to an alternative B which uses other phase shifts offset
+ *		There are earlier references to an alternative B which uses other phase shifts offset
  *		by another 45 degrees.
  *
  *		After getting QPSK working, it was not much more effort to add V.27 with 8 phases.
@@ -781,7 +781,7 @@ static void nudge_pll (int chan, int subchan, int slice, int demod_bits, struct
  * If we adjust it too quickly, the clock will have too much jitter.
  * If we adjust it too slowly, it will take too long to lock on to a new signal.
  *
- * Be a little more agressive about adjusting the PLL
+ * Be a little more aggressive about adjusting the PLL
  * phase when searching for a signal.
  * Don't change it as much when locked on to a signal.
  */
diff --git a/src/digipeater.c b/src/digipeater.c
index 1e4c8147..75aa53d0 100644
--- a/src/digipeater.c
+++ b/src/digipeater.c
@@ -608,7 +608,7 @@ void digi_regen (int from_chan, packet_t pp)
  *
  * Name:	main
  * 
- * Purpose:	Standalone test case for this funtionality.
+ * Purpose:	Standalone test case for this functionality.
  *
  * Usage:	make -f Makefile.<platform> dtest
  *		./dtest 
diff --git a/src/direwolf.c b/src/direwolf.c
index 456b16f0..38e40dc8 100644
--- a/src/direwolf.c
+++ b/src/direwolf.c
@@ -224,7 +224,7 @@ int main (int argc, char *argv[])
 #endif
 	int d_x_opt = 1;	/* "-d x" option for FX.25.  Default minimal. Repeat for more detail.  -qx to silence. */
 
-	int E_tx_opt = 0;		/* "-E n" Error rate % for clobbering trasmit frames. */
+	int E_tx_opt = 0;		/* "-E n" Error rate % for clobbering transmit frames. */
 	int E_rx_opt = 0;		/* "-E Rn" Error rate % for clobbering receive frames. */
 
 	float e_recv_ber = 0.0;		/* Receive Bit Error Rate (BER). */
diff --git a/src/direwolf.h b/src/direwolf.h
index efc329ba..9e6cc2d6 100644
--- a/src/direwolf.h
+++ b/src/direwolf.h
@@ -97,7 +97,7 @@
  * Each one of these can have multiple slicers, at
  * different levels, to compensate for different
  * amplitudes of the AFSK tones.
- * Intially used same number as subchannels but
+ * Initially used same number as subchannels but
  * we could probably trim this down a little
  * without impacting performance.
  */
diff --git a/src/dlq.c b/src/dlq.c
index 2f21f6d0..23f43890 100644
--- a/src/dlq.c
+++ b/src/dlq.c
@@ -840,7 +840,7 @@ void dlq_channel_busy (int chan, int activity, int status)
  * Name:        dlq_seize_confirm
  *
  * Purpose:     Inform data link state machine that the transmitter is on.
- *		This is in reponse to lm_seize_request.
+ *		This is in response to lm_seize_request.
  *
  * Inputs:	chan		- Radio channel number.
  *
diff --git a/src/dtmf.c b/src/dtmf.c
index 788be18b..956f709b 100644
--- a/src/dtmf.c
+++ b/src/dtmf.c
@@ -245,7 +245,7 @@ char dtmf_sample (int c, float input)
  * others in the same group multiplied by some factor.
  *
  * For perfect synthetic signals this needs to be in
- * the range of about 1.33 (very senstive) to 2.15 (very fussy).
+ * the range of about 1.33 (very sensitive) to 2.15 (very fussy).
  *
  * Too low will cause false triggers on random noise.
  * Too high will won't decode less than perfect signals.
diff --git a/src/dwgps.c b/src/dwgps.c
index 83e92444..ccf24b0b 100644
--- a/src/dwgps.c
+++ b/src/dwgps.c
@@ -90,7 +90,7 @@ static dw_mutex_t s_gps_mutex;
  *
  * Name:        dwgps_init
  *
- * Purpose:    	Intialize the GPS interface.
+ * Purpose:    	Initialize the GPS interface.
  *
  * Inputs:	pconfig		Configuration settings.  This might include
  *				serial port name for direct connect and host
diff --git a/src/dwgpsd.c b/src/dwgpsd.c
index 70b650bd..8378288a 100644
--- a/src/dwgpsd.c
+++ b/src/dwgpsd.c
@@ -94,7 +94,7 @@ static void * read_gpsd_thread (void *arg);
  *
  * Name:        dwgpsd_init
  *
- * Purpose:    	Intialize the GPS interface.
+ * Purpose:    	Initialize the GPS interface.
  *
  * Inputs:	pconfig		Configuration settings.  This includes
  *				host name or address for network connection.
@@ -191,7 +191,7 @@ int dwgpsd_init (struct misc_config_s *pconfig, int debug)
 
 	if (strlen(pconfig->gpsd_host) == 0) {
 
-	  /* Nothing to do.  Leave initial fix value of errror. */
+	  /* Nothing to do.  Leave initial fix value of error. */
 	  return (0);
 	}	  
 
diff --git a/src/dwgpsnmea.c b/src/dwgpsnmea.c
index 840ab652..547c07d8 100644
--- a/src/dwgpsnmea.c
+++ b/src/dwgpsnmea.c
@@ -436,7 +436,7 @@ static int remove_checksum (char *sent, int quiet)
  *
  * Name:        dwgpsnmea_gprmc
  *
- * Purpose:    	Parse $GPRMC sentence and extract interesing parts.
+ * Purpose:    	Parse $GPRMC sentence and extract interesting parts.
  *
  * Inputs:	sentence	NMEA sentence.
  *
@@ -585,7 +585,7 @@ dwfix_t dwgpsnmea_gprmc (char *sentence, int quiet, double *odlat, double *odlon
  *
  * Name:        dwgpsnmea_gpgga
  *
- * Purpose:    	Parse $GPGGA sentence and extract interesing parts.
+ * Purpose:    	Parse $GPGGA sentence and extract interesting parts.
  *
  * Inputs:	sentence	NMEA sentence.
  *
diff --git a/src/encode_aprs.c b/src/encode_aprs.c
index 225cb080..af39aa5a 100644
--- a/src/encode_aprs.c
+++ b/src/encode_aprs.c
@@ -497,7 +497,7 @@ static int frequency_spec (float freq, float tone, float offset, char *presult)
  *
  *		comment	- Additional comment text.
  *
- *		result_size - Ammount of space for result, provideed by 
+ *		result_size - Amount of space for result, provided by
  *				caller, to avoid buffer overflow.
  *
  * Outputs:	presult	- Stored here.  Should be at least ??? bytes.
@@ -512,7 +512,7 @@ static int frequency_spec (float freq, float tone, float offset, char *presult)
  *			Power/height/gain/directivity or
  *			Course/speed.
  *
- *		Afer that, 
+ *		After that,
  *
  *----------------------------------------------------------------*/
 
@@ -639,7 +639,7 @@ int encode_position (int messaging, int compressed, double lat, double lon, int
  *
  *		comment	- Additional comment text.
  *
- *		result_size - Ammount of space for result, provideed by 
+ *		result_size - Amount of space for result, provided by
  *				caller, to avoid buffer overflow.
  *
  * Outputs:	presult	- Stored here.  Should be at least ??? bytes.
@@ -769,7 +769,7 @@ int encode_object (char *name, int compressed, time_t thyme, double lat, double
  * Inputs:      addressee	- Addressed to, up to 9 characters.
  *		text		- Text part of the message.
  *		id		- Identifier, 0 to 5 characters.
- *		result_size 	- Ammount of space for result, provided by
+ *		result_size 	- Amount of space for result, provided by
  *				  caller, to avoid buffer overflow.
  *
  * Outputs:	presult	- Stored here.
@@ -853,7 +853,7 @@ int main (int argc, char *argv[])
 	dw_printf ("%s\n", result);
 	if (strcmp(result, "!4234.61ND07126.47W&PHG7368") != 0) { dw_printf ("ERROR!  line %d\n", __LINE__); errors++; }
 
-/* with freq & tone.  minus offset, no offset, explict simplex. */
+/* with freq & tone.  minus offset, no offset, explicit simplex. */
 
 	encode_position (0, 0, 42+34.61/60, -(71+26.47/60), 0, G_UNKNOWN, 'D', '&',
 		0, 0, 0, NULL, G_UNKNOWN, 0, 146.955, 74.4, -0.6, NULL, result, sizeof(result));
diff --git a/src/fx25_rec.c b/src/fx25_rec.c
index 3ab78518..9cb5c4d9 100644
--- a/src/fx25_rec.c
+++ b/src/fx25_rec.c
@@ -258,7 +258,7 @@ int fx25_rec_busy (int chan)
 {
 	assert (chan >= 0 && chan < MAX_CHANS);
 
-	// This could be a litle faster if we knew number of
+	// This could be a little faster if we knew number of
 	// subchannels and slicers but it is probably insignificant.
 
 	for (int i = 0; i < MAX_SUBCHANS; i++) {
diff --git a/src/hdlc_rec.c b/src/hdlc_rec.c
index 6b395be6..9a84d3c5 100644
--- a/src/hdlc_rec.c
+++ b/src/hdlc_rec.c
@@ -759,7 +759,7 @@ void dcd_change (int chan, int subchan, int slice, int state)
  *
  * Name:        hdlc_rec_data_detect_any
  *
- * Purpose:     Determine if the radio channel is curently busy
+ * Purpose:     Determine if the radio channel is currently busy
  *		with packet data.
  *		This version doesn't care about voice or other sounds.
  *		This is used by the transmit logic to transmit only
@@ -774,7 +774,7 @@ void dcd_change (int chan, int subchan, int slice, int state)
  * Description:	We have two different versions here.
  *
  *		hdlc_rec_data_detect_any sees if ANY of the decoders
- *		for this channel are receving a signal.   This is
+ *		for this channel are receiving a signal.   This is
  *		used to determine whether the channel is clear and
  *		we can transmit.  This would apply to the 300 baud
  *		HF SSB case where we have multiple decoders running
diff --git a/src/hdlc_rec2.c b/src/hdlc_rec2.c
index e23aaee7..b817018f 100644
--- a/src/hdlc_rec2.c
+++ b/src/hdlc_rec2.c
@@ -273,7 +273,7 @@ void hdlc_rec2_block (rrbb_t block)
 	}
 
 /*
- * Not successful with frame in orginal form.
+ * Not successful with frame in original form.
  * See if we can "fix" it.
  */
 	if (try_to_fix_quick_now (block, chan, subchan, slice, alevel)) {
diff --git a/src/igate.c b/src/igate.c
index 37cd34fa..f4c1b572 100644
--- a/src/igate.c
+++ b/src/igate.c
@@ -2211,7 +2211,7 @@ static int rx_to_ig_allow (packet_t pp)
  *
  * Future:
  *		Should the digipeater function avoid transmitting something if it
- *		was recently transmitted by the IGate funtion?
+ *		was recently transmitted by the IGate function?
  *		This code is pretty much the same as dedupe.c. Maybe it could all
  *		be combined into one.  Need to ponder this some more.
  * 
diff --git a/src/kiss.c b/src/kiss.c
index 76cb322d..74c622c6 100644
--- a/src/kiss.c
+++ b/src/kiss.c
@@ -465,11 +465,11 @@ void kisspt_send_rec_packet (int chan, int kiss_cmd, unsigned char *fbuf,  int f
  *
  * Returns:	one byte (value 0 - 255) or terminate thread on error.
  *
- * Description:	There is room for improvment here.  Reading one byte
+ * Description:	There is room for improvement here.  Reading one byte
  *		at a time is inefficient.  We could read a large block
  *		into a local buffer and return a byte from that most of the time.
  *		Is it worth the effort?  I don't know.  With GHz processors and
- *		the low data rate here it might not make a noticable difference.
+ *		the low data rate here it might not make a noticeable difference.
  *
  *--------------------------------------------------------------------*/
 
diff --git a/src/kiss_frame.c b/src/kiss_frame.c
index c0876357..7329227d 100644
--- a/src/kiss_frame.c
+++ b/src/kiss_frame.c
@@ -64,7 +64,7 @@
  *			_6	SetHardware	TNC specific.
  *
  *			_C	XKISS extension - not supported.
- *			_E	XKISS extention - not supported.
+ *			_E	XKISS extension - not supported.
  *			
  *			FF	Return		Exit KISS mode.  Ignored.
  *
diff --git a/src/kiss_frame.h b/src/kiss_frame.h
index 0bddf3ec..a2990129 100644
--- a/src/kiss_frame.h
+++ b/src/kiss_frame.h
@@ -41,7 +41,7 @@ enum kiss_state_e {
 
 
 #define MAX_KISS_LEN 2048	/* Spec calls for at least 1024. */
-				/* Might want to make it longer to accomodate */
+				/* Might want to make it longer to accommodate */
 				/* maximum packet length. */
 
 #define MAX_NOISE_LEN 100
diff --git a/src/kissnet.c b/src/kissnet.c
index 7b4f1c4f..d7737773 100644
--- a/src/kissnet.c
+++ b/src/kissnet.c
@@ -424,7 +424,7 @@ static THREAD_F connect_listen_thread (void *arg)
 #else		/* End of Windows case, now Linux. */
 
 
-    	struct sockaddr_in sockaddr; /* Internet socket address stuct */
+    	struct sockaddr_in sockaddr; /* Internet socket address struct */
     	socklen_t sockaddr_size = sizeof(struct sockaddr_in);
 	int kiss_port = (int)(ptrdiff_t)arg;
 	int listen_sock;  
diff --git a/src/kissserial.c b/src/kissserial.c
index 9f185ef1..dc43628c 100644
--- a/src/kissserial.c
+++ b/src/kissserial.c
@@ -370,11 +370,11 @@ void kissserial_send_rec_packet (int chan, int kiss_cmd, unsigned char *fbuf,  i
  *
  * Returns:	one byte (value 0 - 255) or terminate thread on error.
  *
- * Description:	There is room for improvment here.  Reading one byte
+ * Description:	There is room for improvement here.  Reading one byte
  *		at a time is inefficient.  We could read a large block
  *		into a local buffer and return a byte from that most of the time.
  *		Is it worth the effort?  I don't know.  With GHz processors and
- *		the low data rate here it might not make a noticable difference.
+ *		the low data rate here it might not make a noticeable difference.
  *
  *--------------------------------------------------------------------*/
 
diff --git a/src/multi_modem.c b/src/multi_modem.c
index c59af071..bdb706d0 100644
--- a/src/multi_modem.c
+++ b/src/multi_modem.c
@@ -468,7 +468,7 @@ static void pick_best_candidate (int chan)
 	    spectrum[n] = '.';
 	  }
 
-	  /* Begining score depends on effort to get a valid frame CRC. */
+	  /* Beginning score depends on effort to get a valid frame CRC. */
 
 	  if (candidate[chan][j][k].packet_p == NULL) {
 	    candidate[chan][j][k].score = 0;
diff --git a/src/pfilter.c b/src/pfilter.c
index 626f0712..d67dd58a 100644
--- a/src/pfilter.c
+++ b/src/pfilter.c
@@ -116,7 +116,7 @@ typedef struct pfstate_s {
 
 /*
  * Are we processing APRS or connected mode?
- * This determines whch types of filters are available.
+ * This determines which types of filters are available.
  */
 	int is_aprs;
 
@@ -220,7 +220,7 @@ int pfilter (int from_chan, int to_chan, char *filter, packet_t pp, int is_aprs)
 	pfstate.from_chan = from_chan;
 	pfstate.to_chan = to_chan;
 
-	/* Copy filter string, changing any control characers to spaces. */
+	/* Copy filter string, changing any control characters to spaces. */
 
 	strlcpy (pfstate.filter_str, filter, sizeof(pfstate.filter_str));
 
@@ -776,7 +776,7 @@ static int parse_filter_spec (pfstate_t *pf)
  *		-1 = error detected
  *
  * Description:	Same function is used for all of these because they are so similar.
- *		Look for exact match to any of the specifed strings.
+ *		Look for exact match to any of the specified strings.
  *		All of them allow wildcarding with single * at the end.
  *
  *------------------------------------------------------------------------------*/
@@ -967,7 +967,7 @@ static int filt_t (pfstate_t *pf)
 	      if (strncmp(infop, ":BOM", 4) == 0) return (1);
 /*
  * Or we can have an object.
- * It's not exactly clear how to distiguish this from other objects.
+ * It's not exactly clear how to distinguish this from other objects.
  * It looks like the first 3 characters of the source should be the same
  * as the first 3 characters of the addressee.
  */
@@ -1290,7 +1290,7 @@ static int filt_s (pfstate_t *pf)
  *		-1 = error detected
  *
  * Description: Selection is based on time since last heard on RF, and distance
- *		in terms of digipeater hops and/or phyiscal location.
+ *		in terms of digipeater hops and/or physical location.
  *
  *		i/time
  *		i/time/hops
diff --git a/src/ptt.c b/src/ptt.c
index 2a943006..3780853f 100644
--- a/src/ptt.c
+++ b/src/ptt.c
@@ -126,7 +126,7 @@
 	This is documented in the User Guide, section called,
 		"Hamlib PTT Example 2: Use GPIO of USB audio adapter.  (e.g. DMK URI)"
 
-	It's rather involved and the explantion doesn't cover the case of multiple
+	It's rather involved and the explanation doesn't cover the case of multiple
 	USB-Audio adapters.  It would be nice to have a little script which lists all
 	of the USB-Audio adapters and the corresponding /dev/hidraw device.
 	( We now have it.  The included "cm108" application. )
@@ -914,7 +914,7 @@ void ptt_init (struct audio_s *audio_config_p)
 	      if (audio_config_p->achan[ch].octrl[ot].ptt_method == PTT_METHOD_LPT) {
 
 	        /* Can't open the same device more than once so we */
-	        /* need more logic to look for the case of mutiple radio */
+	        /* need more logic to look for the case of multiple radio */
 	        /* channels using different pins of the LPT port. */
 
 	        /* Did some earlier channel use the same ptt device name? */
diff --git a/src/recv.c b/src/recv.c
index f5c78167..f93f1d1e 100644
--- a/src/recv.c
+++ b/src/recv.c
@@ -42,7 +42,7 @@
  *				multi_modem_process_sample(s)
  *				
  *
- *		When a packet is succesfully decoded, somebody calls
+ *		When a packet is successfully decoded, somebody calls
  *		app_process_rec_frame, also in direwolf.c
  *
  *
diff --git a/src/server.c b/src/server.c
index 8c52b199..c6e38945 100644
--- a/src/server.c
+++ b/src/server.c
@@ -666,7 +666,7 @@ static THREAD_F connect_listen_thread (void *arg)
 #else		/* End of Windows case, now Linux */
 
 
-    	struct sockaddr_in sockaddr; /* Internet socket address stuct */
+    	struct sockaddr_in sockaddr; /* Internet socket address struct */
     	socklen_t sockaddr_size = sizeof(struct sockaddr_in);
 	int server_port = (int)(ptrdiff_t)arg;
 	int listen_sock;  
@@ -1860,7 +1860,7 @@ static THREAD_F cmd_listen_thread (void *arg)
 	          dw_printf ("AGW protocol error.  Unregister callsign for invalid channel %d.\n", chan);
 	        }
 	      }
-	      /* No reponse is expected. */
+	      /* No response is expected. */
 	      break;
 
 	    case 'C':				/* Connect, Start an AX.25 Connection  */
@@ -2065,7 +2065,7 @@ static THREAD_F cmd_listen_thread (void *arg)
 	      // Before disconnecting from another station, it would be good to know
 	      // that it actually received the last message we sent.  For this reason,
 	      // I think it would be good for this to include information frames that were 
-	      // transmitted but not yet acknowleged.
+	      // transmitted but not yet acknowledged.
 	      // You could say that a particular frame is still waiting to be sent even
 	      // if was already sent because it could be sent again if lost previously.
 
diff --git a/src/telemetry.c b/src/telemetry.c
index b71bc8d9..d4105fd3 100644
--- a/src/telemetry.c
+++ b/src/telemetry.c
@@ -69,7 +69,7 @@
 
 
 #define T_NUM_ANALOG 5				/* Number of analog channels. */
-#define T_NUM_DIGITAL 8				/* Number of digital channnels. */
+#define T_NUM_DIGITAL 8				/* Number of digital channels. */
 
 #define T_STR_LEN 16				/* Max len for labels and units. */
 
@@ -707,7 +707,7 @@ void telemetry_unit_label_message (char *station, char *msg)
  *
  * Name:        telemetry_coefficents_message
  *
- * Purpose:     Interpret message with scaling coefficents for analog channels.
+ * Purpose:     Interpret message with scaling coefficients for analog channels.
  *
  * Inputs:	station	- Name of station reporting telemetry.
  *			  In this case it is the destination for the message,
@@ -807,7 +807,7 @@ void telemetry_coefficents_message (char *station, char *msg, int quiet)
  *
  * Name:        telemetry_bit_sense_message
  *
- * Purpose:     Interpret message with scaling coefficents for analog channels.
+ * Purpose:     Interpret message with scaling coefficients for analog channels.
  *
  * Inputs:	station	- Name of station reporting telemetry.
  *			  In this case it is the destination for the message,
@@ -910,7 +910,7 @@ void telemetry_bit_sense_message (char *station, char *msg, int quiet)
  *		seq	- Sequence number.
  *		araw	- 5 analog raw values.
  *		ndp	- Number of decimal points for each.
- *		draw	- 8 digial raw vales.
+ *		draw	- 8 digital raw vales.
  *
  * Outputs:	output	- Decoded telemetry in human readable format.
  *
diff --git a/src/textcolor.c b/src/textcolor.c
index a515e2eb..dea90f09 100644
--- a/src/textcolor.c
+++ b/src/textcolor.c
@@ -349,7 +349,7 @@ void text_color_set ( enum dw_color_e c )
  *		output to stdout or other desired destination.
  *
  * Inputs:	fmt	- C language format.
- *		...	- Addtional arguments, just like printf.
+ *		...	- Additional arguments, just like printf.
  *
  *
  * Returns:	Number of characters in result.
diff --git a/src/tt_text.c b/src/tt_text.c
index 9ca7f466..d5482d74 100644
--- a/src/tt_text.c
+++ b/src/tt_text.c
@@ -382,7 +382,7 @@ int tt_text_to_two_key (const char *text, int quiet, char *buttons)
  * Outputs:	buttons	- Sequence of two buttons to press.
  *			  "00" for error because this is probably
  *			  being used to build up a fixed length
- *			  string where positions are signficant.
+ *			  string where positions are significant.
  *			  Must be at least 3 bytes.
  *
  * Returns:     Number of errors detected.
diff --git a/src/tt_user.c b/src/tt_user.c
index c0713264..2da0e846 100644
--- a/src/tt_user.c
+++ b/src/tt_user.c
@@ -230,7 +230,7 @@ void tt_user_init (struct audio_s *p_audio_config, struct tt_config_s *p_tt_conf
  * Inputs:      callsign	- full or a old style 3 DIGIT suffix abbreviation
  *		overlay
  *
- * Returns:     Handle for refering to table position or -1 if not found.
+ * Returns:     Handle for referring to table position or -1 if not found.
  *		This happens to be an index into an array but
  *		the implementation could change so the caller should
  *		not make any assumptions.
@@ -290,7 +290,7 @@ int tt_user_search (char *callsign, char overlay)
  *
  * Outputs:	callsign - corresponding full callsign or empty string.
  *
- * Returns:     Handle for refering to table position (>= 0) or -1 if not found.
+ * Returns:     Handle for referring to table position (>= 0) or -1 if not found.
  *		This happens to be an index into an array but
  *		the implementation could change so the caller should
  *		not make any assumptions.
@@ -351,7 +351,7 @@ static void clear_user(int i)
  *
  * Inputs:      none
  *
- * Returns:     Handle for refering to table position.
+ * Returns:     Handle for referring to table position.
  *
  * Description:	If table is already full, this should delete the 
  *		least recently heard user to make room.		
@@ -453,7 +453,7 @@ static void digit_suffix (char *callsign, char *suffix)
  *
  * Name:        tt_user_heard
  *
- * Purpose:     Record information from an APRStt trasmission.
+ * Purpose:     Record information from an APRStt transmission.
  *
  * Inputs:      callsign	- full or an abbreviation
  *		ssid
@@ -881,7 +881,7 @@ static void xmit_object_report (int i, int first_time)
  *	Any attached application(s).
  * 	IGate.
  *
- * When transmitting over the radio, it gets sent multipe times, to help
+ * When transmitting over the radio, it gets sent multiple times, to help
  * probablity of being heard, with increasing delays between.
  *
  * The other methods are reliable so we only want to send it once.
diff --git a/src/xid.c b/src/xid.c
index 617720c7..14e67e8d 100644
--- a/src/xid.c
+++ b/src/xid.c
@@ -92,7 +92,7 @@
 // The first byte must be of the form	1000 0xx0
 // The second byte must be of the form	1010 xx00
 // The third byte must be of the form	0000 0010
-// If we process the three byte "HDLC Optional Parmeters" like
+// If we process the three byte "HDLC Optional Parameters" like
 // the other multibyte numeric fields, with the most significant
 // byte first, we end up with bit masks like this.
 // The bit order would be  8 7 6 5 4 3 2 1   16 15 14 13 12 11 10 9   24 23 22 21 20 19 18 17
diff --git a/src/xmit.c b/src/xmit.c
index 6a725a7d..2eebe5c3 100644
--- a/src/xmit.c
+++ b/src/xmit.c
@@ -88,7 +88,7 @@
  */
 
 
-static int xmit_slottime[MAX_CHANS];	/* Slot time in 10 mS units for persistance algorithm. */
+static int xmit_slottime[MAX_CHANS];	/* Slot time in 10 mS units for persistence algorithm. */
 
 static int xmit_persist[MAX_CHANS];	/* Sets probability for transmitting after each */
 					/* slot time delay.  Transmit if a random number */
@@ -1384,7 +1384,7 @@ static void xmit_dtmf (int c, packet_t pp, int speed)
  *		New in version 1.5: full duplex.
  *		Just start transmitting rather than waiting for clear channel.
  *		This would only be appropriate when transmit and receive are
- *		using different radio freqencies.  e.g.  VHF up, UHF down satellite.
+ *		using different radio frequencies.  e.g.  VHF up, UHF down satellite.
  *
  * Transmit delay algorithm:
  *
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 6d4336e1..8e3e3753 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -205,7 +205,7 @@ if(WIN32 OR CYGWIN)
 endif()
 
 
-# Unit test for APRStt tone seqence parsing.
+# Unit test for APRStt tone sequence parsing.
 list(APPEND ttest_SOURCES
   ${CUSTOM_SRC_DIR}/aprs_tt.c
   ${CUSTOM_SRC_DIR}/tt_text.c

From d10ccb6cc0e0d3d2496eeed423a0973d12a9f704 Mon Sep 17 00:00:00 2001
From: Daniele Forsi <iu5hkx@gmail.com>
Date: Sun, 19 Sep 2021 21:15:34 +0200
Subject: [PATCH 2/3] Fix errors in strings

Errors found with codespell.
---
 src/agwlib.c      | 2 +-
 src/atest.c       | 2 +-
 src/ax25_link.c   | 4 ++--
 src/decode_aprs.c | 2 +-
 src/demod.c       | 4 ++--
 src/kissutil.c    | 4 ++--
 src/server.c      | 2 +-
 src/telemetry.c   | 4 ++--
 8 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/src/agwlib.c b/src/agwlib.c
index 337c85b6..33d490c8 100644
--- a/src/agwlib.c
+++ b/src/agwlib.c
@@ -321,7 +321,7 @@ static void * tnc_listen_thread (void *arg)
 	    s_tnc_sock = dwsock_connect (s_tnc_host, s_tnc_port, "TNC", 0, 0, tncaddr);
 
 	    if (s_tnc_sock != -1) {
-	      dw_printf ("Succesfully reattached to network TNC.\n");
+	      dw_printf ("Successfully reattached to network TNC.\n");
 
 	      // Might need to run TNC initialization again.
 	      // For example, a server would register its callsigns.
diff --git a/src/atest.c b/src/atest.c
index b7068cd8..ee914d37 100644
--- a/src/atest.c
+++ b/src/atest.c
@@ -703,7 +703,7 @@ int main (int argc, char *argv[])
 	dw_printf ("%d packets decoded in %.3f seconds.  %.1f x realtime\n", packets_decoded_total, elapsed, total_filetime/elapsed);
 	if (d_o_opt) {
 	  dw_printf ("DCD count = %d\n", dcd_count);
-	  dw_printf ("DCD missing erors = %d\n", dcd_missing_errors);
+	  dw_printf ("DCD missing errors = %d\n", dcd_missing_errors);
 	}
 
 	if (error_if_less_than != -1 && packets_decoded_total < error_if_less_than) {
diff --git a/src/ax25_link.c b/src/ax25_link.c
index c39f5ab4..988385a2 100644
--- a/src/ax25_link.c
+++ b/src/ax25_link.c
@@ -2993,7 +2993,7 @@ dw_printf ("%s:%d, %d srej exceptions, V(R)=%d, N(S)=%d\n", __func__, __LINE__,
 	      if (first == AX25MODULO(S->vr - 1, S->modulo, __FILE__, __func__, __LINE__)) {
 	        //  Oops!  Went too far.  This I frame was already processed.
 		text_color_set(DW_COLOR_ERROR);
-	        dw_printf ("INTERNAL ERROR calulating what to put in SREJ, %s line %d\n", __func__, __LINE__);
+	        dw_printf ("INTERNAL ERROR calculating what to put in SREJ, %s line %d\n", __func__, __LINE__);
 	        dw_printf ("V(R)=%d, N(S)=%d, SREJ exception=%d, first=%d, ask_resend_count=%d\n", S->vr, ns, selective_reject_exception(S), first, ask_resend_count);
 		int k;
 	        for (k=0; k<128; k++) {
@@ -3146,7 +3146,7 @@ static void send_srej_frames (ax25_dlsm_t *S, int *resend, int count, int allow_
 	if (s_debug_retry) {
 	  text_color_set(DW_COLOR_INFO);
 	  dw_printf ("%s line %d\n", __func__, __LINE__);
-	  //dw_printf ("state=%d, count=%d, k=%d, V(R)=%d, SREJ exeception=%d\n", S->state, count, S->k_maxframe, S->vr, selective_reject_exception(S));
+	  //dw_printf ("state=%d, count=%d, k=%d, V(R)=%d, SREJ exception=%d\n", S->state, count, S->k_maxframe, S->vr, selective_reject_exception(S));
 	  dw_printf ("state=%d, count=%d, k=%d, V(R)=%d\n", S->state, count, S->k_maxframe, S->vr);
 
 	  dw_printf ("resend[]=");
diff --git a/src/decode_aprs.c b/src/decode_aprs.c
index d4661e04..0b59a996 100644
--- a/src/decode_aprs.c
+++ b/src/decode_aprs.c
@@ -1566,7 +1566,7 @@ static void aprs_message (decode_aprs_t *A, unsigned char *info, int ilen, int q
 	  telemetry_unit_label_message (addressee, p->message+5);
 	}
 	else if (strncmp(p->message,"EQNS.",5) == 0) {
-	  snprintf (A->g_msg_type, sizeof(A->g_msg_type), "Telemetry Equation Coefficents Message for \"%s\"", addressee);
+	  snprintf (A->g_msg_type, sizeof(A->g_msg_type), "Telemetry Equation Coefficients Message for \"%s\"", addressee);
 	  A->g_message_subtype = message_subtype_telem_eqns;
 	  telemetry_coefficents_message (addressee, p->message+5, quiet);
 	}
diff --git a/src/demod.c b/src/demod.c
index 500cf6ce..e7df7960 100644
--- a/src/demod.c
+++ b/src/demod.c
@@ -503,8 +503,8 @@ int demod_init (struct audio_s *pa)
 
 	        text_color_set(DW_COLOR_ERROR);
 	        dw_printf ("Two incompatible versions of 2400 bps QPSK are now available.\n");
-	        dw_printf ("For compatbility with direwolf <= 1.5, use 'V26A' modem option in config file.\n");
-	        dw_printf ("For compatbility MFJ-2400 use 'V26B' modem option in config file.\n");
+	        dw_printf ("For compatibility with direwolf <= 1.5, use 'V26A' modem option in config file.\n");
+	        dw_printf ("For compatibility MFJ-2400 use 'V26B' modem option in config file.\n");
 	        dw_printf ("Command line options -j and -J can be used for channel 0.\n");
 	        dw_printf ("For more information, read the Dire Wolf User Guide and\n");
 	        dw_printf ("2400-4800-PSK-for-APRS-Packet-Radio.pdf.\n");
diff --git a/src/kissutil.c b/src/kissutil.c
index 026a6ea3..e27f4f37 100644
--- a/src/kissutil.c
+++ b/src/kissutil.c
@@ -915,7 +915,7 @@ static void usage(void)
  	dw_printf ("		a serial port.  e.g.  /dev/ttyAMA0 or COM3.\n");
  	dw_printf ("	-s	Serial port speed, default 9600.\n");
 	dw_printf ("	-v	Verbose.  Show the KISS frame contents.\n");
-	dw_printf ("	-f	Transmit files directory.  Processs and delete files here.\n");
+	dw_printf ("	-f	Transmit files directory.  Process and delete files here.\n");
 	dw_printf ("	-o	Receive output queue directory.  Store received frames here.\n");
 	dw_printf ("	-T	Precede received frames with 'strftime' format time stamp.\n");
 	usage2();
@@ -929,7 +929,7 @@ static void usage2 (void)
 	dw_printf ("Input, starting with upper case letter or digit, is assumed\n");
 	dw_printf ("to be an AX.25 frame in the usual TNC2 monitoring format.\n");
 	dw_printf ("\n");
-	dw_printf ("Input, starting with a lower case letter is a commmand.\n");
+	dw_printf ("Input, starting with a lower case letter is a command.\n");
 	dw_printf ("Whitespace, as shown in examples, is optional.\n");
 	dw_printf ("\n");
 	dw_printf ("	letter	meaning			example\n");
diff --git a/src/server.c b/src/server.c
index c6e38945..ee7f9b1c 100644
--- a/src/server.c
+++ b/src/server.c
@@ -397,7 +397,7 @@ static void debug_print (fromto_t fromto, int client, struct agwpe_s *pmsg, int
 
 	if (msg_len < 36) {
 	  text_color_set (DW_COLOR_ERROR);
-	  dw_printf ("AGWPE message length, %d, is shorter than minumum 36.\n", msg_len);
+	  dw_printf ("AGWPE message length, %d, is shorter than minimum 36.\n", msg_len);
 	}
 	if (msg_len != netle2host(pmsg->data_len_NETLE) + 36) {
 	  text_color_set (DW_COLOR_ERROR);
diff --git a/src/telemetry.c b/src/telemetry.c
index d4105fd3..2a6c690c 100644
--- a/src/telemetry.c
+++ b/src/telemetry.c
@@ -771,7 +771,7 @@ void telemetry_coefficents_message (char *station, char *msg, int quiet)
 	    else {
 	      if ( ! quiet) {
 	        text_color_set(DW_COLOR_ERROR);
-	        dw_printf ("Equation coefficent position A%d%c is empty.\n", n/3+1, n%3+'a');
+	        dw_printf ("Equation coefficient position A%d%c is empty.\n", n/3+1, n%3+'a');
 	        dw_printf ("Some applications might not handle this correctly.\n");
 	      }
 	    }
@@ -782,7 +782,7 @@ void telemetry_coefficents_message (char *station, char *msg, int quiet)
 	if (n != T_NUM_ANALOG * 3) {
 	  if ( ! quiet) {
 	    text_color_set(DW_COLOR_ERROR);
-	    dw_printf ("Found %d equation coefficents when 15 were expected.\n", n);
+	    dw_printf ("Found %d equation coefficients when 15 were expected.\n", n);
 	    dw_printf ("Some applications might not handle this correctly.\n");
 	  }
 	}

From edc5707cfe35c9cb5b7d724ce88e2664845bd1cd Mon Sep 17 00:00:00 2001
From: Daniele Forsi <iu5hkx@gmail.com>
Date: Sun, 19 Sep 2021 21:20:37 +0200
Subject: [PATCH 3/3] Fix errors in man pages

Errors found with codespell.
---
 man/kissutil.1 | 2 +-
 man/tt2text.1  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/man/kissutil.1 b/man/kissutil.1
index 09eb12c6..a7968f97 100644
--- a/man/kissutil.1
+++ b/man/kissutil.1
@@ -45,7 +45,7 @@ Example:  %H:%M:%S  for current time in hours, minutes, seconds.
 
 .TP
 .BI "-f " "xmit-directory"
-Files in this directory are transmited and deleted.
+Files in this directory are transmitted and deleted.
 Another application places a file here when it wants something to be transmitted.
 
 .TP
diff --git a/man/tt2text.1 b/man/tt2text.1
index b3c3266c..c6214c27 100644
--- a/man/tt2text.1
+++ b/man/tt2text.1
@@ -11,7 +11,7 @@ tt2text \- Convert Touch Tone sequence to text
 
 
 .SH DESCRIPTION
-\fBtt2text\fR  converts a Touch Tone squence to text.  There are two types 
+\fBtt2text\fR  converts a Touch Tone sequence to text.  There are two types
 of encoding:
 .RS
 .HP