Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Rigctl not found #804

Closed
danieldamon opened this issue Sep 13, 2024 · 22 comments · Fixed by #805
Closed

[Bug]: Rigctl not found #804

danieldamon opened this issue Sep 13, 2024 · 22 comments · Fixed by #805
Assignees
Labels
bug 🪲 Something isn't working

Comments

@danieldamon
Copy link

FreeDATA Version

v0.16.2-alpha

What operating system are you using?

Windows

Operating System Version

windows 11 32H2 AMD Ryzen

Architecture

x64

Area of problem

Rig Control

Describe the bug

2024-09-12 17:59:12 [info ] [C2 ] Libcodec2 loaded path=C:\Users\dangd\AppData\Local\FreeDATA\FREEDA1\lib\codec2\libcodec2.dll
Using config from C:\Users\dangd\AppData\Local\FreeDATA\FREEDA
1\config.ini
2024-09-12 17:59:13 [info ] [DatabaseManager]: Initialized database
2024-09-12 17:59:13 [info ] [DatabaseManager]: Database vacuumed successfully
Hamlib args ==>['-m', '2028', '-r', 'COM3', '-s', '115200', '-p', 'COM3', '-P', 'USB', '-D', 'RIG', '--set-conf', 'dtr_state=ON', '--set-conf', 'data_bits=8', '--set-conf', 'stop_bits=1', '']
2024-09-12 17:59:13 [warning ] Rigctld binary not found.
2024-09-12 17:59:13 [info ] [DatabaseManager]: Database reindexed successfully
2024-09-12 17:59:13 [info ] [DatabaseManager]: Database integrity check passed
2024-09-12 17:59:13 [info ] ---------------------------------------------------
2024-09-12 17:59:13 [info ]
2024-09-12 17:59:13 [info ] [GUI] AVAILABLE ON http://127.0.0.1:5001/gui
2024-09-12 17:59:13 [info ] just open it in your browser
2024-09-12 17:59:13 [info ]
2024-09-12 17:59:13 [info ] ---------------------------------------------------
2024-09-12 17:59:15 [warning ] [RIGCTLD] Failed to connect to rigctld: [WinError 10061] No connection could be made because the target machine actively refused it
2024-09-12 17:59:15 [info ] tested audio devices result=[True, True]
2024-09-12 17:59:15 [info ] starting freedata_server....
2024-09-12 17:59:15 [debug ] [C2 ] Create 48<->8 kHz resampler
2024-09-12 17:59:15 [debug ] [C2 ] Creating audio buffer size=9600
2024-09-12 17:59:15 [debug ] [C2 ] Creating audio buffer size=9600
2024-09-12 17:59:15 [debug ] [C2 ] Creating audio buffer size=9600
2024-09-12 17:59:15 [debug ] [C2 ] Creating audio buffer size=9600
2024-09-12 17:59:15 [debug ] [C2 ] Creating audio buffer size=9600
2024-09-12 17:59:15 [debug ] [C2 ] Creating audio buffer size=9600
2024-09-12 17:59:15 [debug ] [C2 ] Creating audio buffer size=9600
2024-09-12 17:59:15 [debug ] [C2 ] Creating audio buffer size=9600
2024-09-12 17:59:15 [info ] loading frame dispatcher.....

2024-09-12 17:59:15 [debug ] Event: ev={'freedata_server': 'started'}
2024-09-12 17:59:15 [info ] [MDM] init: get audio devices input_device=3cdc output_device=0129
2024-09-12 17:59:15 [info ] [MDM] init: receiving audio from 'Stereo Mix (Realtek HD Audio Stereo input)'
2024-09-12 17:59:15 [info ] [MDM] init: transmiting audio on 'Speakers 2 (Realtek HD Audio output with HAP)'
2024-09-12 17:59:15 [debug ] [MDM] init: starting pyaudio callback and decoding threads
2024-09-12 17:59:15 [debug ] [C2 ] Create 48<->8 kHz resampler
2024-09-12 17:59:15 [info ] [DatabaseManagerBeacon]: Deleted 0 beacons older than 2 days
2024-09-12 17:59:16 [info ] [API] GET response_code=307 url=http://127.0.0.1:5001/gui
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/gui/
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/version
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/devices/audio
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/devices/serial
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/radio
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/modem/state
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/modem/state
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/version
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/devices/audio
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/radio
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/devices/serial
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/config
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/radio
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/freedata/messages
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/version
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/devices/audio
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/devices/serial
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/radio
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/config
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/freedata/messages
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/radio
{'NETWORK': {'modemaddress': '127.0.0.1', 'modemport': 5001}, 'STATION': {'mycall': 'KE0UR', 'mygrid': 'DM45gg', 'myssid': 3, 'ssid_list': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9], 'enable_explorer': False, 'enable_stats': False, 'respond_to_cq': True, 'enable_callsign_blacklist': False, 'callsign_blacklist': []}, 'AUDIO': {'input_device': '3cdc', 'output_device': '0129', 'rx_audio_level': 8, 'tx_audio_level': 8}, 'RIGCTLD': {'ip': '127.0.0.1', 'port': 4532, 'path': '', 'command': '', 'arguments': '', 'enable_vfo': True}, 'RADIO': {'control': 'rigctld_bundle', 'model_id': 2028, 'serial_port': 'COM3', 'serial_speed': 115200, 'data_bits': 8, 'stop_bits': 1, 'serial_handshake': 'None', 'ptt_port': 'COM3', 'ptt_type': 'USB', 'serial_dcd': 'RIG', 'serial_dtr': 'ON', 'serial_rts': 'OFF'}, 'TCI': {'tci_ip': '127.0.0.1', 'tci_port': 50001}, 'MESH': {'enable_protocol': False}, 'MODEM': {'enable_hmac': False, 'enable_morse_identifier': False, 'tx_delay': 50, 'maximum_bandwidth': 2438, 'enable_socket_interface': False}, 'SOCKET_INTERFACE': {'enable': False, 'host': '127.0.0.1', 'cmd_port': 8000, 'data_port': 8001}, 'MESSAGES': {'enable_auto_repeat': False}, 'GUI': {'auto_run_browser': True}}
2024-09-12 17:59:16 [info ] [API] POST response_code=200 url=http://127.0.0.1:5001/config
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/config
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/radio
2024-09-12 17:59:16 [info ] [API] GET response_code=200 url=http://127.0.0.1:5001/freedata/messages
{'NETWORK': {'modemaddress': '127.0.0.1', 'modemport': 5001}, 'STATION': {'mycall': 'KE0UR', 'mygrid': 'DM45gg', 'myssid': 3, 'ssid_list': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9], 'enable_explorer': False, 'enable_stats': False, 'respond_to_cq': True, 'enable_callsign_blacklist': False, 'callsign_blacklist': []}, 'AUDIO': {'input_device': '3cdc', 'output_device': '0129', 'rx_audio_level': 8, 'tx_audio_level': 8}, 'RIGCTLD': {'ip': '127.0.0.1', 'port': 4532, 'path': '', 'command': '', 'arguments': '', 'enable_vfo': True}, 'RADIO': {'control': 'rigctld_bundle', 'model_id': 2028, 'serial_port': 'COM3', 'serial_speed': 115200, 'data_bits': 8, 'stop_bits': 1, 'serial_handshake': 'None', 'ptt_port': 'COM3', 'ptt_type': 'USB', 'serial_dcd': 'RIG', 'serial_dtr': 'ON', 'serial_rts': 'OFF'}, 'TCI': {'tci_ip': '127.0.0.1', 'tci_port': 50001}, 'MESH': {'enable_protocol': False}, 'MODEM': {'enable_hmac': False, 'enable_morse_identifier': False, 'tx_delay': 50, 'maximum_bandwidth': 2438, 'enable_socket_interface': False}, 'SOCKET_INTERFACE': {'enable': False, 'host': '127.0.0.1', 'cmd_port': 8000, 'data_port': 8001}, 'MESSAGES': {'enable_auto_repeat': False}, 'GUI': {'auto_run_browser': True}}
2024-09-12 17:59:16 [info ] [API] POST response_code=200 url=http://127.0.0.1:5001/config
{'NETWORK': {'modemaddress': '127.0.0.1', 'modemport': 5001}, 'STATION': {'mycall': 'KE0UR', 'mygrid': 'DM45gg', 'myssid': 3, 'ssid_list': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9], 'enable_explorer': False, 'enable_stats': False, 'respond_to_cq': True, 'enable_callsign_blacklist': False, 'callsign_blacklist': []}, 'AUDIO': {'input_device': '3cdc', 'output_device': '0129', 'rx_audio_level': 8, 'tx_audio_level': 8}, 'RIGCTLD': {'ip': '127.0.0.1', 'port': 4532, 'path': '', 'command': '', 'arguments': '', 'enable_vfo': True}, 'RADIO': {'control': 'rigctld_bundle', 'model_id': 2028, 'serial_port': 'COM3', 'serial_speed': 115200, 'data_bits': 8, 'stop_bits': 1, 'serial_handshake': 'None', 'ptt_port': 'COM3', 'ptt_type': 'USB', 'serial_dcd': 'RIG', 'serial_dtr': 'ON', 'serial_rts': 'OFF'}, 'TCI': {'tci_ip': '127.0.0.1', 'tci_port': 50001}, 'MESH': {'enable_protocol': False}, 'MODEM': {'enable_hmac': False, 'enable_morse_identifier': False, 'tx_delay': 50, 'maximum_bandwidth': 2438, 'enable_socket_interface': False}, 'SOCKET_INTERFACE': {'enable': False, 'host': '127.0.0.1', 'cmd_port': 8000, 'data_port': 8001}, 'MESSAGES': {'enable_auto_repeat': False}, 'GUI': {'auto_run_browser': True}}
2024-09-12 17:59:16 [info ] [API] POST response_code=200 url=http://127.0.0.1:5001/config
2024-09-12 17:59:17 [warning ] [RIGCTLD] Failed to connect to rigctld: [WinError 10061] No connection could be made because the target machine actively refused it

To Reproduce

Use Hamlib internal.

Expected behavior

Should not get message that Rigctld could not be found.

Screenshots

No response

Log Files

No response

Additional context

I'm using TRUSDX transciever which conforms to Kenwood TS480. I have used it with WSTJX which also uses Hamlib, so this should work.

@danieldamon danieldamon added the bug 🪲 Something isn't working label Sep 13, 2024
@danieldamon danieldamon changed the title [Bug]: Rigctl not founs [Bug]: Rigctl not found Sep 13, 2024
@danieldamon
Copy link
Author

First warning in the log may not be obvious. It is:

2024-09-12 17:59:13 [warning ] Rigctld binary not found.

@DJ2LS
Copy link
Owner

DJ2LS commented Sep 14, 2024

It might be possible, there is a problem with Hamlib and x64 systems. @dk5sm, maybe you can assist here if you have the time?

@dk5sm
Copy link
Collaborator

dk5sm commented Sep 14, 2024

@danieldamon I have had a (at least) similar issue here. To help with your case, plase allow some questions:

  1. I assume that you are also using the FreeDATA Windows Installer package - correct?
  2. What rigctl mode are you using? See Settings -> Rigcontrol: internal or external Hamlib?

As far as your log is concerned, I am missing the Hamlib path, which leads to the conclusion that you may have configured external Hamlib. Please switch to internal Hamlib and make sure that you have set the appropriate settings for your transceiver.

After restarting the server, a successful hamlib start should read like this:

Hamlib args ==>['-m', '3073', '-r', 'COM5', '-s', '115200', '-P', 'RIG', '--set-conf', 'data_bits=8', '--set-conf', 'stop_bits=1', '']
2024-09-14 10:18:48 [info     ] Attempting to start rigctld using binary found at: C:\Users\[Username]\AppData\Local\FreeData\freedata-server\lib\hamlib\hamlib-w64-4.5.5\bin\rigctld.exe

73 de
Stefan | DK5SM.

@danieldamon
Copy link
Author

Yes, I am using the windows .exe installer.

The mode I am using is Rigcontrol:internal. I did not install an external hamlib

@danieldamon
Copy link
Author

Thanks for your work on this. I'd love to have something that works on all platforms. Currently it looks like it is not used widely,, so I'm willing to test to help out.

@danieldamon
Copy link
Author

By the way, my computer is dual boot with Linux. I just got it working in Linux, so apparently I'm doing it right.

@dk5sm
Copy link
Collaborator

dk5sm commented Sep 15, 2024

OK, please check whether these files are contained in this path (C:\Users[Username]....):

image

Check also with the file date: I had an issue with old/corrupt files. To be on the safe side, please unzip all the files you find in C:\Users[Username]\AppData\Local\FreeData\freedata-server\lib\hamlib\hamlib-w64-4.5.5.zip, and then test them again.

@danieldamon
Copy link
Author

In fact, there is no bin directory, although that directory does exist in the zip archive. How is it extracted, and I will try manually to see what happens.

@danieldamon
Copy link
Author

In fact, it seems to work when I extract manually

@DJ2LS
Copy link
Owner

DJ2LS commented Sep 16, 2024

Thanks for the feedback! So you are missing just the bin folder, right? Did this occur at first installation. Or as an update?

@danieldamon
Copy link
Author

First installation. If you like, I can delete all and try again.

@DJ2LS DJ2LS added this to FreeDATA Sep 17, 2024
@DJ2LS DJ2LS moved this to In progress in FreeDATA Sep 17, 2024
@DJ2LS
Copy link
Owner

DJ2LS commented Sep 17, 2024

It might be a problem with nuitka bundling. Maybe the corresponding subfolders are ignored

@DJ2LS
Copy link
Owner

DJ2LS commented Sep 17, 2024

confirming its a nuitka problem

DJ2LS pushed a commit that referenced this issue Sep 17, 2024
@DJ2LS DJ2LS self-assigned this Sep 17, 2024
@DJ2LS
Copy link
Owner

DJ2LS commented Sep 17, 2024

python3 -m nuitka
--remove-output
--assume-yes-for-downloads
--follow-imports
--include-data-dir=lib=lib
--include-data-dir=../freedata_gui/dist=gui
--include-data-files=lib/codec2/=lib/codec2/
--include-data-files=lib/hamlib/hamlib-w64-4.5.5/bin/
.exe=lib/hamlib/hamlib-w64-4.5.5/bin/
--include-data-files=lib/hamlib/hamlib-w64-4.5.5/bin/*.dll=lib/hamlib/hamlib-w64-4.5.5/bin/
--include-data-files=config.ini.example=config.ini
--standalone server.py
--output-filename=freedata-server

hardcoded fix, we need to make the version of hamlib dynamically.

@DJ2LS
Copy link
Owner

DJ2LS commented Sep 17, 2024

@danieldamon As an additional information: If you are install hamlib system wide, it will also work. However, it seems I've found a fix

@danieldamon
Copy link
Author

Thanks! should I try again?

@DJ2LS
Copy link
Owner

DJ2LS commented Sep 17, 2024 via email

@DJ2LS
Copy link
Owner

DJ2LS commented Sep 18, 2024

@LA3QMA could you do me the favour and testing the internal development nsis package?

@danieldamon
Copy link
Author

Not sure I understand nsis, but am looking on github

@danieldamon
Copy link
Author

Sorry, I'll be on a plane most of the day, but I can continue Thursday. NSIS looks like an open source windows installer. Unfortunately, I am not familiar with it. Can you provide pointers?

@DJ2LS
Copy link
Owner

DJ2LS commented Sep 21, 2024

It's the windows installer. We can test this with next release or depending on feedback from @LA3QMA

@LA3QMA
Copy link
Collaborator

LA3QMA commented Sep 21, 2024

I installed this on win11. turned on my kx3 after connecting the cables and started FD. selected audio and internal rigctl usb port. then all green. then i go to Settings and select KX3. then CAT and rx/tx works.

Did a short test with the parameter "rigctld VFO parameter" on/off. Both seems to work on KX3.

@DJ2LS DJ2LS moved this from In progress to In review in FreeDATA Sep 25, 2024
@DJ2LS DJ2LS linked a pull request Sep 25, 2024 that will close this issue
@github-project-automation github-project-automation bot moved this from In review to Done in FreeDATA Sep 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🪲 Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

4 participants