mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
accessed static
This commit is contained in:
parent
50328946a2
commit
2256d87816
1 changed files with 23 additions and 12 deletions
|
@ -85,25 +85,36 @@ myport.parm.serial.rate = 9600
|
||||||
|
|
||||||
|
|
||||||
rig = hamlib.rig_init(myrig_model)
|
rig = hamlib.rig_init(myrig_model)
|
||||||
retcode = hamlib.serial_setup(myport)
|
|
||||||
|
retcode = hamlib.rig_set_parm(rig, 'stop_bits', 5)
|
||||||
print(retcode)
|
print(retcode)
|
||||||
|
|
||||||
|
'''
|
||||||
|
parameter = create_string_buffer(16)
|
||||||
|
retcode = hamlib.rig_get_parm(rig, 0, parameter)
|
||||||
|
print(retcode)
|
||||||
|
print(bytes(parameter))
|
||||||
|
'''
|
||||||
|
|
||||||
|
|
||||||
|
# attempt to access global vars. Maybe we can access structures as well?
|
||||||
|
# https://github.com/Hamlib/Hamlib/blob/f5b229f9dc4b4364d2f40e0b0b415e92c9a371ce/src/rig.c#L95
|
||||||
|
hamlib_version = ctypes.cast(hamlib.hamlib_version, ctypes.POINTER(ctypes.c_char*21))
|
||||||
|
print(hamlib_version.contents.value)
|
||||||
|
|
||||||
|
|
||||||
|
'''
|
||||||
|
retcode = hamlib.rig_has_get_parm(rig, 7)
|
||||||
|
print(retcode)
|
||||||
|
'''
|
||||||
|
|
||||||
|
'''
|
||||||
retcode = hamlib.rig_open(rig)
|
retcode = hamlib.rig_open(rig)
|
||||||
print(retcode)
|
print(retcode)
|
||||||
|
|
||||||
|
|
||||||
hamlib.rig_close(rig)
|
hamlib.rig_close(rig)
|
||||||
|
'''
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue