I think the Jammer deserves a green icon, since it actually does it job pretty well.
Then there is a Jitter parameter. It allows to introduce a jitter from 1/60th of a second up to 60/60th of a second (a full one). It will delay / move forward either the TX or the cooldown period for a maximum of a half of the time you choose as jitter.
Meaning: If I choose 60/60th, a full second of jitter, it will produce a random number from 1 to 60.
Then it will calculate jitter = 30 - randomnumber
THen it will "add" that (positive or negative) time to the time counter for the next jitter change of state.
Discord User jteich did some investigation (Thanks!) and helped me understanding this rather obscure parameter:
Internally, is called "TRIGGER", and is passed into the baseband when configuring the desired spectrum sample rate.
Please forgive me in advance if this explanation is not 100% correct. It's only my interpretation, based on my own observation and jteich's comments over Discord chat.
This trigger parameter apparently determines the amount of data over time used for calculating the signal's power inside each specttrum's bin, before considering it "done".
In short, if you lower this resolution value then the cascade will tend to be rendered a bit faster, while kind of blind to tiny signals.
On the other hand, a bigger value will help rendering and distinguishing different signals on the cascade.
Too big a value can easily clutter up the cascade. But then it may be a "blessing" when inspecting higher freuqencies -where hackrf is more deaf"
The default value of 32 is quite decent. But then, now you can experiment with it. Cheers
Added a PRESETS.TXT file (inside /LOOKINGGLASS folder).
Also optimized the way the spectrum signal is integrated into the cascade.
Added provision for ranges lower than 240MHz but I am afraid that at this time it will not be advisable to lower ranges any more than 240MHz, since some artifacts and frequency running - moving out of place- occurs.
I can only hope that someone with a better understanding of hackrf's inner code can fix this issue and perhaps enhance the scanning speed.
I found some "original commenting" inside the code:
// TODO: Move more low-level radio control stuff to M4. It'll enable tighter
// synchronization for things like wideband (sweeping) spectrum analysis, and
// protocols that need quick RX/TX turn-around.
Which makes me think that there are things "missing" from the portapack side of the code, for allowing serious speed sweeping. So I am concluding that with current "portapack framework" this might be "the best possible thing".
It is to be noted that the "new" internal sweep mode code is signed by:
* Copyright 2016 Mike Walters, Dominic Spill
*
* This file is part of HackRF.
Maybe Mike or Dominic can be contacted and hopefully lend a hand on enhancing this code.
- Now we have variable CLKOUT.
- CLKOUT can be set between 10kHz and 60MHz.
(The output signal will become mostly sine shape when reaching 50MHz.)
- Click on freq setting field to change tuning step.
Added a nicer MARKER (thanks to XSX(H1) contributor for the suggestion)
Fixed a bug that made the screen scroll from top, when using a popup "window" and returning (like, when pressing the DC VOLTAGE enable / disable" button on top bar) THanks to GregoryFenton for the testing and bug spotting!
Capable of showing a cascade with full bandwidth scan. You can select Min and Max Mhz for the cascade.
You can move a marker so to (aproximately) know a particular frequency on the cascade. If you press the select button, the app will jump into the RX -> AUDIO app, already tuned into the just "marked" frequency.
This first version SURELY has space for lots of optimizations and improvement in general.
Several old bugs squashed.
On the APRS side, most notably, SSID numbers where shifted left twice, instead of once, and bits 5,6 where not properly set.
On AX.25 side, the bit stuffing part of the encoder was not placing the zero bit on the right place.
Finally, I changed APRS icon from ORANGE to GREEN, since even this may be a simple app, now it's doing its work as intended.
Values where left bit-shifted upon being entered by the user, so resulting SSID being transmitted was a different number. This shifting was happening both on Source and Destination SSID values.
* No device freeze when you try to close app while it's transmitting
* Bypassed 100 .wav files limit by implementing paging functionality
* Removed useless progressbar and implemented page info line instead
Moved the MIC TX RX into the main menu.
Changed scanner color from yellow to green, since it is kind of rounded up into an acceptable functionality.
Also, did a bit of cleanup on the code spacing inside the menues.
Also added the fields "DateTime" which just shows the raw timestamp that portapack assigned the last packet received, in the format: YYYYMMDDHHMMSS ... And "Frame" which shows the packet # (or frame) for correlating with other software / verify that there are new packets being received.
Also moved a string function for returning rounded-up decimals, originally inside the whipcalc tool app, into the string_format functions library, because I used that function on TEMP and HUMIDITY values inisde the radiosonde app.
Finally, the whole UI has its widgets moved a bit, giving space for these new parameters.
Thanks @euquiq for a more common solution to the bug.
Added RX gain control.
Now we have full gain controls!
Merged PTT and Voice activation into one option selector.(allowing RIGHT BUTTON to work with PTT off)
This patch addresses the issue detected in: https://github.com/eried/portapack-mayhem/issues/159
This patch will revert the behavior of the function to_string_short_freq
into using spaces on the left of the integer part of the frequency (as it did originally).
When upgrading the scanner app, I did change the behavior of this function eliminating those spaces, so I could gain some characters-worth of space inside the scanner, but I failed to detect that it introduced some lack of padding on the rx->audio app.
Now, it is back as before, and I also did update the scanner so it can cope with the "extra spaces" this function now adds (again).
A bug that enabling audio RX resets the TX gain (perhaps because that changing to receiving mode modifies some registers) inspired me to add this gain control.
Commented out some steps which don't require for the VU meter to work again.
Moved some widgets for gain control.
Added CRC calculation for Vaisala radiosondes.
Added a Checkbox on APP for turning ON / OFF CRC. When CRC on, malformed packets are ignored.
Connected existing CRC function for METEOMAN sondes, using the same "CRC" checkbox logic.
Added the Vaisala RS41 data packet decoding.
Changed the default freq from 402.0 to 402.7 Mhz, since it is more popular freq.
Lowered the frequency stepping, so it is easier to fine-tune the exact freq center, if needed.
Sonde's Serial ID is passed into the VIEW MAP, so now the sonde is labelled on the map.
Earlier code did not start with squelch totally open, but a tiny bit closed. (now at app loading, squelch is truly set up with the same value it shows on screen).
I also hardcoded the NFM sampling rate and baseband bandwidth. It seemed "the right thing to do".
You can enable RX and adjust VOLUME and SQUELCH into your liking.
Sadly enough, you will NOT be able to use VOICE ACTIVATION when RX is enabled (to ensure there will be NO audio feedback defeating the VA sensing)
A "bug" that won over me, but perhaps and hopefully other coder can easily fix: The Vumeter will momentarily "dissappear" when enabling RX. But it will reappear as soon as you start TX. Or when you turn off RX.
I enabled the PEAK LEVEL MARK on the Vumeter, so you can easily see in which level your input voice / signal is peaking and regulate the MIC gain accordingly in an easier / more robust way.
Side enhancement: Took off the dark green, yellow and red coloring from the vumeter when no signal is present, and replaced it with dark_grey. I know that some coloring is "eye-candy" but the vu-meter is more readable with this new contrast.
The file rename function needs to be called with full_path/old_name and full_path/new_name.
Instead, it was called with full_path/old_name and new_name ... thus the renamed file ended on the root dir (path not preserved).
Squelch value now goes from -90 to +20 and it's directly compared against the max_db parameter returned from each freq scanned by the radio subsystem, with no adjusts or manipulation (you adjust the number as will be used).
Less squelch means weaker signals will trigger it. (as expected).
There was a tiny cosmetic bug when you deleted a frequency from the scanning memory: The description was not erased from screen and you could see it while the scan did not resume.
There was another bug on the pause button: If you asked for another manual scan range when paused, the button kept the text "RESUME" (its text was not reset to "PAUSE" again).
Added buttons for:
Change scanning direction (ascending / descending)
Saving current freq into the SCANNER.TXT file
(Please notice that, on the other hand -for safety issues- the DEL FQ button, deletes the frequency only from the temp memory on the actual scanning session, but does NOT erases the freq. inside the SCANNER.TXT)
Also there are other bug fixes and scanning speed enhancements.
MIC TX button :Shortcut for jumping into TX -> MIC app.
FREQ DEL button: Deletes currently displayed frequency from temporary scanning memory. Ideal to get rid of those not wanted "noisy" freqs in the middle of a range scan.
Also, some code optimizations thrown in.
I changed width in pixels of the "fine-tune cursor" from 2 to 5 , and then re-centered the cursor, from 120 to 118 to accomodate the shift in width.
I was inspired by this old ISSUE on Havoc's repository, where at the end @furrtek commented the need to make the red tick bigger in the future (but forgot / was swamped with other ehnancements / issues):
https://github.com/furrtek/portapack-havoc/issues/172
When scanner finds a freq with high dbi, it locks into it "listening" a bit more (less than a second) for either confirm or discard it as an actual high dbi or just a spurious thing.
The big number frequency changes color accordingly: Grey = just scanning, yellow = locking in, Green = Found something, allowing the user to listen.
New ui_scanner, inspired on AlainD's (alain00091) PR: https://github.com/eried/portapack-mayhem/pull/80
It includes the following:
1) A big frequency numbers display.
2) A Manual scan section (you can input a frequency range (START / END), choose a STEP value from an available of standard frequency intervals, and press SCAN button.
3) An AM / WFM / NFM scan mode selector, changing "on the fly".
4) A PAUSE / RESUME button, which will make the scanner to stop upon you listening something of interest
5) AUDIO APP button, a quick shortcut into the analog audio visualizing / recording app, with the mode, frequency, amp, LNA, VGA settings already in tune with the scanner.
6) Two enums are added to freqman.hpp, reserved for compatibility with AlainD's proposed freqman's app and / or further enhancement. More on this topic:
ORIGINAL scanner just used one frequency step, when creating scanning frequency ranges, which was unacceptable. AlainD enhanced freqman in order to pass different steppings along with ranges. This seems an excellent idea, and I preserved that aspect on my current implementation of thisscanner, while adding those enums into the freqman just to keep the door open for AlainD's freqman in the future.
7) I did eliminate the extra blank spaces added by function to_string_short_freq() which created unnecessary spacing in every app where there is need for a SHORT string, from a frequency number. (SHORT!, no extra spaces!!)
8) I also maintained AlainD idea of capping the number of frequencies which are dynamically created for each range and stored inside a memory based db. While AlainD capped the number into 400 frequencies, I was able to up that value a bit more, into 500.
Cheers!
As shown in https://github.com/eried/portapack-mayhem/issues/88 ...
Tiny bug but probably responsible for badly forming datetime in several apps, as it is used in ACARS, POCSAG and ADSB_TX (and of course AIS RX)
Lowered the scale -10 ºC so it accomodates less than zero temperatures, present sometimes when cold starting the system.
Added 1 char for temperature label length.
Adjusted the max2837 sensor value -> ºC temp result, by normalizing the conversion to correctly display the standard 25ºC, mentioned in Datasheet.
It reads the antennas definition from a txt file:
WHIPCALC/ANTENNAS.TXT
Inside the textfile you place each antenna you own with the following sintaxis:
<antenna label> <elements length in mm, separated by a space>
For example:
ANT500 185 315 450 586 724 862
Input the required frequency, adjust the wave type (full / half / quarter, etc.) and the calculator will return the antenna length (metric and imperial) while also calculating how much you need to expand the fitting antennas you got defined on the txt.
It may return up to 8 matching antennas, which is more than enough (normally you will have 2, perhaps 3 telescopic antennas around for your portapack)
If by any chance your antennas txt got more than 8 antennas, and more than 8 matches the length of the freq / wave you want, it will only show the first 8 matching antennas and will warn you at the bottom that there are even more results (hidden).
All calculations now are rounded into the best integer, considering first decimal, so precision is double than the original antenna calculator app.
Icons disappear when they are rolled over using the jog wheel and the colour is set to
ui::color::white()
Fixed by changing the colours of the icons to something other than ui::color::white()