3.2 Frequency data format
Frequency data is transferred using the BCD (binary coded decimal) code. For historical reasons there are two data lengths used: 4 and 5 bytes. Practically all rigs use 5 bytes of data, only one old model uses 4-byte length: the IC-735 (IC-731 in Japan). Most rigs can be set to 'IC-731' compatibility, reducing the used data length for frequencies to four bytes.
In the remaining document I will discuss only 5 byte length data formats.
The frequency data is used for the following commands:
- $00: Transfer operating freq. data
- $02: Read band edge data
- $03: Read operating frequency data
- $05: Write operating frequency data
- $14: Extended memory commands
- $1A: Extended memory commands
Frequency data is transferred with the least significant byte first, beginning with 1 Hz data, up to 1 GHz digit.
The frequency to transfer is 145'282.376 (2m band, 145Mhz 282kHz 376Hz).
The command used here is $05, transfer frequency. More on commands in section 4.
The five bytes following the command contain the data, the frequency coded in BCD, least significant byte sent first.
$76 is the 10Hz (7) and 1Hz (6) digit in BCD format
$23 is the 1kHz (2) and 100Hz (3) digit in BCD format
$28 is the 100kHz (2) and 10kHz (8) digit in BCD format
$45 is the 10MHz (4) and 1MHz (5) digit in BCDformat
$01 is the 100MHz (1) and 1GHz (0) digit in BCD format
Older documentation shows that it is possible to send shorter frequency data, like one to four bytes. This would change only the affected digits. I tested this on an IC-725 and IC-735, but not on newer rigs, so i cannot guarantee if this feature is supported on newer rigs. The benefit of this is a shorter message and faster transmission.
Why BCD data?
So why is Icom using BCD as the data format for frequencies (and most other values)? It's quite easy to answer: When using BCD the valid numerical range for a data byte is limited from $00 to $99. With this coding it is ensured that other, reserved byte values like $FE or $FB can never show up in data bytes. That would be the case if a simple binary format would have been used, making the protocol much more difficult and error prone.
Confused about BCD and Hex data representation? Maybe the appendix A can help a little bit.