1RIGCTL(1) Hamlib Utilities RIGCTL(1)
2
3
4
6 rigctl - control radio transceivers and receivers
7
9 rigctl [-hiIlLnouV] [-m id] [-r device] [-p device] [-d device]
10 [-P type] [-D type] [-s baud] [-c id] [-t char] [-C parm=val]
11 [-v[-Z]] [command|-]
12
14 Control radio transceivers and receivers. rigctl accepts commands from
15 the command line as well as in interactive mode if none are provided on
16 the command line.
17
18 Keep in mind that Hamlib is BETA level software. While a lot of back‐
19 end libraries lack complete rig support, the basic functions are usu‐
20 ally well supported.
21
22 Please report bugs and provide feedback at the e-mail address given in
23 the BUGS section below. Patches and code enhancements sent to the same
24 address are welcome.
25
27 This program follows the usual GNU command line syntax. Short options
28 that take an argument may have the value follow immediately or be sepa‐
29 rated by a space. Long options starting with two dashes (‘-’) require
30 an ‘=’ between the option and any argument.
31
32 Here is a summary of the supported options:
33
34 -m, --model=id
35 Select radio model number.
36
37 See model list (use “rigctl -l”).
38
39 Note: rigctl (or third party software using the C API) will use
40 radio model 2 for NET rigctl (communicating with rigctld).
41
42 -r, --rig-file=device
43 Use device as the file name of the port connected to the radio.
44
45 Often a serial port, but could be a USB to serial adapter. Typ‐
46 ically /dev/ttyS0, /dev/ttyS1, /dev/ttyUSB0, etc. on Linux,
47 COM1, COM2, etc. on MS Windows. The BSD flavors and Mac OS/X
48 have their own designations. See your system's documentation.
49
50 The special string “uh-rig” may be given to enable micro-ham
51 device support.
52
53 -p, --ptt-file=device
54 Use device as the file name of the Push-To-Talk device using a
55 device file as described above.
56
57 -d, --dcd-file=device
58 Use device as the file name of the Data Carrier Detect device
59 using a device file as described above.
60
61 -P, --ptt-type=type
62 Use type of Push-To-Talk device.
63
64 Supported types are ‘RIG’ (CAT command), ‘DTR’, ‘RTS’, ‘PARAL‐
65 LEL’, ‘CM108’, ‘GPIO’, ‘GPION’, ‘NONE’, overriding PTT type
66 defined in the rig's backend.
67
68 Some side effects of this command are that when type is set to
69 DTR, read PTT state comes from the Hamlib frontend, not read
70 from the radio. When set to NONE, PTT state cannot be read or
71 set even if rig backend supports reading/setting PTT status from
72 the rig.
73
74 -D, --dcd-type=type
75 Use type of Data Carrier Detect device.
76
77 Supported types are ‘RIG’ (CAT command), ‘DSR’, ‘CTS’, ‘CD’,
78 ‘PARALLEL’, ‘CM108’, ‘GPIO’, ‘GPION’, ‘NONE’.
79
80 -s, --serial-speed=baud
81 Set serial speed to baud rate.
82
83 Uses maximum serial speed from radio backend capabilities (set
84 by -m above) as the default.
85
86 -c, --civaddr=id
87 Use id as the CI-V address to communicate with the rig.
88
89 Only useful for Icom and some Ten-Tec rigs.
90
91 Note: The id is in decimal notation, unless prefixed by 0x, in
92 which case it is hexadecimal.
93
94 -t, --send-cmd-term=char
95 Change the termination char for text protocol when using the
96 send_cmd command.
97
98 The default value is ASCII CR (‘0x0D’). ASCII non-printing
99 characters can be given as the ASCII number in hexadecimal for‐
100 mat prepended with “0x”. You may pass an empty string for no
101 termination char. The string “-1” tells rigctl to switch to
102 binary protocol. See the send_cmd command for further explana‐
103 tion.
104
105 For example, to specify a command terminator for Kenwood style
106 text commands pass “-t ';'” to rigctl. See EXAMPLE below.
107
108 -L, --show-conf
109 List all config parameters for the radio defined with -m above.
110
111 -C, --set-conf=parm=val[,parm=val]
112 Set radio configuration parameter(s), e.g. stop_bits=2.
113
114 Use the -L option above for a list of configuration parameters
115 for a given model number.
116
117 -u, --dump-caps
118 Dump capabilities for the radio defined with -m above and exit.
119
120 -l, --list
121 List all model numbers defined in Hamlib and exit.
122
123 The list is sorted by model number.
124
125 Note: In Linux the list can be scrolled back using Shift-
126 PageUp/Shift-PageDown, or using the scrollbars of a virtual ter‐
127 minal in X or the cmd window in Windows. The output can be
128 piped to more(1) or less(1), e.g. “rigctl -l | more”.
129
130 -o, --vfo
131 Enable vfo mode.
132
133 An extra VFO argument will be required in front of each appro‐
134 priate command (except set_vfo). Otherwise, ‘currVFO’ is used
135 when this option is not set and an extra VFO argument is not
136 used.
137
138 -n, --no-restore-ai
139 On exit rigctl restores the state of auto information (AI) on
140 the controlled rig.
141
142 If this is not desired, for example if you are using rigctl to
143 turn AI mode on or off, pass this option.
144
145 -i, --read-history
146 Read previously saved command and argument history from a file
147 (default $HOME/.rigctl_history) for the current session.
148
149 Available when rigctl is built with Readline support (see READ‐
150 LINE below).
151
152 Note: To read a history file stored in another directory, set
153 the RIGCTL_HIST_DIR environment variable, e.g.
154 “RIGCTL_HIST_DIR=~/tmp rigctl -i”. When RIGCTL_HIST_DIR is not
155 set, the value of HOME is used.
156
157 -I, --save-history
158 Write current session (and previous session(s), if -i option is
159 given) command and argument history to a file (default
160 $HOME/.rigctl_history) at the end of the current session.
161
162 Complete commands with arguments are saved as a single line to
163 be recalled and used or edited. Available when rigctl is built
164 with Readline support (see READLINE below).
165
166 Note: To write a history file in another directory, set the
167 RIGCTL_HIST_DIR environment variable, e.g.
168 “RIGCTL_HIST_DIR=~/tmp rigctl -IRq. When RIGCTL_HIST_DIR is not
169 set, the value of HOME is used.
170
171 -v, --verbose
172 Set verbose mode, cumulative (see DIAGNOSTICS below).
173
174 -Z, --debug-time-stamps
175 Enable time stamps for the debug messages.
176
177 Use only in combination with the -v option as it generates no
178 output on its own.
179
180 -h, --help
181 Show a summary of these options and exit.
182
183 -V, --version
184 Show version of rigctl and exit.
185
186 - Stop option processing and read commands from standard input.
187
188 See Standard Input below.
189
190 Note: Some options may not be implemented by a given backend and will
191 return an error. This is most likely to occur with the --set-conf and
192 --show-conf options.
193
194 Please note that the backend for the radio to be controlled, or the
195 radio itself may not support some commands. In that case, the opera‐
196 tion will fail with a Hamlib error code.
197
199 Commands can be entered either as a single char, or as a long command
200 name. The commands are not prefixed with a dash as the options are.
201 They may be typed in when in interactive mode or provided as argu‐
202 ment(s) in command line interface mode. In interactive mode commands
203 and their arguments may be entered on a single line:
204
205 M LSB 2400
206
207 Since most of the Hamlib operations have a set and a get method, an
208 upper case letter will often be used for a set method whereas the cor‐
209 responding lower case letter refers to the get method. Each operation
210 also has a long name; in interactive mode, prepend a backslash, ‘\’, to
211 enter a long command name.
212
213 Example: Use “\dump_caps” to see what capabilities this radio and back‐
214 end support.
215
216 Note: The backend for the radio to be controlled, or the radio itself
217 may not support some commands. In that case, the operation will fail
218 with a Hamlib error message.
219
220 Standard Input
221 As an alternative to the READLINE interactive command entry or a single
222 command for each run, rigctl features a special option where a single
223 dash (‘-’) may be used to read commands from standard input (stdin).
224 Commands must be separated by whitespace similar to the commands given
225 on the command line. Comments may be added using the ‘#’ character,
226 all text up until the end of the current line including the ‘#’ charac‐
227 ter is ignored.
228
229 A simple example:
230
231 $ cat <<.EOF. >cmds.txt
232 > # File of commands
233 > v f m # query rig
234 > V VFOB F 14200000 M CW 500 # set rig
235 > v f m # query rig
236 > .EOF.
237
238 $ rigctl -m1 - <cmds.txt
239
240 v VFOA
241
242 f 145000000
243
244 m FM
245 15000
246
247 V VFOB
248 F 14200000
249 M CW 500
250 v VFOB
251
252 f 14200000
253
254 m CW
255 500
256
257 $
258
259 rigctl Commands
260 A summary of commands is included below (In the case of set commands
261 the quoted italicized string is replaced by the value in the descrip‐
262 tion. In the case of get commands the quoted italicized string is the
263 key name of the value returned.):
264
265 Q|q, exit rigctl
266 Exit rigctl in interactive mode.
267
268 When rigctl is controlling the rig directly, will close the rig
269 backend and port. When rigctl is connected to rigctld (radio
270 model 2), the TCP/IP connection to rigctld is closed and rigctld
271 remains running, available for another TCP/IP network connec‐
272 tion.
273
274 F, set_freq 'Frequency'
275 Set 'Frequency', in Hz.
276
277 Frequency may be a floating point or integer value.
278
279 f, get_freq
280 Get 'Frequency', in Hz.
281
282 Returns an integer value and the VFO hamlib thinks is active.
283 Note that some rigs (e.g. all Icoms) cannot track current VFO so
284 hamlib can get out of sync with the rig if the user presses rig
285 buttons like the VFO.
286
287 M, set_mode 'Mode' 'Passband'
288 Set 'Mode' and 'Passband'.
289
290 Mode is a token: ‘USB’, ‘LSB’, ‘CW’, ‘CWR’, ‘RTTY’, ‘RTTYR’,
291 ‘AM’, ‘FM’, ‘WFM’, ‘AMS’, ‘PKTLSB’, ‘PKTUSB’, ‘PKTFM’,
292 ‘ECSSUSB’, ‘ECSSLSB’, ‘FA’, ‘SAM’, ‘SAL’, ‘SAH’, ‘DSB’.
293
294 Passband is in Hz as an integer, or ‘0’ for the radio backend
295 default.
296
297 Note: Passing a ‘?’ (query) as the first argument instead of a
298 Mode token will return a space separated list of radio backend
299 supported Modes. Use this to determine the supported Modes of a
300 given radio backend.
301
302 m, get_mode
303 Get 'Mode' and 'Passband'.
304
305 Returns Mode as a token and Passband in Hz as in set_mode above.
306
307 V, set_vfo 'VFO'
308 Set 'VFO'.
309
310 VFO is a token: ‘VFOA’, ‘VFOB’, ‘VFOC’, ‘currVFO’, ‘VFO’, ‘MEM’,
311 ‘Main’, ‘Sub’, ‘TX’, ‘RX’.
312
313 In VFO mode (see --vfo option above) only a single VFO parameter
314 is required:
315
316 $ rigctl -m 229 -r /dev/rig -o
317
318 Rig command: V
319 VFO: VFOB
320
321 Rig command:
322
323 v, get_vfo
324 Get current 'VFO'.
325
326 Returns VFO as a token as in set_vfo above.
327
328 J, set_rit 'RIT'
329 Set 'RIT'.
330
331 RIT is in Hz and can be + or -. A value of ‘0’ resets RIT
332 (Receiver Incremental Tuning) to match the VFO frequency.
333
334 Note: RIT needs to be explicitly activated or deactivated with
335 the set_func command. This allows setting the RIT offset inde‐
336 pendently of its activation and allows RIT to remain active
337 while setting the offset to ‘0’.
338
339 j, get_rit
340 Get 'RIT' in Hz.
341
342 Returned value is an integer.
343
344 Z, set_xit 'XIT'
345 Set 'XIT'.
346
347 XIT is in Hz and can be + or -. A value of ‘0’ resets XIT
348 (Transmitter Incremental Tuning) to match the VFO frequency.
349
350 Note: XIT needs to be explicitly activated or deactivated with
351 the set_func command. This allows setting the XIT offset inde‐
352 pendently of its activation and allows XIT to remain active
353 while setting the offset to ‘0’.
354
355 z, get_xit
356 Get 'XIT' in Hz.
357
358 Returned value is an integer.
359
360 T, set_ptt 'PTT'
361 Set 'PTT'.
362
363 PTT is a value: ‘0’ (RX), ‘1’ (TX), ‘2’ (TX mic), or ‘3’ (TX
364 data).
365
366 t, get_ptt
367 Get 'PTT' status.
368
369 Returns PTT as a value in set_ptt above.
370
371 S, set_split_vfo 'Split' 'TX VFO'
372 Set 'Split' mode.
373
374 Split is either ‘0’ = Normal or ‘1’ = Split.
375
376 Set 'TX VFO'.
377
378 TX VFO is a token: ‘VFOA’, ‘VFOB’, ‘VFOC’, ‘currVFO’, ‘VFO’,
379 ‘MEM’, ‘Main’, ‘Sub’, ‘TX’, ‘RX’.
380
381 s, get_split_vfo
382 Get 'Split' mode.
383
384 Split is either ‘0’ = Normal or ‘1’ = Split.
385
386 Get 'TX VFO'.
387
388 TX VFO is a token as in set_split_vfo above.
389
390 I, set_split_freq 'Tx Frequency'
391 Set 'TX Frequency', in Hz.
392
393 Frequency may be a floating point or integer value.
394
395 i, get_split_freq
396 Get 'TX Frequency', in Hz.
397
398 Returns an integer value.
399
400 X, set_split_mode 'TX Mode' 'TX Passband'
401 Set 'TX Mode' and 'TX Passband'.
402
403 TX Mode is a token: ‘USB’, ‘LSB’, ‘CW’, ‘CWR’, ‘RTTY’, ‘RTTYR’,
404 ‘AM’, ‘FM’, ‘WFM’, ‘AMS’, ‘PKTLSB’, ‘PKTUSB’, ‘PKTFM’,
405 ‘ECSSUSB’, ‘ECSSLSB’, ‘FA’, ‘SAM’, ‘SAL’, ‘SAH’, ‘DSB’.
406
407 TX Passband is in Hz as an integer, or ‘0’ for the radio backend
408 default.
409
410 Note: Passing a ‘?’ (query) as the first argument instead of a
411 TX Mode token will return a space separated list of radio back‐
412 end supported TX Modes. Use this to determine the supported TX
413 Modes of a given radio backend.
414
415 x, get_split_mode
416 Get 'TX Mode' and 'TX Passband'.
417
418 Returns TX Mode as a token and TX Passband in Hz as in
419 set_split_mode above.
420
421 Y, set_ant 'Antenna' 'Option'
422 Set 'Antenna' and 'Option'.
423
424 Number is 1-based antenna# (‘1’, ‘2’, ‘3’, ...).
425
426 Option depends on rig..for Icom it probably sets the RX only
427 flag. See your manual for specific option values.
428
429 y, get_ant 'Antenna'
430 Get 'Antenna'
431
432 A value of 0 for Antenna will return the current TX antenna
433
434 > 0 is 1-based antenna# (‘1’, ‘2’, ‘3’, ...).
435
436
437
438 Option returned depends on rig..for Icom is likely the RX only
439 flag.
440
441 b, send_morse 'Morse'
442 Send 'Morse' symbols.
443
444 0x8b, get_dcd
445 Get 'DCD' (squelch) status: ‘0’ (Closed) or ‘1’ (Open).
446
447 R, set_rptr_shift 'Rptr Shift'
448 Set 'Rptr Shift'.
449
450 Rptr Shift is one of: ‘+’, ‘-’, or something else for ‘None’.
451
452 r, get_rptr_shift
453 Get 'Rptr Shift'.
454
455 Returns ‘+’, ‘-’, or ‘None’.
456
457 O, set_rptr_offs 'Rptr Offset'
458 Set 'Rptr Offset', in Hz.
459
460 o, get_rptr_offs
461 Get 'Rptr Offset', in Hz.
462
463 C, set_ctcss_tone 'CTCSS Tone'
464 Set 'CTCSS Tone', in tenths of Hz.
465
466 c, get_ctcss_tone
467 Get 'CTCSS Tone', in tenths of Hz.
468
469 D, set_dcs_code 'DCS Code'
470 Set 'DCS Code'.
471
472 d, get_dcs_code
473 Get 'DCS Code'.
474
475 0x90, set_ctcss_sql 'CTCSS Sql'
476 Set 'CTCSS Sql' tone, in tenths of Hz.
477
478 0x91, get_ctcss_sql
479 Get 'CTCSS Sql' tone, in tenths of Hz.
480
481 0x92, set_dcs_sql 'DCS Sql'
482 Set 'DCS Sql' code.
483
484 0x93, get_dcs_sql
485 Get 'DCS Sql'
486 code.
487
488 N, set_ts 'Tuning Step'
489 Set 'Tuning Step', in Hz.
490
491 n, get_ts
492 Get 'Tuning Step', in Hz.
493
494 U, set_func 'Func' 'Func Status'
495 Set 'Func' and 'Func Status'.
496
497 Func is a token: ‘FAGC’, ‘NB’, ‘COMP’, ‘VOX’, ‘TONE’, ‘TSQL’,
498 ‘SBKIN’, ‘FBKIN’, ‘ANF’, ‘NR’, ‘AIP’, ‘APF’, ‘MON’, ‘MN’, ‘RF’,
499 ‘ARO’, ‘LOCK’, ‘MUTE’, ‘VSC’, ‘REV’, ‘SQL’, ‘ABM’, ‘BC’, ‘MBC’,
500 ‘RIT’, ‘AFC’, ‘SATMODE’, ‘SCOPE’, ‘RESUME’, ‘TBURST’, ‘TUNER’,
501 ‘XIT’.
502
503 Func Status is a non null value for “activate” or “de-activate”
504 otherwise, much as TRUE/FALSE definitions in the C language
505 (true is non-zero and false is zero, ‘0’).
506
507 Note: Passing a ‘?’ (query) as the first argument instead of a
508 Func token will return a space separated list of radio backend
509 supported set function tokens. Use this to determine the sup‐
510 ported functions of a given radio backend.
511
512 u, get_func 'Func'
513 Get 'Func Status'.
514
515 Returns Func Status as a non null value for the Func token given
516 as in set_func above.
517
518 Note: Passing a ‘?’ (query) as the first argument instead of a
519 Func token will return a space separated list of radio backend
520 supported get function tokens. Use this to determine the sup‐
521 ported functions of a given radio backend.
522
523 L, set_level 'Level' 'Level Value'
524 Set 'Level' and 'Level Value'.
525
526 Level is a token: ‘PREAMP’, ‘ATT’, ‘VOX’, ‘AF’, ‘RF’, ‘SQL’,
527 ‘IF’, ‘APF’, ‘NR’, ‘PBT_IN’, ‘PBT_OUT’, ‘CWPITCH’, ‘RFPOWER’,
528 ‘MICGAIN’, ‘KEYSPD’, ‘NOTCHF’, ‘COMP’, ‘AGC’, ‘BKINDL’, ‘BAL’,
529 ‘METER’, ‘VOXGAIN’, ‘ANTIVOX’, ‘SLOPE_LOW’, ‘SLOPE_HIGH’, ‘RAW‐
530 STR’, ‘SWR’, ‘ALC’, ‘STRENGTH’.
531
532 The Level Value can be a float or an integer value. For the AGC
533 token the value is one of ‘0’ = OFF, ‘1’ = SUPERFAST, ‘2’ =
534 FAST, ‘3’ = SLOW, ‘4’ = USER, ‘5’ = MEDIUM, ‘6’ = AUTO.
535
536 Note: Passing a ‘?’ (query) as the first argument instead of a
537 Level token will return a space separated list of radio backend
538 supported set level tokens. Use this to determine the supported
539 levels of a given radio backend.
540
541 l, get_level 'Level'
542 Get 'Level Value'.
543
544 Returns Level Value as a float or integer for the Level token
545 given as in set_level above.
546
547 Note: Passing a ‘?’ (query) as the first argument instead of a
548 Level token will return a space separated list of radio backend
549 supported get level tokens. Use this to determine the supported
550 levels of a given radio backend.
551
552 P, set_parm 'Parm' 'Parm Value'
553 Set 'Parm' and 'Parm Value'.
554
555 Parm is a token: ‘ANN’, ‘APO’, ‘BACKLIGHT’, ‘BEEP’, ‘TIME’,
556 ‘BAT’, ‘KEYLIGHT’.
557
558 Note: Passing a ‘?’ (query) as the first argument instead of a
559 Parm token will return a space separated list of radio backend
560 supported set parameter tokens. Use this to determine the sup‐
561 ported parameters of a given radio backend.
562
563 p, get_parm 'Parm'
564 Get 'Parm Value'.
565
566 Returns Parm Value as a float or integer for the Parm token
567 given as in set_parm above.
568
569 Note: Passing a ‘?’ (query) as the first argument instead of a
570 Parm token will return a space separated list of radio backend
571 supported get parameter tokens. Use this to determine the sup‐
572 ported parameters of a given radio backend.
573
574 B, set_bank 'Bank'
575 Set 'Bank'.
576
577 Sets the current memory bank number.
578
579 E, set_mem 'Memory#'
580 Set 'Memory#' channel number.
581
582 e, get_mem
583 Get 'Memory#' channel number.
584
585 G, vfo_op 'Mem/VFO Op'
586 Perform a 'Mem/VFO Op'.
587
588 Mem/VFO Operation is a token: ‘CPY’, ‘XCHG’, ‘FROM_VFO’,
589 ‘TO_VFO’, ‘MCL’, ‘UP’, ‘DOWN’, ‘BAND_UP’, ‘BAND_DOWN’, ‘LEFT’,
590 ‘RIGHT’, ‘TUNE’, ‘TOGGLE’.
591
592 Note: Passing a ‘?’ (query) as the first argument instead of a
593 Mem/VFO Op token will return a space separated list of radio
594 backend supported Set Mem/VFO Op tokens. Use this to determine
595 the supported Mem/VFO Ops of a given radio backend.
596
597 g, scan 'Scan Fct' 'Scan Channel'
598 Perform a 'Scan Fct' on a 'Scan Channel'.
599
600 Scan Function is a token: ‘STOP’, ‘MEM’, ‘SLCT’, ‘PRIO’, ‘PROG’,
601 ‘DELTA’, ‘VFO’, ‘PLT’.
602
603 Scan Channel is an integer (maybe?).
604
605 Note: Passing a ‘?’ (query) as the first argument instead of a
606 Scan Fct token will return a space separated list of radio back‐
607 end supported Scan Function tokens. Use this to determine the
608 supported Scan Functions of a given radio backend.
609
610 H, set_channel 'Channel'
611 Set memory 'Channel' data.
612
613 Not implemented yet.
614
615 h, get_channel
616 Get memory 'Channel' data.
617
618 Not implemented yet.
619
620 A, set_trn 'Transceive'
621 Set 'Transceive' mode.
622
623 Transcieve is a token: ‘OFF’, ‘RIG’, ‘POLL’.
624
625 Transceive is a mechanism for radios to report events without a
626 specific call for information.
627
628 Note: Passing a ‘?’ (query) as the first argument instead of a
629 Transceive token will return a space separated list of radio
630 backend supported Transceive mode tokens. Use this to determine
631 the supported Transceive modes of a given radio backend.
632
633 a, get_trn
634 Get 'Transceive' mode.
635
636 Transceive mode (reporting event) as in set_trn above.
637
638 *, reset 'Reset'
639 Perform rig 'Reset'.
640
641 Reset is a value: ‘0’ = None, ‘1’ = Software reset, ‘2’ = VFO
642 reset, ‘4’ = Memory Clear reset, ‘8’ = Master reset.
643
644 Since these values are defined as a bitmask in include/ham‐
645 lib/rig.h, it should be possible to AND these values together to
646 do multiple resets at once, if the backend supports it or sup‐
647 ports a reset action via rig control at all.
648
649 0x87, set_powerstat 'Power Status'
650 Set 'Power Status'.
651
652 Power Status is a value: ‘0’ = Power Off, ‘1’ = Power On, ‘2’ =
653 Power Standby (enter standby), ‘4’ = Power Operate (leave
654 standby).
655
656 0x88, get_powerstat
657 Get 'Power Status' as in set_powerstat above.
658
659 0x89, send_dtmf 'Digits'
660 Set DTMF 'Digits'.
661
662 0x8a, recv_dtmf
663 Get DTMF 'Digits'.
664
665 _, get_info
666 Get misc information about the rig (no VFO in 'VFO mode' or
667 value is passed).
668
669 dump_state
670 Return certain state information about the radio backend.
671
672 1, dump_caps
673 Not a real rig remote command, it just dumps capabilities, i.e.
674 what the backend knows about this model, and what it can do.
675
676 TODO: Ensure this is in a consistent format so it can be read
677 into a hash, dictionary, etc. Bug reports requested.
678
679 Note: This command will produce many lines of output so be very
680 careful if using a fixed length array! For example, running
681 this command against the Dummy backend results in over 5kB of
682 text output.
683
684 VFO parameter not used in 'VFO mode'.
685
686 2, power2mW 'Power [0.0..1.0]' 'Frequency' 'Mode'
687 Returns 'Power mW'.
688
689 Converts a Power value in a range of 0.0...1.0 to the real
690 transmit power in milli-Watts (integer).
691
692 'Frequency' and 'Mode' also need to be provided as output power
693 may vary according to these values.
694
695 VFO parameter is not used in VFO mode.
696
697 4, mW2power 'Power mW' 'Frequency' 'Mode'
698 Returns 'Power [0.0..1.0]'.
699
700 Converts the real transmit power in milli-Watts (integer) to a
701 Power value in a range of 0.0 ... 1.0.
702
703 'Frequency' and 'Mode' also need to be provided as output power
704 may vary according to these values.
705
706 VFO parameter is not used in VFO mode.
707
708 w, send_cmd 'Cmd'
709 Send a raw command string to the radio.
710
711 This is useful for testing and troubleshooting radio commands
712 and responses when developing a backend.
713
714 For binary protocols enter values as \0xAA\0xBB. Expect a
715 'Reply' from the radio which will likely be a binary block or an
716 ASCII string depending on the radio's protocol (see your radio's
717 computer control documentation).
718
719 The command terminator, set by the send-cmd-term option above,
720 will terminate each command string sent to the radio. This
721 character should not be a part of the input string.
722
723 W, send_cmd_rx 'Cmd'
724 Send a raw command string to the radio and expect a number of
725 bytes returned.
726
727 This is useful for testing and troubleshooting radio commands
728 and responses when developing a backend. If the # of bytes
729 requested is <= the number actually returnead no timeout will
730 occur.
731
732 The command argument can have no spaces in it. For binary pro‐
733 tocols enter values as \0xAA\0xBB. Expect a 'Reply' from the
734 radio which will likely be a binary block or an ASCII string
735 depending on the radio's protocol (see your radio's computer
736 control documentation).
737
738 The command terminator, set by the send-cmd-term option above,
739 will terminate each command string sent to the radio. This
740 character should not be a part of the input string.
741
742 pause 'Seconds'
743 Pause for the given whole (integer) number of 'Seconds' before
744 sending the next command to the radio.
745
747 If Readline library development files are found at configure time,
748 rigctl will be conditonally built with Readline support for command and
749 argument entry. Readline command key bindings are at their defaults as
750 described in the Readline manual
751 ⟨https://tiswww.cwru.edu/php/chet/readline/rluserman.html⟩. rigctl
752 sets the name “rigctl” which can be used in Conditional Init Constructs
753 in the Readline Init File ($HOME/.inputrc by default) for custom key‐
754 bindings unique to rigctl.
755
756 Command history is available with Readline support as described in the
757 Readline History manual
758 ⟨https://tiswww.case.edu/php/chet/readline/history.html#SEC1⟩. Command
759 and argument strings are stored as single lines even when arguments are
760 prompted for input individually. Commands and arguments are not vali‐
761 dated and are stored as typed with values separated by a single space.
762
763 Normally session history is not saved, however, use of either of the
764 -i/--read-history or -I/--save-history options when starting rigctl
765 will cause any previously saved history to be read in and/or the cur‐
766 rent and any previous session history (assuming the -i and -I options
767 are given together) will be written out when rigctl is closed. Each
768 option is mutually exclusive, i.e. either may be given separately or in
769 combination. This is useful to save a set of commands and then read
770 them later but not write the modified history for a consistent set of
771 test commands in interactive mode, for example.
772
773 History is stored in $HOME/.rigctl_history by default although the des‐
774 tination directory may be changed by setting the RIGCTL_HIST_DIR envi‐
775 ronment variable. When RIGCTL_HIST_DIR is unset, the value of the HOME
776 environment variable is used instead. Only the destination directory
777 may be changed at this time.
778
779 If Readline support is not found at configure time the original inter‐
780 nal command handler is used. Readline is not used for rigctl commands
781 entered on the command line regardless if Readline support is built in
782 or not.
783
784 Note: Readline support is not included in the MS Windows 32 or 64 bit
785 binary builds supplied by the Hamlib Project. Running rigctl on the MS
786 Windows platform in the ‘cmd’ shell does give session command line his‐
787 tory, however, it is not saved to disk between sessions.
788
790 The -v, --verbose option allows different levels of diagnostics to be
791 output to stderr and correspond to -v for BUG, -vv for ERR, -vvv for
792 WARN, -vvvv for VERBOSE, or -vvvvv for TRACE.
793
794 A given verbose level is useful for providing needed debugging informa‐
795 tion to the email address below. For example, TRACE output shows all
796 of the values sent to and received from the radio which is very useful
797 for radio backend library development and may be requested by the
798 developers.
799
801 rigctl exits with:
802
803 0 if all operations completed normally;
804
805 1 if there was an invalid command line option or argument;
806
807 2 if an error was returned by Hamlib.
808
810 Start rigctl for a Yaesu FT-920 using a USB to serial adapter on Linux
811 in interactive mode:
812
813 $ rigctl -m 114 -r /dev/ttyUSB1
814
815 Start rigctl for a Yaesu FT-920 using COM1 on MS Windows while generat‐
816 ing TRACE output to stderr:
817
818 > rigctl -m 114 -r COM1 -vvvvv
819
820 Start rigctl for a Yaesu FT-920 using a USB to serial adapter while
821 setting baud rate and stop bits:
822
823 $ rigctl -m 114 -r /dev/ttyUSB1 -s 4800 -C stop_bits=2
824
825 Start rigctl for an Elecraft K3 using a USB to serial adapter while
826 specifying a command terminator for the w command:
827
828 $ rigctl -m 229 -r /dev/ttyUSB0 -t';'
829
830 Connect to a running rigctld with radio model 2 (“NET rigctl”) on the
831 local host and specifying the TCP port, setting frequency and mode:
832
833 $ rigctl -m 2 -r localhost:4532 F 7253500 M LSB 0
834
836 set_chan has no entry method as of yet, hence left unimplemented.
837
838 This almost empty section...
839
840 Report bugs to:
841
842 Hamlib Developer mailing list
843 ⟨hamlib-developer@lists.sourceforge.net⟩
844
846 This file is part of Hamlib, a project to develop a library that sim‐
847 plifies radio, rotator, and amplifier control functions for developers
848 of software primarily of interest to radio amateurs and those inter‐
849 ested in radio communications.
850
851 Copyright © 2000-2011 Stephane Fillod
852 Copyright © 2000-2018 the Hamlib Group (various contributors)
853 Copyright © 2010-2019 Nate Bargmann
854
855 This is free software; see the file COPYING for copying conditions.
856 There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
857 PARTICULAR PURPOSE.
858
860 less(1), more(1), rigctld(1), hamlib(7)
861
863 Links to the Hamlib Wiki, Git repository, release archives, and daily
864 snapshot archives:
865
866 hamlib.org ⟨http://www.hamlib.org⟩.
867
868
869
870Hamlib 2019-12-10 RIGCTL(1)