icom-wlan-node 0.6.1 → 0.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -122,6 +122,17 @@ await rig.setTunerEnabled(true);
122
122
  const swr = await rig.readSWR();
123
123
  const power = await rig.readPowerLevel();
124
124
  console.log({ tuner, swr, watts: power?.watts, powerPercent: power?.percent });
125
+
126
+ // Hamlib A/B-level controls are profile-gated.
127
+ await rig.setFunction('NR', true);
128
+ await rig.setNoiseReductionEnabled(true);
129
+ await rig.setLevel('RF', 0.5);
130
+ await rig.setRitOffset(-120);
131
+ await rig.setSplitEnabled(true);
132
+ await rig.setSplitFrequency(7074000);
133
+ await rig.setTuningStep(100);
134
+ await rig.setToneFrequency(88.5);
135
+ await rig.setSpectrumSpeed('slow');
125
136
  ```
126
137
 
127
138
  Profile-specific behavior includes IC-905 6-byte frequency BCD above 5.85 GHz, model-specific scope fixed-edge ranges, and calibrated SWR/ALC/RF power/COMP/voltage/current meters. Private connector commands such as WLAN level or connector data mode are only enabled when the active profile declares the vendor extension; unsupported writes throw `UnsupportedCommandError`.
@@ -222,6 +233,10 @@ await rig.disableScope();
222
233
  - **Rig Control**: `setFrequency()`, `setMode()`, `setConnectorDataMode()`, `setConnectorWLanLevel()`
223
234
  - **Rig Query**: `readOperatingFrequency()`, `readOperatingMode()`, `readTransmitFrequency()`, `readPtt()`, `readTransceiverState()`, `readBandEdges()`
224
235
  - **Antenna Tuner**: `readTunerStatus()`, `setTunerEnabled()`, `startManualTune()`
236
+ - **Functions**: `getFunction()`, `setFunction()`, plus wrappers for NB/NR/COMP/VOX/MON/ANF/MN/LOCK/BK-IN
237
+ - **Levels**: `getLevel()`, `setLevel()`, plus wrappers for RF gain, IF shift, PBT, CW pitch, key speed, monitor gain, VOX gain
238
+ - **RIT/XIT + Split/VFO**: `getRitOffset()`, `setRitOffset()`, `getSplitEnabled()`, `setSplitFrequency()`, `getVfo()`, `setVfo()`, `vfoOperation()`
239
+ - **Tone/Tuning**: `getTuningStep()`, `setTuningStep()`, `getToneFrequency()`, `setToneFrequency()`, `getRepeaterShift()`, `setRepeaterOffset()`
225
240
  - **Meters (RX)**: `readSquelchStatus()`, `readAudioSquelch()`, `readOvfStatus()`, `getLevelMeter()`
226
241
  - **Meters (TX)**: `readSWR()`, `readALC()`, `readPowerLevel()`, `readCompLevel()`
227
242
  - **Power Supply**: `readVoltage()`, `readCurrent()`
@@ -362,6 +377,20 @@ The library exposes common CI‑V operations as friendly methods. Addresses are
362
377
  - `readTransceiverState(options?: QueryOptions) => Promise<'TX' | 'RX' | 'UNKNOWN' | null>`
363
378
  - `readBandEdges(options?: QueryOptions) => Promise<Buffer|null>`
364
379
 
380
+ #### Hamlib A/B Functions, Levels, RIT/XIT, Split, and Tone
381
+
382
+ - `getFunction(name: IcomFunctionName, options?: QueryOptions) => Promise<boolean|null>` / `setFunction(name, enabled)` — Generic Hamlib function layer for supported profile functions such as `NB`, `NR`, `COMP`, `VOX`, `MON`, `ANF`, `MN`, `LOCK`, `RIT`, `XIT`, `TUNER`, `SCOPE`, `SPECTRUM`, `SPECTRUM_HOLD`, and model-specific extensions.
383
+ - Common function wrappers: `getNoiseBlankerEnabled()/setNoiseBlankerEnabled()`, `getNoiseReductionEnabled()/setNoiseReductionEnabled()`, `getCompressorEnabled()/setCompressorEnabled()`, `getVoxEnabled()/setVoxEnabled()`, `getMonitorEnabled()/setMonitorEnabled()`, `getAutoNotchEnabled()/setAutoNotchEnabled()`, `getManualNotchEnabled()/setManualNotchEnabled()`, `getDialLockEnabled()/setDialLockEnabled()`.
384
+ - `getBreakInMode() => Promise<'off'|'semi'|'full'|null>` / `setBreakInMode(mode)` — Hamlib-aligned BK-IN control using `0x16 0x47`, where raw `1` is semi and raw `2` is full.
385
+ - `getLevel(name: IcomLevelName, options?: QueryOptions) => Promise<number|null>` / `setLevel(name, value)` — Generic level layer for `AF`, `RF`, `SQL`, `IF`, `PBT_IN`, `PBT_OUT`, `CWPITCH`, `KEYSPD`, `NOTCHF_RAW`, `COMP`, `MONITOR_GAIN`, `VOXGAIN`, `ANTIVOX`, and profile ext levels.
386
+ - Common level wrappers: `getRFGain()/setRFGain()`, `getIFShift()/setIFShift()`, `getPbtIn()/setPbtIn()`, `getPbtOut()/setPbtOut()`, `getCwPitch()/setCwPitch()`, `getKeySpeed()/setKeySpeed()`, `getNotchRaw()/setNotchRaw()`, `getCompressionLevel()/setCompressionLevel()`, `getMonitorGain()/setMonitorGain()`, `getVoxGain()/setVoxGain()`, `getAntiVox()/setAntiVox()`.
387
+ - `getRitOffset()/setRitOffset()` and `getXitOffset()/setXitOffset()` — RIT/XIT delta register using Hamlib `0x21 0x00`; `getRitEnabled()/setRitEnabled()` and `getXitEnabled()/setXitEnabled()` use `0x21 0x01/0x02`.
388
+ - `getSplitEnabled()/setSplitEnabled()`, `getSplitFrequency()/setSplitFrequency()`, `getSplitMode()/setSplitMode()` — Modern profiles use targetable TX VFO `0x25/0x26` with VFO number `1`.
389
+ - `getVfo()/setVfo()` and `vfoOperation('copy'|'exchange'|'from-vfo'|'to-vfo'|'memory-clear'|'tune')` — Safe Hamlib VFO operation subset.
390
+ - `getTuningStep()/setTuningStep(hz)` — Profile-specific Hamlib tuning step tables.
391
+ - `getToneFrequency()/setToneFrequency(hz)` and `getToneSquelchFrequency()/setToneSquelchFrequency(hz)` — CTCSS values use public Hz, encoded as tenth-Hz BCD BE.
392
+ - `getRepeaterShift()/setRepeaterShift('none'|'minus'|'plus')` and `getRepeaterOffset()/setRepeaterOffset(hz)` — Repeater offset uses public Hz, encoded as 100 Hz units.
393
+
365
394
  #### Scope / Spectrum
366
395
 
367
396
  - `scope: IcomScopeService` — Standalone scope service object that can be reused with other CI‑V transport paths in the future
@@ -379,6 +408,7 @@ The library exposes common CI‑V operations as friendly methods. Addresses are
379
408
  - `getSpectrumMode()/setSpectrumMode()` / `getSpectrumSpan()/setSpectrumSpan()` / `getSpectrumEdgeSlot()/setSpectrumEdgeSlot()` / `getSpectrumFixedEdges()/setSpectrumFixedEdges()` — Hamlib-like convenience aliases over the scope-specific methods
380
409
  - `getSpectrumDisplayState(options?: QueryOptions & { receiver?: 0 | 1 }) => Promise<IcomSpectrumDisplayState>` — Read a Hamlib-like normalized display state
381
410
  - `configureSpectrumDisplay(config?: IcomSpectrumDisplayConfig) => Promise<IcomSpectrumDisplayState>` — Apply a normalized display config covering center/fixed modes
411
+ - `getSpectrumDataOutput()/setSpectrumDataOutput()`, `getSpectrumHold()/setSpectrumHold()`, `getSpectrumSpeed()/setSpectrumSpeed()`, `getSpectrumRef()/setSpectrumRef()`, `getSpectrumAverage()/setSpectrumAverage()`, `getSpectrumVbw()/setSpectrumVbw()`, `getSpectrumRbw()/setSpectrumRbw()`, `getSpectrumDuringTx()/setSpectrumDuringTx()`, `getSpectrumCenterType()/setSpectrumCenterType()` — Advanced Hamlib spectrum controls where the active profile supports them
382
412
  - `waitForScopeFrame(options?: QueryOptions) => Promise<IcomScopeFrame | null>` — Wait for the next complete scope frame
383
413
 
384
414
  `IcomScopeFrame` shape:
@@ -433,6 +463,8 @@ Current implementation notes:
433
463
 
434
464
  **Audio Configuration**:
435
465
  - `getUsbAfLevel(options?: QueryOptions) => Promise<{ raw: number; percent: number } | null>` / `setUsbAfLevel(level: number)` — Hamlib-aligned USB AF level when the active profile declares it
466
+ - `getAudioIfMode(options?: QueryOptions) => Promise<'default'|'wlan'|'lan'|'acc'|null>` / `setAudioIfMode(source)` — Hamlib AF/IF audio routing for profile-supported WLAN/LAN/ACC parameters
467
+ - `getParameter(name, options?)` / `setParameter(name, value)` — Generic profile ext-param API for `BEEP`, `BACKLIGHT`, `SCREENSAVER`, `TIME`, `KEYERTYPE`, and `AFIF*`
436
468
  - `getConnectorWLanLevel(options?: QueryOptions) => Promise<{ raw: number; percent: number } | null>` / `setConnectorWLanLevel(level: number)` — Private `icom-wlan-node` WLAN level extension; returns `null` or throws `UnsupportedCommandError` when the active profile does not declare it
437
469
 
438
470
  #### Connector Settings
@@ -10,29 +10,101 @@ export declare const CIV: {
10
10
  readonly C_RD_MODE: 4;
11
11
  readonly C_SET_FREQ: 5;
12
12
  readonly C_SET_MODE: 6;
13
+ readonly C_SET_VFO: 7;
14
+ readonly C_WR_MEM: 9;
15
+ readonly C_MEM2VFO: 10;
16
+ readonly C_CLR_MEM: 11;
17
+ readonly C_RD_OFFS: 12;
18
+ readonly C_SET_OFFS: 13;
19
+ readonly C_CTL_SCAN: 14;
20
+ readonly C_CTL_SPLT: 15;
21
+ readonly C_SET_TS: 16;
22
+ readonly C_CTL_ATT: 17;
23
+ readonly C_CTL_ANT: 18;
24
+ readonly C_CTL_ANN: 19;
13
25
  readonly C_CTL_LVL: 20;
14
26
  readonly C_RD_SQSM: 21;
15
27
  readonly C_CTL_FUNC: 22;
28
+ readonly C_SET_TONE: 27;
16
29
  readonly C_CTL_MEM: 26;
17
30
  readonly C_CTL_PTT: 28;
31
+ readonly C_CTL_RIT: 33;
18
32
  readonly C_SEND_SEL_FREQ: 37;
19
33
  readonly C_SEND_SEL_MODE: 38;
20
34
  readonly C_CTL_SCP: 39;
35
+ readonly S_VFOA: 0;
36
+ readonly S_VFOB: 1;
37
+ readonly S_BTOA: 160;
38
+ readonly S_XCHNG: 176;
39
+ readonly S_SUBTOMAIN: 177;
40
+ readonly S_DUAL_OFF: 192;
41
+ readonly S_DUAL_ON: 193;
42
+ readonly S_DUAL: 194;
43
+ readonly S_MAIN: 208;
44
+ readonly S_SUB: 209;
45
+ readonly S_BAND_SEL: 210;
46
+ readonly S_SPLT_OFF: 0;
47
+ readonly S_SPLT_ON: 1;
48
+ readonly S_DUP_OFF: 16;
49
+ readonly S_DUP_M: 17;
50
+ readonly S_DUP_P: 18;
21
51
  readonly S_PTT: 0;
22
52
  readonly S_ANT_TUN: 1;
23
53
  readonly S_RD_TX_FREQ: 3;
54
+ readonly S_RIT_FREQ: 0;
55
+ readonly S_RIT: 1;
56
+ readonly S_XIT: 2;
24
57
  readonly S_MEM_PARM: 5;
25
58
  readonly S_MEM_DATA_MODE: 6;
59
+ readonly S_MEM_DUALMODE: 89;
60
+ readonly S_MEM_SATMODE: 90;
26
61
  readonly S_LVL_AF: 1;
27
62
  readonly S_LVL_RF: 2;
28
63
  readonly S_LVL_SQL: 3;
64
+ readonly S_LVL_IF: 4;
65
+ readonly S_LVL_APF: 5;
29
66
  readonly S_LVL_NR: 6;
67
+ readonly S_LVL_PBTIN: 7;
68
+ readonly S_LVL_PBTOUT: 8;
69
+ readonly S_LVL_CWPITCH: 9;
30
70
  readonly S_LVL_RFPOWER: 10;
31
71
  readonly S_LVL_MICGAIN: 11;
72
+ readonly S_LVL_KEYSPD: 12;
73
+ readonly S_LVL_NOTCHF: 13;
32
74
  readonly S_LVL_COMP: 14;
33
75
  readonly S_LVL_BKINDL: 15;
76
+ readonly S_LVL_BALANCE: 16;
77
+ readonly S_LVL_AGC: 17;
34
78
  readonly S_LVL_NB: 18;
35
79
  readonly S_LVL_DIGI: 19;
80
+ readonly S_LVL_DRIVE: 20;
81
+ readonly S_LVL_MON: 21;
82
+ readonly S_LVL_VOXGAIN: 22;
83
+ readonly S_LVL_ANTIVOX: 23;
84
+ readonly S_FUNC_PAMP: 2;
85
+ readonly S_FUNC_AGC: 18;
86
+ readonly S_FUNC_NB: 34;
87
+ readonly S_FUNC_APF: 50;
88
+ readonly S_FUNC_NR: 64;
89
+ readonly S_FUNC_ANF: 65;
90
+ readonly S_FUNC_TONE: 66;
91
+ readonly S_FUNC_TSQL: 67;
92
+ readonly S_FUNC_COMP: 68;
93
+ readonly S_FUNC_MON: 69;
94
+ readonly S_FUNC_VOX: 70;
95
+ readonly S_FUNC_BKIN: 71;
96
+ readonly S_FUNC_MN: 72;
97
+ readonly S_FUNC_RF: 73;
98
+ readonly S_FUNC_AFC: 74;
99
+ readonly S_FUNC_VSC: 76;
100
+ readonly S_FUNC_DIGISEL: 78;
101
+ readonly S_FUNC_DIAL_LK: 80;
102
+ readonly S_FUNC_SATM: 90;
103
+ readonly S_FUNC_IPP: 101;
104
+ readonly S_FUNC_TX_INHIBIT: 102;
105
+ readonly S_FUNC_DPP: 103;
106
+ readonly S_TONE_RPTR: 0;
107
+ readonly S_TONE_SQL: 1;
36
108
  readonly S_SQL: 1;
37
109
  readonly S_SML: 2;
38
110
  readonly S_CSQL: 5;
@@ -46,9 +118,20 @@ export declare const CIV: {
46
118
  readonly S_SCP_DAT: 0;
47
119
  readonly S_SCP_STS: 16;
48
120
  readonly S_SCP_DOP: 17;
121
+ readonly S_SCP_MSS: 18;
122
+ readonly S_SCP_SDS: 19;
49
123
  readonly S_SCP_MOD: 20;
50
124
  readonly S_SCP_SPN: 21;
51
125
  readonly S_SCP_EDG: 22;
126
+ readonly S_SCP_HLD: 23;
127
+ readonly S_SCP_ATT: 24;
128
+ readonly S_SCP_REF: 25;
129
+ readonly S_SCP_SWP: 26;
130
+ readonly S_SCP_STX: 27;
131
+ readonly S_SCP_CFQ: 28;
132
+ readonly S_SCP_VBW: 29;
52
133
  readonly S_SCP_FEF: 30;
134
+ readonly S_SCP_RBW: 31;
135
+ readonly S_SCP_MKP: 32;
53
136
  };
54
137
  export declare const ICOM_MODE_FILTER_DEFAULT: 1;
@@ -13,29 +13,101 @@ exports.CIV = {
13
13
  C_RD_MODE: 0x04,
14
14
  C_SET_FREQ: 0x05,
15
15
  C_SET_MODE: 0x06,
16
+ C_SET_VFO: 0x07,
17
+ C_WR_MEM: 0x09,
18
+ C_MEM2VFO: 0x0a,
19
+ C_CLR_MEM: 0x0b,
20
+ C_RD_OFFS: 0x0c,
21
+ C_SET_OFFS: 0x0d,
22
+ C_CTL_SCAN: 0x0e,
23
+ C_CTL_SPLT: 0x0f,
24
+ C_SET_TS: 0x10,
25
+ C_CTL_ATT: 0x11,
26
+ C_CTL_ANT: 0x12,
27
+ C_CTL_ANN: 0x13,
16
28
  C_CTL_LVL: 0x14,
17
29
  C_RD_SQSM: 0x15,
18
30
  C_CTL_FUNC: 0x16,
31
+ C_SET_TONE: 0x1b,
19
32
  C_CTL_MEM: 0x1a,
20
33
  C_CTL_PTT: 0x1c,
34
+ C_CTL_RIT: 0x21,
21
35
  C_SEND_SEL_FREQ: 0x25,
22
36
  C_SEND_SEL_MODE: 0x26,
23
37
  C_CTL_SCP: 0x27,
38
+ S_VFOA: 0x00,
39
+ S_VFOB: 0x01,
40
+ S_BTOA: 0xa0,
41
+ S_XCHNG: 0xb0,
42
+ S_SUBTOMAIN: 0xb1,
43
+ S_DUAL_OFF: 0xc0,
44
+ S_DUAL_ON: 0xc1,
45
+ S_DUAL: 0xc2,
46
+ S_MAIN: 0xd0,
47
+ S_SUB: 0xd1,
48
+ S_BAND_SEL: 0xd2,
49
+ S_SPLT_OFF: 0x00,
50
+ S_SPLT_ON: 0x01,
51
+ S_DUP_OFF: 0x10,
52
+ S_DUP_M: 0x11,
53
+ S_DUP_P: 0x12,
24
54
  S_PTT: 0x00,
25
55
  S_ANT_TUN: 0x01,
26
56
  S_RD_TX_FREQ: 0x03,
57
+ S_RIT_FREQ: 0x00,
58
+ S_RIT: 0x01,
59
+ S_XIT: 0x02,
27
60
  S_MEM_PARM: 0x05,
28
61
  S_MEM_DATA_MODE: 0x06,
62
+ S_MEM_DUALMODE: 0x59,
63
+ S_MEM_SATMODE: 0x5a,
29
64
  S_LVL_AF: 0x01,
30
65
  S_LVL_RF: 0x02,
31
66
  S_LVL_SQL: 0x03,
67
+ S_LVL_IF: 0x04,
68
+ S_LVL_APF: 0x05,
32
69
  S_LVL_NR: 0x06,
70
+ S_LVL_PBTIN: 0x07,
71
+ S_LVL_PBTOUT: 0x08,
72
+ S_LVL_CWPITCH: 0x09,
33
73
  S_LVL_RFPOWER: 0x0a,
34
74
  S_LVL_MICGAIN: 0x0b,
75
+ S_LVL_KEYSPD: 0x0c,
76
+ S_LVL_NOTCHF: 0x0d,
35
77
  S_LVL_COMP: 0x0e,
36
78
  S_LVL_BKINDL: 0x0f,
79
+ S_LVL_BALANCE: 0x10,
80
+ S_LVL_AGC: 0x11,
37
81
  S_LVL_NB: 0x12,
38
82
  S_LVL_DIGI: 0x13,
83
+ S_LVL_DRIVE: 0x14,
84
+ S_LVL_MON: 0x15,
85
+ S_LVL_VOXGAIN: 0x16,
86
+ S_LVL_ANTIVOX: 0x17,
87
+ S_FUNC_PAMP: 0x02,
88
+ S_FUNC_AGC: 0x12,
89
+ S_FUNC_NB: 0x22,
90
+ S_FUNC_APF: 0x32,
91
+ S_FUNC_NR: 0x40,
92
+ S_FUNC_ANF: 0x41,
93
+ S_FUNC_TONE: 0x42,
94
+ S_FUNC_TSQL: 0x43,
95
+ S_FUNC_COMP: 0x44,
96
+ S_FUNC_MON: 0x45,
97
+ S_FUNC_VOX: 0x46,
98
+ S_FUNC_BKIN: 0x47,
99
+ S_FUNC_MN: 0x48,
100
+ S_FUNC_RF: 0x49,
101
+ S_FUNC_AFC: 0x4a,
102
+ S_FUNC_VSC: 0x4c,
103
+ S_FUNC_DIGISEL: 0x4e,
104
+ S_FUNC_DIAL_LK: 0x50,
105
+ S_FUNC_SATM: 0x5a,
106
+ S_FUNC_IPP: 0x65,
107
+ S_FUNC_TX_INHIBIT: 0x66,
108
+ S_FUNC_DPP: 0x67,
109
+ S_TONE_RPTR: 0x00,
110
+ S_TONE_SQL: 0x01,
39
111
  S_SQL: 0x01,
40
112
  S_SML: 0x02,
41
113
  S_CSQL: 0x05,
@@ -49,9 +121,20 @@ exports.CIV = {
49
121
  S_SCP_DAT: 0x00,
50
122
  S_SCP_STS: 0x10,
51
123
  S_SCP_DOP: 0x11,
124
+ S_SCP_MSS: 0x12,
125
+ S_SCP_SDS: 0x13,
52
126
  S_SCP_MOD: 0x14,
53
127
  S_SCP_SPN: 0x15,
54
128
  S_SCP_EDG: 0x16,
129
+ S_SCP_HLD: 0x17,
130
+ S_SCP_ATT: 0x18,
131
+ S_SCP_REF: 0x19,
132
+ S_SCP_SWP: 0x1a,
133
+ S_SCP_STX: 0x1b,
134
+ S_SCP_CFQ: 0x1c,
135
+ S_SCP_VBW: 0x1d,
55
136
  S_SCP_FEF: 0x1e,
137
+ S_SCP_RBW: 0x1f,
138
+ S_SCP_MKP: 0x20,
56
139
  };
57
140
  exports.ICOM_MODE_FILTER_DEFAULT = 1;
@@ -1,4 +1,4 @@
1
- import { IcomRigOptions, RigEventEmitter, IcomMode, ConnectorDataMode, SetModeOptions, QueryOptions, SwrReading, AlcReading, WlanLevelReading, LevelMeterReading, SquelchStatusReading, AudioSquelchReading, OvfStatusReading, PowerLevelReading, CompLevelReading, VoltageReading, CurrentReading, ConnectionState, ConnectionMonitorConfig, ConnectionPhase, ConnectionMetrics, DisconnectReason, DisconnectOptions, TunerStatusReading, LevelReading, IcomScopeSpanInfo, IcomScopeMode, IcomScopeModeInfo, IcomScopeEdgeInfo, IcomScopeFixedEdgeInfo, IcomSpectrumDisplayState, IcomSpectrumDisplayConfig } from '../types';
1
+ import { IcomRigOptions, RigEventEmitter, IcomMode, ConnectorDataMode, SetModeOptions, QueryOptions, SwrReading, AlcReading, WlanLevelReading, LevelMeterReading, SquelchStatusReading, AudioSquelchReading, OvfStatusReading, PowerLevelReading, CompLevelReading, VoltageReading, CurrentReading, ConnectionState, ConnectionMonitorConfig, ConnectionPhase, ConnectionMetrics, DisconnectReason, DisconnectOptions, TunerStatusReading, LevelReading, IcomScopeSpanInfo, IcomScopeMode, IcomScopeModeInfo, IcomScopeEdgeInfo, IcomScopeFixedEdgeInfo, IcomSpectrumDisplayState, IcomSpectrumDisplayConfig, IcomFunctionName, IcomLevelName, IcomParameterName, IcomVfoName, IcomVfoOperation, IcomRepeaterShift, IcomSpectrumSpeed, IcomSpectrumCenterType, IcomAudioIfSource } from '../types';
2
2
  import { IcomCiv } from './IcomCiv';
3
3
  import { IcomAudio } from './IcomAudio';
4
4
  import { IcomScopeService } from '../scope/IcomScopeService';
@@ -397,6 +397,152 @@ export declare class IcomControl {
397
397
  * }
398
398
  */
399
399
  readCurrent(options?: QueryOptions): Promise<CurrentReading | null>;
400
+ getFunction(name: IcomFunctionName, options?: QueryOptions): Promise<boolean | null>;
401
+ setFunction(name: IcomFunctionName, enabled: boolean): void;
402
+ getLevel(name: IcomLevelName, options?: QueryOptions): Promise<number | null>;
403
+ setLevel(name: IcomLevelName, value: number): void;
404
+ getParameter(name: IcomParameterName, options?: QueryOptions): Promise<number | boolean | null>;
405
+ setParameter(name: IcomParameterName, value: number | boolean): void;
406
+ getNoiseBlankerEnabled(options?: QueryOptions): Promise<boolean | null>;
407
+ setNoiseBlankerEnabled(enabled: boolean): void;
408
+ getNoiseReductionEnabled(options?: QueryOptions): Promise<boolean | null>;
409
+ setNoiseReductionEnabled(enabled: boolean): void;
410
+ getCompressorEnabled(options?: QueryOptions): Promise<boolean | null>;
411
+ setCompressorEnabled(enabled: boolean): void;
412
+ getVoxEnabled(options?: QueryOptions): Promise<boolean | null>;
413
+ setVoxEnabled(enabled: boolean): void;
414
+ getMonitorEnabled(options?: QueryOptions): Promise<boolean | null>;
415
+ setMonitorEnabled(enabled: boolean): void;
416
+ getAutoNotchEnabled(options?: QueryOptions): Promise<boolean | null>;
417
+ setAutoNotchEnabled(enabled: boolean): void;
418
+ getManualNotchEnabled(options?: QueryOptions): Promise<boolean | null>;
419
+ setManualNotchEnabled(enabled: boolean): void;
420
+ getDialLockEnabled(options?: QueryOptions): Promise<boolean | null>;
421
+ setDialLockEnabled(enabled: boolean): void;
422
+ getBreakInMode(options?: QueryOptions): Promise<'off' | 'semi' | 'full' | null>;
423
+ setBreakInMode(mode: 'off' | 'semi' | 'full'): void;
424
+ getRFGain(options?: QueryOptions): Promise<number | null>;
425
+ setRFGain(value: number): void;
426
+ getIFShift(options?: QueryOptions): Promise<number | null>;
427
+ setIFShift(value: number): void;
428
+ getPbtIn(options?: QueryOptions): Promise<number | null>;
429
+ setPbtIn(value: number): void;
430
+ getPbtOut(options?: QueryOptions): Promise<number | null>;
431
+ setPbtOut(value: number): void;
432
+ getCwPitch(options?: QueryOptions): Promise<number | null>;
433
+ setCwPitch(hz: number): void;
434
+ getKeySpeed(options?: QueryOptions): Promise<number | null>;
435
+ setKeySpeed(wpm: number): void;
436
+ getNotchRaw(options?: QueryOptions): Promise<number | null>;
437
+ setNotchRaw(value: number): void;
438
+ getCompressionLevel(options?: QueryOptions): Promise<number | null>;
439
+ setCompressionLevel(value: number): void;
440
+ getMonitorGain(options?: QueryOptions): Promise<number | null>;
441
+ setMonitorGain(value: number): void;
442
+ getVoxGain(options?: QueryOptions): Promise<number | null>;
443
+ setVoxGain(value: number): void;
444
+ getAntiVox(options?: QueryOptions): Promise<number | null>;
445
+ setAntiVox(value: number): void;
446
+ getRitOffset(options?: QueryOptions): Promise<number | null>;
447
+ setRitOffset(offsetHz: number): void;
448
+ getXitOffset(options?: QueryOptions): Promise<number | null>;
449
+ setXitOffset(offsetHz: number): void;
450
+ getRitEnabled(options?: QueryOptions): Promise<boolean | null>;
451
+ setRitEnabled(enabled: boolean): void;
452
+ getXitEnabled(options?: QueryOptions): Promise<boolean | null>;
453
+ setXitEnabled(enabled: boolean): void;
454
+ getVfo(options?: QueryOptions): Promise<IcomVfoName | null>;
455
+ setVfo(vfo: IcomVfoName): void;
456
+ vfoOperation(op: IcomVfoOperation): void;
457
+ getSplitEnabled(options?: QueryOptions): Promise<boolean | null>;
458
+ setSplitEnabled(enabled: boolean): void;
459
+ getSplitFrequency(options?: QueryOptions): Promise<number | null>;
460
+ setSplitFrequency(hz: number): void;
461
+ getSplitMode(options?: QueryOptions): Promise<{
462
+ mode: number;
463
+ filter?: number;
464
+ modeName?: string;
465
+ filterName?: string;
466
+ dataMode?: boolean;
467
+ } | null>;
468
+ setSplitMode(mode: IcomMode | number, options?: SetModeOptions): void;
469
+ getTuningStep(options?: QueryOptions): Promise<number | null>;
470
+ setTuningStep(hz: number): void;
471
+ getRepeaterShift(options?: QueryOptions): Promise<IcomRepeaterShift | null>;
472
+ setRepeaterShift(shift: IcomRepeaterShift): void;
473
+ getRepeaterOffset(options?: QueryOptions): Promise<number | null>;
474
+ setRepeaterOffset(offsetHz: number): void;
475
+ getToneFrequency(options?: QueryOptions): Promise<number | null>;
476
+ setToneFrequency(hz: number): void;
477
+ getToneSquelchFrequency(options?: QueryOptions): Promise<number | null>;
478
+ setToneSquelchFrequency(hz: number): void;
479
+ getBeepEnabled(options?: QueryOptions): Promise<boolean | null>;
480
+ setBeepEnabled(enabled: boolean): void;
481
+ getBacklight(options?: QueryOptions): Promise<number | null>;
482
+ setBacklight(value: number): void;
483
+ getScreenSaver(options?: QueryOptions): Promise<number | null>;
484
+ setScreenSaver(value: number): void;
485
+ getKeyerType(options?: QueryOptions): Promise<number | null>;
486
+ setKeyerType(value: number): void;
487
+ getAudioIfMode(options?: QueryOptions): Promise<IcomAudioIfSource | null>;
488
+ setAudioIfMode(source: IcomAudioIfSource): void;
489
+ getSpectrumDataOutput(options?: QueryOptions): Promise<boolean | null>;
490
+ setSpectrumDataOutput(enabled: boolean): void;
491
+ getSpectrumHold(options?: QueryOptions & {
492
+ receiver?: 0 | 1;
493
+ }): Promise<boolean | null>;
494
+ setSpectrumHold(enabled: boolean, options?: {
495
+ receiver?: 0 | 1;
496
+ }): void;
497
+ getSpectrumSpeed(options?: QueryOptions & {
498
+ receiver?: 0 | 1;
499
+ }): Promise<IcomSpectrumSpeed | null>;
500
+ setSpectrumSpeed(speed: IcomSpectrumSpeed, options?: {
501
+ receiver?: 0 | 1;
502
+ }): void;
503
+ getSpectrumRef(options?: QueryOptions & {
504
+ receiver?: 0 | 1;
505
+ }): Promise<number | null>;
506
+ setSpectrumRef(db: number, options?: {
507
+ receiver?: 0 | 1;
508
+ }): void;
509
+ getSpectrumAverage(options?: QueryOptions): Promise<number | null>;
510
+ setSpectrumAverage(value: number): void;
511
+ getSpectrumVbw(options?: QueryOptions & {
512
+ receiver?: 0 | 1;
513
+ }): Promise<number | null>;
514
+ setSpectrumVbw(value: number, options?: {
515
+ receiver?: 0 | 1;
516
+ }): void;
517
+ getSpectrumRbw(options?: QueryOptions & {
518
+ receiver?: 0 | 1;
519
+ }): Promise<number | null>;
520
+ setSpectrumRbw(value: number, options?: {
521
+ receiver?: 0 | 1;
522
+ }): void;
523
+ getSpectrumDuringTx(options?: QueryOptions): Promise<boolean | null>;
524
+ setSpectrumDuringTx(enabled: boolean): void;
525
+ getSpectrumCenterType(options?: QueryOptions): Promise<IcomSpectrumCenterType | null>;
526
+ setSpectrumCenterType(type: IcomSpectrumCenterType): void;
527
+ private unsupported;
528
+ private readFunctionRaw;
529
+ private writeFunctionRaw;
530
+ private readLevelRaw;
531
+ private writeLevelRaw;
532
+ private readExtParamValue;
533
+ private writeExtParamValue;
534
+ private static encodeDataValue;
535
+ private static decodeDataValue;
536
+ private readRitOffset;
537
+ private writeRitOffset;
538
+ private vfoToSubcmd;
539
+ private readSplitRaw;
540
+ private readTone;
541
+ private writeTone;
542
+ private audioIfSourceToParameter;
543
+ private getScopeBoolean;
544
+ private getScopeByte;
545
+ private writeScopeSimple;
400
546
  private static isReplyOf;
401
547
  /**
402
548
  * Extract meter data from CI-V response frame