Is there a way in FlexLib.NET to save/load global profiles?

  • 1
  • Question
  • Updated 3 years ago

Is there a way in FlexLib.NET to save/load global profiles?  I am writing SmartSDR version of my SWRplotter utility.  I want to be able to reset the radio back to its original state when my program closes.

73, Ray, K9DUR

Photo of Ray Andrews, K9DUR

Ray Andrews, K9DUR, Elmer

  • 238 Posts
  • 61 Reply Likes

Posted 4 years ago

  • 1
Photo of Richard Clafton W4/G7EIX

Richard Clafton W4/G7EIX, Elmer

  • 455 Posts
  • 117 Reply Likes

Ray,

I see....

SaveGlobalProfile in RADIO

and

ProfileGlobalSelection in RADIO


Photo of Ray Andrews, K9DUR

Ray Andrews, K9DUR, Elmer

  • 238 Posts
  • 61 Reply Likes
Tnx.  I looked over that list several time & still missed it....hi...hi.  73, Ray, K9DUR
Photo of Richard Clafton W4/G7EIX

Richard Clafton W4/G7EIX, Elmer

  • 455 Posts
  • 117 Reply Likes
Aye, it's like looking for that missing sock sometimes! :-)
Photo of Jim Shaffer (KE5AL)

Jim Shaffer (KE5AL)

  • 37 Posts
  • 0 Reply Likes
I apparently don't know how to use SaveGlobalProfile and ProfileGlobalSelection.
I have at least one panadapter with a slice, and make some modifications, and then do "theRadio.SaveGlobalProfile("testing");".
I then disconnect and reconnect the radio and do "theRadio.ProfileGlobalSelection = "testing";".
The hope is that this will restore the characteristics from the "testing" profile.
I would expect the ProfileGlobalList to contain my profile, but it contains nothing.  Apparently I've missed something obvious here, but I can't figure out what.
Photo of Ray Andrews, K9DUR

Ray Andrews, K9DUR, Elmer

  • 238 Posts
  • 61 Reply Likes

I can save a global profile named "tempSWR", but when I try to load it, there is no spectrum display & the waterfall is blank.  Everything else appears to restore correctly.


I have to close the panadapter to recover.

My Visual Basic code is:     

myRadio.SaveGlobalProfile("tempSWR")

myRadio.ProfileGlobalSelection = "tempSWR"

Any ideas?

73, Ray, K9DUR

Photo of Mark - W3II

Mark - W3II

  • 130 Posts
  • 33 Reply Likes
When  you call Connect on the Radio object the API requests the status of many items, profile lists being among them. The Radio has a Property changed event you need to listen to. This will notify you when the profile list you desire has been loaded / changed.
In this case look for the property name "ProfileGlobalList". Once you see this property notification you can then use the ProfileGlobalList to access existing profiles.

Now that you know how to access the list I have to warn you that SmartSDR 1.4.X and earlier has an issue where selecting a global profile from an API application will / may corrupt the SmartSDR UI. This is a know issue in their bug tracking system which has been fixed in the next release of SmartSDR.

Setting TX Profiles works without any issues.

73,
Mark