开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

#firmware-build #software #TinySA-App #firmware-build #software #TinySA-App


 

Hello Erik

Hello Erik

I just bought a tinysa Ultra fro eleshop.nl , it is still in transit.
I'm a linux user, so MS programs are not used here.

I just have two quick questions (don't spend much time on it).

1:
What linux program do i use for the tinysa Ultra ?
I already have a "recent" nanovna saver installed, but don't think i saw that mentioned as tinysa Ultra pc program.
I have been lightly browsing the groups.io page , and the "wikki", end and found the tinysaSaver.

But it seems to have been untouched for 3 years, is that the recomended linux pc program ?
Is there another/better/more recent program for linux ?

I tried it out on a Deb-11 in Vbox , and it "barfs at me"

./TinySASaver 
Traceback (most recent call last):
? File "/home/cfo/.local/bin/./TinySASaver", line 5, in <module>
? ? from TinySASaver.__main__ import main
? File "/home/cfo/.local/lib/python3.9/site-packages/TinySASaver/__main__.py", line 23, in <module>
? ? from .TinySASaver import TinySASaver
? File "/home/cfo/.local/lib/python3.9/site-packages/TinySASaver/TinySASaver.py", line 36, in <module>
? ? from .Calibration import CalibrationWindow, Calibration
? File "/home/cfo/.local/lib/python3.9/site-packages/TinySASaver/Calibration.py", line 815, in <module>
? ? class Calibration:
? File "/home/cfo/.local/lib/python3.9/site-packages/TinySASaver/Calibration.py", line 834, in Calibration
? ? shortIdeal = np.complex(-1, 0)
? File "/home/cfo/.local/lib/python3.9/site-packages/numpy/__init__.py", line 305, in __getattr__
? ? raise AttributeError(__former_attrs__[attr])
AttributeError: module 'numpy' has no attribute 'complex'.
`np.complex` was a deprecated alias for the builtin `complex`. To avoid this error in existing code, use `complex` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.complex128` here.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
? ? https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations



2:? - Just an info
The tinysa firmware from your git builds fine if i specify
make TARGET="F303"

It barfs if i just specify make ....
I don't care , but others might if they have a F072
Is that intentionally or ??

To have people fiddle with the "ifdef's below ??
./nanovna.h:23:2: error: #error "Remove comment for #ifdef TINYSA_F303"
?#error "Remove comment for #ifdef TINYSA_F303"
? ^~~~~

Thank you for making the devices & software.
Looking forward to play around w. my tinysa Ultra when it arrives.

Regards

Carsten


 

On Sat, Mar 25, 2023 at 03:05 AM, Carsten F (OZ1FTG) wrote:
1:
What linux program do i use for the tinysa Ultra ?
Its still tinySA-Saver and I did not update it.
Some people run tinySA-App in wine.

2:? - Just an info
The tinysa firmware from your git builds fine if i specify
make TARGET="F303"

It barfs if i just specify make ....
I don't care , but others might if they have a F072
Is that intentionally or ??

To have people fiddle with the "ifdef's below ??
./nanovna.h:23:2: error: #error "Remove comment for #ifdef TINYSA_F303"
?#error "Remove comment for #ifdef TINYSA_F303"
? ^~~~~
Sometimes I comment out the #ifdef TINYSA_F303" and the associated #endif or better visibility during editing and I tend to forget restoring this ifdef when pushing changes to git.
If you get these errors, restore the #ifdef TINYSA_F303" and you can build both tinySA Basic and Ultra SW
?
--
For more info on the tinySA go to https://tinysa.org/wiki/


 

Erik
Would you have a look at the python error, and try to fix it, if it "easy" ?
I have no idea if it's a complex or scalar that is needed on line 834 in calibration

Or do i really have to run "wine" ....

Carsten


 

Well i replaced all np.complex with complex in the calibrate file (before pip install)

Then i tried to execute TinySsaver from a command line .. no go
Did a lot of stuff (not working)
Then i executed from a filebrowser --- Worked





Will rollback the Vbox VM , and do it a bit more structured this time

Ps: if executing from command line (at least on Debian) do a : export DISPLAY=:0? first.

Will be back ...

?

@Erik
Is it ok to change to np.complex to just complex ??
They also mention some scalar stuff

If you specifically wanted the numpy scalar type, use `np.complex128` here.

?


 

I just redid my steps, and took a few notes:

This is on a "Clean reinstalled Debian 11" running in VirtualBox (Vbox)

1: Install git + pip
sudo apt install git python3-pip

2: Get tinysa-saver from Erik's git.
git clone https://github.com/erikkaashoek/tinysa-saver

3: In the file Calibration.py , find all ocurrences of np.complex( , and replace with complex(??
You can use an editor , or the sed command below.

cd tinysa-saver/
cd TinySASaver/

You can skip all the grep commands below , they were just for "proff".

Check for #of occurences (we have 21)
deb11-vb:~/tinysa-saver/TinySASaver$ grep "np.complex(" Calibration.py? | wc
???? 21???? 183??? 1439

*** This is the important comand: Replace all occurences of np.complex( with complex(??? ... In the file Calibration.py
deb11-vb:~/tinysa-saver/TinySASaver$ sed -i 's/np.complex(/complex(/g' Calibration.py

No more np.complex( in the file
deb11-vb:~/tinysa-saver/TinySASaver$ grep "np.complex(" Calibration.py? | wc
????? 0?????? 0?????? 0

But 21 occurences of complex( in the file? .... seems good to me.
deb11-vb:~/tinysa-saver/TinySASaver$ grep "complex(" Calibration.py? | wc
???? 21???? 183??? 1376

Return back to the top-level dir.
cd ..

Install the program with pip
python3 -m pip install .

The program is now installed in ~/.local/bin


But i still got an error , when trying to start the program:

deb11-vb:~/.local/bin$ ./TinySASaver
TinySASaver 0.2.2
Copyright (C) 2019 Rune B. Broberg
This program comes with ABSOLUTELY NO WARRANTY
This program is licensed under the GNU General Public License version 3

See https://github.com/erikkaashoek/tinysa-saver for further details
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, wayland-egl, wayland, wayland-xcomposite-egl, wayland-xcomposite-glx, webgl, xcb.

Aborted


This thread gave me a solution:
https://stackoverflow.com/questions/59809703/could-not-load-the-qt-platform-plugin-xcb-in-even-though-it-was-found

I then installed this
sudo apt-get install python3-pyqt5


And now trying again:
deb11-vb:~/.local/bin$ ./TinySASaver

It started


During the process i alsi installed this one (before doing the : sudo apt-get install python3-pyqt5) but it didn't work after that install, and i doubt it's needed to do the below.
sudo apt-get install libxcb-xinerama0


Carsten


 

Carsten,
? TinySA-saver was an early modification of NanoVNA-App by Erik to give both Linux and Windows users a way to save data and capture screenshots.? For the most part, it has been depreciated by TinySA-App which gives you much more control over the tinySA (Ultra) and looks like a true spectrum analyzer application.? If you can get TinySA-App running in Wine, you will have a much better user experience.

Herb


 

Herb
I wish i have known that two days ago.
Then i would prob have looked for another "mini SA" with native linux support.

Well ... That one is on me, for not doing my homework.

Thanx for the input.

Carsten


 

I just installed Wine 8 ....


 

Do i need to install the STM Drivers ??

Or will linux handle the serial IO for wine ??


 

On Sat, Mar 25, 2023 at 05:45 AM, Carsten F (OZ1FTG) wrote:
I wish i have known that two days ago.
Then i would prob have looked for another "mini SA" with native linux support.
? ?Since you purchased the TinySA Ultra model you may find that you have little use for a Linux PC application.? You can save data and screenshots to its SanDisk and transfer that data to your Linux PC.? I primarily use TinySA-App for updating my FW instead of using dfu-util (Windows, Linux and Mac). I also use it for sending commands to the TinySA-Ultra but you can do the same thing using a native Linux terminal application.

?The TinySA-Ultra has a very nice 4" color display, so a PC application is not as important as when purchasing a black box spectrum analyzer.? At $125, you would have had a hard time finding another "miniSA" that matched its technical specifications and developer support at even twice the price.

? Depending on your intended use, the TinySA Ultra may turn out to exceed your expectations without a native Linux application.

Herb


 

On Sat, Mar 25, 2023 at 06:10 AM, Carsten F (OZ1FTG) wrote:

Do i need to install the STM Drivers ??

Or will linux handle the serial IO for wine ??

One of the group's users uploaded this document?/g/tinysa/files/WINE/USB%20port%20mapping%20under%20Wine.pdf which may answer your questions.? However you may find, per my previous message, that installing a PC application is not that important.? You might wait until you receive your TinySA Ultra before you decide.

Herb


 

On Sat, Mar 25, 2023 at 02:36 PM, hwalker wrote:
/g/tinysa/files/WINE/USB%20port%20mapping%20under%20Wine.pdf
Thanx Herb

Let's see, when the SA arrives


 


Well - I'm glad i did? try the tinysa Ultra :-)

I upgraded the fw to the latest 1.4-82 (named 1.4-77) , and cleared config , set the clock , calibrated the touch sreen , and gave selftest a spin (PASSED)

I tried the "APP" under Wine in linux , and it's actually working fine (I think)
I did have to install "Wine 8" on my inux-mint 21.1 (a bit reluctantly) , but the app seems to be running fine..




I did waste most of 1h, as i started the : tinySA.exe
And that didn't behave very well .....
I had the idea that the "small .exe" was the launcher for the lager .exe ....
But after i tried the tinySA-APP.exe , i was met with the above screen.

The tinysa is "dancing" a little around /dev/ttyACM0 & /dev/ttyACM1 , but i can see the mapping in the syslog , or else i can prob lock to /dev/tinysa01 via an udev script & the serial.


I have a set of? - 3 x 2 SMA attenuators on the way - 10,20,30 dB weinschel 18GHZ.
Now to calibrate the frequency offset against my counter & gpsdo

Thank you to Erik & all who helped out ...

Carsten

Ps: I attached a "Wine registry extract" of my COMxx to /dev/ttyxxx mapping.


 

Ohh ....

I just installed Wine8 (stable), following this , edited the registry to add COMxx mapping - Noting else.


Btw: My tinysa came w. an SD card inserted ..Thnx :-)