I'm developing an interface to control a Radio Shack DX-394 that emulates a combination of Drake R8B and ICOM IC-R75 serial protocols - the two protocols are mutually independent and by having both, a wider range of compatible apps would be available. I'm having problems with both using hamlib rigctl even though a single function app like S Meter Lite is happy with the Read Signal Strength response.
My problem with the ICR75 emulation may be that I
am guessing incorrectly what the correct response should be, despite Ekki's (DF4OR) excellent compendium. Additionally, I may not be providing the correct electrical interface on the serial port to look like CI-V.
Here's what rigctl lists:
-------------------------------------------------------------------------
rig:rig_open called
Opened rig model 339, 'IC-R75'
Backend version: 0.3, Status: Beta
Rig command: F
Frequency: 1234567890
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd ..Z...xV4..
RX 11 characters
0000 fe fe e0 5a 03 90 78 56 34 12 fd ...Z..xV4..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd ..Z...xV4..
RX 11 characters
0000 fe fe e0 5a 03 90 78 56 34 12 fd ...Z..xV4..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd ..Z...xV4..
RX 11 characters
0000 fe fe e0 5a 03 90 78 56 34 12 fd ...Z..xV4..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd ..Z...xV4..
RX 11 characters
0000 fe fe e0 5a 03 90 78 56 34 12 fd ...Z..xV4..
set_freq: error = Protocol error
Yep, you got it. In CAT-V, TXD & RXD are tied together, so the incoming command is echoed. Then comes the acknowlege from the rig.
Here is an example with a (real) 706MkIIG:
Opened rig model 311, 'IC-706MkIIG'
Backend version: 0.3, Status: Beta
Rig command: F
Frequency: 145237500
TX 11 bytes
0000 fe fe 58 e0 05 00 75 23 45 01 fd ..X...u#E..
RX 11 characters
0000 fe fe 58 e0 05 00 75 23 45 01 fd ..X...u#E..
RX 6 characters
0000 fe fe e0 58 fb fd ...X..
Note, the frequency "1234567890" should be rejected if the radio has no support for it:
Rig command: F
Frequency: 1234567890
TX 11 bytes
0000 fe fe 58 e0 05 90 78 56 34 12 fd ..X...xV4..
RX 11 characters
0000 fe fe 58 e0 05 90 78 56 34 12 fd ..X...xV4..
RX 6 characters
0000 fe fe e0 58 fa fd ...X..
icom_set_freq: ack NG (0xfa), len=1
set_freq: error = Command rejected by the rig
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I can't seem to get the -C option of Dream to set the serial speed to 9600.
This command line selects the R75 and the COM port but I cannot find any combination that sets the speed. I have tried multiple -C's, commas, "serial_speed" and "serial-speed" but to no avail.
"Dream.exe -M 339 -C rig_pathname=COM4
How do you send multiple hamlib config parameters?
What's the right syntax for setting serial speed?
73, Tom
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
That works! I must have had a space after the comma when I tried it earlier. Dream is now happily updating its S-meter via the hamlib IC-R75 interface to my DX-394 and being fooled into thinking it's controlling frequency.
Now I have to get down to serious hardware interfacing between my emulator and the DX-394 and grow the functionality so that I can try some of the other hamlib apps that do a lot more control than Dream.
Thanks for your help and what a great piece of work you and the team have done on hamlib. I'm sure I will find some inspiration from the R8B and R75 definitions and code to help me with my emulator development (in assembler).
73, Tom
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm developing an interface to control a Radio Shack DX-394 that emulates a combination of Drake R8B and ICOM IC-R75 serial protocols - the two protocols are mutually independent and by having both, a wider range of compatible apps would be available. I'm having problems with both using hamlib rigctl even though a single function app like S Meter Lite is happy with the Read Signal Strength response.
My problem with the ICR75 emulation may be that I
am guessing incorrectly what the correct response should be, despite Ekki's (DF4OR) excellent compendium. Additionally, I may not be providing the correct electrical interface on the serial port to look like CI-V.
Here's what rigctl lists:
-------------------------------------------------------------------------
rig:rig_open called
Opened rig model 339, 'IC-R75'
Backend version: 0.3, Status: Beta
Rig command: F
Frequency: 1234567890
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd ..Z...xV4..
RX 11 characters
0000 fe fe e0 5a 03 90 78 56 34 12 fd ...Z..xV4..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd ..Z...xV4..
RX 11 characters
0000 fe fe e0 5a 03 90 78 56 34 12 fd ...Z..xV4..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd ..Z...xV4..
RX 11 characters
0000 fe fe e0 5a 03 90 78 56 34 12 fd ...Z..xV4..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd ..Z...xV4..
RX 11 characters
0000 fe fe e0 5a 03 90 78 56 34 12 fd ...Z..xV4..
set_freq: error = Protocol error
Rig command:
-------------------------------------------------------------------------
I've tried responding with the 05 code instead of 03, and also the Good acknowledgement but no go. CIV-test is happy with all of them.
Any advice appreciated.
Tom VE3MEO
Here's the rigctl report when using the $FB acknowledgement:
---------------------------------------------------------------
rig:rig_open called
Opened rig model 339, 'IC-R75'
Backend version: 0.3, Status: Beta
Rig command: F
Frequency: 1234567890
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd
RX 6 characters
0000 fe fe e0 5a fb fd ...Z..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd
RX 6 characters
0000 fe fe e0 5a fb fd ...Z..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd
RX 6 characters
0000 fe fe e0 5a fb fd ...Z..
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd
RX 6 characters
0000 fe fe e0 5a fb fd ...Z..
set_freq: error = Protocol error
Rig command:
---------------------------------------------------------------
Same error as the previous.
73, Tom
OK - have to echo the incoming command and follow it with the ACK msg.
Tom
Opened rig model 339, 'IC-R75'
Backend version: 0.3, Status: Beta
Rig command: F
Frequency: 1234567890
TX 11 bytes
0000 fe fe 5a e0 05 90 78 56 34 12 fd
RX 11 characters
0000 fe fe 5a e0 05 90 78 56 34 12 fd
RX 6 characters
0000 fe fe e0 5a fb fd ...Z..
Rig command:
Yep, you got it. In CAT-V, TXD & RXD are tied together, so the incoming command is echoed. Then comes the acknowlege from the rig.
Here is an example with a (real) 706MkIIG:
Opened rig model 311, 'IC-706MkIIG'
Backend version: 0.3, Status: Beta
Rig command: F
Frequency: 145237500
TX 11 bytes
0000 fe fe 58 e0 05 00 75 23 45 01 fd ..X...u#E..
RX 11 characters
0000 fe fe 58 e0 05 00 75 23 45 01 fd ..X...u#E..
RX 6 characters
0000 fe fe e0 58 fb fd ...X..
Note, the frequency "1234567890" should be rejected if the radio has no support for it:
Rig command: F
Frequency: 1234567890
TX 11 bytes
0000 fe fe 58 e0 05 90 78 56 34 12 fd ..X...xV4..
RX 11 characters
0000 fe fe 58 e0 05 90 78 56 34 12 fd ..X...xV4..
RX 6 characters
0000 fe fe e0 58 fa fd ...X..
icom_set_freq: ack NG (0xfa), len=1
set_freq: error = Command rejected by the rig
Hi Stephane,
I can't seem to get the -C option of Dream to set the serial speed to 9600.
This command line selects the R75 and the COM port but I cannot find any combination that sets the speed. I have tried multiple -C's, commas, "serial_speed" and "serial-speed" but to no avail.
"Dream.exe -M 339 -C rig_pathname=COM4
How do you send multiple hamlib config parameters?
What's the right syntax for setting serial speed?
73, Tom
The syntax is comma separated (no space). The -C option should be the very same that rigctl.exe (yes, you can select serial speed of rigctl from -C).
For Dream, it should be something like this, unless there's a bug:
"Dream.exe -M 339 -C rig_pathname=COM4,serial_speed=9600"
What are the error messages?
73, Stphane
Hi Stephane,
That works! I must have had a space after the comma when I tried it earlier. Dream is now happily updating its S-meter via the hamlib IC-R75 interface to my DX-394 and being fooled into thinking it's controlling frequency.
Now I have to get down to serious hardware interfacing between my emulator and the DX-394 and grow the functionality so that I can try some of the other hamlib apps that do a lot more control than Dream.
Thanks for your help and what a great piece of work you and the team have done on hamlib. I'm sure I will find some inspiration from the R8B and R75 definitions and code to help me with my emulator development (in assembler).
73, Tom