Wykres commitów

63 Commity (801e16ac97bb1a8596953897f52953f2cadeac6e)

Autor SHA1 Wiadomość Data
Nonoo 2deeca86dc Fix decimal separators which sscanf can't handle
This is a workaround for some apps like Gpredict, which use comma as a decimal
separator (depending on locale settings), but sscanf in Hamlib can only handle
dots.
2020-11-14 08:56:37 +01:00
Michael Black W9MDB fade1681fa Fix cppcheck errors and warnings 2020-09-02 16:56:11 -05:00
Michael Black W9MDB e459d4edc2 astyle files 2020-09-01 09:06:46 -05:00
Daniele Forsi d7b332c3f7 Fix spelling errors
Fixed using the following command:
codespell --write-changes --summary --skip=*.m4 --ignore-words-list="develope,get's,quitt,setts,som,ue,vektor"
codespell --write-changes --summary --skip=aclocal.m4,lib --ignore-words-list="develope,get's,quitt,setts,som,ue,vektor"

Codespell home page: https://github.com/codespell-project/codespell
2020-07-24 09:02:48 +02:00
Michael Black W9MDB 6f8100ffc0 Fix cppcheck warnings 2020-07-08 11:48:48 -05:00
Michael Black W9MDB 1be5c71e76 More conversions to rig_flush
https://github.com/Hamlib/Hamlib/issues/307
2020-06-23 08:39:11 -05:00
Michael Black W9MDB f71c12da94 astyle files 2020-06-09 22:37:03 -05:00
Michael Black W9MDB 17b404a6c7 Add seconds to dmmm2dec
Change meade.c to support dmmm2dec seconds
https://github.com/Hamlib/Hamlib/issues/268
2020-06-03 22:33:56 -05:00
Michael Black bda5feb1bd More cppcheck changes 2020-03-23 10:13:02 -05:00
Michael Black 98e1316f11 Fix -L printout for rotctl south_zero 2020-03-10 17:00:44 -05:00
Michael Black f46067977a Fix rotctl set_conf 2020-03-10 08:43:42 -05:00
Michael Black e704f7783c Fix rotctl state printout to show az_offset and el_offset 2020-03-10 07:07:21 -05:00
Michael Black d0f114b178 Add macro_name to caps structures for rig, rot, and amp devices 2020-03-05 23:48:14 -06:00
Michael Black ff8ddf018c astyle all C files 2020-02-23 11:26:09 -06:00
Michael Black 16f85be147
More mingw32 fixes 2020-01-15 17:05:31 -06:00
Michael Black c437bbc4d1 Fix mingw32 build 2020-01-15 16:10:35 -06:00
Michael Black 0d304ecf53 Fix mingw32 build 2020-01-15 16:06:56 -06:00
Michael Black e50f552e0f Fix mingw32 build 2020-01-15 15:57:01 -06:00
Michael Black 4be4b7033b
Clean up HAVE_LIBREADLINE mods 2020-01-15 07:04:40 -06:00
Michael Black 297bf9aa6b
Fix cppcheck warnings 2020-01-14 23:36:01 -06:00
Michael Black 4cc80fa603
Fix up some cppcheck warnings in rotctl_parse.c 2020-01-14 14:18:47 -06:00
Michael Black 4e5e533248
Fix cppcheck warnings 2019-12-24 15:48:36 -06:00
Michael Black 57952c5927
Fix cppcheck warnings in rotctl_parse.c 2019-12-24 15:12:05 -06:00
Michael Black fb73e5abd7
Fix some cppcheck warnings
Fix declarations after statements
Remove some !rig checks...we either don't need them or need them everywhere with a new error code
If you pass a NULL rig you get what you deserve :-)
2019-12-09 17:12:13 -06:00
Michael Black c9ace18daa
Fix hash sort comparison for models 2019-12-06 12:13:38 -06:00
Michael Black 60cfecd5b4
Hopefully suppress arm compilation warning 2019-12-03 16:15:33 -06:00
Michael Black a7335595de
Add az and el offset to rotctl & rotctld 2019-12-02 23:30:08 -06:00
Michael Black 6bf3b00c4f
astyle all files 2019-11-30 10:19:08 -06:00
Michael Black 2f4d62709e
Added a dummy snprintf to rig_debug to allow gcc to check format strings
This found tons of errors in rig_debug statements
So this patch cleans up all the files that were producing warnings or errors
This should fix a few segfaults when running with debug turned on
2019-11-30 10:04:31 -06:00
Michael Black 46a9fff6ad
Fix rotctl C command 2019-11-23 23:11:27 -06:00
Bill Somerville 8028663ef9
Simplify unnecessary persistence of extended response state
The \chk_vfo  command to  rigctl_parse() accepts an  extended response
prefix but  does not act  upon it, instead it  is held over  until the
next command.  This seems unnecessary  as an extended  response prefix
can just as  easily be added to the following  command if required. By
removing this  carried over  state the processing  of commands  can be
greatly simplified as per this commit.
2019-08-29 14:27:22 +01:00
Bill Somerville d931bd4e18
Move unnecessary global and file static variables to the stack 2019-08-29 00:39:39 +01:00
Michael Black 3dce8b01d1
Make rigctld thread safe for vfo_mode and ext_resp and change other globals to thread_local for future reference 2019-07-31 16:03:46 -05:00
Michael Black ab7527d95a Fix compile warning in rotctl_parse.c 2019-05-22 11:15:30 -05:00
Nate Bargmann a915f1e69e Quell clang6 warning of format string not a literal
The warning was:

  CC       rotctl_parse.o
../../hamlib/tests/rotctl_parse.c:1012:50: warning: format string is not a string literal (potentially insecure)
      [-Wformat-security]
            snprintf(cmd_name, sizeof(cmd_name), parsed_input[0] + 1);
                                                 ^~~~~~~~~~~~~~~~~~~
../../hamlib/tests/rotctl_parse.c:1012:50: note: treat the string as an argument to avoid this
            snprintf(cmd_name, sizeof(cmd_name), parsed_input[0] + 1);
                                                 ^
                                                 "%s",
1 warning generated.
2018-11-05 20:07:34 -06:00
Nate Bargmann 478a7a25c1 Merge branch 'new_man_pages' 2018-07-29 22:11:31 -05:00
Nate Bargmann f9b2f27373 Correct the -l option output header text 2018-07-29 21:38:54 -05:00
Michael Black W9MDB cd1fdfe6ce Allow rotctld to continue operationg aftr tcp or serial rig disappears 2018-05-09 07:31:42 -05:00
Michael Black W9MDB 9ba1f1a972 Fix compile warning on strings in tests 2018-04-22 18:38:16 -05:00
Nate Bargmann b692fb22ef Formatted tests/ to final coding guidelines 2017-10-06 18:58:42 -05:00
Nate Bargmann d489b8bcb5 Apply formatting to 'tests/' directory
Format per style guide.
2017-08-10 05:46:12 -05:00
Michael Black 35fda10dfd Fixed buffer overflow in rigctl_parse and rotctl_parse 2016-11-01 16:02:15 -05:00
Bill Somerville fcb93b98fa Switch to POSIXLY_CORRECT mode for getopt_long()
This  makes the  first non-option  argument end  getopt_long() parsing
stop rather  than shuffling non-option  arguments to the end.  This is
necessary  so that  rig/rotator command  language arguments  can start
with a  '-' character and  also it enables  the '-' pseudo  command to
switch to reading commands from stdin work correctly.

The change  also make checking for  the '-', switch to  stdin, command
stricter in that it must be where a command is expected and it must be
a word containing exactly a single '-' character.

Overall this allows the following styles of use:

$ rigctl R -

$ rigctl - <<EOF
>R -
>EOF

R -

$ echo "R -" | rigctl -

R -
$ rigctl -m 1 M CW -1

$ rigctl F 434000000 - <<EOF
>M FM 15000
>f m
>EOF

M FM 15000
f 145000000

m FM
15000

$

as well  as the command  line interpreter operation where  no commands
nor '-' are provided:

$ rigctl

Rig command: R -

Rig command: r
Rptr Shift: -

Rig command: f
Frequency: 145000000

Rig command: m
Mode: FM
Passband: 15000

Rig command: F 434000000

Rig command: f
Frequency: 434000000

Rig command: q

$
2016-04-19 21:52:02 -05:00
Michael Black 95a99fa37d Quell clang warnings in tests directory
Remove unnecessary parentheses in memcsv.c.

Fix cfp->u.c.combostr as old check was always true since it's statically
allocated.

RRR
Mike W9MDB
2016-02-09 11:12:28 -06:00
Bill Somerville e939279c4c Add read commands from stdin and pause command features to rotctl.
The capability to read commands from  standard input and the new pause
command allow regression tests to be written for rotctl as well as for
rigctl.
2014-05-02 19:44:29 +01:00
Nate Bargmann 245ab86441 Quell compiler warnings on Cygwin
Quell mostly harmless warnings from the older GCC installed in Cygwin.
Produces a quiet compilation.
2013-05-09 22:06:39 -05:00
Nate Bargmann e34a94ad66 rotctl_parse.c: Implement history recall
Implement first cut at storing and recalling history.  At this point
history is retained for the current session only.

History is stored as complete command lines even if values are entered
at separate prompts.  Readline allows editing and even deleting recalled
history lines.
2013-02-22 21:06:30 -06:00
Nate Bargmann e549fee11a rotctl_parse.c: Implement readline interactive mode
Initial implementation of Readline input handling.  Only if 'configure'
finds Readline will it be enabled and when enabled it will only be used
by rotctl in interactive mode.  Passing rotator commands from the rotctl
command line and rotctld use the original input handling which has not
been modified.
2013-02-22 21:06:30 -06:00
Nate Bargmann 7e9f628648 rigctld/rotctld: Remove -e|--end-marker option
Remove support for deprecated "End Marker" protocol in rigctld and
rotctld.
2013-02-05 14:40:41 -06:00
Nate Bargmann c3bc66eafc Tidy up rotctl --list output
Implemented hash table to temporarily store and sort the rot models by ID
to print the --list by model numbers.  Hash is implemented using
uthash.h, see http://uthash.sourceforge.net/

Suppressed rot backend register output by setting rig_debug_level to 0
for list output.

Removed rotlist definition of RPC backend.
2012-02-13 15:28:03 -06:00