Welcome to the new FlexRadio Community! Please review the new Community Rules and other important new Community information on the Message Board.
Need the latest SmartSDR, Power Genius, Tuner Genius and Antenna Genius Software?
SmartSDR v3.8.19 and the SmartSDR v3.8.19 Release Notes | SmartSDR v2.12.1 and the SmartSDR v2.12.1 Release Notes
SmartSDR v1.12.1 and the SmartSDR v1.12.1 Release Notes
Power Genius XL Utility v3.8.8 and the Power Genius XL Release Notes v3.8.8
Tuner Genius XL Utility v1.2.11 and the Tuner Genius XL Release Notes v1.2.11
Antenna Genius Utility v4.1.8
SmartSDR v3.8.19 and the SmartSDR v3.8.19 Release Notes | SmartSDR v2.12.1 and the SmartSDR v2.12.1 Release Notes
SmartSDR v1.12.1 and the SmartSDR v1.12.1 Release Notes
Power Genius XL Utility v3.8.8 and the Power Genius XL Release Notes v3.8.8
Tuner Genius XL Utility v1.2.11 and the Tuner Genius XL Release Notes v1.2.11
Antenna Genius Utility v4.1.8
If you are having a problem, please refer to the product documentation or check the Help Center for known solutions.
Need technical support from FlexRadio? It's as simple as Creating a HelpDesk ticket.
Need technical support from FlexRadio? It's as simple as Creating a HelpDesk ticket.
Getting started question
IW7DMH, Enzo
Member ✭✭
Hello,
while I am waiting for my new Flex 6300, I am taking a look at the latest FlexRadio API archive (FlexLib_v1.3.9).
I am finding it a bit hard bearing among lots objects in the various projects and therefore I would ask if it is possible to have some help for this simple use case:
- Acquiring radio control (I suppose it is like getting a radio instance)
- Reading the VFO frequency
- Set the volume level
I don't want to use the cat approach but the powerful api access instead. I can't find the documentation for all these classes, nor a class diagram that can help me. I would be glad also for a code snippet.
Thank you very much
73' Enzo
iw7dmh
while I am waiting for my new Flex 6300, I am taking a look at the latest FlexRadio API archive (FlexLib_v1.3.9).
I am finding it a bit hard bearing among lots objects in the various projects and therefore I would ask if it is possible to have some help for this simple use case:
- Acquiring radio control (I suppose it is like getting a radio instance)
- Reading the VFO frequency
- Set the volume level
I don't want to use the cat approach but the powerful api access instead. I can't find the documentation for all these classes, nor a class diagram that can help me. I would be glad also for a code snippet.
Thank you very much
73' Enzo
iw7dmh
0
Answers
-
Enzo. Your translator is broken. I have no idea what you just asked.0
-
I am talking about writing a simple Windows application that can interact with a Flex Signature radio.
Surely my translation is not perfect, but most of the terms I used, are well known to software developers.
Best regards
0 -
I thought his request was perfectly understandable both times
He just wants better documentation of the API so he can find the classes that contain control for the radio's volume and frequency as well as a copy of some sample code so that he can see how to write the application to bypass using CAT in order to address the radio directly..
3 -
Well of course! Why am I not surprised?0
-
Yes, that was what I meant.
In the meantime I found this interesting post https://community.flexradio.com/flexradio/topics/first_steps_with_flexlib
with an answer by Eric:)
I'll start from here.
Thank you very much
73 '
iw7dmh
0 -
Hello,
I am back after doing some tests, but with no great results.
I followed the directions of Eric and tried to write a simple program.
When my program starts I get the error listed below, and any radio is found.
...
A first chance exception of type 'System.Net.Sockets.SocketException' occurred in System.dll
A first chance exception of type 'System.Net.Sockets.SocketException' occurred in System.dll
A first chance exception of type 'System.Net.Sockets.SocketException' occurred in System.dll
A first chance exception of type 'System.Net.Sockets.SocketException' occurred in System.dll
...
The socket error happens when SmartSDRCat is already running, otherwise no errors but again any radio is found.
Also SmartSdrCAT, compiled from FlexLib 1.3.9 source, can't find any radio, while the version getted from the installation package (luckly) works fine.
I really do not understand where I'm wrong.
Here is my simple source code and I would be glad for any help.
73' Enzo
iw7dmh
===========================================
...
using Flex.Smoothlake.FlexLib;
using AsyncSocketsV2;
using log4net;
namespace FlexTest
{
public partial class Form1 : Form
{
Radio this_radio;
public Form1()
{
InitializeComponent();
//
API.RadioAdded += new API.RadioAddedEventHandler(API_RadioAdded);
API.RadioRemoved += new API.RadioRemovedEventHandler(API_RadioRemoved);
API.ProgramName = "FlexTEST";
API.Init();
}
/*
* API_RadioAdded
*/
void API_RadioAdded(Radio radio)
{
Console.WriteLine("API_RadioAdded Fired: " + radio.ToString());
this_radio = radio;
}
/*
* API_RadioRemoved
*/
void API_RadioRemoved(Radio radio)
{
Console.WriteLine("API_RadioRemovfed Fired: " + radio.ToString());
this_radio = null;
}
private void button1_Click(object sender, EventArgs e)
{
Close();
}
}
}
===========================================
0 -
Well, it was really hard, but in the end I solved the mystery.
The code in the previous post, even if so simple, is correct and works well.
The problem is related to the Windows firewall settings !!!
When you run the program for the first time, Windows firewall prompt you to allow your application connections. Even if you agree, it actually doesn't happen. YOU HAVE TO CHECK ALSO "Public Network".
If you forgot it, as you can see from the image below, you wil have two connections still blocked (they have the red icon).
These are just the TCP and UDP rules used by Flex Library to communicate with your radio.
You only need to change (allow connection) these two rules and the program magically works.
Hope this can help other beginners like me.
73' Enzo
iw7dmh0
Leave a Comment
Categories
- All Categories
- 289 Community Topics
- 2.1K New Ideas
- 530 The Flea Market
- 7.5K Software
- 6K SmartSDR for Windows
- 146 SmartSDR for Maestro and M models
- 358 SmartSDR for Mac
- 249 SmartSDR for iOS
- 230 SmartSDR CAT
- 171 DAX
- 352 SmartSDR API
- 8.7K Radios and Accessories
- 7K FLEX-6000 Signature Series
- 20 FLEX-8000 Signature Series
- 841 Maestro
- 43 FlexControl
- 847 FLEX Series (Legacy) Radios
- 793 Genius Products
- 415 Power Genius XL Amplifier
- 277 Tuner Genius XL
- 101 Antenna Genius
- 243 Shack Infrastructure
- 166 Networking
- 404 Remote Operation (SmartLink)
- 130 Contesting
- 630 Peripherals & Station Integration
- 125 Amateur Radio Interests
- 869 Third-Party Software