Radio Control in RBASIC™
In RBASIC, all radio control variables start with an "R". The same variable names are used for both reading the value and changing it.
sets frequency to 468.125 MHz, and
assigns the current receiver frequency to a variable called "freq".
Some functions have duplicate or multiple keywords for faster programming. For example, RFREQUENCY, RFREQ and RFR are all interchangeable.
Here is a summary of radio controls (alternative keywords are shown in parentheses):
Receiver frequency. This is both read and write variable. The range is determined by the receiver capabilities. The value is in MHz.
Receiver volume. Read and write. Value is between 0 and 31.
Receiver squelch. Read and write. Value is between 0 and 100.
Receiver power. Read and write. Zero turns the receiver off. Non-zero turns it on. When read, value 1 is returned if the receiver is on.
Receiver attenuator. Read and write. Zero turns the attenuator off. Non-zero turns it on. When read, value 1 is returned if the attenuator is on.
Receiver preamplifier. Read and write. Zero turns the preamplifier off. Non-zero turns it on. When read, value 1 is returned if the preamplifier is on. Supported by some receiver models only.
AGC setting. Meaningfull values are 0 and 1 for WR-1000 and WR-3000 series receivers and <0-3> for G3 series receivers.
IF Gain. Meaningful only when AGC is off (zero). Allowed values are <0,100>
IF Gain in dB units. Usage similar to RIFGAIN, but supported only by G31x receiver models. Allowed values are <0,120>
Received signal strenth. Read-only, returns values in the range 0 to 120.
Received signal strenth in dBm units. Read-only, supported only by some receiver models.
Receiver's serial number. Supported only by G3 series receivers.
Receiver's model name. Supported only by G3 series receivers. WR-1000 and WR-3000 series receivers contain the receiver's name as entered in the control panel.
Receiver modulation mode. Allowed values are: "AM", "AMS", "FMW", "WFM", "FM-W", "DSB", "ISB", "FMN", "FM-N", "NFM", "LSB", "USB", "CW", "FMM", "FM1", "FM2", "FM3", "FM4".
"FMW", "WFM" and "FM-W" are equivalent. "FMN", "FM-N" and "NFM" are also equivalent. "FM1".."FM4" and "FMM" are ready for expansion.
An error message is shown, when an incorrect value is being sent to the receiver.