Wykres commitów

18 Commity (68e121d82c8000d60075c51a9e1f115772ad0620)

Autor SHA1 Wiadomość Data
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
Michael Black 3503d5e603 Add amplifier.swg to bindings 2020-03-14 08:46:28 -05:00
Michael Black e51f16d7e7 Cleanup Java warning in SWIG files
Comment out misc.h in hamlib.swg
2020-03-13 23:40:32 -05:00
Bill Somerville df4ec51909 Simplify SWIG interface definition and hide 64-bit values from Lua binding
By  including the  stdint  SWIG  typemaps we  can  directly use  types
derived from [u]int64_t etc.

Because Lua numbers are  implemented using a double-precision floating
point type and  also because SWIG when generating a  Lua wrappings can
only define  constants from #define and  enum values that fit  into an
'int' type we  must hide any constants that require  more than 32-bits
to represent themselves,  as they cannot be represented  in Lua.  This
applies  to  rmode_t  and  the  RIG_FUNC... defines  at  the  time  of
writing. By  hiding them from  the Lua binding  they will get  a 'nil'
value in Lua i.e. undefined so clients using the Lua binding will know
they are  not there.  This is  a nasty hack  but without  major design
changes to the Hamlib API it is do this or drop the Lua binding.
2018-12-28 20:33:30 +00:00
Ervin Hegedus 2b657e7c9d Added Lua binding and demo script 2016-12-13 16:28:41 -06:00
Hegedüs Ervin 37cac121f4 Fixed int[10] type variable error in bindings 2016-08-27 21:24:17 +02:00
Hegedüs Ervin cef8c2d157 Leave off multiply 'typedef const char * const_char_string' definition (in rig.swg and rotator.swg) 2016-05-20 22:46:23 +02:00
Hegedüs Ervin c7476de364 Check SWIG string functions for some languages 2016-05-20 22:08:10 +02:00
Ervin Hegedus 8c4bb72b99 Fixed SWIG `Setting a const char * variable may leak memory' error 2014-02-03 22:38:48 +01:00
Ervin Hegedüs d9fc9c04d7 rig.swg: New properly formatted macro
I made a patch, you can see in that there is the solution, which
describe the error: if a function in hamlib looks 3 argument
(rig, vfo, any 3rd arg), the order of the 2nd and 3rd argument
were reversed, because the macro METHOD1 reversed them.

I've collected these functions, compared its arguments with
hamlib docs (http://hamlib.sourceforge.net/manuals/1.2.15/), and
where 1st arg is rig, 2nd arg is vfo, and 3rd is any kind of
type, changed to METHOD3, which is a new macro, and keeps the
correct order of original function - see the patch. (I didn't
find any info about the expected diff format, so I just created
the `diff -uprN ORIG NEW'.)

To check my theory, I've tested with another function, which uses
vfo type at 2nd argument, eg. rig_set_freq; here is the Python
code:

  my_rig.set_freq(Hamlib.RIG_VFO_A, 7013200.0)

and the original code drop the exception:

    my_rig.set_freq(Hamlib.RIG_VFO_A, 7012500.0)
  File "/usr/local/lib/python2.7/dist-packages/Hamlib.py", line 2513, in
set_freq
    def set_freq(self, *args): return _Hamlib.Rig_set_freq(self, *args)
TypeError: in method 'Rig_set_freq', argument 3 of type 'vfo_t'

As you can see, it's same as my original error above.

So, after I patched the source and recompiled it again, these two
function works correctly - I will test it at soon, but I think
_this_ is good and stable.

Signed-off-by: Nate Bargmann <n0nb@n0nb.us>
2013-02-12 18:35:03 -06:00
Stephane Fillod 443cf020e4 add rig_debug() in python binding 2011-09-14 22:43:06 +02:00
Nate Bargmann a7f758d582 Update LGPL header in bindings source files.
TNX to Lucian Laga, YO6PLB, for the notification.
2011-08-22 21:38:34 -05:00
Stéphane Fillod, F8CFE 42143f1976 make locator/qrb/longlat functions to work from bindings
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@2351 7ae35d74-ebe9-4afe-98af-79ac388436b8
2008-05-04 21:38:25 +00:00
Stéphane Fillod, F8CFE 2ebb2a80e8 hamlib -> Hamlib
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@1431 7ae35d74-ebe9-4afe-98af-79ac388436b8
2003-04-06 18:52:16 +00:00
Stéphane Fillod, F8CFE 0780ba058e added intial channel support
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@1209 7ae35d74-ebe9-4afe-98af-79ac388436b8
2002-10-08 21:54:58 +00:00
Stéphane Fillod, F8CFE 03160aa72f more work on swig bindings, nearly every calls supported, some chan wrapping missing, and also lists
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@1200 7ae35d74-ebe9-4afe-98af-79ac388436b8
2002-10-07 21:44:51 +00:00
Stéphane Fillod, F8CFE cbfbe9d64a added error checking through exception
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@1179 7ae35d74-ebe9-4afe-98af-79ac388436b8
2002-09-16 06:50:13 +00:00
Stéphane Fillod, F8CFE dee8c252f4 Initial release
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@1165 7ae35d74-ebe9-4afe-98af-79ac388436b8
2002-09-08 22:31:01 +00:00