Wykres commitów

59 Commity (master)

Autor SHA1 Wiadomość Data
George Baltz N3GB 07f8023d17 Convert tests/* to pointers 2024-03-01 12:27:26 -05:00
Mike Black W9MDB 05033171c3 Change token_t to hamlib_token_t to avoid collsions with libbsm and others
https://github.com/Hamlib/Hamlib/issues/1469
2024-01-21 23:11:55 -06:00
Mike Black W9MDB e267c62764 astyle files 2023-12-16 11:37:58 -06:00
Mike Black W9MDB 02ffc6d6dc More set_conf/get_conf work
https://github.com/Hamlib/Hamlib/issues/971
2023-11-05 17:03:21 -06:00
Mike Black W9MDB 8d15c04727 Fix more cppcheck items 2023-10-14 12:01:41 -05:00
Mike Black W9MDB d28ce6b798 Bump up some 1024 buffers to 2048 to avoid overflow error 2023-07-21 11:46:58 -05:00
Daniele Forsi IU5HKX 3f90086991 [tests] Fix includes 2023-02-16 19:08:24 +01:00
Mike Black W9MDB a83eb3bf42 astyle files for 4.5 release 2022-07-27 17:16:17 -05:00
Mike Black W9MDB 627ec83652 Change malloc to calloc 2022-07-27 10:26:08 -05:00
Mike Black W9MDB 68e121d82c Change all to remove HAVE_CONFIG dependency and include <hamlib/config.h> by default
This is necessary to keep alignment between the client view of rig->state and the shared libarary view
Including PTHREAD functions in rig->state necessitated this as HAVE_PTHREAD only defined during hamlib compilation.
Clients including hamlib/rig.h did not pick up all the HAVE* config variable that control what gets included
https://github.com/Hamlib/Hamlib/issues/947
2022-02-04 07:41:36 -06:00
Mike Black W9MDB 63a51c36a1 astyle files preparing for 4.4 release 2021-11-28 12:41:10 -06:00
Mike Black W9MDB 12f7bb4d8f Change getnameinfo to return numeric IP instead of hostname to avoid Windows long delay on reverse lookups
https://github.com/Hamlib/Hamlib/issues/873
2021-11-20 11:52:39 -06:00
AuroraRAS 1c3250f6f4 add androidsensor rotator
The androidsensor rotator is not a real rotator, it uses the accelerometer sensor and magnetic field sensor of the cell phone or tablet to perform attitude determination for your antenna and the phone tied to it.
Now you can wave your antenna to find radio signals.

Signed-off-by: AuroraRAS <chplee@gmail.com>
2021-09-25 09:51:11 +08:00
Mike Black W9MDB fa10d10e38 Add -R --rot_file2 option to rotctl and rotctld for 2nd rotator controller for RT21
https://github.com/Hamlib/Hamlib/issues/747
2021-07-23 23:28:02 -05:00
Michael Black W9MDB 6eee309b56 Improve rig_get_version and hamlib_version2 information to include commit information
https://github.com/Hamlib/Hamlib/issues/617
2021-03-19 22:56:18 -05:00
Michael Black W9MDB 1fcb9404b9 More changes to support macro renaming 2021-03-06 14:59:57 -06: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
Michael Black W9MDB 6f8100ffc0 Fix cppcheck warnings 2020-07-08 11:48:48 -05:00
Michael Black W9MDB f454cff0b7 Add check for -s switch on all utils to ensure integer is entered 2020-07-01 08:52:44 -05:00
mdblack98 f0437aa575 Fix cppcheck warnings in rotctld.c 2020-05-05 09:26:40 -05:00
Michael Black ee87d5e6df Fix buffer overrun in all utilities
Change MAXCONFLEN to 1024 bytes for some future proofing
2020-04-01 14:51:50 -05:00
Michael Black ff8ddf018c astyle all C files 2020-02-23 11:26:09 -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 a7335595de
Add az and el offset to rotctl & rotctld 2019-12-02 23:30:08 -06:00
Michael Black dc3f33bc11
Change %z to %d with casts for portability 2019-11-30 13:05:21 -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
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 W9MDB 6c369109e6 Add debug time stamps via -Z and --debug-time-stamps 2018-04-15 15:06:52 -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
Bill Somerville 2828422e92 Stop rigctld and rotctld crashing when service threads cannot write to clients
Although there is  no reasonable recovery from SIGPIPE we  do not want
to terminate the server process,  just the client servicing thread. We
do this by setting the disposition for SIGPIPE to ignored, this causes
an EPIPE to be returned from blocked write() and send() calls that end
up trying to send to a broken pipe/socket.
2017-05-22 21:56:41 -05:00
Nate Bargmann 4595f77f99 Touch up rigctld.c and rotctld.c with astyle
Prior reformat had only been a reindent with Emacs.  Now use astyle.
2016-02-14 18:05:55 -06:00
Nate Bargmann 9b45fce776 Reformat rigctld.c and rotctld.c
Several lines in each file benefitted from formatting so just reformat
the entire files into Linux C Style.
2016-02-12 20:46:38 -06:00
Bill Somerville e4e17ce862 Improve IPv6 portability and consistency
After  discussions with  Greg  N1DAM  I have  changed  the dual  stack
support to  explicitly allow IPv4  connections mapped to IPv6  for any
AF_INET6 address  since BSD  as well as  Windows defaults  this socket
option to on (disallowed).

IPv4 mapped to IPv6 makes sense  for Hamlib servers since starting two
servers  one  for each  protocol  family  (the  other option)  is  not
possible  since there  is only  a single  rig/rotator which  cannot be
shared between two servers.
2016-02-12 20:20:25 -06:00
Bill Somerville 04c545b9b9 Only use IPv6 features on Windows versions that support it (>=XP) 2016-02-12 15:30:41 +00:00
Bill Somerville 6061cae8df Proper IPv6 and dual stack networking for rotator net daemon
This means that rigctl & rigctld  now work with default arguments on a
modern Windows  machine with dual  stack and localhost being  [::1] as
the first interface returned by getaddrinfo().

Try all the interfaces return by DNS lookups to establish a connection
or listening  port. Handle  Windows network  errors correctly  so that
meaningful messages are printed.

The rigctl program now accepts  IPv6 numeric addresses in the portname
field like [<addr>}:<port> for example  the IPv6 loopback on port 4531
would be [::1]:4531.
2015-11-27 19:41:04 +00:00
Nate Bargmann 36f5f4cf6a Revert to previous handling of getaddrinfo()
Use the system gettaddrinfo function when possible as before.  Tested on
GNU, Cygwin, MinGW on Linux, and MinGW on Windows.  Under MinGW the
replacement getaddrinfo is used.  Perhaps this is an area for
investigation to be certain MinGW really doesn't supply getaddrinfo.
This reverts some of the patches from Remi Chateauneu in commit
60019c9.  This fixes build issues encountered building the Windows
binary daily snapshots.

Enabled static library build by default at configure time.

Fixed pthread library linking for the ars backend on MinGW.
2013-09-15 19:47:49 -05:00
Remi Chateauneu 60019c9444 Monolitic libraries. 2013-09-08 14:56:28 +01:00
Nate Bargmann b9ff04abf0 Fix W2k 'freeaddrinfo' error
Trying to run the pthread enabled binaries on W2k resulted in an error
dialog with the text, "The procedure entry point freeaddrinfo could not be
located in ws2_32.dll".  A Microsoft support page
(http://support.microsoft.com/kb/955045) hints that when 'ws2tcpip.h' is
included that 'wspiapi.h' should be included as well.  Since MinGw
includes both files, this patch corrects the runtime error on W2k
2013-05-18 07:31:40 -05: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 1229a0a42a Assure NULL terminated strings in tests programs.
Various strncpy operations could result in a port pathname that is not a
NULL terminated string as the allowed string length is the same size as
the buffer per the strncpy manual page.  This is corrected by assuring
that the allowed length is FILPATHLEN - 1.
2012-01-07 20:36:50 -06:00
Nate Bargmann 0882cd696d Update GPL/LGPL header in tests source files.
TNX to Lucian Laga, YO6PLB, for the notification.
2011-08-22 21:38:37 -05:00
Stephane Fillod 07bc66e7ab Port rigctld/rotctld to Mingw32
Sockets under Windows require specific startup and cleanup calls.
Besides, the standard fdopen() does no work on socket descriptors,
and has to be worked around thanks to _open_osfhandle().
2011-03-27 19:13:22 +02:00
Stéphane Fillod, F8CFE 8690fb0594 Implement exit status according to manual page:
1 if there was an invalid command line option or argument;
  2 if an error was returned by Hamlib.


git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@3009 7ae35d74-ebe9-4afe-98af-79ac388436b8
2010-12-01 21:41:55 +00:00
Stéphane Fillod, F8CFE 6ee58f0bff get ready for IPv6
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@2883 7ae35d74-ebe9-4afe-98af-79ac388436b8
2010-04-16 20:50:14 +00:00
Stéphane Fillod, F8CFE 5be226561b fix mixup
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@2844 7ae35d74-ebe9-4afe-98af-79ac388436b8
2010-03-03 08:34:00 +00:00