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.20 and the SmartSDR v3.8.20 Release Notes
SmartSDR v2.12.1 and the SmartSDR v2.12.1 Release Notes
Power Genius XL Utility v3.8.9 and the Power Genius XL Release Notes v3.8.9
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.20 and the SmartSDR v3.8.20 Release Notes
SmartSDR v2.12.1 and the SmartSDR v2.12.1 Release Notes
Power Genius XL Utility v3.8.9 and the Power Genius XL Release Notes v3.8.9
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.
VitaFFTPacket
James Whiteway
Member
Under the Library Flex.SmoothLake.Vita, there is a Class called : VitaFFTPacket.
Looking thru it's Methods it seems it provides the size of each bin, the number of bins
associated with a particular packet and on down the line.
But, for whatever reason, I cannot access Vita to the point to use any of this data.
I tried this as Stu suggested:
private void panadapter_DataReady(Panadapter pan, ushort data)
{
// WHAT GOES HERE???
}
The //WHAT GOES HERE?? is what I added after trying, (and failing) several things
in Panadapter.cs to get the data packets needed for the Panadapter.
Wish Steve or Eric could drop a couple of hints this way. It sure would be appreciated.
(especially since they wrote this and are using C#)
:-)
james
WD5GWY
Looking thru it's Methods it seems it provides the size of each bin, the number of bins
associated with a particular packet and on down the line.
But, for whatever reason, I cannot access Vita to the point to use any of this data.
I tried this as Stu suggested:
private void panadapter_DataReady(Panadapter pan, ushort data)
{
// WHAT GOES HERE???
}
The //WHAT GOES HERE?? is what I added after trying, (and failing) several things
in Panadapter.cs to get the data packets needed for the Panadapter.
Wish Steve or Eric could drop a couple of hints this way. It sure would be appreciated.
(especially since they wrote this and are using C#)
:-)
james
WD5GWY
0
Answers
-
James,
What is it that you are trying to do? If you use the Panadapter_DataReady event as shown in the code mentioned, you shouldn't need to deal with the VitaFFTPacket class as we pull the data out before it gets to this event and present it as an array of points (this is the ushort data parameter in the event).0 -
Thanks Eric. I am trying to draw the panadapter. But, it was not clear to me which events and values I need to watch to get the spectrum display to draw correctly. (hope that makes sense as I'm sure I'm using the wrong nominclature to describe what I'm trying to do.) James WD5GWY0
-
This makes perfect sense. Stu is right. You want to subscribe to the DataReady event in the Panadapter class. This will provide you with formatted data based on the Width, Height, MindBm and MaxdBm parameters you have set for the Pandapter object.
The data will be an array of points where the index is assumed to be the X position (so you would draw it left to right). The values for the data are in pixels with the reference (0, 0) in the upper left corner.0 -
Eric, one more question(for now).
The array of pixels, they are for drawing a bitmap, that is refreshed X number of milliseconds, depending on the refresh rate set? Not for plotting the spectrum based on freq, (x value) and signal strength (-dBm for y value).
is that correct? If so, that explains the difference between VitaFFTPacket.cs and Panadapter.cs
Panadapter.cs takes all the proccessed FFT data and turns it into a bitmap to be drawn by the client.
Or so it seems to me.
james
WD5GWY0 -
Not exactly. FFT packets are sent from the radio across the ethernet connection to the client as often as needed to keep the framerate selected. Depending on the size of the display being shown, it may take more than one packet to hold a full frame of FFT data. The expectation is that the client will use the most recent data and overwrite any previous data. So no timing on the client side should be required other than handling the DataReady event.
The data in the packets is already rendered to pixels with x_pixels representing the frequency and y_pixels representing log power (dB). This data is collected and ordered in the Panadapter class before firing the DataReady event. But the data really doesn't change -- it has the same units in the DataReady event as the FFT packet payload. This is part of the point of doing the rendering in the radio -- to make it easier on the client to absorb the information.
So the panadapter.cs class is really just the glue that presents a nice C# Object Oriented interface (Properties, Routines, Events) for interacting with the Panadapter that the radio interface exposes. The details of the packets are handled for you and the myriad of rendering decisions that happen when changing the display window size or the bandwidth, etc are abstracted behind the scenes (mostly in the radio) so that the developer can just focus on how to make the data look nice in their application.
I hope that helps. Keep the questions coming if it is still as clear as mud.0 -
Ok, do the packets for the panadapter include RGB values as well? Or is that in the data for the Waterfall? I ask that because when I think of pixels, I think of them as having color values associated with them james WD5GWY0
-
The Panadapter just has rendered pixel data. No colors.
The Waterfall has rendered power density data that is then turned into colors in the client.0 -
Thank you Eric. I "think" I am starting to get it now. I'm on the way to Phoenix and cannot test what I am thinking. But, I will this weekend. What think I need to do is start a DrawLine from 0,0 and use the values I load into an array.(from the PanadapterDataReady event) for the Y value. If the value (depending on where it is in the array) is 0, then no line is drawn to a higher point or lower point until the the next non-zero value is encountered. Once reaching the end of the line(based on the Width of the Panadapter) increment a counter for the loop that I have the DrawLine statement in(loop based on height of Panadapter--- lowdBm & HighdBm) and continue till loop count is zero or the array is empty. Then reset loop count and reload array. Is that anywhere near right? James I wrote all the above to help me remember what I'm thinking for when I get home and back to my computer.0
-
This makes sense. I would suggest that you grab the data and put it into an array of Points where x is just the index into the data (really, the x position) and Y is the incoming data from the DataReady event. Then call the DrawLines function on the whole array. This is more efficient than doing a bunch of 1 pixel line draws.
0
Leave a Comment
Categories
- All Categories
- 260 Community Topics
- 2.1K New Ideas
- 538 The Flea Market
- 7.6K Software
- 6K SmartSDR for Windows
- 139 SmartSDR for Maestro and M models
- 368 SmartSDR for Mac
- 242 SmartSDR for iOS
- 226 SmartSDR CAT
- 175 DAX
- 345 SmartSDR API
- 8.8K Radios and Accessories
- 7K FLEX-6000 Signature Series
- 45 FLEX-8000 Signature Series
- 859 Maestro
- 45 FlexControl
- 849 FLEX Series (Legacy) Radios
- 807 Genius Products
- 424 Power Genius XL Amplifier
- 280 Tuner Genius XL
- 87 Antenna Genius
- 227 Shack Infrastructure
- 153 Networking
- 410 Remote Operation (SmartLink)
- 130 Contesting
- 642 Peripherals & Station Integration
- 116 Amateur Radio Interests
- 878 Third-Party Software