portapack-mayhem / mayhem-firmware

Custom firmware for the HackRF+PortaPack H1/H2/H4
https://hackrf.app
GNU General Public License v3.0
3.45k stars 560 forks source link

faulty GPS signal for R9 version? #1070

Closed Robert19721106 closed 1 year ago

Robert19721106 commented 1 year ago

I have an older version of HackRF One (with MAX2387 chip) and two new R9 cards (with MAX2839 chip) and one PortaPack H1 card (from older HackRF One version)

After uploading the mayhem firmware to new boards (R9) with PortaPack connected, the GPS simulator does not work properly - the signal is "narrowband" - attached is a screenshot from the spectrum analyzer.

hackrf_one_MAX2839

After uploading the same firmware to the older version of HackRF One (the one based on MAX2837), everything is OK - a screenshot of the emitted GPS signal is attached.

hackrf_one_MAX2837

Is the problem caused by a bug in the software (incorrect MAX2839 support?) or is my PortaPack H1 board not compatible with the newer R9 version ?

Regards, Robert

Brumi-2021 commented 1 year ago

Hackrf_info is detecting it, as hw r9 ? Which fw are you testing,?

Robert19721106 commented 1 year ago

I checked all boards under microscope and these two new boards have MAX2389 instead of MAX2387 (as my old board). So this is R9 version. I have old executables of hackrf_info , so answer is not completed:

Found HackRF board. Board ID Number: 4 (Unknown Board ID) Firmware Version: 2023.01.1 Part ID Number: 0x0054435d 0x0054435d Serial Number: 0x00000000 0x00000000 0x118461dc 0x21249b03

If you send me newer hackrf_info.exe (for Windows) I can check these new board, but for sure it contain MAX2839.

I tested portapack-mayhem V1.7.0 and the newest (V1.7.1?) and portapack-havoc-modified (https://github.com/jamesshao8/portapack-havoc-modified) and results are the same...

BTW: GPS signal generation in HACKRF mode are OK for each board (https://github.com/osqzss/gps-sdr-sim) but GPS signal generation in standalone mode (with PortaPack) is wrong for hackrf one with MAX2839 chip.

Brumi-2021 commented 1 year ago

Hello Robert, I do not have a r9 . But I could see other colleagues with r9 , And in that case Hackrf_info is detecting it

I just delete his serial number .

hackrf_info version: 2022.09.1
libhackrf version: 2022.09.1 (0.7)
Found HackRF
Index: 0
Serial number: 0000000000000000xxxxxxxxxxxxxxxx
Board ID Number: 4 (HackRF One)
Firmware Version: v1.7.1 (API:1.07)
Part ID Number: 0xa000xxxx 0x00xxxxxx
Hardware Revision: r9
Hardware does not appear to have been manufactured by Great Scott Gadgets.
Hardware supported by installed firmware: HackRF One

I believe that he just used the hackrf_info from the latest 1.70 or 1.71 zip distribution .

Did you used a recent version of Hackrf_info ?

Brumi-2021 commented 1 year ago

I think , first we need to achieve that your board is recognised as r9 by hackrf_info .

You will need to separate Hackrf board from Portapack board .

Just In case that in our Mayhem releases we still did not have updated the new tools for r9 (not sure ?) , better that you download it from here try the latest hackrf bin. download 2023.1.1 here:

https://github.com/greatscottgadgets/hackrf/releases

You will find a hackrf_one_usb.bin in firmware-bin in that zip. And you will also need hackrf_one_usb.dfu . If you are working on windows: place both where your dfu_hackrf_one.bat is and do the dfu flash.

Then from DFU, write first the hackrf_one_usb.dfu (And once you got Hackrf mode with blue screen) write the downloaded Hackrf bin :

If you have errors just with -w , try adding -i : try "hackrf_spiflash -i -w hackrf_one_usb.bin" ( in Linux or write equivalent on Windows).

And then check again hackrf_info . Once detected r9 , you can overwrite the latest Mayhem fw 1.70 or 1.71 or latest nightly. And then switch off the board and you can reassemble Hackrf + Portapack and power up

And let's try again if that GPS issue is solved ?? .

Robert19721106 commented 1 year ago

I can not find the newest hackrf_info.exe (binary for Windows).

BTW: https://hackrf.readthedocs.io/en/latest/installing_hackrf_software.html ---> but Windows binaries provided as part of the PothosSDR are from 2021... (but R9 board is made from 2023)

Can you send me hackrf_info.exe which recognize R9? (I have not time for compilation it from sources).

Brumi-2021 commented 1 year ago

Sorry Robert, i also have not that latest hackrf_info file in windows .

I try to follow all Hackrf issues in linux . You are right, PhotosSDR build is from 2021 !!! (Not latest one ) maybe it would be easier if you can access to any other laptop with linux, is it possible ?

Robert19721106 commented 1 year ago

I have UBUNTU @ Windows10, so it should be OK, can you send me binaries of hackrf tools for Linux?

Brumi-2021 commented 1 year ago

Hi , I have pentoo (gentoo) distro , so I am afraid that I can Not transfer you my local Hackrf tools compiled as binaries ebuilds , to your different linux distro .

I think , the easy way , follow Hackrf Ubuntu install instructions . If need we can ask help to other Ubuntu colleagues in Discord .

New help from Tournesol , un discord : as easy as: sudo apt install hackrf Cheers

Robert19721106 commented 1 year ago

Hi Brumi!

My new board:

Found HackRF Index: 0 Serial number: 0000000000000000118461dc21935803 Board ID Number: 4 (HackRF One) Firmware Version: 2023.01.1 (API:1.07) Part ID Number: 0xa000cb3c 0x0061475e Hardware Revision: r9 Hardware does not appear to have been manufactured by Great Scott Gadgets. Hardware supported by installed firmware: HackRF One

My old board:

Found HackRF Index: 0 Serial number: 0000000000000000088869dc35994c1b Board ID Number: 2 (HackRF One) Firmware Version: 2023.01.1 (API:1.07) Part ID Number: 0xa000cb3c 0x00544f58 Hardware Revision: older than r6 Hardware supported by installed firmware: HackRF One

It seems that support for MAX2839 contains some important bug.

To sum up, the GPS simulator does not work properly for the R9 version - it emits some strange narrow-band signal instead of a typical wide-spectrum signal, earlier I sent screenshots from the spectrum analyzer for both versions of HackRF One and the same firmware version.

Robert

Brumi-2021 commented 1 year ago

Ok good , how about the rest of community members that has HackRF r9 ? Can someone else try to play GPS Simul and see with other SDR Receiver if the radiated spectrum is narrow (as described by Robert ) one instead of wide spectrum (normal ) ?

u-foka commented 1 year ago

I've tested with r9 + H2 from ali, receiving with an RTL2832 based DVB tuner, the signal looks alright, anyhow I change gain / amp settings. CleanShot 2023-05-27 at 11 02 33

If I find my old android phone, will test with that too..

Brumi-2021 commented 1 year ago

Hi @Robert19721106 , as you could see other colleague with r9 , transmit a correct wide broadband using GPS Simul and the default .C8 example files . Then it seems more a problem to your board . Other TX modulation goes well , WFM , NFM , AM , SSB . morse ?

Robert19721106 commented 1 year ago

I checked the transmitter/sound broadcasting mode and found something interesting to track down the bug.

Well, there is an unmodulated carrier there, but after a few START/STOP it starts working (I can hear the WAV file being broadcast in the external FM radio receiver and I can change the FM deviation value and it causes the correct volume change in the receiver). After this "unblocking" when I enter the GPS simulator mode, the transmitted signal is correct ... And it works properly until RESET / power-up of HackRF One...

This is some sort of software or hardware hazard.

So there can only be two explanations:

option 1) I have both defective newly purchased HackRF One R9 boards (e.g. incorrect value of some electronic component), tiles purchased from Aliexpress, Chinese of course, but I would not prejudge the fault

option 2) there is a glitch in the initialization of the radio path (e.g. the MAX2839 initialization procedure) which results in an uncertain (hazardous) result, e.g. an unlocked PLL sync loop or something like that, which causes that the modulation does not work; after a few manipulations START/STOP for different modes of the transmitter "something hit" and then everything works fine (until next power-up)

Any ideas?

Brumi-2021 commented 1 year ago

Hello @Robert19721106 , I just have this idea , at the moment , in the past , we have found several colleagues having some strange modulation problems (you can see here #466 , you can check my comment of 22nd March 22) , and they were due to have a very old Hackrf Xilinx CPLD firmware not updated.

So far we have found three clear ways to detect indirectly if you have old HackRF Xilinx CPLD fw , (1) Check #1009 (painter mirrored picture spectrum) (2) Check #651 (Unnatural jerky motion Waterfall) (3) check #1468 (no adsb reception just after booting)

Maybe the easy one for you would be check (1) . Let me know if you could recognise any of those (1) , (2) problems in your new Hackrf r9 , and if yes, I advice you to try to update the Hackrf CPLD fw , following the (1) process description, and then repeat the test of GPS Simul ,and other Modulation incidences.

Cheers.

Robert19721106 commented 1 year ago

Hi Brumi!

In my case, autoupdating the CPLD by installing the latest hackrf_one firmware didn't work (tested on both R9 boards), while manually reprogramming the CPLD ( ./hackrf_cpldjtag -x default.xsvf ) yielded positive results and both R9 boards now work fine.

Thank you for your help.

Cheers.

Brumi-2021 commented 1 year ago

Hi @Robert19721106 , that it is excellent results ! We are really happy about it .πŸ‘πŸŽ‰πŸŽ‰πŸŽ‰πŸŽ‰ Just before closing that issue , could you let me know if you could identify it with the checking (1) and (2)

cheers

Robert19721106 commented 1 year ago

it was (1):

image

Brumi-2021 commented 1 year ago

Ok thanks @Robert19721106 to give us full details . We take note about it , to advice to other users with similar problem , to go straight away to the direct CPLD flash methode , and not rely about the automatic one .

I guess that now , you also fixed all other modulation incidences . Then let’s gladly close that issue !!! cheers

Brumi-2021 commented 1 year ago

BTW @Robert19721106 , as you could probably see . Latest nightly Mayhem binary , also solves the #1081 (that also was related to your Hackrf version r9 ) (Not included yet in latest official fw v 1.70, nor 1.71)

Cheers

Sats301 commented 1 year ago

Hello everybody! I am completely upset!

Completely same situation, but with one little difference...

  1. All actions with FW/CPLD manually flashing - not working.
  2. Can't check situation with 1.6.0 and lower FW (screen not working, buttons can't help).
  3. I've bought 100 PCS of HackRF PortaPack H2+ for student education, and the part of education program - not available, because we cant discover lite spoofing...
  4. .C8 folder generated by gps-sdr-sim pack.
  5. SD cards no make sense.
  6. But in HackRF with PC - is fine.

I am really not understand what I need to do. Just look on photos... image Hacrf_info

photo1690247638 Chipsets

photo1690247644 GPS_Sim - completely bad! photo1690247653

HackRF mode - is ok image photo1690249837

Friends could I ask you for a help? Because this situation is a really nervous...