+Log files are made exclusively in the UTF\-8 encoding. Each line in the log file
+starts with the date and time at which the entry was made \- for example:
+.IP
+Feb 27 23:24:42.509440
+.PP
+.I Sympathy
+logs a line to the file whenever the cursor leaves the line. Additionally
+.I sympathy
+.IP \(bu 3
+logs certain other events to the file:
+.IP \(bu 3
+serial port parameter changes: baud\-rate and flow control.
+.IP \(bu 3
+serial port control line state changes.
+.IP \(bu 3
+serial port line discipline errors.
+.IP \(bu 3
+serial port errors.
+.IP \(bu 3
+suggested baud rates and bit frequency analyses.
+.IP \(bu 3
+transmission of breaks.
+.IP \(bu 3
+sending of the hangup signal (dropping the DTR line).
+.IP \(bu 3
+unknown or un\-handled messages sent on the socket.
+.IP \(bu 3
+connexion and disconnexion of clients.
+.IP \(bu 3
+reception of SIGHUP.
+.IP \(bu 3
+invalid UTF-8 sequences.
+.IP \(bu 3
+terminal size changes
+.IP \(bu 3
+un\-handled terminal command sequences
+.PP
+The log file is rotated when it gets too large if the \fI\-R\fP option
+is specified, and the log file is re-opened on receipt of a \fBSIGHUP\fP
+which together with the \fB\-P\fP allows the use of of a program such
+as logrotate(8)
+.SH AUTOMATIC BAUD RATE ALGORITHM
+If
+.I sympathy
+detects a framing error on the serial port it displays the count of
+errors on the status line, and logs the error.
+.IP
+<tty reports error: \\377 \\000 \\000>
+.PP
+The count is reset to zero after ten seconds
+have elapsed during which no errors have occurred.
+.I Sympathy
+looks at bit patterns of the characters received, and
+measures the length (in units of the receiving UART's
+bit period) of any runs of '1's delimited by '0's and vice\-versa. It
+then calculates the statistics on the length of these runs, and logs these.
+.IP
+<tty_bit_analyse: 0000000001 [0,0,0,0,0,0,110,0,0,80]>
+.PP
+For a typical
+stream of ASCII data, the most common run length will be the correct bit
+period.
+.I Sympathy
+uses this together with the current bit period to calculate the most probable
+correct baud\-rate, which is displayed in the status line, and logged.
+If the correct baud\irate is higher than the current baud\-rate then the most common bit frequency will be '0' or '1' and the correct baud\-rate cannot be
+determined. In this case sympathy will display and log the message 'try higher'.
+.IP
+<tty_analyse: 80 errors, current rate 115200b, suggest 19200b>
+.PP
+The algorithm only works well if the data stream is normal. If the data stream
+is generated by the reception, at the wrong baud\-rate, of characters emitted
+by
+.I sympathy
+then the algorithm will be biased towards suggesting that the baud\-rate
+is too low. Noise on the line will also result in sympathy concluding that
+the baud\-rate is too low.
+.SH SIGNALS
+.I Sympathy
+reacts to a set of signals. You can use the \fB-P\fP option
+to easily determine the PID of the
+.I sympathy
+process to which you would like to send a signal.
+.TP 8
+.B SIGINT
+.I Sympathy
+will immediately try to restore the outer terminal emulator to its original
+state and then exit.
+.TP 8
+.B SIGHUP
+.I Sympathy
+will close and reopen the log-file specified with the -L option, which allows
+the use of programs like logrotate(8)
+.TP 8
+.B SIGWINCH
+.I Sympathy
+will redraw the display in the outer terminal emulator so that it will fit within
+the new display size.
+.TP 8
+.B SIGCHLD
+.I Sympathy
+will wait for children if some were born (for example from compressing rotated logs)