kopia lustrzana https://github.com/Hamlib/Hamlib
Implement Amp.get_powerstat
rodzic
81d7745411
commit
6e8b5d602f
|
@ -133,6 +133,8 @@ typedef struct Amp {
|
|||
return s;
|
||||
}
|
||||
|
||||
AMPMETHOD1GET(get_powerstat, powerstat_t)
|
||||
|
||||
};
|
||||
%{
|
||||
|
||||
|
@ -140,8 +142,4 @@ typedef struct Amp {
|
|||
{
|
||||
self->error_status = amp_get_freq(self->amp, freq);
|
||||
}
|
||||
void Amp_get_powerstat(Amp *self, powerstat_t *status)
|
||||
{
|
||||
self->error_status = amp_get_powerstat(self->amp, status);
|
||||
}
|
||||
%}
|
||||
|
|
|
@ -47,8 +47,8 @@ class TestClass:
|
|||
assert amp.reset(Hamlib.AMP_RESET_FAULT) is None
|
||||
assert amp.set_freq(0) is None
|
||||
# assert amp.get_freq() is None # FIXME: AttributeError: 'Amp' object has no attribute 'get_freq'
|
||||
assert amp.set_powerstat(Hamlib.RIG_POWER_OFF) is None
|
||||
# assert amp.get_powerstat() is None # FIXME: AttributeError: 'Amp' object has no attribute 'get_powerstat'
|
||||
assert amp.set_powerstat(Hamlib.RIG_POWER_ON) is None
|
||||
assert amp.get_powerstat() == Hamlib.RIG_POWER_ON
|
||||
assert amp.close() is None
|
||||
assert amp.state.comm_state == 0
|
||||
info = amp.get_info()
|
||||
|
|
Ładowanie…
Reference in New Issue