Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

X40 Error (bladerf.script:0): An unexpected error occurred #917

Open
cn0xroot opened this issue Apr 14, 2023 · 4 comments
Open

X40 Error (bladerf.script:0): An unexpected error occurred #917

cn0xroot opened this issue Apr 14, 2023 · 4 comments

Comments

@cn0xroot
Copy link

cn0xroot commented Apr 14, 2023

gps-sdr-sim# bladeRF-cli -s bladerf.script 



  Error (bladerf.script:0): An unexpected error occurred

gps-sdr-sim# bladeRF-cli -i
bladeRF> version

  bladeRF-cli version:        1.9.0-git-2b90ed39
  libbladeRF version:         2.5.0-git-2b90ed39

  Firmware version:           2.4.0-git-a3d5c55f
  FPGA version:               0.14.0 (configured from SPI flash)
dmesg >/tmp/log
 cat /tmp/log |grep usb
[    5.314246] usbcore: registered new interface driver usbfs
[    5.314246] usbcore: registered new interface driver hub
[    5.314246] usbcore: registered new device driver usb
[    5.955460] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.15
[    5.955464] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    5.955466] usb usb1: Product: xHCI Host Controller
[    5.955468] usb usb1: Manufacturer: Linux 5.15.0-39-generic xhci-hcd
[    5.955469] usb usb1: SerialNumber: 0000:00:14.0
[    5.958086] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 5.15
[    5.958088] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    5.958089] usb usb2: Product: xHCI Host Controller
[    5.958090] usb usb2: Manufacturer: Linux 5.15.0-39-generic xhci-hcd
[    5.958091] usb usb2: SerialNumber: 0000:00:14.0
[    6.015108] usb usb3: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.15
[    6.015110] usb usb3: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    6.015111] usb usb3: Product: xHCI Host Controller
[    6.015112] usb usb3: Manufacturer: Linux 5.15.0-39-generic xhci-hcd
[    6.015113] usb usb3: SerialNumber: 0000:02:00.0
[    6.015481] usb usb4: We don't know the algorithms for LPM for this host, disabling LPM.
[    6.015492] usb usb4: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 5.15
[    6.015494] usb usb4: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    6.015495] usb usb4: Product: xHCI Host Controller
[    6.015495] usb usb4: Manufacturer: Linux 5.15.0-39-generic xhci-hcd
[    6.015496] usb usb4: SerialNumber: 0000:02:00.0
[    6.017167] usb usb5: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.15
[    6.017168] usb usb5: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    6.017169] usb usb5: Product: xHCI Host Controller
[    6.017170] usb usb5: Manufacturer: Linux 5.15.0-39-generic xhci-hcd
[    6.017171] usb usb5: SerialNumber: 0000:3d:00.0
[    6.017524] usb usb6: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 5.15
[    6.017526] usb usb6: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    6.017527] usb usb6: Product: xHCI Host Controller
[    6.017527] usb usb6: Manufacturer: Linux 5.15.0-39-generic xhci-hcd
[    6.017528] usb usb6: SerialNumber: 0000:3d:00.0
[    6.295270] usb 1-9: new full-speed USB device number 2 using xhci_hcd
[    6.444654] usb 1-9: New USB device found, idVendor=0a5c, idProduct=4500, bcdDevice= 1.00
[    6.444664] usb 1-9: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[    6.444669] usb 1-9: Product: BRCM20702 Hub
[    6.444674] usb 1-9: Manufacturer: Apple Inc.
[    6.571302] usb 2-7: new SuperSpeed USB device number 2 using xhci_hcd
[    6.591875] usb 2-7: LPM exit latency is zeroed, disabling LPM.
[    6.592331] usb 2-7: New USB device found, idVendor=2cf0, idProduct=5246, bcdDevice= 0.00
[    6.592338] usb 2-7: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    6.592342] usb 2-7: Product: bladeRF
[    6.592346] usb 2-7: Manufacturer: Nuand
[    6.592348] usb 2-7: SerialNumber: a76f362458cf1f9be326411cf981a1ff
[    6.719253] usb 1-13: new high-speed USB device number 3 using xhci_hcd
[    6.867548] usb 1-13: New USB device found, idVendor=1a40, idProduct=0101, bcdDevice= 1.11
[    6.867559] usb 1-13: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[    6.867563] usb 1-13: Product: USB 2.0 Hub
[    6.947258] usb 1-9.1: new full-speed USB device number 4 using xhci_hcd
[    7.049583] usb 1-9.1: New USB device found, idVendor=05ac, idProduct=820a, bcdDevice= 1.00
[    7.049596] usb 1-9.1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[    7.131246] usb 1-9.2: new full-speed USB device number 5 using xhci_hcd
[    7.233064] usb 1-9.2: New USB device found, idVendor=05ac, idProduct=820b, bcdDevice= 1.00
[    7.233075] usb 1-9.2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[    7.431252] usb 1-13.1: new full-speed USB device number 6 using xhci_hcd
[    7.654331] usb 1-13.1: New USB device found, idVendor=258a, idProduct=002a, bcdDevice=13.45
[    7.654342] usb 1-13.1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[    7.654347] usb 1-13.1: Product: Keyboard
[    7.654350] usb 1-13.1: Manufacturer: SINO WEALTH
[    7.673713] usbcore: registered new interface driver usbhid
[    7.673751] usbhid: USB HID core driver
[    7.675614] input: HID 05ac:820a as /devices/pci0000:00/0000:00:14.0/usb1/1-9/1-9.1/1-9.1:1.0/0003:05AC:820A.0001/input/input12
[    7.735262] usb 1-9.3: new full-speed USB device number 7 using xhci_hcd
[    7.735655] hid-generic 0003:05AC:820A.0001: input,hidraw0: USB HID v1.11 Keyboard [HID 05ac:820a] on usb-0000:00:14.0-9.1/input0
[    7.736060] input: HID 05ac:820b as /devices/pci0000:00/0000:00:14.0/usb1/1-9/1-9.2/1-9.2:1.0/0003:05AC:820B.0002/input/input13
[    7.736577] hid-generic 0003:05AC:820B.0002: input,hidraw1: USB HID v1.11 Mouse [HID 05ac:820b] on usb-0000:00:14.0-9.2/input0
[    7.737211] input: SINO WEALTH Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.0/0003:258A:002A.0003/input/input14
[    7.795651] hid-generic 0003:258A:002A.0003: input,hidraw2: USB HID v1.11 Keyboard [SINO WEALTH Keyboard] on usb-0000:00:14.0-13.1/input0
[    7.796409] input: SINO WEALTH Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.0004/input/input15
[    7.837727] usb 1-9.3: New USB device found, idVendor=05ac, idProduct=828d, bcdDevice= 1.50
[    7.837738] usb 1-9.3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[    7.837743] usb 1-9.3: Product: Bluetooth USB Host Controller
[    7.837746] usb 1-9.3: Manufacturer: Apple Inc.
[    7.859546] input: SINO WEALTH Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.0004/input/input16
[    7.859818] input: SINO WEALTH Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.0004/input/input17
[    7.860328] hid-generic 0003:258A:002A.0004: input,hiddev0,hidraw3: USB HID v1.11 Keyboard [SINO WEALTH Keyboard] on usb-0000:00:14.0-13.1/input1
[    8.035222] usb 1-13.2: new full-speed USB device number 8 using xhci_hcd
[    8.265958] usb 1-13.2: New USB device found, idVendor=260d, idProduct=1010, bcdDevice= 1.30
[    8.265972] usb 1-13.2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[    8.265979] usb 1-13.2: Product: USB Gaming Mouse
[    8.265984] usb 1-13.2: Manufacturer: E-Signal
[    8.280434] input: E-Signal USB Gaming Mouse as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.0/0003:260D:1010.0005/input/input18
[    8.280978] hid-generic 0003:260D:1010.0005: input,hidraw4: USB HID v1.10 Mouse [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input0
[    8.285359] input: E-Signal USB Gaming Mouse Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.1/0003:260D:1010.0006/input/input19
[    8.343365] input: E-Signal USB Gaming Mouse as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.1/0003:260D:1010.0006/input/input20
[    8.343624] hid-generic 0003:260D:1010.0006: input,hiddev1,hidraw5: USB HID v1.10 Keyboard [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input1
[    8.345024] hid-generic 0003:260D:1010.0007: hiddev2,hidraw6: USB HID v1.10 Device [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input2
[   10.979352] usbcore: registered new device driver apple-mfi-fastcharge
[   11.151484] usbcore: registered new interface driver btusb
[   11.172333] usb 1-9.1: USB disconnect, device number 4
[   11.454902] usb 1-9.2: USB disconnect, device number 5
[   11.492955] usb 1-13: USB disconnect, device number 3
[   11.492958] usb 1-13.1: USB disconnect, device number 6
[   11.817192] usb 1-13.2: USB disconnect, device number 8
[   12.271203] usb 1-13: new high-speed USB device number 9 using xhci_hcd
[   12.419515] usb 1-13: New USB device found, idVendor=1a40, idProduct=0101, bcdDevice= 1.11
[   12.419519] usb 1-13: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[   12.419521] usb 1-13: Product: USB 2.0 Hub
[   12.811205] usb 1-13.2: new full-speed USB device number 10 using xhci_hcd
[   13.038030] usb 1-13.2: New USB device found, idVendor=260d, idProduct=1010, bcdDevice= 1.30
[   13.038033] usb 1-13.2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[   13.038034] usb 1-13.2: Product: USB Gaming Mouse
[   13.038035] usb 1-13.2: Manufacturer: E-Signal
[   13.051290] input: E-Signal USB Gaming Mouse as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.0/0003:260D:1010.0008/input/input29
[   13.051410] hid-generic 0003:260D:1010.0008: input,hidraw0: USB HID v1.10 Mouse [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input0
[   13.055123] input: E-Signal USB Gaming Mouse Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.1/0003:260D:1010.0009/input/input30
[   13.111378] input: E-Signal USB Gaming Mouse as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.1/0003:260D:1010.0009/input/input31
[   13.111613] hid-generic 0003:260D:1010.0009: input,hiddev0,hidraw1: USB HID v1.10 Keyboard [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input1
[   13.113214] hid-generic 0003:260D:1010.000A: hiddev1,hidraw2: USB HID v1.10 Device [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input2
[   13.467304] usb 1-13.1: new full-speed USB device number 11 using xhci_hcd
[   13.693807] usb 1-13.1: New USB device found, idVendor=258a, idProduct=002a, bcdDevice=13.45
[   13.693812] usb 1-13.1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[   13.693814] usb 1-13.1: Product: Keyboard
[   13.693815] usb 1-13.1: Manufacturer: SINO WEALTH
[   13.701112] input: SINO WEALTH Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.0/0003:258A:002A.000B/input/input32
[   13.759585] hid-generic 0003:258A:002A.000B: input,hidraw3: USB HID v1.11 Keyboard [SINO WEALTH Keyboard] on usb-0000:00:14.0-13.1/input0
[   13.761294] input: SINO WEALTH Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.000C/input/input33
[   13.819395] input: SINO WEALTH Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.000C/input/input34
[   13.819518] input: SINO WEALTH Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.000C/input/input35
[   13.819783] hid-generic 0003:258A:002A.000C: input,hiddev2,hidraw4: USB HID v1.11 Keyboard [SINO WEALTH Keyboard] on usb-0000:00:14.0-13.1/input1
[   58.094650] usb 1-13: USB disconnect, device number 9
[   58.094653] usb 1-13.1: USB disconnect, device number 11
[   58.412316] usb 1-13.2: USB disconnect, device number 10
[   58.895209] usb 1-13: new high-speed USB device number 12 using xhci_hcd
[   59.047580] usb 1-13: New USB device found, idVendor=1a40, idProduct=0101, bcdDevice= 1.11
[   59.047584] usb 1-13: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[   59.047585] usb 1-13: Product: USB 2.0 Hub
[   59.459212] usb 1-13.2: new full-speed USB device number 13 using xhci_hcd
[   59.670166] usb 1-13.2: New USB device found, idVendor=260d, idProduct=1010, bcdDevice= 1.30
[   59.670183] usb 1-13.2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[   59.670184] usb 1-13.2: Product: USB Gaming Mouse
[   59.670185] usb 1-13.2: Manufacturer: E-Signal
[   59.683713] input: E-Signal USB Gaming Mouse as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.0/0003:260D:1010.000D/input/input36
[   59.684009] hid-generic 0003:260D:1010.000D: input,hidraw0: USB HID v1.10 Mouse [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input0
[   59.687625] input: E-Signal USB Gaming Mouse Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.1/0003:260D:1010.000E/input/input37
[   59.747407] input: E-Signal USB Gaming Mouse as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.2/1-13.2:1.1/0003:260D:1010.000E/input/input38
[   59.747649] hid-generic 0003:260D:1010.000E: input,hiddev0,hidraw1: USB HID v1.10 Keyboard [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input1
[   59.749310] hid-generic 0003:260D:1010.000F: hiddev1,hidraw2: USB HID v1.10 Device [E-Signal USB Gaming Mouse] on usb-0000:00:14.0-13.2/input2
[   60.095221] usb 1-13.1: new full-speed USB device number 14 using xhci_hcd
[   60.302000] usb 1-13.1: New USB device found, idVendor=258a, idProduct=002a, bcdDevice=13.45
[   60.302017] usb 1-13.1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[   60.302018] usb 1-13.1: Product: Keyboard
[   60.302019] usb 1-13.1: Manufacturer: SINO WEALTH
[   60.309278] input: SINO WEALTH Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.0/0003:258A:002A.0010/input/input39
[   60.367547] hid-generic 0003:258A:002A.0010: input,hidraw3: USB HID v1.11 Keyboard [SINO WEALTH Keyboard] on usb-0000:00:14.0-13.1/input0
[   60.369316] input: SINO WEALTH Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.0011/input/input40
[   60.431426] input: SINO WEALTH Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.0011/input/input41
[   60.431564] input: SINO WEALTH Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-13/1-13.1/1-13.1:1.1/0003:258A:002A.0011/input/input42
[   60.431808] hid-generic 0003:258A:002A.0011: input,hiddev2,hidraw4: USB HID v1.11 Keyboard [SINO WEALTH Keyboard] on usb-0000:00:14.0-13.1/input1
[  100.724611] usb 2-7: reset SuperSpeed USB device number 2 using xhci_hcd
[  100.744911] usb 2-7: LPM exit latency is zeroed, disabling LPM.
[  116.109818] usb 2-7: reset SuperSpeed USB device number 2 using xhci_hcd
[  116.130294] usb 2-7: LPM exit latency is zeroed, disabling LPM.
[  252.613373] usb 2-7: reset SuperSpeed USB device number 2 using xhci_hcd
[  252.633592] usb 2-7: LPM exit latency is zeroed, disabling LPM.
[  286.175785] usb 2-7: reset SuperSpeed USB device number 2 using xhci_hcd
[  286.195916] usb 2-7: LPM exit latency is zeroed, disabling LPM.
[  418.960173] usb 2-7: reset SuperSpeed USB device number 2 using xhci_hcd
[  418.980669] usb 2-7: LPM exit latency is zeroed, disabling LPM.
[  557.580441] usb 2-7: reset SuperSpeed USB device number 2 using xhci_hcd
[  557.600939] usb 2-7: LPM exit latency is zeroed, disabling LPM.
[  639.263384] usb 2-7: USB disconnect, device number 2
[  649.148805] usb 2-2: new SuperSpeed USB device number 3 using xhci_hcd
[  649.169296] usb 2-2: LPM exit latency is zeroed, disabling LPM.
[  649.169938] usb 2-2: New USB device found, idVendor=2cf0, idProduct=5246, bcdDevice= 0.00
[  649.169947] usb 2-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  649.169952] usb 2-2: Product: bladeRF
[  649.169955] usb 2-2: Manufacturer: Nuand
[  649.169958] usb 2-2: SerialNumber: a76f362458cf1f9be326411cf981a1ff
[  653.805854] usb 2-2: reset SuperSpeed USB device number 3 using xhci_hcd
[  653.826301] usb 2-2: LPM exit latency is zeroed, disabling LPM.
[  655.782257] usb 2-2: reset SuperSpeed USB device number 3 using xhci_hcd
[  655.802656] usb 2-2: LPM exit latency is zeroed, disabling LPM.
[  737.639392] usb 2-2: reset SuperSpeed USB device number 3 using xhci_hcd
[  737.659822] usb 2-2: LPM exit latency is zeroed, disabling LPM.
[  769.414384] usb 2-2: reset SuperSpeed USB device number 3 using xhci_hcd
[  769.438844] usb 2-2: LPM exit latency is zeroed, disabling LPM.


#911

@cn0xroot
Copy link
Author

Try to use latest rbf FPGA

bladeRF-cli -l hostedx40-latest.rbf 
[INFO @ host/libraries/libbladeRF/src/board/bladerf1/bladerf1.c:872] Waiting for device to become ready...
Loading FPGA...
Error: failed to load FPGA: An unexpected error occurred
[ERROR @ host/libraries/libbladeRF/src/board/bladerf1/bladerf1.c:2531] Board state insufficient for operation (current "FPGA Loaded", requires "Initialized").
[ERROR @ host/libraries/libbladeRF/src/board/bladerf1/bladerf1.c:2531] Board state insufficient for operation (current "FPGA Loaded", requires "Initialized").

How to make it works fine? thanks

@rghilduta
Copy link
Collaborator

It seems like the PC is aggressively trying to power down XHCI devices. Can you put the governmor into performance mode?
Is this a VM or a physical machine?

Also, what's in bladerf.script?

@cn0xroot
Copy link
Author

cn0xroot commented Apr 18, 2023

  1. physical machine

cat bladerf.script 
set frequency tx 1575.42M
set samplerate tx 2.6M
set bandwidth tx 2.5M
set gain tx -25
cal lms
cal dc tx
tx config file=gpssim.bin format=bin
tx start
tx wait 

and also try default config file: https://github.com/osqzss/gps-sdr-sim/blob/master/bladerf.script

For best results, it is not recommended to set both RX and TX to the
same frequency. Instead, consider offsetting them by at least 1 MHz
and mixing digitally.

For the above reason, 'set frequency <value>` is deprecated and
scheduled for removal in future bladeRF-cli versions.

Please use 'set frequency rx' and 'set frequency tx' to configure
channels individually.



  Error (s.script:0): An unexpected error occurred

bladeRF-cli -l hostedx40-latest.rbf

Loading FPGA...
Error: failed to load FPGA: An unexpected error occurred
[ERROR @ host/libraries/libbladeRF/src/board/bladerf1/bladerf1.c:2531] Board state insufficient for operation (current "FPGA Loaded", requires "Initialized").
[ERROR @ host/libraries/libbladeRF/src/board/bladerf1/bladerf1.c:2531] Board state insufficient for operation (current "FPGA Loaded", requires "Initialized").

@cn0xroot
Copy link
Author

I would suggest removing: cal lms cal dc tx from the script if you're using a bladeRF 2.0 micro
thanks for comment

using bladerf X40

cal lms cal dc tx remove,and get the same output:
Error (bladerf.script:0): An unexpected error occurred

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants