feat: added APF for CW in Icom
This commit is contained in:
@@ -1166,6 +1166,9 @@ func (b *IcomSerial) readDSP() {
|
||||
if v, ok := b.readSwitch(civ.SubSwANF); ok {
|
||||
st.ANF = v != 0
|
||||
}
|
||||
if v, ok := b.readSwitch(civ.SubSwAPF); ok {
|
||||
st.APF = v != 0
|
||||
}
|
||||
if v, ok := b.readSwitch(civ.SubSwAGC); ok {
|
||||
st.AGC = agcName(v)
|
||||
}
|
||||
@@ -1357,6 +1360,14 @@ func (b *IcomSerial) SetANF(on bool) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (b *IcomSerial) SetAPF(on bool) error {
|
||||
if err := b.exec(civ.CmdSwitch, civ.SubSwAPF, boolByte(on)); err != nil {
|
||||
return err
|
||||
}
|
||||
b.setCache(func(s *IcomTXState) { s.APF = on })
|
||||
return nil
|
||||
}
|
||||
|
||||
func (b *IcomSerial) SetAGC(name string) error {
|
||||
v := agcValue(name)
|
||||
if v == 0 {
|
||||
|
||||
Reference in New Issue
Block a user